Version in base suite: 3.3.8-2 Base version: ruby3.3_3.3.8-2 Target version: ruby3.3_3.3.13-0+deb13u1 Base file: /srv/ftp-master.debian.org/ftp/pool/main/r/ruby3.3/ruby3.3_3.3.8-2.dsc Target file: /srv/ftp-master.debian.org/policy/pool/main/r/ruby3.3/ruby3.3_3.3.13-0+deb13u1.dsc .bundle/gems/net-imap-0.4.19/BSDL | 22 .bundle/gems/net-imap-0.4.19/COPYING | 56 .bundle/gems/net-imap-0.4.19/Gemfile | 16 .bundle/gems/net-imap-0.4.19/LICENSE.txt | 65 .bundle/gems/net-imap-0.4.19/README.md | 71 .bundle/gems/net-imap-0.4.19/Rakefile | 13 .bundle/gems/net-imap-0.4.19/docs/styles.css | 24 .bundle/gems/net-imap-0.4.19/lib/net/imap.rb | 3116 .bundle/gems/net-imap-0.4.19/lib/net/imap/authenticators.rb | 37 .bundle/gems/net-imap-0.4.19/lib/net/imap/command_data.rb | 307 .bundle/gems/net-imap-0.4.19/lib/net/imap/config.rb | 443 .bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_accessors.rb | 75 .bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_inheritance.rb | 90 .bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_type_coercion.rb | 61 .bundle/gems/net-imap-0.4.19/lib/net/imap/data_encoding.rb | 214 .bundle/gems/net-imap-0.4.19/lib/net/imap/deprecated_client_options.rb | 139 .bundle/gems/net-imap-0.4.19/lib/net/imap/errors.rb | 79 .bundle/gems/net-imap-0.4.19/lib/net/imap/fetch_data.rb | 518 .bundle/gems/net-imap-0.4.19/lib/net/imap/flags.rb | 262 .bundle/gems/net-imap-0.4.19/lib/net/imap/response_data.rb | 1159 .bundle/gems/net-imap-0.4.19/lib/net/imap/response_parser.rb | 2140 .bundle/gems/net-imap-0.4.19/lib/net/imap/response_parser/parser_utils.rb | 240 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl.rb | 179 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/anonymous_authenticator.rb | 69 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/authentication_exchange.rb | 107 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/authenticators.rb | 118 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/client_adapter.rb | 72 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/cram_md5_authenticator.rb | 61 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/digest_md5_authenticator.rb | 180 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/external_authenticator.rb | 83 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/gs2_header.rb | 80 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/login_authenticator.rb | 55 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/oauthbearer_authenticator.rb | 199 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/plain_authenticator.rb | 101 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/protocol_adapters.rb | 45 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/scram_algorithm.rb | 58 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/scram_authenticator.rb | 287 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/stringprep.rb | 12 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/xoauth2_authenticator.rb | 106 .bundle/gems/net-imap-0.4.19/lib/net/imap/sasl_adapter.rb | 21 .bundle/gems/net-imap-0.4.19/lib/net/imap/search_result.rb | 146 .bundle/gems/net-imap-0.4.19/lib/net/imap/sequence_set.rb | 1570 .bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep.rb | 159 .bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/nameprep.rb | 70 .bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/saslprep.rb | 69 .bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/saslprep_tables.rb | 96 .bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/tables.rb | 146 .bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/trace.rb | 85 .bundle/gems/net-imap-0.4.19/lib/net/imap/uidplus_data.rb | 326 .bundle/gems/net-imap-0.4.19/net-imap.gemspec | 38 .bundle/gems/net-imap-0.4.19/rakelib/benchmarks.rake | 91 .bundle/gems/net-imap-0.4.19/rakelib/rdoc.rake | 70 .bundle/gems/net-imap-0.4.19/rakelib/rfcs.rake | 168 .bundle/gems/net-imap-0.4.19/rakelib/saslprep.rake | 30 .bundle/gems/net-imap-0.4.19/rakelib/string_prep_tables_generator.rb | 445 .bundle/gems/net-imap-0.4.19/sample/net-imap.rb | 167 .bundle/gems/net-imap-0.4.25/BSDL | 22 .bundle/gems/net-imap-0.4.25/COPYING | 56 .bundle/gems/net-imap-0.4.25/Gemfile | 16 .bundle/gems/net-imap-0.4.25/LICENSE.txt | 65 .bundle/gems/net-imap-0.4.25/README.md | 71 .bundle/gems/net-imap-0.4.25/Rakefile | 13 .bundle/gems/net-imap-0.4.25/docs/styles.css | 24 .bundle/gems/net-imap-0.4.25/lib/net/imap.rb | 3273 .bundle/gems/net-imap-0.4.25/lib/net/imap/authenticators.rb | 37 .bundle/gems/net-imap-0.4.25/lib/net/imap/command_data.rb | 507 .bundle/gems/net-imap-0.4.25/lib/net/imap/config.rb | 524 .bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_accessors.rb | 75 .bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_inheritance.rb | 90 .bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_type_coercion.rb | 62 .bundle/gems/net-imap-0.4.25/lib/net/imap/data_encoding.rb | 214 .bundle/gems/net-imap-0.4.25/lib/net/imap/deprecated_client_options.rb | 139 .bundle/gems/net-imap-0.4.25/lib/net/imap/errors.rb | 112 .bundle/gems/net-imap-0.4.25/lib/net/imap/fetch_data.rb | 518 .bundle/gems/net-imap-0.4.25/lib/net/imap/flags.rb | 262 .bundle/gems/net-imap-0.4.25/lib/net/imap/response_data.rb | 1179 .bundle/gems/net-imap-0.4.25/lib/net/imap/response_parser.rb | 2148 .bundle/gems/net-imap-0.4.25/lib/net/imap/response_parser/parser_utils.rb | 240 .bundle/gems/net-imap-0.4.25/lib/net/imap/response_reader.rb | 94 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl.rb | 179 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/anonymous_authenticator.rb | 69 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/authentication_exchange.rb | 107 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/authenticators.rb | 118 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/client_adapter.rb | 72 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/cram_md5_authenticator.rb | 61 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/digest_md5_authenticator.rb | 180 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/external_authenticator.rb | 83 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/gs2_header.rb | 80 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/login_authenticator.rb | 55 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/oauthbearer_authenticator.rb | 199 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/plain_authenticator.rb | 101 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/protocol_adapters.rb | 45 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/scram_algorithm.rb | 58 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/scram_authenticator.rb | 361 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/stringprep.rb | 12 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/xoauth2_authenticator.rb | 106 .bundle/gems/net-imap-0.4.25/lib/net/imap/sasl_adapter.rb | 21 .bundle/gems/net-imap-0.4.25/lib/net/imap/search_result.rb | 146 .bundle/gems/net-imap-0.4.25/lib/net/imap/sequence_set.rb | 1577 .bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep.rb | 159 .bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/nameprep.rb | 70 .bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/saslprep.rb | 69 .bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/saslprep_tables.rb | 96 .bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/tables.rb | 146 .bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/trace.rb | 85 .bundle/gems/net-imap-0.4.25/lib/net/imap/uidplus_data.rb | 326 .bundle/gems/net-imap-0.4.25/net-imap.gemspec | 38 .bundle/gems/net-imap-0.4.25/rakelib/benchmarks.rake | 91 .bundle/gems/net-imap-0.4.25/rakelib/rdoc.rake | 70 .bundle/gems/net-imap-0.4.25/rakelib/rfcs.rake | 168 .bundle/gems/net-imap-0.4.25/rakelib/saslprep.rake | 30 .bundle/gems/net-imap-0.4.25/rakelib/string_prep_tables_generator.rb | 445 .bundle/gems/net-imap-0.4.25/sample/net-imap.rb | 167 .bundle/gems/rexml-3.3.9/LICENSE.txt | 22 .bundle/gems/rexml-3.3.9/NEWS.md | 646 .bundle/gems/rexml-3.3.9/README.md | 57 .bundle/gems/rexml-3.3.9/doc/rexml/context.rdoc | 143 .bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/child.rdoc | 87 .bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/document.rdoc | 276 .bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/element.rdoc | 602 .bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/node.rdoc | 97 .bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/parent.rdoc | 267 .bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/child_toc.rdoc | 12 .bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/document_toc.rdoc | 30 .bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/element_toc.rdoc | 55 .bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/master_toc.rdoc | 135 .bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/node_toc.rdoc | 16 .bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/parent_toc.rdoc | 25 .bundle/gems/rexml-3.3.9/doc/rexml/tutorial.rdoc | 1358 .bundle/gems/rexml-3.3.9/lib/rexml.rb | 3 .bundle/gems/rexml-3.3.9/lib/rexml/attlistdecl.rb | 63 .bundle/gems/rexml-3.3.9/lib/rexml/attribute.rb | 211 .bundle/gems/rexml-3.3.9/lib/rexml/cdata.rb | 68 .bundle/gems/rexml-3.3.9/lib/rexml/child.rb | 97 .bundle/gems/rexml-3.3.9/lib/rexml/comment.rb | 80 .bundle/gems/rexml-3.3.9/lib/rexml/doctype.rb | 311 .bundle/gems/rexml-3.3.9/lib/rexml/document.rb | 455 .bundle/gems/rexml-3.3.9/lib/rexml/dtd/attlistdecl.rb | 11 .bundle/gems/rexml-3.3.9/lib/rexml/dtd/dtd.rb | 47 .bundle/gems/rexml-3.3.9/lib/rexml/dtd/elementdecl.rb | 18 .bundle/gems/rexml-3.3.9/lib/rexml/dtd/entitydecl.rb | 57 .bundle/gems/rexml-3.3.9/lib/rexml/dtd/notationdecl.rb | 40 .bundle/gems/rexml-3.3.9/lib/rexml/element.rb | 2584 .bundle/gems/rexml-3.3.9/lib/rexml/encoding.rb | 51 .bundle/gems/rexml-3.3.9/lib/rexml/entity.rb | 142 .bundle/gems/rexml-3.3.9/lib/rexml/formatters/default.rb | 116 .bundle/gems/rexml-3.3.9/lib/rexml/formatters/pretty.rb | 142 .bundle/gems/rexml-3.3.9/lib/rexml/formatters/transitive.rb | 58 .bundle/gems/rexml-3.3.9/lib/rexml/functions.rb | 446 .bundle/gems/rexml-3.3.9/lib/rexml/instruction.rb | 79 .bundle/gems/rexml-3.3.9/lib/rexml/light/node.rb | 188 .bundle/gems/rexml-3.3.9/lib/rexml/namespace.rb | 63 .bundle/gems/rexml-3.3.9/lib/rexml/node.rb | 80 .bundle/gems/rexml-3.3.9/lib/rexml/output.rb | 30 .bundle/gems/rexml-3.3.9/lib/rexml/parent.rb | 166 .bundle/gems/rexml-3.3.9/lib/rexml/parseexception.rb | 53 .bundle/gems/rexml-3.3.9/lib/rexml/parsers/baseparser.rb | 862 .bundle/gems/rexml-3.3.9/lib/rexml/parsers/lightparser.rb | 59 .bundle/gems/rexml-3.3.9/lib/rexml/parsers/pullparser.rb | 209 .bundle/gems/rexml-3.3.9/lib/rexml/parsers/sax2parser.rb | 270 .bundle/gems/rexml-3.3.9/lib/rexml/parsers/streamparser.rb | 67 .bundle/gems/rexml-3.3.9/lib/rexml/parsers/treeparser.rb | 89 .bundle/gems/rexml-3.3.9/lib/rexml/parsers/ultralightparser.rb | 57 .bundle/gems/rexml-3.3.9/lib/rexml/parsers/xpathparser.rb | 739 .bundle/gems/rexml-3.3.9/lib/rexml/quickpath.rb | 266 .bundle/gems/rexml-3.3.9/lib/rexml/rexml.rb | 39 .bundle/gems/rexml-3.3.9/lib/rexml/sax2listener.rb | 98 .bundle/gems/rexml-3.3.9/lib/rexml/security.rb | 28 .bundle/gems/rexml-3.3.9/lib/rexml/source.rb | 334 .bundle/gems/rexml-3.3.9/lib/rexml/streamlistener.rb | 93 .bundle/gems/rexml-3.3.9/lib/rexml/text.rb | 448 .bundle/gems/rexml-3.3.9/lib/rexml/undefinednamespaceexception.rb | 9 .bundle/gems/rexml-3.3.9/lib/rexml/validation/relaxng.rb | 539 .bundle/gems/rexml-3.3.9/lib/rexml/validation/validation.rb | 144 .bundle/gems/rexml-3.3.9/lib/rexml/validation/validationexception.rb | 10 .bundle/gems/rexml-3.3.9/lib/rexml/xmldecl.rb | 130 .bundle/gems/rexml-3.3.9/lib/rexml/xmltokens.rb | 85 .bundle/gems/rexml-3.3.9/lib/rexml/xpath.rb | 81 .bundle/gems/rexml-3.3.9/lib/rexml/xpath_parser.rb | 978 .bundle/gems/rexml-3.4.4/LICENSE.txt | 22 .bundle/gems/rexml-3.4.4/NEWS.md | 843 .bundle/gems/rexml-3.4.4/README.md | 57 .bundle/gems/rexml-3.4.4/doc/rexml/context.rdoc | 143 .bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/child.rdoc | 87 .bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/document.rdoc | 276 .bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/element.rdoc | 602 .bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/node.rdoc | 97 .bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/parent.rdoc | 267 .bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/child_toc.rdoc | 12 .bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/document_toc.rdoc | 30 .bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/element_toc.rdoc | 55 .bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/master_toc.rdoc | 135 .bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/node_toc.rdoc | 16 .bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/parent_toc.rdoc | 25 .bundle/gems/rexml-3.4.4/doc/rexml/tutorial.rdoc | 1358 .bundle/gems/rexml-3.4.4/lib/rexml.rb | 3 .bundle/gems/rexml-3.4.4/lib/rexml/attlistdecl.rb | 63 .bundle/gems/rexml-3.4.4/lib/rexml/attribute.rb | 210 .bundle/gems/rexml-3.4.4/lib/rexml/cdata.rb | 68 .bundle/gems/rexml-3.4.4/lib/rexml/child.rb | 96 .bundle/gems/rexml-3.4.4/lib/rexml/comment.rb | 80 .bundle/gems/rexml-3.4.4/lib/rexml/doctype.rb | 306 .bundle/gems/rexml-3.4.4/lib/rexml/document.rb | 471 .bundle/gems/rexml-3.4.4/lib/rexml/dtd/attlistdecl.rb | 11 .bundle/gems/rexml-3.4.4/lib/rexml/dtd/dtd.rb | 47 .bundle/gems/rexml-3.4.4/lib/rexml/dtd/elementdecl.rb | 18 .bundle/gems/rexml-3.4.4/lib/rexml/dtd/entitydecl.rb | 57 .bundle/gems/rexml-3.4.4/lib/rexml/dtd/notationdecl.rb | 40 .bundle/gems/rexml-3.4.4/lib/rexml/element.rb | 2578 .bundle/gems/rexml-3.4.4/lib/rexml/encoding.rb | 48 .bundle/gems/rexml-3.4.4/lib/rexml/entity.rb | 142 .bundle/gems/rexml-3.4.4/lib/rexml/formatters/default.rb | 116 .bundle/gems/rexml-3.4.4/lib/rexml/formatters/pretty.rb | 142 .bundle/gems/rexml-3.4.4/lib/rexml/formatters/transitive.rb | 58 .bundle/gems/rexml-3.4.4/lib/rexml/functions.rb | 446 .bundle/gems/rexml-3.4.4/lib/rexml/instruction.rb | 79 .bundle/gems/rexml-3.4.4/lib/rexml/light/node.rb | 188 .bundle/gems/rexml-3.4.4/lib/rexml/namespace.rb | 63 .bundle/gems/rexml-3.4.4/lib/rexml/node.rb | 80 .bundle/gems/rexml-3.4.4/lib/rexml/output.rb | 30 .bundle/gems/rexml-3.4.4/lib/rexml/parent.rb | 166 .bundle/gems/rexml-3.4.4/lib/rexml/parseexception.rb | 53 .bundle/gems/rexml-3.4.4/lib/rexml/parsers/baseparser.rb | 949 .bundle/gems/rexml-3.4.4/lib/rexml/parsers/lightparser.rb | 59 .bundle/gems/rexml-3.4.4/lib/rexml/parsers/pullparser.rb | 213 .bundle/gems/rexml-3.4.4/lib/rexml/parsers/sax2parser.rb | 270 .bundle/gems/rexml-3.4.4/lib/rexml/parsers/streamparser.rb | 67 .bundle/gems/rexml-3.4.4/lib/rexml/parsers/treeparser.rb | 89 .bundle/gems/rexml-3.4.4/lib/rexml/parsers/ultralightparser.rb | 57 .bundle/gems/rexml-3.4.4/lib/rexml/parsers/xpathparser.rb | 739 .bundle/gems/rexml-3.4.4/lib/rexml/quickpath.rb | 267 .bundle/gems/rexml-3.4.4/lib/rexml/rexml.rb | 39 .bundle/gems/rexml-3.4.4/lib/rexml/sax2listener.rb | 98 .bundle/gems/rexml-3.4.4/lib/rexml/security.rb | 28 .bundle/gems/rexml-3.4.4/lib/rexml/source.rb | 388 .bundle/gems/rexml-3.4.4/lib/rexml/streamlistener.rb | 93 .bundle/gems/rexml-3.4.4/lib/rexml/text.rb | 420 .bundle/gems/rexml-3.4.4/lib/rexml/undefinednamespaceexception.rb | 9 .bundle/gems/rexml-3.4.4/lib/rexml/validation/relaxng.rb | 540 .bundle/gems/rexml-3.4.4/lib/rexml/validation/validation.rb | 144 .bundle/gems/rexml-3.4.4/lib/rexml/validation/validationexception.rb | 10 .bundle/gems/rexml-3.4.4/lib/rexml/xmldecl.rb | 130 .bundle/gems/rexml-3.4.4/lib/rexml/xmltokens.rb | 85 .bundle/gems/rexml-3.4.4/lib/rexml/xpath.rb | 70 .bundle/gems/rexml-3.4.4/lib/rexml/xpath_parser.rb | 980 .bundle/specifications/net-imap-0.4.19.gemspec | 26 .bundle/specifications/net-imap-0.4.25.gemspec | 26 .bundle/specifications/rexml-3.3.9.gemspec | 23 .bundle/specifications/rexml-3.4.4.gemspec | 23 ChangeLog |83367 ---------- bignum.c | 11 bootstraptest/test_fork.rb | 9 bootstraptest/test_ractor.rb | 12 bootstraptest/test_yjit.rb | 78 common.mk | 41 compile.c | 29 configure | 10 configure.ac | 10 cont.c | 45 debian/changelog | 52 debian/patches/CVE-2025-27221_1.patch | 49 debian/patches/CVE-2025-27221_2.patch | 85 debian/patches/series | 2 defs/gmake.mk | 3 enc/depend | 1 enc/jis/props.h | 17 enc/jis/props.h.blt | 17 enc/trans/iso2022.c | 5 enc/trans/iso2022.trans | 3 enc/unicode.c | 8 enumerator.c | 5 error.c | 4 eval_error.c | 4 ext/-test-/string/fstring.c | 2 ext/date/date_core.c | 21 ext/date/prereq.mk | 2 ext/date/zonetab.h | 635 ext/etc/extconf.rb | 2 ext/extmk.rb | 1 ext/io/console/depend | 2 ext/io/console/extconf.rb | 10 ext/io/console/win32_vk.inc | 327 ext/io/console/win32_vk.list | 2 ext/io/nonblock/extconf.rb | 2 ext/io/wait/extconf.rb | 4 ext/io/wait/wait.c | 8 ext/json/parser/extconf.rb | 4 ext/openssl/History.md | 86 ext/openssl/depend | 156 ext/openssl/extconf.rb | 13 ext/openssl/lib/openssl/buffering.rb | 17 ext/openssl/lib/openssl/ssl.rb | 1 ext/openssl/lib/openssl/version.rb | 2 ext/openssl/lib/openssl/x509.rb | 10 ext/openssl/openssl.gemspec | 2 ext/openssl/openssl_missing.c | 1 ext/openssl/openssl_missing.h | 27 ext/openssl/ossl.c | 2 ext/openssl/ossl.h | 3 ext/openssl/ossl_asn1.c | 124 ext/openssl/ossl_cipher.c | 23 ext/openssl/ossl_digest.c | 1 ext/openssl/ossl_ns_spki.c | 9 ext/openssl/ossl_ocsp.c | 16 ext/openssl/ossl_pkcs7.c | 14 ext/openssl/ossl_pkey.c | 83 ext/openssl/ossl_pkey_dh.c | 2 ext/openssl/ossl_pkey_dsa.c | 2 ext/openssl/ossl_pkey_ec.c | 2 ext/openssl/ossl_pkey_rsa.c | 2 ext/openssl/ossl_provider.c | 2 ext/openssl/ossl_ts.c | 8 ext/openssl/ossl_x509.h | 12 ext/openssl/ossl_x509attr.c | 13 ext/openssl/ossl_x509cert.c | 12 ext/openssl/ossl_x509crl.c | 10 ext/openssl/ossl_x509ext.c | 27 ext/openssl/ossl_x509name.c | 12 ext/openssl/ossl_x509req.c | 4 ext/openssl/ossl_x509revoked.c | 7 ext/openssl/ossl_x509store.c | 8 ext/socket/rubysocket.h | 4 ext/socket/unixsocket.c | 3 ext/strscan/extconf.rb | 4 ext/zlib/zlib.c | 6 ext/zlib/zlib.gemspec | 2 file.c | 7 gems/bundled_gems | 4 golf_prelude.c | 15 hash.c | 107 id.c | 3 include/ruby/internal/anyargs.h | 22 include/ruby/internal/attr/nonstring.h | 40 include/ruby/internal/core/rbasic.h | 3 include/ruby/internal/core/rstring.h | 57 include/ruby/internal/stdbool.h | 12 include/ruby/onigmo.h | 3 include/ruby/win32.h | 7 io.c | 107 iseq.c | 2 lex.c | 85 lex.c.blt | 85 lib/bundler/vendor/uri/lib/uri/generic.rb | 32 lib/bundler/vendor/uri/lib/uri/version.rb | 2 lib/erb.rb | 3 lib/erb/version.rb | 2 lib/mkmf.rb | 2 lib/pstore.rb | 27 lib/resolv.rb | 105 lib/rubygems/vendor/uri/lib/uri/generic.rb | 38 lib/rubygems/vendor/uri/lib/uri/version.rb | 2 lib/syntax_suggest/api.rb | 7 lib/syntax_suggest/capture_code_context.rb | 2 lib/syntax_suggest/clean_document.rb | 2 lib/syntax_suggest/code_frontier.rb | 2 lib/syntax_suggest/code_line.rb | 19 lib/syntax_suggest/core_ext.rb | 18 lib/syntax_suggest/mini_stringio.rb | 30 lib/syntax_suggest/version.rb | 2 lib/unicode_normalize/normalize.rb | 22 lib/uri/generic.rb | 29 lib/uri/version.rb | 2 libexec/syntax_suggest | 7 load.c | 17 marshal.c | 99 miniprelude.c | 619 numeric.c | 2 pack.c | 2 prism/util/pm_memchr.c | 2 prism/util/pm_memchr.h | 2 prism_compile.c | 2 proc.c | 39 ractor.c | 2 random.c | 88 regcomp.c | 2410 regenc.c | 88 regenc.h | 13 regerror.c | 90 regexec.c | 2778 regint.h | 6 regparse.c | 2563 regparse.h | 4 revision.h | 10 ruby.c | 2 scheduler.c | 24 signal.c | 4 siphash.c | 3 spec/bundler/spec_helper.rb | 10 spec/bundler/support/builders.rb | 4 spec/bundler/support/path.rb | 4 spec/ruby/core/file/atime_spec.rb | 3 spec/ruby/core/file/ctime_spec.rb | 3 spec/ruby/core/file/mtime_spec.rb | 3 spec/ruby/core/kernel/shared/require.rb | 4 spec/ruby/core/marshal/dump_spec.rb | 27 spec/ruby/core/math/lgamma_spec.rb | 11 spec/ruby/core/module/ruby2_keywords_spec.rb | 17 spec/ruby/core/proc/ruby2_keywords_spec.rb | 14 spec/ruby/core/process/daemon_spec.rb | 3 spec/ruby/core/unboundmethod/equal_value_spec.rb | 30 spec/ruby/core/unboundmethod/fixtures/classes.rb | 16 spec/ruby/library/uri/set_component_spec.rb | 40 spec/syntax_suggest/integration/syntax_suggest_spec.rb | 4 spec/syntax_suggest/spec_helper.rb | 5 spec/syntax_suggest/unit/mini_stringio_spec.rb | 25 st.c | 9 string.c | 42 struct.c | 4 symbol.c | 9 template/Makefile.in | 66 template/fake.rb.in | 1 template/id.c.tmpl | 3 template/prelude.c.tmpl | 5 test/-ext-/bug_reporter/test_bug_reporter.rb | 2 test/-ext-/debug/test_debug.rb | 15 test/coverage/test_coverage.rb | 17 test/date/test_date.rb | 4 test/erb/test_erb.rb | 27 test/io/wait/test_io_wait_uncommon.rb | 30 test/openssl/test_asn1.rb | 17 test/openssl/test_bn.rb | 48 test/openssl/test_cipher.rb | 40 test/openssl/test_ossl.rb | 12 test/openssl/test_pkcs7.rb | 15 test/openssl/test_pkey.rb | 54 test/openssl/test_pkey_dsa.rb | 6 test/openssl/test_pkey_rsa.rb | 2 test/openssl/test_provider.rb | 17 test/openssl/test_ssl.rb | 8 test/openssl/test_x509cert.rb | 99 test/resolv/test_dns.rb | 208 test/resolv/test_resource.rb | 61 test/resolv/test_resource_leak.rb | 101 test/ruby/test_bignum.rb | 3 test/ruby/test_data.rb | 7 test/ruby/test_exception.rb | 9 test/ruby/test_hash.rb | 24 test/ruby/test_keyword.rb | 38 test/ruby/test_marshal.rb | 26 test/ruby/test_math.rb | 12 test/ruby/test_method.rb | 14 test/ruby/test_numeric.rb | 4 test/ruby/test_process.rb | 2 test/ruby/test_refinement.rb | 35 test/ruby/test_regexp.rb | 74 test/ruby/test_require.rb | 38 test/ruby/test_rubyoptions.rb | 70 test/ruby/test_string.rb | 7 test/ruby/test_struct.rb | 6 test/ruby/test_thread.rb | 61 test/ruby/test_variable.rb | 23 test/ruby/test_vm_dump.rb | 2 test/ruby/test_yjit.rb | 12 test/rubygems/test_gem_request.rb | 2 test/rubygems/test_gem_uri.rb | 2 test/socket/test_unix.rb | 20 test/test_pstore.rb | 13 test/test_unicode_normalize.rb | 19 test/uri/test_generic.rb | 15 test/zlib/test_zlib.rb | 19 thread.c | 4 thread_pthread.c | 85 thread_pthread.h | 50 thread_pthread_mn.c | 44 thread_sync.c | 73 tool/bundler/dev_gems.rb | 2 tool/bundler/vendor_gems.rb | 1 tool/commit-mail.rb | 399 tool/config.guess | 1240 tool/config.sub | 15 tool/downloader.rb | 3 tool/gperf.sed | 19 tool/lib/core_assertions.rb | 59 tool/lib/test/unit.rb | 1 tool/merger.rb | 24 tool/redmine-backporter.rb | 35 tool/sync_default_gems.rb | 4 tool/test/webrick/test_filehandler.rb | 1 variable.c | 107 version.h | 4 vm.c | 7 vm_method.c | 23 vm_trace.c | 1 wasm/setjmp.c | 8 wasm/setjmp.h | 1 win32/Makefile.sub | 11 win32/mkexports.rb | 21 win32/win32.c | 21 yjit/src/codegen.rs | 10 yjit/src/core.rs | 39 yjit/src/stats.rs | 1 491 files changed, 40116 insertions(+), 119937 deletions(-) dpkg-source: warning: cannot verify inline signature for /srv/release.debian.org/tmp/tmplbpur2l7/ruby3.3_3.3.8-2.dsc: no acceptable signature found dpkg-source: warning: cannot verify inline signature for /srv/release.debian.org/tmp/tmplbpur2l7/ruby3.3_3.3.13-0+deb13u1.dsc: no acceptable signature found diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/BSDL ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/BSDL --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/BSDL 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/BSDL 1970-01-01 00:00:00.000000000 +0000 @@ -1,22 +0,0 @@ -Copyright (C) 1993-2013 Yukihiro Matsumoto. All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions -are met: -1. Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. -2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - -THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -SUCH DAMAGE. diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/COPYING ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/COPYING --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/COPYING 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/COPYING 1970-01-01 00:00:00.000000000 +0000 @@ -1,56 +0,0 @@ -Ruby is copyrighted free software by Yukihiro Matsumoto . -You can redistribute it and/or modify it under either the terms of the -2-clause BSDL (see the file BSDL), or the conditions below: - -1. You may make and give away verbatim copies of the source form of the - software without restriction, provided that you duplicate all of the - original copyright notices and associated disclaimers. - -2. You may modify your copy of the software in any way, provided that - you do at least ONE of the following: - - a. place your modifications in the Public Domain or otherwise - make them Freely Available, such as by posting said - modifications to Usenet or an equivalent medium, or by allowing - the author to include your modifications in the software. - - b. use the modified software only within your corporation or - organization. - - c. give non-standard binaries non-standard names, with - instructions on where to get the original software distribution. - - d. make other distribution arrangements with the author. - -3. You may distribute the software in object code or binary form, - provided that you do at least ONE of the following: - - a. distribute the binaries and library files of the software, - together with instructions (in the manual page or equivalent) - on where to get the original distribution. - - b. accompany the distribution with the machine-readable source of - the software. - - c. give non-standard binaries non-standard names, with - instructions on where to get the original software distribution. - - d. make other distribution arrangements with the author. - -4. You may modify and include the part of the software into any other - software (possibly commercial). But some files in the distribution - are not written by the author, so that they are not under these terms. - - For the list of those files and their copying conditions, see the - file LEGAL. - -5. The scripts and library files supplied as input to or produced as - output from the software do not automatically fall under the - copyright of the software, but belong to whomever generated them, - and may be sold commercially, and may be aggregated with this - software. - -6. THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR - IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR - PURPOSE. diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/Gemfile ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/Gemfile --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/Gemfile 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/Gemfile 1970-01-01 00:00:00.000000000 +0000 @@ -1,16 +0,0 @@ -# frozen_string_literal: true - -source "https://rubygems.org" - -gemspec - -gem "digest" -gem "strscan" -gem "base64" - -gem "rake" -gem "rdoc" -gem "test-unit" -gem "test-unit-ruby-core", git: "https://github.com/ruby/test-unit-ruby-core" - -gem "benchmark-driver" diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/LICENSE.txt ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/LICENSE.txt --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/LICENSE.txt 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/LICENSE.txt 1970-01-01 00:00:00.000000000 +0000 @@ -1,65 +0,0 @@ -All the files in this distribution are covered under either the Ruby license or -the BSD-2-Clause license (see the file COPYING) except some documentation mentioned -below. - -------------------------------------------------------------------------- - -This software includes documentation which has been copied from the relevant -RFCs. The copied documentation is covered by the following licenses: - -RFC 3501 (Editor: M. Crispin) -Full Copyright Statement - - Copyright (C) The Internet Society (2003). All Rights Reserved. - - This document and translations of it may be copied and furnished to - others, and derivative works that comment on or otherwise explain it - or assist in its implementation may be prepared, copied, published - and distributed, in whole or in part, without restriction of any - kind, provided that the above copyright notice and this paragraph are - included on all such copies and derivative works. However, this - document itself may not be modified in any way, such as by removing - the copyright notice or references to the Internet Society or other - Internet organizations, except as needed for the purpose of - developing Internet standards in which case the procedures for - copyrights defined in the Internet Standards process must be - followed, or as required to translate it into languages other than - English. - - The limited permissions granted above are perpetual and will not be - revoked by the Internet Society or its successors or assigns. v This - document and the information contained herein is provided on an "AS - IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING TASK - FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT - LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL - NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY - OR FITNESS FOR A PARTICULAR PURPOSE. - - -RFC9051 (Editors: A. Melnikov, B. Leiba) -Copyright Notice - - Copyright (c) 2021 IETF Trust and the persons identified as the - document authors. All rights reserved. - - This document is subject to BCP 78 and the IETF Trust's Legal - Provisions Relating to IETF Documents - (https://trustee.ietf.org/license-info) in effect on the date of - publication of this document. Please review these documents - carefully, as they describe your rights and restrictions with respect - to this document. Code Components extracted from this document must - include Simplified BSD License text as described in Section 4.e of - the Trust Legal Provisions and are provided without warranty as - described in the Simplified BSD License. - - This document may contain material from IETF Documents or IETF - Contributions published or made publicly available before November - 10, 2008. The person(s) controlling the copyright in some of this - material may not have granted the IETF Trust the right to allow - modifications of such material outside the IETF Standards Process. - Without obtaining an adequate license from the person(s) controlling - the copyright in such materials, this document may not be modified - outside the IETF Standards Process, and derivative works of it may - not be created outside the IETF Standards Process, except to format - it for publication as an RFC or to translate it into languages other - than English. diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/README.md ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/README.md --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/README.md 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/README.md 1970-01-01 00:00:00.000000000 +0000 @@ -1,71 +0,0 @@ -# Net::IMAP - -Net::IMAP implements Internet Message Access Protocol (IMAP) client -functionality. The protocol is described in [IMAP](https://tools.ietf.org/html/rfc3501). - -## Installation - -Add this line to your application's Gemfile: - -```ruby -gem 'net-imap' -``` - -And then execute: - - $ bundle install - -Or install it yourself as: - - $ gem install net-imap - -## Usage - -### Connect with TLS to port 993 - -```ruby -imap = Net::IMAP.new('mail.example.com', ssl: true) -imap.port => 993 -imap.tls_verified? => true -case imap.greeting.name -in /OK/i - # The client is connected in the "Not Authenticated" state. - imap.authenticate("PLAIN", "joe_user", "joes_password") -in /PREAUTH/i - # The client is connected in the "Authenticated" state. -end -``` - -### List sender and subject of all recent messages in the default mailbox - -```ruby -imap.examine('INBOX') -imap.search(["RECENT"]).each do |message_id| - envelope = imap.fetch(message_id, "ENVELOPE")[0].attr["ENVELOPE"] - puts "#{envelope.from[0].name}: \t#{envelope.subject}" -end -``` - -### Move all messages from April 2003 from "Mail/sent-mail" to "Mail/sent-apr03" - -```ruby -imap.select('Mail/sent-mail') -if not imap.list('Mail/', 'sent-apr03') - imap.create('Mail/sent-apr03') -end -imap.search(["BEFORE", "30-Apr-2003", "SINCE", "1-Apr-2003"]).each do |message_id| - imap.copy(message_id, "Mail/sent-apr03") - imap.store(message_id, "+FLAGS", [:Deleted]) -end -imap.expunge -``` - -## Development - -After checking out the repo, run `bin/setup` to install dependencies. Then, run `bundle exec rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment. - -To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org). - -## Contributing - -Bug reports and pull requests are welcome on GitHub at https://github.com/ruby/net-imap. diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/Rakefile ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/Rakefile --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/Rakefile 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/Rakefile 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ -# frozen_string_literal: true - -require "bundler/gem_tasks" -require "rake/testtask" -require "rake/clean" - -Rake::TestTask.new(:test) do |t| - t.libs << "test/lib" - t.ruby_opts << "-rhelper" - t.test_files = FileList["test/**/test_*.rb"] -end - -task :default => :test diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/docs/styles.css ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/docs/styles.css --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/docs/styles.css 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/docs/styles.css 1970-01-01 00:00:00.000000000 +0000 @@ -1,24 +0,0 @@ -/* this is a work in progress. :) */ - -main .method-header { - background: rgba(27,31,35,0.05); - border: 1px solid #6C8C22; - padding: 0.5em; - border-radius: 4px; - /* padding: 0 0.5em; */ - /* border-width: 0 1px; */ - /* border-color: #6C8C22; */ - /* border-style: solid; */ -} - -main .method-description, main .aliases { - padding-left: 1em; -} - -body { - /* - * The default (300) can be too low contrast. Also, many fonts don't - * distinguish between 300->400, so ... had no effect. - */ - font-weight: 400; -} diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/authenticators.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/authenticators.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/authenticators.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/authenticators.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,37 +0,0 @@ -# frozen_string_literal: true - -# Backward compatible delegators from Net::IMAP to Net::IMAP::SASL. -module Net::IMAP::Authenticators - - # Deprecated. Use Net::IMAP::SASL.add_authenticator instead. - def add_authenticator(...) - warn( - "%s.%s is deprecated. Use %s.%s instead." % [ - Net::IMAP, __method__, Net::IMAP::SASL, __method__ - ], - uplevel: 1 - ) - Net::IMAP::SASL.add_authenticator(...) - end - - # Deprecated. Use Net::IMAP::SASL.authenticator instead. - def authenticator(...) - warn( - "%s.%s is deprecated. Use %s.%s instead." % [ - Net::IMAP, __method__, Net::IMAP::SASL, __method__ - ], - uplevel: 1 - ) - Net::IMAP::SASL.authenticator(...) - end - - Net::IMAP.extend self -end - -class Net::IMAP - PlainAuthenticator = SASL::PlainAuthenticator # :nodoc: - deprecate_constant :PlainAuthenticator - - XOauth2Authenticator = SASL::XOAuth2Authenticator # :nodoc: - deprecate_constant :XOauth2Authenticator -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/command_data.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/command_data.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/command_data.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/command_data.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,307 +0,0 @@ -# frozen_string_literal: true - -require "date" - -require_relative "errors" - -module Net - class IMAP < Protocol - - private - - def validate_data(data) - case data - when nil - when String - when Integer - NumValidator.ensure_number(data) - when Array - if data[0] == 'CHANGEDSINCE' - NumValidator.ensure_mod_sequence_value(data[1]) - else - data.each do |i| - validate_data(i) - end - end - when Time, Date, DateTime - when Symbol - else - data.validate - end - end - - def send_data(data, tag = nil) - case data - when nil - put_string("NIL") - when String - send_string_data(data, tag) - when Integer - send_number_data(data) - when Array - send_list_data(data, tag) - when Time, DateTime - send_time_data(data) - when Date - send_date_data(data) - when Symbol - send_symbol_data(data) - else - data.send_data(self, tag) - end - end - - def send_string_data(str, tag = nil) - if str.empty? - put_string('""') - elsif str.match?(/[\r\n]/n) - # literal, because multiline - send_literal(str, tag) - elsif !str.ascii_only? - if @utf8_strings - # quoted string - send_quoted_string(str) - else - # literal, because of non-ASCII bytes - send_literal(str, tag) - end - elsif str.match?(/[(){ \x00-\x1f\x7f%*"\\]/n) - # quoted string - send_quoted_string(str) - else - put_string(str) - end - end - - def send_quoted_string(str) - put_string('"' + str.gsub(/["\\]/, "\\\\\\&") + '"') - end - - def send_literal(str, tag = nil) - synchronize do - put_string("{" + str.bytesize.to_s + "}" + CRLF) - @continued_command_tag = tag - @continuation_request_exception = nil - begin - @continuation_request_arrival.wait - e = @continuation_request_exception || @exception - raise e if e - put_string(str) - ensure - @continued_command_tag = nil - @continuation_request_exception = nil - end - end - end - - def send_number_data(num) - put_string(num.to_s) - end - - def send_list_data(list, tag = nil) - put_string("(") - first = true - list.each do |i| - if first - first = false - else - put_string(" ") - end - send_data(i, tag) - end - put_string(")") - end - - def send_date_data(date) put_string Net::IMAP.encode_date(date) end - def send_time_data(time) put_string Net::IMAP.encode_time(time) end - - def send_symbol_data(symbol) - put_string("\\" + symbol.to_s) - end - - class RawData # :nodoc: - def send_data(imap, tag) - imap.__send__(:put_string, @data) - end - - def validate - end - - private - - def initialize(data) - @data = data - end - end - - class Atom # :nodoc: - def send_data(imap, tag) - imap.__send__(:put_string, @data) - end - - def validate - end - - private - - def initialize(data) - @data = data - end - end - - class QuotedString # :nodoc: - def send_data(imap, tag) - imap.__send__(:send_quoted_string, @data) - end - - def validate - end - - private - - def initialize(data) - @data = data - end - end - - class Literal # :nodoc: - def send_data(imap, tag) - imap.__send__(:send_literal, @data, tag) - end - - def validate - end - - private - - def initialize(data) - @data = data - end - end - - class MessageSet # :nodoc: - def send_data(imap, tag) - imap.__send__(:put_string, format_internal(@data)) - end - - def validate - validate_internal(@data) - end - - private - - def initialize(data) - @data = data - end - - def format_internal(data) - case data - when "*" - return data - when Integer - if data == -1 - return "*" - else - return data.to_s - end - when Range - return format_internal(data.first) + - ":" + format_internal(data.last) - when Array - return data.collect {|i| format_internal(i)}.join(",") - when ThreadMember - return data.seqno.to_s + - ":" + data.children.collect {|i| format_internal(i).join(",")} - end - end - - def validate_internal(data) - case data - when "*" - when Integer - NumValidator.ensure_nz_number(data) - when Range - when Array - data.each do |i| - validate_internal(i) - end - when ThreadMember - data.children.each do |i| - validate_internal(i) - end - else - raise DataFormatError, data.inspect - end - end - end - - class ClientID # :nodoc: - - def send_data(imap, tag) - imap.__send__(:send_data, format_internal(@data), tag) - end - - def validate - validate_internal(@data) - end - - private - - def initialize(data) - @data = data - end - - def validate_internal(client_id) - client_id.to_h.each do |k,v| - unless StringFormatter.valid_string?(k) - raise DataFormatError, client_id.inspect - end - end - rescue NoMethodError, TypeError # to_h failed - raise DataFormatError, client_id.inspect - end - - def format_internal(client_id) - return nil if client_id.nil? - client_id.to_h.flat_map {|k,v| - [StringFormatter.string(k), StringFormatter.nstring(v)] - } - end - - end - - module StringFormatter - - LITERAL_REGEX = /[\x80-\xff\r\n]/n - - module_function - - # Allows symbols in addition to strings - def valid_string?(str) - str.is_a?(Symbol) || str.respond_to?(:to_str) - end - - # Allows nil, symbols, and strings - def valid_nstring?(str) - str.nil? || valid_string?(str) - end - - # coerces using +to_s+ - def string(str) - str = str.to_s - if str =~ LITERAL_REGEX - Literal.new(str) - else - QuotedString.new(str) - end - end - - # coerces non-nil using +to_s+ - def nstring(str) - str.nil? ? nil : string(str) - end - - end - - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_accessors.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_accessors.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_accessors.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_accessors.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,75 +0,0 @@ -# frozen_string_literal: true - -require "forwardable" - -module Net - class IMAP - class Config - # >>> - # *NOTE:* This module is an internal implementation detail, with no - # guarantee of backward compatibility. - # - # +attr_accessor+ values are stored in a struct rather than ivars, making - # it simpler to ensure that all config objects share a single object - # shape. This also simplifies iteration over all defined attributes. - module AttrAccessors - module Macros # :nodoc: internal API - def attr_accessor(name) AttrAccessors.attr_accessor(name) end - end - private_constant :Macros - - def self.included(mod) - mod.extend Macros - end - private_class_method :included - - extend Forwardable - - def self.attr_accessor(name) # :nodoc: internal API - name = name.to_sym - def_delegators :data, name, :"#{name}=" - end - - def self.attributes - instance_methods.grep(/=\z/).map { _1.to_s.delete_suffix("=").to_sym } - end - private_class_method :attributes - - def self.struct # :nodoc: internal API - unless defined?(self::Struct) - const_set :Struct, Struct.new(*attributes) - end - self::Struct - end - - def initialize # :notnew: - super() - @data = AttrAccessors.struct.new - end - - # Freezes the internal attributes struct, in addition to +self+. - def freeze - data.freeze - super - end - - protected - - attr_reader :data # :nodoc: internal API - - private - - def initialize_clone(other) - super - @data = other.data.clone - end - - def initialize_dup(other) - super - @data = other.data.dup - end - - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_inheritance.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_inheritance.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_inheritance.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_inheritance.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,90 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - class Config - # >>> - # *NOTE:* The public methods on this module are part of the stable - # public API of Net::IMAP::Config. But the module itself is an internal - # implementation detail, with no guarantee of backward compatibility. - # - # +attr_accessor+ methods will delegate to their #parent when the local - # value does not contain an override. Inheritance forms a singly linked - # list, so lookup will be O(n) on the number of ancestors. In - # practice, the ancestor chain is not expected to be long. Without - # customization, it is only three deep: - # >>> - # IMAP#config → Config.global → Config.default - # - # When creating a client with the +config+ keyword, for example to use - # the appropriate defaults for an application or a library while still - # relying on global for configuration of +debug+ or +logger+, most likely - # the ancestor chain is still only four deep: - # >>> - # IMAP#config → alternate defaults → Config.global → Config.default - module AttrInheritance - INHERITED = Module.new.freeze - private_constant :INHERITED - - module Macros # :nodoc: internal API - def attr_accessor(name) super; AttrInheritance.attr_accessor(name) end - end - private_constant :Macros - - def self.included(mod) - mod.extend Macros - end - private_class_method :included - - def self.attr_accessor(name) # :nodoc: internal API - module_eval <<~RUBY, __FILE__, __LINE__ + 1 - def #{name}; (val = super) == INHERITED ? parent&.#{name} : val end - RUBY - end - - # The parent Config object - attr_reader :parent - - def initialize(parent = nil) # :notnew: - super() - @parent = Config[parent] - reset - end - - # Creates a new config, which inherits from +self+. - def new(**attrs) self.class.new(self, **attrs) end - - # Returns +true+ if +attr+ is inherited from #parent and not overridden - # by this config. - def inherited?(attr) data[attr] == INHERITED end - - # :call-seq: - # reset -> self - # reset(attr) -> attribute value - # - # Resets an +attr+ to inherit from the #parent config. - # - # When +attr+ is nil or not given, all attributes are reset. - def reset(attr = nil) - if attr.nil? - data.members.each do |attr| data[attr] = INHERITED end - self - elsif inherited?(attr) - nil - else - old, data[attr] = data[attr], INHERITED - old - end - end - - private - - def initialize_copy(other) - super - @parent ||= other # only default has nil parent - end - - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_type_coercion.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_type_coercion.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_type_coercion.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/config/attr_type_coercion.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,61 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - class Config - # >>> - # *NOTE:* This module is an internal implementation detail, with no - # guarantee of backward compatibility. - # - # Adds a +type+ keyword parameter to +attr_accessor+, to enforce that - # config attributes have valid types, for example: boolean, numeric, - # enumeration, non-nullable, etc. - module AttrTypeCoercion - # :stopdoc: internal APIs only - - module Macros # :nodoc: internal API - def attr_accessor(attr, type: nil) - super(attr) - AttrTypeCoercion.attr_accessor(attr, type: type) - end - end - private_constant :Macros - - def self.included(mod) - mod.extend Macros - end - private_class_method :included - - def self.attr_accessor(attr, type: nil) - return unless type - if :boolean == type then boolean attr - elsif Integer == type then integer attr - elsif Array === type then enum attr, type - else raise ArgumentError, "unknown type coercion %p" % [type] - end - end - - def self.boolean(attr) - define_method :"#{attr}=" do |val| super !!val end - define_method :"#{attr}?" do send attr end - end - - def self.integer(attr) - define_method :"#{attr}=" do |val| super Integer val end - end - - def self.enum(attr, enum) - enum = enum.dup.freeze - expected = -"one of #{enum.map(&:inspect).join(", ")}" - define_method :"#{attr}=" do |val| - unless enum.include?(val) - raise ArgumentError, "expected %s, got %p" % [expected, val] - end - super val - end - end - - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/config.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/config.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/config.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/config.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,443 +0,0 @@ -# frozen_string_literal: true - -require_relative "config/attr_accessors" -require_relative "config/attr_inheritance" -require_relative "config/attr_type_coercion" - -module Net - class IMAP - - # Net::IMAP::Config (available since +v0.4.13+) stores - # configuration options for Net::IMAP clients. The global configuration can - # be seen at either Net::IMAP.config or Net::IMAP::Config.global, and the - # client-specific configuration can be seen at Net::IMAP#config. - # - # When creating a new client, all unhandled keyword arguments to - # Net::IMAP.new are delegated to Config.new. Every client has its own - # config. - # - # debug_client = Net::IMAP.new(hostname, debug: true) - # quiet_client = Net::IMAP.new(hostname, debug: false) - # debug_client.config.debug? # => true - # quiet_client.config.debug? # => false - # - # == Inheritance - # - # Configs have a parent[rdoc-ref:Config::AttrInheritance#parent] config, and - # any attributes which have not been set locally will inherit the parent's - # value. Every client creates its own specific config. By default, client - # configs inherit from Config.global. - # - # plain_client = Net::IMAP.new(hostname) - # debug_client = Net::IMAP.new(hostname, debug: true) - # quiet_client = Net::IMAP.new(hostname, debug: false) - # - # plain_client.config.inherited?(:debug) # => true - # debug_client.config.inherited?(:debug) # => false - # quiet_client.config.inherited?(:debug) # => false - # - # plain_client.config.debug? # => false - # debug_client.config.debug? # => true - # quiet_client.config.debug? # => false - # - # # Net::IMAP.debug is delegated to Net::IMAP::Config.global.debug - # Net::IMAP.debug = true - # plain_client.config.debug? # => true - # debug_client.config.debug? # => true - # quiet_client.config.debug? # => false - # - # Net::IMAP.debug = false - # plain_client.config.debug = true - # plain_client.config.inherited?(:debug) # => false - # plain_client.config.debug? # => true - # plain_client.config.reset(:debug) - # plain_client.config.inherited?(:debug) # => true - # plain_client.config.debug? # => false - # - # == Versioned defaults - # - # The effective default configuration for a specific +x.y+ version of - # +net-imap+ can be loaded with the +config+ keyword argument to - # Net::IMAP.new. Requesting default configurations for previous versions - # enables extra backward compatibility with those versions: - # - # client = Net::IMAP.new(hostname, config: 0.3) - # client.config.sasl_ir # => false - # client.config.responses_without_block # => :silence_deprecation_warning - # - # client = Net::IMAP.new(hostname, config: 0.4) - # client.config.sasl_ir # => true - # client.config.responses_without_block # => :silence_deprecation_warning - # - # client = Net::IMAP.new(hostname, config: 0.5) - # client.config.sasl_ir # => true - # client.config.responses_without_block # => :warn - # - # client = Net::IMAP.new(hostname, config: :future) - # client.config.sasl_ir # => true - # client.config.responses_without_block # => :raise - # - # The versioned default configs inherit certain specific config options from - # Config.global, for example #debug: - # - # client = Net::IMAP.new(hostname, config: 0.4) - # Net::IMAP.debug = false - # client.config.debug? # => false - # - # Net::IMAP.debug = true - # client.config.debug? # => true - # - # Use #load_defaults to globally behave like a specific version: - # client = Net::IMAP.new(hostname) - # client.config.sasl_ir # => true - # Net::IMAP.config.load_defaults 0.3 - # client.config.sasl_ir # => false - # - # === Named defaults - # In addition to +x.y+ version numbers, the following aliases are supported: - # - # [+:default+] - # An alias for +:current+. - # - # >>> - # *NOTE*: This is _not_ the same as Config.default. It inherits some - # attributes from Config.global, for example: #debug. - # [+:current+] - # An alias for the current +x.y+ version's defaults. - # [+:next+] - # The _planned_ config for the next +x.y+ version. - # [+:future+] - # The _planned_ eventual config for some future +x.y+ version. - # - # For example, to raise exceptions for all current deprecations: - # client = Net::IMAP.new(hostname, config: :future) - # client.responses # raises an ArgumentError - # - # == Thread Safety - # - # *NOTE:* Updates to config objects are not synchronized for thread-safety. - # - class Config - # Array of attribute names that are _not_ loaded by #load_defaults. - DEFAULT_TO_INHERIT = %i[debug].freeze - private_constant :DEFAULT_TO_INHERIT - - # The default config, which is hardcoded and frozen. - def self.default; @default end - - # The global config object. Also available from Net::IMAP.config. - def self.global; @global if defined?(@global) end - - # A hash of hard-coded configurations, indexed by version number or name. - def self.version_defaults; @version_defaults end - @version_defaults = {} - - # :call-seq: - # Net::IMAP::Config[number] -> versioned config - # Net::IMAP::Config[symbol] -> named config - # Net::IMAP::Config[hash] -> new frozen config - # Net::IMAP::Config[config] -> same config - # - # Given a version number, returns the default configuration for the target - # version. See Config@Versioned+defaults. - # - # Given a version name, returns the default configuration for the target - # version. See Config@Named+defaults. - # - # Given a Hash, creates a new _frozen_ config which inherits from - # Config.global. Use Config.new for an unfrozen config. - # - # Given a config, returns that same config. - def self.[](config) - if config.is_a?(Config) then config - elsif config.nil? && global.nil? then nil - elsif config.respond_to?(:to_hash) then new(global, **config).freeze - else - version_defaults.fetch(config) do - case config - when Numeric - raise RangeError, "unknown config version: %p" % [config] - when Symbol - raise KeyError, "unknown config name: %p" % [config] - else - raise TypeError, "no implicit conversion of %s to %s" % [ - config.class, Config - ] - end - end - end - end - - include AttrAccessors - include AttrInheritance - include AttrTypeCoercion - - # The debug mode (boolean). The default value is +false+. - # - # When #debug is +true+: - # * Data sent to and received from the server will be logged. - # * ResponseParser will print warnings with extra detail for parse - # errors. _This may include recoverable errors._ - # * ResponseParser makes extra assertions. - # - # *NOTE:* Versioned default configs inherit #debug from Config.global, and - # #load_defaults will not override #debug. - attr_accessor :debug, type: :boolean - - # method: debug? - # :call-seq: debug? -> boolean - # - # Alias for #debug - - # Seconds to wait until a connection is opened. - # - # If the IMAP object cannot open a connection within this time, - # it raises a Net::OpenTimeout exception. - # - # See Net::IMAP.new. - # - # The default value is +30+ seconds. - attr_accessor :open_timeout, type: Integer - - # Seconds to wait until an IDLE response is received, after - # the client asks to leave the IDLE state. - # - # See Net::IMAP#idle and Net::IMAP#idle_done. - # - # The default value is +5+ seconds. - attr_accessor :idle_response_timeout, type: Integer - - # Whether to use the +SASL-IR+ extension when the server and \SASL - # mechanism both support it. Can be overridden by the +sasl_ir+ keyword - # parameter to Net::IMAP#authenticate. - # - # (Support for +SASL-IR+ was added in +v0.4.0+.) - # - # ==== Valid options - # - # [+false+ (original behavior, before support was added)] - # Do not use +SASL-IR+, even when it is supported by the server and the - # mechanism. - # - # [+true+ (default since +v0.4+)] - # Use +SASL-IR+ when it is supported by the server and the mechanism. - attr_accessor :sasl_ir, type: :boolean - - - # Controls the behavior of Net::IMAP#responses when called without any - # arguments (+type+ or +block+). - # - # ==== Valid options - # - # [+:silence_deprecation_warning+ (original behavior)] - # Returns the mutable responses hash (without any warnings). - # This is not thread-safe. - # - # [+:warn+ (default since +v0.5+)] - # Prints a warning and returns the mutable responses hash. - # This is not thread-safe. - # - # [+:frozen_dup+ (planned default for +v0.6+)] - # Returns a frozen copy of the unhandled responses hash, with frozen - # array values. - # - # Note that calling IMAP#responses with a +type+ and without a block is - # not configurable and always behaves like +:frozen_dup+. - # - # (+:frozen_dup+ config option was added in +v0.4.17+) - # - # [+:raise+] - # Raise an ArgumentError with the deprecation warning. - # - # Note: #responses_without_args is an alias for #responses_without_block. - attr_accessor :responses_without_block, type: [ - :silence_deprecation_warning, :warn, :frozen_dup, :raise, - ] - - alias responses_without_args responses_without_block # :nodoc: - alias responses_without_args= responses_without_block= # :nodoc: - - ## - # :attr_accessor: responses_without_args - # - # Alias for responses_without_block - - # Whether ResponseParser should use the deprecated UIDPlusData or - # CopyUIDData for +COPYUID+ response codes, and UIDPlusData or - # AppendUIDData for +APPENDUID+ response codes. - # - # UIDPlusData stores its data in arrays of numbers, which is vulnerable to - # a memory exhaustion denial of service attack from an untrusted or - # compromised server. Set this option to +false+ to completely block this - # vulnerability. Otherwise, parser_max_deprecated_uidplus_data_size - # mitigates this vulnerability. - # - # AppendUIDData and CopyUIDData are _mostly_ backward-compatible with - # UIDPlusData. Most applications should be able to upgrade with little - # or no changes. - # - # (Parser support for +UIDPLUS+ added in +v0.3.2+.) - # - # (Config option added in +v0.4.19+ and +v0.5.6+.) - # - # UIDPlusData will be removed in +v0.6+ and this config setting will - # be ignored. - # - # ==== Valid options - # - # [+true+ (original default)] - # ResponseParser only uses UIDPlusData. - # - # [+:up_to_max_size+ (default since +v0.5.6+)] - # ResponseParser uses UIDPlusData when the +uid-set+ size is below - # parser_max_deprecated_uidplus_data_size. Above that size, - # ResponseParser uses AppendUIDData or CopyUIDData. - # - # [+false+ (planned default for +v0.6+)] - # ResponseParser _only_ uses AppendUIDData and CopyUIDData. - attr_accessor :parser_use_deprecated_uidplus_data, type: [ - true, :up_to_max_size, false - ] - - # The maximum +uid-set+ size that ResponseParser will parse into - # deprecated UIDPlusData. This limit only applies when - # parser_use_deprecated_uidplus_data is not +false+. - # - # (Parser support for +UIDPLUS+ added in +v0.3.2+.) - # - # Support for limiting UIDPlusData to a maximum size was added in - # +v0.3.8+, +v0.4.19+, and +v0.5.6+. - # - # UIDPlusData will be removed in +v0.6+. - # - # ==== Versioned Defaults - # - # Because this limit guards against a remote server causing catastrophic - # memory exhaustion, the versioned default (used by #load_defaults) also - # applies to versions without the feature. - # - # * +0.3+ and prior: 10,000 - # * +0.4+: 1,000 - # * +0.5+: 100 - # * +0.6+: 0 - # - attr_accessor :parser_max_deprecated_uidplus_data_size, type: Integer - - # Creates a new config object and initialize its attribute with +attrs+. - # - # If +parent+ is not given, the global config is used by default. - # - # If a block is given, the new config object is yielded to it. - def initialize(parent = Config.global, **attrs) - super(parent) - update(**attrs) - yield self if block_given? - end - - # :call-seq: update(**attrs) -> self - # - # Assigns all of the provided +attrs+ to this config, and returns +self+. - # - # An ArgumentError is raised unless every key in +attrs+ matches an - # assignment method on Config. - # - # >>> - # *NOTE:* #update is not atomic. If an exception is raised due to an - # invalid attribute value, +attrs+ may be partially applied. - def update(**attrs) - unless (bad = attrs.keys.reject { respond_to?(:"#{_1}=") }).empty? - raise ArgumentError, "invalid config options: #{bad.join(", ")}" - end - attrs.each do send(:"#{_1}=", _2) end - self - end - - # :call-seq: - # with(**attrs) -> config - # with(**attrs) {|config| } -> result - # - # Without a block, returns a new config which inherits from self. With a - # block, yields the new config and returns the block's result. - # - # If no keyword arguments are given, an ArgumentError will be raised. - # - # If +self+ is frozen, the copy will also be frozen. - def with(**attrs) - attrs.empty? and - raise ArgumentError, "expected keyword arguments, none given" - copy = new(**attrs) - copy.freeze if frozen? - block_given? ? yield(copy) : copy - end - - # :call-seq: load_defaults(version) -> self - # - # Resets the current config to behave like the versioned default - # configuration for +version+. #parent will not be changed. - # - # Some config attributes default to inheriting from their #parent (which - # is usually Config.global) and are left unchanged, for example: #debug. - # - # See Config@Versioned+defaults and Config@Named+defaults. - def load_defaults(version) - [Numeric, Symbol, String].any? { _1 === version } or - raise ArgumentError, "expected number or symbol, got %p" % [version] - update(**Config[version].defaults_hash) - end - - # :call-seq: to_h -> hash - # - # Returns all config attributes in a hash. - def to_h; data.members.to_h { [_1, send(_1)] } end - - protected - - def defaults_hash - to_h.reject {|k,v| DEFAULT_TO_INHERIT.include?(k) } - end - - @default = new( - debug: false, - open_timeout: 30, - idle_response_timeout: 5, - sasl_ir: true, - responses_without_block: :silence_deprecation_warning, - parser_use_deprecated_uidplus_data: true, - parser_max_deprecated_uidplus_data_size: 1000, - ).freeze - - @global = default.new - - version_defaults[0.4] = Config[default.send(:defaults_hash)] - - version_defaults[0] = Config[0.4].dup.update( - sasl_ir: false, - parser_use_deprecated_uidplus_data: true, - parser_max_deprecated_uidplus_data_size: 10_000, - ).freeze - version_defaults[0.0] = Config[0] - version_defaults[0.1] = Config[0] - version_defaults[0.2] = Config[0] - version_defaults[0.3] = Config[0] - - version_defaults[0.5] = Config[0.4].dup.update( - responses_without_block: :warn, - parser_use_deprecated_uidplus_data: :up_to_max_size, - parser_max_deprecated_uidplus_data_size: 100, - ).freeze - - version_defaults[:default] = Config[0.4] - version_defaults[:current] = Config[0.4] - version_defaults[:next] = Config[0.5] - - version_defaults[0.6] = Config[0.5].dup.update( - responses_without_block: :frozen_dup, - parser_use_deprecated_uidplus_data: false, - parser_max_deprecated_uidplus_data_size: 0, - ).freeze - version_defaults[:future] = Config[0.6] - - version_defaults.freeze - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/data_encoding.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/data_encoding.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/data_encoding.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/data_encoding.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,214 +0,0 @@ -# frozen_string_literal: true - -require "date" -require "time" - -require_relative "errors" - -module Net - class IMAP < Protocol - - # strftime/strptime format for an IMAP4 +date+, excluding optional dquotes. - # Use via the encode_date and decode_date methods. - # - # date = date-text / DQUOTE date-text DQUOTE - # date-text = date-day "-" date-month "-" date-year - # - # date-day = 1*2DIGIT - # ; Day of month - # date-month = "Jan" / "Feb" / "Mar" / "Apr" / "May" / "Jun" / - # "Jul" / "Aug" / "Sep" / "Oct" / "Nov" / "Dec" - # date-year = 4DIGIT - STRFDATE = "%d-%b-%Y" - - # strftime/strptime format for an IMAP4 +date-time+, including dquotes. - # See the encode_datetime and decode_datetime methods. - # - # date-time = DQUOTE date-day-fixed "-" date-month "-" date-year - # SP time SP zone DQUOTE - # - # date-day-fixed = (SP DIGIT) / 2DIGIT - # ; Fixed-format version of date-day - # date-month = "Jan" / "Feb" / "Mar" / "Apr" / "May" / "Jun" / - # "Jul" / "Aug" / "Sep" / "Oct" / "Nov" / "Dec" - # date-year = 4DIGIT - # time = 2DIGIT ":" 2DIGIT ":" 2DIGIT - # ; Hours minutes seconds - # zone = ("+" / "-") 4DIGIT - # ; Signed four-digit value of hhmm representing - # ; hours and minutes east of Greenwich (that is, - # ; the amount that the given time differs from - # ; Universal Time). Subtracting the timezone - # ; from the given time will give the UT form. - # ; The Universal Time zone is "+0000". - # - # Note that Time.strptime "%d" flexibly parses either space or zero - # padding. However, the DQUOTEs are *not* optional. - STRFTIME = '"%d-%b-%Y %H:%M:%S %z"' - - # Decode a string from modified UTF-7 format to UTF-8. - # - # UTF-7 is a 7-bit encoding of Unicode [UTF7]. IMAP uses a - # slightly modified version of this to encode mailbox names - # containing non-ASCII characters; see [IMAP] section 5.1.3. - # - # Net::IMAP does _not_ automatically encode and decode - # mailbox names to and from UTF-7. - def self.decode_utf7(s) - return s.gsub(/&([A-Za-z0-9+,]+)?-/n) { - if base64 = $1 - (base64.tr(",", "/") + "===").unpack1("m").encode(Encoding::UTF_8, Encoding::UTF_16BE) - else - "&" - end - } - end - - # Encode a string from UTF-8 format to modified UTF-7. - def self.encode_utf7(s) - return s.gsub(/(&)|[^\x20-\x7e]+/) { - if $1 - "&-" - else - base64 = [$&.encode(Encoding::UTF_16BE)].pack("m0") - "&" + base64.delete("=").tr("/", ",") + "-" - end - }.force_encoding("ASCII-8BIT") - end - - # Formats +time+ as an IMAP4 date. - def self.encode_date(date) - date.to_date.strftime STRFDATE - end - - # :call-seq: decode_date(string) -> Date - # - # Decodes +string+ as an IMAP formatted "date". - # - # Double quotes are optional. Day of month may be padded with zero or - # space. See STRFDATE. - def self.decode_date(string) - string = string.delete_prefix('"').delete_suffix('"') - Date.strptime(string, STRFDATE) - end - - # :call-seq: encode_datetime(time) -> string - # - # Formats +time+ as an IMAP4 date-time. - def self.encode_datetime(time) - time.to_datetime.strftime STRFTIME - end - - # :call-seq: decode_datetime(string) -> DateTime - # - # Decodes +string+ as an IMAP4 formatted "date-time". - # - # NOTE: Although double-quotes are not optional in the IMAP grammar, - # Net::IMAP currently parses "date-time" values as "quoted" strings and this - # removes the quotation marks. To be useful for strings which have already - # been parsed as a quoted string, this method makes double-quotes optional. - # - # See STRFTIME. - def self.decode_datetime(string) - unless string.start_with?(?") && string.end_with?(?") - string = '"%s"' % [string] - end - DateTime.strptime(string, STRFTIME) - end - - # :call-seq: decode_time(string) -> Time - # - # Decodes +string+ as an IMAP4 formatted "date-time". - # - # Same as +decode_datetime+, but returning a Time instead. - def self.decode_time(string) - unless string.start_with?(?") && string.end_with?(?") - string = '"%s"' % [string] - end - Time.strptime(string, STRFTIME) - end - - class << self - alias encode_time encode_datetime - alias format_date encode_date - alias format_time encode_time - alias parse_date decode_date - alias parse_datetime decode_datetime - alias parse_time decode_time - - # alias format_datetime encode_datetime # n.b: this is overridden below... - end - - # DEPRECATED:: The original version returned incorrectly formatted strings. - # Strings returned by encode_datetime or format_time use the - # correct IMAP4rev1 syntax for "date-time". - # - # This invalid format has been temporarily retained for backward - # compatibility. A future release will change this method to return the - # correct format. - def self.format_datetime(time) - warn("#{self}.format_datetime incorrectly formats IMAP date-time. " \ - "Convert to #{self}.encode_datetime or #{self}.format_time instead.", - uplevel: 1, category: :deprecated) - time.strftime("%d-%b-%Y %H:%M %z") - end - - # Common validators of number and nz_number types - module NumValidator # :nodoc - module_function - - # Check is passed argument valid 'number' in RFC 3501 terminology - def valid_number?(num) - # [RFC 3501] - # number = 1*DIGIT - # ; Unsigned 32-bit integer - # ; (0 <= n < 4,294,967,296) - num >= 0 && num < 4294967296 - end - - # Check is passed argument valid 'nz_number' in RFC 3501 terminology - def valid_nz_number?(num) - # [RFC 3501] - # nz-number = digit-nz *DIGIT - # ; Non-zero unsigned 32-bit integer - # ; (0 < n < 4,294,967,296) - num != 0 && valid_number?(num) - end - - # Check is passed argument valid 'mod_sequence_value' in RFC 4551 terminology - def valid_mod_sequence_value?(num) - # mod-sequence-value = 1*DIGIT - # ; Positive unsigned 64-bit integer - # ; (mod-sequence) - # ; (1 <= n < 18,446,744,073,709,551,615) - num >= 1 && num < 18446744073709551615 - end - - # Ensure argument is 'number' or raise DataFormatError - def ensure_number(num) - return if valid_number?(num) - - msg = "number must be unsigned 32-bit integer: #{num}" - raise DataFormatError, msg - end - - # Ensure argument is 'nz_number' or raise DataFormatError - def ensure_nz_number(num) - return if valid_nz_number?(num) - - msg = "nz_number must be non-zero unsigned 32-bit integer: #{num}" - raise DataFormatError, msg - end - - # Ensure argument is 'mod_sequence_value' or raise DataFormatError - def ensure_mod_sequence_value(num) - return if valid_mod_sequence_value?(num) - - msg = "mod_sequence_value must be unsigned 64-bit integer: #{num}" - raise DataFormatError, msg - end - - end - - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/deprecated_client_options.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/deprecated_client_options.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/deprecated_client_options.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/deprecated_client_options.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,139 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP < Protocol - - # This module handles deprecated arguments to various Net::IMAP methods. - module DeprecatedClientOptions - - # :call-seq: - # Net::IMAP.new(host, **options) # standard keyword options - # Net::IMAP.new(host, options) # obsolete hash options - # Net::IMAP.new(host, port) # obsolete port argument - # Net::IMAP.new(host, port, usessl, certs = nil, verify = true) # deprecated SSL arguments - # - # Translates Net::IMAP.new arguments for backward compatibility. - # - # ==== Obsolete arguments - # - # Use of obsolete arguments does not print a warning. Obsolete arguments - # will be deprecated by a future release. - # - # If a second positional argument is given and it is a hash (or is - # convertible via +#to_hash+), it is converted to keyword arguments. - # - # # Obsolete: - # Net::IMAP.new("imap.example.com", options_hash) - # # Use instead: - # Net::IMAP.new("imap.example.com", **options_hash) - # - # If a second positional argument is given and it is not a hash, it is - # converted to the +port+ keyword argument. - # # Obsolete: - # Net::IMAP.new("imap.example.com", 114433) - # # Use instead: - # Net::IMAP.new("imap.example.com", port: 114433) - # - # ==== Deprecated arguments - # - # Using deprecated arguments prints a warning. Convert to keyword - # arguments to avoid the warning. Deprecated arguments will be removed in - # a future release. - # - # If +usessl+ is false, +certs+, and +verify+ are ignored. When it true, - # all three arguments are converted to the +ssl+ keyword argument. - # Without +certs+ or +verify+, it is converted to ssl: true. - # # DEPRECATED: - # Net::IMAP.new("imap.example.com", nil, true) # => prints a warning - # # Use instead: - # Net::IMAP.new("imap.example.com", ssl: true) - # - # When +certs+ is a path to a directory, it is converted to ca_path: - # certs. - # # DEPRECATED: - # Net::IMAP.new("imap.example.com", nil, true, "/path/to/certs") # => prints a warning - # # Use instead: - # Net::IMAP.new("imap.example.com", ssl: {ca_path: "/path/to/certs"}) - # - # When +certs+ is a path to a file, it is converted to ca_file: - # certs. - # # DEPRECATED: - # Net::IMAP.new("imap.example.com", nil, true, "/path/to/cert.pem") # => prints a warning - # # Use instead: - # Net::IMAP.new("imap.example.com", ssl: {ca_file: "/path/to/cert.pem"}) - # - # When +verify+ is +false+, it is converted to verify_mode: - # OpenSSL::SSL::VERIFY_NONE. - # # DEPRECATED: - # Net::IMAP.new("imap.example.com", nil, true, nil, false) # => prints a warning - # # Use instead: - # Net::IMAP.new("imap.example.com", ssl: {verify_mode: OpenSSL::SSL::VERIFY_NONE}) - # - def initialize(host, port_or_options = nil, *deprecated, **options) - if port_or_options.nil? && deprecated.empty? - super host, **options - elsif options.any? - # Net::IMAP.new(host, *__invalid__, **options) - raise ArgumentError, "Do not combine deprecated and keyword arguments" - elsif port_or_options.respond_to?(:to_hash) and deprecated.any? - # Net::IMAP.new(host, options, *__invalid__) - raise ArgumentError, "Do not use deprecated SSL params with options hash" - elsif port_or_options.respond_to?(:to_hash) - super host, **Hash.try_convert(port_or_options) - elsif deprecated.empty? - super host, port: port_or_options - elsif deprecated.shift - warn "DEPRECATED: Call Net::IMAP.new with keyword options", uplevel: 1 - super host, port: port_or_options, ssl: create_ssl_params(*deprecated) - else - warn "DEPRECATED: Call Net::IMAP.new with keyword options", uplevel: 1 - super host, port: port_or_options, ssl: false - end - end - - # :call-seq: - # starttls(**options) # standard - # starttls(options = {}) # obsolete - # starttls(certs = nil, verify = true) # deprecated - # - # Translates Net::IMAP#starttls arguments for backward compatibility. - # - # Support for +certs+ and +verify+ will be dropped in a future release. - # - # See ::new for interpretation of +certs+ and +verify+. - def starttls(*deprecated, **options) - if deprecated.empty? - super(**options) - elsif options.any? - # starttls(*__invalid__, **options) - raise ArgumentError, "Do not combine deprecated and keyword options" - elsif deprecated.first.respond_to?(:to_hash) && deprecated.length > 1 - # starttls(*__invalid__, **options) - raise ArgumentError, "Do not use deprecated verify param with options hash" - elsif deprecated.first.respond_to?(:to_hash) - super(**Hash.try_convert(deprecated.first)) - else - warn "DEPRECATED: Call Net::IMAP#starttls with keyword options", uplevel: 1 - super(**create_ssl_params(*deprecated)) - end - end - - private - - def create_ssl_params(certs = nil, verify = true) - params = {} - if certs - if File.file?(certs) - params[:ca_file] = certs - elsif File.directory?(certs) - params[:ca_path] = certs - end - end - params[:verify_mode] = - verify ? OpenSSL::SSL::VERIFY_PEER : OpenSSL::SSL::VERIFY_NONE - params - end - - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/errors.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/errors.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/errors.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/errors.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,79 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP < Protocol - - # Superclass of IMAP errors. - class Error < StandardError - end - - # Error raised when data is in the incorrect format. - class DataFormatError < Error - end - - # Error raised when a response from the server is non-parsable. - class ResponseParseError < Error - end - - # Superclass of all errors used to encapsulate "fail" responses - # from the server. - class ResponseError < Error - - # The response that caused this error - attr_accessor :response - - def initialize(response) - @response = response - - super @response.data.text - end - - end - - # Error raised upon a "NO" response from the server, indicating - # that the client command could not be completed successfully. - class NoResponseError < ResponseError - end - - # Error raised upon a "BAD" response from the server, indicating - # that the client command violated the IMAP protocol, or an internal - # server failure has occurred. - class BadResponseError < ResponseError - end - - # Error raised upon a "BYE" response from the server, indicating - # that the client is not being allowed to login, or has been timed - # out due to inactivity. - class ByeResponseError < ResponseError - end - - # Error raised when the server sends an invalid response. - # - # This is different from UnknownResponseError: the response has been - # rejected. Although it may be parsable, the server is forbidden from - # sending it in the current context. The client should automatically - # disconnect, abruptly (without logout). - # - # Note that InvalidResponseError does not inherit from ResponseError: it - # can be raised before the response is fully parsed. A related - # ResponseParseError or ResponseError may be the #cause. - class InvalidResponseError < Error - end - - # Error raised upon an unknown response from the server. - # - # This is different from InvalidResponseError: the response may be a - # valid extension response and the server may be allowed to send it in - # this context, but Net::IMAP either does not know how to parse it or - # how to handle it. This could result from enabling unknown or - # unhandled extensions. The connection may still be usable, - # but—depending on context—it may be prudent to disconnect. - class UnknownResponseError < ResponseError - end - - RESPONSE_ERRORS = Hash.new(ResponseError) # :nodoc: - RESPONSE_ERRORS["NO"] = NoResponseError - RESPONSE_ERRORS["BAD"] = BadResponseError - - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/fetch_data.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/fetch_data.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/fetch_data.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/fetch_data.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,518 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP < Protocol - - # Net::IMAP::FetchData represents the contents of a FETCH response. - # Net::IMAP#fetch and Net::IMAP#uid_fetch both return an array of - # FetchData objects. - # - # === Fetch attributes - # - # See {[IMAP4rev1 §7.4.2]}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2] - # and {[IMAP4rev2 §7.5.2]}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2] - # for a full description of the standard fetch response data items, and - # Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. - # - # ==== Static fetch data items - # - # Most message attributes are static, and must never change for a given - # (server, account, mailbox, UIDVALIDITY, UID) tuple. - # - # The static fetch data items defined by both - # IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] and - # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] are: - # - # * "UID" --- See #uid. - # * "BODY" --- See #body. - # * "BODY[#{section_spec}]", - # "BODY[#{section_spec}]<#{offset}>" --- See #message, - # #part, #header, #header_fields, #header_fields_not, #mime, and #text. - # * "BODYSTRUCTURE" --- See #bodystructure. - # * "ENVELOPE" --- See #envelope. - # * "INTERNALDATE" --- See #internaldate. - # * "RFC822.SIZE" --- See #rfc822_size. - # - # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] adds the - # additional fetch items from the +BINARY+ extension - # {[RFC3516]}[https://www.rfc-editor.org/rfc/rfc3516.html]: - # - # * "BINARY[#{part}]", - # "BINARY[#{part}]<#{offset}>" -- See #binary. - # * "BINARY.SIZE[#{part}]" -- See #binary_size. - # - # Several static message attributes in - # IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] are obsolete and - # been removed from - # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html]: - # - # * "RFC822" --- See #rfc822 or replace with - # "BODY[]" and #message. - # * "RFC822.HEADER" --- See #rfc822_header or replace with - # "BODY[HEADER]" and #header. - # * "RFC822.TEXT" --- See #rfc822_text or replace with - # "BODY[TEXT]" and #text. - # - # Net::IMAP supports static attributes defined by the following extensions: - # * +OBJECTID+ {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html] - # * "EMAILID" --- See #emailid. - # * "THREADID" --- See #threadid. - # - # * +X-GM-EXT-1+ {[non-standard Gmail - # extension]}[https://developers.google.com/gmail/imap/imap-extensions] - # * "X-GM-MSGID" --- unique message ID. Access via #attr. - # * "X-GM-THRID" --- Thread ID. Access via #attr. - # - # [Note:] - # >>> - # Additional static fields are defined in other \IMAP extensions, but - # Net::IMAP can't parse them yet. - # - # ==== Dynamic message attributes - # - # Some message attributes can be dynamically changed, for example using the - # {STORE command}[rdoc-ref:Net::IMAP#store]. - # - # The only dynamic message attribute defined by - # IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] and - # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] is: - # - # * "FLAGS" --- See #flags. - # - # Net::IMAP supports dynamic attributes defined by the following extensions: - # - # * +CONDSTORE+ {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]: - # * "MODSEQ" --- See #modseq. - # * +X-GM-EXT-1+ {[non-standard Gmail - # extension]}[https://developers.google.com/gmail/imap/imap-extensions] - # * "X-GM-LABELS" --- Gmail labels. Access via #attr. - # - # [Note:] - # >>> - # Additional dynamic fields are defined in other \IMAP extensions, but - # Net::IMAP can't parse them yet. - # - # === Implicitly setting \Seen and using +PEEK+ - # - # Unless the mailbox is has been opened as read-only, fetching - # BODY[#{section}] or BINARY[#{section}] - # will implicitly set the \Seen flag. To avoid this, fetch using - # BODY.PEEK[#{section}] or BINARY.PEEK[#{section}] - # instead. - # - # Note that the data will always be _returned_ without ".PEEK", in - # BODY[#{specifier}] or BINARY[#{section}]. - # - class FetchData < Struct.new(:seqno, :attr) - ## - # method: seqno - # :call-seq: seqno -> Integer - # - # The message sequence number. - # - # [Note] - # This is never the unique identifier (UID), not even for the - # Net::IMAP#uid_fetch result. The UID is available from #uid, if it was - # returned. - - ## - # method: attr - # :call-seq: attr -> hash - # - # Each key specifies a message attribute, and the value is the - # corresponding data item. Standard data items have corresponding - # accessor methods. The definitions of each attribute type is documented - # on its accessor. - # - # >>> - # *Note:* #seqno is not a message attribute. - - # :call-seq: attr_upcase -> hash - # - # A transformation of #attr, with all the keys converted to upper case. - # - # Header field names are case-preserved but not case-sensitive, so this is - # used by #header_fields and #header_fields_not. - def attr_upcase; attr.transform_keys(&:upcase) end - - # :call-seq: - # body -> body structure or nil - # - # Returns an alternate form of #bodystructure, without any extension data. - # - # This is the same as getting the value for "BODY" from #attr. - # - # [Note] - # Use #message, #part, #header, #header_fields, #header_fields_not, - # #text, or #mime to retrieve BODY[#{section_spec}] attributes. - def body; attr["BODY"] end - - # :call-seq: - # message(offset: bytes) -> string or nil - # - # The RFC5322[https://www.rfc-editor.org/rfc/rfc5322.html] - # expression of the entire message, as a string. - # - # See #part for a description of +offset+. - # - # RFC5322 messages can be parsed using the "mail" gem. - # - # This is the same as getting the value for "BODY[]" or - # "BODY[]<#{offset}>" from #attr. - # - # See also: #header, #text, and #mime. - def message(offset: nil) attr[body_section_attr(offset: offset)] end - - # :call-seq: - # part(*part_nums, offset: bytes) -> string or nil - # - # The string representation of a particular MIME part. - # - # +part_nums+ forms a path of MIME part numbers, counting up from +1+, - # which may specify an arbitrarily nested part, similarly to Array#dig. - # Messages that don't use MIME, or MIME messages that are not multipart - # and don't hold an encapsulated message, only have part +1+. - # - # If a zero-based +offset+ is given, the returned string is a substring of - # the entire contents, starting at that origin octet. This means that - # BODY[]<0> MAY be truncated, but BODY[] is never - # truncated. - # - # This is the same as getting the value of - # "BODY[#{part_nums.join(".")}]" or - # "BODY[#{part_nums.join(".")}]<#{offset}>" from #attr. - # - # See also: #message, #header, #text, and #mime. - def part(index, *subparts, offset: nil) - attr[body_section_attr([index, *subparts], offset: offset)] - end - - # :call-seq: - # header(*part_nums, offset: nil) -> string or nil - # header(*part_nums, fields: names, offset: nil) -> string or nil - # header(*part_nums, except: names, offset: nil) -> string or nil - # - # The {[RFC5322]}[https://www.rfc-editor.org/rfc/rfc5322.html] header of a - # message or of an encapsulated - # {[MIME-IMT]}[https://www.rfc-editor.org/rfc/rfc2046.html] - # MESSAGE/RFC822 or MESSAGE/GLOBAL message. - # - # Headers can be parsed using the "mail" gem. - # - # See #part for a description of +part_nums+ and +offset+. - # - # ==== Without +fields+ or +except+ - # This is the same as getting the value from #attr for one of: - # * BODY[HEADER] - # * BODY[HEADER]<#{offset}> - # * BODY[#{part_nums.join "."}.HEADER]" - # * BODY[#{part_nums.join "."}.HEADER]<#{offset}>" - # - # ==== With +fields+ - # When +fields+ is sent, returns a subset of the header which contains - # only the header fields that match one of the names in the list. - # - # This is the same as getting the value from #attr_upcase for one of: - # * BODY[HEADER.FIELDS (#{names.join " "})] - # * BODY[HEADER.FIELDS (#{names.join " "})]<#{offset}> - # * BODY[#{part_nums.join "."}.HEADER.FIELDS (#{names.join " "})] - # * BODY[#{part_nums.join "."}.HEADER.FIELDS (#{names.join " "})]<#{offset}> - # - # See also: #header_fields - # - # ==== With +except+ - # When +except+ is sent, returns a subset of the header which contains - # only the header fields that do _not_ match one of the names in the list. - # - # This is the same as getting the value from #attr_upcase for one of: - # * BODY[HEADER.FIELDS.NOT (#{names.join " "})] - # * BODY[HEADER.FIELDS.NOT (#{names.join " "})]<#{offset}> - # * BODY[#{part_nums.join "."}.HEADER.FIELDS.NOT (#{names.join " "})] - # * BODY[#{part_nums.join "."}.HEADER.FIELDS.NOT (#{names.join " "})]<#{offset}> - # - # See also: #header_fields_not - def header(*part_nums, fields: nil, except: nil, offset: nil) - fields && except and - raise ArgumentError, "conflicting 'fields' and 'except' arguments" - if fields - text = "HEADER.FIELDS (%s)" % [fields.join(" ").upcase] - attr_upcase[body_section_attr(part_nums, text, offset: offset)] - elsif except - text = "HEADER.FIELDS.NOT (%s)" % [except.join(" ").upcase] - attr_upcase[body_section_attr(part_nums, text, offset: offset)] - else - attr[body_section_attr(part_nums, "HEADER", offset: offset)] - end - end - - # :call-seq: - # header_fields(*names, part: [], offset: nil) -> string or nil - # - # The result from #header when called with fields: names. - def header_fields(first, *rest, part: [], offset: nil) - header(*part, fields: [first, *rest], offset: offset) - end - - # :call-seq: - # header_fields_not(*names, part: [], offset: nil) -> string or nil - # - # The result from #header when called with except: names. - def header_fields_not(first, *rest, part: [], offset: nil) - header(*part, except: [first, *rest], offset: offset) - end - - # :call-seq: - # mime(*part_nums) -> string or nil - # mime(*part_nums, offset: bytes) -> string or nil - # - # The {[MIME-IMB]}[https://www.rfc-editor.org/rfc/rfc2045.html] header for - # a message part, if it was fetched. - # - # See #part for a description of +part_nums+ and +offset+. - # - # This is the same as getting the value for - # "BODY[#{part_nums}.MIME]" or - # "BODY[#{part_nums}.MIME]<#{offset}>" from #attr. - # - # See also: #message, #header, and #text. - def mime(part, *subparts, offset: nil) - attr[body_section_attr([part, *subparts], "MIME", offset: offset)] - end - - # :call-seq: - # text(*part_nums) -> string or nil - # text(*part_nums, offset: bytes) -> string or nil - # - # The text body of a message or a message part, if it was fetched, - # omitting the {[RFC5322]}[https://www.rfc-editor.org/rfc/rfc5322.html] - # header. - # - # See #part for a description of +part_nums+ and +offset+. - # - # This is the same as getting the value from #attr for one of: - # * "BODY[TEXT]", - # * "BODY[TEXT]<#{offset}>", - # * "BODY[#{section}.TEXT]", or - # * "BODY[#{section}.TEXT]<#{offset}>". - # - # See also: #message, #header, and #mime. - def text(*part, offset: nil) - attr[body_section_attr(part, "TEXT", offset: offset)] - end - - # :call-seq: - # bodystructure -> BodyStructure struct or nil - # - # A BodyStructure object that describes the message, if it was fetched. - # - # This is the same as getting the value for "BODYSTRUCTURE" from - # #attr. - def bodystructure; attr["BODYSTRUCTURE"] end - alias body_structure bodystructure - - # :call-seq: envelope -> Envelope or nil - # - # An Envelope object that describes the envelope structure of a message. - # See the documentation for Envelope for a description of the envelope - # structure attributes. - # - # This is the same as getting the value for "ENVELOPE" from - # #attr. - def envelope; attr["ENVELOPE"] end - - # :call-seq: flags -> array of Symbols and Strings - # - # A array of flags that are set for this message. System flags are - # symbols that have been capitalized by String#capitalize. Keyword flags - # are strings and their case is not changed. - # - # This is the same as getting the value for "FLAGS" from #attr. - # - # [Note] - # The +FLAGS+ field is dynamic, and can change for a uniquely identified - # message. - def flags; attr["FLAGS"] end - - # :call-seq: internaldate -> Time or nil - # - # The internal date and time of the message on the server. This is not - # the date and time in the [RFC5322[https://tools.ietf.org/html/rfc5322]] - # header, but rather a date and time which reflects when the message was - # received. - # - # This is similar to getting the value for "INTERNALDATE" from - # #attr. - # - # [Note] - # attr["INTERNALDATE"] returns a string, and this method - # returns a Time object. - def internaldate - attr["INTERNALDATE"]&.then { IMAP.decode_time _1 } - end - alias internal_date internaldate - - # :call-seq: rfc822 -> String - # - # Semantically equivalent to #message with no arguments. - # - # This is the same as getting the value for "RFC822" from #attr. - # - # [Note] - # +IMAP4rev2+ deprecates RFC822. - def rfc822; attr["RFC822"] end - - # :call-seq: rfc822_size -> Integer - # - # A number expressing the [RFC5322[https://tools.ietf.org/html/rfc5322]] - # size of the message. - # - # This is the same as getting the value for "RFC822.SIZE" from - # #attr. - # - # [Note] - # \IMAP was originally developed for the older - # RFC822[https://www.rfc-editor.org/rfc/rfc822.html] standard, and as a - # consequence several fetch items in \IMAP incorporate "RFC822" in their - # name. With the exception of +RFC822.SIZE+, there are more modern - # replacements; for example, the modern version of +RFC822.HEADER+ is - # BODY.PEEK[HEADER]. In all cases, "RFC822" should be - # interpreted as a reference to the updated - # RFC5322[https://www.rfc-editor.org/rfc/rfc5322.html] standard. - def rfc822_size; attr["RFC822.SIZE"] end - alias size rfc822_size - - # :call-seq: rfc822_header -> String - # - # Semantically equivalent to #header, with no arguments. - # - # This is the same as getting the value for "RFC822.HEADER" from #attr. - # - # [Note] - # +IMAP4rev2+ deprecates RFC822.HEADER. - def rfc822_header; attr["RFC822.HEADER"] end - - # :call-seq: rfc822_text -> String - # - # Semantically equivalent to #text, with no arguments. - # - # This is the same as getting the value for "RFC822.TEXT" from - # #attr. - # - # [Note] - # +IMAP4rev2+ deprecates RFC822.TEXT. - def rfc822_text; attr["RFC822.TEXT"] end - - # :call-seq: uid -> Integer - # - # A number expressing the unique identifier of the message. - # - # This is the same as getting the value for "UID" from #attr. - def uid; attr["UID"] end - - # :call-seq: - # binary(*part_nums, offset: nil) -> string or nil - # - # Returns the binary representation of a particular MIME part, which has - # already been decoded according to its Content-Transfer-Encoding. - # - # See #part for a description of +part_nums+ and +offset+. - # - # This is the same as getting the value of - # "BINARY[#{part_nums.join(".")}]" or - # "BINARY[#{part_nums.join(".")}]<#{offset}>" from #attr. - # - # The server must support either - # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] - # or the +BINARY+ extension - # {[RFC3516]}[https://www.rfc-editor.org/rfc/rfc3516.html]. - # - # See also: #binary_size, #mime - def binary(*part_nums, offset: nil) - attr[section_attr("BINARY", part_nums, offset: offset)] - end - - # :call-seq: - # binary_size(*part_nums) -> integer or nil - # - # Returns the decoded size of a particular MIME part (the size to expect - # in response to a BINARY fetch request). - # - # See #part for a description of +part_nums+. - # - # This is the same as getting the value of - # "BINARY.SIZE[#{part_nums.join(".")}]" from #attr. - # - # The server must support either - # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] - # or the +BINARY+ extension - # {[RFC3516]}[https://www.rfc-editor.org/rfc/rfc3516.html]. - # - # See also: #binary, #mime - def binary_size(*part_nums) - attr[section_attr("BINARY.SIZE", part_nums)] - end - - # :call-seq: modseq -> Integer - # - # The modification sequence number associated with this IMAP message. - # - # This is the same as getting the value for "MODSEQ" from #attr. - # - # The server must support the +CONDSTORE+ extension - # {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. - # - # [Note] - # The +MODSEQ+ field is dynamic, and can change for a uniquely - # identified message. - def modseq; attr["MODSEQ"] end - - # :call-seq: emailid -> string or nil - # - # An ObjectID that uniquely identifies the immutable content of a single - # message. - # - # The server must return the same +EMAILID+ for both the source and - # destination messages after a COPY or MOVE command. However, it is - # possible for different messages with the same EMAILID to have different - # mutable attributes, such as flags. - # - # This is the same as getting the value for "EMAILID" from - # #attr. - # - # The server must support the +OBJECTID+ extension - # {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. - def emailid; attr["EMAILID"] end - - # :call-seq: threadid -> string or nil - # - # An ObjectID that uniquely identifies a set of messages that the server - # believes should be grouped together. - # - # It is generally based on some combination of References, In-Reply-To, - # and Subject, but the exact implementation is left up to the server - # implementation. The server should return the same thread identifier for - # related messages, even if they are in different mailboxes. - # - # This is the same as getting the value for "THREADID" from - # #attr. - # - # The server must support the +OBJECTID+ extension - # {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. - def threadid; attr["THREADID"] end - - private - - def body_section_attr(...) section_attr("BODY", ...) end - - def section_attr(attr, part = [], text = nil, offset: nil) - spec = Array(part).flatten.map { Integer(_1) } - spec << text if text - spec = spec.join(".") - if offset then "%s[%s]<%d>" % [attr, spec, Integer(offset)] - else "%s[%s]" % [attr, spec] - end - end - - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/flags.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/flags.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/flags.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/flags.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,262 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP < Protocol - - # ------------------------------------------------------------------------- - # :section: System Flags - # - # A message has a list of zero or more named tokens, known as "flags", - # associated with it. A flag is set by its addition to this list and is - # cleared by its removal. There are two types of flags in - # IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] and - # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html]: flags and - # keywords. A flag of either type can be permanent or session-only. - # - # A "system flag" is a message flag name that is predefined in the \IMAP - # specifications and begins with "\". Net::IMAP returns all - # system flags as symbols, without the "\" prefix. - # - # The descriptions here were copied from {[RFC-9051 - # §2.3.2]}[https://www.rfc-editor.org/rfc/rfc9051.html#section-2.3.2]. - # See also {[RFC-3501 - # §2.3.2]}[https://www.rfc-editor.org/rfc/rfc3501.html#section-2.3.2], - # which describes the flags message attribute semantics under - # IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html]. - # ------------------------------------------------------------------------- - - ## - # Flag indicating a message has been read. - SEEN = :Seen - - # Flag indicating a message has been answered. - ANSWERED = :Answered - - # A message flag indicating a message has been flagged for special or urgent - # attention. - # - # Also a mailbox special use attribute, which indicates that this mailbox - # presents all messages marked in some way as "important". When this - # special use is supported, it is likely to represent a virtual mailbox - # collecting messages (from other mailboxes) that are marked with the - # "\Flagged" message flag. - FLAGGED = :Flagged - - # Flag indicating a message has been marked for deletion. This - # will occur when the mailbox is closed or expunged. - DELETED = :Deleted - - # Flag indicating a message is only a draft or work-in-progress version. - DRAFT = :Draft - - # Flag indicating that the message is "recent," meaning that this - # session is the first session in which the client has been notified - # of this message. - # - # This flag was defined by - # IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] - # and is deprecated by - # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html]. - RECENT = :Recent - - # ------------------------------------------------------------------------- - # :section: Basic Mailbox Attributes - # Mailbox name attributes will be returned in #list responses. Base - # attributes must be returned according to the server's capabilities. - # - # IMAP4 specifies that all mailbox name attributes, including future - # extensions, begin with "\". Net::IMAP returns all mailbox - # attributes as symbols, without the "\" prefix. - # - # Mailbox name attributes are not case-sensitive. The current - # implementation normalizes mailbox attribute case using - # String#capitalize, such as +:Noselect+ (not +:NoSelect+). The constants - # (such as NO_SELECT) can also be used for comparison. The constants have - # been defined both with and without underscores between words. - # - # The descriptions here were copied from {[RFC-9051 § - # 7.3.1]}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.3.1]. - # - # Other mailbox name attributes can be found in the {IANA IMAP Mailbox Name - # Attributes registry}[https://www.iana.org/assignments/imap-mailbox-name-attributes/imap-mailbox-name-attributes.xhtml]. - # ------------------------------------------------------------------------- - - ## - # The +\NonExistent+ attribute indicates that a mailbox name does not refer - # to an existing mailbox. Note that this attribute is not meaningful by - # itself, as mailbox names that match the canonical #list pattern but don't - # exist must not be returned unless one of the two conditions listed below - # is also satisfied: - # - # 1. The mailbox name also satisfies the selection criteria (for example, - # it is subscribed and the "SUBSCRIBED" selection option has been - # specified). - # - # 2. "RECURSIVEMATCH" has been specified, and the mailbox name has at least - # one descendant mailbox name that does not match the #list pattern and - # does match the selection criteria. - # - # In practice, this means that the +\NonExistent+ attribute is usually - # returned with one or more of +\Subscribed+, +\Remote+, +\HasChildren+, or - # the CHILDINFO extended data item. - # - # The client must treat the presence of the +\NonExistent+ attribute as if the - # +\NoSelect+ attribute was also sent by the server - NONEXISTENT = :Nonexistent - - # Mailbox attribute indicating it is not possible for any child levels of - # hierarchy to exist under this name; no child levels exist now and none can - # be created in the future children. - # - # The client must treat the presence of the +\NoInferiors+ attribute as if the - # +\HasNoChildren+ attribute was also sent by the server - NO_INFERIORS = :Noinferiors - - # Mailbox attribute indicating it is not possible to use this name as a - # selectable mailbox. - NO_SELECT = :Noselect - - # The presence of this attribute indicates that the mailbox has child - # mailboxes. A server SHOULD NOT set this attribute if there are child - # mailboxes and the user does not have permission to access any of them. In - # this case, +\HasNoChildren+ SHOULD be used. In many cases, however, a - # server may not be able to efficiently compute whether a user has access to - # any child mailboxes. Note that even though the +\HasChildren+ attribute - # for a mailbox must be correct at the time of processing the mailbox, a - # client must be prepared to deal with a situation when a mailbox is marked - # with the +\HasChildren+ attribute, but no child mailbox appears in the - # response to the #list command. This might happen, for example, due to child - # mailboxes being deleted or made inaccessible to the user (using access - # control) by another client before the server is able to list them. - # - # It is an error for the server to return both a +\HasChildren+ and a - # +\HasNoChildren+ attribute in the same #list response. A client that - # encounters a #list response with both +\HasChildren+ and +\HasNoChildren+ - # attributes present should act as if both are absent in the #list response. - HAS_CHILDREN = :Haschildren - - # The presence of this attribute indicates that the mailbox has NO child - # mailboxes that are accessible to the currently authenticated user. - # - # It is an error for the server to return both a +\HasChildren+ and a - # +\HasNoChildren+ attribute in the same #list response. A client that - # encounters a #list response with both +\HasChildren+ and +\HasNoChildren+ - # attributes present should act as if both are absent in the #list response. - # - # Note: the +\HasNoChildren+ attribute should not be confused with the - # +\NoInferiors+ attribute, which indicates that no child mailboxes exist - # now and none can be created in the future. - HAS_NO_CHILDREN = :Hasnochildren - - # The mailbox has been marked "interesting" by the server; the mailbox - # probably contains messages that have been added since the last time the - # mailbox was selected. - # - # If it is not feasible for the server to determine whether or not the - # mailbox is "interesting", the server SHOULD NOT send either +\Marked+ or - # +\Unmarked+. The server MUST NOT send more than one of +\Marked+, - # +\Unmarked+, and +\NoSelect+ for a single mailbox, and it MAY send none of - # these. - MARKED = :Marked - - # The mailbox does not contain any additional messages since the last time - # the mailbox was selected. - # - # If it is not feasible for the server to determine whether or not the - # mailbox is "interesting", the server SHOULD NOT send either +\Marked+ or - # +\Unmarked+. The server MUST NOT send more than one of +\Marked+, - # +\Unmarked+, and +\NoSelect+ for a single mailbox, and it MAY send none of - # these. - UNMARKED = :Unmarked - - # The mailbox name was subscribed to using the #subscribe command. - SUBSCRIBED = :Subscribed - - # The mailbox is a remote mailbox. - REMOTE = :Remove - - # Alias for NO_INFERIORS, to match the \IMAP spelling. - NOINFERIORS = NO_INFERIORS - # Alias for NO_SELECT, to match the \IMAP spelling. - NOSELECT = NO_SELECT - # Alias for HAS_CHILDREN, to match the \IMAP spelling. - HASCHILDREN = HAS_CHILDREN - # Alias for HAS_NO_CHILDREN, to match the \IMAP spelling. - HASNOCHILDREN = HAS_NO_CHILDREN - - # ------------------------------------------------------------------------- - # :section: Mailbox role attributes - # - # Mailbox name attributes will be returned in #list responses. In addition - # to the base mailbox name attributes defined above, an \IMAP server MAY - # also include any or all of the following attributes that denote "role" (or - # "special-use") of a mailbox. These attributes are included along with base - # attributes defined above. A given mailbox may have none, one, or more than - # one of these attributes. In some cases, a special use is advice to a - # client about what to put in that mailbox. In other cases, it's advice to a - # client about what to expect to find there. - # - # IMAP4 specifies that all mailbox name attributes, including future - # extensions, begin with "\". Net::IMAP returns all mailbox - # attributes as symbols, without the "\" prefix. - # - # The special use attributes were first defined as part of the - # SPECIAL-USE[https://www.rfc-editor.org/rfc/rfc6154.html] extension, but - # servers may return them without including the +SPECIAL-USE+ #capability. - # - # The descriptions here were copied from {[RFC-9051 § - # 7.3.1]}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.3.1]. - # - # Other mailbox name attributes can be found in the {IANA IMAP Mailbox Name - # Attributes registry}[https://www.iana.org/assignments/imap-mailbox-name-attributes/imap-mailbox-name-attributes.xhtml]. - # ------------------------------------------------------------------------- - - # Mailbox attribute indicating that this mailbox presents all messages in - # the user's message store. Implementations MAY omit some messages, such as, - # perhaps, those in \Trash and \Junk. When this special use is supported, it - # is almost certain to represent a virtual mailbox - ALL = :All - - # Mailbox attribute indicating that this mailbox is used to archive - # messages. The meaning of an "archival" mailbox is server dependent; - # typically, it will be used to get messages out of the inbox, or otherwise - # keep them out of the user's way, while still making them accessible - ARCHIVE = :Archive - - # Mailbox attribute indicating that this mailbox is used to hold draft - # messages -- typically, messages that are being composed but have not yet - # been sent. In some server implementations, this might be a virtual - # mailbox, containing messages from other mailboxes that are marked with the - # "\Draft" message flag. Alternatively, this might just be advice that a - # client put drafts here - DRAFTS = :Drafts - - #-- - # n.b. FLAGGED is defined in the system flags section. - #++ - - # Mailbox attribute indicating that this mailbox is where messages deemed to - # be junk mail are held. Some server implementations might put messages here - # automatically. Alternatively, this might just be advice to a client-side - # spam filter. - JUNK = :Junk - - # Mailbox attribute indicating that this mailbox is used to hold copies of - # messages that have been sent. Some server implementations might put - # messages here automatically. Alternatively, this might just be advice that - # a client save sent messages here. - SENT = :Sent - - # Mailbox attribute indicating that this mailbox is used to hold messages - # that have been deleted or marked for deletion. In some server - # implementations, this might be a virtual mailbox, containing messages from - # other mailboxes that are marked with the +\Deleted+ message flag. - # Alternatively, this might just be advice that a client that chooses not to - # use the \IMAP +\Deleted+ model should use as its trash location. In server - # implementations that strictly expect the \IMAP +\Deleted+ model, this - # special use is likely not to be supported. - TRASH = :Trash - - # :section: - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/response_data.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/response_data.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/response_data.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/response_data.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,1159 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP < Protocol - autoload :FetchData, "#{__dir__}/fetch_data" - autoload :SearchResult, "#{__dir__}/search_result" - autoload :SequenceSet, "#{__dir__}/sequence_set" - autoload :UIDPlusData, "#{__dir__}/uidplus_data" - autoload :AppendUIDData, "#{__dir__}/uidplus_data" - autoload :CopyUIDData, "#{__dir__}/uidplus_data" - - # Net::IMAP::ContinuationRequest represents command continuation requests. - # - # The command continuation request response is indicated by a "+" token - # instead of a tag. This form of response indicates that the server is - # ready to accept the continuation of a command from the client. The - # remainder of this response is a line of text. - # - class ContinuationRequest < Struct.new(:data, :raw_data) - ## - # method: data - # :call-seq: data -> ResponseText - # - # Returns a ResponseText object - - ## - # method: raw_data - # :call-seq: raw_data -> string - # - # the raw response data - end - - # Net::IMAP::UntaggedResponse represents untagged responses. - # - # Data transmitted by the server to the client and status responses - # that do not indicate command completion are prefixed with the token - # "*", and are called untagged responses. - # - class UntaggedResponse < Struct.new(:name, :data, :raw_data) - ## - # method: name - # :call-seq: name -> string - # - # The uppercase response name, e.g. "FLAGS", "LIST", "FETCH", etc. - - ## - # method: data - # :call-seq: data -> object or nil - # - # The parsed response data, e.g: an array of flag symbols, an array of - # capabilities strings, a ResponseText object, a MailboxList object, a - # FetchData object, a Namespaces object, etc. The response #name - # determines what form the data can take. - - ## - # method: raw_data - # :call-seq: raw_data -> string - # - # The raw response data. - end - - # Net::IMAP::IgnoredResponse represents intentionally ignored responses. - # - # This includes untagged response "NOOP" sent by e.g. Zimbra to avoid - # some clients to close the connection. - # - # It matches no IMAP standard. - class IgnoredResponse < UntaggedResponse - end - - # **Note:** This represents an intentionally _unstable_ API. Where - # instances of this class are returned, future releases may return a - # different (incompatible) object without deprecation or warning. - # - # Net::IMAP::UnparsedData represents data for unknown response types or - # unknown extensions to response types without a well-defined extension - # grammar. - # - # See also: UnparsedNumericResponseData, ExtensionData, IgnoredResponse - class UnparsedData < Struct.new(:unparsed_data) - ## - # method: unparsed_data - # :call-seq: unparsed_data -> string - # - # The unparsed data - end - - # **Note:** This represents an intentionally _unstable_ API. Where - # instances of this class are returned, future releases may return a - # different (incompatible) object without deprecation or warning. - # - # Net::IMAP::UnparsedNumericResponseData represents data for unhandled - # response types with a numeric prefix. See the documentation for #number. - # - # See also: UnparsedData, ExtensionData, IgnoredResponse - class UnparsedNumericResponseData < Struct.new(:number, :unparsed_data) - ## - # method: number - # :call-seq: number -> integer - # - # Returns a numeric response data prefix, when available. - # - # Many response types are prefixed with a non-negative #number. For - # message data, #number may represent a sequence number or a UID. For - # mailbox data, #number may represent a message count. - - ## - # method: unparsed_data - # :call-seq: unparsed_data -> string - # - # The unparsed data, not including #number or UntaggedResponse#name. - end - - # **Note:** This represents an intentionally _unstable_ API. Where - # instances of this class are returned, future releases may return a - # different (incompatible) object without deprecation or warning. - # - # Net::IMAP::ExtensionData represents data that is parsable according to the - # forward-compatible extension syntax in RFC3501, RFC4466, or RFC9051, but - # isn't directly known or understood by Net::IMAP yet. - # - # See also: UnparsedData, UnparsedNumericResponseData, IgnoredResponse - class ExtensionData < Struct.new(:data) - ## - # method: data - # :call-seq: data -> string - # - # The parsed extension data. - end - - # Net::IMAP::TaggedResponse represents tagged responses. - # - # The server completion result response indicates the success or - # failure of the operation. It is tagged with the same tag as the - # client command which began the operation. - # - class TaggedResponse < Struct.new(:tag, :name, :data, :raw_data) - ## - # method: tag - # :call-seq: tag -> string - # - # Returns the command tag - - ## - # method: name - # :call-seq: name -> string - # - # Returns the name, one of "OK", "NO", or "BAD". - - ## - # method: data - # :call-seq: data -> ResponseText - # - # Returns a ResponseText object - - ## - # method: raw_data - # :call-seq: raw_data -> string - # - # The raw response data. - end - - # Net::IMAP::ResponseText represents texts of responses. - # - # The text may be prefixed by a ResponseCode. - # - # ResponseText is returned from TaggedResponse#data, or from - # UntaggedResponse#data when the response type is a "condition" ("OK", "NO", - # "BAD", "PREAUTH", or "BYE"). - class ResponseText < Struct.new(:code, :text) - # Used to avoid an allocation when ResponseText is empty - EMPTY = new(nil, "").freeze - - ## - # method: code - # :call-seq: code -> ResponseCode or nil - # - # Returns a ResponseCode, if the response contains one - - ## - # method: text - # :call-seq: text -> string - # - # Returns the response text, not including any response code - end - - # Net::IMAP::ResponseCode represents response codes. Response codes can be - # retrieved from ResponseText#code and can be included in any "condition" - # response: any TaggedResponse and UntaggedResponse when the response type - # is a "condition" ("OK", "NO", "BAD", "PREAUTH", or "BYE"). - # - # Some response codes come with additional data which will be parsed by - # Net::IMAP. Others return +nil+ for #data, but are used as a - # machine-readable annotation for the human-readable ResponseText#text in - # the same response. When Net::IMAP does not know how to parse response - # code text, #data returns the unparsed string. - # - # Untagged response code #data is pushed directly onto Net::IMAP#responses, - # keyed by #name, unless it is removed by the command that generated it. - # Use Net::IMAP#add_response_handler to view tagged response codes for - # command methods that do not return their TaggedResponse. - # - # \IMAP extensions may define new codes and the data that comes with them. - # The IANA {IMAP Response - # Codes}[https://www.iana.org/assignments/imap-response-codes/imap-response-codes.xhtml] - # registry has links to specifications for all standard response codes. - # Response codes are backwards compatible: Servers are allowed to send new - # response codes even if the client has not enabled the extension that - # defines them. When unknown response code data is encountered, #data - # will return an unparsed string. - # - # ==== +IMAP4rev1+ Response Codes - # See [IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501]] {§7.1, "Server - # Responses - Status - # Responses"}[https://www.rfc-editor.org/rfc/rfc3501#section-7.1] for full - # definitions of the basic set of IMAP4rev1 response codes: - # * +ALERT+, the ResponseText#text contains a special alert that MUST be - # brought to the user's attention. - # * +BADCHARSET+, #data will be an array of charset strings, or +nil+. - # * +CAPABILITY+, #data will be an array of capability strings. - # * +PARSE+, the ResponseText#text presents an error parsing a message's - # \[RFC5322] or [MIME-IMB] headers. - # * +PERMANENTFLAGS+, followed by an array of flags. System flags will be - # symbols, and keyword flags will be strings. See - # rdoc-ref:Net::IMAP@System+flags - # * +READ-ONLY+, the mailbox was selected read-only, or changed to read-only - # * +READ-WRITE+, the mailbox was selected read-write, or changed to - # read-write - # * +TRYCREATE+, when #append or #copy fail because the target mailbox - # doesn't exist. - # * +UIDNEXT+, #data is an Integer, the next UID value of the mailbox. See - # [{IMAP4rev1}[https://www.rfc-editor.org/rfc/rfc3501]], - # {§2.3.1.1, "Unique Identifier (UID) Message - # Attribute}[https://www.rfc-editor.org/rfc/rfc3501#section-2.3.1.1]. - # * +UIDVALIDITY+, #data is an Integer, the UID validity value of the - # mailbox. See [{IMAP4rev1}[https://www.rfc-editor.org/rfc/rfc3501]], - # {§2.3.1.1, "Unique Identifier (UID) Message - # Attribute}[https://www.rfc-editor.org/rfc/rfc3501#section-2.3.1.1]. - # * +UNSEEN+, #data is an Integer, the number of messages which do not have - # the \Seen flag set. - # DEPRECATED by IMAP4rev2. - # - # ==== +BINARY+ extension - # See {[RFC3516]}[https://www.rfc-editor.org/rfc/rfc3516]. - # * +UNKNOWN-CTE+, with a tagged +NO+ response, when the server does not - # known how to decode a CTE (content-transfer-encoding). #data is +nil+. - # See IMAP#fetch. - # - # ==== +UIDPLUS+ extension - # See {[RFC4315 §3]}[https://www.rfc-editor.org/rfc/rfc4315#section-3]. - # * +APPENDUID+, #data is UIDPlusData. See IMAP#append. - # * +COPYUID+, #data is UIDPlusData. See IMAP#copy. - # * +UIDNOTSTICKY+, #data is +nil+. See IMAP#select. - # - # ==== +SEARCHRES+ extension - # See {[RFC5182]}[https://www.rfc-editor.org/rfc/rfc5182]. - # * +NOTSAVED+, with a tagged +NO+ response, when the search result variable - # is not saved. #data is +nil+. - # - # ==== +RFC5530+ Response Codes - # See {[RFC5530]}[https://www.rfc-editor.org/rfc/rfc5530], "IMAP Response - # Codes" for the definition of the following response codes, which are all - # machine-readable annotations for the human-readable ResponseText#text, and - # have +nil+ #data of their own: - # * +UNAVAILABLE+ - # * +AUTHENTICATIONFAILED+ - # * +AUTHORIZATIONFAILED+ - # * +EXPIRED+ - # * +PRIVACYREQUIRED+ - # * +CONTACTADMIN+ - # * +NOPERM+ - # * +INUSE+ - # * +EXPUNGEISSUED+ - # * +CORRUPTION+ - # * +SERVERBUG+ - # * +CLIENTBUG+ - # * +CANNOT+ - # * +LIMIT+ - # * +OVERQUOTA+ - # * +ALREADYEXISTS+ - # * +NONEXISTENT+ - # - # ==== +QRESYNC+ extension - # See {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. - # * +CLOSED+, returned when the currently selected mailbox is closed - # implicitly by selecting or examining another mailbox. #data is +nil+. - # - # ==== +IMAP4rev2+ Response Codes - # See {[RFC9051]}[https://www.rfc-editor.org/rfc/rfc9051] {§7.1, "Server - # Responses - Status - # Responses"}[https://www.rfc-editor.org/rfc/rfc9051#section-7.1] for full - # descriptions of IMAP4rev2 response codes. IMAP4rev2 includes all of the - # response codes listed above (except "UNSEEN") and adds the following: - # * +HASCHILDREN+, with a tagged +NO+ response, when a mailbox delete failed - # because the server doesn't allow deletion of mailboxes with children. - # #data is +nil+. - # - # ==== +CONDSTORE+ extension - # See {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. - # * +NOMODSEQ+, when selecting a mailbox that does not support - # mod-sequences. #data is +nil+. See IMAP#select. - # * +HIGHESTMODSEQ+, #data is an Integer, the highest mod-sequence value of - # all messages in the mailbox. See IMAP#select. - # * +MODIFIED+, #data is a SequenceSet, the messages that have been modified - # since the +UNCHANGEDSINCE+ mod-sequence given to +STORE+ or UID - # STORE. - # - # ==== +OBJECTID+ extension - # See {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. - # * +MAILBOXID+, #data is a string - # - class ResponseCode < Struct.new(:name, :data) - ## - # method: name - # :call-seq: name -> string - # - # Returns the response code name, such as "ALERT", "PERMANENTFLAGS", or - # "UIDVALIDITY". - - ## - # method: data - # :call-seq: data -> object or nil - # - # Returns the parsed response code data, e.g: an array of capabilities - # strings, an array of character set strings, a list of permanent flags, - # an Integer, etc. The response #code determines what form the response - # code data can take. - end - - # Net::IMAP::MailboxList represents contents of the LIST response, - # representing a single mailbox path. - # - # Net::IMAP#list returns an array of MailboxList objects. - # - class MailboxList < Struct.new(:attr, :delim, :name) - ## - # method: attr - # :call-seq: attr -> array of Symbols - # - # Returns the name attributes. Each name attribute is a symbol capitalized - # by String#capitalize, such as :Noselect (not :NoSelect). For the - # semantics of each attribute, see: - # * rdoc-ref:Net::IMAP@Basic+Mailbox+Attributes - # * rdoc-ref:Net::IMAP@Mailbox+role+Attributes - # * Net::IMAP@SPECIAL-USE - # * The IANA {IMAP Mailbox Name Attributes - # registry}[https://www.iana.org/assignments/imap-mailbox-name-attributes/imap-mailbox-name-attributes.xhtml] - - ## - # method: delim - # :call-seq: delim -> single character string - # - # Returns the hierarchy delimiter for the mailbox path. - - ## - # method: name - # :call-seq: name -> string - # - # Returns the mailbox name. - end - - # Net::IMAP::MailboxQuota represents contents of GETQUOTA response. - # This object can also be a response to GETQUOTAROOT. In the syntax - # specification below, the delimiter used with the "#" construct is a - # single space (SPACE). - # - # Net:IMAP#getquota returns an array of MailboxQuota objects. - # - # Net::IMAP#getquotaroot returns an array containing both MailboxQuotaRoot - # and MailboxQuota objects. - # - class MailboxQuota < Struct.new(:mailbox, :usage, :quota) - ## - # method: mailbox - # :call-seq: mailbox -> string - # - # The mailbox with the associated quota. - - ## - # method: usage - # :call-seq: usage -> Integer - # - # Current storage usage of the mailbox. - - ## - # method: quota - # :call-seq: quota -> Integer - # - # Quota limit imposed on the mailbox. - # - end - - # Net::IMAP::MailboxQuotaRoot represents part of the GETQUOTAROOT - # response. (GETQUOTAROOT can also return Net::IMAP::MailboxQuota.) - # - # Net::IMAP#getquotaroot returns an array containing both MailboxQuotaRoot - # and MailboxQuota objects. - # - class MailboxQuotaRoot < Struct.new(:mailbox, :quotaroots) - ## - # method: mailbox - # :call-seq: mailbox -> string - # - # The mailbox with the associated quota. - - ## - # method: mailbox - # :call-seq: quotaroots -> array of strings - # - # Zero or more quotaroots that affect the quota on the specified mailbox. - end - - # Net::IMAP::MailboxACLItem represents the response from GETACL. - # - # Net::IMAP#getacl returns an array of MailboxACLItem objects. - # - # ==== Required capability - # +ACL+ - described in [ACL[https://tools.ietf.org/html/rfc4314]] - class MailboxACLItem < Struct.new(:user, :rights, :mailbox) - ## - # method: mailbox - # :call-seq: mailbox -> string - # - # The mailbox to which the indicated #user has the specified #rights. - - ## - # method: user - # :call-seq: user -> string - # - # Login name that has certain #rights to the #mailbox that was specified - # with the getacl command. - - ## - # method: rights - # :call-seq: rights -> string - # - # The access rights the indicated #user has to the #mailbox. - end - - # Net::IMAP::Namespace represents a single namespace contained inside a - # NAMESPACE response. - # - # Returned by Net::IMAP#namespace, contained inside a Namespaces object. - # - class Namespace < Struct.new(:prefix, :delim, :extensions) - ## - # method: prefix - # :call-seq: prefix -> string - # - # Returns the namespace prefix string. - - ## - # method: delim - # :call-seq: delim -> single character string or nil - # - # Returns a hierarchy delimiter character, if it exists. - - ## - # method: extensions - # :call-seq: extensions -> Hash[String, Array[String]] - # - # A hash of parameters mapped to arrays of strings, for extensibility. - # Extension parameter semantics would be defined by the extension. - end - - # Net::IMAP::Namespaces represents a +NAMESPACE+ server response, which - # contains lists of #personal, #shared, and #other namespaces. - # - # Net::IMAP#namespace returns a Namespaces object. - # - class Namespaces < Struct.new(:personal, :other, :shared) - ## - # method: personal - # :call-seq: personal -> array of Namespace - # - # Returns an array of Personal Namespace objects. - - ## - # method: other - # :call-seq: other -> array of Namespace - # - # Returns an array of Other Users' Namespace objects. - - ## - # method: shared - # :call-seq: shared -> array of Namespace - # - # Returns an array of Shared Namespace objects. - end - - # Net::IMAP::StatusData represents the contents of the STATUS response. - # - # Net::IMAP#status returns the contents of #attr. - class StatusData < Struct.new(:mailbox, :attr) - ## - # method: mailbox - # :call-seq: mailbox -> string - # - # The mailbox name. - - ## - # method: attr - # :call-seq: attr -> Hash[String, Integer] - # - # A hash. Each key is one of "MESSAGES", "RECENT", "UIDNEXT", - # "UIDVALIDITY", "UNSEEN". Each value is a number. - end - - # Net::IMAP::Envelope represents envelope structures of messages. - # - # [Note] - # When the #sender and #reply_to fields are absent or empty, they will - # return the same value as #from. Also, fields may return values that are - # invalid for well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] - # messages when the message is malformed or a draft message. - # - # See [{IMAP4rev1 §7.4.2}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2]] - # and [{IMAP4rev2 §7.5.2}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2]] - # for full description of the envelope fields, and - # Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. - # - # Returned by FetchData#envelope - class Envelope < Struct.new(:date, :subject, :from, :sender, :reply_to, - :to, :cc, :bcc, :in_reply_to, :message_id) - ## - # method: date - # call-seq: date -> string - # - # Returns a string that represents the +Date+ header. - # - # [Note] - # For a well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] - # message, the #date field must not be +nil+. However it can be +nil+ - # for a malformed or draft message. - - ## - # method: subject - # call-seq: subject -> string or nil - # - # Returns a string that represents the +Subject+ header, if it is present. - # - # [Note] - # Servers should return +nil+ when the header is absent and an empty - # string when it is present but empty. Some servers may return a +nil+ - # envelope member in the "present but empty" case. Clients should treat - # +nil+ and empty string as identical. - - ## - # method: from - # call-seq: from -> array of Net::IMAP::Address or nil - # - # Returns an array of Address that represents the +From+ header. - # - # If the +From+ header is absent, or is present but empty, the server - # returns +nil+ for this envelope field. - # - # [Note] - # For a well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] - # message, the #from field must not be +nil+. However it can be +nil+ - # for a malformed or draft message. - - ## - # method: sender - # call-seq: sender -> array of Net::IMAP::Address or nil - # - # Returns an array of Address that represents the +Sender+ header. - # - # [Note] - # If the Sender header is absent, or is present but empty, the - # server sets this field to be the same value as #from. Therefore, in a - # well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] message, - # the #sender envelope field must not be +nil+. However it can be - # +nil+ for a malformed or draft message. - - ## - # method: reply_to - # call-seq: reply_to -> array of Net::IMAP::Address or nil - # - # Returns an array of Address that represents the Reply-To - # header. - # - # [Note] - # If the Reply-To header is absent, or is present but empty, - # the server sets this field to be the same value as #from. Therefore, - # in a well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] - # message, the #reply_to envelope field must not be +nil+. However it - # can be +nil+ for a malformed or draft message. - - ## - # method: to - # call-seq: to -> array of Net::IMAP::Address - # - # Returns an array of Address that represents the +To+ header. - - ## - # method: cc - # call-seq: cc -> array of Net::IMAP::Address - # - # Returns an array of Address that represents the +Cc+ header. - - ## - # method: bcc - # call-seq: bcc -> array of Net::IMAP::Address - # - # Returns an array of Address that represents the +Bcc+ header. - - ## - # method: in_reply_to - # call-seq: in_reply_to -> string - # - # Returns a string that represents the In-Reply-To header. - # - # [Note] - # For a well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] - # message, the #in_reply_to field, if present, must not be empty. But - # it can still return an empty string for malformed messages. - # - # Servers should return +nil+ when the header is absent and an empty - # string when it is present but empty. Some servers may return a +nil+ - # envelope member in the "present but empty" case. Clients should treat - # +nil+ and empty string as identical. - - ## - # method: message_id - # call-seq: message_id -> string - # - # Returns a string that represents the Message-ID. - # - # [Note] - # For a well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] - # message, the #message_id field, if present, must not be empty. But it - # can still return an empty string for malformed messages. - # - # Servers should return +nil+ when the header is absent and an empty - # string when it is present but empty. Some servers may return a +nil+ - # envelope member in the "present but empty" case. Clients should treat - # +nil+ and empty string as identical. - end - - # Net::IMAP::Address represents an electronic mail address, which has been - # parsed into its component parts by the server. Address objects are - # returned within Envelope fields. - # - # === Group syntax - # - # When the #host field is +nil+, this is a special form of address structure - # that indicates the [RFC5322[https://tools.ietf.org/html/rfc5322]] group - # syntax. If the #mailbox name field is also +nil+, this is an end-of-group - # marker (semicolon in RFC-822 syntax). If the #mailbox name field is - # non-+NIL+, this is the start of a group marker, and the mailbox #name - # field holds the group name phrase. - class Address < Struct.new(:name, :route, :mailbox, :host) - ## - # method: name - # :call-seq: name -> string or nil - # - # Returns the [RFC5322[https://tools.ietf.org/html/rfc5322]] address - # +display-name+ (or the mailbox +phrase+ in the RFC-822 grammar). - - ## - # method: route - # :call-seq: route -> string or nil - # - # Returns the route from RFC-822 route-addr. - # - # Note:: Generating this obsolete route addressing syntax is not allowed - # by [RFC5322[https://tools.ietf.org/html/rfc5322]]. However, - # addresses with this syntax must still be accepted and parsed. - - ## - # method: mailbox - # :call-seq: mailbox -> string or nil - # - # Returns the [RFC5322[https://tools.ietf.org/html/rfc5322]] address - # +local-part+, if #host is not +nil+. - # - # When #host is +nil+, this returns - # an [RFC5322[https://tools.ietf.org/html/rfc5322]] group name and a +nil+ - # mailbox indicates the end of a group. - - ## - # method: host - # :call-seq: host -> string or nil - # - # Returns the [RFC5322[https://tools.ietf.org/html/rfc5322]] addr-spec - # +domain+ name. - # - # +nil+ indicates [RFC5322[https://tools.ietf.org/html/rfc5322]] group - # syntax. - end - - # Net::IMAP::ContentDisposition represents Content-Disposition fields. - # - class ContentDisposition < Struct.new(:dsp_type, :param) - ## - # method: dsp_type - # :call-seq: dsp_type -> string - # - # Returns the content disposition type, as defined by - # [DISPOSITION[https://tools.ietf.org/html/rfc2183]]. - - ## - # method: param - # :call-seq: param -> hash - # - # Returns a hash representing parameters of the Content-Disposition - # field, as defined by [DISPOSITION[https://tools.ietf.org/html/rfc2183]]. - end - - # Net::IMAP::ThreadMember represents a thread-node returned - # by Net::IMAP#thread. - # - class ThreadMember < Struct.new(:seqno, :children) - ## - # method: seqno - # :call-seq: seqno -> Integer - # - # The message sequence number. - - ## - # method: children - # :call-seq: children -> array of ThreadMember - # - # An array of Net::IMAP::ThreadMember objects for mail items that are - # children of this in the thread. - - # Returns a SequenceSet containing #seqno and all #children's seqno, - # recursively. - def to_sequence_set - SequenceSet.new all_seqnos - end - - protected - - def all_seqnos(node = self) - [node.seqno].concat node.children.flat_map { _1.all_seqnos } - end - - end - - # Net::IMAP::BodyStructure is included by all of the structs that can be - # returned from a "BODYSTRUCTURE" or "BODY" - # FetchData#attr value. Although these classes don't share a base class, - # this module can be used to pattern match all of them. - # - # See {[IMAP4rev1] §7.4.2}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2] - # and {[IMAP4rev2] §7.5.2}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2-4.9] - # for full description of all +BODYSTRUCTURE+ fields, and also - # Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. - # - # === Classes that include BodyStructure - # BodyTypeBasic:: Represents any message parts that are not handled by - # BodyTypeText, BodyTypeMessage, or BodyTypeMultipart. - # BodyTypeText:: Used by text/* parts. Contains all of the - # BodyTypeBasic fields. - # BodyTypeMessage:: Used by message/rfc822 and - # message/global parts. Contains all of the - # BodyTypeBasic fields. Other message/* types - # should use BodyTypeBasic. - # BodyTypeMultipart:: for multipart/* parts - # - module BodyStructure - end - - # Net::IMAP::BodyTypeBasic represents basic body structures of messages and - # message parts, unless they have a Content-Type that is handled by - # BodyTypeText, BodyTypeMessage, or BodyTypeMultipart. - # - # See {[IMAP4rev1] §7.4.2}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2] - # and {[IMAP4rev2] §7.5.2}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2-4.9] - # for full description of all +BODYSTRUCTURE+ fields, and also - # Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. - # - class BodyTypeBasic < Struct.new(:media_type, :subtype, - :param, :content_id, - :description, :encoding, :size, - :md5, :disposition, :language, - :location, - :extension) - include BodyStructure - - ## - # method: media_type - # :call-seq: media_type -> string - # - # The top-level media type as defined in - # [MIME-IMB[https://tools.ietf.org/html/rfc2045]]. - - ## - # method: subtype - # :call-seq: subtype -> string - # - # The media subtype name as defined in - # [MIME-IMB[https://tools.ietf.org/html/rfc2045]]. - - ## - # method: param - # :call-seq: param -> string - # - # Returns a hash that represents parameters as defined in - # [MIME-IMB[https://tools.ietf.org/html/rfc2045]]. - - ## - # method: content_id - # :call-seq: content_id -> string - # - # Returns a string giving the content id as defined - # in [MIME-IMB[https://tools.ietf.org/html/rfc2045]] - # {§7}[https://tools.ietf.org/html/rfc2045#section-7]. - - ## - # method: description - # :call-seq: description -> string - # - # Returns a string giving the content description as defined - # in [MIME-IMB[https://tools.ietf.org/html/rfc2045]] - # {§8}[https://tools.ietf.org/html/rfc2045#section-8]. - - ## - # method: encoding - # :call-seq: encoding -> string - # - # Returns a string giving the content transfer encoding as defined - # in [MIME-IMB[https://tools.ietf.org/html/rfc2045]] - # {§6}[https://tools.ietf.org/html/rfc2045#section-6]. - - ## - # method: size - # :call-seq: size -> integer - # - # Returns a number giving the size of the body in octets. - - ## - # method: md5 - # :call-seq: md5 -> string - # - # Returns a string giving the body MD5 value as defined in - # [MD5[https://tools.ietf.org/html/rfc1864]]. - - ## - # method: disposition - # :call-seq: disposition -> ContentDisposition - # - # Returns a ContentDisposition object giving the content - # disposition, as defined by - # [DISPOSITION[https://tools.ietf.org/html/rfc2183]]. - - ## - # method: language - # :call-seq: language -> string - # - # Returns a string or an array of strings giving the body - # language value as defined in - # [LANGUAGE-TAGS[https://www.rfc-editor.org/info/rfc3282]]. - - #-- - ## - # method: location - # :call-seq: location -> string - # - # A string list giving the body content URI as defined in - # [LOCATION[https://www.rfc-editor.org/info/rfc2557]]. - #++ - - ## - # method: extension - # :call-seq: extension -> string - # - # Returns extension data. The +BODYSTRUCTURE+ fetch attribute - # contains extension data, but +BODY+ does not. - - ## - # :call-seq: multipart? -> false - # - # BodyTypeBasic is not used for multipart MIME parts. - def multipart? - return false - end - - # :call-seq: media_subtype -> subtype - # - # >>> - # [Obsolete] - # Use +subtype+ instead. Calling this will generate a warning message - # to +stderr+, then return the value of +subtype+. - #-- - # TODO: why not just keep this as an alias? Would "media_subtype" be used - # for something else? - #++ - def media_subtype - warn("media_subtype is obsolete, use subtype instead.\n", uplevel: 1) - return subtype - end - end - - # Net::IMAP::BodyTypeText represents the body structures of messages and - # message parts, when Content-Type is text/*. - # - # BodyTypeText contains all of the fields of BodyTypeBasic. See - # BodyTypeBasic for documentation of the following: - # * {media_type}[rdoc-ref:BodyTypeBasic#media_type] - # * subtype[rdoc-ref:BodyTypeBasic#subtype] - # * param[rdoc-ref:BodyTypeBasic#param] - # * {content_id}[rdoc-ref:BodyTypeBasic#content_id] - # * description[rdoc-ref:BodyTypeBasic#description] - # * encoding[rdoc-ref:BodyTypeBasic#encoding] - # * size[rdoc-ref:BodyTypeBasic#size] - # - class BodyTypeText < Struct.new(:media_type, :subtype, - :param, :content_id, - :description, :encoding, :size, - :lines, - :md5, :disposition, :language, - :location, - :extension) - include BodyStructure - - ## - # method: lines - # :call-seq: lines -> Integer - # - # Returns the size of the body in text lines. - - ## - # :call-seq: multipart? -> false - # - # BodyTypeText is not used for multipart MIME parts. - def multipart? - return false - end - - # Obsolete: use +subtype+ instead. Calling this will - # generate a warning message to +stderr+, then return - # the value of +subtype+. - def media_subtype - warn("media_subtype is obsolete, use subtype instead.\n", uplevel: 1) - return subtype - end - end - - # Net::IMAP::BodyTypeMessage represents the body structures of messages and - # message parts, when Content-Type is message/rfc822 or - # message/global. - # - # BodyTypeMessage contains all of the fields of BodyTypeBasic. See - # BodyTypeBasic for documentation of the following fields: - # * {media_type}[rdoc-ref:BodyTypeBasic#media_type] - # * subtype[rdoc-ref:BodyTypeBasic#subtype] - # * param[rdoc-ref:BodyTypeBasic#param] - # * {content_id}[rdoc-ref:BodyTypeBasic#content_id] - # * description[rdoc-ref:BodyTypeBasic#description] - # * encoding[rdoc-ref:BodyTypeBasic#encoding] - # * size[rdoc-ref:BodyTypeBasic#size] - class BodyTypeMessage < Struct.new(:media_type, :subtype, - :param, :content_id, - :description, :encoding, :size, - :envelope, :body, :lines, - :md5, :disposition, :language, - :location, - :extension) - include BodyStructure - - ## - # method: envelope - # :call-seq: envelope -> Envelope - # - # Returns a Net::IMAP::Envelope giving the envelope structure. - - ## - # method: body - # :call-seq: body -> BodyStructure - # - # Returns a Net::IMAP::BodyStructure for the message's body structure. - - ## - # :call-seq: multipart? -> false - # - # BodyTypeMessage is not used for multipart MIME parts. - def multipart? - return false - end - - # Obsolete: use +subtype+ instead. Calling this will - # generate a warning message to +stderr+, then return - # the value of +subtype+. - def media_subtype - warn("media_subtype is obsolete, use subtype instead.\n", uplevel: 1) - return subtype - end - end - - # BodyTypeAttachment is not used and will be removed in an upcoming release. - # - # === Bug Analysis - # - # \IMAP body structures are parenthesized lists and assign their fields - # positionally, so missing fields change the interpretation of all - # following fields. Additionally, different body types have a different - # number of required fields, followed by optional "extension" fields. - # - # BodyTypeAttachment was previously returned when a "message/rfc822" part, - # which should be sent as body-type-msg with ten required fields, - # was actually sent as a body-type-basic with _seven_ required - # fields. - # - # basic => type, subtype, param, id, desc, enc, octets, md5=nil, dsp=nil, lang=nil, loc=nil, *ext - # msg => type, subtype, param, id, desc, enc, octets, envelope, body, lines, md5=nil, ... - # - # Normally, +envelope+ and +md5+ are incompatible, but Net::IMAP leniently - # allowed buggy servers to send +NIL+ for +envelope+. As a result, when a - # server sent a message/rfc822 part with +NIL+ for +md5+ and a - # non-NIL +dsp+, Net::IMAP misinterpreted the - # Content-Disposition as if it were a strange body type. In all - # reported cases, the Content-Disposition was "attachment", so - # BodyTypeAttachment was created as the workaround. - # - # === Current behavior - # - # When interpreted strictly, +envelope+ and +md5+ are incompatible. So the - # current parsing algorithm peeks ahead after it has received the seventh - # body field. If the next token is not the start of an +envelope+, we assume - # the server has incorrectly sent us a body-type-basic and return - # BodyTypeBasic. As a result, what was previously BodyTypeMessage#body => - # BodyTypeAttachment is now BodyTypeBasic#disposition => ContentDisposition. - # - class BodyTypeAttachment < Struct.new(:dsp_type, :_unused_, :param) - # *invalid for BodyTypeAttachment* - def media_type - warn(<<~WARN, uplevel: 1) - BodyTypeAttachment#media_type is obsolete. Use dsp_type instead. - WARN - dsp_type - end - - # *invalid for BodyTypeAttachment* - def subtype - warn("BodyTypeAttachment#subtype is obsolete.\n", uplevel: 1) - nil - end - - ## - # method: dsp_type - # :call-seq: dsp_type -> string - # - # Returns the content disposition type, as defined by - # [DISPOSITION[https://tools.ietf.org/html/rfc2183]]. - - ## - # method: param - # :call-seq: param -> hash - # - # Returns a hash representing parameters of the Content-Disposition - # field, as defined by [DISPOSITION[https://tools.ietf.org/html/rfc2183]]. - - ## - def multipart? - return false - end - end - - deprecate_constant :BodyTypeAttachment - - # Net::IMAP::BodyTypeMultipart represents body structures of messages and - # message parts, when Content-Type is multipart/*. - class BodyTypeMultipart < Struct.new(:media_type, :subtype, - :parts, - :param, :disposition, :language, - :location, - :extension) - include BodyStructure - - ## - # method: media_type - # call-seq: media_type -> "multipart" - # - # BodyTypeMultipart is only used with multipart/* media types. - - ## - # method: subtype - # call-seq: subtype -> string - # - # Returns the content subtype name - # as defined in [MIME-IMB[https://tools.ietf.org/html/rfc2045]]. - - ## - # method: parts - # call-seq: parts -> array of BodyStructure objects - # - # Returns an array with a BodyStructure object for each part contained in - # this part. - - ## - # method: param - # call-seq: param -> hash - # - # Returns a hash that represents parameters - # as defined in [MIME-IMB[https://tools.ietf.org/html/rfc2045]]. - - ## - # method: disposition - # call-seq: disposition -> ContentDisposition - # - # Returns a Net::IMAP::ContentDisposition object giving the content - # disposition. - - ## - # method: language - # :call-seq: language -> string - # - # Returns a string or an array of strings giving the body - # language value as defined in - # [LANGUAGE-TAGS[https://www.rfc-editor.org/info/rfc3282]]. - - ## - # method: extension - # call-seq: extension -> array - # - # Returns extension data as an array of numbers strings, and nested - # arrays (of numbers, strings, etc). - - ## - # :call-seq: multipart? -> true - # - # BodyTypeMultipart is used for multipart MIME parts. - def multipart? - return true - end - - ## - # Obsolete: use +subtype+ instead. Calling this will - # generate a warning message to +stderr+, then return - # the value of +subtype+. - def media_subtype - warn("media_subtype is obsolete, use subtype instead.\n", uplevel: 1) - return subtype - end - end - - # === Obsolete - # BodyTypeExtension is not used and will be removed in an upcoming release. - # - # >>> - # BodyTypeExtension was (incorrectly) used for message/* parts - # (besides message/rfc822, which correctly uses BodyTypeMessage). - # - # Net::IMAP now (correctly) parses all message types (other than - # message/rfc822 or message/global) as BodyTypeBasic. - class BodyTypeExtension < Struct.new(:media_type, :subtype, - :params, :content_id, - :description, :encoding, :size) - def multipart? - return false - end - end - - deprecate_constant :BodyTypeExtension - - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/response_parser/parser_utils.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/response_parser/parser_utils.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/response_parser/parser_utils.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/response_parser/parser_utils.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,240 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP < Protocol - class ResponseParser - # basic utility methods for parsing. - # - # (internal API, subject to change) - module ParserUtils # :nodoc: - - module Generator # :nodoc: - - LOOKAHEAD = "(@token ||= next_token)" - SHIFT_TOKEN = "(@token = nil)" - - # we can skip lexer for single character matches, as a shortcut - def def_char_matchers(name, char, token) - byte = char.ord - match_name = name.match(/\A[A-Z]/) ? "#{name}!" : name - char = char.dump - class_eval <<~RUBY, __FILE__, __LINE__ + 1 - # frozen_string_literal: true - - # force use of #next_token; no string peeking - def lookahead_#{name}? - #{LOOKAHEAD}&.symbol == #{token} - end - - # use token or string peek - def peek_#{name}? - @token ? @token.symbol == #{token} : @str.getbyte(@pos) == #{byte} - end - - # like accept(token_symbols); returns token or nil - def #{name}? - if @token&.symbol == #{token} - #{SHIFT_TOKEN} - #{char} - elsif !@token && @str.getbyte(@pos) == #{byte} - @pos += 1 - #{char} - end - end - - # like match(token_symbols); returns token or raises parse_error - def #{match_name} - if @token&.symbol == #{token} - #{SHIFT_TOKEN} - #{char} - elsif !@token && @str.getbyte(@pos) == #{byte} - @pos += 1 - #{char} - else - parse_error("unexpected %s (expected %p)", - @token&.symbol || @str[@pos].inspect, #{char}) - end - end - RUBY - end - - # TODO: move coersion to the token.value method? - def def_token_matchers(name, *token_symbols, coerce: nil, send: nil) - match_name = name.match(/\A[A-Z]/) ? "#{name}!" : name - - if token_symbols.size == 1 - token = token_symbols.first - matcher = "token&.symbol == %p" % [token] - desc = token - else - matcher = "%p.include? token&.symbol" % [token_symbols] - desc = token_symbols.join(" or ") - end - - value = "(token.value)" - value = coerce.to_s + value if coerce - value = [value, send].join(".") if send - - raise_parse_error = <<~RUBY - parse_error("unexpected %s (expected #{desc})", token&.symbol) - RUBY - - class_eval <<~RUBY, __FILE__, __LINE__ + 1 - # frozen_string_literal: true - - # lookahead version of match, returning the value - def lookahead_#{name}! - token = #{LOOKAHEAD} - if #{matcher} - #{value} - else - #{raise_parse_error} - end - end - - def #{name}? - token = #{LOOKAHEAD} - if #{matcher} - #{SHIFT_TOKEN} - #{value} - end - end - - def #{match_name} - token = #{LOOKAHEAD} - if #{matcher} - #{SHIFT_TOKEN} - #{value} - else - #{raise_parse_error} - end - end - RUBY - end - - end - - private - - # TODO: after checking the lookahead, use a regexp for remaining chars. - # That way a loop isn't needed. - def combine_adjacent(*tokens) - result = "".b - while token = accept(*tokens) - result << token.value - end - if result.empty? - parse_error('unexpected token %s (expected %s)', - lookahead.symbol, tokens.join(" or ")) - end - result - end - - def match(*args) - token = lookahead - unless args.include?(token.symbol) - parse_error('unexpected token %s (expected %s)', - token.symbol.id2name, - args.collect {|i| i.id2name}.join(" or ")) - end - shift_token - token - end - - # like match, but does not raise error on failure. - # - # returns and shifts token on successful match - # returns nil and leaves @token unshifted on no match - def accept(*args) - token = lookahead - if args.include?(token.symbol) - shift_token - token - end - end - - # To be used conditionally: - # assert_no_lookahead if config.debug? - def assert_no_lookahead - @token.nil? or - parse_error("assertion failed: expected @token.nil?, actual %s: %p", - @token.symbol, @token.value) - end - - # like accept, without consuming the token - def lookahead?(*symbols) - @token if symbols.include?((@token ||= next_token)&.symbol) - end - - def lookahead - @token ||= next_token - end - - # like match, without consuming the token - def lookahead!(*args) - if args.include?((@token ||= next_token)&.symbol) - @token - else - parse_error('unexpected token %s (expected %s)', - @token&.symbol, args.join(" or ")) - end - end - - def peek_str?(str) - assert_no_lookahead if config.debug? - @str[@pos, str.length] == str - end - - def peek_re(re) - assert_no_lookahead if config.debug? - re.match(@str, @pos) - end - - def accept_re(re) - assert_no_lookahead if config.debug? - re.match(@str, @pos) and @pos = $~.end(0) - $~ - end - - def match_re(re, name) - assert_no_lookahead if config.debug? - if re.match(@str, @pos) - @pos = $~.end(0) - $~ - else - parse_error("invalid #{name}") - end - end - - def shift_token - @token = nil - end - - def parse_error(fmt, *args) - msg = format(fmt, *args) - if config.debug? - local_path = File.dirname(__dir__) - tok = @token ? "%s: %p" % [@token.symbol, @token.value] : "nil" - warn "%s %s: %s" % [self.class, __method__, msg] - warn " tokenized : %s" % [@str[...@pos].dump] - warn " remaining : %s" % [@str[@pos..].dump] - warn " @lex_state: %s" % [@lex_state] - warn " @pos : %d" % [@pos] - warn " @token : %s" % [tok] - caller_locations(1..20).each_with_index do |cloc, idx| - next unless cloc.path&.start_with?(local_path) - warn " caller[%2d]: %-30s (%s:%d)" % [ - idx, - cloc.base_label, - File.basename(cloc.path, ".rb"), - cloc.lineno - ] - end - end - raise ResponseParseError, msg - end - - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/response_parser.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/response_parser.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/response_parser.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/response_parser.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,2140 +0,0 @@ -# frozen_string_literal: true - -require_relative "errors" -require_relative "response_parser/parser_utils" - -module Net - class IMAP < Protocol - - # Parses an \IMAP server response. - class ResponseParser - include ParserUtils - extend ParserUtils::Generator - - attr_reader :config - - # Creates a new ResponseParser. - # - # When +config+ is frozen or global, the parser #config inherits from it. - # Otherwise, +config+ will be used directly. - def initialize(config: Config.global) - @str = nil - @pos = nil - @lex_state = nil - @token = nil - @config = Config[config] - @config = @config.new if @config == Config.global || @config.frozen? - end - - # :call-seq: - # parse(str) -> ContinuationRequest - # parse(str) -> UntaggedResponse - # parse(str) -> TaggedResponse - # - # Raises ResponseParseError for unparsable strings. - def parse(str) - @str = str - @pos = 0 - @lex_state = EXPR_BEG - @token = nil - return response - end - - private - - # :stopdoc: - - EXPR_BEG = :EXPR_BEG # the default, used in most places - EXPR_DATA = :EXPR_DATA # envelope, body(structure), namespaces - - T_SPACE = :SPACE # atom special - T_ATOM = :ATOM # atom (subset of astring chars) - T_NIL = :NIL # subset of atom and label - T_NUMBER = :NUMBER # subset of atom - T_LBRA = :LBRA # subset of atom - T_PLUS = :PLUS # subset of atom; tag special - T_RBRA = :RBRA # atom special; resp_special; valid astring char - T_QUOTED = :QUOTED # starts/end with atom special - T_BSLASH = :BSLASH # atom special; quoted special - T_LPAR = :LPAR # atom special; paren list delimiter - T_RPAR = :RPAR # atom special; paren list delimiter - T_STAR = :STAR # atom special; list wildcard - T_PERCENT = :PERCENT # atom special; list wildcard - T_LITERAL = :LITERAL # starts with atom special - T_LITERAL8 = :LITERAL8 # starts with atom char "~" - T_CRLF = :CRLF # atom special; text special; quoted special - T_TEXT = :TEXT # any char except CRLF - T_EOF = :EOF # end of response string - - module ResponseConditions - OK = "OK" - NO = "NO" - BAD = "BAD" - BYE = "BYE" - PREAUTH = "PREAUTH" - - RESP_COND_STATES = [OK, NO, BAD ].freeze - RESP_DATA_CONDS = [OK, NO, BAD, BYE, ].freeze - AUTH_CONDS = [OK, PREAUTH].freeze - GREETING_CONDS = [OK, BYE, PREAUTH].freeze - RESP_CONDS = [OK, NO, BAD, BYE, PREAUTH].freeze - end - include ResponseConditions - - module Patterns - - module CharClassSubtraction - refine Regexp do - def -(rhs); /[#{source}&&[^#{rhs.source}]]/n.freeze end - end - end - using CharClassSubtraction - - # From RFC5234, "Augmented BNF for Syntax Specifications: ABNF" - # >>> - # ALPHA = %x41-5A / %x61-7A ; A-Z / a-z - # CHAR = %x01-7F - # CRLF = CR LF - # ; Internet standard newline - # CTL = %x00-1F / %x7F - # ; controls - # DIGIT = %x30-39 - # ; 0-9 - # DQUOTE = %x22 - # ; " (Double Quote) - # HEXDIG = DIGIT / "A" / "B" / "C" / "D" / "E" / "F" - # OCTET = %x00-FF - # SP = %x20 - module RFC5234 - ALPHA = /[A-Za-z]/n - CHAR = /[\x01-\x7f]/n - CRLF = /\r\n/n - CTL = /[\x00-\x1F\x7F]/n - DIGIT = /\d/n - DQUOTE = /"/n - HEXDIG = /\h/ - OCTET = /[\x00-\xFF]/n # not using /./m for embedding purposes - SP = / /n - end - - # UTF-8, a transformation format of ISO 10646 - # >>> - # UTF8-1 = %x00-7F - # UTF8-tail = %x80-BF - # UTF8-2 = %xC2-DF UTF8-tail - # UTF8-3 = %xE0 %xA0-BF UTF8-tail / %xE1-EC 2( UTF8-tail ) / - # %xED %x80-9F UTF8-tail / %xEE-EF 2( UTF8-tail ) - # UTF8-4 = %xF0 %x90-BF 2( UTF8-tail ) / %xF1-F3 3( UTF8-tail ) / - # %xF4 %x80-8F 2( UTF8-tail ) - # UTF8-char = UTF8-1 / UTF8-2 / UTF8-3 / UTF8-4 - # UTF8-octets = *( UTF8-char ) - # - # n.b. String * Integer is used for repetition, rather than /x{3}/, - # because ruby 3.2's linear-time cache-based optimization doesn't work - # with "bounded or fixed times repetition nesting in another repetition - # (e.g. /(a{2,3})*/). It is an implementation issue entirely, but we - # believe it is hard to support this case correctly." - # See https://bugs.ruby-lang.org/issues/19104 - module RFC3629 - UTF8_1 = /[\x00-\x7f]/n # aka ASCII 7bit - UTF8_TAIL = /[\x80-\xBF]/n - UTF8_2 = /[\xC2-\xDF]#{UTF8_TAIL}/n - UTF8_3 = Regexp.union(/\xE0[\xA0-\xBF]#{UTF8_TAIL}/n, - /\xED[\x80-\x9F]#{UTF8_TAIL}/n, - /[\xE1-\xEC]#{ UTF8_TAIL.source * 2}/n, - /[\xEE-\xEF]#{ UTF8_TAIL.source * 2}/n) - UTF8_4 = Regexp.union(/[\xF1-\xF3]#{ UTF8_TAIL.source * 3}/n, - /\xF0[\x90-\xBF]#{UTF8_TAIL.source * 2}/n, - /\xF4[\x80-\x8F]#{UTF8_TAIL.source * 2}/n) - UTF8_CHAR = Regexp.union(UTF8_1, UTF8_2, UTF8_3, UTF8_4) - UTF8_OCTETS = /#{UTF8_CHAR}*/n - end - - include RFC5234 - include RFC3629 - - # CHAR8 = %x01-ff - # ; any OCTET except NUL, %x00 - CHAR8 = /[\x01-\xff]/n - - # list-wildcards = "%" / "*" - LIST_WILDCARDS = /[%*]/n - # quoted-specials = DQUOTE / "\" - QUOTED_SPECIALS = /["\\]/n - # resp-specials = "]" - RESP_SPECIALS = /[\]]/n - - # atomish = 1* - # ; We use "atomish" for msg-att and section, in order - # ; to simplify "BODY[HEADER.FIELDS (foo bar)]". - # - # atom-specials = "(" / ")" / "{" / SP / CTL / list-wildcards / - # quoted-specials / resp-specials - # ATOM-CHAR = - # atom = 1*ATOM-CHAR - # ASTRING-CHAR = ATOM-CHAR / resp-specials - # tag = 1* - - ATOM_SPECIALS = /[(){ \x00-\x1f\x7f%*"\\\]]/n - ASTRING_SPECIALS = /[(){ \x00-\x1f\x7f%*"\\]/n - - ASTRING_CHAR = CHAR - ASTRING_SPECIALS - ATOM_CHAR = CHAR - ATOM_SPECIALS - - ATOM = /#{ATOM_CHAR}+/n - ASTRING_CHARS = /#{ASTRING_CHAR}+/n - ATOMISH = /#{ATOM_CHAR - /[\[]/ }+/ - TAG = /#{ASTRING_CHAR - /[+]/ }+/ - - # TEXT-CHAR = - TEXT_CHAR = CHAR - /[\r\n]/ - - # resp-text-code = ... / atom [SP 1*] - CODE_TEXT_CHAR = TEXT_CHAR - RESP_SPECIALS - CODE_TEXT = /#{CODE_TEXT_CHAR}+/n - - # flag = "\Answered" / "\Flagged" / "\Deleted" / - # "\Seen" / "\Draft" / flag-keyword / flag-extension - # ; Does not include "\Recent" - # flag-extension = "\" atom - # ; Future expansion. Client implementations - # ; MUST accept flag-extension flags. Server - # ; implementations MUST NOT generate - # ; flag-extension flags except as defined by - # ; a future Standard or Standards Track - # ; revisions of this specification. - # flag-keyword = "$MDNSent" / "$Forwarded" / "$Junk" / - # "$NotJunk" / "$Phishing" / atom - # - # flag-perm = flag / "\*" - # - # Not checking for max one mbx-list-sflag in the parser. - # >>> - # mbx-list-oflag = "\Noinferiors" / child-mbox-flag / - # "\Subscribed" / "\Remote" / flag-extension - # ; Other flags; multiple from this list are - # ; possible per LIST response, but each flag - # ; can only appear once per LIST response - # mbx-list-sflag = "\NonExistent" / "\Noselect" / "\Marked" / - # "\Unmarked" - # ; Selectability flags; only one per LIST response - # child-mbox-flag = "\HasChildren" / "\HasNoChildren" - # ; attributes for the CHILDREN return option, at most - # ; one possible per LIST response - FLAG = /\\?#{ATOM}/n - FLAG_EXTENSION = /\\#{ATOM}/n - FLAG_KEYWORD = ATOM - FLAG_PERM = Regexp.union(FLAG, "\\*") - MBX_FLAG = FLAG_EXTENSION - - # flag-list = "(" [flag *(SP flag)] ")" - # resp-text-code =/ "PERMANENTFLAGS" SP - # "(" [flag-perm *(SP flag-perm)] ")" - # mbx-list-flags = *(mbx-list-oflag SP) mbx-list-sflag - # *(SP mbx-list-oflag) / - # mbx-list-oflag *(SP mbx-list-oflag) - # (Not checking for max one mbx-list-sflag in the parser.) - FLAG_LIST = /\G\((#{FLAG }(?:#{SP}#{FLAG })*|)\)/ni - FLAG_PERM_LIST = /\G\((#{FLAG_PERM}(?:#{SP}#{FLAG_PERM})*|)\)/ni - MBX_LIST_FLAGS = /\G (#{MBX_FLAG }(?:#{SP}#{MBX_FLAG })*) /nix - - # Gmail allows SP and "]" in flags....... - QUIRKY_FLAG = Regexp.union(/\\?#{ASTRING_CHARS}/n, "\\*") - QUIRKY_FLAGS_LIST = /\G\(( [^)]* )\)/nx - - # RFC3501: - # QUOTED-CHAR = / - # "\" quoted-specials - # RFC9051: - # QUOTED-CHAR = / - # "\" quoted-specials / UTF8-2 / UTF8-3 / UTF8-4 - # RFC3501 & RFC9051: - # quoted = DQUOTE *QUOTED-CHAR DQUOTE - QUOTED_CHAR_safe = TEXT_CHAR - QUOTED_SPECIALS - QUOTED_CHAR_esc = /\\#{QUOTED_SPECIALS}/n - QUOTED_CHAR_rev1 = Regexp.union(QUOTED_CHAR_safe, QUOTED_CHAR_esc) - QUOTED_CHAR_rev2 = Regexp.union(QUOTED_CHAR_rev1, - UTF8_2, UTF8_3, UTF8_4) - QUOTED_rev1 = /"(#{QUOTED_CHAR_rev1}*)"/n - QUOTED_rev2 = /"(#{QUOTED_CHAR_rev2}*)"/n - - # RFC3501: - # text = 1*TEXT-CHAR - # RFC9051: - # text = 1*(TEXT-CHAR / UTF8-2 / UTF8-3 / UTF8-4) - # ; Non-ASCII text can only be returned - # ; after ENABLE IMAP4rev2 command - TEXT_rev1 = /#{TEXT_CHAR}+/ - TEXT_rev2 = /#{Regexp.union TEXT_CHAR, UTF8_2, UTF8_3, UTF8_4}+/ - - # tagged-label-fchar = ALPHA / "-" / "_" / "." - TAGGED_LABEL_FCHAR = /[a-zA-Z\-_.]/n - # tagged-label-char = tagged-label-fchar / DIGIT / ":" - TAGGED_LABEL_CHAR = /[a-zA-Z\-_.0-9:]*/n - # tagged-ext-label = tagged-label-fchar *tagged-label-char - # ; Is a valid RFC 3501 "atom". - TAGGED_EXT_LABEL = /#{TAGGED_LABEL_FCHAR}#{TAGGED_LABEL_CHAR}*/n - - # nz-number = digit-nz *DIGIT - # ; Non-zero unsigned 32-bit integer - # ; (0 < n < 4,294,967,296) - NZ_NUMBER = /[1-9]\d*/n - - # seq-number = nz-number / "*" - # ; message sequence number (COPY, FETCH, STORE - # ; commands) or unique identifier (UID COPY, - # ; UID FETCH, UID STORE commands). - # ; * represents the largest number in use. In - # ; the case of message sequence numbers, it is - # ; the number of messages in a non-empty mailbox. - # ; In the case of unique identifiers, it is the - # ; unique identifier of the last message in the - # ; mailbox or, if the mailbox is empty, the - # ; mailbox's current UIDNEXT value. - # ; The server should respond with a tagged BAD - # ; response to a command that uses a message - # ; sequence number greater than the number of - # ; messages in the selected mailbox. This - # ; includes "*" if the selected mailbox is empty. - SEQ_NUMBER = /#{NZ_NUMBER}|\*/n - - # seq-range = seq-number ":" seq-number - # ; two seq-number values and all values between - # ; these two regardless of order. - # ; Example: 2:4 and 4:2 are equivalent and - # ; indicate values 2, 3, and 4. - # ; Example: a unique identifier sequence range of - # ; 3291:* includes the UID of the last message in - # ; the mailbox, even if that value is less than - # ; 3291. - SEQ_RANGE = /#{SEQ_NUMBER}:#{SEQ_NUMBER}/n - - # sequence-set = (seq-number / seq-range) ["," sequence-set] - # ; set of seq-number values, regardless of order. - # ; Servers MAY coalesce overlaps and/or execute - # ; the sequence in any order. - # ; Example: a message sequence number set of - # ; 2,4:7,9,12:* for a mailbox with 15 messages is - # ; equivalent to 2,4,5,6,7,9,12,13,14,15 - # ; Example: a message sequence number set of - # ; *:4,5:7 for a mailbox with 10 messages is - # ; equivalent to 10,9,8,7,6,5,4,5,6,7 and MAY - # ; be reordered and overlap coalesced to be - # ; 4,5,6,7,8,9,10. - SEQUENCE_SET_ITEM = /#{SEQ_NUMBER}|#{SEQ_RANGE}/n - SEQUENCE_SET = /#{SEQUENCE_SET_ITEM}(?:,#{SEQUENCE_SET_ITEM})*/n - SEQUENCE_SET_STR = /\A#{SEQUENCE_SET}\z/n - - # RFC3501: - # literal = "{" number "}" CRLF *CHAR8 - # ; Number represents the number of CHAR8s - # RFC9051: - # literal = "{" number64 ["+"] "}" CRLF *CHAR8 - # ; represents the number of CHAR8s. - # ; A non-synchronizing literal is distinguished - # ; from a synchronizing literal by the presence of - # ; "+" before the closing "}". - # ; Non-synchronizing literals are not allowed when - # ; sent from server to the client. - LITERAL = /\{(\d+)\}\r\n/n - - # RFC3516 (BINARY): - # literal8 = "~{" number "}" CRLF *OCTET - # ; represents the number of OCTETs - # ; in the response string. - # RFC9051: - # literal8 = "~{" number64 "}" CRLF *OCTET - # ; represents the number of OCTETs - # ; in the response string. - LITERAL8 = /~\{(\d+)\}\r\n/n - - module_function - - def unescape_quoted!(quoted) - quoted - &.gsub!(/\\(#{QUOTED_SPECIALS})/n, "\\1") - &.force_encoding("UTF-8") - end - - def unescape_quoted(quoted) - quoted - &.gsub(/\\(#{QUOTED_SPECIALS})/n, "\\1") - &.force_encoding("UTF-8") - end - - end - - # the default, used in most places - BEG_REGEXP = /\G(?:\ -(?# 1: SPACE )( )|\ -(?# 2: LITERAL8)#{Patterns::LITERAL8}|\ -(?# 3: ATOM prefixed with a compatible subtype)\ -((?:\ -(?# 4: NIL )(NIL)|\ -(?# 5: NUMBER )(\d+)|\ -(?# 6: PLUS )(\+))\ -(?# 7: ATOM remaining after prefix )(#{Patterns::ATOMISH})?\ -(?# This enables greedy alternation without lookahead, in linear time.)\ -)|\ -(?# Also need to check for ATOM without a subtype prefix.)\ -(?# 8: ATOM )(#{Patterns::ATOMISH})|\ -(?# 9: QUOTED )#{Patterns::QUOTED_rev2}|\ -(?# 10: LPAR )(\()|\ -(?# 11: RPAR )(\))|\ -(?# 12: BSLASH )(\\)|\ -(?# 13: STAR )(\*)|\ -(?# 14: LBRA )(\[)|\ -(?# 15: RBRA )(\])|\ -(?# 16: LITERAL )#{Patterns::LITERAL}|\ -(?# 17: PERCENT )(%)|\ -(?# 18: CRLF )(\r\n)|\ -(?# 19: EOF )(\z))/ni - - # envelope, body(structure), namespaces - DATA_REGEXP = /\G(?:\ -(?# 1: SPACE )( )|\ -(?# 2: NIL )(NIL)|\ -(?# 3: NUMBER )(\d+)|\ -(?# 4: QUOTED )#{Patterns::QUOTED_rev2}|\ -(?# 5: LITERAL )#{Patterns::LITERAL}|\ -(?# 6: LPAR )(\()|\ -(?# 7: RPAR )(\)))/ni - - # text, after 'resp-text-code "]"' - TEXT_REGEXP = /\G(#{Patterns::TEXT_rev2})/n - - # resp-text-code, after 'atom SP' - CTEXT_REGEXP = /\G(#{Patterns::CODE_TEXT})/n - - Token = Struct.new(:symbol, :value) - - def_char_matchers :SP, " ", :T_SPACE - def_char_matchers :PLUS, "+", :T_PLUS - def_char_matchers :STAR, "*", :T_STAR - - def_char_matchers :lpar, "(", :T_LPAR - def_char_matchers :rpar, ")", :T_RPAR - - def_char_matchers :lbra, "[", :T_LBRA - def_char_matchers :rbra, "]", :T_RBRA - - # valid number ranges are not enforced by parser - # number = 1*DIGIT - # ; Unsigned 32-bit integer - # ; (0 <= n < 4,294,967,296) - def_token_matchers :number, T_NUMBER, coerce: Integer - - def_token_matchers :quoted, T_QUOTED - - # string = quoted / literal - def_token_matchers :string, T_QUOTED, T_LITERAL - - # used by nstring8 = nstring / literal8 - def_token_matchers :string8, T_QUOTED, T_LITERAL, T_LITERAL8 - - # use where string represents "LABEL" values - def_token_matchers :case_insensitive__string, - T_QUOTED, T_LITERAL, - send: :upcase - - # n.b: NIL? and NIL! return the "NIL" atom string (truthy) on success. - # NIL? returns nil when it does *not* match - def_token_matchers :NIL, T_NIL - - # In addition to explicitly uses of +tagged-ext-label+, use this to match - # keywords when the grammar has not provided any extension syntax. - # - # Do *not* use this for labels where the grammar specifies extensions - # can be +atom+, even if all currently defined labels would match. For - # example response codes in +resp-text-code+. - # - # tagged-ext-label = tagged-label-fchar *tagged-label-char - # ; Is a valid RFC 3501 "atom". - # tagged-label-fchar = ALPHA / "-" / "_" / "." - # tagged-label-char = tagged-label-fchar / DIGIT / ":" - # - # TODO: add to lexer and only match tagged-ext-label - def_token_matchers :tagged_ext_label, T_ATOM, T_NIL, send: :upcase - - def_token_matchers :CRLF, T_CRLF - def_token_matchers :EOF, T_EOF - - # atom = 1*ATOM-CHAR - # ATOM-CHAR = - ATOM_TOKENS = [T_ATOM, T_NUMBER, T_NIL, T_LBRA, T_PLUS] - - SEQUENCE_SET_TOKENS = [T_ATOM, T_NUMBER, T_STAR] - - # sequence-set = (seq-number / seq-range) ["," sequence-set] - # sequence-set =/ seq-last-command - # ; Allow for "result of the last command" - # ; indicator. - # seq-last-command = "$" - # - # *note*: doesn't match seq-last-command - def sequence_set - str = combine_adjacent(*SEQUENCE_SET_TOKENS) - if Patterns::SEQUENCE_SET_STR.match?(str) - SequenceSet[str] - else - parse_error("unexpected atom %p, expected sequence-set", str) - end - end - - # ASTRING-CHAR = ATOM-CHAR / resp-specials - # resp-specials = "]" - ASTRING_CHARS_TOKENS = [*ATOM_TOKENS, T_RBRA].freeze - - ASTRING_TOKENS = [T_QUOTED, *ASTRING_CHARS_TOKENS, T_LITERAL].freeze - - # tag = 1* - TAG_TOKENS = (ASTRING_CHARS_TOKENS - [T_PLUS]).freeze - - # TODO: handle atom, astring_chars, and tag entirely inside the lexer - def atom; combine_adjacent(*ATOM_TOKENS) end - def astring_chars; combine_adjacent(*ASTRING_CHARS_TOKENS) end - def tag; combine_adjacent(*TAG_TOKENS) end - - # the #accept version of #atom - def atom?; -combine_adjacent(*ATOM_TOKENS) if lookahead?(*ATOM_TOKENS) end - - # Returns atom.upcase - def case_insensitive__atom; -combine_adjacent(*ATOM_TOKENS).upcase end - - # Returns atom?&.upcase - def case_insensitive__atom? - -combine_adjacent(*ATOM_TOKENS).upcase if lookahead?(*ATOM_TOKENS) - end - - # astring = 1*ASTRING-CHAR / string - def astring - lookahead?(*ASTRING_CHARS_TOKENS) ? astring_chars : string - end - - def astring? - lookahead?(*ASTRING_CHARS_TOKENS) ? astring_chars : string? - end - - # Use #label or #label_in to assert specific known labels - # (+tagged-ext-label+ only, not +atom+). - def label(word) - (val = tagged_ext_label) == word and return val - parse_error("unexpected atom %p, expected %p instead", val, word) - end - - # Use #label or #label_in to assert specific known labels - # (+tagged-ext-label+ only, not +atom+). - def label_in(*labels) - lbl = tagged_ext_label and labels.include?(lbl) and return lbl - parse_error("unexpected atom %p, expected one of %s instead", - lbl, labels.join(" or ")) - end - - # expects "OK" or "PREAUTH" and raises InvalidResponseError on failure - def resp_cond_auth__name - lbl = tagged_ext_label and AUTH_CONDS.include? lbl and return lbl - raise InvalidResponseError, "bad response type %p, expected %s" % [ - lbl, AUTH_CONDS.join(" or ") - ] - end - - # expects "OK" or "NO" or "BAD" and raises InvalidResponseError on failure - def resp_cond_state__name - lbl = tagged_ext_label and RESP_COND_STATES.include? lbl and return lbl - raise InvalidResponseError, "bad response type %p, expected %s" % [ - lbl, RESP_COND_STATES.join(" or ") - ] - end - - # nstring = string / nil - def nstring - NIL? ? nil : string - end - - def nstring8 - NIL? ? nil : string8 - end - - def nquoted - NIL? ? nil : quoted - end - - # use where nstring represents "LABEL" values - def case_insensitive__nstring - NIL? ? nil : case_insensitive__string - end - - # tagged-ext-comp = astring / - # tagged-ext-comp *(SP tagged-ext-comp) / - # "(" tagged-ext-comp ")" - # ; Extensions that follow this general - # ; syntax should use nstring instead of - # ; astring when appropriate in the context - # ; of the extension. - # ; Note that a message set or a "number" - # ; can always be represented as an "atom". - # ; A URL should be represented as - # ; a "quoted" string. - def tagged_ext_comp - vals = [] - while true - vals << case lookahead!(*ASTRING_TOKENS, T_LPAR).symbol - when T_LPAR then lpar; ary = tagged_ext_comp; rpar; ary - when T_NUMBER then number - else astring - end - SP? or break - end - vals - end - - # tagged-ext-simple is a subset of atom - # TODO: recognize sequence-set in the lexer - # - # tagged-ext-simple = sequence-set / number / number64 - def tagged_ext_simple - number? || sequence_set - end - - # tagged-ext-val = tagged-ext-simple / - # "(" [tagged-ext-comp] ")" - def tagged_ext_val - if lpar? - _ = peek_rpar? ? [] : tagged_ext_comp - rpar - _ - else - tagged_ext_simple - end - end - - # mailbox = "INBOX" / astring - # ; INBOX is case-insensitive. All case variants of - # ; INBOX (e.g., "iNbOx") MUST be interpreted as INBOX - # ; not as an astring. An astring which consists of - # ; the case-insensitive sequence "I" "N" "B" "O" "X" - # ; is considered to be INBOX and not an astring. - # ; Refer to section 5.1 for further - # ; semantic details of mailbox names. - alias mailbox astring - - # valid number ranges are not enforced by parser - # number64 = 1*DIGIT - # ; Unsigned 63-bit integer - # ; (0 <= n <= 9,223,372,036,854,775,807) - alias number64 number - alias number64? number? - - # valid number ranges are not enforced by parser - # nz-number = digit-nz *DIGIT - # ; Non-zero unsigned 32-bit integer - # ; (0 < n < 4,294,967,296) - alias nz_number number - alias nz_number? number? - - # valid number ranges are not enforced by parser - # nz-number64 = digit-nz *DIGIT - # ; Unsigned 63-bit integer - # ; (0 < n <= 9,223,372,036,854,775,807) - alias nz_number64 nz_number - - # valid number ranges are not enforced by parser - # uniqueid = nz-number - # ; Strictly ascending - alias uniqueid nz_number - - # valid number ranges are not enforced by parser - # - # a 64-bit unsigned integer and is the decimal equivalent for the ID hex - # string used in the web interface and the Gmail API. - alias x_gm_id number - - # [RFC3501 & RFC9051:] - # response = *(continue-req / response-data) response-done - # - # For simplicity, response isn't interpreted as the combination of the - # three response types, but instead represents any individual server - # response. Our simplified interpretation is defined as: - # response = continue-req | response_data | response-tagged - # - # n.b: our "response-tagged" definition parses "greeting" too. - def response - resp = case lookahead!(T_PLUS, T_STAR, *TAG_TOKENS).symbol - when T_PLUS then continue_req - when T_STAR then response_data - else response_tagged - end - accept_spaces # QUIRKY: Ignore trailing space (MS Exchange Server?) - CRLF! - EOF! - resp - end - - # RFC3501 & RFC9051: - # continue-req = "+" SP (resp-text / base64) CRLF - # - # n.b: base64 is valid resp-text. And in the spirit of RFC9051 Appx E 23 - # (and to workaround existing servers), we use the following grammar: - # - # continue-req = "+" (SP (resp-text)) CRLF - def continue_req - PLUS! - ContinuationRequest.new(SP? ? resp_text : ResponseText::EMPTY, @str) - end - - RE_RESPONSE_TYPE = /\G(?:\d+ )?(?#{Patterns::TAGGED_EXT_LABEL})/n - - # [RFC3501:] - # response-data = "*" SP (resp-cond-state / resp-cond-bye / - # mailbox-data / message-data / capability-data) CRLF - # [RFC4466:] - # response-data = "*" SP response-payload CRLF - # response-payload = resp-cond-state / resp-cond-bye / - # mailbox-data / message-data / capability-data - # RFC5161 (ENABLE capability): - # response-data =/ "*" SP enable-data CRLF - # RFC5255 (LANGUAGE capability) - # response-payload =/ language-data - # RFC5255 (I18NLEVEL=1 and I18NLEVEL=2 capabilities) - # response-payload =/ comparator-data - # [RFC9051:] - # response-data = "*" SP (resp-cond-state / resp-cond-bye / - # mailbox-data / message-data / capability-data / - # enable-data) CRLF - # - # [merging in greeting and response-fatal:] - # greeting = "*" SP (resp-cond-auth / resp-cond-bye) CRLF - # response-fatal = "*" SP resp-cond-bye CRLF - # response-data =/ "*" SP (resp-cond-auth / resp-cond-bye) CRLF - # [removing duplicates, this is simply] - # response-payload =/ resp-cond-auth - # - # TODO: remove resp-cond-auth and handle greeting separately - def response_data - STAR!; SP! - m = peek_re(RE_RESPONSE_TYPE) or parse_error("unparsable response") - case m["type"].upcase - when "OK" then resp_cond_state__untagged # RFC3501, RFC9051 - when "FETCH" then message_data__fetch # RFC3501, RFC9051 - when "EXPUNGE" then message_data__expunge # RFC3501, RFC9051 - when "EXISTS" then mailbox_data__exists # RFC3501, RFC9051 - when "ESEARCH" then esearch_response # RFC4731, RFC9051, etc - when "VANISHED" then expunged_resp # RFC7162 - when "UIDFETCH" then uidfetch_resp # (draft) UIDONLY - when "SEARCH" then mailbox_data__search # RFC3501 (obsolete) - when "CAPABILITY" then capability_data__untagged # RFC3501, RFC9051 - when "FLAGS" then mailbox_data__flags # RFC3501, RFC9051 - when "LIST" then mailbox_data__list # RFC3501, RFC9051 - when "STATUS" then mailbox_data__status # RFC3501, RFC9051 - when "NAMESPACE" then namespace_response # RFC2342, RFC9051 - when "ENABLED" then enable_data # RFC5161, RFC9051 - when "BAD" then resp_cond_state__untagged # RFC3501, RFC9051 - when "NO" then resp_cond_state__untagged # RFC3501, RFC9051 - when "PREAUTH" then resp_cond_auth # RFC3501, RFC9051 - when "BYE" then resp_cond_bye # RFC3501, RFC9051 - when "RECENT" then mailbox_data__recent # RFC3501 (obsolete) - when "SORT" then sort_data # RFC5256, RFC7162 - when "THREAD" then thread_data # RFC5256 - when "QUOTA" then quota_response # RFC2087, RFC9208 - when "QUOTAROOT" then quotaroot_response # RFC2087, RFC9208 - when "ID" then id_response # RFC2971 - when "ACL" then acl_data # RFC4314 - when "LISTRIGHTS" then listrights_data # RFC4314 - when "MYRIGHTS" then myrights_data # RFC4314 - when "METADATA" then metadata_resp # RFC5464 - when "LANGUAGE" then language_data # RFC5255 - when "COMPARATOR" then comparator_data # RFC5255 - when "CONVERTED" then message_data__converted # RFC5259 - when "LSUB" then mailbox_data__lsub # RFC3501 (obsolete) - when "XLIST" then mailbox_data__xlist # deprecated - when "NOOP" then response_data__noop - else response_data__unhandled - end - end - - def response_data__unhandled(klass = UntaggedResponse) - num = number?; SP? - type = tagged_ext_label; SP? - text = remaining_unparsed - data = - if num && text then UnparsedNumericResponseData.new(num, text) - elsif text then UnparsedData.new(text) - else num - end - klass.new(type, data, @str) - end - - # reads all the way up until CRLF - def remaining_unparsed - str = @str[@pos...-2] and @pos += str.bytesize - str&.empty? ? nil : str - end - - def response_data__ignored; response_data__unhandled(IgnoredResponse) end - alias response_data__noop response_data__ignored - - alias esearch_response response_data__unhandled - alias expunged_resp response_data__unhandled - alias uidfetch_resp response_data__unhandled - alias listrights_data response_data__unhandled - alias myrights_data response_data__unhandled - alias metadata_resp response_data__unhandled - alias language_data response_data__unhandled - alias comparator_data response_data__unhandled - alias message_data__converted response_data__unhandled - - # RFC3501 & RFC9051: - # response-tagged = tag SP resp-cond-state CRLF - def response_tagged - TaggedResponse.new(tag, *(SP!; resp_cond_state), @str) - end - - # RFC3501 & RFC9051: - # resp-cond-state = ("OK" / "NO" / "BAD") SP resp-text - # - # NOTE: In the spirit of RFC9051 Appx E 23 (and to workaround existing - # servers), we don't require a final SP and instead parse this as: - # - # resp-cond-state = ("OK" / "NO" / "BAD") [SP resp-text] - def resp_cond_state - [resp_cond_state__name, SP? ? resp_text : ResponseText::EMPTY] - end - - def resp_cond_state__untagged - UntaggedResponse.new(*resp_cond_state, @str) - end - - # resp-cond-auth = ("OK" / "PREAUTH") SP resp-text - # - # NOTE: In the spirit of RFC9051 Appx E 23 (and to workaround existing - # servers), we don't require a final SP and instead parse this as: - # - # resp-cond-auth = ("OK" / "PREAUTH") [SP resp-text] - def resp_cond_auth - UntaggedResponse.new(resp_cond_auth__name, - SP? ? resp_text : ResponseText::EMPTY, - @str) - end - - # resp-cond-bye = "BYE" SP resp-text - # - # NOTE: In the spirit of RFC9051 Appx E 23 (and to workaround existing - # servers), we don't require a final SP and instead parse this as: - # - # resp-cond-bye = "BYE" [SP resp-text] - def resp_cond_bye - UntaggedResponse.new(label(BYE), - SP? ? resp_text : ResponseText::EMPTY, - @str) - end - - # message-data = nz-number SP ("EXPUNGE" / ("FETCH" SP msg-att)) - def message_data__fetch - seq = nz_number; SP! - name = label "FETCH"; SP! - data = FetchData.new(seq, msg_att(seq)) - UntaggedResponse.new(name, data, @str) - end - - def response_data__simple_numeric - data = nz_number; SP! - name = tagged_ext_label - UntaggedResponse.new(name, data, @str) - end - - alias message_data__expunge response_data__simple_numeric - alias mailbox_data__exists response_data__simple_numeric - alias mailbox_data__recent response_data__simple_numeric - - # RFC3501 & RFC9051: - # msg-att = "(" (msg-att-dynamic / msg-att-static) - # *(SP (msg-att-dynamic / msg-att-static)) ")" - # - # msg-att-dynamic = "FLAGS" SP "(" [flag-fetch *(SP flag-fetch)] ")" - # RFC5257 (ANNOTATE extension): - # msg-att-dynamic =/ "ANNOTATION" SP - # ( "(" entry-att *(SP entry-att) ")" / - # "(" entry *(SP entry) ")" ) - # RFC7162 (CONDSTORE extension): - # msg-att-dynamic =/ fetch-mod-resp - # fetch-mod-resp = "MODSEQ" SP "(" permsg-modsequence ")" - # RFC8970 (PREVIEW extension): - # msg-att-dynamic =/ "PREVIEW" SP nstring - # - # RFC3501: - # msg-att-static = "ENVELOPE" SP envelope / - # "INTERNALDATE" SP date-time / - # "RFC822" [".HEADER" / ".TEXT"] SP nstring / - # "RFC822.SIZE" SP number / - # "BODY" ["STRUCTURE"] SP body / - # "BODY" section ["<" number ">"] SP nstring / - # "UID" SP uniqueid - # RFC3516 (BINARY extension): - # msg-att-static =/ "BINARY" section-binary SP (nstring / literal8) - # / "BINARY.SIZE" section-binary SP number - # RFC8514 (SAVEDATE extension): - # msg-att-static =/ "SAVEDATE" SP (date-time / nil) - # RFC8474 (OBJECTID extension): - # msg-att-static =/ fetch-emailid-resp / fetch-threadid-resp - # fetch-emailid-resp = "EMAILID" SP "(" objectid ")" - # fetch-threadid-resp = "THREADID" SP ( "(" objectid ")" / nil ) - # RFC9051: - # msg-att-static = "ENVELOPE" SP envelope / - # "INTERNALDATE" SP date-time / - # "RFC822.SIZE" SP number64 / - # "BODY" ["STRUCTURE"] SP body / - # "BODY" section ["<" number ">"] SP nstring / - # "BINARY" section-binary SP (nstring / literal8) / - # "BINARY.SIZE" section-binary SP number / - # "UID" SP uniqueid - # - # Re https://www.rfc-editor.org/errata/eid7246, I'm adding "offset" to the - # official "BINARY" ABNF, like so: - # - # msg-att-static =/ "BINARY" section-binary ["<" number ">"] SP - # (nstring / literal8) - def msg_att(n) - lpar - attr = {} - while true - name = msg_att__label; SP! - val = - case name - when "UID" then uniqueid - when "FLAGS" then flag_list - when "BODY" then body - when /\ABODY\[/ni then nstring - when "BODYSTRUCTURE" then body - when "ENVELOPE" then envelope - when "INTERNALDATE" then date_time - when "RFC822.SIZE" then number64 - when /\ABINARY\[/ni then nstring8 # BINARY, IMAP4rev2 - when /\ABINARY\.SIZE\[/ni then number # BINARY, IMAP4rev2 - when "RFC822" then nstring # not in rev2 - when "RFC822.HEADER" then nstring # not in rev2 - when "RFC822.TEXT" then nstring # not in rev2 - when "MODSEQ" then parens__modseq # CONDSTORE - when "EMAILID" then parens__objectid # OBJECTID - when "THREADID" then nparens__objectid # OBJECTID - when "X-GM-MSGID" then x_gm_id # GMail - when "X-GM-THRID" then x_gm_id # GMail - when "X-GM-LABELS" then x_gm_labels # GMail - else parse_error("unknown attribute `%s' for {%d}", name, n) - end - attr[name] = val - break unless SP? - break if lookahead_rpar? - end - rpar - attr - end - - # appends "[section]" and "" to the base label - def msg_att__label - case (name = tagged_ext_label) - when /\A(?:RFC822(?:\.HEADER|\.TEXT)?)\z/ni - # ignoring "[]" fixes https://bugs.ruby-lang.org/issues/5620 - lbra? and rbra - when "BODY" - peek_lbra? and name << section and - peek_str?("<") and name << gt__number__lt # partial - when "BINARY", "BINARY.SIZE" - name << section_binary - # see https://www.rfc-editor.org/errata/eid7246 and the note above - peek_str?("<") and name << gt__number__lt # partial - end - name - end - - # this represents the partial size for BODY or BINARY - alias gt__number__lt atom - - # RFC3501 & RFC9051: - # envelope = "(" env-date SP env-subject SP env-from SP - # env-sender SP env-reply-to SP env-to SP env-cc SP - # env-bcc SP env-in-reply-to SP env-message-id ")" - def envelope - @lex_state = EXPR_DATA - lpar; date = env_date - SP!; subject = env_subject - SP!; from = env_from - SP!; sender = env_sender - SP!; reply_to = env_reply_to - SP!; to = env_to - SP!; cc = env_cc - SP!; bcc = env_bcc - SP!; in_reply_to = env_in_reply_to - SP!; message_id = env_message_id - rpar - Envelope.new(date, subject, from, sender, reply_to, - to, cc, bcc, in_reply_to, message_id) - ensure - @lex_state = EXPR_BEG - end - - # env-date = nstring - # env-subject = nstring - # env-in-reply-to = nstring - # env-message-id = nstring - alias env_date nstring - alias env_subject nstring - alias env_in_reply_to nstring - alias env_message_id nstring - - # env-from = "(" 1*address ")" / nil - # env-sender = "(" 1*address ")" / nil - # env-reply-to = "(" 1*address ")" / nil - # env-to = "(" 1*address ")" / nil - # env-cc = "(" 1*address ")" / nil - # env-bcc = "(" 1*address ")" / nil - def nlist__address - return if NIL? - lpar; list = [address]; list << address until (quirky_SP?; rpar?) - list - end - - alias env_from nlist__address - alias env_sender nlist__address - alias env_reply_to nlist__address - alias env_to nlist__address - alias env_cc nlist__address - alias env_bcc nlist__address - - # Used when servers erroneously send an extra SP. - # - # As of 2023-11-28, Outlook.com (still) sends SP - # between +address+ in env-* lists. - alias quirky_SP? SP? - - # date-time = DQUOTE date-day-fixed "-" date-month "-" date-year - # SP time SP zone DQUOTE - alias date_time quoted - alias ndatetime nquoted - - # RFC-3501 & RFC-9051: - # body = "(" (body-type-1part / body-type-mpart) ")" - def body - @lex_state = EXPR_DATA - lpar; result = peek_lpar? ? body_type_mpart : body_type_1part; rpar - result - ensure - @lex_state = EXPR_BEG - end - alias lookahead_body? lookahead_lpar? - - # RFC-3501 & RFC9051: - # body-type-1part = (body-type-basic / body-type-msg / body-type-text) - # [SP body-ext-1part] - def body_type_1part - # This regexp peek is a performance optimization. - # The lookahead fallback would work fine too. - m = peek_re(/\G(?: - (? "TEXT" \s "[^"]+" ) - |(? "MESSAGE" \s "(?:RFC822|GLOBAL)" ) - |(? "[^"]+" \s "[^"]+" ) - |(? "MIXED" ) - )/nix) - choice = m&.named_captures&.compact&.keys&.first - # In practice, the following line should never be used. But the ABNF - # *does* allow literals, and this will handle them. - choice ||= lookahead_case_insensitive__string! - case choice - when "BASIC" then body_type_basic # => BodyTypeBasic - when "MESSAGE" then body_type_msg # => BodyTypeMessage | BodyTypeBasic - when "TEXT" then body_type_text # => BodyTypeText - when "MIXED" then body_type_mixed # => BodyTypeMultipart (server bug) - else body_type_basic # might be a bug; server's or ours? - end - end - - # RFC-3501 & RFC9051: - # body-type-basic = media-basic SP body-fields - def body_type_basic - type = media_basic # n.b. "basic" type isn't enforced here - if lookahead_rpar? then return BodyTypeBasic.new(*type) end # invalid - SP!; flds = body_fields - SP? and exts = body_ext_1part - BodyTypeBasic.new(*type, *flds, *exts) - end - - # RFC-3501 & RFC-9051: - # body-type-text = media-text SP body-fields SP body-fld-lines - def body_type_text - type = media_text - SP!; flds = body_fields - SP!; lines = body_fld_lines - SP? and exts = body_ext_1part - BodyTypeText.new(*type, *flds, lines, *exts) - end - - # RFC-3501 & RFC-9051: - # body-type-msg = media-message SP body-fields SP envelope - # SP body SP body-fld-lines - def body_type_msg - # n.b. "message/rfc822" type isn't enforced here - type = media_message - SP!; flds = body_fields - - # Sometimes servers send body-type-basic when body-type-msg should be. - # E.g: when a message/rfc822 part has "Content-Disposition: attachment". - # - # * SP "(" --> SP envelope --> continue as body-type-msg - # * ")" --> no body-ext-1part --> completed body-type-basic - # * SP nstring --> SP body-fld-md5 - # --> SP body-ext-1part --> continue as body-type-basic - # - # It's probably better to return BodyTypeBasic---even for - # "message/rfc822"---than BodyTypeMessage with invalid fields. - unless peek_str?(" (") - SP? and exts = body_ext_1part - return BodyTypeBasic.new(*type, *flds, *exts) - end - - SP!; env = envelope - SP!; bdy = body - SP!; lines = body_fld_lines - SP? and exts = body_ext_1part - BodyTypeMessage.new(*type, *flds, env, bdy, lines, *exts) - end - - # This is a malformed body-type-mpart with no subparts. - def body_type_mixed - # warn "malformed body-type-mpart: multipart/mixed with no parts." - type = media_subtype # => "MIXED" - SP? and exts = body_ext_mpart - BodyTypeMultipart.new("MULTIPART", type, nil, *exts) - end - - # RFC-3501 & RFC-9051: - # body-type-mpart = 1*body SP media-subtype - # [SP body-ext-mpart] - def body_type_mpart - parts = [body]; parts << body until SP?; msubtype = media_subtype - SP? and exts = body_ext_mpart - BodyTypeMultipart.new("MULTIPART", msubtype, parts, *exts) - end - - # n.b. this handles both type and subtype - # - # RFC-3501 vs RFC-9051: - # media-basic = ((DQUOTE ("APPLICATION" / "AUDIO" / "IMAGE" / - # "MESSAGE" / - # "VIDEO") DQUOTE) / string) SP media-subtype - # media-basic = ((DQUOTE ("APPLICATION" / "AUDIO" / "IMAGE" / - # "FONT" / "MESSAGE" / "MODEL" / - # "VIDEO") DQUOTE) / string) SP media-subtype - # - # media-message = DQUOTE "MESSAGE" DQUOTE SP - # DQUOTE "RFC822" DQUOTE - # media-message = DQUOTE "MESSAGE" DQUOTE SP - # DQUOTE ("RFC822" / "GLOBAL") DQUOTE - # - # RFC-3501 & RFC-9051: - # media-text = DQUOTE "TEXT" DQUOTE SP media-subtype - # media-subtype = string - def media_type - mtype = case_insensitive__string - SP? or return mtype, nil # ??? quirky! - msubtype = media_subtype - return mtype, msubtype - end - - # TODO: check types - alias media_basic media_type # */* --- catchall - alias media_message media_type # message/rfc822, message/global - alias media_text media_type # text/* - - alias media_subtype case_insensitive__string - - # RFC-3501 & RFC-9051: - # body-fields = body-fld-param SP body-fld-id SP body-fld-desc SP - # body-fld-enc SP body-fld-octets - def body_fields - fields = [] - fields << body_fld_param; SP! - fields << body_fld_id; SP! - fields << body_fld_desc; SP! - fields << body_fld_enc; SP! - fields << body_fld_octets - fields - end - - # RFC3501, RFC9051: - # body-fld-param = "(" string SP string *(SP string SP string) ")" / nil - def body_fld_param - quirky_SP? # See comments on test_bodystructure_extra_space - return if NIL? - param = {} - lpar - name = case_insensitive__string; SP!; param[name] = string - while SP? - name = case_insensitive__string; SP!; param[name] = string - end - rpar - param - end - - # RFC2060 - # body_ext_1part ::= body_fld_md5 [SPACE body_fld_dsp - # [SPACE body_fld_lang - # [SPACE 1#body_extension]]] - # ;; MUST NOT be returned on non-extensible - # ;; "BODY" fetch - # RFC3501 & RFC9051 - # body-ext-1part = body-fld-md5 [SP body-fld-dsp [SP body-fld-lang - # [SP body-fld-loc *(SP body-extension)]]] - # ; MUST NOT be returned on non-extensible - # ; "BODY" fetch - def body_ext_1part - fields = []; fields << body_fld_md5 - SP? or return fields; fields << body_fld_dsp - SP? or return fields; fields << body_fld_lang - SP? or return fields; fields << body_fld_loc - SP? or return fields; fields << body_extensions - fields - end - - # RFC-2060: - # body_ext_mpart = body_fld_param [SP body_fld_dsp SP body_fld_lang - # [SP 1#body_extension]] - # ;; MUST NOT be returned on non-extensible - # ;; "BODY" fetch - # RFC-3501 & RFC-9051: - # body-ext-mpart = body-fld-param [SP body-fld-dsp [SP body-fld-lang - # [SP body-fld-loc *(SP body-extension)]]] - # ; MUST NOT be returned on non-extensible - # ; "BODY" fetch - def body_ext_mpart - fields = []; fields << body_fld_param - SP? or return fields; fields << body_fld_dsp - SP? or return fields; fields << body_fld_lang - SP? or return fields; fields << body_fld_loc - SP? or return fields; fields << body_extensions - fields - end - - alias body_fld_desc nstring - alias body_fld_id nstring - alias body_fld_loc nstring - alias body_fld_lines number64 # number in 3501, number64 in 9051 - alias body_fld_md5 nstring - alias body_fld_octets number - - # RFC-3501 & RFC-9051: - # body-fld-enc = (DQUOTE ("7BIT" / "8BIT" / "BINARY" / "BASE64"/ - # "QUOTED-PRINTABLE") DQUOTE) / string - alias body_fld_enc case_insensitive__string - - # body-fld-dsp = "(" string SP body-fld-param ")" / nil - def body_fld_dsp - return if NIL? - lpar; dsp_type = case_insensitive__string - SP!; param = body_fld_param - rpar - ContentDisposition.new(dsp_type, param) - end - - # body-fld-lang = nstring / "(" string *(SP string) ")" - def body_fld_lang - if lpar? - result = [case_insensitive__string] - result << case_insensitive__string while SP? - rpar - result - else - case_insensitive__nstring - end - end - - # body-extension *(SP body-extension) - def body_extensions - result = [] - result << body_extension; while SP? do result << body_extension end - result - end - - # body-extension = nstring / number / number64 / - # "(" body-extension *(SP body-extension) ")" - # ; Future expansion. Client implementations - # ; MUST accept body-extension fields. Server - # ; implementations MUST NOT generate - # ; body-extension fields except as defined by - # ; future Standard or Standards Track - # ; revisions of this specification. - def body_extension - if (uint = number64?) then uint - elsif lpar? then exts = body_extensions; rpar; exts - else nstring - end - end - - # section = "[" [section-spec] "]" - def section - str = +lbra - str << section_spec unless peek_rbra? - str << rbra - end - - # section-binary = "[" [section-part] "]" - def section_binary - str = +lbra - str << section_part unless peek_rbra? - str << rbra - end - - # section-spec = section-msgtext / (section-part ["." section-text]) - # section-msgtext = "HEADER" / - # "HEADER.FIELDS" [".NOT"] SP header-list / - # "TEXT" - # ; top-level or MESSAGE/RFC822 or - # ; MESSAGE/GLOBAL part - # section-part = nz-number *("." nz-number) - # ; body part reference. - # ; Allows for accessing nested body parts. - # section-text = section-msgtext / "MIME" - # ; text other than actual body part (headers, - # ; etc.) - # - # n.b: we could "cheat" here and just grab all text inside the brackets, - # but literals would need special treatment. - def section_spec - str = "".b - str << atom # grabs everything up to "SP header-list" or "]" - str << " " << header_list if SP? - str - end - - # header-list = "(" header-fld-name *(SP header-fld-name) ")" - def header_list - str = +"" - str << lpar << header_fld_name - str << " " << header_fld_name while SP? - str << rpar - end - - # section-part = nz-number *("." nz-number) - # ; body part reference. - # ; Allows for accessing nested body parts. - alias section_part atom - - # RFC3501 & RFC9051: - # header-fld-name = astring - # - # NOTE: Previously, Net::IMAP recreated the raw original source string. - # Now, it grabs the raw encoded value using @str and @pos. A future - # version may simply return the decoded astring value. Although that is - # technically incompatible, it should almost never make a difference: all - # standard header field names are valid atoms: - # - # https://www.iana.org/assignments/message-headers/message-headers.xhtml - # - # Although RFC3501 allows any astring, RFC5322-valid header names are one - # or more of the printable US-ASCII characters, except SP and colon. So - # empty string isn't valid, and literals aren't needed and should not be - # used. This is explicitly unchanged by [I18N-HDRS] (RFC6532). - # - # RFC5233: - # optional-field = field-name ":" unstructured CRLF - # field-name = 1*ftext - # ftext = %d33-57 / ; Printable US-ASCII - # %d59-126 ; characters not including - # ; ":". - def header_fld_name - assert_no_lookahead - start = @pos - astring - end_pos = @token ? @pos - 1 : @pos - @str[start...end_pos] - end - - # mailbox-data = "FLAGS" SP flag-list / "LIST" SP mailbox-list / - # "LSUB" SP mailbox-list / "SEARCH" *(SP nz-number) / - # "STATUS" SP mailbox SP "(" [status-att-list] ")" / - # number SP "EXISTS" / number SP "RECENT" - - def mailbox_data__flags - name = label("FLAGS") - SP! - UntaggedResponse.new(name, flag_list, @str) - end - - def mailbox_data__list - name = label_in("LIST", "LSUB", "XLIST") - SP! - UntaggedResponse.new(name, mailbox_list, @str) - end - alias mailbox_data__lsub mailbox_data__list - alias mailbox_data__xlist mailbox_data__list - - # mailbox-list = "(" [mbx-list-flags] ")" SP - # (DQUOTE QUOTED-CHAR DQUOTE / nil) SP mailbox - # [SP mbox-list-extended] - # ; This is the list information pointed to by the ABNF - # ; item "mailbox-data", which is defined above - def mailbox_list - lpar; attr = peek_rpar? ? [] : mbx_list_flags; rpar - SP!; delim = nquoted - SP!; name = mailbox - # TODO: mbox-list-extended - MailboxList.new(attr, delim, name) - end - - def quota_response - # If quota never established, get back - # `NO Quota root does not exist'. - # If quota removed, get `()' after the - # folder spec with no mention of `STORAGE'. - token = match(T_ATOM) - name = token.value.upcase - match(T_SPACE) - mailbox = astring - match(T_SPACE) - match(T_LPAR) - token = lookahead - case token.symbol - when T_RPAR - shift_token - data = MailboxQuota.new(mailbox, nil, nil) - return UntaggedResponse.new(name, data, @str) - when T_ATOM - shift_token - match(T_SPACE) - token = match(T_NUMBER) - usage = token.value - match(T_SPACE) - token = match(T_NUMBER) - quota = token.value - match(T_RPAR) - data = MailboxQuota.new(mailbox, usage, quota) - return UntaggedResponse.new(name, data, @str) - else - parse_error("unexpected token %s", token.symbol) - end - end - - def quotaroot_response - # Similar to getquota, but only admin can use getquota. - token = match(T_ATOM) - name = token.value.upcase - match(T_SPACE) - mailbox = astring - quotaroots = [] - while true - token = lookahead - break unless token.symbol == T_SPACE - shift_token - quotaroots.push(astring) - end - data = MailboxQuotaRoot.new(mailbox, quotaroots) - return UntaggedResponse.new(name, data, @str) - end - - # acl-data = "ACL" SP mailbox *(SP identifier SP rights) - def acl_data - token = match(T_ATOM) - name = token.value.upcase - match(T_SPACE) - mailbox = astring - data = [] - token = lookahead - if token.symbol == T_SPACE - shift_token - while true - token = lookahead - case token.symbol - when T_CRLF - break - when T_SPACE - shift_token - end - user = astring - match(T_SPACE) - rights = astring - data.push(MailboxACLItem.new(user, rights, mailbox)) - end - end - return UntaggedResponse.new(name, data, @str) - end - - # RFC3501: - # mailbox-data = "SEARCH" *(SP nz-number) / ... - # RFC5256: SORT - # sort-data = "SORT" *(SP nz-number) - # RFC7162: CONDSTORE, QRESYNC - # mailbox-data =/ "SEARCH" [1*(SP nz-number) SP - # search-sort-mod-seq] - # sort-data = "SORT" [1*(SP nz-number) SP - # search-sort-mod-seq] - # ; Updates the SORT response from RFC 5256. - # search-sort-mod-seq = "(" "MODSEQ" SP mod-sequence-value ")" - # RFC9051: - # mailbox-data = obsolete-search-response / ... - # obsolete-search-response = "SEARCH" *(SP nz-number) - def mailbox_data__search - name = label_in("SEARCH", "SORT") - data = [] - while _ = SP? && nz_number? do data << _ end - if lpar? - label("MODSEQ"); SP! - modseq = mod_sequence_value - rpar - end - data = SearchResult.new(data, modseq: modseq) - UntaggedResponse.new(name, data, @str) - end - alias sort_data mailbox_data__search - - # RFC5256: THREAD - # thread-data = "THREAD" [SP 1*thread-list] - def thread_data - name = label("THREAD") - threads = [] - if SP? - threads << thread_list while lookahead_thread_list? - end - UntaggedResponse.new(name, threads, @str) - end - - alias lookahead_thread_list? lookahead_lpar? - alias lookahead_thread_nested? lookahead_thread_list? - - # RFC5256: THREAD - # thread-list = "(" (thread-members / thread-nested) ")" - def thread_list - lpar - thread = if lookahead_thread_nested? - ThreadMember.new(nil, thread_nested) - else - thread_members - end - rpar - thread - end - - # RFC5256: THREAD - # thread-members = nz-number *(SP nz-number) [SP thread-nested] - def thread_members - members = [] - members << nz_number # thread root - while SP? - case lookahead!(T_NUMBER, T_LPAR).symbol - when T_NUMBER then members << nz_number - else nested = thread_nested; break - end - end - members.reverse.inject(nested || []) {|subthreads, number| - [ThreadMember.new(number, subthreads)] - }.first - end - - # RFC5256: THREAD - # thread-nested = 2*thread-list - def thread_nested - nested = [thread_list, thread_list] - while lookahead_thread_list? do nested << thread_list end - nested - end - - # mailbox-data =/ "STATUS" SP mailbox SP "(" [status-att-list] ")" - def mailbox_data__status - resp_name = label("STATUS"); SP! - mbox_name = mailbox; SP! - lpar; attr = status_att_list; rpar - UntaggedResponse.new(resp_name, StatusData.new(mbox_name, attr), @str) - end - - # RFC3501 - # status-att-list = status-att SP number *(SP status-att SP number) - # RFC4466, RFC9051, and RFC3501 Errata - # status-att-list = status-att-val *(SP status-att-val) - def status_att_list - attrs = [status_att_val] - while SP? do attrs << status_att_val end - attrs.to_h - end - - # RFC3501 Errata: - # status-att-val = ("MESSAGES" SP number) / ("RECENT" SP number) / - # ("UIDNEXT" SP nz-number) / ("UIDVALIDITY" SP nz-number) / - # ("UNSEEN" SP number) - # RFC4466: - # status-att-val = ("MESSAGES" SP number) / - # ("RECENT" SP number) / - # ("UIDNEXT" SP nz-number) / - # ("UIDVALIDITY" SP nz-number) / - # ("UNSEEN" SP number) - # ;; Extensions to the STATUS responses - # ;; should extend this production. - # ;; Extensions should use the generic - # ;; syntax defined by tagged-ext. - # RFC9051: - # status-att-val = ("MESSAGES" SP number) / - # ("UIDNEXT" SP nz-number) / - # ("UIDVALIDITY" SP nz-number) / - # ("UNSEEN" SP number) / - # ("DELETED" SP number) / - # ("SIZE" SP number64) - # ; Extensions to the STATUS responses - # ; should extend this production. - # ; Extensions should use the generic - # ; syntax defined by tagged-ext. - # RFC7162: - # status-att-val =/ "HIGHESTMODSEQ" SP mod-sequence-valzer - # ;; Extends non-terminal defined in [RFC4466]. - # ;; Value 0 denotes that the mailbox doesn't - # ;; support persistent mod-sequences - # ;; as described in Section 3.1.2.2. - # RFC7889: - # status-att-val =/ "APPENDLIMIT" SP (number / nil) - # ;; status-att-val is defined in RFC 4466 - # RFC8438: - # status-att-val =/ "SIZE" SP number64 - # RFC8474: - # status-att-val =/ "MAILBOXID" SP "(" objectid ")" - # ; follows tagged-ext production from [RFC4466] - def status_att_val - key = tagged_ext_label - SP! - val = - case key - when "MESSAGES" then number # RFC3501, RFC9051 - when "UNSEEN" then number # RFC3501, RFC9051 - when "DELETED" then number # RFC3501, RFC9051 - when "UIDNEXT" then nz_number # RFC3501, RFC9051 - when "UIDVALIDITY" then nz_number # RFC3501, RFC9051 - when "RECENT" then number # RFC3501 (obsolete) - when "SIZE" then number64 # RFC8483, RFC9051 - when "HIGHESTMODSEQ" then mod_sequence_valzer # RFC7162 - when "MAILBOXID" then parens__objectid # RFC8474 - else - number? || ExtensionData.new(tagged_ext_val) - end - [key, val] - end - - # The presence of "IMAP4rev1" or "IMAP4rev2" is unenforced here. - # The grammar rule is used by both response-data and resp-text-code. - # But this method only returns UntaggedResponse (response-data). - # - # RFC3501: - # capability-data = "CAPABILITY" *(SP capability) SP "IMAP4rev1" - # *(SP capability) - # RFC9051: - # capability-data = "CAPABILITY" *(SP capability) SP "IMAP4rev2" - # *(SP capability) - def capability_data__untagged - UntaggedResponse.new label("CAPABILITY"), capability__list, @str - end - - # enable-data = "ENABLED" *(SP capability) - def enable_data - UntaggedResponse.new label("ENABLED"), capability__list, @str - end - - # As a workaround for buggy servers, allow a trailing SP: - # *(SP capability) [SP] - def capability__list - list = []; while SP? && (capa = capability?) do list << capa end; list - end - - alias resp_code__capability capability__list - - # capability = ("AUTH=" auth-type) / atom - # ; New capabilities MUST begin with "X" or be - # ; registered with IANA as standard or - # ; standards-track - alias capability case_insensitive__atom - alias capability? case_insensitive__atom? - - def id_response - token = match(T_ATOM) - name = token.value.upcase - match(T_SPACE) - token = match(T_LPAR, T_NIL) - if token.symbol == T_NIL - return UntaggedResponse.new(name, nil, @str) - else - data = {} - while true - token = lookahead - case token.symbol - when T_RPAR - shift_token - break - when T_SPACE - shift_token - next - else - key = string - match(T_SPACE) - val = nstring - data[key] = val - end - end - return UntaggedResponse.new(name, data, @str) - end - end - - # namespace-response = "NAMESPACE" SP namespace - # SP namespace SP namespace - # ; The first Namespace is the Personal Namespace(s). - # ; The second Namespace is the Other Users' - # ; Namespace(s). - # ; The third Namespace is the Shared Namespace(s). - def namespace_response - name = label("NAMESPACE") - @lex_state = EXPR_DATA - data = Namespaces.new((SP!; namespace), - (SP!; namespace), - (SP!; namespace)) - UntaggedResponse.new(name, data, @str) - ensure - @lex_state = EXPR_BEG - end - - # namespace = nil / "(" 1*namespace-descr ")" - def namespace - NIL? and return [] - lpar - list = [namespace_descr] - list << namespace_descr until rpar? - list - end - - # namespace-descr = "(" string SP - # (DQUOTE QUOTED-CHAR DQUOTE / nil) - # [namespace-response-extensions] ")" - def namespace_descr - lpar - prefix = string; SP! - delimiter = nquoted # n.b: should only accept single char - extensions = namespace_response_extensions - rpar - Namespace.new(prefix, delimiter, extensions) - end - - # namespace-response-extensions = *namespace-response-extension - # namespace-response-extension = SP string SP - # "(" string *(SP string) ")" - def namespace_response_extensions - data = {} - while SP? - name = string; SP! - lpar - data[name] ||= [] - data[name] << string - data[name] << string while SP? - rpar - end - data - end - - # TEXT-CHAR = - # RFC3501: - # text = 1*TEXT-CHAR - # RFC9051: - # text = 1*(TEXT-CHAR / UTF8-2 / UTF8-3 / UTF8-4) - # ; Non-ASCII text can only be returned - # ; after ENABLE IMAP4rev2 command - def text - match_re(TEXT_REGEXP, "text")[0].force_encoding("UTF-8") - end - - # an "accept" versiun of #text - def text? - accept_re(TEXT_REGEXP)&.[](0)&.force_encoding("UTF-8") - end - - # RFC3501: - # resp-text = ["[" resp-text-code "]" SP] text - # RFC9051: - # resp-text = ["[" resp-text-code "]" SP] [text] - # - # We leniently re-interpret this as - # resp-text = ["[" resp-text-code "]" [SP [text]] / [text] - def resp_text - if lbra? - code = resp_text_code; rbra - ResponseText.new(code, SP? && text? || "") - else - ResponseText.new(nil, text? || "") - end - end - - # RFC3501 (See https://www.rfc-editor.org/errata/rfc3501): - # resp-text-code = "ALERT" / - # "BADCHARSET" [SP "(" charset *(SP charset) ")" ] / - # capability-data / "PARSE" / - # "PERMANENTFLAGS" SP "(" [flag-perm *(SP flag-perm)] ")" / - # "READ-ONLY" / "READ-WRITE" / "TRYCREATE" / - # "UIDNEXT" SP nz-number / "UIDVALIDITY" SP nz-number / - # "UNSEEN" SP nz-number / - # atom [SP 1*] - # capability-data = "CAPABILITY" *(SP capability) SP "IMAP4rev1" - # *(SP capability) - # - # RFC5530: - # resp-text-code =/ "UNAVAILABLE" / "AUTHENTICATIONFAILED" / - # "AUTHORIZATIONFAILED" / "EXPIRED" / - # "PRIVACYREQUIRED" / "CONTACTADMIN" / "NOPERM" / - # "INUSE" / "EXPUNGEISSUED" / "CORRUPTION" / - # "SERVERBUG" / "CLIENTBUG" / "CANNOT" / - # "LIMIT" / "OVERQUOTA" / "ALREADYEXISTS" / - # "NONEXISTENT" - # RFC9051: - # resp-text-code = "ALERT" / - # "BADCHARSET" [SP "(" charset *(SP charset) ")" ] / - # capability-data / "PARSE" / - # "PERMANENTFLAGS" SP "(" [flag-perm *(SP flag-perm)] ")" / - # "READ-ONLY" / "READ-WRITE" / "TRYCREATE" / - # "UIDNEXT" SP nz-number / "UIDVALIDITY" SP nz-number / - # resp-code-apnd / resp-code-copy / "UIDNOTSTICKY" / - # "UNAVAILABLE" / "AUTHENTICATIONFAILED" / - # "AUTHORIZATIONFAILED" / "EXPIRED" / - # "PRIVACYREQUIRED" / "CONTACTADMIN" / "NOPERM" / - # "INUSE" / "EXPUNGEISSUED" / "CORRUPTION" / - # "SERVERBUG" / "CLIENTBUG" / "CANNOT" / - # "LIMIT" / "OVERQUOTA" / "ALREADYEXISTS" / - # "NONEXISTENT" / "NOTSAVED" / "HASCHILDREN" / - # "CLOSED" / - # "UNKNOWN-CTE" / - # atom [SP 1*] - # capability-data = "CAPABILITY" *(SP capability) SP "IMAP4rev2" - # *(SP capability) - # - # RFC4315 (UIDPLUS), RFC9051 (IMAP4rev2): - # resp-code-apnd = "APPENDUID" SP nz-number SP append-uid - # resp-code-copy = "COPYUID" SP nz-number SP uid-set SP uid-set - # resp-text-code =/ resp-code-apnd / resp-code-copy / "UIDNOTSTICKY" - # - # RFC7162 (CONDSTORE): - # resp-text-code =/ "HIGHESTMODSEQ" SP mod-sequence-value / - # "NOMODSEQ" / - # "MODIFIED" SP sequence-set - # RFC7162 (QRESYNC): - # resp-text-code =/ "CLOSED" - # - # RFC8474: OBJECTID - # resp-text-code =/ "MAILBOXID" SP "(" objectid ")" - def resp_text_code - name = resp_text_code__name - data = - case name - when "CAPABILITY" then resp_code__capability - when "PERMANENTFLAGS" then SP? ? flag_perm__list : [] - when "UIDNEXT" then SP!; nz_number - when "UIDVALIDITY" then SP!; nz_number - when "UNSEEN" then SP!; nz_number # rev1 only - when "APPENDUID" then SP!; resp_code_apnd__data # rev2, UIDPLUS - when "COPYUID" then SP!; resp_code_copy__data # rev2, UIDPLUS - when "BADCHARSET" then SP? ? charset__list : [] - when "ALERT", "PARSE", "READ-ONLY", "READ-WRITE", "TRYCREATE", - "UNAVAILABLE", "AUTHENTICATIONFAILED", "AUTHORIZATIONFAILED", - "EXPIRED", "PRIVACYREQUIRED", "CONTACTADMIN", "NOPERM", "INUSE", - "EXPUNGEISSUED", "CORRUPTION", "SERVERBUG", "CLIENTBUG", "CANNOT", - "LIMIT", "OVERQUOTA", "ALREADYEXISTS", "NONEXISTENT", "CLOSED", - "NOTSAVED", "UIDNOTSTICKY", "UNKNOWN-CTE", "HASCHILDREN" - when "NOMODSEQ" then nil # CONDSTORE - when "HIGHESTMODSEQ" then SP!; mod_sequence_value # CONDSTORE - when "MODIFIED" then SP!; sequence_set # CONDSTORE - when "MAILBOXID" then SP!; parens__objectid # RFC8474: OBJECTID - else - SP? and text_chars_except_rbra - end - ResponseCode.new(name, data) - end - - alias resp_text_code__name case_insensitive__atom - - # 1* - def text_chars_except_rbra - match_re(CTEXT_REGEXP, '1*')[0] - end - - # "(" charset *(SP charset) ")" - def charset__list - lpar; list = [charset]; while SP? do list << charset end; rpar; list - end - - # already matched: "APPENDUID" - # - # +UIDPLUS+ ABNF:: https://www.rfc-editor.org/rfc/rfc4315.html#section-4 - # resp-code-apnd = "APPENDUID" SP nz-number SP append-uid - # append-uid = uniqueid - # append-uid =/ uid-set - # ; only permitted if client uses [MULTIAPPEND] - # ; to append multiple messages. - # - # n.b, uniqueid ⊂ uid-set. To avoid inconsistent return types, we always - # match uid_set even if that returns a single-member array. - def resp_code_apnd__data - validity = number; SP! - dst_uids = uid_set # uniqueid ⊂ uid-set - AppendUID(validity, dst_uids) - end - - # already matched: "COPYUID" - # - # resp-code-copy = "COPYUID" SP nz-number SP uid-set SP uid-set - def resp_code_copy__data - validity = number; SP! - src_uids = uid_set; SP! - dst_uids = uid_set - CopyUID(validity, src_uids, dst_uids) - end - - def AppendUID(...) DeprecatedUIDPlus(...) || AppendUIDData.new(...) end - def CopyUID(...) DeprecatedUIDPlus(...) || CopyUIDData.new(...) end - - # TODO: remove this code in the v0.6.0 release - def DeprecatedUIDPlus(validity, src_uids = nil, dst_uids) - return unless config.parser_use_deprecated_uidplus_data - compact_uid_sets = [src_uids, dst_uids].compact - count = compact_uid_sets.map { _1.count_with_duplicates }.max - max = config.parser_max_deprecated_uidplus_data_size - if count <= max - src_uids &&= src_uids.each_ordered_number.to_a - dst_uids = dst_uids.each_ordered_number.to_a - UIDPlusData.new(validity, src_uids, dst_uids) - elsif config.parser_use_deprecated_uidplus_data != :up_to_max_size - parse_error("uid-set is too large: %d > %d", count, max) - end - end - - ADDRESS_REGEXP = /\G - \( (?: NIL | #{Patterns::QUOTED_rev2} ) # 1: NAME - \s (?: NIL | #{Patterns::QUOTED_rev2} ) # 2: ROUTE - \s (?: NIL | #{Patterns::QUOTED_rev2} ) # 3: MAILBOX - \s (?: NIL | #{Patterns::QUOTED_rev2} ) # 4: HOST - \) - /nix - - # address = "(" addr-name SP addr-adl SP addr-mailbox SP - # addr-host ")" - # addr-adl = nstring - # addr-host = nstring - # addr-mailbox = nstring - # addr-name = nstring - def address - if (match = accept_re(ADDRESS_REGEXP)) - # note that "NIL" isn't captured by the regexp - name, route, mailbox, host = match.captures - .map { Patterns.unescape_quoted _1 } - else # address may include literals - lpar; name = addr_name - SP!; route = addr_adl - SP!; mailbox = addr_mailbox - SP!; host = addr_host - rpar - end - Address.new(name, route, mailbox, host) - end - - alias addr_adl nstring - alias addr_host nstring - alias addr_mailbox nstring - alias addr_name nstring - - # flag-list = "(" [flag *(SP flag)] ")" - def flag_list - if (match = accept_re(Patterns::FLAG_LIST)) - match[1].split(nil) - .map! { _1.delete_prefix!("\\") ? _1.capitalize.to_sym : _1 } - else - quirky__flag_list "flags-list" - end - end - - # "(" [flag-perm *(SP flag-perm)] ")" - def flag_perm__list - if (match = accept_re(Patterns::FLAG_PERM_LIST)) - match[1].split(nil) - .map! { _1.delete_prefix!("\\") ? _1.capitalize.to_sym : _1 } - else - quirky__flag_list "PERMANENTFLAGS flag-perm list" - end - end - - # This allows illegal "]" in flag names (Gmail), - # or "\*" in a FLAGS response (greenmail). - def quirky__flag_list(name) - match_re(Patterns::QUIRKY_FLAGS_LIST, "quirks mode #{name}")[1] - .scan(Patterns::QUIRKY_FLAG) - .map! { _1.delete_prefix!("\\") ? _1.capitalize.to_sym : _1 } - end - - # See Patterns::MBX_LIST_FLAGS - def mbx_list_flags - match_re(Patterns::MBX_LIST_FLAGS, "mbx-list-flags")[1] - .split(nil) - .map! { _1.delete_prefix!("\\"); _1.capitalize.to_sym } - end - - # See https://developers.google.com/gmail/imap/imap-extensions - def x_gm_label; accept(T_BSLASH) ? atom.capitalize.to_sym : astring end - - # See https://developers.google.com/gmail/imap/imap-extensions - def x_gm_labels - lpar; return [] if rpar? - labels = [] - labels << x_gm_label - labels << x_gm_label while SP? - rpar - labels - end - - # See https://www.rfc-editor.org/errata/rfc3501 - # - # charset = atom / quoted - def charset; quoted? || atom end - - # RFC7162: - # mod-sequence-value = 1*DIGIT - # ;; Positive unsigned 63-bit integer - # ;; (mod-sequence) - # ;; (1 <= n <= 9,223,372,036,854,775,807). - alias mod_sequence_value nz_number64 - - # RFC7162: - # permsg-modsequence = mod-sequence-value - # ;; Per-message mod-sequence. - alias permsg_modsequence mod_sequence_value - - # RFC7162: - # mod-sequence-valzer = "0" / mod-sequence-value - alias mod_sequence_valzer number64 - - def parens__modseq; lpar; _ = permsg_modsequence; rpar; _ end - - # RFC8474: - # objectid = 1*255(ALPHA / DIGIT / "_" / "-") - # ; characters in object identifiers are case - # ; significant - alias objectid atom - - def parens__objectid; lpar; _ = objectid; rpar; _ end - def nparens__objectid; NIL? ? nil : parens__objectid end - - # RFC-4315 (UIDPLUS) or RFC9051 (IMAP4rev2): - # uid-set = (uniqueid / uid-range) *("," uid-set) - # uid-range = (uniqueid ":" uniqueid) - # ; two uniqueid values and all values - # ; between these two regardless of order. - # ; Example: 2:4 and 4:2 are equivalent. - # uniqueid = nz-number - # ; Strictly ascending - def uid_set - set = sequence_set - parse_error("uid-set cannot contain '*'") if set.include_star? - set - end - - def nil_atom - match(T_NIL) - return nil - end - - SPACES_REGEXP = /\G */n - - # The RFC is very strict about this and usually we should be too. - # But skipping spaces is usually a safe workaround for buggy servers. - # - # This advances @pos directly so it's safe before changing @lex_state. - def accept_spaces - return false unless SP? - @str.index(SPACES_REGEXP, @pos) and - @pos = $~.end(0) - true - end - - def next_token - case @lex_state - when EXPR_BEG - if @str.index(BEG_REGEXP, @pos) - @pos = $~.end(0) - if $1 - return Token.new(T_SPACE, $+) - elsif $2 - len = $+.to_i - val = @str[@pos, len] - @pos += len - return Token.new(T_LITERAL8, val) - elsif $3 && $7 - # greedily match ATOM, prefixed with NUMBER, NIL, or PLUS. - return Token.new(T_ATOM, $3) - elsif $4 - return Token.new(T_NIL, $+) - elsif $5 - return Token.new(T_NUMBER, $+) - elsif $6 - return Token.new(T_PLUS, $+) - elsif $8 - # match ATOM, without a NUMBER, NIL, or PLUS prefix - return Token.new(T_ATOM, $+) - elsif $9 - return Token.new(T_QUOTED, Patterns.unescape_quoted($+)) - elsif $10 - return Token.new(T_LPAR, $+) - elsif $11 - return Token.new(T_RPAR, $+) - elsif $12 - return Token.new(T_BSLASH, $+) - elsif $13 - return Token.new(T_STAR, $+) - elsif $14 - return Token.new(T_LBRA, $+) - elsif $15 - return Token.new(T_RBRA, $+) - elsif $16 - len = $+.to_i - val = @str[@pos, len] - @pos += len - return Token.new(T_LITERAL, val) - elsif $17 - return Token.new(T_PERCENT, $+) - elsif $18 - return Token.new(T_CRLF, $+) - elsif $19 - return Token.new(T_EOF, $+) - else - parse_error("[Net::IMAP BUG] BEG_REGEXP is invalid") - end - else - @str.index(/\S*/n, @pos) - parse_error("unknown token - %s", $&.dump) - end - when EXPR_DATA - if @str.index(DATA_REGEXP, @pos) - @pos = $~.end(0) - if $1 - return Token.new(T_SPACE, $+) - elsif $2 - return Token.new(T_NIL, $+) - elsif $3 - return Token.new(T_NUMBER, $+) - elsif $4 - return Token.new(T_QUOTED, Patterns.unescape_quoted($+)) - elsif $5 - len = $+.to_i - val = @str[@pos, len] - @pos += len - return Token.new(T_LITERAL, val) - elsif $6 - return Token.new(T_LPAR, $+) - elsif $7 - return Token.new(T_RPAR, $+) - else - parse_error("[Net::IMAP BUG] DATA_REGEXP is invalid") - end - else - @str.index(/\S*/n, @pos) - parse_error("unknown token - %s", $&.dump) - end - else - parse_error("invalid @lex_state - %s", @lex_state.inspect) - end - end - - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/anonymous_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/anonymous_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/anonymous_authenticator.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/anonymous_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,69 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP < Protocol - module SASL - - # Authenticator for the "+ANONYMOUS+" SASL mechanism, as specified by - # RFC-4505[https://tools.ietf.org/html/rfc4505]. See - # Net::IMAP#authenticate. - class AnonymousAuthenticator - - # An optional token sent for the +ANONYMOUS+ mechanism., up to 255 UTF-8 - # characters in length. - # - # If it contains an "@" sign, the message must be a valid email address - # (+addr-spec+ from RFC-2822[https://tools.ietf.org/html/rfc2822]). - # Email syntax is _not_ validated by AnonymousAuthenticator. - # - # Otherwise, it can be any UTF8 string which is permitted by the - # StringPrep::Trace profile. - attr_reader :anonymous_message - - # :call-seq: - # new(anonymous_message = "", **) -> authenticator - # new(anonymous_message: "", **) -> authenticator - # - # Creates an Authenticator for the "+ANONYMOUS+" SASL mechanism, as - # specified in RFC-4505[https://tools.ietf.org/html/rfc4505]. To use - # this, see Net::IMAP#authenticate or your client's authentication - # method. - # - # ==== Parameters - # - # * _optional_ #anonymous_message — a message to send to the server. - # - # Any other keyword arguments are silently ignored. - def initialize(anon_msg = nil, anonymous_message: nil, **) - message = (anonymous_message || anon_msg || "").to_str - @anonymous_message = StringPrep::Trace.stringprep_trace message - if (size = @anonymous_message&.length)&.> 255 - raise ArgumentError, - "anonymous_message is too long. (%d codepoints)" % [size] - end - @done = false - end - - # :call-seq: - # initial_response? -> true - # - # +ANONYMOUS+ can send an initial client response. - def initial_response?; true end - - # Returns #anonymous_message. - def process(_server_challenge_string) - anonymous_message - ensure - @done = true - end - - # Returns true when the initial client response was sent. - # - # The authentication should not succeed unless this returns true, but it - # does *not* indicate success. - def done?; @done end - - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/authentication_exchange.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/authentication_exchange.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/authentication_exchange.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/authentication_exchange.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,107 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - module SASL - - # This API is *experimental*, and may change. - # - # TODO: catch exceptions in #process and send #cancel_response. - # TODO: raise an error if the command succeeds after being canceled. - # TODO: use with more clients, to verify the API can accommodate them. - # - # Create an AuthenticationExchange from a client adapter and a mechanism - # authenticator: - # def authenticate(mechanism, ...) - # authenticator = SASL.authenticator(mechanism, ...) - # SASL::AuthenticationExchange.new( - # sasl_adapter, mechanism, authenticator - # ).authenticate - # end - # - # private - # - # def sasl_adapter = MyClientAdapter.new(self, &method(:send_command)) - # - # Or delegate creation of the authenticator to ::build: - # def authenticate(...) - # SASL::AuthenticationExchange.build(sasl_adapter, ...) - # .authenticate - # end - # - # As a convenience, ::authenticate combines ::build and #authenticate: - # def authenticate(...) - # SASL::AuthenticationExchange.authenticate(sasl_adapter, ...) - # end - # - # Likewise, ClientAdapter#authenticate delegates to #authenticate: - # def authenticate(...) = sasl_adapter.authenticate(...) - # - class AuthenticationExchange - # Convenience method for build(...).authenticate - def self.authenticate(...) build(...).authenticate end - - # Use +registry+ to override the global Authenticators registry. - def self.build(client, mechanism, *args, sasl_ir: true, **kwargs, &block) - authenticator = SASL.authenticator(mechanism, *args, **kwargs, &block) - new(client, mechanism, authenticator, sasl_ir: sasl_ir) - end - - attr_reader :mechanism, :authenticator - - def initialize(client, mechanism, authenticator, sasl_ir: true) - @client = client - @mechanism = -mechanism.to_s.upcase.tr(?_, ?-) - @authenticator = authenticator - @sasl_ir = sasl_ir - @processed = false - end - - # Call #authenticate to execute an authentication exchange for #client - # using #authenticator. Authentication failures will raise an - # exception. Any exceptions other than those in RESPONSE_ERRORS will - # drop the connection. - def authenticate - client.run_command(mechanism, initial_response) { process _1 } - .tap { raise AuthenticationIncomplete, _1 unless done? } - rescue *client.response_errors - raise # but don't drop the connection - rescue - client.drop_connection - raise - rescue Exception # rubocop:disable Lint/RescueException - client.drop_connection! - raise - end - - def send_initial_response? - @sasl_ir && - authenticator.respond_to?(:initial_response?) && - authenticator.initial_response? && - client.sasl_ir_capable? && - client.auth_capable?(mechanism) - end - - def done? - authenticator.respond_to?(:done?) ? authenticator.done? : @processed - end - - private - - attr_reader :client - - def initial_response - return unless send_initial_response? - client.encode_ir authenticator.process nil - end - - def process(challenge) - client.encode authenticator.process client.decode challenge - ensure - @processed = true - end - - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/authenticators.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/authenticators.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/authenticators.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/authenticators.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,118 +0,0 @@ -# frozen_string_literal: true - -module Net::IMAP::SASL - - # Registry for SASL authenticators - # - # Registered authenticators must respond to +#new+ or +#call+ (e.g. a class or - # a proc), receiving any credentials and options and returning an - # authenticator instance. The returned object represents a single - # authentication exchange and must not be reused for multiple - # authentication attempts. - # - # An authenticator instance object must respond to +#process+, receiving the - # server's challenge and returning the client's response. Optionally, it may - # also respond to +#initial_response?+ and +#done?+. When - # +#initial_response?+ returns +true+, +#process+ may be called the first - # time with +nil+. When +#done?+ returns +false+, the exchange is incomplete - # and an exception should be raised if the exchange terminates prematurely. - # - # See the source for PlainAuthenticator, XOAuth2Authenticator, and - # ScramSHA1Authenticator for examples. - class Authenticators - - # Create a new Authenticators registry. - # - # This class is usually not instantiated directly. Use SASL.authenticators - # to reuse the default global registry. - # - # When +use_defaults+ is +false+, the registry will start empty. When - # +use_deprecated+ is +false+, deprecated authenticators will not be - # included with the defaults. - def initialize(use_defaults: true, use_deprecated: true) - @authenticators = {} - return unless use_defaults - add_authenticator "Anonymous" - add_authenticator "External" - add_authenticator "OAuthBearer" - add_authenticator "Plain" - add_authenticator "Scram-SHA-1" - add_authenticator "Scram-SHA-256" - add_authenticator "XOAuth2" - return unless use_deprecated - add_authenticator "Login" # deprecated - add_authenticator "Cram-MD5" # deprecated - add_authenticator "Digest-MD5" # deprecated - end - - # Returns the names of all registered SASL mechanisms. - def names; @authenticators.keys end - - # :call-seq: - # add_authenticator(mechanism) - # add_authenticator(mechanism, authenticator_class) - # add_authenticator(mechanism, authenticator_proc) - # - # Registers an authenticator for #authenticator to use. +mechanism+ is the - # name of the - # {SASL mechanism}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] - # implemented by +authenticator_class+ (for instance, "PLAIN"). - # - # If +mechanism+ refers to an existing authenticator, - # the old authenticator will be replaced. - # - # When only a single argument is given, the authenticator class will be - # lazily loaded from Net::IMAP::SASL::#{name}Authenticator (case is - # preserved and non-alphanumeric characters are removed.. - def add_authenticator(name, authenticator = nil) - key = -name.to_s.upcase.tr(?_, ?-) - authenticator ||= begin - class_name = "#{name.gsub(/[^a-zA-Z0-9]/, "")}Authenticator".to_sym - auth_class = nil - ->(*creds, **props, &block) { - auth_class ||= Net::IMAP::SASL.const_get(class_name) - auth_class.new(*creds, **props, &block) - } - end - @authenticators[key] = authenticator - end - - # Removes the authenticator registered for +name+ - def remove_authenticator(name) - key = -name.to_s.upcase.tr(?_, ?-) - @authenticators.delete(key) - end - - def mechanism?(name) - key = -name.to_s.upcase.tr(?_, ?-) - @authenticators.key?(key) - end - - # :call-seq: - # authenticator(mechanism, ...) -> auth_session - # - # Builds an authenticator instance using the authenticator registered to - # +mechanism+. The returned object represents a single authentication - # exchange and must not be reused for multiple authentication - # attempts. - # - # All arguments (except +mechanism+) are forwarded to the registered - # authenticator's +#new+ or +#call+ method. Each authenticator must - # document its own arguments. - # - # [Note] - # This method is intended for internal use by connection protocol code - # only. Protocol client users should see refer to their client's - # documentation, e.g. Net::IMAP#authenticate. - def authenticator(mechanism, ...) - key = -mechanism.to_s.upcase.tr(?_, ?-) - auth = @authenticators.fetch(key) do - raise ArgumentError, 'unknown auth type - "%s"' % key - end - auth.respond_to?(:new) ? auth.new(...) : auth.call(...) - end - alias new authenticator - - end - -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/client_adapter.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/client_adapter.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/client_adapter.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/client_adapter.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,72 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - module SASL - - # This API is *experimental*, and may change. - # - # TODO: use with more clients, to verify the API can accommodate them. - # - # An abstract base class for implementing a SASL authentication exchange. - # Different clients will each have their own adapter subclass, overridden - # to match their needs. - # - # Although the default implementations _may_ be sufficient, subclasses - # will probably need to override some methods. Additionally, subclasses - # may need to include a protocol adapter mixin, if the default - # ProtocolAdapters::Generic isn't sufficient. - class ClientAdapter - include ProtocolAdapters::Generic - - attr_reader :client, :command_proc - - # +command_proc+ can used to avoid exposing private methods on #client. - # It should run a command with the arguments sent to it, yield each - # continuation payload, respond to the server with the result of each - # yield, and return the result. Non-successful results *MUST* raise an - # exception. Exceptions in the block *MUST* cause the command to fail. - # - # Subclasses that override #run_command may use #command_proc for - # other purposes. - def initialize(client, &command_proc) - @client, @command_proc = client, command_proc - end - - # Delegates to AuthenticationExchange.authenticate. - def authenticate(...) AuthenticationExchange.authenticate(self, ...) end - - # Do the protocol and server both support an initial response? - def sasl_ir_capable?; client.sasl_ir_capable? end - - # Does the server advertise support for the mechanism? - def auth_capable?(mechanism); client.auth_capable?(mechanism) end - - # Runs the authenticate command with +mechanism+ and +initial_response+. - # When +initial_response+ is nil, an initial response must NOT be sent. - # - # Yields each continuation payload, responds to the server with the - # result of each yield, and returns the result. Non-successful results - # *MUST* raise an exception. Exceptions in the block *MUST* cause the - # command to fail. - # - # Subclasses that override this may use #command_proc differently. - def run_command(mechanism, initial_response = nil, &block) - command_proc or raise Error, "initialize with block or override" - args = [command_name, mechanism, initial_response].compact - command_proc.call(*args, &block) - end - - # Returns an array of server responses errors raised by run_command. - # Exceptions in this array won't drop the connection. - def response_errors; [] end - - # Drop the connection gracefully. - def drop_connection; client.drop_connection end - - # Drop the connection abruptly. - def drop_connection!; client.drop_connection! end - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/cram_md5_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/cram_md5_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/cram_md5_authenticator.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/cram_md5_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,61 +0,0 @@ -# frozen_string_literal: true - -# Authenticator for the "+CRAM-MD5+" SASL mechanism, specified in -# RFC2195[https://tools.ietf.org/html/rfc2195]. See Net::IMAP#authenticate. -# -# == Deprecated -# -# +CRAM-MD5+ is obsolete and insecure. It is included for compatibility with -# existing servers. -# {draft-ietf-sasl-crammd5-to-historic}[https://tools.ietf.org/html/draft-ietf-sasl-crammd5-to-historic-00.html] -# recommends using +SCRAM-*+ or +PLAIN+ protected by TLS instead. -# -# Additionally, RFC8314[https://tools.ietf.org/html/rfc8314] discourage the use -# of cleartext and recommends TLS version 1.2 or greater be used for all -# traffic. With TLS +CRAM-MD5+ is okay, but so is +PLAIN+ -class Net::IMAP::SASL::CramMD5Authenticator - def initialize(user = nil, pass = nil, - authcid: nil, username: nil, - password: nil, secret: nil, - warn_deprecation: true, - **) - if warn_deprecation - warn "WARNING: CRAM-MD5 mechanism is deprecated." # TODO: recommend SCRAM - end - require "digest/md5" - @user = authcid || username || user - @password = password || secret || pass - @done = false - end - - def initial_response?; false end - - def process(challenge) - digest = hmac_md5(challenge, @password) - return @user + " " + digest - ensure - @done = true - end - - def done?; @done end - - private - - def hmac_md5(text, key) - if key.length > 64 - key = Digest::MD5.digest(key) - end - - k_ipad = key + "\0" * (64 - key.length) - k_opad = key + "\0" * (64 - key.length) - for i in 0..63 - k_ipad[i] = (k_ipad[i].ord ^ 0x36).chr - k_opad[i] = (k_opad[i].ord ^ 0x5c).chr - end - - digest = Digest::MD5.digest(k_ipad + text) - - return Digest::MD5.hexdigest(k_opad + digest) - end - -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/digest_md5_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/digest_md5_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/digest_md5_authenticator.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/digest_md5_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,180 +0,0 @@ -# frozen_string_literal: true - -# Net::IMAP authenticator for the "`DIGEST-MD5`" SASL mechanism type, specified -# in RFC-2831[https://tools.ietf.org/html/rfc2831]. See Net::IMAP#authenticate. -# -# == Deprecated -# -# "+DIGEST-MD5+" has been deprecated by -# RFC-6331[https://tools.ietf.org/html/rfc6331] and should not be relied on for -# security. It is included for compatibility with existing servers. -class Net::IMAP::SASL::DigestMD5Authenticator - STAGE_ONE = :stage_one - STAGE_TWO = :stage_two - STAGE_DONE = :stage_done - private_constant :STAGE_ONE, :STAGE_TWO, :STAGE_DONE - - # Authentication identity: the identity that matches the #password. - # - # RFC-2831[https://tools.ietf.org/html/rfc2831] uses the term +username+. - # "Authentication identity" is the generic term used by - # RFC-4422[https://tools.ietf.org/html/rfc4422]. - # RFC-4616[https://tools.ietf.org/html/rfc4616] and many later RFCs abbreviate - # this to +authcid+. - attr_reader :username - alias authcid username - - # A password or passphrase that matches the #username. - # - # The +password+ will be used to create the response digest. - attr_reader :password - - # Authorization identity: an identity to act as or on behalf of. The identity - # form is application protocol specific. If not provided or left blank, the - # server derives an authorization identity from the authentication identity. - # The server is responsible for verifying the client's credentials and - # verifying that the identity it associates with the client's authentication - # identity is allowed to act as (or on behalf of) the authorization identity. - # - # For example, an administrator or superuser might take on another role: - # - # imap.authenticate "DIGEST-MD5", "root", ->{passwd}, authzid: "user" - # - attr_reader :authzid - - # :call-seq: - # new(username, password, authzid = nil, **options) -> authenticator - # new(username:, password:, authzid: nil, **options) -> authenticator - # new(authcid:, password:, authzid: nil, **options) -> authenticator - # - # Creates an Authenticator for the "+DIGEST-MD5+" SASL mechanism. - # - # Called by Net::IMAP#authenticate and similar methods on other clients. - # - # ==== Parameters - # - # * #authcid ― Authentication identity that is associated with #password. - # - # #username ― An alias for +authcid+. - # - # * #password ― A password or passphrase associated with this #authcid. - # - # * _optional_ #authzid ― Authorization identity to act as or on behalf of. - # - # When +authzid+ is not set, the server should derive the authorization - # identity from the authentication identity. - # - # * _optional_ +warn_deprecation+ — Set to +false+ to silence the warning. - # - # Any other keyword arguments are silently ignored. - def initialize(user = nil, pass = nil, authz = nil, - username: nil, password: nil, authzid: nil, - authcid: nil, secret: nil, - warn_deprecation: true, **) - username = authcid || username || user or - raise ArgumentError, "missing username (authcid)" - password ||= secret || pass or raise ArgumentError, "missing password" - authzid ||= authz - if warn_deprecation - warn "WARNING: DIGEST-MD5 SASL mechanism was deprecated by RFC6331." - # TODO: recommend SCRAM instead. - end - require "digest/md5" - require "strscan" - @username, @password, @authzid = username, password, authzid - @nc, @stage = {}, STAGE_ONE - end - - def initial_response?; false end - - # Responds to server challenge in two stages. - def process(challenge) - case @stage - when STAGE_ONE - @stage = STAGE_TWO - sparams = {} - c = StringScanner.new(challenge) - while c.scan(/(?:\s*,)?\s*(\w+)=("(?:[^\\"]|\\.)*"|[^,]+)\s*/) - k, v = c[1], c[2] - if v =~ /^"(.*)"$/ - v = $1 - if v =~ /,/ - v = v.split(',') - end - end - sparams[k] = v - end - - raise Net::IMAP::DataFormatError, "Bad Challenge: '#{challenge}'" unless c.eos? and sparams['qop'] - raise Net::IMAP::Error, "Server does not support auth (qop = #{sparams['qop'].join(',')})" unless sparams['qop'].include?("auth") - - response = { - :nonce => sparams['nonce'], - :username => @username, - :realm => sparams['realm'], - :cnonce => Digest::MD5.hexdigest("%.15f:%.15f:%d" % [Time.now.to_f, rand, Process.pid.to_s]), - :'digest-uri' => 'imap/' + sparams['realm'], - :qop => 'auth', - :maxbuf => 65535, - :nc => "%08d" % nc(sparams['nonce']), - :charset => sparams['charset'], - } - - response[:authzid] = @authzid unless @authzid.nil? - - # now, the real thing - a0 = Digest::MD5.digest( [ response.values_at(:username, :realm), @password ].join(':') ) - - a1 = [ a0, response.values_at(:nonce,:cnonce) ].join(':') - a1 << ':' + response[:authzid] unless response[:authzid].nil? - - a2 = "AUTHENTICATE:" + response[:'digest-uri'] - a2 << ":00000000000000000000000000000000" if response[:qop] and response[:qop] =~ /^auth-(?:conf|int)$/ - - response[:response] = Digest::MD5.hexdigest( - [ - Digest::MD5.hexdigest(a1), - response.values_at(:nonce, :nc, :cnonce, :qop), - Digest::MD5.hexdigest(a2) - ].join(':') - ) - - return response.keys.map {|key| qdval(key.to_s, response[key]) }.join(',') - when STAGE_TWO - @stage = STAGE_DONE - # if at the second stage, return an empty string - if challenge =~ /rspauth=/ - return '' - else - raise ResponseParseError, challenge - end - else - raise ResponseParseError, challenge - end - end - - def done?; @stage == STAGE_DONE end - - private - - def nc(nonce) - if @nc.has_key? nonce - @nc[nonce] = @nc[nonce] + 1 - else - @nc[nonce] = 1 - end - return @nc[nonce] - end - - # some responses need quoting - def qdval(k, v) - return if k.nil? or v.nil? - if %w"username authzid realm nonce cnonce digest-uri qop".include? k - v = v.gsub(/([\\"])/, "\\\1") - return '%s="%s"' % [k, v] - else - return '%s=%s' % [k, v] - end - end - -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/external_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/external_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/external_authenticator.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/external_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,83 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP < Protocol - module SASL - - # Authenticator for the "+EXTERNAL+" SASL mechanism, as specified by - # RFC-4422[https://tools.ietf.org/html/rfc4422]. See - # Net::IMAP#authenticate. - # - # The EXTERNAL mechanism requests that the server use client credentials - # established external to SASL, for example by TLS certificate or IPSec. - class ExternalAuthenticator - - # Authorization identity: an identity to act as or on behalf of. The - # identity form is application protocol specific. If not provided or - # left blank, the server derives an authorization identity from the - # authentication identity. The server is responsible for verifying the - # client's credentials and verifying that the identity it associates - # with the client's authentication identity is allowed to act as (or on - # behalf of) the authorization identity. - # - # For example, an administrator or superuser might take on another role: - # - # imap.authenticate "PLAIN", "root", passwd, authzid: "user" - # - attr_reader :authzid - alias username authzid - - # :call-seq: - # new(authzid: nil, **) -> authenticator - # new(username: nil, **) -> authenticator - # new(username = nil, **) -> authenticator - # - # Creates an Authenticator for the "+EXTERNAL+" SASL mechanism, as - # specified in RFC-4422[https://tools.ietf.org/html/rfc4422]. To use - # this, see Net::IMAP#authenticate or your client's authentication - # method. - # - # ==== Parameters - # - # * _optional_ #authzid ― Authorization identity to act as or on behalf of. - # - # _optional_ #username ― An alias for #authzid. - # - # Note that, unlike some other authenticators, +username+ sets the - # _authorization_ identity and not the _authentication_ identity. The - # authentication identity is established for the client by the - # external credentials. - # - # Any other keyword parameters are quietly ignored. - def initialize(user = nil, authzid: nil, username: nil, **) - authzid ||= username || user - @authzid = authzid&.to_str&.encode "UTF-8" - if @authzid&.match?(/\u0000/u) # also validates UTF8 encoding - raise ArgumentError, "contains NULL" - end - @done = false - end - - # :call-seq: - # initial_response? -> true - # - # +EXTERNAL+ can send an initial client response. - def initial_response?; true end - - # Returns #authzid, or an empty string if there is no authzid. - def process(_) - authzid || "" - ensure - @done = true - end - - # Returns true when the initial client response was sent. - # - # The authentication should not succeed unless this returns true, but it - # does *not* indicate success. - def done?; @done end - - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/gs2_header.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/gs2_header.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/gs2_header.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/gs2_header.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,80 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP < Protocol - module SASL - - # Originally defined for the GS2 mechanism family in - # RFC5801[https://tools.ietf.org/html/rfc5801], - # several different mechanisms start with a GS2 header: - # * +GS2-*+ --- RFC5801[https://tools.ietf.org/html/rfc5801] - # * +SCRAM-*+ --- RFC5802[https://tools.ietf.org/html/rfc5802] - # (ScramAuthenticator) - # * +SAML20+ --- RFC6595[https://tools.ietf.org/html/rfc6595] - # * +OPENID20+ --- RFC6616[https://tools.ietf.org/html/rfc6616] - # * +OAUTH10A+ --- RFC7628[https://tools.ietf.org/html/rfc7628] - # * +OAUTHBEARER+ --- RFC7628[https://tools.ietf.org/html/rfc7628] - # (OAuthBearerAuthenticator) - # - # Classes that include this module must implement +#authzid+. - module GS2Header - NO_NULL_CHARS = /\A[^\x00]+\z/u.freeze # :nodoc: - - ## - # Matches {RFC5801 §4}[https://www.rfc-editor.org/rfc/rfc5801#section-4] - # +saslname+. The output from gs2_saslname_encode matches this Regexp. - RFC5801_SASLNAME = /\A(?:[^,=\x00]|=2C|=3D)+\z/u.freeze - - # The {RFC5801 §4}[https://www.rfc-editor.org/rfc/rfc5801#section-4] - # +gs2-header+, which prefixes the #initial_client_response. - # - # >>> - # Note: the actual GS2 header includes an optional flag to - # indicate that the GSS mechanism is not "standard", but since all of - # the SASL mechanisms using GS2 are "standard", we don't include that - # flag. A class for a nonstandard GSSAPI mechanism should prefix with - # "+F,+". - def gs2_header - "#{gs2_cb_flag},#{gs2_authzid}," - end - - # The {RFC5801 §4}[https://www.rfc-editor.org/rfc/rfc5801#section-4] - # +gs2-cb-flag+: - # - # "+n+":: The client doesn't support channel binding. - # "+y+":: The client does support channel binding - # but thinks the server does not. - # "+p+":: The client requires channel binding. - # The selected channel binding follows "+p=+". - # - # The default always returns "+n+". A mechanism that supports channel - # binding must override this method. - # - def gs2_cb_flag; "n" end - - # The {RFC5801 §4}[https://www.rfc-editor.org/rfc/rfc5801#section-4] - # +gs2-authzid+ header, when +#authzid+ is not empty. - # - # If +#authzid+ is empty or +nil+, an empty string is returned. - def gs2_authzid - return "" if authzid.nil? || authzid == "" - "a=#{gs2_saslname_encode(authzid)}" - end - - module_function - - # Encodes +str+ to match RFC5801_SASLNAME. - def gs2_saslname_encode(str) - str = str.encode("UTF-8") - # Regexp#match raises "invalid byte sequence" for invalid UTF-8 - NO_NULL_CHARS.match str or - raise ArgumentError, "invalid saslname: %p" % [str] - str - .gsub(?=, "=3D") - .gsub(?,, "=2C") - end - - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/login_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/login_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/login_authenticator.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/login_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,55 +0,0 @@ -# frozen_string_literal: true - -# Authenticator for the "+LOGIN+" SASL mechanism. See Net::IMAP#authenticate. -# -# +LOGIN+ authentication sends the password in cleartext. -# RFC3501[https://tools.ietf.org/html/rfc3501] encourages servers to disable -# cleartext authentication until after TLS has been negotiated. -# RFC8314[https://tools.ietf.org/html/rfc8314] recommends TLS version 1.2 or -# greater be used for all traffic, and deprecate cleartext access ASAP. +LOGIN+ -# can be secured by TLS encryption. -# -# == Deprecated -# -# The {SASL mechanisms -# registry}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] -# marks "LOGIN" as obsoleted in favor of "PLAIN". It is included here for -# compatibility with existing servers. See -# {draft-murchison-sasl-login}[https://www.iana.org/go/draft-murchison-sasl-login] -# for both specification and deprecation. -class Net::IMAP::SASL::LoginAuthenticator - STATE_USER = :USER - STATE_PASSWORD = :PASSWORD - STATE_DONE = :DONE - private_constant :STATE_USER, :STATE_PASSWORD, :STATE_DONE - - def initialize(user = nil, pass = nil, - authcid: nil, username: nil, - password: nil, secret: nil, - warn_deprecation: true, - **) - if warn_deprecation - warn "WARNING: LOGIN SASL mechanism is deprecated. Use PLAIN instead." - end - @user = authcid || username || user - @password = password || secret || pass - @state = STATE_USER - end - - def initial_response?; false end - - def process(data) - case @state - when STATE_USER - @state = STATE_PASSWORD - return @user - when STATE_PASSWORD - @state = STATE_DONE - return @password - when STATE_DONE - raise ResponseParseError, data - end - end - - def done?; @state == STATE_DONE end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/oauthbearer_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/oauthbearer_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/oauthbearer_authenticator.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/oauthbearer_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,199 +0,0 @@ -# frozen_string_literal: true - -require_relative "gs2_header" - -module Net - class IMAP < Protocol - module SASL - - # Abstract base class for the SASL mechanisms defined in - # RFC7628[https://tools.ietf.org/html/rfc7628]: - # * OAUTHBEARER[rdoc-ref:OAuthBearerAuthenticator] - # (OAuthBearerAuthenticator) - # * OAUTH10A - class OAuthAuthenticator - include GS2Header - - # Authorization identity: an identity to act as or on behalf of. The - # identity form is application protocol specific. If not provided or - # left blank, the server derives an authorization identity from the - # authentication identity. The server is responsible for verifying the - # client's credentials and verifying that the identity it associates - # with the client's authentication identity is allowed to act as (or on - # behalf of) the authorization identity. - # - # For example, an administrator or superuser might take on another role: - # - # imap.authenticate "PLAIN", "root", passwd, authzid: "user" - # - attr_reader :authzid - alias username authzid - - # Hostname to which the client connected. (optional) - attr_reader :host - - # Service port to which the client connected. (optional) - attr_reader :port - - # HTTP method. (optional) - attr_reader :mthd - - # HTTP path data. (optional) - attr_reader :path - - # HTTP post data. (optional) - attr_reader :post - - # The query string. (optional) - attr_reader :qs - alias query qs - - # Stores the most recent server "challenge". When authentication fails, - # this may hold information about the failure reason, as JSON. - attr_reader :last_server_response - - # Creates an RFC7628[https://tools.ietf.org/html/rfc7628] OAuth - # authenticator. - # - # ==== Parameters - # - # See child classes for required parameter(s). The following parameters - # are all optional, but it is worth noting that application protocols - # are allowed to require #authzid (or other parameters, such as - # #host or #port) as are specific server implementations. - # - # * _optional_ #authzid ― Authorization identity to act as or on behalf of. - # - # _optional_ #username — An alias for #authzid. - # - # Note that, unlike some other authenticators, +username+ sets the - # _authorization_ identity and not the _authentication_ identity. The - # authentication identity is established for the client by the OAuth - # token. - # - # * _optional_ #host — Hostname to which the client connected. - # * _optional_ #port — Service port to which the client connected. - # * _optional_ #mthd — HTTP method - # * _optional_ #path — HTTP path data - # * _optional_ #post — HTTP post data - # * _optional_ #qs — HTTP query string - # - # _optional_ #query — An alias for #qs - # - # Any other keyword parameters are quietly ignored. - def initialize(authzid: nil, host: nil, port: nil, - username: nil, query: nil, - mthd: nil, path: nil, post: nil, qs: nil, **) - @authzid = authzid || username - @host = host - @port = port - @mthd = mthd - @path = path - @post = post - @qs = qs || query - @done = false - end - - # The {RFC7628 §3.1}[https://www.rfc-editor.org/rfc/rfc7628#section-3.1] - # formatted response. - def initial_client_response - kv_pairs = { - host: host, port: port, mthd: mthd, path: path, post: post, qs: qs, - auth: authorization, # authorization is implemented by subclasses - }.compact - [gs2_header, *kv_pairs.map {|kv| kv.join("=") }, "\1"].join("\1") - end - - # Returns initial_client_response the first time, then "^A". - def process(data) - @last_server_response = data - done? ? "\1" : initial_client_response - ensure - @done = true - end - - # Returns true when the initial client response was sent. - # - # The authentication should not succeed unless this returns true, but it - # does *not* indicate success. - def done?; @done end - - # Value of the HTTP Authorization header - # - # Implemented by subclasses. - def authorization; raise "must be implemented by subclass" end - - end - - # Authenticator for the "+OAUTHBEARER+" SASL mechanism, specified in - # RFC7628[https://tools.ietf.org/html/rfc7628]. Authenticates using OAuth - # 2.0 bearer tokens, as described in - # RFC6750[https://tools.ietf.org/html/rfc6750]. Use via - # Net::IMAP#authenticate. - # - # RFC6750[https://tools.ietf.org/html/rfc6750] requires Transport Layer - # Security (TLS) to secure the protocol interaction between the client and - # the resource server. TLS _MUST_ be used for +OAUTHBEARER+ to protect - # the bearer token. - class OAuthBearerAuthenticator < OAuthAuthenticator - - # An OAuth 2.0 bearer token. See {RFC-6750}[https://www.rfc-editor.org/rfc/rfc6750] - attr_reader :oauth2_token - alias secret oauth2_token - - # :call-seq: - # new(oauth2_token, **options) -> authenticator - # new(authzid, oauth2_token, **options) -> authenticator - # new(oauth2_token:, **options) -> authenticator - # - # Creates an Authenticator for the "+OAUTHBEARER+" SASL mechanism. - # - # Called by Net::IMAP#authenticate and similar methods on other clients. - # - # ==== Parameters - # - # * #oauth2_token — An OAuth2 bearer token - # - # All other keyword parameters are passed to - # {super}[rdoc-ref:OAuthAuthenticator::new] (see OAuthAuthenticator). - # The most common ones are: - # - # * _optional_ #authzid ― Authorization identity to act as or on behalf of. - # - # _optional_ #username — An alias for #authzid. - # - # Note that, unlike some other authenticators, +username+ sets the - # _authorization_ identity and not the _authentication_ identity. The - # authentication identity is established for the client by - # #oauth2_token. - # - # * _optional_ #host — Hostname to which the client connected. - # * _optional_ #port — Service port to which the client connected. - # - # Although only oauth2_token is required by this mechanism, it is worth - # noting that application protocols are allowed to - # require #authzid (or other parameters, such as #host - # _or_ #port) as are specific server implementations. - def initialize(arg1 = nil, arg2 = nil, - oauth2_token: nil, secret: nil, - **args, &blk) - username, oauth2_token_arg = arg2.nil? ? [nil, arg1] : [arg1, arg2] - super(username: username, **args, &blk) - @oauth2_token = oauth2_token || secret || oauth2_token_arg or - raise ArgumentError, "missing oauth2_token" - end - - # :call-seq: - # initial_response? -> true - # - # +OAUTHBEARER+ sends an initial client response. - def initial_response?; true end - - # Value of the HTTP Authorization header - def authorization; "Bearer #{oauth2_token}" end - - end - end - - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/plain_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/plain_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/plain_authenticator.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/plain_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,101 +0,0 @@ -# frozen_string_literal: true - -# Authenticator for the "+PLAIN+" SASL mechanism, specified in -# RFC-4616[https://tools.ietf.org/html/rfc4616]. See Net::IMAP#authenticate. -# -# +PLAIN+ authentication sends the password in cleartext. -# RFC-3501[https://tools.ietf.org/html/rfc3501] encourages servers to disable -# cleartext authentication until after TLS has been negotiated. -# RFC-8314[https://tools.ietf.org/html/rfc8314] recommends TLS version 1.2 or -# greater be used for all traffic, and deprecate cleartext access ASAP. +PLAIN+ -# can be secured by TLS encryption. -class Net::IMAP::SASL::PlainAuthenticator - - NULL = -"\0".b - private_constant :NULL - - # Authentication identity: the identity that matches the #password. - # - # RFC-2831[https://tools.ietf.org/html/rfc2831] uses the term +username+. - # "Authentication identity" is the generic term used by - # RFC-4422[https://tools.ietf.org/html/rfc4422]. - # RFC-4616[https://tools.ietf.org/html/rfc4616] and many later RFCs abbreviate - # this to +authcid+. - attr_reader :username - alias authcid username - - # A password or passphrase that matches the #username. - attr_reader :password - alias secret password - - # Authorization identity: an identity to act as or on behalf of. The identity - # form is application protocol specific. If not provided or left blank, the - # server derives an authorization identity from the authentication identity. - # The server is responsible for verifying the client's credentials and - # verifying that the identity it associates with the client's authentication - # identity is allowed to act as (or on behalf of) the authorization identity. - # - # For example, an administrator or superuser might take on another role: - # - # imap.authenticate "PLAIN", "root", passwd, authzid: "user" - # - attr_reader :authzid - - # :call-seq: - # new(username, password, authzid: nil, **) -> authenticator - # new(username:, password:, authzid: nil, **) -> authenticator - # new(authcid:, password:, authzid: nil, **) -> authenticator - # - # Creates an Authenticator for the "+PLAIN+" SASL mechanism. - # - # Called by Net::IMAP#authenticate and similar methods on other clients. - # - # ==== Parameters - # - # * #authcid ― Authentication identity that is associated with #password. - # - # #username ― An alias for #authcid. - # - # * #password ― A password or passphrase associated with the #authcid. - # - # * _optional_ #authzid ― Authorization identity to act as or on behalf of. - # - # When +authzid+ is not set, the server should derive the authorization - # identity from the authentication identity. - # - # Any other keyword parameters are quietly ignored. - def initialize(user = nil, pass = nil, - authcid: nil, secret: nil, - username: nil, password: nil, authzid: nil, **) - username ||= authcid || user or - raise ArgumentError, "missing username (authcid)" - password ||= secret || pass or raise ArgumentError, "missing password" - raise ArgumentError, "username contains NULL" if username.include?(NULL) - raise ArgumentError, "password contains NULL" if password.include?(NULL) - raise ArgumentError, "authzid contains NULL" if authzid&.include?(NULL) - @username = username - @password = password - @authzid = authzid - @done = false - end - - # :call-seq: - # initial_response? -> true - # - # +PLAIN+ can send an initial client response. - def initial_response?; true end - - # Responds with the client's credentials. - def process(data) - return "#@authzid\0#@username\0#@password" - ensure - @done = true - end - - # Returns true when the initial client response was sent. - # - # The authentication should not succeed unless this returns true, but it - # does *not* indicate success. - def done?; @done end - -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/protocol_adapters.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/protocol_adapters.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/protocol_adapters.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/protocol_adapters.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,45 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - module SASL - - module ProtocolAdapters - # This API is experimental, and may change. - module Generic - def command_name; "AUTHENTICATE" end - def service; raise "Implement in subclass or module" end - def host; client.host end - def port; client.port end - def encode_ir(string) string.empty? ? "=" : encode(string) end - def encode(string) [string].pack("m0") end - def decode(string) string.unpack1("m0") end - def cancel_response; "*" end - end - - # See RFC-3501 (IMAP4rev1), RFC-4959 (SASL-IR capability), - # and RFC-9051 (IMAP4rev2). - module IMAP - include Generic - def service; "imap" end - end - - # See RFC-4954 (AUTH capability). - module SMTP - include Generic - def command_name; "AUTH" end - def service; "smtp" end - end - - # See RFC-5034 (SASL capability). - module POP - include Generic - def command_name; "AUTH" end - def service; "pop" end - end - - end - - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/scram_algorithm.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/scram_algorithm.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/scram_algorithm.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/scram_algorithm.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,58 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - module SASL - - # For method descriptions, - # see {RFC5802 §2.2}[https://www.rfc-editor.org/rfc/rfc5802#section-2.2] - # and {RFC5802 §3}[https://www.rfc-editor.org/rfc/rfc5802#section-3]. - module ScramAlgorithm - def Normalize(str) SASL.saslprep(str) end - - def Hi(str, salt, iterations) - length = digest.digest_length - OpenSSL::KDF.pbkdf2_hmac( - str, - salt: salt, - iterations: iterations, - length: length, - hash: digest, - ) - end - - def H(str) digest.digest str end - - def HMAC(key, data) OpenSSL::HMAC.digest(digest, key, data) end - - def XOR(str1, str2) - str1.unpack("C*") - .zip(str2.unpack("C*")) - .map {|a, b| a ^ b } - .pack("C*") - end - - def auth_message - [ - client_first_message_bare, - server_first_message, - client_final_message_without_proof, - ] - .join(",") - end - - def salted_password - Hi(Normalize(password), salt, iterations) - end - - def client_key; HMAC(salted_password, "Client Key") end - def server_key; HMAC(salted_password, "Server Key") end - def stored_key; H(client_key) end - def client_signature; HMAC(stored_key, auth_message) end - def server_signature; HMAC(server_key, auth_message) end - def client_proof; XOR(client_key, client_signature) end - end - - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/scram_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/scram_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/scram_authenticator.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/scram_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,287 +0,0 @@ -# frozen_string_literal: true - -require "openssl" -require "securerandom" - -require_relative "gs2_header" -require_relative "scram_algorithm" - -module Net - class IMAP - module SASL - - # Abstract base class for the "+SCRAM-*+" family of SASL mechanisms, - # defined in RFC5802[https://tools.ietf.org/html/rfc5802]. Use via - # Net::IMAP#authenticate. - # - # Directly supported: - # * +SCRAM-SHA-1+ --- ScramSHA1Authenticator - # * +SCRAM-SHA-256+ --- ScramSHA256Authenticator - # - # New +SCRAM-*+ mechanisms can easily be added for any hash algorithm - # supported by - # OpenSSL::Digest[https://ruby.github.io/openssl/OpenSSL/Digest.html]. - # Subclasses need only set an appropriate +DIGEST_NAME+ constant. - # - # === SCRAM algorithm - # - # See the documentation and method definitions on ScramAlgorithm for an - # overview of the algorithm. The different mechanisms differ only by - # which hash function that is used (or by support for channel binding with - # +-PLUS+). - # - # See also the methods on GS2Header. - # - # ==== Server messages - # - # As server messages are received, they are validated and loaded into - # the various attributes, e.g: #snonce, #salt, #iterations, #verifier, - # #server_error, etc. - # - # Unlike many other SASL mechanisms, the +SCRAM-*+ family supports mutual - # authentication and can return server error data in the server messages. - # If #process raises an Error for the server-final-message, then - # server_error may contain error details. - # - # === TLS Channel binding - # - # The SCRAM-*-PLUS mechanisms and channel binding are not - # supported yet. - # - # === Caching SCRAM secrets - # - # Caching of salted_password, client_key, stored_key, and server_key - # is not supported yet. - # - class ScramAuthenticator - include GS2Header - include ScramAlgorithm - - # :call-seq: - # new(username, password, **options) -> auth_ctx - # new(username:, password:, **options) -> auth_ctx - # new(authcid:, password:, **options) -> auth_ctx - # - # Creates an authenticator for one of the "+SCRAM-*+" SASL mechanisms. - # Each subclass defines #digest to match a specific mechanism. - # - # Called by Net::IMAP#authenticate and similar methods on other clients. - # - # === Parameters - # - # * #authcid ― Identity whose #password is used. - # - # #username - An alias for #authcid. - # * #password ― Password or passphrase associated with this #username. - # * _optional_ #authzid ― Alternate identity to act as or on behalf of. - # * _optional_ #min_iterations - Overrides the default value (4096). - # - # Any other keyword parameters are quietly ignored. - def initialize(username_arg = nil, password_arg = nil, - authcid: nil, username: nil, - authzid: nil, - password: nil, secret: nil, - min_iterations: 4096, # see both RFC5802 and RFC7677 - cnonce: nil, # must only be set in tests - **options) - @username = username || username_arg || authcid or - raise ArgumentError, "missing username (authcid)" - @password = password || secret || password_arg or - raise ArgumentError, "missing password" - @authzid = authzid - - @min_iterations = Integer min_iterations - @min_iterations.positive? or - raise ArgumentError, "min_iterations must be positive" - - @cnonce = cnonce || SecureRandom.base64(32) - end - - # Authentication identity: the identity that matches the #password. - # - # RFC-2831[https://tools.ietf.org/html/rfc2831] uses the term +username+. - # "Authentication identity" is the generic term used by - # RFC-4422[https://tools.ietf.org/html/rfc4422]. - # RFC-4616[https://tools.ietf.org/html/rfc4616] and many later RFCs abbreviate - # this to +authcid+. - attr_reader :username - alias authcid username - - # A password or passphrase that matches the #username. - attr_reader :password - alias secret password - - # Authorization identity: an identity to act as or on behalf of. The - # identity form is application protocol specific. If not provided or - # left blank, the server derives an authorization identity from the - # authentication identity. For example, an administrator or superuser - # might take on another role: - # - # imap.authenticate "SCRAM-SHA-256", "root", passwd, authzid: "user" - # - # The server is responsible for verifying the client's credentials and - # verifying that the identity it associates with the client's - # authentication identity is allowed to act as (or on behalf of) the - # authorization identity. - attr_reader :authzid - - # The minimal allowed iteration count. Lower #iterations will raise an - # Error. - attr_reader :min_iterations - - # The client nonce, generated by SecureRandom - attr_reader :cnonce - - # The server nonce, which must start with #cnonce - attr_reader :snonce - - # The salt used by the server for this user - attr_reader :salt - - # The iteration count for the selected hash function and user - attr_reader :iterations - - # An error reported by the server during the \SASL exchange. - # - # Does not include errors reported by the protocol, e.g. - # Net::IMAP::NoResponseError. - attr_reader :server_error - - # Returns a new OpenSSL::Digest object, set to the appropriate hash - # function for the chosen mechanism. - # - # The class's +DIGEST_NAME+ constant must be set to the name of an - # algorithm supported by OpenSSL::Digest. - def digest; OpenSSL::Digest.new self.class::DIGEST_NAME end - - # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] - # +client-first-message+. - def initial_client_response - "#{gs2_header}#{client_first_message_bare}" - end - - # responds to the server's challenges - def process(challenge) - case (@state ||= :initial_client_response) - when :initial_client_response - initial_client_response.tap { @state = :server_first_message } - when :server_first_message - recv_server_first_message challenge - final_message_with_proof.tap { @state = :server_final_message } - when :server_final_message - recv_server_final_message challenge - "".tap { @state = :done } - else - raise Error, "server sent after complete, %p" % [challenge] - end - rescue Exception => ex - @state = ex - raise - end - - # Is the authentication exchange complete? - # - # If false, another server continuation is required. - def done?; @state == :done end - - private - - # Need to store this for auth_message - attr_reader :server_first_message - - def format_message(hash) hash.map { _1.join("=") }.join(",") end - - def recv_server_first_message(server_first_message) - @server_first_message = server_first_message - sparams = parse_challenge server_first_message - @snonce = sparams["r"] or - raise Error, "server did not send nonce" - @salt = sparams["s"]&.unpack1("m") or - raise Error, "server did not send salt" - @iterations = sparams["i"]&.then {|i| Integer i } or - raise Error, "server did not send iteration count" - min_iterations <= iterations or - raise Error, "too few iterations: %d" % [iterations] - mext = sparams["m"] and - raise Error, "mandatory extension: %p" % [mext] - snonce.start_with? cnonce or - raise Error, "invalid server nonce" - end - - def recv_server_final_message(server_final_message) - sparams = parse_challenge server_final_message - @server_error = sparams["e"] and - raise Error, "server error: %s" % [server_error] - verifier = sparams["v"].unpack1("m") or - raise Error, "server did not send verifier" - verifier == server_signature or - raise Error, "server verify failed: %p != %p" % [ - server_signature, verifier - ] - end - - # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] - # +client-first-message-bare+. - def client_first_message_bare - @client_first_message_bare ||= - format_message(n: gs2_saslname_encode(SASL.saslprep(username)), - r: cnonce) - end - - # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] - # +client-final-message+. - def final_message_with_proof - proof = [client_proof].pack("m0") - "#{client_final_message_without_proof},p=#{proof}" - end - - # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] - # +client-final-message-without-proof+. - def client_final_message_without_proof - @client_final_message_without_proof ||= - format_message(c: [cbind_input].pack("m0"), # channel-binding - r: snonce) # nonce - end - - # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] - # +cbind-input+. - # - # >>> - # *TODO:* implement channel binding, appending +cbind-data+ here. - alias cbind_input gs2_header - - # RFC5802 specifies "that the order of attributes in client or server - # messages is fixed, with the exception of extension attributes", but - # this parses it simply as a hash, without respect to order. Note that - # repeated keys (violating the spec) will use the last value. - def parse_challenge(challenge) - challenge.split(/,/).to_h {|pair| pair.split(/=/, 2) } - rescue ArgumentError - raise Error, "unparsable challenge: %p" % [challenge] - end - - end - - # Authenticator for the "+SCRAM-SHA-1+" SASL mechanism, defined in - # RFC5802[https://tools.ietf.org/html/rfc5802]. - # - # Uses the "SHA-1" digest algorithm from OpenSSL::Digest. - # - # See ScramAuthenticator. - class ScramSHA1Authenticator < ScramAuthenticator - DIGEST_NAME = "SHA1" - end - - # Authenticator for the "+SCRAM-SHA-256+" SASL mechanism, defined in - # RFC7677[https://tools.ietf.org/html/rfc7677]. - # - # Uses the "SHA-256" digest algorithm from OpenSSL::Digest. - # - # See ScramAuthenticator. - class ScramSHA256Authenticator < ScramAuthenticator - DIGEST_NAME = "SHA256" - end - - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/stringprep.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/stringprep.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/stringprep.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/stringprep.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,12 +0,0 @@ -# frozen_string_literal: true - -module Net::IMAP::SASL - - # Alias for Net::IMAP::StringPrep::SASLprep. - SASLprep = Net::IMAP::StringPrep::SASLprep - StringPrep = Net::IMAP::StringPrep # :nodoc: - BidiStringError = Net::IMAP::StringPrep::BidiStringError # :nodoc: - ProhibitedCodepoint = Net::IMAP::StringPrep::ProhibitedCodepoint # :nodoc: - StringPrepError = Net::IMAP::StringPrep::StringPrepError # :nodoc: - -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/xoauth2_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/xoauth2_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/xoauth2_authenticator.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl/xoauth2_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,106 +0,0 @@ -# frozen_string_literal: true - -# Authenticator for the "+XOAUTH2+" SASL mechanism. This mechanism was -# originally created for GMail and widely adopted by hosted email providers. -# +XOAUTH2+ has been documented by -# Google[https://developers.google.com/gmail/imap/xoauth2-protocol] and -# Microsoft[https://learn.microsoft.com/en-us/exchange/client-developer/legacy-protocols/how-to-authenticate-an-imap-pop-smtp-application-by-using-oauth]. -# -# This mechanism requires an OAuth2 access token which has been authorized -# with the appropriate OAuth2 scopes to access the user's services. Most of -# these scopes are not standardized---consult each service provider's -# documentation for their scopes. -# -# Although this mechanism was never standardized and has been obsoleted by -# "+OAUTHBEARER+", it is still very widely supported. -# -# See Net::IMAP::SASL::OAuthBearerAuthenticator. -class Net::IMAP::SASL::XOAuth2Authenticator - - # It is unclear from {Google's original XOAUTH2 - # documentation}[https://developers.google.com/gmail/imap/xoauth2-protocol], - # whether "User" refers to the authentication identity (+authcid+) or the - # authorization identity (+authzid+). The authentication identity is - # established for the client by the OAuth token, so it seems that +username+ - # must be the authorization identity. - # - # {Microsoft's documentation for shared - # mailboxes}[https://learn.microsoft.com/en-us/exchange/client-developer/legacy-protocols/how-to-authenticate-an-imap-pop-smtp-application-by-using-oauth#sasl-xoauth2-authentication-for-shared-mailboxes-in-office-365] - # _clearly_ indicates that the Office 365 server interprets it as the - # authorization identity. - # - # Although they _should_ validate that the token has been authorized to access - # the service for +username+, _some_ servers appear to ignore this field, - # relying only the identity and scope authorized by the token. - attr_reader :username - - # Note that, unlike most other authenticators, #username is an alias for the - # authorization identity and not the authentication identity. The - # authenticated identity is established for the client by the #oauth2_token. - alias authzid username - - # An OAuth2 access token which has been authorized with the appropriate OAuth2 - # scopes to use the service for #username. - attr_reader :oauth2_token - alias secret oauth2_token - - # :call-seq: - # new(username, oauth2_token, **) -> authenticator - # new(username:, oauth2_token:, **) -> authenticator - # new(authzid:, oauth2_token:, **) -> authenticator - # - # Creates an Authenticator for the "+XOAUTH2+" SASL mechanism, as specified by - # Google[https://developers.google.com/gmail/imap/xoauth2-protocol], - # Microsoft[https://learn.microsoft.com/en-us/exchange/client-developer/legacy-protocols/how-to-authenticate-an-imap-pop-smtp-application-by-using-oauth] - # and Yahoo[https://senders.yahooinc.com/developer/documentation]. - # - # === Properties - # - # * #username --- the username for the account being accessed. - # - # #authzid --- an alias for #username. - # - # Note that, unlike some other authenticators, +username+ sets the - # _authorization_ identity and not the _authentication_ identity. The - # authenticated identity is established for the client with the OAuth token. - # - # * #oauth2_token --- An OAuth2.0 access token which is authorized to access - # the service for #username. - # - # Any other keyword parameters are quietly ignored. - def initialize(user = nil, token = nil, username: nil, oauth2_token: nil, - authzid: nil, secret: nil, **) - @username = authzid || username || user or - raise ArgumentError, "missing username (authzid)" - @oauth2_token = oauth2_token || secret || token or - raise ArgumentError, "missing oauth2_token" - @done = false - end - - # :call-seq: - # initial_response? -> true - # - # +XOAUTH2+ can send an initial client response. - def initial_response?; true end - - # Returns the XOAUTH2 formatted response, which combines the +username+ - # with the +oauth2_token+. - def process(_data) - build_oauth2_string(@username, @oauth2_token) - ensure - @done = true - end - - # Returns true when the initial client response was sent. - # - # The authentication should not succeed unless this returns true, but it - # does *not* indicate success. - def done?; @done end - - private - - def build_oauth2_string(username, oauth2_token) - format("user=%s\1auth=Bearer %s\1\1", username, oauth2_token) - end - -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,179 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - - # Pluggable authentication mechanisms for protocols which support SASL - # (Simple Authentication and Security Layer), such as IMAP4, SMTP, LDAP, and - # XMPP. {RFC-4422}[https://tools.ietf.org/html/rfc4422] specifies the - # common \SASL framework: - # >>> - # SASL is conceptually a framework that provides an abstraction layer - # between protocols and mechanisms as illustrated in the following - # diagram. - # - # SMTP LDAP XMPP Other protocols ... - # \ | | / - # \ | | / - # SASL abstraction layer - # / | | \ - # / | | \ - # EXTERNAL GSSAPI PLAIN Other mechanisms ... - # - # Net::IMAP uses SASL via the Net::IMAP#authenticate method. - # - # == Mechanisms - # - # Each mechanism has different properties and requirements. Please consult - # the documentation for the specific mechanisms you are using: - # - # +ANONYMOUS+:: - # See AnonymousAuthenticator. - # - # Allows the user to gain access to public services or resources without - # authenticating or disclosing an identity. - # - # +EXTERNAL+:: - # See ExternalAuthenticator. - # - # Authenticates using already established credentials, such as a TLS - # certificate or IPSec. - # - # +OAUTHBEARER+:: - # See OAuthBearerAuthenticator. - # - # Login using an OAuth2 Bearer token. This is the standard mechanism - # for using OAuth2 with \SASL, but it is not yet deployed as widely as - # +XOAUTH2+. - # - # +PLAIN+:: - # See PlainAuthenticator. - # - # Login using clear-text username and password. - # - # +SCRAM-SHA-1+:: - # +SCRAM-SHA-256+:: - # See ScramAuthenticator. - # - # Login by username and password. The password is not sent to the - # server but is used in a salted challenge/response exchange. - # +SCRAM-SHA-1+ and +SCRAM-SHA-256+ are directly supported by - # Net::IMAP::SASL. New authenticators can easily be added for any other - # SCRAM-* mechanism if the digest algorithm is supported by - # OpenSSL::Digest. - # - # +XOAUTH2+:: - # See XOAuth2Authenticator. - # - # Login using a username and an OAuth2 access token. Non-standard and - # obsoleted by +OAUTHBEARER+, but widely supported. - # - # See the {SASL mechanism - # registry}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] - # for a list of all SASL mechanisms and their specifications. To register - # new authenticators, see Authenticators. - # - # === Deprecated mechanisms - # - # Obsolete mechanisms should be avoided, but are still available for - # backwards compatibility. - # - # >>> - # For +DIGEST-MD5+ see DigestMD5Authenticator. - # - # For +LOGIN+, see LoginAuthenticator. - # - # For +CRAM-MD5+, see CramMD5Authenticator. - # - # Using a deprecated mechanism will print a warning. - # - module SASL - # Exception class for any client error detected during the authentication - # exchange. - # - # When the _server_ reports an authentication failure, it will respond - # with a protocol specific error instead, e.g: +BAD+ or +NO+ in IMAP. - # - # When the client encounters any error, it *must* consider the - # authentication exchange to be unsuccessful and it might need to drop the - # connection. For example, if the server reports that the authentication - # exchange was successful or the protocol does not allow additional - # authentication attempts. - Error = Class.new(StandardError) - - # Indicates an authentication exchange that will be or has been canceled - # by the client, not due to any error or failure during processing. - AuthenticationCanceled = Class.new(Error) - - # Indicates an error when processing a server challenge, e.g: an invalid - # or unparsable challenge. An underlying exception may be available as - # the exception's #cause. - AuthenticationError = Class.new(Error) - - # Indicates that authentication cannot proceed because one of the server's - # messages has not passed integrity checks. - AuthenticationFailed = Class.new(Error) - - # Indicates that authentication cannot proceed because one of the server's - # ended authentication prematurely. - class AuthenticationIncomplete < AuthenticationFailed - # The success response from the server - attr_reader :response - - def initialize(response, message = "authentication ended prematurely") - super(message) - @response = response - end - end - - # autoloading to avoid loading all of the regexps when they aren't used. - sasl_stringprep_rb = File.expand_path("sasl/stringprep", __dir__) - autoload :StringPrep, sasl_stringprep_rb - autoload :SASLprep, sasl_stringprep_rb - autoload :StringPrepError, sasl_stringprep_rb - autoload :ProhibitedCodepoint, sasl_stringprep_rb - autoload :BidiStringError, sasl_stringprep_rb - - sasl_dir = File.expand_path("sasl", __dir__) - autoload :AuthenticationExchange, "#{sasl_dir}/authentication_exchange" - autoload :ClientAdapter, "#{sasl_dir}/client_adapter" - autoload :ProtocolAdapters, "#{sasl_dir}/protocol_adapters" - - autoload :Authenticators, "#{sasl_dir}/authenticators" - autoload :GS2Header, "#{sasl_dir}/gs2_header" - autoload :ScramAlgorithm, "#{sasl_dir}/scram_algorithm" - - autoload :AnonymousAuthenticator, "#{sasl_dir}/anonymous_authenticator" - autoload :ExternalAuthenticator, "#{sasl_dir}/external_authenticator" - autoload :OAuthBearerAuthenticator, "#{sasl_dir}/oauthbearer_authenticator" - autoload :PlainAuthenticator, "#{sasl_dir}/plain_authenticator" - autoload :ScramAuthenticator, "#{sasl_dir}/scram_authenticator" - autoload :ScramSHA1Authenticator, "#{sasl_dir}/scram_authenticator" - autoload :ScramSHA256Authenticator, "#{sasl_dir}/scram_authenticator" - autoload :XOAuth2Authenticator, "#{sasl_dir}/xoauth2_authenticator" - - autoload :CramMD5Authenticator, "#{sasl_dir}/cram_md5_authenticator" - autoload :DigestMD5Authenticator, "#{sasl_dir}/digest_md5_authenticator" - autoload :LoginAuthenticator, "#{sasl_dir}/login_authenticator" - - # Returns the default global SASL::Authenticators instance. - def self.authenticators; @authenticators ||= Authenticators.new end - - # Delegates to registry.new See Authenticators#new. - def self.authenticator(*args, registry: authenticators, **kwargs, &block) - registry.new(*args, **kwargs, &block) - end - - # Delegates to ::authenticators. See Authenticators#add_authenticator. - def self.add_authenticator(...) authenticators.add_authenticator(...) end - - module_function - - # See Net::IMAP::StringPrep::SASLprep#saslprep. - def saslprep(string, **opts) - Net::IMAP::StringPrep::SASLprep.saslprep(string, **opts) - end - - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl_adapter.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl_adapter.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl_adapter.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sasl_adapter.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,21 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - - # Experimental - class SASLAdapter < SASL::ClientAdapter - include SASL::ProtocolAdapters::IMAP - - RESPONSE_ERRORS = [NoResponseError, BadResponseError, ByeResponseError] - .freeze - - def response_errors; RESPONSE_ERRORS end - def sasl_ir_capable?; client.capable?("SASL-IR") end - def auth_capable?(mechanism); client.auth_capable?(mechanism) end - def drop_connection; client.logout! end - def drop_connection!; client.disconnect end - end - - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/search_result.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/search_result.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/search_result.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/search_result.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,146 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - - # An array of sequence numbers returned by Net::IMAP#search, or unique - # identifiers returned by Net::IMAP#uid_search. - # - # For backward compatibility, SearchResult inherits from Array. - class SearchResult < Array - - # Returns a SearchResult populated with the given +seq_nums+. - # - # Net::IMAP::SearchResult[1, 3, 5, modseq: 9] - # # => Net::IMAP::SearchResult[1, 3, 5, modseq: 9] - def self.[](*seq_nums, modseq: nil) - new(seq_nums, modseq: modseq) - end - - # A modification sequence number, as described by the +CONDSTORE+ - # extension in {[RFC7162 - # §3.1.6]}[https://www.rfc-editor.org/rfc/rfc7162.html#section-3.1.6]. - attr_reader :modseq - - # Returns a SearchResult populated with the given +seq_nums+. - # - # Net::IMAP::SearchResult.new([1, 3, 5], modseq: 9) - # # => Net::IMAP::SearchResult[1, 3, 5, modseq: 9] - def initialize(seq_nums, modseq: nil) - super(seq_nums.to_ary.map { Integer _1 }) - @modseq = Integer modseq if modseq - end - - # Returns whether +other+ is a SearchResult with the same values and the - # same #modseq. The order of numbers is irrelevant. - # - # Net::IMAP::SearchResult[123, 456, modseq: 789] == - # Net::IMAP::SearchResult[123, 456, modseq: 789] - # # => true - # Net::IMAP::SearchResult[123, 456, modseq: 789] == - # Net::IMAP::SearchResult[456, 123, modseq: 789] - # # => true - # - # Net::IMAP::SearchResult[123, 456, modseq: 789] == - # Net::IMAP::SearchResult[987, 654, modseq: 789] - # # => false - # Net::IMAP::SearchResult[123, 456, modseq: 789] == - # Net::IMAP::SearchResult[1, 2, 3, modseq: 9999] - # # => false - # - # SearchResult can be compared directly with Array, if #modseq is nil and - # the array is sorted. - # - # Net::IMAP::SearchResult[9, 8, 6, 4, 1] == [1, 4, 6, 8, 9] # => true - # Net::IMAP::SearchResult[3, 5, 7, modseq: 99] == [3, 5, 7] # => false - # - # Note that Array#== does require matching order and ignores #modseq. - # - # [9, 8, 6, 4, 1] == Net::IMAP::SearchResult[1, 4, 6, 8, 9] # => false - # [3, 5, 7] == Net::IMAP::SearchResult[3, 5, 7, modseq: 99] # => true - # - def ==(other) - (modseq ? - other.is_a?(self.class) && modseq == other.modseq : - other.is_a?(Array)) && - size == other.size && - sort == other.sort - end - - # Hash equality. Unlike #==, order will be taken into account. - def hash - return super if modseq.nil? - [super, self.class, modseq].hash - end - - # Hash equality. Unlike #==, order will be taken into account. - def eql?(other) - return super if modseq.nil? - self.class == other.class && hash == other.hash - end - - # Returns a string that represents the SearchResult. - # - # Net::IMAP::SearchResult[123, 456, 789].inspect - # # => "[123, 456, 789]" - # - # Net::IMAP::SearchResult[543, 210, 678, modseq: 2048].inspect - # # => "Net::IMAP::SearchResult[543, 210, 678, modseq: 2048]" - # - def inspect - return super if modseq.nil? - "%s[%s, modseq: %p]" % [self.class, join(", "), modseq] - end - - # Returns a string that follows the formal \IMAP syntax. - # - # data = Net::IMAP::SearchResult[2, 8, 32, 128, 256, 512] - # data.to_s # => "* SEARCH 2 8 32 128 256 512" - # data.to_s("SEARCH") # => "* SEARCH 2 8 32 128 256 512" - # data.to_s("SORT") # => "* SORT 2 8 32 128 256 512" - # data.to_s(nil) # => "2 8 32 128 256 512" - # - # data = Net::IMAP::SearchResult[1, 3, 16, 1024, modseq: 2048].to_s - # data.to_s # => "* SEARCH 1 3 16 1024 (MODSEQ 2048)" - # data.to_s("SORT") # => "* SORT 1 3 16 1024 (MODSEQ 2048)" - # data.to_s # => "1 3 16 1024 (MODSEQ 2048)" - # - def to_s(type = "SEARCH") - str = +"" - str << "* %s " % [type.to_str] unless type.nil? - str << join(" ") - str << " (MODSEQ %d)" % [modseq] if modseq - -str - end - - # Converts the SearchResult into a SequenceSet. - # - # Net::IMAP::SearchResult[9, 1, 2, 4, 10, 12, 3, modseq: 123_456] - # .to_sequence_set - # # => Net::IMAP::SequenceSet["1:4,9:10,12"] - def to_sequence_set; SequenceSet[*self] end - - def pretty_print(pp) - return super if modseq.nil? - pp.text self.class.name + "[" - pp.group_sub do - pp.nest(2) do - pp.breakable "" - each do |num| - pp.pp num - pp.text "," - pp.fill_breakable - end - pp.breakable "" - pp.text "modseq: " - pp.pp modseq - end - pp.breakable "" - pp.text "]" - end - end - - end - - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sequence_set.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sequence_set.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/sequence_set.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/sequence_set.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,1570 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - - ## - # An \IMAP sequence set is a set of message sequence numbers or unique - # identifier numbers ("UIDs"). It contains numbers and ranges of numbers. - # The numbers are all non-zero unsigned 32-bit integers and one special - # value ("*") that represents the largest value in the mailbox. - # - # Certain types of \IMAP responses will contain a SequenceSet, for example - # the data for a "MODIFIED" ResponseCode. Some \IMAP commands may - # receive a SequenceSet as an argument, for example IMAP#search, IMAP#fetch, - # and IMAP#store. - # - # == EXPERIMENTAL API - # - # SequenceSet is currently experimental. Only two methods, ::[] and - # #valid_string, are considered stable. Although the API isn't expected to - # change much, any other methods may be removed or changed without - # deprecation. - # - # == Creating sequence sets - # - # SequenceSet.new with no arguments creates an empty sequence set. Note - # that an empty sequence set is invalid in the \IMAP grammar. - # - # set = Net::IMAP::SequenceSet.new - # set.empty? #=> true - # set.valid? #=> false - # set.valid_string #!> raises DataFormatError - # set << 1..10 - # set.empty? #=> false - # set.valid? #=> true - # set.valid_string #=> "1:10" - # - # SequenceSet.new may receive a single optional argument: a non-zero 32 bit - # unsigned integer, a range, a sequence-set formatted string, - # another sequence set, or an enumerable containing any of these. - # - # set = Net::IMAP::SequenceSet.new(1) - # set.valid_string #=> "1" - # set = Net::IMAP::SequenceSet.new(1..100) - # set.valid_string #=> "1:100" - # set = Net::IMAP::SequenceSet.new(1...100) - # set.valid_string #=> "1:99" - # set = Net::IMAP::SequenceSet.new([1, 2, 5..]) - # set.valid_string #=> "1:2,5:*" - # set = Net::IMAP::SequenceSet.new("1,2,3:7,5,6:10,2048,1024") - # set.valid_string #=> "1,2,3:7,5,6:10,2048,1024" - # set = Net::IMAP::SequenceSet.new(1, 2, 3..7, 5, 6..10, 2048, 1024) - # set.valid_string #=> "1:10,55,1024:2048" - # - # Use ::[] with one or more arguments to create a frozen SequenceSet. An - # invalid (empty) set cannot be created with ::[]. - # - # set = Net::IMAP::SequenceSet["1,2,3:7,5,6:10,2048,1024"] - # set.valid_string #=> "1,2,3:7,5,6:10,2048,1024" - # set = Net::IMAP::SequenceSet[1, 2, [3..7, 5], 6..10, 2048, 1024] - # set.valid_string #=> "1:10,55,1024:2048" - # - # == Ordered and Normalized sets - # - # Sometimes the order of the set's members is significant, such as with the - # +ESORT+, CONTEXT=SORT, and +UIDPLUS+ extensions. So, when a - # sequence set is created by the parser or with a single string value, that - # #string representation is preserved. - # - # Internally, SequenceSet stores a normalized representation which sorts all - # entries, de-duplicates numbers, and coalesces adjacent or overlapping - # ranges. Most methods use this normalized representation to achieve - # O(lg n) porformance. Use #entries or #each_entry to enumerate - # the set in its original order. - # - # Most modification methods convert #string to its normalized form. To - # preserve #string order while modifying a set, use #append, #string=, or - # #replace. - # - # == Using * - # - # \IMAP sequence sets may contain a special value "*", which - # represents the largest number in use. From +seq-number+ in - # {RFC9051 §9}[https://www.rfc-editor.org/rfc/rfc9051.html#section-9-5]: - # >>> - # In the case of message sequence numbers, it is the number of messages - # in a non-empty mailbox. In the case of unique identifiers, it is the - # unique identifier of the last message in the mailbox or, if the - # mailbox is empty, the mailbox's current UIDNEXT value. - # - # When creating a SequenceSet, * may be input as -1, - # "*", :*, an endless range, or a range ending in - # -1. When converting to #elements, #ranges, or #numbers, it will - # output as either :* or an endless range. For example: - # - # Net::IMAP::SequenceSet["1,3,*"].to_a #=> [1, 3, :*] - # Net::IMAP::SequenceSet["1,234:*"].to_a #=> [1, 234..] - # Net::IMAP::SequenceSet[1234..-1].to_a #=> [1234..] - # Net::IMAP::SequenceSet[1234..].to_a #=> [1234..] - # - # Net::IMAP::SequenceSet[1234..].to_s #=> "1234:*" - # Net::IMAP::SequenceSet[1234..-1].to_s #=> "1234:*" - # - # Use #limit to convert "*" to a maximum value. When a range - # includes "*", the maximum value will always be matched: - # - # Net::IMAP::SequenceSet["9999:*"].limit(max: 25) - # #=> Net::IMAP::SequenceSet["25"] - # - # === Surprising * behavior - # - # When a set includes *, some methods may have surprising behavior. - # - # For example, #complement treats * as its own number. This way, - # the #intersection of a set and its #complement will always be empty. - # This is not how an \IMAP server interprets the set: it will convert - # * to either the number of messages in the mailbox or +UIDNEXT+, - # as appropriate. And there _will_ be overlap between a set and its - # complement after #limit is applied to each: - # - # ~Net::IMAP::SequenceSet["*"] == Net::IMAP::SequenceSet[1..(2**32-1)] - # ~Net::IMAP::SequenceSet[1..5] == Net::IMAP::SequenceSet["6:*"] - # - # set = Net::IMAP::SequenceSet[1..5] - # (set & ~set).empty? => true - # - # (set.limit(max: 4) & (~set).limit(max: 4)).to_a => [4] - # - # When counting the number of numbers in a set, * will be counted - # _except_ when UINT32_MAX is also in the set: - # UINT32_MAX = 2**32 - 1 - # Net::IMAP::SequenceSet["*"].count => 1 - # Net::IMAP::SequenceSet[1..UINT32_MAX - 1, :*].count => UINT32_MAX - # - # Net::IMAP::SequenceSet["1:*"].count => UINT32_MAX - # Net::IMAP::SequenceSet[UINT32_MAX, :*].count => 1 - # Net::IMAP::SequenceSet[UINT32_MAX..].count => 1 - # - # == What's here? - # - # SequenceSet provides methods for: - # * {Creating a SequenceSet}[rdoc-ref:SequenceSet@Methods+for+Creating+a+SequenceSet] - # * {Comparing}[rdoc-ref:SequenceSet@Methods+for+Comparing] - # * {Querying}[rdoc-ref:SequenceSet@Methods+for+Querying] - # * {Iterating}[rdoc-ref:SequenceSet@Methods+for+Iterating] - # * {Set Operations}[rdoc-ref:SequenceSet@Methods+for+Set+Operations] - # * {Assigning}[rdoc-ref:SequenceSet@Methods+for+Assigning] - # * {Deleting}[rdoc-ref:SequenceSet@Methods+for+Deleting] - # * {IMAP String Formatting}[rdoc-ref:SequenceSet@Methods+for+IMAP+String+Formatting] - # - # === Methods for Creating a \SequenceSet - # * ::[]: Creates a validated frozen sequence set from one or more inputs. - # * ::new: Creates a new mutable sequence set, which may be empty (invalid). - # * ::try_convert: Calls +to_sequence_set+ on an object and verifies that - # the result is a SequenceSet. - # * ::empty: Returns a frozen empty (invalid) SequenceSet. - # * ::full: Returns a frozen SequenceSet containing every possible number. - # - # === Methods for Comparing - # - # Comparison to another \SequenceSet: - # - #==: Returns whether a given set contains the same numbers as +self+. - # - #eql?: Returns whether a given set uses the same #string as +self+. - # - # Comparison to objects which are convertible to \SequenceSet: - # - #===: - # Returns whether a given object is fully contained within +self+, or - # +nil+ if the object cannot be converted to a compatible type. - # - #cover?: - # Returns whether a given object is fully contained within +self+. - # - #intersect? (aliased as #overlap?): - # Returns whether +self+ and a given object have any common elements. - # - #disjoint?: - # Returns whether +self+ and a given object have no common elements. - # - # === Methods for Querying - # These methods do not modify +self+. - # - # Set membership: - # - #include? (aliased as #member?): - # Returns whether a given object (nz-number, range, or *) is - # contained by the set. - # - #include_star?: Returns whether the set contains *. - # - # Minimum and maximum value elements: - # - #min: Returns the minimum number in the set. - # - #max: Returns the maximum number in the set. - # - #minmax: Returns the minimum and maximum numbers in the set. - # - # Accessing value by offset in sorted set: - # - #[] (aliased as #slice): Returns the number or consecutive subset at a - # given offset or range of offsets in the sorted set. - # - #at: Returns the number at a given offset in the sorted set. - # - #find_index: Returns the given number's offset in the sorted set. - # - # Accessing value by offset in ordered entries - # - #ordered_at: Returns the number at a given offset in the ordered entries. - # - #find_ordered_index: Returns the index of the given number's first - # occurrence in entries. - # - # Set cardinality: - # - #count (aliased as #size): Returns the count of numbers in the set. - # Duplicated numbers are not counted. - # - #empty?: Returns whether the set has no members. \IMAP syntax does not - # allow empty sequence sets. - # - #valid?: Returns whether the set has any members. - # - #full?: Returns whether the set contains every possible value, including - # *. - # - # Denormalized properties: - # - #has_duplicates?: Returns whether the ordered entries repeat any - # numbers. - # - #count_duplicates: Returns the count of repeated numbers in the ordered - # entries. - # - #count_with_duplicates: Returns the count of numbers in the ordered - # entries, including any repeated numbers. - # - # === Methods for Iterating - # - # Normalized (sorted and coalesced): - # - #each_element: Yields each number and range in the set, sorted and - # coalesced, and returns +self+. - # - #elements (aliased as #to_a): Returns an Array of every number and range - # in the set, sorted and coalesced. - # - #each_range: - # Yields each element in the set as a Range and returns +self+. - # - #ranges: Returns an Array of every element in the set, converting - # numbers into ranges of a single value. - # - #each_number: Yields each number in the set and returns +self+. - # - #numbers: Returns an Array with every number in the set, expanding - # ranges into all of their contained numbers. - # - #to_set: Returns a Set containing all of the #numbers in the set. - # - # Order preserving: - # - #each_entry: Yields each number and range in the set, unsorted and - # without deduplicating numbers or coalescing ranges, and returns +self+. - # - #entries: Returns an Array of every number and range in the set, - # unsorted and without deduplicating numbers or coalescing ranges. - # - #each_ordered_number: Yields each number in the ordered entries and - # returns +self+. - # - # === Methods for \Set Operations - # These methods do not modify +self+. - # - # - #| (aliased as #union and #+): Returns a new set combining all members - # from +self+ with all members from the other object. - # - #& (aliased as #intersection): Returns a new set containing all members - # common to +self+ and the other object. - # - #- (aliased as #difference): Returns a copy of +self+ with all members - # in the other object removed. - # - #^ (aliased as #xor): Returns a new set containing all members from - # +self+ and the other object except those common to both. - # - #~ (aliased as #complement): Returns a new set containing all members - # that are not in +self+ - # - #limit: Returns a copy of +self+ which has replaced * with a - # given maximum value and removed all members over that maximum. - # - # === Methods for Assigning - # These methods add or replace elements in +self+. - # - # Normalized (sorted and coalesced): - # - # These methods always update #string to be fully sorted and coalesced. - # - # - #add (aliased as #<<): Adds a given object to the set; returns +self+. - # - #add?: If the given object is not an element in the set, adds it and - # returns +self+; otherwise, returns +nil+. - # - #merge: Merges multiple elements into the set; returns +self+. - # - #complement!: Replaces the contents of the set with its own #complement. - # - # Order preserving: - # - # These methods _may_ cause #string to not be sorted or coalesced. - # - # - #append: Adds a given object to the set, appending it to the existing - # string, and returns +self+. - # - #string=: Assigns a new #string value and replaces #elements to match. - # - #replace: Replaces the contents of the set with the contents - # of a given object. - # - # === Methods for Deleting - # These methods remove elements from +self+, and update #string to be fully - # sorted and coalesced. - # - # - #clear: Removes all elements in the set; returns +self+. - # - #delete: Removes a given object from the set; returns +self+. - # - #delete?: If the given object is an element in the set, removes it and - # returns it; otherwise, returns +nil+. - # - #delete_at: Removes the number at a given offset. - # - #slice!: Removes the number or consecutive numbers at a given offset or - # range of offsets. - # - #subtract: Removes each given object from the set; returns +self+. - # - #limit!: Replaces * with a given maximum value and removes all - # members over that maximum; returns +self+. - # - # === Methods for \IMAP String Formatting - # - # - #to_s: Returns the +sequence-set+ string, or an empty string when the - # set is empty. - # - #string: Returns the +sequence-set+ string, or nil when empty. - # - #valid_string: Returns the +sequence-set+ string, or raises - # DataFormatError when the set is empty. - # - #normalized_string: Returns a sequence-set string with its - # elements sorted and coalesced, or nil when the set is empty. - # - #normalize: Returns a new set with this set's normalized +sequence-set+ - # representation. - # - #normalize!: Updates #string to its normalized +sequence-set+ - # representation and returns +self+. - # - class SequenceSet - # The largest possible non-zero unsigned 32-bit integer - UINT32_MAX = 2**32 - 1 - - # represents "*" internally, to simplify sorting (etc) - STAR_INT = UINT32_MAX + 1 - private_constant :STAR_INT - - # valid inputs for "*" - STARS = [:*, ?*, -1].freeze - private_constant :STAR_INT, :STARS - - COERCIBLE = ->{ _1.respond_to? :to_sequence_set } - ENUMABLE = ->{ _1.respond_to?(:each) && _1.respond_to?(:empty?) } - private_constant :COERCIBLE, :ENUMABLE - - class << self - - # :call-seq: - # SequenceSet[*values] -> valid frozen sequence set - # - # Returns a frozen SequenceSet, constructed from +values+. - # - # An empty SequenceSet is invalid and will raise a DataFormatError. - # - # Use ::new to create a mutable or empty SequenceSet. - def [](first, *rest) - if rest.empty? - if first.is_a?(SequenceSet) && first.frozen? && first.valid? - first - else - new(first).validate.freeze - end - else - new(first).merge(*rest).validate.freeze - end - end - - # :call-seq: - # SequenceSet.try_convert(obj) -> sequence set or nil - # - # If +obj+ is a SequenceSet, returns +obj+. If +obj+ responds_to - # +to_sequence_set+, calls +obj.to_sequence_set+ and returns the result. - # Otherwise returns +nil+. - # - # If +obj.to_sequence_set+ doesn't return a SequenceSet, an exception is - # raised. - def try_convert(obj) - return obj if obj.is_a?(SequenceSet) - return nil unless obj.respond_to?(:to_sequence_set) - obj = obj.to_sequence_set - return obj if obj.is_a?(SequenceSet) - raise DataFormatError, "invalid object returned from to_sequence_set" - end - - # Returns a frozen empty set singleton. Note that valid \IMAP sequence - # sets cannot be empty, so this set is _invalid_. - def empty; EMPTY end - - # Returns a frozen full set singleton: "1:*" - def full; FULL end - - end - - # Create a new SequenceSet object from +input+, which may be another - # SequenceSet, an IMAP formatted +sequence-set+ string, a number, a - # range, :*, or an enumerable of these. - # - # Use ::[] to create a frozen (non-empty) SequenceSet. - def initialize(input = nil) input ? replace(input) : clear end - - # Removes all elements and returns self. - def clear; @tuples, @string = [], nil; self end - - # Replace the contents of the set with the contents of +other+ and returns - # +self+. - # - # +other+ may be another SequenceSet, or it may be an IMAP +sequence-set+ - # string, a number, a range, *, or an enumerable of these. - def replace(other) - case other - when SequenceSet then initialize_dup(other) - when String then self.string = other - else clear; merge other - end - self - end - - # Returns the \IMAP +sequence-set+ string representation, or raises a - # DataFormatError when the set is empty. - # - # Use #string to return +nil+ or #to_s to return an empty string without - # error. - # - # Related: #string, #normalized_string, #to_s - def valid_string - raise DataFormatError, "empty sequence-set" if empty? - string - end - - # Returns the \IMAP +sequence-set+ string representation, or +nil+ when - # the set is empty. Note that an empty set is invalid in the \IMAP - # syntax. - # - # Use #valid_string to raise an exception when the set is empty, or #to_s - # to return an empty string. - # - # If the set was created from a single string, it is not normalized. If - # the set is updated the string will be normalized. - # - # Related: #valid_string, #normalized_string, #to_s - def string; @string ||= normalized_string if valid? end - - # Assigns a new string to #string and resets #elements to match. It - # cannot be set to an empty string—assign +nil+ or use #clear instead. - # The string is validated but not normalized. - # - # Use #add or #merge to add a string to an existing set. - # - # Related: #replace, #clear - def string=(str) - if str.nil? - clear - else - str = String.try_convert(str) or raise ArgumentError, "not a string" - tuples = str_to_tuples str - @tuples, @string = [], -str - tuples_add tuples - end - end - - # Returns the \IMAP +sequence-set+ string representation, or an empty - # string when the set is empty. Note that an empty set is invalid in the - # \IMAP syntax. - # - # Related: #valid_string, #normalized_string, #to_s - def to_s; string || "" end - - # Freezes and returns the set. A frozen SequenceSet is Ractor-safe. - def freeze - return self if frozen? - string - @tuples.each(&:freeze).freeze - super - end - - # :call-seq: self == other -> true or false - # - # Returns true when the other SequenceSet represents the same message - # identifiers. Encoding difference—such as order, overlaps, or - # duplicates—are ignored. - # - # Net::IMAP::SequenceSet["1:3"] == Net::IMAP::SequenceSet["1:3"] - # #=> true - # Net::IMAP::SequenceSet["1,2,3"] == Net::IMAP::SequenceSet["1:3"] - # #=> true - # Net::IMAP::SequenceSet["1,3"] == Net::IMAP::SequenceSet["3,1"] - # #=> true - # Net::IMAP::SequenceSet["9,1:*"] == Net::IMAP::SequenceSet["1:*"] - # #=> true - # - # Related: #eql?, #normalize - def ==(other) - self.class == other.class && - (to_s == other.to_s || tuples == other.tuples) - end - - # :call-seq: eql?(other) -> true or false - # - # Hash equality requires the same encoded #string representation. - # - # Net::IMAP::SequenceSet["1:3"] .eql? Net::IMAP::SequenceSet["1:3"] - # #=> true - # Net::IMAP::SequenceSet["1,2,3"].eql? Net::IMAP::SequenceSet["1:3"] - # #=> false - # Net::IMAP::SequenceSet["1,3"] .eql? Net::IMAP::SequenceSet["3,1"] - # #=> false - # Net::IMAP::SequenceSet["9,1:*"].eql? Net::IMAP::SequenceSet["1:*"] - # #=> false - # - # Related: #==, #normalize - def eql?(other) self.class == other.class && string == other.string end - - # See #eql? - def hash; [self.class, string].hash end - - # :call-seq: self === other -> true | false | nil - # - # Returns whether +other+ is contained within the set. Returns +nil+ if a - # StandardError is raised while converting +other+ to a comparable type. - # - # Related: #cover?, #include?, #include_star? - def ===(other) - cover?(other) - rescue - nil - end - - # :call-seq: cover?(other) -> true | false | nil - # - # Returns whether +other+ is contained within the set. +other+ may be any - # object that would be accepted by ::new. - # - # Related: #===, #include?, #include_star? - def cover?(other) input_to_tuples(other).none? { !include_tuple?(_1) } end - - # Returns +true+ when a given number or range is in +self+, and +false+ - # otherwise. Returns +false+ unless +number+ is an Integer, Range, or - # *. - # - # set = Net::IMAP::SequenceSet["5:10,100,111:115"] - # set.include? 1 #=> false - # set.include? 5..10 #=> true - # set.include? 11..20 #=> false - # set.include? 100 #=> true - # set.include? 6 #=> true, covered by "5:10" - # set.include? 4..9 #=> true, covered by "5:10" - # set.include? "4:9" #=> true, strings are parsed - # set.include? 4..9 #=> false, intersection is not sufficient - # set.include? "*" #=> false, use #limit to re-interpret "*" - # set.include? -1 #=> false, -1 is interpreted as "*" - # - # set = Net::IMAP::SequenceSet["5:10,100,111:*"] - # set.include? :* #=> true - # set.include? "*" #=> true - # set.include? -1 #=> true - # set.include? 200.. #=> true - # set.include? 100.. #=> false - # - # Related: #include_star?, #cover?, #=== - def include?(element) include_tuple? input_to_tuple element end - - alias member? include? - - # Returns +true+ when the set contains *. - def include_star?; @tuples.last&.last == STAR_INT end - - # Returns +true+ if the set and a given object have any common elements, - # +false+ otherwise. - # - # Net::IMAP::SequenceSet["5:10"].intersect? "7,9,11" #=> true - # Net::IMAP::SequenceSet["5:10"].intersect? "11:33" #=> false - # - # Related: #intersection, #disjoint? - def intersect?(other) - valid? && input_to_tuples(other).any? { intersect_tuple? _1 } - end - alias overlap? intersect? - - # Returns +true+ if the set and a given object have no common elements, - # +false+ otherwise. - # - # Net::IMAP::SequenceSet["5:10"].disjoint? "7,9,11" #=> false - # Net::IMAP::SequenceSet["5:10"].disjoint? "11:33" #=> true - # - # Related: #intersection, #intersect? - def disjoint?(other) - empty? || input_to_tuples(other).none? { intersect_tuple? _1 } - end - - # :call-seq: max(star: :*) => integer or star or nil - # - # Returns the maximum value in +self+, +star+ when the set includes - # *, or +nil+ when the set is empty. - def max(star: :*) - (val = @tuples.last&.last) && val == STAR_INT ? star : val - end - - # :call-seq: min(star: :*) => integer or star or nil - # - # Returns the minimum value in +self+, +star+ when the only value in the - # set is *, or +nil+ when the set is empty. - def min(star: :*) - (val = @tuples.first&.first) && val == STAR_INT ? star : val - end - - # :call-seq: minmax(star: :*) => nil or [integer, integer or star] - # - # Returns a 2-element array containing the minimum and maximum numbers in - # +self+, or +nil+ when the set is empty. - def minmax(star: :*); [min(star: star), max(star: star)] unless empty? end - - # Returns false when the set is empty. - def valid?; !empty? end - - # Returns true if the set contains no elements - def empty?; @tuples.empty? end - - # Returns true if the set contains every possible element. - def full?; @tuples == [[1, STAR_INT]] end - - # :call-seq: - # self + other -> sequence set - # self | other -> sequence set - # union(other) -> sequence set - # - # Returns a new sequence set that has every number in the +other+ object - # added. - # - # +other+ may be any object that would be accepted by ::new: a non-zero 32 - # bit unsigned integer, range, sequence-set formatted string, - # another sequence set, or an enumerable containing any of these. - # - # Net::IMAP::SequenceSet["1:5"] | 2 | [4..6, 99] - # #=> Net::IMAP::SequenceSet["1:6,99"] - # - # Related: #add, #merge - def |(other) remain_frozen dup.merge other end - alias :+ :| - alias union :| - - # :call-seq: - # self - other -> sequence set - # difference(other) -> sequence set - # - # Returns a new sequence set built by duplicating this set and removing - # every number that appears in +other+. - # - # +other+ may be any object that would be accepted by ::new: a non-zero 32 - # bit unsigned integer, range, sequence-set formatted string, - # another sequence set, or an enumerable containing any of these. - # - # Net::IMAP::SequenceSet[1..5] - 2 - 4 - 6 - # #=> Net::IMAP::SequenceSet["1,3,5"] - # - # Related: #subtract - def -(other) remain_frozen dup.subtract other end - alias difference :- - - # :call-seq: - # self & other -> sequence set - # intersection(other) -> sequence set - # - # Returns a new sequence set containing only the numbers common to this - # set and +other+. - # - # +other+ may be any object that would be accepted by ::new: a non-zero 32 - # bit unsigned integer, range, sequence-set formatted string, - # another sequence set, or an enumerable containing any of these. - # - # Net::IMAP::SequenceSet[1..5] & [2, 4, 6] - # #=> Net::IMAP::SequenceSet["2,4"] - # - # (seqset & other) is equivalent to (seqset - ~other). - def &(other) - remain_frozen dup.subtract SequenceSet.new(other).complement! - end - alias intersection :& - - # :call-seq: - # self ^ other -> sequence set - # xor(other) -> sequence set - # - # Returns a new sequence set containing numbers that are exclusive between - # this set and +other+. - # - # +other+ may be any object that would be accepted by ::new: a non-zero 32 - # bit unsigned integer, range, sequence-set formatted string, - # another sequence set, or an enumerable containing any of these. - # - # Net::IMAP::SequenceSet[1..5] ^ [2, 4, 6] - # #=> Net::IMAP::SequenceSet["1,3,5:6"] - # - # (seqset ^ other) is equivalent to ((seqset | other) - - # (seqset & other)). - def ^(other) remain_frozen (self | other).subtract(self & other) end - alias xor :^ - - # :call-seq: - # ~ self -> sequence set - # complement -> sequence set - # - # Returns the complement of self, a SequenceSet which contains all numbers - # _except_ for those in this set. - # - # ~Net::IMAP::SequenceSet.full #=> Net::IMAP::SequenceSet.empty - # ~Net::IMAP::SequenceSet.empty #=> Net::IMAP::SequenceSet.full - # ~Net::IMAP::SequenceSet["1:5,100:222"] - # #=> Net::IMAP::SequenceSet["6:99,223:*"] - # ~Net::IMAP::SequenceSet["6:99,223:*"] - # #=> Net::IMAP::SequenceSet["1:5,100:222"] - # - # Related: #complement! - def ~; remain_frozen dup.complement! end - alias complement :~ - - # :call-seq: - # add(object) -> self - # self << other -> self - # - # Adds a range or number to the set and returns +self+. - # - # #string will be regenerated. Use #merge to add many elements at once. - # - # Related: #add?, #merge, #union - def add(object) - tuple_add input_to_tuple object - normalize! - end - alias << add - - # Adds a range or number to the set and returns +self+. - # - # Unlike #add, #merge, or #union, the new value is appended to #string. - # This may result in a #string which has duplicates or is out-of-order. - def append(object) - modifying! - tuple = input_to_tuple object - entry = tuple_to_str tuple - string unless empty? # write @string before tuple_add - tuple_add tuple - @string = -(@string ? "#{@string},#{entry}" : entry) - self - end - - # :call-seq: add?(object) -> self or nil - # - # Adds a range or number to the set and returns +self+. Returns +nil+ - # when the object is already included in the set. - # - # #string will be regenerated. Use #merge to add many elements at once. - # - # Related: #add, #merge, #union, #include? - def add?(object) - add object unless include? object - end - - # :call-seq: delete(object) -> self - # - # Deletes the given range or number from the set and returns +self+. - # - # #string will be regenerated after deletion. Use #subtract to remove - # many elements at once. - # - # Related: #delete?, #delete_at, #subtract, #difference - def delete(object) - tuple_subtract input_to_tuple object - normalize! - end - - # :call-seq: - # delete?(number) -> integer or nil - # delete?(star) -> :* or nil - # delete?(range) -> sequence set or nil - # - # Removes a specified value from the set, and returns the removed value. - # Returns +nil+ if nothing was removed. - # - # Returns an integer when the specified +number+ argument was removed: - # set = Net::IMAP::SequenceSet.new [5..10, 20] - # set.delete?(7) #=> 7 - # set #=> # - # set.delete?("20") #=> 20 - # set #=> # - # set.delete?(30) #=> nil - # - # Returns :* when * or -1 is specified and - # removed: - # set = Net::IMAP::SequenceSet.new "5:9,20,35,*" - # set.delete?(-1) #=> :* - # set #=> # - # - # And returns a new SequenceSet when a range is specified: - # - # set = Net::IMAP::SequenceSet.new [5..10, 20] - # set.delete?(9..) #=> # - # set #=> # - # set.delete?(21..) #=> nil - # - # #string will be regenerated after deletion. - # - # Related: #delete, #delete_at, #subtract, #difference, #disjoint? - def delete?(object) - tuple = input_to_tuple object - if tuple.first == tuple.last - return unless include_tuple? tuple - tuple_subtract tuple - normalize! - from_tuple_int tuple.first - else - copy = dup - tuple_subtract tuple - normalize! - copy if copy.subtract(self).valid? - end - end - - # :call-seq: delete_at(index) -> number or :* or nil - # - # Deletes a number the set, indicated by the given +index+. Returns the - # number that was removed, or +nil+ if nothing was removed. - # - # #string will be regenerated after deletion. - # - # Related: #delete, #delete?, #slice!, #subtract, #difference - def delete_at(index) - slice! Integer(index.to_int) - end - - # :call-seq: - # slice!(index) -> integer or :* or nil - # slice!(start, length) -> sequence set or nil - # slice!(range) -> sequence set or nil - # - # Deletes a number or consecutive numbers from the set, indicated by the - # given +index+, +start+ and +length+, or +range+ of offsets. Returns the - # number or sequence set that was removed, or +nil+ if nothing was - # removed. Arguments are interpreted the same as for #slice or #[]. - # - # #string will be regenerated after deletion. - # - # Related: #slice, #delete_at, #delete, #delete?, #subtract, #difference - def slice!(index, length = nil) - deleted = slice(index, length) and subtract deleted - deleted - end - - # Merges all of the elements that appear in any of the +inputs+ into the - # set, and returns +self+. - # - # The +inputs+ may be any objects that would be accepted by ::new: - # non-zero 32 bit unsigned integers, ranges, sequence-set - # formatted strings, other sequence sets, or enumerables containing any of - # these. - # - # #string will be regenerated after all inputs have been merged. - # - # Related: #add, #add?, #union - def merge(*inputs) - tuples_add input_to_tuples inputs - normalize! - end - - # Removes all of the elements that appear in any of the given +objects+ - # from the set, and returns +self+. - # - # The +objects+ may be any objects that would be accepted by ::new: - # non-zero 32 bit unsigned integers, ranges, sequence-set - # formatted strings, other sequence sets, or enumerables containing any of - # these. - # - # Related: #difference - def subtract(*objects) - tuples_subtract input_to_tuples objects - normalize! - end - - # Returns an array of ranges and integers and :*. - # - # The entries are in the same order they appear in #string, with no - # sorting, deduplication, or coalescing. When #string is in its - # normalized form, this will return the same result as #elements. - # This is useful when the given order is significant, for example in a - # ESEARCH response to IMAP#sort. - # - # Related: #each_entry, #elements - def entries; each_entry.to_a end - - # Returns an array of ranges and integers and :*. - # - # The returned elements are sorted and coalesced, even when the input - # #string is not. * will sort last. See #normalize. - # - # By itself, * translates to :*. A range containing - # * translates to an endless range. Use #limit to translate both - # cases to a maximum value. - # - # The returned elements will be sorted and coalesced, even when the input - # #string is not. * will sort last. See #normalize. - # - # Net::IMAP::SequenceSet["2,5:9,6,*,12:11"].elements - # #=> [2, 5..9, 11..12, :*] - # - # Related: #each_element, #ranges, #numbers - def elements; each_element.to_a end - alias to_a elements - - # Returns an array of ranges - # - # The returned elements are sorted and coalesced, even when the input - # #string is not. * will sort last. See #normalize. - # - # * translates to an endless range. By itself, * - # translates to :*... Use #limit to set * to a maximum - # value. - # - # The returned ranges will be sorted and coalesced, even when the input - # #string is not. * will sort last. See #normalize. - # - # Net::IMAP::SequenceSet["2,5:9,6,*,12:11"].ranges - # #=> [2..2, 5..9, 11..12, :*..] - # Net::IMAP::SequenceSet["123,999:*,456:789"].ranges - # #=> [123..123, 456..789, 999..] - # - # Related: #each_range, #elements, #numbers, #to_set - def ranges; each_range.to_a end - - # Returns a sorted array of all of the number values in the sequence set. - # - # The returned numbers are sorted and de-duplicated, even when the input - # #string is not. See #normalize. - # - # Net::IMAP::SequenceSet["2,5:9,6,12:11"].numbers - # #=> [2, 5, 6, 7, 8, 9, 11, 12] - # - # If the set contains a *, RangeError is raised. See #limit. - # - # Net::IMAP::SequenceSet["10000:*"].numbers - # #!> RangeError - # - # *WARNING:* Even excluding sets with *, an enormous result can - # easily be created. An array with over 4 billion integers could be - # returned, requiring up to 32GiB of memory on a 64-bit architecture. - # - # Net::IMAP::SequenceSet[10000..2**32-1].numbers - # # ...probably freezes the process for a while... - # #!> NoMemoryError (probably) - # - # For safety, consider using #limit or #intersection to set an upper - # bound. Alternatively, use #each_element, #each_range, or even - # #each_number to avoid allocation of a result array. - # - # Related: #elements, #ranges, #to_set - def numbers; each_number.to_a end - - # Yields each number or range in #string to the block and returns +self+. - # Returns an enumerator when called without a block. - # - # The entries are yielded in the same order they appear in #string, with - # no sorting, deduplication, or coalescing. When #string is in its - # normalized form, this will yield the same values as #each_element. - # - # Related: #entries, #each_element - def each_entry(&block) # :yields: integer or range or :* - return to_enum(__method__) unless block_given? - each_entry_tuple do yield tuple_to_entry _1 end - end - - # Yields each number or range (or :*) in #elements to the block - # and returns self. Returns an enumerator when called without a block. - # - # The returned numbers are sorted and de-duplicated, even when the input - # #string is not. See #normalize. - # - # Related: #elements, #each_entry - def each_element # :yields: integer or range or :* - return to_enum(__method__) unless block_given? - @tuples.each do yield tuple_to_entry _1 end - self - end - - private - - def each_entry_tuple(&block) - return to_enum(__method__) unless block_given? - if @string - @string.split(",") do block.call str_to_tuple _1 end - else - @tuples.each(&block) - end - self - end - - def tuple_to_entry((min, max)) - if min == STAR_INT then :* - elsif max == STAR_INT then min.. - elsif min == max then min - else min..max - end - end - - public - - # Yields each range in #ranges to the block and returns self. - # Returns an enumerator when called without a block. - # - # Related: #ranges - def each_range # :yields: range - return to_enum(__method__) unless block_given? - @tuples.each do |min, max| - if min == STAR_INT then yield :*.. - elsif max == STAR_INT then yield min.. - else yield min..max - end - end - self - end - - # Yields each number in #numbers to the block and returns self. - # If the set contains a *, RangeError will be raised. - # - # Returns an enumerator when called without a block (even if the set - # contains *). - # - # Related: #numbers, #each_ordered_number - def each_number(&block) # :yields: integer - return to_enum(__method__) unless block_given? - raise RangeError, '%s contains "*"' % [self.class] if include_star? - @tuples.each do each_number_in_tuple _1, _2, &block end - self - end - - # Yields each number in #entries to the block and returns self. - # If the set contains a *, RangeError will be raised. - # - # Returns an enumerator when called without a block (even if the set - # contains *). - # - # Related: #entries, #each_number - def each_ordered_number(&block) - return to_enum(__method__) unless block_given? - raise RangeError, '%s contains "*"' % [self.class] if include_star? - each_entry_tuple do each_number_in_tuple _1, _2, &block end - end - - private def each_number_in_tuple(min, max, &block) - if min == STAR_INT then yield :* - elsif min == max then yield min - elsif max != STAR_INT then (min..max).each(&block) - else - raise RangeError, "#{SequenceSet} cannot enumerate range with '*'" - end - end - - # Returns a Set with all of the #numbers in the sequence set. - # - # If the set contains a *, RangeError will be raised. - # - # See #numbers for the warning about very large sets. - # - # Related: #elements, #ranges, #numbers - def to_set; Set.new(numbers) end - - # Returns the count of #numbers in the set. - # - # * will be counted as 2**32 - 1 (the maximum 32-bit - # unsigned integer value). - # - # Related: #count_with_duplicates - def count - @tuples.sum(@tuples.count) { _2 - _1 } + - (include_star? && include?(UINT32_MAX) ? -1 : 0) - end - - alias size count - - # Returns the count of numbers in the ordered #entries, including any - # repeated numbers. - # - # * will be counted as 2**32 - 1 (the maximum 32-bit - # unsigned integer value). - # - # When #string is normalized, this behaves the same as #count. - # - # Related: #entries, #count_duplicates, #has_duplicates? - def count_with_duplicates - return count unless @string - each_entry_tuple.sum {|min, max| - max - min + ((max == STAR_INT && min != STAR_INT) ? 0 : 1) - } - end - - # Returns the count of repeated numbers in the ordered #entries, the - # difference between #count_with_duplicates and #count. - # - # When #string is normalized, this is zero. - # - # Related: #entries, #count_with_duplicates, #has_duplicates? - def count_duplicates - return 0 unless @string - count_with_duplicates - count - end - - # :call-seq: has_duplicates? -> true | false - # - # Returns whether or not the ordered #entries repeat any numbers. - # - # Always returns +false+ when #string is normalized. - # - # Related: #entries, #count_with_duplicates, #count_duplicates? - def has_duplicates? - return false unless @string - count_with_duplicates != count - end - - # Returns the (sorted and deduplicated) index of +number+ in the set, or - # +nil+ if +number+ isn't in the set. - # - # Related: #[], #at, #find_ordered_index - def find_index(number) - number = to_tuple_int number - each_tuple_with_index(@tuples) do |min, max, idx_min| - number < min and return nil - number <= max and return from_tuple_int(idx_min + (number - min)) - end - nil - end - - # Returns the first index of +number+ in the ordered #entries, or - # +nil+ if +number+ isn't in the set. - # - # Related: #find_index - def find_ordered_index(number) - number = to_tuple_int number - each_tuple_with_index(each_entry_tuple) do |min, max, idx_min| - if min <= number && number <= max - return from_tuple_int(idx_min + (number - min)) - end - end - nil - end - - private - - def each_tuple_with_index(tuples) - idx_min = 0 - tuples.each do |min, max| - idx_max = idx_min + (max - min) - yield min, max, idx_min, idx_max - idx_min = idx_max + 1 - end - idx_min - end - - def reverse_each_tuple_with_index(tuples) - idx_max = -1 - tuples.reverse_each do |min, max| - yield min, max, (idx_min = idx_max - (max - min)), idx_max - idx_max = idx_min - 1 - end - idx_max - end - - public - - # :call-seq: at(index) -> integer or nil - # - # Returns the number at the given +index+ in the sorted set, without - # modifying the set. - # - # +index+ is interpreted the same as in #[], except that #at only allows a - # single integer argument. - # - # Related: #[], #slice, #ordered_at - def at(index) - lookup_number_by_tuple_index(tuples, index) - end - - # :call-seq: ordered_at(index) -> integer or nil - # - # Returns the number at the given +index+ in the ordered #entries, without - # modifying the set. - # - # +index+ is interpreted the same as in #at (and #[]), except that - # #ordered_at applies to the ordered #entries, not the sorted set. - # - # Related: #[], #slice, #ordered_at - def ordered_at(index) - lookup_number_by_tuple_index(each_entry_tuple, index) - end - - private def lookup_number_by_tuple_index(tuples, index) - index = Integer(index.to_int) - if index.negative? - reverse_each_tuple_with_index(tuples) do |min, max, idx_min, idx_max| - idx_min <= index and return from_tuple_int(min + (index - idx_min)) - end - else - each_tuple_with_index(tuples) do |min, _, idx_min, idx_max| - index <= idx_max and return from_tuple_int(min + (index - idx_min)) - end - end - nil - end - - # :call-seq: - # seqset[index] -> integer or :* or nil - # slice(index) -> integer or :* or nil - # seqset[start, length] -> sequence set or nil - # slice(start, length) -> sequence set or nil - # seqset[range] -> sequence set or nil - # slice(range) -> sequence set or nil - # - # Returns a number or a subset from the _sorted_ set, without modifying - # the set. - # - # When an Integer argument +index+ is given, the number at offset +index+ - # in the sorted set is returned: - # - # set = Net::IMAP::SequenceSet["10:15,20:23,26"] - # set[0] #=> 10 - # set[5] #=> 15 - # set[10] #=> 26 - # - # If +index+ is negative, it counts relative to the end of the sorted set: - # set = Net::IMAP::SequenceSet["10:15,20:23,26"] - # set[-1] #=> 26 - # set[-3] #=> 22 - # set[-6] #=> 15 - # - # If +index+ is out of range, +nil+ is returned. - # - # set = Net::IMAP::SequenceSet["10:15,20:23,26"] - # set[11] #=> nil - # set[-12] #=> nil - # - # The result is based on the sorted and de-duplicated set, not on the - # ordered #entries in #string. - # - # set = Net::IMAP::SequenceSet["12,20:23,11:16,21"] - # set[0] #=> 11 - # set[-1] #=> 23 - # - # Related: #at - def [](index, length = nil) - if length then slice_length(index, length) - elsif index.is_a?(Range) then slice_range(index) - else at(index) - end - end - - alias slice :[] - - private - - def slice_length(start, length) - start = Integer(start.to_int) - length = Integer(length.to_int) - raise ArgumentError, "length must be positive" unless length.positive? - last = start + length - 1 unless start.negative? && start.abs <= length - slice_range(start..last) - end - - def slice_range(range) - first = range.begin || 0 - last = range.end || -1 - last -= 1 if range.exclude_end? && range.end && last != STAR_INT - if (first * last).positive? && last < first - SequenceSet.empty - elsif (min = at(first)) - max = at(last) - if max == :* then self & (min..) - elsif min <= max then self & (min..max) - else SequenceSet.empty - end - end - end - - public - - # Returns a frozen SequenceSet with * converted to +max+, numbers - # and ranges over +max+ removed, and ranges containing +max+ converted to - # end at +max+. - # - # Net::IMAP::SequenceSet["5,10:22,50"].limit(max: 20).to_s - # #=> "5,10:20" - # - # * is always interpreted as the maximum value. When the set - # contains *, it will be set equal to the limit. - # - # Net::IMAP::SequenceSet["*"].limit(max: 37) - # #=> Net::IMAP::SequenceSet["37"] - # Net::IMAP::SequenceSet["5:*"].limit(max: 37) - # #=> Net::IMAP::SequenceSet["5:37"] - # Net::IMAP::SequenceSet["500:*"].limit(max: 37) - # #=> Net::IMAP::SequenceSet["37"] - # - def limit(max:) - max = to_tuple_int(max) - if empty? then self.class.empty - elsif !include_star? && max < min then self.class.empty - elsif max(star: STAR_INT) <= max then frozen? ? self : dup.freeze - else dup.limit!(max: max).freeze - end - end - - # Removes all members over +max+ and returns self. If * is a - # member, it will be converted to +max+. - # - # Related: #limit - def limit!(max:) - star = include_star? - max = to_tuple_int(max) - tuple_subtract [max + 1, STAR_INT] - tuple_add [max, max ] if star - normalize! - end - - # :call-seq: complement! -> self - # - # Converts the SequenceSet to its own #complement. It will contain all - # possible values _except_ for those currently in the set. - # - # Related: #complement - def complement! - return replace(self.class.full) if empty? - return clear if full? - flat = @tuples.flat_map { [_1 - 1, _2 + 1] } - if flat.first < 1 then flat.shift else flat.unshift 1 end - if STAR_INT < flat.last then flat.pop else flat.push STAR_INT end - @tuples = flat.each_slice(2).to_a - normalize! - end - - # Returns a new SequenceSet with a normalized string representation. - # - # The returned set's #string is sorted and deduplicated. Adjacent or - # overlapping elements will be merged into a single larger range. - # - # Net::IMAP::SequenceSet["1:5,3:7,10:9,10:11"].normalize - # #=> Net::IMAP::SequenceSet["1:7,9:11"] - # - # Related: #normalize!, #normalized_string - def normalize - str = normalized_string - return self if frozen? && str == string - remain_frozen dup.instance_exec { @string = str&.-@; self } - end - - # Resets #string to be sorted, deduplicated, and coalesced. Returns - # +self+. - # - # Related: #normalize, #normalized_string - def normalize! - @string = nil - self - end - - # Returns a normalized +sequence-set+ string representation, sorted - # and deduplicated. Adjacent or overlapping elements will be merged into - # a single larger range. Returns +nil+ when the set is empty. - # - # Net::IMAP::SequenceSet["1:5,3:7,10:9,10:11"].normalized_string - # #=> "1:7,9:11" - # - # Related: #normalize!, #normalize - def normalized_string - @tuples.empty? ? nil : -@tuples.map { tuple_to_str _1 }.join(",") - end - - def inspect - if empty? - (frozen? ? "%s.empty" : "#<%s empty>") % [self.class] - elsif frozen? - "%s[%p]" % [self.class, to_s] - else - "#<%s %p>" % [self.class, to_s] - end - end - - # Returns self - alias to_sequence_set itself - - # Unstable API: currently for internal use only (Net::IMAP#validate_data) - def validate # :nodoc: - empty? and raise DataFormatError, "empty sequence-set is invalid" - self - end - - # Unstable API: for internal use only (Net::IMAP#send_data) - def send_data(imap, tag) # :nodoc: - imap.__send__(:put_string, valid_string) - end - - protected - - attr_reader :tuples # :nodoc: - - private - - def remain_frozen(set) frozen? ? set.freeze : set end - - # frozen clones are shallow copied - def initialize_clone(other) - other.frozen? ? super : initialize_dup(other) - end - - def initialize_dup(other) - @tuples = other.tuples.map(&:dup) - @string = other.string&.-@ - super - end - - def input_to_tuple(obj) - obj = input_try_convert obj - case obj - when *STARS, Integer then [int = to_tuple_int(obj), int] - when Range then range_to_tuple(obj) - when String then str_to_tuple(obj) - else - raise DataFormatError, "expected number or range, got %p" % [obj] - end - end - - def input_to_tuples(obj) - obj = input_try_convert obj - case obj - when *STARS, Integer, Range then [input_to_tuple(obj)] - when String then str_to_tuples obj - when SequenceSet then obj.tuples - when ENUMABLE then obj.flat_map { input_to_tuples _1 } - when nil then [] - else - raise DataFormatError, - "expected nz-number, range, string, or enumerable; " \ - "got %p" % [obj] - end - end - - # unlike SequenceSet#try_convert, this returns an Integer, Range, - # String, Set, Array, or... any type of object. - def input_try_convert(input) - SequenceSet.try_convert(input) || - # Integer.try_convert(input) || # ruby 3.1+ - input.respond_to?(:to_int) && Integer(input.to_int) || - String.try_convert(input) || - input - end - - def range_to_tuple(range) - first = to_tuple_int(range.begin || 1) - last = to_tuple_int(range.end || :*) - last -= 1 if range.exclude_end? && range.end && last != STAR_INT - unless first <= last - raise DataFormatError, "invalid range for sequence-set: %p" % [range] - end - [first, last] - end - - def to_tuple_int(obj) STARS.include?(obj) ? STAR_INT : nz_number(obj) end - def from_tuple_int(num) num == STAR_INT ? :* : num end - - def tuple_to_str(tuple) tuple.uniq.map{ from_tuple_int _1 }.join(":") end - def str_to_tuples(str) str.split(",", -1).map! { str_to_tuple _1 } end - def str_to_tuple(str) - raise DataFormatError, "invalid sequence set string" if str.empty? - str.split(":", 2).map! { to_tuple_int _1 }.minmax - end - - def include_tuple?((min, max)) range_gte_to(min)&.cover?(min..max) end - - def intersect_tuple?((min, max)) - range = range_gte_to(min) and - range.include?(min) || range.include?(max) || (min..max).cover?(range) - end - - def modifying! - if frozen? - raise FrozenError, "can't modify frozen #{self.class}: %p" % [self] - end - end - - def tuples_add(tuples) tuples.each do tuple_add _1 end; self end - def tuples_subtract(tuples) tuples.each do tuple_subtract _1 end; self end - - # - # --|=====| |=====new tuple=====| append - # ?????????-|=====new tuple=====|-|===lower===|-- insert - # - # |=====new tuple=====| - # ---------??=======lower=======??--------------- noop - # - # ---------??===lower==|--|==| join remaining - # ---------??===lower==|--|==|----|===upper===|-- join until upper - # ---------??===lower==|--|==|--|=====upper===|-- join to upper - def tuple_add(tuple) - modifying! - min, max = tuple - lower, lower_idx = tuple_gte_with_index(min - 1) - if lower.nil? then tuples << [min, max] - elsif (max + 1) < lower.first then tuples.insert(lower_idx, [min, max]) - else tuple_coalesce(lower, lower_idx, min, max) - end - end - - def tuple_coalesce(lower, lower_idx, min, max) - return if lower.first <= min && max <= lower.last - lower[0] = [min, lower.first].min - lower[1] = [max, lower.last].max - lower_idx += 1 - return if lower_idx == tuples.count - tmax_adj = lower.last + 1 - upper, upper_idx = tuple_gte_with_index(tmax_adj) - if upper - tmax_adj < upper.first ? (upper_idx -= 1) : (lower[1] = upper.last) - end - tuples.slice!(lower_idx..upper_idx) - end - - # |====tuple================| - # --|====| no more 1. noop - # --|====|---------------------------|====lower====|-- 2. noop - # -------|======lower================|---------------- 3. split - # --------|=====lower================|---------------- 4. trim beginning - # - # -------|======lower====????????????----------------- trim lower - # --------|=====lower====????????????----------------- delete lower - # - # -------??=====lower===============|----------------- 5. trim/delete one - # -------??=====lower====|--|====| no more 6. delete rest - # -------??=====lower====|--|====|---|====upper====|-- 7. delete until - # -------??=====lower====|--|====|--|=====upper====|-- 8. delete and trim - def tuple_subtract(tuple) - modifying! - min, max = tuple - lower, idx = tuple_gte_with_index(min) - if lower.nil? then nil # case 1. - elsif max < lower.first then nil # case 2. - elsif max < lower.last then tuple_trim_or_split lower, idx, min, max - else tuples_trim_or_delete lower, idx, min, max - end - end - - def tuple_trim_or_split(lower, idx, tmin, tmax) - if lower.first < tmin # split - tuples.insert(idx, [lower.first, tmin - 1]) - end - lower[0] = tmax + 1 - end - - def tuples_trim_or_delete(lower, lower_idx, tmin, tmax) - if lower.first < tmin # trim lower - lower[1] = tmin - 1 - lower_idx += 1 - end - if tmax == lower.last # case 5 - upper_idx = lower_idx - elsif (upper, upper_idx = tuple_gte_with_index(tmax + 1)) - upper_idx -= 1 # cases 7 and 8 - upper[0] = tmax + 1 if upper.first <= tmax # case 8 (else case 7) - end - tuples.slice!(lower_idx..upper_idx) - end - - def tuple_gte_with_index(num) - idx = tuples.bsearch_index { _2 >= num } and [tuples[idx], idx] - end - - def range_gte_to(num) - first, last = tuples.bsearch { _2 >= num } - first..last if first - end - - def nz_number(num) - case num - when Integer, /\A[1-9]\d*\z/ then num = Integer(num) - else raise DataFormatError, "%p is not a valid nz-number" % [num] - end - NumValidator.ensure_nz_number(num) - num - end - - # intentionally defined after the class implementation - - EMPTY = new.freeze - FULL = self["1:*"] - private_constant :EMPTY, :FULL - - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/nameprep.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/nameprep.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/nameprep.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/nameprep.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,70 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - module StringPrep - - # Defined in RFC3491[https://tools.ietf.org/html/rfc3491], the +nameprep+ - # profile of "Stringprep" is: - # >>> - # used by the IDNA protocol for preparing domain names; it is not - # designed for any other purpose. It is explicitly not designed for - # processing arbitrary free text and SHOULD NOT be used for that - # purpose. - # - # ... - # - # This profile specifies prohibiting using the following tables...: - # - # - C.1.2 (Non-ASCII space characters) - # - C.2.2 (Non-ASCII control characters) - # - C.3 (Private use characters) - # - C.4 (Non-character code points) - # - C.5 (Surrogate codes) - # - C.6 (Inappropriate for plain text) - # - C.7 (Inappropriate for canonical representation) - # - C.8 (Change display properties are deprecated) - # - C.9 (Tagging characters) - # - # IMPORTANT NOTE: This profile MUST be used with the IDNA protocol. - # The IDNA protocol has additional prohibitions that are checked - # outside of this profile. - module NamePrep - - # From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §10 - STRINGPREP_PROFILE = "nameprep" - - # From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §2 - UNASSIGNED_TABLE = "A.1" - - # From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §3 - MAPPING_TABLES = %w[B.1 B.2].freeze - - # From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §4 - NORMALIZATION = :nfkc - - # From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §5 - PROHIBITED_TABLES = %w[C.1.2 C.2.2 C.3 C.4 C.5 C.6 C.7 C.8 C.9].freeze - - # From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §6 - CHECK_BIDI = true - - module_function - - def nameprep(string, **opts) - StringPrep.stringprep( - string, - unassigned: UNASSIGNED_TABLE, - maps: MAPPING_TABLES, - prohibited: PROHIBITED_TABLES, - normalization: NORMALIZATION, - bidi: CHECK_BIDI, - profile: STRINGPREP_PROFILE, - **opts, - ) - end - end - - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/saslprep.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/saslprep.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/saslprep.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/saslprep.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,69 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - module StringPrep - - # SASLprep#saslprep can be used to prepare a string according to [RFC4013]. - # - # \SASLprep maps characters three ways: to nothing, to space, and Unicode - # normalization form KC. \SASLprep prohibits codepoints from nearly all - # standard StringPrep tables (RFC3454, Appendix "C"), and uses - # \StringPrep's standard bidirectional characters requirements (Appendix - # "D"). \SASLprep also uses \StringPrep's definition of "Unassigned" - # codepoints (Appendix "A"). - module SASLprep - - # Used to short-circuit strings that don't need preparation. - ASCII_NO_CTRLS = /\A[\x20-\x7e]*\z/u.freeze - - # Avoid loading these tables unless they are needed (they are only - # needed for non-ASCII). - saslprep_tables = File.expand_path("saslprep_tables", __dir__) - autoload :MAP_TO_NOTHING, saslprep_tables - autoload :MAP_TO_SPACE, saslprep_tables - autoload :PROHIBITED, saslprep_tables - autoload :PROHIBITED_STORED, saslprep_tables - autoload :TABLES_PROHIBITED, saslprep_tables - autoload :TABLES_PROHIBITED_STORED, saslprep_tables - - module_function - - # Prepares a UTF-8 +string+ for comparison, using the \SASLprep profile - # RFC4013 of the StringPrep algorithm RFC3454. - # - # By default, prohibited strings will return +nil+. When +exception+ is - # +true+, a StringPrepError describing the violation will be raised. - # - # When +stored+ is +true+, "unassigned" codepoints will be prohibited. - # For \StringPrep and the \SASLprep profile, "unassigned" refers to - # Unicode 3.2, and not later versions. See RFC3454 §7 for more - # information. - def saslprep(str, stored: false, exception: false) - return str if ASCII_NO_CTRLS.match?(str) # incompatible encoding raises - str = str.encode("UTF-8") # also dups (and raises for invalid encoding) - str.gsub!(MAP_TO_SPACE, " ") - str.gsub!(MAP_TO_NOTHING, "") - str.unicode_normalize!(:nfkc) - # These regexps combine the prohibited and bidirectional checks - return str unless str.match?(stored ? PROHIBITED_STORED : PROHIBITED) - return nil unless exception - # raise helpful errors to indicate *why* it failed: - tables = stored ? TABLES_PROHIBITED_STORED : TABLES_PROHIBITED - StringPrep.check_prohibited! str, *tables, bidi: true, profile: "SASLprep" - raise InvalidStringError.new( - "unknown error", string: string, profile: "SASLprep" - ) - rescue ArgumentError, Encoding::CompatibilityError => ex - if /invalid byte sequence|incompatible encoding/.match? ex.message - return nil unless exception - raise StringPrepError.new(ex.message, string: str, profile: "saslprep") - end - raise ex - end - - end - - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/saslprep_tables.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/saslprep_tables.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/saslprep_tables.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/saslprep_tables.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,96 +0,0 @@ -# frozen_string_literal: true - -#-- -# This file is generated from RFC3454, by rake. Don't edit directly. -#++ - -module Net::IMAP::StringPrep - - module SASLprep - - # RFC4013 §2.1 Mapping - mapped to space - # >>> - # non-ASCII space characters (\StringPrep\[\"C.1.2\"]) that can - # be mapped to SPACE (U+0020) - # - # Equal to \StringPrep\[\"C.1.2\"]. - # Redefined here to avoid loading StringPrep::Tables unless necessary. - MAP_TO_SPACE = /[\u200b\p{Zs}&&[^ ]]/.freeze - - # RFC4013 §2.1 Mapping - mapped to nothing - # >>> - # the "commonly mapped to nothing" characters - # (\StringPrep\[\"B.1\"]) that can be mapped to nothing. - # - # Equal to \StringPrep\[\"B.1\"]. - # Redefined here to avoid loading StringPrep::Tables unless necessary. - MAP_TO_NOTHING = /[\u{00ad 034f 1806 2060 feff}\u{180b}-\u{180d}\u{200b}-\u{200d}\u{fe00}-\u{fe0f}]/.freeze - - # RFC4013 §2.3 Prohibited Output - # >>> - # * Non-ASCII space characters — \StringPrep\[\"C.1.2\"] - # * ASCII control characters — \StringPrep\[\"C.2.1\"] - # * Non-ASCII control characters — \StringPrep\[\"C.2.2\"] - # * Private Use characters — \StringPrep\[\"C.3\"] - # * Non-character code points — \StringPrep\[\"C.4\"] - # * Surrogate code points — \StringPrep\[\"C.5\"] - # * Inappropriate for plain text characters — \StringPrep\[\"C.6\"] - # * Inappropriate for canonical representation characters — \StringPrep\[\"C.7\"] - # * Change display properties or deprecated characters — \StringPrep\[\"C.8\"] - # * Tagging characters — \StringPrep\[\"C.9\"] - TABLES_PROHIBITED = ["C.1.2", "C.2.1", "C.2.2", "C.3", "C.4", "C.5", "C.6", "C.7", "C.8", "C.9"].freeze - - # Adds unassigned (by Unicode 3.2) codepoints to TABLES_PROHIBITED. - # - # RFC4013 §2.5 Unassigned Code Points - # >>> - # This profile specifies the \StringPrep\[\"A.1\"] table as its - # list of unassigned code points. - TABLES_PROHIBITED_STORED = ["A.1", *TABLES_PROHIBITED].freeze - - # A Regexp matching codepoints prohibited by RFC4013 §2.3. - # - # This combines all of the TABLES_PROHIBITED tables. - PROHIBITED_OUTPUT = /[\u{06dd 070f 1680 180e 3000 feff e0001}\u{0000}-\u{001f}\u{007f}-\u{00a0}\u{0340}-\u{0341}\u{2000}-\u{200f}\u{2028}-\u{202f}\u{205f}-\u{2063}\u{206a}-\u{206f}\u{2ff0}-\u{2ffb}\u{e000}-\u{f8ff}\u{fdd0}-\u{fdef}\u{fff9}-\u{ffff}\u{1d173}-\u{1d17a}\u{1fffe}-\u{1ffff}\u{2fffe}-\u{2ffff}\u{3fffe}-\u{3ffff}\u{4fffe}-\u{4ffff}\u{5fffe}-\u{5ffff}\u{6fffe}-\u{6ffff}\u{7fffe}-\u{7ffff}\u{8fffe}-\u{8ffff}\u{9fffe}-\u{9ffff}\u{afffe}-\u{affff}\u{bfffe}-\u{bffff}\u{cfffe}-\u{cffff}\u{dfffe}-\u{dffff}\u{e0020}-\u{e007f}\u{efffe}-\u{10ffff}\p{Cs}]/.freeze - - # RFC4013 §2.5 Unassigned Code Points - # >>> - # This profile specifies the \StringPrep\[\"A.1\"] table as its - # list of unassigned code points. - # - # Equal to \StringPrep\[\"A.1\"]. - # Redefined here to avoid loading StringPrep::Tables unless necessary. - UNASSIGNED = /\p{^AGE=3.2}/.freeze - - # A Regexp matching codepoints prohibited by RFC4013 §2.3 and §2.5. - # - # This combines PROHIBITED_OUTPUT and UNASSIGNED. - PROHIBITED_OUTPUT_STORED = Regexp.union( - UNASSIGNED, PROHIBITED_OUTPUT - ).freeze - - # Bidirectional Characters [StringPrep, §6] - # - # A Regexp for strings that don't satisfy StringPrep's Bidirectional - # Characters rules. - # - # Equal to StringPrep::Tables::BIDI_FAILURE. - # Redefined here to avoid loading StringPrep::Tables unless necessary. - BIDI_FAILURE = /(?-mix:(?m-ix:(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]))|(?m-ix:(?-mix:[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]).*?(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}])))|(?-mix:(?m-ix:\A(?-mix:[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]))|(?m-ix:(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}])\z))/.freeze - - # A Regexp matching strings prohibited by RFC4013 §2.3 and §2.4. - # - # This combines PROHIBITED_OUTPUT and BIDI_FAILURE. - PROHIBITED = Regexp.union( - PROHIBITED_OUTPUT, BIDI_FAILURE, - ) - - # A Regexp matching strings prohibited by RFC4013 §2.3, §2.4, and §2.5. - # - # This combines PROHIBITED_OUTPUT_STORED and BIDI_FAILURE. - PROHIBITED_STORED = Regexp.union( - PROHIBITED_OUTPUT_STORED, BIDI_FAILURE, - ) - - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/tables.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/tables.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/tables.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/tables.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,146 +0,0 @@ -# frozen_string_literal: true - -#-- -# This file is generated from RFC3454, by rake. Don't edit directly. -#++ - -module Net::IMAP::StringPrep - - module Tables - - # Unassigned code points in Unicode 3.2 \StringPrep\[\"A.1\"] - IN_A_1 = /\p{^AGE=3.2}/.freeze - - # Commonly mapped to nothing \StringPrep\[\"B.1\"] - IN_B_1 = /[\u{00ad 034f 1806 2060 feff}\u{180b}-\u{180d}\u{200b}-\u{200d}\u{fe00}-\u{fe0f}]/.freeze - - # Mapping for case-folding used with NFKC \StringPrep\[\"B.2\"] - IN_B_2 = /[\u{00b5 0100 0102 0104 0106 0108 010a 010c 010e 0110 0112 0114 0116 0118 011a 011c 011e 0120 0122 0124 0126 0128 012a 012c 012e 0130 0132 0134 0136 0139 013b 013d 013f 0141 0143 0145 0147 014c 014e 0150 0152 0154 0156 0158 015a 015c 015e 0160 0162 0164 0166 0168 016a 016c 016e 0170 0172 0174 0176 017b 017d 017f 0184 01a2 01a4 01a9 01ac 01b5 01bc 01cd 01cf 01d1 01d3 01d5 01d7 01d9 01db 01de 01e0 01e2 01e4 01e6 01e8 01ea 01ec 01ee 01f4 01fa 01fc 01fe 0200 0202 0204 0206 0208 020a 020c 020e 0210 0212 0214 0216 0218 021a 021c 021e 0220 0222 0224 0226 0228 022a 022c 022e 0230 0232 0345 037a 0386 038c 03b0 03c2 03d8 03da 03dc 03de 03e0 03e2 03e4 03e6 03e8 03ea 03ec 03ee 0460 0462 0464 0466 0468 046a 046c 046e 0470 0472 0474 0476 0478 047a 047c 047e 0480 048a 048c 048e 0490 0492 0494 0496 0498 049a 049c 049e 04a0 04a2 04a4 04a6 04a8 04aa 04ac 04ae 04b0 04b2 04b4 04b6 04b8 04ba 04bc 04be 04c1 04c3 04c5 04c7 04c9 04cb 04cd 04d0 04d2 04d4 04d6 04d8 04da 04dc 04de 04e0 04e2 04e4 04e6 04e8 04ea 04ec 04ee 04f0 04f2 04f4 04f8 0500 0502 0504 0506 0508 050a 050c 050e 0587 1e00 1e02 1e04 1e06 1e08 1e0a 1e0c 1e0e 1e10 1e12 1e14 1e16 1e18 1e1a 1e1c 1e1e 1e20 1e22 1e24 1e26 1e28 1e2a 1e2c 1e2e 1e30 1e32 1e34 1e36 1e38 1e3a 1e3c 1e3e 1e40 1e42 1e44 1e46 1e48 1e4a 1e4c 1e4e 1e50 1e52 1e54 1e56 1e58 1e5a 1e5c 1e5e 1e60 1e62 1e64 1e66 1e68 1e6a 1e6c 1e6e 1e70 1e72 1e74 1e76 1e78 1e7a 1e7c 1e7e 1e80 1e82 1e84 1e86 1e88 1e8a 1e8c 1e8e 1e90 1e92 1e94 1ea0 1ea2 1ea4 1ea6 1ea8 1eaa 1eac 1eae 1eb0 1eb2 1eb4 1eb6 1eb8 1eba 1ebc 1ebe 1ec0 1ec2 1ec4 1ec6 1ec8 1eca 1ecc 1ece 1ed0 1ed2 1ed4 1ed6 1ed8 1eda 1edc 1ede 1ee0 1ee2 1ee4 1ee6 1ee8 1eea 1eec 1eee 1ef0 1ef2 1ef4 1ef6 1ef8 1f50 1f52 1f54 1f56 1f59 1f5b 1f5d 1f5f 1fbe 20a8 2107 2109 2124 2126 2128 2133 2145 3371 3373 3375 33c3 33cb 33d7 1d49c 1d4a2 1d546 1d6d3 1d70d 1d747 1d781 1d7bb}\u{0041}-\u{005a}\u{00c0}-\u{00d6}\u{00d8}-\u{00df}\u{0149}-\u{014a}\u{0178}-\u{0179}\u{0181}-\u{0182}\u{0186}-\u{0187}\u{0189}-\u{018b}\u{018e}-\u{0191}\u{0193}-\u{0194}\u{0196}-\u{0198}\u{019c}-\u{019d}\u{019f}-\u{01a0}\u{01a6}-\u{01a7}\u{01ae}-\u{01af}\u{01b1}-\u{01b3}\u{01b7}-\u{01b8}\u{01c4}-\u{01c5}\u{01c7}-\u{01c8}\u{01ca}-\u{01cb}\u{01f0}-\u{01f2}\u{01f6}-\u{01f8}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ab}\u{03d0}-\u{03d6}\u{03f0}-\u{03f2}\u{03f4}-\u{03f5}\u{0400}-\u{042f}\u{0531}-\u{0556}\u{1e96}-\u{1e9b}\u{1f08}-\u{1f0f}\u{1f18}-\u{1f1d}\u{1f28}-\u{1f2f}\u{1f38}-\u{1f3f}\u{1f48}-\u{1f4d}\u{1f68}-\u{1f6f}\u{1f80}-\u{1faf}\u{1fb2}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd2}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe2}-\u{1fe4}\u{1fe6}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{2102}-\u{2103}\u{210b}-\u{210d}\u{2110}-\u{2112}\u{2115}-\u{2116}\u{2119}-\u{211d}\u{2120}-\u{2122}\u{212a}-\u{212d}\u{2130}-\u{2131}\u{213e}-\u{213f}\u{2160}-\u{216f}\u{24b6}-\u{24cf}\u{3380}-\u{3387}\u{338a}-\u{338c}\u{3390}-\u{3394}\u{33a9}-\u{33ac}\u{33b4}-\u{33c1}\u{33c6}-\u{33c9}\u{33cd}-\u{33ce}\u{33d9}-\u{33da}\u{33dc}-\u{33dd}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{10400}-\u{10425}\u{1d400}-\u{1d419}\u{1d434}-\u{1d44d}\u{1d468}-\u{1d481}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b5}\u{1d4d0}-\u{1d4e9}\u{1d504}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d538}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d56c}-\u{1d585}\u{1d5a0}-\u{1d5b9}\u{1d5d4}-\u{1d5ed}\u{1d608}-\u{1d621}\u{1d63c}-\u{1d655}\u{1d670}-\u{1d689}\u{1d6a8}-\u{1d6c0}\u{1d6e2}-\u{1d6fa}\u{1d71c}-\u{1d734}\u{1d756}-\u{1d76e}\u{1d790}-\u{1d7a8}]/.freeze - - # Mapping for case-folding used with no normalization \StringPrep\[\"B.3\"] - IN_B_3 = /[\u{00b5 0100 0102 0104 0106 0108 010a 010c 010e 0110 0112 0114 0116 0118 011a 011c 011e 0120 0122 0124 0126 0128 012a 012c 012e 0130 0132 0134 0136 0139 013b 013d 013f 0141 0143 0145 0147 014c 014e 0150 0152 0154 0156 0158 015a 015c 015e 0160 0162 0164 0166 0168 016a 016c 016e 0170 0172 0174 0176 017b 017d 017f 0184 01a2 01a4 01a9 01ac 01b5 01bc 01cd 01cf 01d1 01d3 01d5 01d7 01d9 01db 01de 01e0 01e2 01e4 01e6 01e8 01ea 01ec 01ee 01f4 01fa 01fc 01fe 0200 0202 0204 0206 0208 020a 020c 020e 0210 0212 0214 0216 0218 021a 021c 021e 0220 0222 0224 0226 0228 022a 022c 022e 0230 0232 0345 0386 038c 03b0 03c2 03d8 03da 03dc 03de 03e0 03e2 03e4 03e6 03e8 03ea 03ec 03ee 0460 0462 0464 0466 0468 046a 046c 046e 0470 0472 0474 0476 0478 047a 047c 047e 0480 048a 048c 048e 0490 0492 0494 0496 0498 049a 049c 049e 04a0 04a2 04a4 04a6 04a8 04aa 04ac 04ae 04b0 04b2 04b4 04b6 04b8 04ba 04bc 04be 04c1 04c3 04c5 04c7 04c9 04cb 04cd 04d0 04d2 04d4 04d6 04d8 04da 04dc 04de 04e0 04e2 04e4 04e6 04e8 04ea 04ec 04ee 04f0 04f2 04f4 04f8 0500 0502 0504 0506 0508 050a 050c 050e 0587 1e00 1e02 1e04 1e06 1e08 1e0a 1e0c 1e0e 1e10 1e12 1e14 1e16 1e18 1e1a 1e1c 1e1e 1e20 1e22 1e24 1e26 1e28 1e2a 1e2c 1e2e 1e30 1e32 1e34 1e36 1e38 1e3a 1e3c 1e3e 1e40 1e42 1e44 1e46 1e48 1e4a 1e4c 1e4e 1e50 1e52 1e54 1e56 1e58 1e5a 1e5c 1e5e 1e60 1e62 1e64 1e66 1e68 1e6a 1e6c 1e6e 1e70 1e72 1e74 1e76 1e78 1e7a 1e7c 1e7e 1e80 1e82 1e84 1e86 1e88 1e8a 1e8c 1e8e 1e90 1e92 1e94 1ea0 1ea2 1ea4 1ea6 1ea8 1eaa 1eac 1eae 1eb0 1eb2 1eb4 1eb6 1eb8 1eba 1ebc 1ebe 1ec0 1ec2 1ec4 1ec6 1ec8 1eca 1ecc 1ece 1ed0 1ed2 1ed4 1ed6 1ed8 1eda 1edc 1ede 1ee0 1ee2 1ee4 1ee6 1ee8 1eea 1eec 1eee 1ef0 1ef2 1ef4 1ef6 1ef8 1f50 1f52 1f54 1f56 1f59 1f5b 1f5d 1f5f 1fbe 2126}\u{0041}-\u{005a}\u{00c0}-\u{00d6}\u{00d8}-\u{00df}\u{0149}-\u{014a}\u{0178}-\u{0179}\u{0181}-\u{0182}\u{0186}-\u{0187}\u{0189}-\u{018b}\u{018e}-\u{0191}\u{0193}-\u{0194}\u{0196}-\u{0198}\u{019c}-\u{019d}\u{019f}-\u{01a0}\u{01a6}-\u{01a7}\u{01ae}-\u{01af}\u{01b1}-\u{01b3}\u{01b7}-\u{01b8}\u{01c4}-\u{01c5}\u{01c7}-\u{01c8}\u{01ca}-\u{01cb}\u{01f0}-\u{01f2}\u{01f6}-\u{01f8}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ab}\u{03d0}-\u{03d1}\u{03d5}-\u{03d6}\u{03f0}-\u{03f2}\u{03f4}-\u{03f5}\u{0400}-\u{042f}\u{0531}-\u{0556}\u{1e96}-\u{1e9b}\u{1f08}-\u{1f0f}\u{1f18}-\u{1f1d}\u{1f28}-\u{1f2f}\u{1f38}-\u{1f3f}\u{1f48}-\u{1f4d}\u{1f68}-\u{1f6f}\u{1f80}-\u{1faf}\u{1fb2}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd2}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe2}-\u{1fe4}\u{1fe6}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{212a}-\u{212b}\u{2160}-\u{216f}\u{24b6}-\u{24cf}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{10400}-\u{10425}]/.freeze - - # Replacements for IN_B.1 - MAP_B_1 = "".freeze - - # Replacements for IN_B.2 - MAP_B_2 = {"A"=>"a", "B"=>"b", "C"=>"c", "D"=>"d", "E"=>"e", "F"=>"f", "G"=>"g", "H"=>"h", "I"=>"i", "J"=>"j", "K"=>"k", "L"=>"l", "M"=>"m", "N"=>"n", "O"=>"o", "P"=>"p", "Q"=>"q", "R"=>"r", "S"=>"s", "T"=>"t", "U"=>"u", "V"=>"v", "W"=>"w", "X"=>"x", "Y"=>"y", "Z"=>"z", "µ"=>"μ", "À"=>"à", "Á"=>"á", "Â"=>"â", "Ã"=>"ã", "Ä"=>"ä", "Å"=>"å", "Æ"=>"æ", "Ç"=>"ç", "È"=>"è", "É"=>"é", "Ê"=>"ê", "Ë"=>"ë", "Ì"=>"ì", "Í"=>"í", "Î"=>"î", "Ï"=>"ï", "Ð"=>"ð", "Ñ"=>"ñ", "Ò"=>"ò", "Ó"=>"ó", "Ô"=>"ô", "Õ"=>"õ", "Ö"=>"ö", "Ø"=>"ø", "Ù"=>"ù", "Ú"=>"ú", "Û"=>"û", "Ü"=>"ü", "Ý"=>"ý", "Þ"=>"þ", "ß"=>"ss", "Ā"=>"ā", "Ă"=>"ă", "Ą"=>"ą", "Ć"=>"ć", "Ĉ"=>"ĉ", "Ċ"=>"ċ", "Č"=>"č", "Ď"=>"ď", "Đ"=>"đ", "Ē"=>"ē", "Ĕ"=>"ĕ", "Ė"=>"ė", "Ę"=>"ę", "Ě"=>"ě", "Ĝ"=>"ĝ", "Ğ"=>"ğ", "Ġ"=>"ġ", "Ģ"=>"ģ", "Ĥ"=>"ĥ", "Ħ"=>"ħ", "Ĩ"=>"ĩ", "Ī"=>"ī", "Ĭ"=>"ĭ", "Į"=>"į", "İ"=>"i̇", "IJ"=>"ij", "Ĵ"=>"ĵ", "Ķ"=>"ķ", "Ĺ"=>"ĺ", "Ļ"=>"ļ", "Ľ"=>"ľ", "Ŀ"=>"ŀ", "Ł"=>"ł", "Ń"=>"ń", "Ņ"=>"ņ", "Ň"=>"ň", "ʼn"=>"ʼn", "Ŋ"=>"ŋ", "Ō"=>"ō", "Ŏ"=>"ŏ", "Ő"=>"ő", "Œ"=>"œ", "Ŕ"=>"ŕ", "Ŗ"=>"ŗ", "Ř"=>"ř", "Ś"=>"ś", "Ŝ"=>"ŝ", "Ş"=>"ş", "Š"=>"š", "Ţ"=>"ţ", "Ť"=>"ť", "Ŧ"=>"ŧ", "Ũ"=>"ũ", "Ū"=>"ū", "Ŭ"=>"ŭ", "Ů"=>"ů", "Ű"=>"ű", "Ų"=>"ų", "Ŵ"=>"ŵ", "Ŷ"=>"ŷ", "Ÿ"=>"ÿ", "Ź"=>"ź", "Ż"=>"ż", "Ž"=>"ž", "ſ"=>"s", "Ɓ"=>"ɓ", "Ƃ"=>"ƃ", "Ƅ"=>"ƅ", "Ɔ"=>"ɔ", "Ƈ"=>"ƈ", "Ɖ"=>"ɖ", "Ɗ"=>"ɗ", "Ƌ"=>"ƌ", "Ǝ"=>"ǝ", "Ə"=>"ə", "Ɛ"=>"ɛ", "Ƒ"=>"ƒ", "Ɠ"=>"ɠ", "Ɣ"=>"ɣ", "Ɩ"=>"ɩ", "Ɨ"=>"ɨ", "Ƙ"=>"ƙ", "Ɯ"=>"ɯ", "Ɲ"=>"ɲ", "Ɵ"=>"ɵ", "Ơ"=>"ơ", "Ƣ"=>"ƣ", "Ƥ"=>"ƥ", "Ʀ"=>"ʀ", "Ƨ"=>"ƨ", "Ʃ"=>"ʃ", "Ƭ"=>"ƭ", "Ʈ"=>"ʈ", "Ư"=>"ư", "Ʊ"=>"ʊ", "Ʋ"=>"ʋ", "Ƴ"=>"ƴ", "Ƶ"=>"ƶ", "Ʒ"=>"ʒ", "Ƹ"=>"ƹ", "Ƽ"=>"ƽ", "DŽ"=>"dž", "Dž"=>"dž", "LJ"=>"lj", "Lj"=>"lj", "NJ"=>"nj", "Nj"=>"nj", "Ǎ"=>"ǎ", "Ǐ"=>"ǐ", "Ǒ"=>"ǒ", "Ǔ"=>"ǔ", "Ǖ"=>"ǖ", "Ǘ"=>"ǘ", "Ǚ"=>"ǚ", "Ǜ"=>"ǜ", "Ǟ"=>"ǟ", "Ǡ"=>"ǡ", "Ǣ"=>"ǣ", "Ǥ"=>"ǥ", "Ǧ"=>"ǧ", "Ǩ"=>"ǩ", "Ǫ"=>"ǫ", "Ǭ"=>"ǭ", "Ǯ"=>"ǯ", "ǰ"=>"ǰ", "DZ"=>"dz", "Dz"=>"dz", "Ǵ"=>"ǵ", "Ƕ"=>"ƕ", "Ƿ"=>"ƿ", "Ǹ"=>"ǹ", "Ǻ"=>"ǻ", "Ǽ"=>"ǽ", "Ǿ"=>"ǿ", "Ȁ"=>"ȁ", "Ȃ"=>"ȃ", "Ȅ"=>"ȅ", "Ȇ"=>"ȇ", "Ȉ"=>"ȉ", "Ȋ"=>"ȋ", "Ȍ"=>"ȍ", "Ȏ"=>"ȏ", "Ȑ"=>"ȑ", "Ȓ"=>"ȓ", "Ȕ"=>"ȕ", "Ȗ"=>"ȗ", "Ș"=>"ș", "Ț"=>"ț", "Ȝ"=>"ȝ", "Ȟ"=>"ȟ", "Ƞ"=>"ƞ", "Ȣ"=>"ȣ", "Ȥ"=>"ȥ", "Ȧ"=>"ȧ", "Ȩ"=>"ȩ", "Ȫ"=>"ȫ", "Ȭ"=>"ȭ", "Ȯ"=>"ȯ", "Ȱ"=>"ȱ", "Ȳ"=>"ȳ", "ͅ"=>"ι", "ͺ"=>" ι", "Ά"=>"ά", "Έ"=>"έ", "Ή"=>"ή", "Ί"=>"ί", "Ό"=>"ό", "Ύ"=>"ύ", "Ώ"=>"ώ", "ΐ"=>"ΐ", "Α"=>"α", "Β"=>"β", "Γ"=>"γ", "Δ"=>"δ", "Ε"=>"ε", "Ζ"=>"ζ", "Η"=>"η", "Θ"=>"θ", "Ι"=>"ι", "Κ"=>"κ", "Λ"=>"λ", "Μ"=>"μ", "Ν"=>"ν", "Ξ"=>"ξ", "Ο"=>"ο", "Π"=>"π", "Ρ"=>"ρ", "Σ"=>"σ", "Τ"=>"τ", "Υ"=>"υ", "Φ"=>"φ", "Χ"=>"χ", "Ψ"=>"ψ", "Ω"=>"ω", "Ϊ"=>"ϊ", "Ϋ"=>"ϋ", "ΰ"=>"ΰ", "ς"=>"σ", "ϐ"=>"β", "ϑ"=>"θ", "ϒ"=>"υ", "ϓ"=>"ύ", "ϔ"=>"ϋ", "ϕ"=>"φ", "ϖ"=>"π", "Ϙ"=>"ϙ", "Ϛ"=>"ϛ", "Ϝ"=>"ϝ", "Ϟ"=>"ϟ", "Ϡ"=>"ϡ", "Ϣ"=>"ϣ", "Ϥ"=>"ϥ", "Ϧ"=>"ϧ", "Ϩ"=>"ϩ", "Ϫ"=>"ϫ", "Ϭ"=>"ϭ", "Ϯ"=>"ϯ", "ϰ"=>"κ", "ϱ"=>"ρ", "ϲ"=>"σ", "ϴ"=>"θ", "ϵ"=>"ε", "Ѐ"=>"ѐ", "Ё"=>"ё", "Ђ"=>"ђ", "Ѓ"=>"ѓ", "Є"=>"є", "Ѕ"=>"ѕ", "І"=>"і", "Ї"=>"ї", "Ј"=>"ј", "Љ"=>"љ", "Њ"=>"њ", "Ћ"=>"ћ", "Ќ"=>"ќ", "Ѝ"=>"ѝ", "Ў"=>"ў", "Џ"=>"џ", "А"=>"а", "Б"=>"б", "В"=>"в", "Г"=>"г", "Д"=>"д", "Е"=>"е", "Ж"=>"ж", "З"=>"з", "И"=>"и", "Й"=>"й", "К"=>"к", "Л"=>"л", "М"=>"м", "Н"=>"н", "О"=>"о", "П"=>"п", "Р"=>"р", "С"=>"с", "Т"=>"т", "У"=>"у", "Ф"=>"ф", "Х"=>"х", "Ц"=>"ц", "Ч"=>"ч", "Ш"=>"ш", "Щ"=>"щ", "Ъ"=>"ъ", "Ы"=>"ы", "Ь"=>"ь", "Э"=>"э", "Ю"=>"ю", "Я"=>"я", "Ѡ"=>"ѡ", "Ѣ"=>"ѣ", "Ѥ"=>"ѥ", "Ѧ"=>"ѧ", "Ѩ"=>"ѩ", "Ѫ"=>"ѫ", "Ѭ"=>"ѭ", "Ѯ"=>"ѯ", "Ѱ"=>"ѱ", "Ѳ"=>"ѳ", "Ѵ"=>"ѵ", "Ѷ"=>"ѷ", "Ѹ"=>"ѹ", "Ѻ"=>"ѻ", "Ѽ"=>"ѽ", "Ѿ"=>"ѿ", "Ҁ"=>"ҁ", "Ҋ"=>"ҋ", "Ҍ"=>"ҍ", "Ҏ"=>"ҏ", "Ґ"=>"ґ", "Ғ"=>"ғ", "Ҕ"=>"ҕ", "Җ"=>"җ", "Ҙ"=>"ҙ", "Қ"=>"қ", "Ҝ"=>"ҝ", "Ҟ"=>"ҟ", "Ҡ"=>"ҡ", "Ң"=>"ң", "Ҥ"=>"ҥ", "Ҧ"=>"ҧ", "Ҩ"=>"ҩ", "Ҫ"=>"ҫ", "Ҭ"=>"ҭ", "Ү"=>"ү", "Ұ"=>"ұ", "Ҳ"=>"ҳ", "Ҵ"=>"ҵ", "Ҷ"=>"ҷ", "Ҹ"=>"ҹ", "Һ"=>"һ", "Ҽ"=>"ҽ", "Ҿ"=>"ҿ", "Ӂ"=>"ӂ", "Ӄ"=>"ӄ", "Ӆ"=>"ӆ", "Ӈ"=>"ӈ", "Ӊ"=>"ӊ", "Ӌ"=>"ӌ", "Ӎ"=>"ӎ", "Ӑ"=>"ӑ", "Ӓ"=>"ӓ", "Ӕ"=>"ӕ", "Ӗ"=>"ӗ", "Ә"=>"ә", "Ӛ"=>"ӛ", "Ӝ"=>"ӝ", "Ӟ"=>"ӟ", "Ӡ"=>"ӡ", "Ӣ"=>"ӣ", "Ӥ"=>"ӥ", "Ӧ"=>"ӧ", "Ө"=>"ө", "Ӫ"=>"ӫ", "Ӭ"=>"ӭ", "Ӯ"=>"ӯ", "Ӱ"=>"ӱ", "Ӳ"=>"ӳ", "Ӵ"=>"ӵ", "Ӹ"=>"ӹ", "Ԁ"=>"ԁ", "Ԃ"=>"ԃ", "Ԅ"=>"ԅ", "Ԇ"=>"ԇ", "Ԉ"=>"ԉ", "Ԋ"=>"ԋ", "Ԍ"=>"ԍ", "Ԏ"=>"ԏ", "Ա"=>"ա", "Բ"=>"բ", "Գ"=>"գ", "Դ"=>"դ", "Ե"=>"ե", "Զ"=>"զ", "Է"=>"է", "Ը"=>"ը", "Թ"=>"թ", "Ժ"=>"ժ", "Ի"=>"ի", "Լ"=>"լ", "Խ"=>"խ", "Ծ"=>"ծ", "Կ"=>"կ", "Հ"=>"հ", "Ձ"=>"ձ", "Ղ"=>"ղ", "Ճ"=>"ճ", "Մ"=>"մ", "Յ"=>"յ", "Ն"=>"ն", "Շ"=>"շ", "Ո"=>"ո", "Չ"=>"չ", "Պ"=>"պ", "Ջ"=>"ջ", "Ռ"=>"ռ", "Ս"=>"ս", "Վ"=>"վ", "Տ"=>"տ", "Ր"=>"ր", "Ց"=>"ց", "Ւ"=>"ւ", "Փ"=>"փ", "Ք"=>"ք", "Օ"=>"օ", "Ֆ"=>"ֆ", "և"=>"եւ", "Ḁ"=>"ḁ", "Ḃ"=>"ḃ", "Ḅ"=>"ḅ", "Ḇ"=>"ḇ", "Ḉ"=>"ḉ", "Ḋ"=>"ḋ", "Ḍ"=>"ḍ", "Ḏ"=>"ḏ", "Ḑ"=>"ḑ", "Ḓ"=>"ḓ", "Ḕ"=>"ḕ", "Ḗ"=>"ḗ", "Ḙ"=>"ḙ", "Ḛ"=>"ḛ", "Ḝ"=>"ḝ", "Ḟ"=>"ḟ", "Ḡ"=>"ḡ", "Ḣ"=>"ḣ", "Ḥ"=>"ḥ", "Ḧ"=>"ḧ", "Ḩ"=>"ḩ", "Ḫ"=>"ḫ", "Ḭ"=>"ḭ", "Ḯ"=>"ḯ", "Ḱ"=>"ḱ", "Ḳ"=>"ḳ", "Ḵ"=>"ḵ", "Ḷ"=>"ḷ", "Ḹ"=>"ḹ", "Ḻ"=>"ḻ", "Ḽ"=>"ḽ", "Ḿ"=>"ḿ", "Ṁ"=>"ṁ", "Ṃ"=>"ṃ", "Ṅ"=>"ṅ", "Ṇ"=>"ṇ", "Ṉ"=>"ṉ", "Ṋ"=>"ṋ", "Ṍ"=>"ṍ", "Ṏ"=>"ṏ", "Ṑ"=>"ṑ", "Ṓ"=>"ṓ", "Ṕ"=>"ṕ", "Ṗ"=>"ṗ", "Ṙ"=>"ṙ", "Ṛ"=>"ṛ", "Ṝ"=>"ṝ", "Ṟ"=>"ṟ", "Ṡ"=>"ṡ", "Ṣ"=>"ṣ", "Ṥ"=>"ṥ", "Ṧ"=>"ṧ", "Ṩ"=>"ṩ", "Ṫ"=>"ṫ", "Ṭ"=>"ṭ", "Ṯ"=>"ṯ", "Ṱ"=>"ṱ", "Ṳ"=>"ṳ", "Ṵ"=>"ṵ", "Ṷ"=>"ṷ", "Ṹ"=>"ṹ", "Ṻ"=>"ṻ", "Ṽ"=>"ṽ", "Ṿ"=>"ṿ", "Ẁ"=>"ẁ", "Ẃ"=>"ẃ", "Ẅ"=>"ẅ", "Ẇ"=>"ẇ", "Ẉ"=>"ẉ", "Ẋ"=>"ẋ", "Ẍ"=>"ẍ", "Ẏ"=>"ẏ", "Ẑ"=>"ẑ", "Ẓ"=>"ẓ", "Ẕ"=>"ẕ", "ẖ"=>"ẖ", "ẗ"=>"ẗ", "ẘ"=>"ẘ", "ẙ"=>"ẙ", "ẚ"=>"aʾ", "ẛ"=>"ṡ", "Ạ"=>"ạ", "Ả"=>"ả", "Ấ"=>"ấ", "Ầ"=>"ầ", "Ẩ"=>"ẩ", "Ẫ"=>"ẫ", "Ậ"=>"ậ", "Ắ"=>"ắ", "Ằ"=>"ằ", "Ẳ"=>"ẳ", "Ẵ"=>"ẵ", "Ặ"=>"ặ", "Ẹ"=>"ẹ", "Ẻ"=>"ẻ", "Ẽ"=>"ẽ", "Ế"=>"ế", "Ề"=>"ề", "Ể"=>"ể", "Ễ"=>"ễ", "Ệ"=>"ệ", "Ỉ"=>"ỉ", "Ị"=>"ị", "Ọ"=>"ọ", "Ỏ"=>"ỏ", "Ố"=>"ố", "Ồ"=>"ồ", "Ổ"=>"ổ", "Ỗ"=>"ỗ", "Ộ"=>"ộ", "Ớ"=>"ớ", "Ờ"=>"ờ", "Ở"=>"ở", "Ỡ"=>"ỡ", "Ợ"=>"ợ", "Ụ"=>"ụ", "Ủ"=>"ủ", "Ứ"=>"ứ", "Ừ"=>"ừ", "Ử"=>"ử", "Ữ"=>"ữ", "Ự"=>"ự", "Ỳ"=>"ỳ", "Ỵ"=>"ỵ", "Ỷ"=>"ỷ", "Ỹ"=>"ỹ", "Ἀ"=>"ἀ", "Ἁ"=>"ἁ", "Ἂ"=>"ἂ", "Ἃ"=>"ἃ", "Ἄ"=>"ἄ", "Ἅ"=>"ἅ", "Ἆ"=>"ἆ", "Ἇ"=>"ἇ", "Ἐ"=>"ἐ", "Ἑ"=>"ἑ", "Ἒ"=>"ἒ", "Ἓ"=>"ἓ", "Ἔ"=>"ἔ", "Ἕ"=>"ἕ", "Ἠ"=>"ἠ", "Ἡ"=>"ἡ", "Ἢ"=>"ἢ", "Ἣ"=>"ἣ", "Ἤ"=>"ἤ", "Ἥ"=>"ἥ", "Ἦ"=>"ἦ", "Ἧ"=>"ἧ", "Ἰ"=>"ἰ", "Ἱ"=>"ἱ", "Ἲ"=>"ἲ", "Ἳ"=>"ἳ", "Ἴ"=>"ἴ", "Ἵ"=>"ἵ", "Ἶ"=>"ἶ", "Ἷ"=>"ἷ", "Ὀ"=>"ὀ", "Ὁ"=>"ὁ", "Ὂ"=>"ὂ", "Ὃ"=>"ὃ", "Ὄ"=>"ὄ", "Ὅ"=>"ὅ", "ὐ"=>"ὐ", "ὒ"=>"ὒ", "ὔ"=>"ὔ", "ὖ"=>"ὖ", "Ὑ"=>"ὑ", "Ὓ"=>"ὓ", "Ὕ"=>"ὕ", "Ὗ"=>"ὗ", "Ὠ"=>"ὠ", "Ὡ"=>"ὡ", "Ὢ"=>"ὢ", "Ὣ"=>"ὣ", "Ὤ"=>"ὤ", "Ὥ"=>"ὥ", "Ὦ"=>"ὦ", "Ὧ"=>"ὧ", "ᾀ"=>"ἀι", "ᾁ"=>"ἁι", "ᾂ"=>"ἂι", "ᾃ"=>"ἃι", "ᾄ"=>"ἄι", "ᾅ"=>"ἅι", "ᾆ"=>"ἆι", "ᾇ"=>"ἇι", "ᾈ"=>"ἀι", "ᾉ"=>"ἁι", "ᾊ"=>"ἂι", "ᾋ"=>"ἃι", "ᾌ"=>"ἄι", "ᾍ"=>"ἅι", "ᾎ"=>"ἆι", "ᾏ"=>"ἇι", "ᾐ"=>"ἠι", "ᾑ"=>"ἡι", "ᾒ"=>"ἢι", "ᾓ"=>"ἣι", "ᾔ"=>"ἤι", "ᾕ"=>"ἥι", "ᾖ"=>"ἦι", "ᾗ"=>"ἧι", "ᾘ"=>"ἠι", "ᾙ"=>"ἡι", "ᾚ"=>"ἢι", "ᾛ"=>"ἣι", "ᾜ"=>"ἤι", "ᾝ"=>"ἥι", "ᾞ"=>"ἦι", "ᾟ"=>"ἧι", "ᾠ"=>"ὠι", "ᾡ"=>"ὡι", "ᾢ"=>"ὢι", "ᾣ"=>"ὣι", "ᾤ"=>"ὤι", "ᾥ"=>"ὥι", "ᾦ"=>"ὦι", "ᾧ"=>"ὧι", "ᾨ"=>"ὠι", "ᾩ"=>"ὡι", "ᾪ"=>"ὢι", "ᾫ"=>"ὣι", "ᾬ"=>"ὤι", "ᾭ"=>"ὥι", "ᾮ"=>"ὦι", "ᾯ"=>"ὧι", "ᾲ"=>"ὰι", "ᾳ"=>"αι", "ᾴ"=>"άι", "ᾶ"=>"ᾶ", "ᾷ"=>"ᾶι", "Ᾰ"=>"ᾰ", "Ᾱ"=>"ᾱ", "Ὰ"=>"ὰ", "Ά"=>"ά", "ᾼ"=>"αι", "ι"=>"ι", "ῂ"=>"ὴι", "ῃ"=>"ηι", "ῄ"=>"ήι", "ῆ"=>"ῆ", "ῇ"=>"ῆι", "Ὲ"=>"ὲ", "Έ"=>"έ", "Ὴ"=>"ὴ", "Ή"=>"ή", "ῌ"=>"ηι", "ῒ"=>"ῒ", "ΐ"=>"ΐ", "ῖ"=>"ῖ", "ῗ"=>"ῗ", "Ῐ"=>"ῐ", "Ῑ"=>"ῑ", "Ὶ"=>"ὶ", "Ί"=>"ί", "ῢ"=>"ῢ", "ΰ"=>"ΰ", "ῤ"=>"ῤ", "ῦ"=>"ῦ", "ῧ"=>"ῧ", "Ῠ"=>"ῠ", "Ῡ"=>"ῡ", "Ὺ"=>"ὺ", "Ύ"=>"ύ", "Ῥ"=>"ῥ", "ῲ"=>"ὼι", "ῳ"=>"ωι", "ῴ"=>"ώι", "ῶ"=>"ῶ", "ῷ"=>"ῶι", "Ὸ"=>"ὸ", "Ό"=>"ό", "Ὼ"=>"ὼ", "Ώ"=>"ώ", "ῼ"=>"ωι", "₨"=>"rs", "ℂ"=>"c", "℃"=>"°c", "ℇ"=>"ɛ", "℉"=>"°f", "ℋ"=>"h", "ℌ"=>"h", "ℍ"=>"h", "ℐ"=>"i", "ℑ"=>"i", "ℒ"=>"l", "ℕ"=>"n", "№"=>"no", "ℙ"=>"p", "ℚ"=>"q", "ℛ"=>"r", "ℜ"=>"r", "ℝ"=>"r", "℠"=>"sm", "℡"=>"tel", "™"=>"tm", "ℤ"=>"z", "Ω"=>"ω", "ℨ"=>"z", "K"=>"k", "Å"=>"å", "ℬ"=>"b", "ℭ"=>"c", "ℰ"=>"e", "ℱ"=>"f", "ℳ"=>"m", "ℾ"=>"γ", "ℿ"=>"π", "ⅅ"=>"d", "Ⅰ"=>"ⅰ", "Ⅱ"=>"ⅱ", "Ⅲ"=>"ⅲ", "Ⅳ"=>"ⅳ", "Ⅴ"=>"ⅴ", "Ⅵ"=>"ⅵ", "Ⅶ"=>"ⅶ", "Ⅷ"=>"ⅷ", "Ⅸ"=>"ⅸ", "Ⅹ"=>"ⅹ", "Ⅺ"=>"ⅺ", "Ⅻ"=>"ⅻ", "Ⅼ"=>"ⅼ", "Ⅽ"=>"ⅽ", "Ⅾ"=>"ⅾ", "Ⅿ"=>"ⅿ", "Ⓐ"=>"ⓐ", "Ⓑ"=>"ⓑ", "Ⓒ"=>"ⓒ", "Ⓓ"=>"ⓓ", "Ⓔ"=>"ⓔ", "Ⓕ"=>"ⓕ", "Ⓖ"=>"ⓖ", "Ⓗ"=>"ⓗ", "Ⓘ"=>"ⓘ", "Ⓙ"=>"ⓙ", "Ⓚ"=>"ⓚ", "Ⓛ"=>"ⓛ", "Ⓜ"=>"ⓜ", "Ⓝ"=>"ⓝ", "Ⓞ"=>"ⓞ", "Ⓟ"=>"ⓟ", "Ⓠ"=>"ⓠ", "Ⓡ"=>"ⓡ", "Ⓢ"=>"ⓢ", "Ⓣ"=>"ⓣ", "Ⓤ"=>"ⓤ", "Ⓥ"=>"ⓥ", "Ⓦ"=>"ⓦ", "Ⓧ"=>"ⓧ", "Ⓨ"=>"ⓨ", "Ⓩ"=>"ⓩ", "㍱"=>"hpa", "㍳"=>"au", "㍵"=>"ov", "㎀"=>"pa", "㎁"=>"na", "㎂"=>"μa", "㎃"=>"ma", "㎄"=>"ka", "㎅"=>"kb", "㎆"=>"mb", "㎇"=>"gb", "㎊"=>"pf", "㎋"=>"nf", "㎌"=>"μf", "㎐"=>"hz", "㎑"=>"khz", "㎒"=>"mhz", "㎓"=>"ghz", "㎔"=>"thz", "㎩"=>"pa", "㎪"=>"kpa", "㎫"=>"mpa", "㎬"=>"gpa", "㎴"=>"pv", "㎵"=>"nv", "㎶"=>"μv", "㎷"=>"mv", "㎸"=>"kv", "㎹"=>"mv", "㎺"=>"pw", "㎻"=>"nw", "㎼"=>"μw", "㎽"=>"mw", "㎾"=>"kw", "㎿"=>"mw", "㏀"=>"kω", "㏁"=>"mω", "㏃"=>"bq", "㏆"=>"c∕kg", "㏇"=>"co.", "㏈"=>"db", "㏉"=>"gy", "㏋"=>"hp", "㏍"=>"kk", "㏎"=>"km", "㏗"=>"ph", "㏙"=>"ppm", "㏚"=>"pr", "㏜"=>"sv", "㏝"=>"wb", "ff"=>"ff", "fi"=>"fi", "fl"=>"fl", "ffi"=>"ffi", "ffl"=>"ffl", "ſt"=>"st", "st"=>"st", "ﬓ"=>"մն", "ﬔ"=>"մե", "ﬕ"=>"մի", "ﬖ"=>"վն", "ﬗ"=>"մխ", "A"=>"a", "B"=>"b", "C"=>"c", "D"=>"d", "E"=>"e", "F"=>"f", "G"=>"g", "H"=>"h", "I"=>"i", "J"=>"j", "K"=>"k", "L"=>"l", "M"=>"m", "N"=>"n", "O"=>"o", "P"=>"p", "Q"=>"q", "R"=>"r", "S"=>"s", "T"=>"t", "U"=>"u", "V"=>"v", "W"=>"w", "X"=>"x", "Y"=>"y", "Z"=>"z", "𐐀"=>"𐐨", "𐐁"=>"𐐩", "𐐂"=>"𐐪", "𐐃"=>"𐐫", "𐐄"=>"𐐬", "𐐅"=>"𐐭", "𐐆"=>"𐐮", "𐐇"=>"𐐯", "𐐈"=>"𐐰", "𐐉"=>"𐐱", "𐐊"=>"𐐲", "𐐋"=>"𐐳", "𐐌"=>"𐐴", "𐐍"=>"𐐵", "𐐎"=>"𐐶", "𐐏"=>"𐐷", "𐐐"=>"𐐸", "𐐑"=>"𐐹", "𐐒"=>"𐐺", "𐐓"=>"𐐻", "𐐔"=>"𐐼", "𐐕"=>"𐐽", "𐐖"=>"𐐾", "𐐗"=>"𐐿", "𐐘"=>"𐑀", "𐐙"=>"𐑁", "𐐚"=>"𐑂", "𐐛"=>"𐑃", "𐐜"=>"𐑄", "𐐝"=>"𐑅", "𐐞"=>"𐑆", "𐐟"=>"𐑇", "𐐠"=>"𐑈", "𐐡"=>"𐑉", "𐐢"=>"𐑊", "𐐣"=>"𐑋", "𐐤"=>"𐑌", "𐐥"=>"𐑍", "𝐀"=>"a", "𝐁"=>"b", "𝐂"=>"c", "𝐃"=>"d", "𝐄"=>"e", "𝐅"=>"f", "𝐆"=>"g", "𝐇"=>"h", "𝐈"=>"i", "𝐉"=>"j", "𝐊"=>"k", "𝐋"=>"l", "𝐌"=>"m", "𝐍"=>"n", "𝐎"=>"o", "𝐏"=>"p", "𝐐"=>"q", "𝐑"=>"r", "𝐒"=>"s", "𝐓"=>"t", "𝐔"=>"u", "𝐕"=>"v", "𝐖"=>"w", "𝐗"=>"x", "𝐘"=>"y", "𝐙"=>"z", "𝐴"=>"a", "𝐵"=>"b", "𝐶"=>"c", "𝐷"=>"d", "𝐸"=>"e", "𝐹"=>"f", "𝐺"=>"g", "𝐻"=>"h", "𝐼"=>"i", "𝐽"=>"j", "𝐾"=>"k", "𝐿"=>"l", "𝑀"=>"m", "𝑁"=>"n", "𝑂"=>"o", "𝑃"=>"p", "𝑄"=>"q", "𝑅"=>"r", "𝑆"=>"s", "𝑇"=>"t", "𝑈"=>"u", "𝑉"=>"v", "𝑊"=>"w", "𝑋"=>"x", "𝑌"=>"y", "𝑍"=>"z", "𝑨"=>"a", "𝑩"=>"b", "𝑪"=>"c", "𝑫"=>"d", "𝑬"=>"e", "𝑭"=>"f", "𝑮"=>"g", "𝑯"=>"h", "𝑰"=>"i", "𝑱"=>"j", "𝑲"=>"k", "𝑳"=>"l", "𝑴"=>"m", "𝑵"=>"n", "𝑶"=>"o", "𝑷"=>"p", "𝑸"=>"q", "𝑹"=>"r", "𝑺"=>"s", "𝑻"=>"t", "𝑼"=>"u", "𝑽"=>"v", "𝑾"=>"w", "𝑿"=>"x", "𝒀"=>"y", "𝒁"=>"z", "𝒜"=>"a", "𝒞"=>"c", "𝒟"=>"d", "𝒢"=>"g", "𝒥"=>"j", "𝒦"=>"k", "𝒩"=>"n", "𝒪"=>"o", "𝒫"=>"p", "𝒬"=>"q", "𝒮"=>"s", "𝒯"=>"t", "𝒰"=>"u", "𝒱"=>"v", "𝒲"=>"w", "𝒳"=>"x", "𝒴"=>"y", "𝒵"=>"z", "𝓐"=>"a", "𝓑"=>"b", "𝓒"=>"c", "𝓓"=>"d", "𝓔"=>"e", "𝓕"=>"f", "𝓖"=>"g", "𝓗"=>"h", "𝓘"=>"i", "𝓙"=>"j", "𝓚"=>"k", "𝓛"=>"l", "𝓜"=>"m", "𝓝"=>"n", "𝓞"=>"o", "𝓟"=>"p", "𝓠"=>"q", "𝓡"=>"r", "𝓢"=>"s", "𝓣"=>"t", "𝓤"=>"u", "𝓥"=>"v", "𝓦"=>"w", "𝓧"=>"x", "𝓨"=>"y", "𝓩"=>"z", "𝔄"=>"a", "𝔅"=>"b", "𝔇"=>"d", "𝔈"=>"e", "𝔉"=>"f", "𝔊"=>"g", "𝔍"=>"j", "𝔎"=>"k", "𝔏"=>"l", "𝔐"=>"m", "𝔑"=>"n", "𝔒"=>"o", "𝔓"=>"p", "𝔔"=>"q", "𝔖"=>"s", "𝔗"=>"t", "𝔘"=>"u", "𝔙"=>"v", "𝔚"=>"w", "𝔛"=>"x", "𝔜"=>"y", "𝔸"=>"a", "𝔹"=>"b", "𝔻"=>"d", "𝔼"=>"e", "𝔽"=>"f", "𝔾"=>"g", "𝕀"=>"i", "𝕁"=>"j", "𝕂"=>"k", "𝕃"=>"l", "𝕄"=>"m", "𝕆"=>"o", "𝕊"=>"s", "𝕋"=>"t", "𝕌"=>"u", "𝕍"=>"v", "𝕎"=>"w", "𝕏"=>"x", "𝕐"=>"y", "𝕬"=>"a", "𝕭"=>"b", "𝕮"=>"c", "𝕯"=>"d", "𝕰"=>"e", "𝕱"=>"f", "𝕲"=>"g", "𝕳"=>"h", "𝕴"=>"i", "𝕵"=>"j", "𝕶"=>"k", "𝕷"=>"l", "𝕸"=>"m", "𝕹"=>"n", "𝕺"=>"o", "𝕻"=>"p", "𝕼"=>"q", "𝕽"=>"r", "𝕾"=>"s", "𝕿"=>"t", "𝖀"=>"u", "𝖁"=>"v", "𝖂"=>"w", "𝖃"=>"x", "𝖄"=>"y", "𝖅"=>"z", "𝖠"=>"a", "𝖡"=>"b", "𝖢"=>"c", "𝖣"=>"d", "𝖤"=>"e", "𝖥"=>"f", "𝖦"=>"g", "𝖧"=>"h", "𝖨"=>"i", "𝖩"=>"j", "𝖪"=>"k", "𝖫"=>"l", "𝖬"=>"m", "𝖭"=>"n", "𝖮"=>"o", "𝖯"=>"p", "𝖰"=>"q", "𝖱"=>"r", "𝖲"=>"s", "𝖳"=>"t", "𝖴"=>"u", "𝖵"=>"v", "𝖶"=>"w", "𝖷"=>"x", "𝖸"=>"y", "𝖹"=>"z", "𝗔"=>"a", "𝗕"=>"b", "𝗖"=>"c", "𝗗"=>"d", "𝗘"=>"e", "𝗙"=>"f", "𝗚"=>"g", "𝗛"=>"h", "𝗜"=>"i", "𝗝"=>"j", "𝗞"=>"k", "𝗟"=>"l", "𝗠"=>"m", "𝗡"=>"n", "𝗢"=>"o", "𝗣"=>"p", "𝗤"=>"q", "𝗥"=>"r", "𝗦"=>"s", "𝗧"=>"t", "𝗨"=>"u", "𝗩"=>"v", "𝗪"=>"w", "𝗫"=>"x", "𝗬"=>"y", "𝗭"=>"z", "𝘈"=>"a", "𝘉"=>"b", "𝘊"=>"c", "𝘋"=>"d", "𝘌"=>"e", "𝘍"=>"f", "𝘎"=>"g", "𝘏"=>"h", "𝘐"=>"i", "𝘑"=>"j", "𝘒"=>"k", "𝘓"=>"l", "𝘔"=>"m", "𝘕"=>"n", "𝘖"=>"o", "𝘗"=>"p", "𝘘"=>"q", "𝘙"=>"r", "𝘚"=>"s", "𝘛"=>"t", "𝘜"=>"u", "𝘝"=>"v", "𝘞"=>"w", "𝘟"=>"x", "𝘠"=>"y", "𝘡"=>"z", "𝘼"=>"a", "𝘽"=>"b", "𝘾"=>"c", "𝘿"=>"d", "𝙀"=>"e", "𝙁"=>"f", "𝙂"=>"g", "𝙃"=>"h", "𝙄"=>"i", "𝙅"=>"j", "𝙆"=>"k", "𝙇"=>"l", "𝙈"=>"m", "𝙉"=>"n", "𝙊"=>"o", "𝙋"=>"p", "𝙌"=>"q", "𝙍"=>"r", "𝙎"=>"s", "𝙏"=>"t", "𝙐"=>"u", "𝙑"=>"v", "𝙒"=>"w", "𝙓"=>"x", "𝙔"=>"y", "𝙕"=>"z", "𝙰"=>"a", "𝙱"=>"b", "𝙲"=>"c", "𝙳"=>"d", "𝙴"=>"e", "𝙵"=>"f", "𝙶"=>"g", "𝙷"=>"h", "𝙸"=>"i", "𝙹"=>"j", "𝙺"=>"k", "𝙻"=>"l", "𝙼"=>"m", "𝙽"=>"n", "𝙾"=>"o", "𝙿"=>"p", "𝚀"=>"q", "𝚁"=>"r", "𝚂"=>"s", "𝚃"=>"t", "𝚄"=>"u", "𝚅"=>"v", "𝚆"=>"w", "𝚇"=>"x", "𝚈"=>"y", "𝚉"=>"z", "𝚨"=>"α", "𝚩"=>"β", "𝚪"=>"γ", "𝚫"=>"δ", "𝚬"=>"ε", "𝚭"=>"ζ", "𝚮"=>"η", "𝚯"=>"θ", "𝚰"=>"ι", "𝚱"=>"κ", "𝚲"=>"λ", "𝚳"=>"μ", "𝚴"=>"ν", "𝚵"=>"ξ", "𝚶"=>"ο", "𝚷"=>"π", "𝚸"=>"ρ", "𝚹"=>"θ", "𝚺"=>"σ", "𝚻"=>"τ", "𝚼"=>"υ", "𝚽"=>"φ", "𝚾"=>"χ", "𝚿"=>"ψ", "𝛀"=>"ω", "𝛓"=>"σ", "𝛢"=>"α", "𝛣"=>"β", "𝛤"=>"γ", "𝛥"=>"δ", "𝛦"=>"ε", "𝛧"=>"ζ", "𝛨"=>"η", "𝛩"=>"θ", "𝛪"=>"ι", "𝛫"=>"κ", "𝛬"=>"λ", "𝛭"=>"μ", "𝛮"=>"ν", "𝛯"=>"ξ", "𝛰"=>"ο", "𝛱"=>"π", "𝛲"=>"ρ", "𝛳"=>"θ", "𝛴"=>"σ", "𝛵"=>"τ", "𝛶"=>"υ", "𝛷"=>"φ", "𝛸"=>"χ", "𝛹"=>"ψ", "𝛺"=>"ω", "𝜍"=>"σ", "𝜜"=>"α", "𝜝"=>"β", "𝜞"=>"γ", "𝜟"=>"δ", "𝜠"=>"ε", "𝜡"=>"ζ", "𝜢"=>"η", "𝜣"=>"θ", "𝜤"=>"ι", "𝜥"=>"κ", "𝜦"=>"λ", "𝜧"=>"μ", "𝜨"=>"ν", "𝜩"=>"ξ", "𝜪"=>"ο", "𝜫"=>"π", "𝜬"=>"ρ", "𝜭"=>"θ", "𝜮"=>"σ", "𝜯"=>"τ", "𝜰"=>"υ", "𝜱"=>"φ", "𝜲"=>"χ", "𝜳"=>"ψ", "𝜴"=>"ω", "𝝇"=>"σ", "𝝖"=>"α", "𝝗"=>"β", "𝝘"=>"γ", "𝝙"=>"δ", "𝝚"=>"ε", "𝝛"=>"ζ", "𝝜"=>"η", "𝝝"=>"θ", "𝝞"=>"ι", "𝝟"=>"κ", "𝝠"=>"λ", "𝝡"=>"μ", "𝝢"=>"ν", "𝝣"=>"ξ", "𝝤"=>"ο", "𝝥"=>"π", "𝝦"=>"ρ", "𝝧"=>"θ", "𝝨"=>"σ", "𝝩"=>"τ", "𝝪"=>"υ", "𝝫"=>"φ", "𝝬"=>"χ", "𝝭"=>"ψ", "𝝮"=>"ω", "𝞁"=>"σ", "𝞐"=>"α", "𝞑"=>"β", "𝞒"=>"γ", "𝞓"=>"δ", "𝞔"=>"ε", "𝞕"=>"ζ", "𝞖"=>"η", "𝞗"=>"θ", "𝞘"=>"ι", "𝞙"=>"κ", "𝞚"=>"λ", "𝞛"=>"μ", "𝞜"=>"ν", "𝞝"=>"ξ", "𝞞"=>"ο", "𝞟"=>"π", "𝞠"=>"ρ", "𝞡"=>"θ", "𝞢"=>"σ", "𝞣"=>"τ", "𝞤"=>"υ", "𝞥"=>"φ", "𝞦"=>"χ", "𝞧"=>"ψ", "𝞨"=>"ω", "𝞻"=>"σ"}.freeze - - # Replacements for IN_B.3 - MAP_B_3 = {"A"=>"a", "B"=>"b", "C"=>"c", "D"=>"d", "E"=>"e", "F"=>"f", "G"=>"g", "H"=>"h", "I"=>"i", "J"=>"j", "K"=>"k", "L"=>"l", "M"=>"m", "N"=>"n", "O"=>"o", "P"=>"p", "Q"=>"q", "R"=>"r", "S"=>"s", "T"=>"t", "U"=>"u", "V"=>"v", "W"=>"w", "X"=>"x", "Y"=>"y", "Z"=>"z", "µ"=>"μ", "À"=>"à", "Á"=>"á", "Â"=>"â", "Ã"=>"ã", "Ä"=>"ä", "Å"=>"å", "Æ"=>"æ", "Ç"=>"ç", "È"=>"è", "É"=>"é", "Ê"=>"ê", "Ë"=>"ë", "Ì"=>"ì", "Í"=>"í", "Î"=>"î", "Ï"=>"ï", "Ð"=>"ð", "Ñ"=>"ñ", "Ò"=>"ò", "Ó"=>"ó", "Ô"=>"ô", "Õ"=>"õ", "Ö"=>"ö", "Ø"=>"ø", "Ù"=>"ù", "Ú"=>"ú", "Û"=>"û", "Ü"=>"ü", "Ý"=>"ý", "Þ"=>"þ", "ß"=>"ss", "Ā"=>"ā", "Ă"=>"ă", "Ą"=>"ą", "Ć"=>"ć", "Ĉ"=>"ĉ", "Ċ"=>"ċ", "Č"=>"č", "Ď"=>"ď", "Đ"=>"đ", "Ē"=>"ē", "Ĕ"=>"ĕ", "Ė"=>"ė", "Ę"=>"ę", "Ě"=>"ě", "Ĝ"=>"ĝ", "Ğ"=>"ğ", "Ġ"=>"ġ", "Ģ"=>"ģ", "Ĥ"=>"ĥ", "Ħ"=>"ħ", "Ĩ"=>"ĩ", "Ī"=>"ī", "Ĭ"=>"ĭ", "Į"=>"į", "İ"=>"i̇", "IJ"=>"ij", "Ĵ"=>"ĵ", "Ķ"=>"ķ", "Ĺ"=>"ĺ", "Ļ"=>"ļ", "Ľ"=>"ľ", "Ŀ"=>"ŀ", "Ł"=>"ł", "Ń"=>"ń", "Ņ"=>"ņ", "Ň"=>"ň", "ʼn"=>"ʼn", "Ŋ"=>"ŋ", "Ō"=>"ō", "Ŏ"=>"ŏ", "Ő"=>"ő", "Œ"=>"œ", "Ŕ"=>"ŕ", "Ŗ"=>"ŗ", "Ř"=>"ř", "Ś"=>"ś", "Ŝ"=>"ŝ", "Ş"=>"ş", "Š"=>"š", "Ţ"=>"ţ", "Ť"=>"ť", "Ŧ"=>"ŧ", "Ũ"=>"ũ", "Ū"=>"ū", "Ŭ"=>"ŭ", "Ů"=>"ů", "Ű"=>"ű", "Ų"=>"ų", "Ŵ"=>"ŵ", "Ŷ"=>"ŷ", "Ÿ"=>"ÿ", "Ź"=>"ź", "Ż"=>"ż", "Ž"=>"ž", "ſ"=>"s", "Ɓ"=>"ɓ", "Ƃ"=>"ƃ", "Ƅ"=>"ƅ", "Ɔ"=>"ɔ", "Ƈ"=>"ƈ", "Ɖ"=>"ɖ", "Ɗ"=>"ɗ", "Ƌ"=>"ƌ", "Ǝ"=>"ǝ", "Ə"=>"ə", "Ɛ"=>"ɛ", "Ƒ"=>"ƒ", "Ɠ"=>"ɠ", "Ɣ"=>"ɣ", "Ɩ"=>"ɩ", "Ɨ"=>"ɨ", "Ƙ"=>"ƙ", "Ɯ"=>"ɯ", "Ɲ"=>"ɲ", "Ɵ"=>"ɵ", "Ơ"=>"ơ", "Ƣ"=>"ƣ", "Ƥ"=>"ƥ", "Ʀ"=>"ʀ", "Ƨ"=>"ƨ", "Ʃ"=>"ʃ", "Ƭ"=>"ƭ", "Ʈ"=>"ʈ", "Ư"=>"ư", "Ʊ"=>"ʊ", "Ʋ"=>"ʋ", "Ƴ"=>"ƴ", "Ƶ"=>"ƶ", "Ʒ"=>"ʒ", "Ƹ"=>"ƹ", "Ƽ"=>"ƽ", "DŽ"=>"dž", "Dž"=>"dž", "LJ"=>"lj", "Lj"=>"lj", "NJ"=>"nj", "Nj"=>"nj", "Ǎ"=>"ǎ", "Ǐ"=>"ǐ", "Ǒ"=>"ǒ", "Ǔ"=>"ǔ", "Ǖ"=>"ǖ", "Ǘ"=>"ǘ", "Ǚ"=>"ǚ", "Ǜ"=>"ǜ", "Ǟ"=>"ǟ", "Ǡ"=>"ǡ", "Ǣ"=>"ǣ", "Ǥ"=>"ǥ", "Ǧ"=>"ǧ", "Ǩ"=>"ǩ", "Ǫ"=>"ǫ", "Ǭ"=>"ǭ", "Ǯ"=>"ǯ", "ǰ"=>"ǰ", "DZ"=>"dz", "Dz"=>"dz", "Ǵ"=>"ǵ", "Ƕ"=>"ƕ", "Ƿ"=>"ƿ", "Ǹ"=>"ǹ", "Ǻ"=>"ǻ", "Ǽ"=>"ǽ", "Ǿ"=>"ǿ", "Ȁ"=>"ȁ", "Ȃ"=>"ȃ", "Ȅ"=>"ȅ", "Ȇ"=>"ȇ", "Ȉ"=>"ȉ", "Ȋ"=>"ȋ", "Ȍ"=>"ȍ", "Ȏ"=>"ȏ", "Ȑ"=>"ȑ", "Ȓ"=>"ȓ", "Ȕ"=>"ȕ", "Ȗ"=>"ȗ", "Ș"=>"ș", "Ț"=>"ț", "Ȝ"=>"ȝ", "Ȟ"=>"ȟ", "Ƞ"=>"ƞ", "Ȣ"=>"ȣ", "Ȥ"=>"ȥ", "Ȧ"=>"ȧ", "Ȩ"=>"ȩ", "Ȫ"=>"ȫ", "Ȭ"=>"ȭ", "Ȯ"=>"ȯ", "Ȱ"=>"ȱ", "Ȳ"=>"ȳ", "ͅ"=>"ι", "Ά"=>"ά", "Έ"=>"έ", "Ή"=>"ή", "Ί"=>"ί", "Ό"=>"ό", "Ύ"=>"ύ", "Ώ"=>"ώ", "ΐ"=>"ΐ", "Α"=>"α", "Β"=>"β", "Γ"=>"γ", "Δ"=>"δ", "Ε"=>"ε", "Ζ"=>"ζ", "Η"=>"η", "Θ"=>"θ", "Ι"=>"ι", "Κ"=>"κ", "Λ"=>"λ", "Μ"=>"μ", "Ν"=>"ν", "Ξ"=>"ξ", "Ο"=>"ο", "Π"=>"π", "Ρ"=>"ρ", "Σ"=>"σ", "Τ"=>"τ", "Υ"=>"υ", "Φ"=>"φ", "Χ"=>"χ", "Ψ"=>"ψ", "Ω"=>"ω", "Ϊ"=>"ϊ", "Ϋ"=>"ϋ", "ΰ"=>"ΰ", "ς"=>"σ", "ϐ"=>"β", "ϑ"=>"θ", "ϕ"=>"φ", "ϖ"=>"π", "Ϙ"=>"ϙ", "Ϛ"=>"ϛ", "Ϝ"=>"ϝ", "Ϟ"=>"ϟ", "Ϡ"=>"ϡ", "Ϣ"=>"ϣ", "Ϥ"=>"ϥ", "Ϧ"=>"ϧ", "Ϩ"=>"ϩ", "Ϫ"=>"ϫ", "Ϭ"=>"ϭ", "Ϯ"=>"ϯ", "ϰ"=>"κ", "ϱ"=>"ρ", "ϲ"=>"σ", "ϴ"=>"θ", "ϵ"=>"ε", "Ѐ"=>"ѐ", "Ё"=>"ё", "Ђ"=>"ђ", "Ѓ"=>"ѓ", "Є"=>"є", "Ѕ"=>"ѕ", "І"=>"і", "Ї"=>"ї", "Ј"=>"ј", "Љ"=>"љ", "Њ"=>"њ", "Ћ"=>"ћ", "Ќ"=>"ќ", "Ѝ"=>"ѝ", "Ў"=>"ў", "Џ"=>"џ", "А"=>"а", "Б"=>"б", "В"=>"в", "Г"=>"г", "Д"=>"д", "Е"=>"е", "Ж"=>"ж", "З"=>"з", "И"=>"и", "Й"=>"й", "К"=>"к", "Л"=>"л", "М"=>"м", "Н"=>"н", "О"=>"о", "П"=>"п", "Р"=>"р", "С"=>"с", "Т"=>"т", "У"=>"у", "Ф"=>"ф", "Х"=>"х", "Ц"=>"ц", "Ч"=>"ч", "Ш"=>"ш", "Щ"=>"щ", "Ъ"=>"ъ", "Ы"=>"ы", "Ь"=>"ь", "Э"=>"э", "Ю"=>"ю", "Я"=>"я", "Ѡ"=>"ѡ", "Ѣ"=>"ѣ", "Ѥ"=>"ѥ", "Ѧ"=>"ѧ", "Ѩ"=>"ѩ", "Ѫ"=>"ѫ", "Ѭ"=>"ѭ", "Ѯ"=>"ѯ", "Ѱ"=>"ѱ", "Ѳ"=>"ѳ", "Ѵ"=>"ѵ", "Ѷ"=>"ѷ", "Ѹ"=>"ѹ", "Ѻ"=>"ѻ", "Ѽ"=>"ѽ", "Ѿ"=>"ѿ", "Ҁ"=>"ҁ", "Ҋ"=>"ҋ", "Ҍ"=>"ҍ", "Ҏ"=>"ҏ", "Ґ"=>"ґ", "Ғ"=>"ғ", "Ҕ"=>"ҕ", "Җ"=>"җ", "Ҙ"=>"ҙ", "Қ"=>"қ", "Ҝ"=>"ҝ", "Ҟ"=>"ҟ", "Ҡ"=>"ҡ", "Ң"=>"ң", "Ҥ"=>"ҥ", "Ҧ"=>"ҧ", "Ҩ"=>"ҩ", "Ҫ"=>"ҫ", "Ҭ"=>"ҭ", "Ү"=>"ү", "Ұ"=>"ұ", "Ҳ"=>"ҳ", "Ҵ"=>"ҵ", "Ҷ"=>"ҷ", "Ҹ"=>"ҹ", "Һ"=>"һ", "Ҽ"=>"ҽ", "Ҿ"=>"ҿ", "Ӂ"=>"ӂ", "Ӄ"=>"ӄ", "Ӆ"=>"ӆ", "Ӈ"=>"ӈ", "Ӊ"=>"ӊ", "Ӌ"=>"ӌ", "Ӎ"=>"ӎ", "Ӑ"=>"ӑ", "Ӓ"=>"ӓ", "Ӕ"=>"ӕ", "Ӗ"=>"ӗ", "Ә"=>"ә", "Ӛ"=>"ӛ", "Ӝ"=>"ӝ", "Ӟ"=>"ӟ", "Ӡ"=>"ӡ", "Ӣ"=>"ӣ", "Ӥ"=>"ӥ", "Ӧ"=>"ӧ", "Ө"=>"ө", "Ӫ"=>"ӫ", "Ӭ"=>"ӭ", "Ӯ"=>"ӯ", "Ӱ"=>"ӱ", "Ӳ"=>"ӳ", "Ӵ"=>"ӵ", "Ӹ"=>"ӹ", "Ԁ"=>"ԁ", "Ԃ"=>"ԃ", "Ԅ"=>"ԅ", "Ԇ"=>"ԇ", "Ԉ"=>"ԉ", "Ԋ"=>"ԋ", "Ԍ"=>"ԍ", "Ԏ"=>"ԏ", "Ա"=>"ա", "Բ"=>"բ", "Գ"=>"գ", "Դ"=>"դ", "Ե"=>"ե", "Զ"=>"զ", "Է"=>"է", "Ը"=>"ը", "Թ"=>"թ", "Ժ"=>"ժ", "Ի"=>"ի", "Լ"=>"լ", "Խ"=>"խ", "Ծ"=>"ծ", "Կ"=>"կ", "Հ"=>"հ", "Ձ"=>"ձ", "Ղ"=>"ղ", "Ճ"=>"ճ", "Մ"=>"մ", "Յ"=>"յ", "Ն"=>"ն", "Շ"=>"շ", "Ո"=>"ո", "Չ"=>"չ", "Պ"=>"պ", "Ջ"=>"ջ", "Ռ"=>"ռ", "Ս"=>"ս", "Վ"=>"վ", "Տ"=>"տ", "Ր"=>"ր", "Ց"=>"ց", "Ւ"=>"ւ", "Փ"=>"փ", "Ք"=>"ք", "Օ"=>"օ", "Ֆ"=>"ֆ", "և"=>"եւ", "Ḁ"=>"ḁ", "Ḃ"=>"ḃ", "Ḅ"=>"ḅ", "Ḇ"=>"ḇ", "Ḉ"=>"ḉ", "Ḋ"=>"ḋ", "Ḍ"=>"ḍ", "Ḏ"=>"ḏ", "Ḑ"=>"ḑ", "Ḓ"=>"ḓ", "Ḕ"=>"ḕ", "Ḗ"=>"ḗ", "Ḙ"=>"ḙ", "Ḛ"=>"ḛ", "Ḝ"=>"ḝ", "Ḟ"=>"ḟ", "Ḡ"=>"ḡ", "Ḣ"=>"ḣ", "Ḥ"=>"ḥ", "Ḧ"=>"ḧ", "Ḩ"=>"ḩ", "Ḫ"=>"ḫ", "Ḭ"=>"ḭ", "Ḯ"=>"ḯ", "Ḱ"=>"ḱ", "Ḳ"=>"ḳ", "Ḵ"=>"ḵ", "Ḷ"=>"ḷ", "Ḹ"=>"ḹ", "Ḻ"=>"ḻ", "Ḽ"=>"ḽ", "Ḿ"=>"ḿ", "Ṁ"=>"ṁ", "Ṃ"=>"ṃ", "Ṅ"=>"ṅ", "Ṇ"=>"ṇ", "Ṉ"=>"ṉ", "Ṋ"=>"ṋ", "Ṍ"=>"ṍ", "Ṏ"=>"ṏ", "Ṑ"=>"ṑ", "Ṓ"=>"ṓ", "Ṕ"=>"ṕ", "Ṗ"=>"ṗ", "Ṙ"=>"ṙ", "Ṛ"=>"ṛ", "Ṝ"=>"ṝ", "Ṟ"=>"ṟ", "Ṡ"=>"ṡ", "Ṣ"=>"ṣ", "Ṥ"=>"ṥ", "Ṧ"=>"ṧ", "Ṩ"=>"ṩ", "Ṫ"=>"ṫ", "Ṭ"=>"ṭ", "Ṯ"=>"ṯ", "Ṱ"=>"ṱ", "Ṳ"=>"ṳ", "Ṵ"=>"ṵ", "Ṷ"=>"ṷ", "Ṹ"=>"ṹ", "Ṻ"=>"ṻ", "Ṽ"=>"ṽ", "Ṿ"=>"ṿ", "Ẁ"=>"ẁ", "Ẃ"=>"ẃ", "Ẅ"=>"ẅ", "Ẇ"=>"ẇ", "Ẉ"=>"ẉ", "Ẋ"=>"ẋ", "Ẍ"=>"ẍ", "Ẏ"=>"ẏ", "Ẑ"=>"ẑ", "Ẓ"=>"ẓ", "Ẕ"=>"ẕ", "ẖ"=>"ẖ", "ẗ"=>"ẗ", "ẘ"=>"ẘ", "ẙ"=>"ẙ", "ẚ"=>"aʾ", "ẛ"=>"ṡ", "Ạ"=>"ạ", "Ả"=>"ả", "Ấ"=>"ấ", "Ầ"=>"ầ", "Ẩ"=>"ẩ", "Ẫ"=>"ẫ", "Ậ"=>"ậ", "Ắ"=>"ắ", "Ằ"=>"ằ", "Ẳ"=>"ẳ", "Ẵ"=>"ẵ", "Ặ"=>"ặ", "Ẹ"=>"ẹ", "Ẻ"=>"ẻ", "Ẽ"=>"ẽ", "Ế"=>"ế", "Ề"=>"ề", "Ể"=>"ể", "Ễ"=>"ễ", "Ệ"=>"ệ", "Ỉ"=>"ỉ", "Ị"=>"ị", "Ọ"=>"ọ", "Ỏ"=>"ỏ", "Ố"=>"ố", "Ồ"=>"ồ", "Ổ"=>"ổ", "Ỗ"=>"ỗ", "Ộ"=>"ộ", "Ớ"=>"ớ", "Ờ"=>"ờ", "Ở"=>"ở", "Ỡ"=>"ỡ", "Ợ"=>"ợ", "Ụ"=>"ụ", "Ủ"=>"ủ", "Ứ"=>"ứ", "Ừ"=>"ừ", "Ử"=>"ử", "Ữ"=>"ữ", "Ự"=>"ự", "Ỳ"=>"ỳ", "Ỵ"=>"ỵ", "Ỷ"=>"ỷ", "Ỹ"=>"ỹ", "Ἀ"=>"ἀ", "Ἁ"=>"ἁ", "Ἂ"=>"ἂ", "Ἃ"=>"ἃ", "Ἄ"=>"ἄ", "Ἅ"=>"ἅ", "Ἆ"=>"ἆ", "Ἇ"=>"ἇ", "Ἐ"=>"ἐ", "Ἑ"=>"ἑ", "Ἒ"=>"ἒ", "Ἓ"=>"ἓ", "Ἔ"=>"ἔ", "Ἕ"=>"ἕ", "Ἠ"=>"ἠ", "Ἡ"=>"ἡ", "Ἢ"=>"ἢ", "Ἣ"=>"ἣ", "Ἤ"=>"ἤ", "Ἥ"=>"ἥ", "Ἦ"=>"ἦ", "Ἧ"=>"ἧ", "Ἰ"=>"ἰ", "Ἱ"=>"ἱ", "Ἲ"=>"ἲ", "Ἳ"=>"ἳ", "Ἴ"=>"ἴ", "Ἵ"=>"ἵ", "Ἶ"=>"ἶ", "Ἷ"=>"ἷ", "Ὀ"=>"ὀ", "Ὁ"=>"ὁ", "Ὂ"=>"ὂ", "Ὃ"=>"ὃ", "Ὄ"=>"ὄ", "Ὅ"=>"ὅ", "ὐ"=>"ὐ", "ὒ"=>"ὒ", "ὔ"=>"ὔ", "ὖ"=>"ὖ", "Ὑ"=>"ὑ", "Ὓ"=>"ὓ", "Ὕ"=>"ὕ", "Ὗ"=>"ὗ", "Ὠ"=>"ὠ", "Ὡ"=>"ὡ", "Ὢ"=>"ὢ", "Ὣ"=>"ὣ", "Ὤ"=>"ὤ", "Ὥ"=>"ὥ", "Ὦ"=>"ὦ", "Ὧ"=>"ὧ", "ᾀ"=>"ἀι", "ᾁ"=>"ἁι", "ᾂ"=>"ἂι", "ᾃ"=>"ἃι", "ᾄ"=>"ἄι", "ᾅ"=>"ἅι", "ᾆ"=>"ἆι", "ᾇ"=>"ἇι", "ᾈ"=>"ἀι", "ᾉ"=>"ἁι", "ᾊ"=>"ἂι", "ᾋ"=>"ἃι", "ᾌ"=>"ἄι", "ᾍ"=>"ἅι", "ᾎ"=>"ἆι", "ᾏ"=>"ἇι", "ᾐ"=>"ἠι", "ᾑ"=>"ἡι", "ᾒ"=>"ἢι", "ᾓ"=>"ἣι", "ᾔ"=>"ἤι", "ᾕ"=>"ἥι", "ᾖ"=>"ἦι", "ᾗ"=>"ἧι", "ᾘ"=>"ἠι", "ᾙ"=>"ἡι", "ᾚ"=>"ἢι", "ᾛ"=>"ἣι", "ᾜ"=>"ἤι", "ᾝ"=>"ἥι", "ᾞ"=>"ἦι", "ᾟ"=>"ἧι", "ᾠ"=>"ὠι", "ᾡ"=>"ὡι", "ᾢ"=>"ὢι", "ᾣ"=>"ὣι", "ᾤ"=>"ὤι", "ᾥ"=>"ὥι", "ᾦ"=>"ὦι", "ᾧ"=>"ὧι", "ᾨ"=>"ὠι", "ᾩ"=>"ὡι", "ᾪ"=>"ὢι", "ᾫ"=>"ὣι", "ᾬ"=>"ὤι", "ᾭ"=>"ὥι", "ᾮ"=>"ὦι", "ᾯ"=>"ὧι", "ᾲ"=>"ὰι", "ᾳ"=>"αι", "ᾴ"=>"άι", "ᾶ"=>"ᾶ", "ᾷ"=>"ᾶι", "Ᾰ"=>"ᾰ", "Ᾱ"=>"ᾱ", "Ὰ"=>"ὰ", "Ά"=>"ά", "ᾼ"=>"αι", "ι"=>"ι", "ῂ"=>"ὴι", "ῃ"=>"ηι", "ῄ"=>"ήι", "ῆ"=>"ῆ", "ῇ"=>"ῆι", "Ὲ"=>"ὲ", "Έ"=>"έ", "Ὴ"=>"ὴ", "Ή"=>"ή", "ῌ"=>"ηι", "ῒ"=>"ῒ", "ΐ"=>"ΐ", "ῖ"=>"ῖ", "ῗ"=>"ῗ", "Ῐ"=>"ῐ", "Ῑ"=>"ῑ", "Ὶ"=>"ὶ", "Ί"=>"ί", "ῢ"=>"ῢ", "ΰ"=>"ΰ", "ῤ"=>"ῤ", "ῦ"=>"ῦ", "ῧ"=>"ῧ", "Ῠ"=>"ῠ", "Ῡ"=>"ῡ", "Ὺ"=>"ὺ", "Ύ"=>"ύ", "Ῥ"=>"ῥ", "ῲ"=>"ὼι", "ῳ"=>"ωι", "ῴ"=>"ώι", "ῶ"=>"ῶ", "ῷ"=>"ῶι", "Ὸ"=>"ὸ", "Ό"=>"ό", "Ὼ"=>"ὼ", "Ώ"=>"ώ", "ῼ"=>"ωι", "Ω"=>"ω", "K"=>"k", "Å"=>"å", "Ⅰ"=>"ⅰ", "Ⅱ"=>"ⅱ", "Ⅲ"=>"ⅲ", "Ⅳ"=>"ⅳ", "Ⅴ"=>"ⅴ", "Ⅵ"=>"ⅵ", "Ⅶ"=>"ⅶ", "Ⅷ"=>"ⅷ", "Ⅸ"=>"ⅸ", "Ⅹ"=>"ⅹ", "Ⅺ"=>"ⅺ", "Ⅻ"=>"ⅻ", "Ⅼ"=>"ⅼ", "Ⅽ"=>"ⅽ", "Ⅾ"=>"ⅾ", "Ⅿ"=>"ⅿ", "Ⓐ"=>"ⓐ", "Ⓑ"=>"ⓑ", "Ⓒ"=>"ⓒ", "Ⓓ"=>"ⓓ", "Ⓔ"=>"ⓔ", "Ⓕ"=>"ⓕ", "Ⓖ"=>"ⓖ", "Ⓗ"=>"ⓗ", "Ⓘ"=>"ⓘ", "Ⓙ"=>"ⓙ", "Ⓚ"=>"ⓚ", "Ⓛ"=>"ⓛ", "Ⓜ"=>"ⓜ", "Ⓝ"=>"ⓝ", "Ⓞ"=>"ⓞ", "Ⓟ"=>"ⓟ", "Ⓠ"=>"ⓠ", "Ⓡ"=>"ⓡ", "Ⓢ"=>"ⓢ", "Ⓣ"=>"ⓣ", "Ⓤ"=>"ⓤ", "Ⓥ"=>"ⓥ", "Ⓦ"=>"ⓦ", "Ⓧ"=>"ⓧ", "Ⓨ"=>"ⓨ", "Ⓩ"=>"ⓩ", "ff"=>"ff", "fi"=>"fi", "fl"=>"fl", "ffi"=>"ffi", "ffl"=>"ffl", "ſt"=>"st", "st"=>"st", "ﬓ"=>"մն", "ﬔ"=>"մե", "ﬕ"=>"մի", "ﬖ"=>"վն", "ﬗ"=>"մխ", "A"=>"a", "B"=>"b", "C"=>"c", "D"=>"d", "E"=>"e", "F"=>"f", "G"=>"g", "H"=>"h", "I"=>"i", "J"=>"j", "K"=>"k", "L"=>"l", "M"=>"m", "N"=>"n", "O"=>"o", "P"=>"p", "Q"=>"q", "R"=>"r", "S"=>"s", "T"=>"t", "U"=>"u", "V"=>"v", "W"=>"w", "X"=>"x", "Y"=>"y", "Z"=>"z", "𐐀"=>"𐐨", "𐐁"=>"𐐩", "𐐂"=>"𐐪", "𐐃"=>"𐐫", "𐐄"=>"𐐬", "𐐅"=>"𐐭", "𐐆"=>"𐐮", "𐐇"=>"𐐯", "𐐈"=>"𐐰", "𐐉"=>"𐐱", "𐐊"=>"𐐲", "𐐋"=>"𐐳", "𐐌"=>"𐐴", "𐐍"=>"𐐵", "𐐎"=>"𐐶", "𐐏"=>"𐐷", "𐐐"=>"𐐸", "𐐑"=>"𐐹", "𐐒"=>"𐐺", "𐐓"=>"𐐻", "𐐔"=>"𐐼", "𐐕"=>"𐐽", "𐐖"=>"𐐾", "𐐗"=>"𐐿", "𐐘"=>"𐑀", "𐐙"=>"𐑁", "𐐚"=>"𐑂", "𐐛"=>"𐑃", "𐐜"=>"𐑄", "𐐝"=>"𐑅", "𐐞"=>"𐑆", "𐐟"=>"𐑇", "𐐠"=>"𐑈", "𐐡"=>"𐑉", "𐐢"=>"𐑊", "𐐣"=>"𐑋", "𐐤"=>"𐑌", "𐐥"=>"𐑍"}.freeze - - # ASCII space characters \StringPrep\[\"C.1.1\"] - IN_C_1_1 = / /.freeze - - # Non-ASCII space characters \StringPrep\[\"C.1.2\"] - IN_C_1_2 = /[\u200b\p{Zs}&&[^ ]]/.freeze - - # ASCII control characters \StringPrep\[\"C.2.1\"] - IN_C_2_1 = /[\x00-\x1f\x7f]/.freeze - - # Non-ASCII control characters \StringPrep\[\"C.2.2\"] - IN_C_2_2 = /[\u{06dd 070f 180e feff}\u{0080}-\u{009f}\u{200c}-\u{200d}\u{2028}-\u{2029}\u{2060}-\u{2063}\u{206a}-\u{206f}\u{fff9}-\u{fffc}\u{1d173}-\u{1d17a}]/.freeze - - # Private use \StringPrep\[\"C.3\"] - IN_C_3 = /\p{private use}/.freeze - - # Non-character code points \StringPrep\[\"C.4\"] - IN_C_4 = /\p{noncharacter code point}/.freeze - - # Surrogate codes \StringPrep\[\"C.5\"] - IN_C_5 = /\p{surrogate}/.freeze - - # Inappropriate for plain text \StringPrep\[\"C.6\"] - IN_C_6 = /[\p{in specials}&&\p{AGE=3.2}&&\p{^NChar}]/.freeze - - # Inappropriate for canonical representation \StringPrep\[\"C.7\"] - IN_C_7 = /[\p{in ideographic description characters}&&\p{AGE=3.2}]/.freeze - - # Change display properties or are deprecated \StringPrep\[\"C.8\"] - IN_C_8 = /[\u{0340}-\u{0341}\u{200e}-\u{200f}\u{202a}-\u{202e}\u{206a}-\u{206f}]/.freeze - - # Tagging characters \StringPrep\[\"C.9\"] - IN_C_9 = /[\p{in Tags}&&\p{AGE=3.2}]/.freeze - - # Characters with bidirectional property "R" or "AL" \StringPrep\[\"D.1\"] - IN_D_1 = /[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]/.freeze - - # Used to check req3 of bidirectional checks - # Matches the negation of the D.1 table - IN_D_1_NEGATED = /[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]/.freeze - - # Characters with bidirectional property "L" \StringPrep\[\"D.2\"] - IN_D_2 = /[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]/.freeze - - BIDI_DESC_REQ2 = "A string with RandALCat characters must not contain LCat characters." - - # Bidirectional Characters [StringPrep, §6], Requirement 2 - # >>> - # If a string contains any RandALCat character, the string MUST NOT - # contain any LCat character. - BIDI_FAILS_REQ2 = /(?m-ix:(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]))|(?m-ix:(?-mix:[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]).*?(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]))/.freeze - - BIDI_DESC_REQ3 = "A string with RandALCat characters must start and end with RandALCat characters." - - # Bidirectional Characters [StringPrep, §6], Requirement 3 - # >>> - # If a string contains any RandALCat character, a RandALCat - # character MUST be the first character of the string, and a - # RandALCat character MUST be the last character of the string. - BIDI_FAILS_REQ3 = /(?m-ix:\A(?-mix:[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]))|(?m-ix:(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}])\z)/.freeze - - # Bidirectional Characters [StringPrep, §6] - BIDI_FAILURE = /(?-mix:(?m-ix:(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]))|(?m-ix:(?-mix:[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]).*?(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}])))|(?-mix:(?m-ix:\A(?-mix:[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]))|(?m-ix:(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}])\z))/.freeze - - # Names of each codepoint table in the RFC-3454 appendices - TITLES = { - "A.1" => "Unassigned code points in Unicode 3.2", - "B.1" => "Commonly mapped to nothing", - "B.2" => "Mapping for case-folding used with NFKC", - "B.3" => "Mapping for case-folding used with no normalization", - "C.1" => "Space characters", - "C.1.1" => "ASCII space characters", - "C.1.2" => "Non-ASCII space characters", - "C.2" => "Control characters", - "C.2.1" => "ASCII control characters", - "C.2.2" => "Non-ASCII control characters", - "C.3" => "Private use", - "C.4" => "Non-character code points", - "C.5" => "Surrogate codes", - "C.6" => "Inappropriate for plain text", - "C.7" => "Inappropriate for canonical representation", - "C.8" => "Change display properties or are deprecated", - "C.9" => "Tagging characters", - "D.1" => "Characters with bidirectional property \"R\" or \"AL\"", - "D.2" => "Characters with bidirectional property \"L\"", - }.freeze - - # Regexps matching each codepoint table in the RFC-3454 appendices - REGEXPS = { - "A.1" => IN_A_1, - "B.1" => IN_B_1, - "B.2" => IN_B_2, - "B.3" => IN_B_3, - "C.1.1" => IN_C_1_1, - "C.1.2" => IN_C_1_2, - "C.2.1" => IN_C_2_1, - "C.2.2" => IN_C_2_2, - "C.3" => IN_C_3, - "C.4" => IN_C_4, - "C.5" => IN_C_5, - "C.6" => IN_C_6, - "C.7" => IN_C_7, - "C.8" => IN_C_8, - "C.9" => IN_C_9, - "D.1" => IN_D_1, - "D.2" => IN_D_2, - }.freeze - - MAPPINGS = { - "B.1" => [IN_B_1, MAP_B_1].freeze, - "B.2" => [IN_B_2, MAP_B_2].freeze, - "B.3" => [IN_B_3, MAP_B_3].freeze, - }.freeze - - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/trace.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/trace.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/trace.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep/trace.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,85 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP - module StringPrep - - # Defined in RFC-4505[https://tools.ietf.org/html/rfc4505] §3, The +trace+ - # profile of \StringPrep is used by the +ANONYMOUS+ \SASL mechanism. - module Trace - - # Defined in RFC-4505[https://tools.ietf.org/html/rfc4505] §3. - STRINGPREP_PROFILE = "trace" - - # >>> - # The character repertoire of this profile is Unicode 3.2 [Unicode]. - UNASSIGNED_TABLE = "A.1" - - # >>> - # No mapping is required by this profile. - MAPPING_TABLES = nil - - # >>> - # No Unicode normalization is required by this profile. - NORMALIZATION = nil - - # From RFC-4505[https://tools.ietf.org/html/rfc4505] §3, The "trace" - # Profile of "Stringprep": - # >>> - # Characters from the following tables of [StringPrep] are prohibited: - # - # - C.2.1 (ASCII control characters) - # - C.2.2 (Non-ASCII control characters) - # - C.3 (Private use characters) - # - C.4 (Non-character code points) - # - C.5 (Surrogate codes) - # - C.6 (Inappropriate for plain text) - # - C.8 (Change display properties are deprecated) - # - C.9 (Tagging characters) - # - # No additional characters are prohibited. - PROHIBITED_TABLES = %w[C.2.1 C.2.2 C.3 C.4 C.5 C.6 C.8 C.9].freeze - - # >>> - # This profile requires bidirectional character checking per Section 6 - # of [StringPrep]. - CHECK_BIDI = true - - module_function - - # From RFC-4505[https://tools.ietf.org/html/rfc4505] §3, The "trace" - # Profile of "Stringprep": - # >>> - # The character repertoire of this profile is Unicode 3.2 [Unicode]. - # - # No mapping is required by this profile. - # - # No Unicode normalization is required by this profile. - # - # The list of unassigned code points for this profile is that provided - # in Appendix A of [StringPrep]. Unassigned code points are not - # prohibited. - # - # Characters from the following tables of [StringPrep] are prohibited: - # (documented on PROHIBITED_TABLES) - # - # This profile requires bidirectional character checking per Section 6 - # of [StringPrep]. - def stringprep_trace(string, **opts) - StringPrep.stringprep( - string, - unassigned: UNASSIGNED_TABLE, - maps: MAPPING_TABLES, - prohibited: PROHIBITED_TABLES, - normalization: NORMALIZATION, - bidi: CHECK_BIDI, - profile: STRINGPREP_PROFILE, - **opts, - ) - end - - end - - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/stringprep.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,159 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP < Protocol - - # Regexps and utility methods for implementing stringprep profiles. The - # \StringPrep algorithm is defined by - # {RFC-3454}[https://www.rfc-editor.org/rfc/rfc3454.html]. Each - # codepoint table defined in the RFC-3454 appendices is matched by a Regexp - # defined in this module. - module StringPrep - autoload :NamePrep, File.expand_path("stringprep/nameprep", __dir__) - autoload :SASLprep, File.expand_path("stringprep/saslprep", __dir__) - autoload :Tables, File.expand_path("stringprep/tables", __dir__) - autoload :Trace, File.expand_path("stringprep/trace", __dir__) - - # ArgumentError raised when +string+ is invalid for the stringprep - # +profile+. - class StringPrepError < ArgumentError - attr_reader :string, :profile - - def initialize(*args, string: nil, profile: nil) - @string = -string.to_str unless string.nil? - @profile = -profile.to_str unless profile.nil? - super(*args) - end - end - - # StringPrepError raised when +string+ contains a codepoint prohibited by - # +table+. - class ProhibitedCodepoint < StringPrepError - attr_reader :table - - def initialize(table, *args, **kwargs) - @table = table - details = (title = Tables::TITLES[table]) ? - "%s [%s]" % [title, table] : table - message = "String contains a prohibited codepoint: %s" % [details] - super(message, *args, **kwargs) - end - end - - # StringPrepError raised when +string+ contains bidirectional characters - # which violate the StringPrep requirements. - class BidiStringError < StringPrepError - end - - # Returns a Regexp matching the given +table+ name. - def self.[](table) - Tables::REGEXPS.fetch(table) - end - - module_function - - # >>> - # 1. Map -- For each character in the input, check if it has a mapping - # and, if so, replace it with its mapping. This is described in - # section 3. - # - # 2. Normalize -- Possibly normalize the result of step 1 using Unicode - # normalization. This is described in section 4. - # - # 3. Prohibit -- Check for any characters that are not allowed in the - # output. If any are found, return an error. This is described in - # section 5. - # - # 4. Check bidi -- Possibly check for right-to-left characters, and if - # any are found, make sure that the whole string satisfies the - # requirements for bidirectional strings. If the string does not - # satisfy the requirements for bidirectional strings, return an - # error. This is described in section 6. - # - # The above steps MUST be performed in the order given to comply with - # this specification. - # - def stringprep(string, - maps:, - normalization:, - prohibited:, - **opts) - string = string.encode("UTF-8") # also dups (and raises invalid encoding) - map_tables!(string, *maps) if maps - string.unicode_normalize!(normalization) if normalization - check_prohibited!(string, *prohibited, **opts) if prohibited - string - end - - def map_tables!(string, *tables) - tables.each do |table| - regexp, replacements = Tables::MAPPINGS.fetch(table) - string.gsub!(regexp, replacements) - end - string - end - - # Checks +string+ for any codepoint in +tables+. Raises a - # ProhibitedCodepoint describing the first matching table. - # - # Also checks bidirectional characters, when bidi: true, which may - # raise a BidiStringError. - # - # +profile+ is an optional string which will be added to any exception that - # is raised (it does not affect behavior). - def check_prohibited!(string, - *tables, - bidi: false, - unassigned: "A.1", - stored: false, - profile: nil) - tables = Tables::TITLES.keys.grep(/^C/) if tables.empty? - tables |= [unassigned] if stored - tables |= %w[C.8] if bidi - table = tables.find {|t| - case t - when String then Tables::REGEXPS.fetch(t).match?(string) - when Regexp then t.match?(string) - else raise ArgumentError, "only table names and regexps can be checked" - end - } - if table - raise ProhibitedCodepoint.new( - table, string: string, profile: profile - ) - end - check_bidi!(string, profile: profile) if bidi - end - - # Checks that +string+ obeys all of the "Bidirectional Characters" - # requirements in RFC-3454, §6: - # - # * The characters in \StringPrep\[\"C.8\"] MUST be prohibited - # * If a string contains any RandALCat character, the string MUST NOT - # contain any LCat character. - # * If a string contains any RandALCat character, a RandALCat - # character MUST be the first character of the string, and a - # RandALCat character MUST be the last character of the string. - # - # This is usually combined with #check_prohibited!, so table "C.8" is only - # checked when c_8: true. - # - # Raises either ProhibitedCodepoint or BidiStringError unless all - # requirements are met. +profile+ is an optional string which will be - # added to any exception that is raised (it does not affect behavior). - def check_bidi!(string, c_8: false, profile: nil) - check_prohibited!(string, "C.8", profile: profile) if c_8 - if Tables::BIDI_FAILS_REQ2.match?(string) - raise BidiStringError.new( - Tables::BIDI_DESC_REQ2, string: string, profile: profile, - ) - elsif Tables::BIDI_FAILS_REQ3.match?(string) - raise BidiStringError.new( - Tables::BIDI_DESC_REQ3, string: string, profile: profile, - ) - end - end - - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/uidplus_data.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/uidplus_data.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap/uidplus_data.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap/uidplus_data.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,326 +0,0 @@ -# frozen_string_literal: true - -module Net - class IMAP < Protocol - - # *NOTE:* UIDPlusData is deprecated and will be removed in the +0.6.0+ - # release. To use AppendUIDData and CopyUIDData before +0.6.0+, set - # Config#parser_use_deprecated_uidplus_data to +false+. - # - # UIDPlusData represents the ResponseCode#data that accompanies the - # +APPENDUID+ and +COPYUID+ {response codes}[rdoc-ref:ResponseCode]. - # - # A server that supports +UIDPLUS+ should send UIDPlusData in response to - # the append[rdoc-ref:Net::IMAP#append], copy[rdoc-ref:Net::IMAP#copy], - # move[rdoc-ref:Net::IMAP#move], {uid copy}[rdoc-ref:Net::IMAP#uid_copy], - # and {uid move}[rdoc-ref:Net::IMAP#uid_move] commands---unless the - # destination mailbox reports +UIDNOTSTICKY+. - # - # Note that append[rdoc-ref:Net::IMAP#append], copy[rdoc-ref:Net::IMAP#copy] - # and {uid_copy}[rdoc-ref:Net::IMAP#uid_copy] return UIDPlusData in their - # TaggedResponse. But move[rdoc-ref:Net::IMAP#copy] and - # {uid_move}[rdoc-ref:Net::IMAP#uid_move] _should_ send UIDPlusData in an - # UntaggedResponse response before sending their TaggedResponse. However - # some servers do send UIDPlusData in the TaggedResponse for +MOVE+ - # commands---this complies with the older +UIDPLUS+ specification but is - # discouraged by the +MOVE+ extension and disallowed by +IMAP4rev2+. - # - # == Required capability - # Requires either +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315]] - # or +IMAP4rev2+ capability. - # - class UIDPlusData < Struct.new(:uidvalidity, :source_uids, :assigned_uids) - ## - # method: uidvalidity - # :call-seq: uidvalidity -> nonzero uint32 - # - # The UIDVALIDITY of the destination mailbox. - - ## - # method: source_uids - # :call-seq: source_uids -> nil or an array of nonzero uint32 - # - # The UIDs of the copied or moved messages. - # - # Note:: Returns +nil+ for Net::IMAP#append. - - ## - # method: assigned_uids - # :call-seq: assigned_uids -> an array of nonzero uint32 - # - # The newly assigned UIDs of the copied, moved, or appended messages. - # - # Note:: This always returns an array, even when it contains only one UID. - - ## - # :call-seq: uid_mapping -> nil or a hash - # - # Returns a hash mapping each source UID to the newly assigned destination - # UID. - # - # Note:: Returns +nil+ for Net::IMAP#append. - def uid_mapping - source_uids&.zip(assigned_uids)&.to_h - end - end - - # This replaces the `Data.define` polyfill that's used by net-imap 0.5. - class Data_define__uidvalidity___assigned_uids_ # :no-doc: - attr_reader :uidvalidity, :assigned_uids - - def self.[](...) new(...) end - def self.new(uidvalidity = (args = false; nil), - assigned_uids = nil, - **kwargs) - if kwargs.empty? - super(uidvalidity: uidvalidity, assigned_uids: assigned_uids) - elsif !args - super - else - raise ArgumentError, "sent both positional and keyword args" - end - end - - def ==(other) - self.class == other.class && - self.uidvalidity == other.uidvalidity && - self.assigned_uids == other.assigned_uids - end - - def eql?(other) - self.class.eql?(other.class) && - self.uidvalidity.eql?(other.uidvalidity) && - self.assigned_uids.eql?(other.assigned_uids) - end - - def hash; [self.class, uidvalidity, assigned_uids].hash end - - def initialize(uidvalidity:, assigned_uids:) - @uidvalidity = uidvalidity - @assigned_uids = assigned_uids - freeze - end - end - - # >>> - # *NOTE:* AppendUIDData will replace UIDPlusData for +APPENDUID+ in the - # +0.6.0+ release. To use AppendUIDData before +0.6.0+, set - # Config#parser_use_deprecated_uidplus_data to +false+. - # - # AppendUIDData represents the ResponseCode#data that accompanies the - # +APPENDUID+ {response code}[rdoc-ref:ResponseCode]. - # - # A server that supports +UIDPLUS+ (or +IMAP4rev2+) should send - # AppendUIDData inside every TaggedResponse returned by the - # append[rdoc-ref:Net::IMAP#append] command---unless the target mailbox - # reports +UIDNOTSTICKY+. - # - # == Required capability - # Requires either +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315]] - # or +IMAP4rev2+ capability. - class AppendUIDData < Data_define__uidvalidity___assigned_uids_ - def initialize(uidvalidity:, assigned_uids:) - uidvalidity = Integer(uidvalidity) - assigned_uids = SequenceSet[assigned_uids] - NumValidator.ensure_nz_number(uidvalidity) - if assigned_uids.include_star? - raise DataFormatError, "uid-set cannot contain '*'" - end - super - end - - ## - # attr_reader: uidvalidity - # :call-seq: uidvalidity -> nonzero uint32 - # - # The UIDVALIDITY of the destination mailbox. - - ## - # attr_reader: assigned_uids - # - # A SequenceSet with the newly assigned UIDs of the appended messages. - - # Returns the number of messages that have been appended. - def size - assigned_uids.count_with_duplicates - end - end - - # This replaces the `Data.define` polyfill that's used by net-imap 0.5. - class Data_define__uidvalidity___source_uids___assigned_uids_ # :no-doc: - attr_reader :uidvalidity, :source_uids, :assigned_uids - - def self.[](...) new(...) end - def self.new(uidvalidity = (args = false; nil), - source_uids = nil, - assigned_uids = nil, - **kwargs) - if kwargs.empty? - super(uidvalidity: uidvalidity, - source_uids: source_uids, - assigned_uids: assigned_uids) - elsif !args - super(**kwargs) - else - raise ArgumentError, "sent both positional and keyword args" - end - end - - def initialize(uidvalidity:, source_uids:, assigned_uids:) - @uidvalidity = uidvalidity - @source_uids = source_uids - @assigned_uids = assigned_uids - freeze - end - - def ==(other) - self.class == other.class && - self.uidvalidity == other.uidvalidity && - self.source_uids == other.source_uids - self.assigned_uids == other.assigned_uids - end - - def eql?(other) - self.class.eql?(other.class) && - self.uidvalidity.eql?(other.uidvalidity) && - self.source_uids.eql?(other.source_uids) - self.assigned_uids.eql?(other.assigned_uids) - end - - def hash; [self.class, uidvalidity, source_uids, assigned_uids].hash end - end - - # >>> - # *NOTE:* CopyUIDData will replace UIDPlusData for +COPYUID+ in the - # +0.6.0+ release. To use CopyUIDData before +0.6.0+, set - # Config#parser_use_deprecated_uidplus_data to +false+. - # - # CopyUIDData represents the ResponseCode#data that accompanies the - # +COPYUID+ {response code}[rdoc-ref:ResponseCode]. - # - # A server that supports +UIDPLUS+ (or +IMAP4rev2+) should send CopyUIDData - # in response to - # copy[rdoc-ref:Net::IMAP#copy], {uid_copy}[rdoc-ref:Net::IMAP#uid_copy], - # move[rdoc-ref:Net::IMAP#copy], and {uid_move}[rdoc-ref:Net::IMAP#uid_move] - # commands---unless the destination mailbox reports +UIDNOTSTICKY+. - # - # Note that copy[rdoc-ref:Net::IMAP#copy] and - # {uid_copy}[rdoc-ref:Net::IMAP#uid_copy] return CopyUIDData in their - # TaggedResponse. But move[rdoc-ref:Net::IMAP#copy] and - # {uid_move}[rdoc-ref:Net::IMAP#uid_move] _should_ send CopyUIDData in an - # UntaggedResponse response before sending their TaggedResponse. However - # some servers do send CopyUIDData in the TaggedResponse for +MOVE+ - # commands---this complies with the older +UIDPLUS+ specification but is - # discouraged by the +MOVE+ extension and disallowed by +IMAP4rev2+. - # - # == Required capability - # Requires either +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315]] - # or +IMAP4rev2+ capability. - class CopyUIDData < Data_define__uidvalidity___source_uids___assigned_uids_ - def initialize(uidvalidity:, source_uids:, assigned_uids:) - uidvalidity = Integer(uidvalidity) - source_uids = SequenceSet[source_uids] - assigned_uids = SequenceSet[assigned_uids] - NumValidator.ensure_nz_number(uidvalidity) - if source_uids.include_star? || assigned_uids.include_star? - raise DataFormatError, "uid-set cannot contain '*'" - elsif source_uids.count_with_duplicates != assigned_uids.count_with_duplicates - raise DataFormatError, "mismatched uid-set sizes for %s and %s" % [ - source_uids, assigned_uids - ] - end - super - end - - ## - # attr_reader: uidvalidity - # - # The +UIDVALIDITY+ of the destination mailbox (a nonzero unsigned 32 bit - # integer). - - ## - # attr_reader: source_uids - # - # A SequenceSet with the original UIDs of the copied or moved messages. - - ## - # attr_reader: assigned_uids - # - # A SequenceSet with the newly assigned UIDs of the copied or moved - # messages. - - # Returns the number of messages that have been copied or moved. - # source_uids and the assigned_uids will both the same number of UIDs. - def size - assigned_uids.count_with_duplicates - end - - # :call-seq: - # assigned_uid_for(source_uid) -> uid - # self[source_uid] -> uid - # - # Returns the UID in the destination mailbox for the message that was - # copied from +source_uid+ in the source mailbox. - # - # This is the reverse of #source_uid_for. - # - # Related: source_uid_for, each_uid_pair, uid_mapping - def assigned_uid_for(source_uid) - idx = source_uids.find_ordered_index(source_uid) and - assigned_uids.ordered_at(idx) - end - alias :[] :assigned_uid_for - - # :call-seq: - # source_uid_for(assigned_uid) -> uid - # - # Returns the UID in the source mailbox for the message that was copied to - # +assigned_uid+ in the source mailbox. - # - # This is the reverse of #assigned_uid_for. - # - # Related: assigned_uid_for, each_uid_pair, uid_mapping - def source_uid_for(assigned_uid) - idx = assigned_uids.find_ordered_index(assigned_uid) and - source_uids.ordered_at(idx) - end - - # Yields a pair of UIDs for each copied message. The first is the - # message's UID in the source mailbox and the second is the UID in the - # destination mailbox. - # - # Returns an enumerator when no block is given. - # - # Please note the warning on uid_mapping before calling methods like - # +to_h+ or +to_a+ on the returned enumerator. - # - # Related: uid_mapping, assigned_uid_for, source_uid_for - def each_uid_pair - return enum_for(__method__) unless block_given? - source_uids.each_ordered_number.lazy - .zip(assigned_uids.each_ordered_number.lazy) do - |source_uid, assigned_uid| - yield source_uid, assigned_uid - end - end - alias each_pair each_uid_pair - alias each each_uid_pair - - # :call-seq: uid_mapping -> hash - # - # Returns a hash mapping each source UID to the newly assigned destination - # UID. - # - # *Warning:* The hash that is created may consume _much_ more - # memory than the data used to create it. When handling responses from an - # untrusted server, check #size before calling this method. - # - # Related: each_uid_pair, assigned_uid_for, source_uid_for - def uid_mapping - each_uid_pair.to_h - end - - end - - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/lib/net/imap.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/lib/net/imap.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,3116 +0,0 @@ -# frozen_string_literal: true -# -# = net/imap.rb -# -# Copyright (C) 2000 Shugo Maeda -# -# This library is distributed under the terms of the Ruby license. -# You can freely distribute/modify this library. -# -# Documentation: Shugo Maeda, with RDoc conversion and overview by William -# Webber. -# -# See Net::IMAP for documentation. -# - -require "socket" -require "monitor" -require 'net/protocol' -begin - require "openssl" -rescue LoadError -end - -module Net - - # Net::IMAP implements Internet Message Access Protocol (\IMAP) client - # functionality. The protocol is described - # in {IMAP4rev1 [RFC3501]}[https://tools.ietf.org/html/rfc3501] - # and {IMAP4rev2 [RFC9051]}[https://tools.ietf.org/html/rfc9051]. - # - # == \IMAP Overview - # - # An \IMAP client connects to a server, and then authenticates - # itself using either #authenticate or #login. Having - # authenticated itself, there is a range of commands - # available to it. Most work with mailboxes, which may be - # arranged in an hierarchical namespace, and each of which - # contains zero or more messages. How this is implemented on - # the server is implementation-dependent; on a UNIX server, it - # will frequently be implemented as files in mailbox format - # within a hierarchy of directories. - # - # To work on the messages within a mailbox, the client must - # first select that mailbox, using either #select or #examine - # (for read-only access). Once the client has successfully - # selected a mailbox, they enter the "_selected_" state, and that - # mailbox becomes the _current_ mailbox, on which mail-item - # related commands implicitly operate. - # - # === Sequence numbers and UIDs - # - # Messages have two sorts of identifiers: message sequence - # numbers and UIDs. - # - # Message sequence numbers number messages within a mailbox - # from 1 up to the number of items in the mailbox. If a new - # message arrives during a session, it receives a sequence - # number equal to the new size of the mailbox. If messages - # are expunged from the mailbox, remaining messages have their - # sequence numbers "shuffled down" to fill the gaps. - # - # To avoid sequence number race conditions, servers must not expunge messages - # when no command is in progress, nor when responding to #fetch, #store, or - # #search. Expunges _may_ be sent during any other command, including - # #uid_fetch, #uid_store, and #uid_search. The #noop and #idle commands are - # both useful for this side-effect: they allow the server to send all mailbox - # updates, including expunges. - # - # UIDs, on the other hand, are permanently guaranteed not to - # identify another message within the same mailbox, even if - # the existing message is deleted. UIDs are required to - # be assigned in ascending (but not necessarily sequential) - # order within a mailbox; this means that if a non-IMAP client - # rearranges the order of mail items within a mailbox, the - # UIDs have to be reassigned. An \IMAP client thus cannot - # rearrange message orders. - # - # === Examples of Usage - # - # ==== List sender and subject of all recent messages in the default mailbox - # - # imap = Net::IMAP.new('mail.example.com') - # imap.authenticate('PLAIN', 'joe_user', 'joes_password') - # imap.examine('INBOX') - # imap.search(["RECENT"]).each do |message_id| - # envelope = imap.fetch(message_id, "ENVELOPE")[0].attr["ENVELOPE"] - # puts "#{envelope.from[0].name}: \t#{envelope.subject}" - # end - # - # ==== Move all messages from April 2003 from "Mail/sent-mail" to "Mail/sent-apr03" - # - # imap = Net::IMAP.new('mail.example.com') - # imap.authenticate('PLAIN', 'joe_user', 'joes_password') - # imap.select('Mail/sent-mail') - # if not imap.list('Mail/', 'sent-apr03') - # imap.create('Mail/sent-apr03') - # end - # imap.search(["BEFORE", "30-Apr-2003", "SINCE", "1-Apr-2003"]).each do |message_id| - # imap.copy(message_id, "Mail/sent-apr03") - # imap.store(message_id, "+FLAGS", [:Deleted]) - # end - # imap.expunge - # - # == Capabilities - # - # Most Net::IMAP methods do not _currently_ modify their behaviour according - # to the server's advertised #capabilities. Users of this class must check - # that the server is capable of extension commands or command arguments before - # sending them. Special care should be taken to follow the #capabilities - # requirements for #starttls, #login, and #authenticate. - # - # See #capable?, #auth_capable?, #capabilities, #auth_mechanisms to discover - # server capabilities. For relevant capability requirements, see the - # documentation on each \IMAP command. - # - # imap = Net::IMAP.new("mail.example.com") - # imap.capable?(:IMAP4rev1) or raise "Not an IMAP4rev1 server" - # imap.capable?(:starttls) or raise "Cannot start TLS" - # imap.starttls - # - # if imap.auth_capable?("PLAIN") - # imap.authenticate "PLAIN", username, password - # elsif !imap.capability?("LOGINDISABLED") - # imap.login username, password - # else - # raise "No acceptable authentication mechanisms" - # end - # - # # Support for "UTF8=ACCEPT" implies support for "ENABLE" - # imap.enable :utf8 if imap.capable?("UTF8=ACCEPT") - # - # namespaces = imap.namespace if imap.capable?(:namespace) - # mbox_prefix = namespaces&.personal&.first&.prefix || "" - # mbox_delim = namespaces&.personal&.first&.delim || "/" - # mbox_path = prefix + %w[path to my mailbox].join(delim) - # imap.create mbox_path - # - # === Basic IMAP4rev1 capabilities - # - # IMAP4rev1 servers must advertise +IMAP4rev1+ in their capabilities list. - # IMAP4rev1 servers must _implement_ the +STARTTLS+, AUTH=PLAIN, - # and +LOGINDISABLED+ capabilities. See #starttls, #login, and #authenticate - # for the implications of these capabilities. - # - # === Caching +CAPABILITY+ responses - # - # Net::IMAP automatically stores and discards capability data according to the - # the requirements and recommendations in - # {IMAP4rev2 §6.1.1}[https://www.rfc-editor.org/rfc/rfc9051#section-6.1.1], - # {§6.2}[https://www.rfc-editor.org/rfc/rfc9051#section-6.2], and - # {§7.1}[https://www.rfc-editor.org/rfc/rfc9051#section-7.1]. - # Use #capable?, #auth_capable?, or #capabilities to use this cache and avoid - # sending the #capability command unnecessarily. - # - # The server may advertise its initial capabilities using the +CAPABILITY+ - # ResponseCode in a +PREAUTH+ or +OK+ #greeting. When TLS has started - # (#starttls) and after authentication (#login or #authenticate), the server's - # capabilities may change and cached capabilities are discarded. The server - # may send updated capabilities with an +OK+ TaggedResponse to #login or - # #authenticate, and these will be cached by Net::IMAP. But the - # TaggedResponse to #starttls MUST be ignored--it is sent before TLS starts - # and is unprotected. - # - # When storing capability values to variables, be careful that they are - # discarded or reset appropriately, especially following #starttls. - # - # === Using IMAP4rev1 extensions - # - # See the {IANA IMAP4 capabilities - # registry}[http://www.iana.org/assignments/imap4-capabilities] for a list of - # all standard capabilities, and their reference RFCs. - # - # IMAP4rev1 servers must not activate behavior that is incompatible with the - # base specification until an explicit client action invokes a capability, - # e.g. sending a command or command argument specific to that capability. - # Servers may send data with backward compatible behavior, such as response - # codes or mailbox attributes, at any time without client action. - # - # Invoking capabilities which are unknown to Net::IMAP may cause unexpected - # behavior and errors. For example, ResponseParseError is raised when - # unknown response syntax is received. Invoking commands or command - # parameters that are unsupported by the server may raise NoResponseError, - # BadResponseError, or cause other unexpected behavior. - # - # Some capabilities must be explicitly activated using the #enable command. - # See #enable for details. - # - # == Thread Safety - # - # Net::IMAP supports concurrent threads. For example, - # - # imap = Net::IMAP.new("imap.foo.net", "imap2") - # imap.authenticate("scram-md5", "bar", "password") - # imap.select("inbox") - # fetch_thread = Thread.start { imap.fetch(1..-1, "UID") } - # search_result = imap.search(["BODY", "hello"]) - # fetch_result = fetch_thread.value - # imap.disconnect - # - # This script invokes the FETCH command and the SEARCH command concurrently. - # - # == Errors - # - # An \IMAP server can send three different types of responses to indicate - # failure: - # - # NO:: the attempted command could not be successfully completed. For - # instance, the username/password used for logging in are incorrect; - # the selected mailbox does not exist; etc. - # - # BAD:: the request from the client does not follow the server's - # understanding of the \IMAP protocol. This includes attempting - # commands from the wrong client state; for instance, attempting - # to perform a SEARCH command without having SELECTed a current - # mailbox. It can also signal an internal server - # failure (such as a disk crash) has occurred. - # - # BYE:: the server is saying goodbye. This can be part of a normal - # logout sequence, and can be used as part of a login sequence - # to indicate that the server is (for some reason) unwilling - # to accept your connection. As a response to any other command, - # it indicates either that the server is shutting down, or that - # the server is timing out the client connection due to inactivity. - # - # These three error response are represented by the errors - # Net::IMAP::NoResponseError, Net::IMAP::BadResponseError, and - # Net::IMAP::ByeResponseError, all of which are subclasses of - # Net::IMAP::ResponseError. Essentially, all methods that involve - # sending a request to the server can generate one of these errors. - # Only the most pertinent instances have been documented below. - # - # Because the IMAP class uses Sockets for communication, its methods - # are also susceptible to the various errors that can occur when - # working with sockets. These are generally represented as - # Errno errors. For instance, any method that involves sending a - # request to the server and/or receiving a response from it could - # raise an Errno::EPIPE error if the network connection unexpectedly - # goes down. See the socket(7), ip(7), tcp(7), socket(2), connect(2), - # and associated man pages. - # - # Finally, a Net::IMAP::DataFormatError is thrown if low-level data - # is found to be in an incorrect format (for instance, when converting - # between UTF-8 and UTF-16), and Net::IMAP::ResponseParseError is - # thrown if a server response is non-parseable. - # - # == What's here? - # - # * {Connection control}[rdoc-ref:Net::IMAP@Connection+control+methods] - # * {Server capabilities}[rdoc-ref:Net::IMAP@Server+capabilities] - # * {Handling server responses}[rdoc-ref:Net::IMAP@Handling+server+responses] - # * {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands] - # * {for any state}[rdoc-ref:Net::IMAP@Any+state] - # * {for the "not authenticated" state}[rdoc-ref:Net::IMAP@Not+Authenticated+state] - # * {for the "authenticated" state}[rdoc-ref:Net::IMAP@Authenticated+state] - # * {for the "selected" state}[rdoc-ref:Net::IMAP@Selected+state] - # * {for the "logout" state}[rdoc-ref:Net::IMAP@Logout+state] - # * {IMAP extension support}[rdoc-ref:Net::IMAP@IMAP+extension+support] - # - # === Connection control methods - # - # - Net::IMAP.new: Creates a new \IMAP client which connects immediately and - # waits for a successful server greeting before the method returns. - # - #starttls: Asks the server to upgrade a clear-text connection to use TLS. - # - #logout: Tells the server to end the session. Enters the "_logout_" state. - # - #disconnect: Disconnects the connection (without sending #logout first). - # - #disconnected?: True if the connection has been closed. - # - # === Server capabilities - # - # - #capable?: Returns whether the server supports a given capability. - # - #capabilities: Returns the server's capabilities as an array of strings. - # - #auth_capable?: Returns whether the server advertises support for a given - # SASL mechanism, for use with #authenticate. - # - #auth_mechanisms: Returns the #authenticate SASL mechanisms which - # the server claims to support as an array of strings. - # - #clear_cached_capabilities: Clears cached capabilities. - # - # The capabilities cache is automatically cleared after completing - # #starttls, #login, or #authenticate. - # - #capability: Sends the +CAPABILITY+ command and returns the #capabilities. - # - # In general, #capable? should be used rather than explicitly sending a - # +CAPABILITY+ command to the server. - # - # === Handling server responses - # - # - #greeting: The server's initial untagged response, which can indicate a - # pre-authenticated connection. - # - #responses: Yields unhandled UntaggedResponse#data and non-+nil+ - # ResponseCode#data. - # - #extract_responses: Removes and returns the responses for which the block - # returns a true value. - # - #clear_responses: Deletes unhandled data from #responses and returns it. - # - #add_response_handler: Add a block to be called inside the receiver thread - # with every server response. - # - #response_handlers: Returns the list of response handlers. - # - #remove_response_handler: Remove a previously added response handler. - # - # === Core \IMAP commands - # - # The following commands are defined either by - # the [IMAP4rev1[https://tools.ietf.org/html/rfc3501]] base specification, or - # by one of the following extensions: - # [IDLE[https://tools.ietf.org/html/rfc2177]], - # [NAMESPACE[https://tools.ietf.org/html/rfc2342]], - # [UNSELECT[https://tools.ietf.org/html/rfc3691]], - # [ENABLE[https://tools.ietf.org/html/rfc5161]], - # [MOVE[https://tools.ietf.org/html/rfc6851]]. - # These extensions are widely supported by modern IMAP4rev1 servers and have - # all been integrated into [IMAP4rev2[https://tools.ietf.org/html/rfc9051]]. - # *NOTE:* Net::IMAP doesn't support IMAP4rev2 yet. - # - # ==== Any state - # - # - #capability: Returns the server's capabilities as an array of strings. - # - # In general, #capable? should be used rather than explicitly sending a - # +CAPABILITY+ command to the server. - # - #noop: Allows the server to send unsolicited untagged #responses. - # - #logout: Tells the server to end the session. Enters the "_logout_" state. - # - # ==== Not Authenticated state - # - # In addition to the commands for any state, the following commands are valid - # in the "not authenticated" state: - # - # - #starttls: Upgrades a clear-text connection to use TLS. - # - # Requires the +STARTTLS+ capability. - # - #authenticate: Identifies the client to the server using the given - # {SASL mechanism}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] - # and credentials. Enters the "_authenticated_" state. - # - # The server should list "AUTH=#{mechanism}" capabilities for - # supported mechanisms. - # - #login: Identifies the client to the server using a plain text password. - # Using #authenticate is generally preferred. Enters the "_authenticated_" - # state. - # - # The +LOGINDISABLED+ capability must NOT be listed. - # - # ==== Authenticated state - # - # In addition to the commands for any state, the following commands are valid - # in the "_authenticated_" state: - # - # - #enable: Enables backwards incompatible server extensions. - # Requires the +ENABLE+ or +IMAP4rev2+ capability. - # - #select: Open a mailbox and enter the "_selected_" state. - # - #examine: Open a mailbox read-only, and enter the "_selected_" state. - # - #create: Creates a new mailbox. - # - #delete: Permanently remove a mailbox. - # - #rename: Change the name of a mailbox. - # - #subscribe: Adds a mailbox to the "subscribed" set. - # - #unsubscribe: Removes a mailbox from the "subscribed" set. - # - #list: Returns names and attributes of mailboxes matching a given pattern. - # - #namespace: Returns mailbox namespaces, with path prefixes and delimiters. - # Requires the +NAMESPACE+ or +IMAP4rev2+ capability. - # - #status: Returns mailbox information, e.g. message count, unseen message - # count, +UIDVALIDITY+ and +UIDNEXT+. - # - #append: Appends a message to the end of a mailbox. - # - #idle: Allows the server to send updates to the client, without the client - # needing to poll using #noop. - # Requires the +IDLE+ or +IMAP4rev2+ capability. - # - *Obsolete* #lsub: Replaced by LIST-EXTENDED and removed from - # +IMAP4rev2+. Lists mailboxes in the "subscribed" set. - # - # *Note:* Net::IMAP hasn't implemented LIST-EXTENDED yet. - # - # ==== Selected state - # - # In addition to the commands for any state and the "_authenticated_" - # commands, the following commands are valid in the "_selected_" state: - # - # - #close: Closes the mailbox and returns to the "_authenticated_" state, - # expunging deleted messages, unless the mailbox was opened as read-only. - # - #unselect: Closes the mailbox and returns to the "_authenticated_" state, - # without expunging any messages. - # Requires the +UNSELECT+ or +IMAP4rev2+ capability. - # - #expunge: Permanently removes messages which have the Deleted flag set. - # - #uid_expunge: Restricts expunge to only remove the specified UIDs. - # Requires the +UIDPLUS+ or +IMAP4rev2+ capability. - # - #search, #uid_search: Returns sequence numbers or UIDs of messages that - # match the given searching criteria. - # - #fetch, #uid_fetch: Returns data associated with a set of messages, - # specified by sequence number or UID. - # - #store, #uid_store: Alters a message's flags. - # - #copy, #uid_copy: Copies the specified messages to the end of the - # specified destination mailbox. - # - #move, #uid_move: Moves the specified messages to the end of the - # specified destination mailbox, expunging them from the current mailbox. - # Requires the +MOVE+ or +IMAP4rev2+ capability. - # - #check: *Obsolete:* removed from +IMAP4rev2+. - # Can be replaced with #noop or #idle. - # - # ==== Logout state - # - # No \IMAP commands are valid in the "_logout_" state. If the socket is still - # open, Net::IMAP will close it after receiving server confirmation. - # Exceptions will be raised by \IMAP commands that have already started and - # are waiting for a response, as well as any that are called after logout. - # - # === \IMAP extension support - # - # ==== RFC9051: +IMAP4rev2+ - # - # Although IMAP4rev2[https://tools.ietf.org/html/rfc9051] is not supported - # yet, Net::IMAP supports several extensions that have been folded into it: - # +ENABLE+, +IDLE+, +MOVE+, +NAMESPACE+, +SASL-IR+, +UIDPLUS+, +UNSELECT+, - # STATUS=SIZE, and the fetch side of +BINARY+. - # Commands for these extensions are listed with the {Core IMAP - # commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands], above. - # - # >>> - # The following are folded into +IMAP4rev2+ but are currently - # unsupported or incompletely supported by Net::IMAP: RFC4466 - # extensions, +ESEARCH+, +SEARCHRES+, +LIST-EXTENDED+, +LIST-STATUS+, - # +LITERAL-+, and +SPECIAL-USE+. - # - # ==== RFC2087: +QUOTA+ - # - #getquota: returns the resource usage and limits for a quota root - # - #getquotaroot: returns the list of quota roots for a mailbox, as well as - # their resource usage and limits. - # - #setquota: sets the resource limits for a given quota root. - # - # ==== RFC2177: +IDLE+ - # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included - # above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. - # - #idle: Allows the server to send updates to the client, without the client - # needing to poll using #noop. - # - # ==== RFC2342: +NAMESPACE+ - # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included - # above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. - # - #namespace: Returns mailbox namespaces, with path prefixes and delimiters. - # - # ==== RFC2971: +ID+ - # - #id: exchanges client and server implementation information. - # - # ==== RFC3516: +BINARY+ - # The fetch side of +BINARY+ has been folded into - # IMAP4rev2[https://tools.ietf.org/html/rfc9051]. - # - Updates #fetch and #uid_fetch with the +BINARY+, +BINARY.PEEK+, and - # +BINARY.SIZE+ items. See FetchData#binary and FetchData#binary_size. - # - # >>> - # *NOTE:* The binary extension the #append command is _not_ supported yet. - # - # ==== RFC3691: +UNSELECT+ - # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included - # above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. - # - #unselect: Closes the mailbox and returns to the "_authenticated_" state, - # without expunging any messages. - # - # ==== RFC4314: +ACL+ - # - #getacl: lists the authenticated user's access rights to a mailbox. - # - #setacl: sets the access rights for a user on a mailbox - # >>> - # *NOTE:* +DELETEACL+, +LISTRIGHTS+, and +MYRIGHTS+ are not supported yet. - # - # ==== RFC4315: +UIDPLUS+ - # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included - # above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. - # - #uid_expunge: Restricts #expunge to only remove the specified UIDs. - # - Updates #select, #examine with the +UIDNOTSTICKY+ ResponseCode - # - Updates #append with the +APPENDUID+ ResponseCode - # - Updates #copy, #move with the +COPYUID+ ResponseCode - # - # ==== RFC4959: +SASL-IR+ - # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051]. - # - Updates #authenticate with the option to send an initial response. - # - # ==== RFC5161: +ENABLE+ - # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included - # above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. - # - #enable: Enables backwards incompatible server extensions. - # - # ==== RFC5256: +SORT+ - # - #sort, #uid_sort: An alternate version of #search or #uid_search which - # sorts the results by specified keys. - # ==== RFC5256: +THREAD+ - # - #thread, #uid_thread: An alternate version of #search or #uid_search, - # which arranges the results into ordered groups or threads according to a - # chosen algorithm. - # - # ==== +X-GM-EXT-1+ - # +X-GM-EXT-1+ is a non-standard Gmail extension. See {Google's - # documentation}[https://developers.google.com/gmail/imap/imap-extensions]. - # - Updates #fetch and #uid_fetch with support for +X-GM-MSGID+ (unique - # message ID), +X-GM-THRID+ (thread ID), and +X-GM-LABELS+ (Gmail labels). - # - Updates #search with the +X-GM-RAW+ search attribute. - # - #xlist: replaced by +SPECIAL-USE+ attributes in #list responses. - # - # *NOTE:* The +OBJECTID+ extension should replace +X-GM-MSGID+ and - # +X-GM-THRID+, but Gmail does not support it (as of 2023-11-10). - # - # ==== RFC6851: +MOVE+ - # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included - # above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. - # - #move, #uid_move: Moves the specified messages to the end of the - # specified destination mailbox, expunging them from the current mailbox. - # - # ==== RFC6855: UTF8=ACCEPT, UTF8=ONLY - # - # - See #enable for information about support for UTF-8 string encoding. - # - # ==== RFC7162: +CONDSTORE+ - # - # - Updates #enable with +CONDSTORE+ parameter. +CONDSTORE+ will also be - # enabled by using any of the extension's command parameters, listed below. - # - Updates #status with the +HIGHESTMODSEQ+ status attribute. - # - Updates #select and #examine with the +condstore+ modifier, and adds - # either a +HIGHESTMODSEQ+ or +NOMODSEQ+ ResponseCode to the responses. - # - Updates #search, #uid_search, #sort, and #uid_sort with the +MODSEQ+ - # search criterion, and adds SearchResult#modseq to the search response. - # - Updates #thread and #uid_thread with the +MODSEQ+ search criterion - # (but thread responses are unchanged). - # - Updates #fetch and #uid_fetch with the +changedsince+ modifier and - # +MODSEQ+ FetchData attribute. - # - Updates #store and #uid_store with the +unchangedsince+ modifier and adds - # the +MODIFIED+ ResponseCode to the tagged response. - # - # ==== RFC8438: STATUS=SIZE - # - Updates #status with the +SIZE+ status attribute. - # - # ==== RFC8474: +OBJECTID+ - # - Adds +MAILBOXID+ ResponseCode to #create tagged response. - # - Adds +MAILBOXID+ ResponseCode to #select and #examine untagged response. - # - Updates #fetch and #uid_fetch with the +EMAILID+ and +THREADID+ items. - # See FetchData#emailid and FetchData#emailid. - # - Updates #status with support for the +MAILBOXID+ status attribute. - # - # == References - # - # [{IMAP4rev1}[https://www.rfc-editor.org/rfc/rfc3501.html]]:: - # Crispin, M., "INTERNET MESSAGE ACCESS PROTOCOL - \VERSION 4rev1", - # RFC 3501, DOI 10.17487/RFC3501, March 2003, - # . - # - # [IMAP-ABNF-EXT[https://www.rfc-editor.org/rfc/rfc4466.html]]:: - # Melnikov, A. and C. Daboo, "Collected Extensions to IMAP4 ABNF", - # RFC 4466, DOI 10.17487/RFC4466, April 2006, - # . - # - # Note: Net::IMAP cannot parse the entire RFC4466 grammar yet. - # - # [{IMAP4rev2}[https://www.rfc-editor.org/rfc/rfc9051.html]]:: - # Melnikov, A., Ed., and B. Leiba, Ed., "Internet Message Access Protocol - # (\IMAP) - Version 4rev2", RFC 9051, DOI 10.17487/RFC9051, August 2021, - # . - # - # Note: Net::IMAP is not fully compatible with IMAP4rev2 yet. - # - # [IMAP-IMPLEMENTATION[https://www.rfc-editor.org/info/rfc2683]]:: - # Leiba, B., "IMAP4 Implementation Recommendations", - # RFC 2683, DOI 10.17487/RFC2683, September 1999, - # . - # - # [IMAP-MULTIACCESS[https://www.rfc-editor.org/info/rfc2180]]:: - # Gahrns, M., "IMAP4 Multi-Accessed Mailbox Practice", RFC 2180, DOI - # 10.17487/RFC2180, July 1997, . - # - # [UTF7[https://tools.ietf.org/html/rfc2152]]:: - # Goldsmith, D. and M. Davis, "UTF-7 A Mail-Safe Transformation Format of - # Unicode", RFC 2152, DOI 10.17487/RFC2152, May 1997, - # . - # - # === Message envelope and body structure - # - # [RFC5322[https://tools.ietf.org/html/rfc5322]]:: - # Resnick, P., Ed., "Internet Message Format", - # RFC 5322, DOI 10.17487/RFC5322, October 2008, - # . - # - # Note: obsoletes - # RFC-2822[https://tools.ietf.org/html/rfc2822] (April 2001) and - # RFC-822[https://tools.ietf.org/html/rfc822] (August 1982). - # - # [CHARSET[https://tools.ietf.org/html/rfc2978]]:: - # Freed, N. and J. Postel, "IANA Charset Registration Procedures", BCP 19, - # RFC 2978, DOI 10.17487/RFC2978, October 2000, - # . - # - # [DISPOSITION[https://tools.ietf.org/html/rfc2183]]:: - # Troost, R., Dorner, S., and K. Moore, Ed., "Communicating Presentation - # Information in Internet Messages: The Content-Disposition Header - # Field", RFC 2183, DOI 10.17487/RFC2183, August 1997, - # . - # - # [MIME-IMB[https://tools.ietf.org/html/rfc2045]]:: - # Freed, N. and N. Borenstein, "Multipurpose Internet Mail Extensions - # (MIME) Part One: Format of Internet Message Bodies", - # RFC 2045, DOI 10.17487/RFC2045, November 1996, - # . - # - # [MIME-IMT[https://tools.ietf.org/html/rfc2046]]:: - # Freed, N. and N. Borenstein, "Multipurpose Internet Mail Extensions - # (MIME) Part Two: Media Types", RFC 2046, DOI 10.17487/RFC2046, - # November 1996, . - # - # [MIME-HDRS[https://tools.ietf.org/html/rfc2047]]:: - # Moore, K., "MIME (Multipurpose Internet Mail Extensions) Part Three: - # Message Header Extensions for Non-ASCII Text", - # RFC 2047, DOI 10.17487/RFC2047, November 1996, - # . - # - # [RFC2231[https://tools.ietf.org/html/rfc2231]]:: - # Freed, N. and K. Moore, "MIME Parameter Value and Encoded Word - # Extensions: Character Sets, Languages, and Continuations", - # RFC 2231, DOI 10.17487/RFC2231, November 1997, - # . - # - # [I18n-HDRS[https://tools.ietf.org/html/rfc6532]]:: - # Yang, A., Steele, S., and N. Freed, "Internationalized Email Headers", - # RFC 6532, DOI 10.17487/RFC6532, February 2012, - # . - # - # [LANGUAGE-TAGS[https://www.rfc-editor.org/info/rfc3282]]:: - # Alvestrand, H., "Content Language Headers", - # RFC 3282, DOI 10.17487/RFC3282, May 2002, - # . - # - # [LOCATION[https://www.rfc-editor.org/info/rfc2557]]:: - # Palme, J., Hopmann, A., and N. Shelness, "MIME Encapsulation of - # Aggregate Documents, such as HTML (MHTML)", - # RFC 2557, DOI 10.17487/RFC2557, March 1999, - # . - # - # [MD5[https://tools.ietf.org/html/rfc1864]]:: - # Myers, J. and M. Rose, "The Content-MD5 Header Field", - # RFC 1864, DOI 10.17487/RFC1864, October 1995, - # . - # - # [RFC3503[https://tools.ietf.org/html/rfc3503]]:: - # Melnikov, A., "Message Disposition Notification (MDN) - # profile for Internet Message Access Protocol (IMAP)", - # RFC 3503, DOI 10.17487/RFC3503, March 2003, - # . - # - # === \IMAP Extensions - # - # [QUOTA[https://tools.ietf.org/html/rfc9208]]:: - # Melnikov, A., "IMAP QUOTA Extension", RFC 9208, DOI 10.17487/RFC9208, - # March 2022, . - # - # Note: obsoletes - # RFC-2087[https://tools.ietf.org/html/rfc2087] (January 1997). - # Net::IMAP does not fully support the RFC9208 updates yet. - # [IDLE[https://tools.ietf.org/html/rfc2177]]:: - # Leiba, B., "IMAP4 IDLE command", RFC 2177, DOI 10.17487/RFC2177, - # June 1997, . - # [NAMESPACE[https://tools.ietf.org/html/rfc2342]]:: - # Gahrns, M. and C. Newman, "IMAP4 Namespace", RFC 2342, - # DOI 10.17487/RFC2342, May 1998, . - # [ID[https://tools.ietf.org/html/rfc2971]]:: - # Showalter, T., "IMAP4 ID extension", RFC 2971, DOI 10.17487/RFC2971, - # October 2000, . - # [BINARY[https://tools.ietf.org/html/rfc3516]]:: - # Nerenberg, L., "IMAP4 Binary Content Extension", RFC 3516, - # DOI 10.17487/RFC3516, April 2003, - # . - # [ACL[https://tools.ietf.org/html/rfc4314]]:: - # Melnikov, A., "IMAP4 Access Control List (ACL) Extension", RFC 4314, - # DOI 10.17487/RFC4314, December 2005, - # . - # [UIDPLUS[https://www.rfc-editor.org/rfc/rfc4315.html]]:: - # Crispin, M., "Internet Message Access Protocol (\IMAP) - UIDPLUS - # extension", RFC 4315, DOI 10.17487/RFC4315, December 2005, - # . - # [SORT[https://tools.ietf.org/html/rfc5256]]:: - # Crispin, M. and K. Murchison, "Internet Message Access Protocol - SORT and - # THREAD Extensions", RFC 5256, DOI 10.17487/RFC5256, June 2008, - # . - # [THREAD[https://tools.ietf.org/html/rfc5256]]:: - # Crispin, M. and K. Murchison, "Internet Message Access Protocol - SORT and - # THREAD Extensions", RFC 5256, DOI 10.17487/RFC5256, June 2008, - # . - # [RFC5530[https://www.rfc-editor.org/rfc/rfc5530.html]]:: - # Gulbrandsen, A., "IMAP Response Codes", RFC 5530, DOI 10.17487/RFC5530, - # May 2009, . - # [MOVE[https://tools.ietf.org/html/rfc6851]]:: - # Gulbrandsen, A. and N. Freed, Ed., "Internet Message Access Protocol - # (\IMAP) - MOVE Extension", RFC 6851, DOI 10.17487/RFC6851, January 2013, - # . - # [UTF8=ACCEPT[https://tools.ietf.org/html/rfc6855]]:: - # [UTF8=ONLY[https://tools.ietf.org/html/rfc6855]]:: - # Resnick, P., Ed., Newman, C., Ed., and S. Shen, Ed., - # "IMAP Support for UTF-8", RFC 6855, DOI 10.17487/RFC6855, March 2013, - # . - # [CONDSTORE[https://tools.ietf.org/html/rfc7162]]:: - # [QRESYNC[https://tools.ietf.org/html/rfc7162]]:: - # Melnikov, A. and D. Cridland, "IMAP Extensions: Quick Flag Changes - # Resynchronization (CONDSTORE) and Quick Mailbox Resynchronization - # (QRESYNC)", RFC 7162, DOI 10.17487/RFC7162, May 2014, - # . - # [OBJECTID[https://tools.ietf.org/html/rfc8474]]:: - # Gondwana, B., Ed., "IMAP Extension for Object Identifiers", - # RFC 8474, DOI 10.17487/RFC8474, September 2018, - # . - # - # === IANA registries - # * {IMAP Capabilities}[http://www.iana.org/assignments/imap4-capabilities] - # * {IMAP Response Codes}[https://www.iana.org/assignments/imap-response-codes/imap-response-codes.xhtml] - # * {IMAP Mailbox Name Attributes}[https://www.iana.org/assignments/imap-mailbox-name-attributes/imap-mailbox-name-attributes.xhtml] - # * {IMAP and JMAP Keywords}[https://www.iana.org/assignments/imap-jmap-keywords/imap-jmap-keywords.xhtml] - # * {IMAP Threading Algorithms}[https://www.iana.org/assignments/imap-threading-algorithms/imap-threading-algorithms.xhtml] - # * {SASL Mechanisms and SASL SCRAM Family Mechanisms}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] - # * {Service Name and Transport Protocol Port Number Registry}[https://www.iana.org/assignments/service-names-port-numbers/service-names-port-numbers.xml]: - # +imap+: tcp/143, +imaps+: tcp/993 - # * {GSSAPI/Kerberos/SASL Service Names}[https://www.iana.org/assignments/gssapi-service-names/gssapi-service-names.xhtml]: - # +imap+ - # * {Character sets}[https://www.iana.org/assignments/character-sets/character-sets.xhtml] - # ===== For currently unsupported features: - # * {IMAP Quota Resource Types}[http://www.iana.org/assignments/imap4-capabilities#imap-capabilities-2] - # * {LIST-EXTENDED options and responses}[https://www.iana.org/assignments/imap-list-extended/imap-list-extended.xhtml] - # * {IMAP METADATA Server Entry and Mailbox Entry Registries}[https://www.iana.org/assignments/imap-metadata/imap-metadata.xhtml] - # * {IMAP ANNOTATE Extension Entries and Attributes}[https://www.iana.org/assignments/imap-annotate-extension/imap-annotate-extension.xhtml] - # * {IMAP URLAUTH Access Identifiers and Prefixes}[https://www.iana.org/assignments/urlauth-access-ids/urlauth-access-ids.xhtml] - # * {IMAP URLAUTH Authorization Mechanism Registry}[https://www.iana.org/assignments/urlauth-authorization-mechanism-registry/urlauth-authorization-mechanism-registry.xhtml] - # - class IMAP < Protocol - VERSION = "0.4.19" - - # Aliases for supported capabilities, to be used with the #enable command. - ENABLE_ALIASES = { - utf8: "UTF8=ACCEPT", - "UTF8=ONLY" => "UTF8=ACCEPT", - }.freeze - - autoload :SASL, File.expand_path("imap/sasl", __dir__) - autoload :SASLAdapter, File.expand_path("imap/sasl_adapter", __dir__) - autoload :StringPrep, File.expand_path("imap/stringprep", __dir__) - - include MonitorMixin - if defined?(OpenSSL::SSL) - include OpenSSL - include SSL - end - - # Returns the global Config object - def self.config; Config.global end - - # Returns the global debug mode. - def self.debug; config.debug end - - # Sets the global debug mode. - def self.debug=(val) - config.debug = val - end - - # The default port for IMAP connections, port 143 - def self.default_port - return PORT - end - - # The default port for IMAPS connections, port 993 - def self.default_tls_port - return SSL_PORT - end - - class << self - alias default_imap_port default_port - alias default_imaps_port default_tls_port - alias default_ssl_port default_tls_port - end - - # Returns the initial greeting the server, an UntaggedResponse. - attr_reader :greeting - - # The client configuration. See Net::IMAP::Config. - # - # By default, the client's local configuration inherits from the global - # Net::IMAP.config. - attr_reader :config - - # Seconds to wait until a connection is opened. - # If the IMAP object cannot open a connection within this time, - # it raises a Net::OpenTimeout exception. The default value is 30 seconds. - def open_timeout; config.open_timeout end - - # Seconds to wait until an IDLE response is received. - def idle_response_timeout; config.idle_response_timeout end - - # The hostname this client connected to - attr_reader :host - - # The port this client connected to - attr_reader :port - - # Returns the - # {SSLContext}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html] - # used by the SSLSocket when TLS is attempted, even when the TLS handshake - # is unsuccessful. The context object will be frozen. - # - # Returns +nil+ for a plaintext connection. - attr_reader :ssl_ctx - - # Returns the parameters that were sent to #ssl_ctx - # {set_params}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-set_params] - # when the connection tries to use TLS (even when unsuccessful). - # - # Returns +false+ for a plaintext connection. - attr_reader :ssl_ctx_params - - # Creates a new Net::IMAP object and connects it to the specified - # +host+. - # - # ==== Options - # - # Accepts the following options: - # - # [port] - # Port number. Defaults to 993 when +ssl+ is truthy, and 143 otherwise. - # - # [ssl] - # If +true+, the connection will use TLS with the default params set by - # {OpenSSL::SSL::SSLContext#set_params}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-set_params]. - # If +ssl+ is a hash, it's passed to - # {OpenSSL::SSL::SSLContext#set_params}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-set_params]; - # the keys are names of attribute assignment methods on - # SSLContext[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html]. For example: - # - # [{ca_file}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#attribute-i-ca_file]] - # The path to a file containing a PEM-format CA certificate. - # [{ca_path}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#attribute-i-ca_path]] - # The path to a directory containing CA certificates in PEM format. - # [{min_version}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-min_version-3D]] - # Sets the lower bound on the supported SSL/TLS protocol version. Set to - # an +OpenSSL+ constant such as +OpenSSL::SSL::TLS1_2_VERSION+, - # [{verify_mode}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#attribute-i-verify_mode]] - # SSL session verification mode. Valid modes include - # +OpenSSL::SSL::VERIFY_PEER+ and +OpenSSL::SSL::VERIFY_NONE+. - # - # See {OpenSSL::SSL::SSLContext}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html] for other valid SSL context params. - # - # See DeprecatedClientOptions.new for deprecated SSL arguments. - # - # [config] - # A Net::IMAP::Config object to use as the basis for #config. By default, - # the global Net::IMAP.config is used. - # - # >>> - # *NOTE:* +config+ does not set #config directly---it sets the _parent_ - # config for inheritance. Every client creates its own unique #config. - # - # All other keyword arguments are forwarded to Net::IMAP::Config.new, to - # initialize the client's #config. For example: - # - # [{open_timeout}[rdoc-ref:Config#open_timeout]] - # Seconds to wait until a connection is opened - # [{idle_response_timeout}[rdoc-ref:Config#idle_response_timeout]] - # Seconds to wait until an IDLE response is received - # - # See Net::IMAP::Config for other valid options. - # - # ==== Examples - # - # Connect to cleartext port 143 at mail.example.com and receive the server greeting: - # imap = Net::IMAP.new('mail.example.com', ssl: false) # => # - # imap.port => 143 - # imap.tls_verified? => false - # imap.greeting => name: ("OK" | "PREAUTH") => status - # status # => "OK" - # # The client is connected in the "Not Authenticated" state. - # - # Connect with TLS to port 993 - # imap = Net::IMAP.new('mail.example.com', ssl: true) # => # - # imap.port => 993 - # imap.tls_verified? => true - # imap.greeting => name: (/OK/i | /PREAUTH/i) => status - # case status - # in /OK/i - # # The client is connected in the "Not Authenticated" state. - # imap.authenticate("PLAIN", "joe_user", "joes_password") - # in /PREAUTH/i - # # The client is connected in the "Authenticated" state. - # end - # - # Connect with prior authentication, for example using an SSL certificate: - # ssl_ctx_params = { - # cert: OpenSSL::X509::Certificate.new(File.read("client.crt")), - # key: OpenSSL::PKey::EC.new(File.read('client.key')), - # extra_chain_cert: [ - # OpenSSL::X509::Certificate.new(File.read("intermediate.crt")), - # ], - # } - # imap = Net::IMAP.new('mail.example.com', ssl: ssl_ctx_params) - # imap.port => 993 - # imap.tls_verified? => true - # imap.greeting => name: "PREAUTH" - # # The client is connected in the "Authenticated" state. - # - # ==== Exceptions - # - # The most common errors are: - # - # [Errno::ECONNREFUSED] - # Connection refused by +host+ or an intervening firewall. - # [Errno::ETIMEDOUT] - # Connection timed out (possibly due to packets being dropped by an - # intervening firewall). - # [Errno::ENETUNREACH] - # There is no route to that network. - # [SocketError] - # Hostname not known or other socket error. - # [Net::IMAP::ByeResponseError] - # Connected to the host successfully, but it immediately said goodbye. - # - def initialize(host, port: nil, ssl: nil, - config: Config.global, **config_options) - super() - # Config options - @host = host - @config = Config.new(config, **config_options) - @port = port || (ssl ? SSL_PORT : PORT) - @ssl_ctx_params, @ssl_ctx = build_ssl_ctx(ssl) - - # Basic Client State - @utf8_strings = false - @debug_output_bol = true - @exception = nil - @greeting = nil - @capabilities = nil - - # Client Protocol Receiver - @parser = ResponseParser.new(config: @config) - @responses = Hash.new {|h, k| h[k] = [] } - @response_handlers = [] - @receiver_thread = nil - @receiver_thread_exception = nil - @receiver_thread_terminating = false - - # Client Protocol Sender (including state for currently running commands) - @tag_prefix = "RUBY" - @tagno = 0 - @tagged_responses = {} - @tagged_response_arrival = new_cond - @continued_command_tag = nil - @continuation_request_arrival = new_cond - @continuation_request_exception = nil - @idle_done_cond = nil - @logout_command_tag = nil - - # Connection - @tls_verified = false - @sock = tcp_socket(@host, @port) - start_tls_session if ssl_ctx - start_imap_connection - - # DEPRECATED: to remove in next version - @client_thread = Thread.current - end - - # Returns true after the TLS negotiation has completed and the remote - # hostname has been verified. Returns false when TLS has been established - # but peer verification was disabled. - def tls_verified?; @tls_verified end - - def client_thread # :nodoc: - warn "Net::IMAP#client_thread is deprecated and will be removed soon." - @client_thread - end - - # Disconnects from the server. - # - # Related: #logout, #logout! - def disconnect - return if disconnected? - begin - begin - # try to call SSL::SSLSocket#io. - @sock.io.shutdown - rescue NoMethodError - # @sock is not an SSL::SSLSocket. - @sock.shutdown - end - rescue Errno::ENOTCONN - # ignore `Errno::ENOTCONN: Socket is not connected' on some platforms. - rescue Exception => e - @receiver_thread.raise(e) - end - @receiver_thread.join - synchronize do - @sock.close - end - raise e if e - end - - # Returns true if disconnected from the server. - # - # Related: #logout, #disconnect - def disconnected? - return @sock.closed? - end - - # Returns whether the server supports a given +capability+. When available, - # cached #capabilities are used without sending a new #capability command to - # the server. - # - # *NOTE:* Most Net::IMAP methods do not _currently_ modify their - # behaviour according to the server's advertised #capabilities. - # - # See Net::IMAP@Capabilities for more about \IMAP capabilities. - # - # Related: #auth_capable?, #capabilities, #capability, #enable - def capable?(capability) capabilities.include? capability.to_s.upcase end - alias capability? capable? - - # Returns the server capabilities. When available, cached capabilities are - # used without sending a new #capability command to the server. - # - # To ensure a case-insensitive comparison, #capable? can be used instead. - # - # *NOTE:* Most Net::IMAP methods do not _currently_ modify their - # behaviour according to the server's advertised #capabilities. - # - # See Net::IMAP@Capabilities for more about \IMAP capabilities. - # - # Related: #capable?, #auth_capable?, #auth_mechanisms, #capability, #enable - def capabilities - @capabilities || capability - end - - # Returns the #authenticate mechanisms that the server claims to support. - # These are derived from the #capabilities with an AUTH= prefix. - # - # This may be different when the connection is cleartext or using TLS. Most - # servers will drop all AUTH= mechanisms from #capabilities after - # the connection has authenticated. - # - # imap = Net::IMAP.new(hostname, ssl: false) - # imap.capabilities # => ["IMAP4REV1", "LOGINDISABLED"] - # imap.auth_mechanisms # => [] - # - # imap.starttls - # imap.capabilities # => ["IMAP4REV1", "AUTH=PLAIN", "AUTH=XOAUTH2", - # # "AUTH=OAUTHBEARER"] - # imap.auth_mechanisms # => ["PLAIN", "XOAUTH2", "OAUTHBEARER"] - # - # imap.authenticate("XOAUTH2", username, oauth2_access_token) - # imap.auth_mechanisms # => [] - # - # Related: #authenticate, #auth_capable?, #capabilities - def auth_mechanisms - capabilities - .grep(/\AAUTH=/i) - .map { _1.delete_prefix("AUTH=") } - end - - # Returns whether the server supports a given SASL +mechanism+ for use with - # the #authenticate command. The +mechanism+ is supported when - # #capabilities includes "AUTH=#{mechanism.to_s.upcase}". When - # available, cached capabilities are used without sending a new #capability - # command to the server. - # - # imap.capable? "AUTH=PLAIN" # => true - # imap.auth_capable? "PLAIN" # => true - # imap.auth_capable? "blurdybloop" # => false - # - # Related: #authenticate, #auth_mechanisms, #capable?, #capabilities - def auth_capable?(mechanism) - capable? "AUTH=#{mechanism}" - end - - # Returns whether capabilities have been cached. When true, #capable? and - # #capabilities don't require sending a #capability command to the server. - # - # See Net::IMAP@Capabilities for more about \IMAP capabilities. - # - # Related: #capable?, #capability, #clear_cached_capabilities - def capabilities_cached? - !!@capabilities - end - - # Clears capabilities that have been remembered by the Net::IMAP client. - # This forces a #capability command to be sent the next time a #capabilities - # query method is called. - # - # Net::IMAP automatically discards its cached capabilities when they can - # change. Explicitly calling this _should_ be unnecessary for well-behaved - # servers. - # - # Related: #capable?, #capability, #capabilities_cached? - def clear_cached_capabilities - synchronize do - clear_responses("CAPABILITY") - @capabilities = nil - end - end - - # Sends a {CAPABILITY command [IMAP4rev1 §6.1.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.1.1] - # and returns an array of capabilities that are supported by the server. - # The result is stored for use by #capable? and #capabilities. - # - # *NOTE:* Most Net::IMAP methods do not _currently_ modify their - # behaviour according to the server's advertised #capabilities. - # - # Net::IMAP automatically stores and discards capability data according to - # the requirements and recommendations in - # {IMAP4rev2 §6.1.1}[https://www.rfc-editor.org/rfc/rfc9051#section-6.1.1], - # {§6.2}[https://www.rfc-editor.org/rfc/rfc9051#section-6.2], and - # {§7.1}[https://www.rfc-editor.org/rfc/rfc9051#section-7.1]. - # Use #capable?, #auth_capable?, or #capabilities to this cache and avoid - # sending the #capability command unnecessarily. - # - # See Net::IMAP@Capabilities for more about \IMAP capabilities. - # - # Related: #capable?, #auth_capable?, #capability, #enable - def capability - synchronize do - send_command("CAPABILITY") - @capabilities = clear_responses("CAPABILITY").last.freeze - end - end - - # Sends an {ID command [RFC2971 §3.1]}[https://www.rfc-editor.org/rfc/rfc2971#section-3.1] - # and returns a hash of the server's response, or nil if the server does not - # identify itself. - # - # Note that the user should first check if the server supports the ID - # capability. For example: - # - # if capable?(:ID) - # id = imap.id( - # name: "my IMAP client (ruby)", - # version: MyIMAP::VERSION, - # "support-url": "mailto:bugs@example.com", - # os: RbConfig::CONFIG["host_os"], - # ) - # end - # - # See [ID[https://tools.ietf.org/html/rfc2971]] for field definitions. - # - # ===== Capabilities - # - # The server's capabilities must include +ID+ - # [RFC2971[https://tools.ietf.org/html/rfc2971]]. - def id(client_id=nil) - synchronize do - send_command("ID", ClientID.new(client_id)) - clear_responses("ID").last - end - end - - # Sends a {NOOP command [IMAP4rev1 §6.1.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.1.2] - # to the server. - # - # This allows the server to send unsolicited untagged EXPUNGE #responses, - # but does not execute any client request. \IMAP servers are permitted to - # send unsolicited untagged responses at any time, except for +EXPUNGE+: - # - # * +EXPUNGE+ can only be sent while a command is in progress. - # * +EXPUNGE+ must _not_ be sent during #fetch, #store, or #search. - # * +EXPUNGE+ may be sent during #uid_fetch, #uid_store, or #uid_search. - # - # Related: #idle, #check - def noop - send_command("NOOP") - end - - # Sends a {LOGOUT command [IMAP4rev1 §6.1.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.1.3] - # to inform the command to inform the server that the client is done with - # the connection. - # - # Related: #disconnect, #logout! - def logout - send_command("LOGOUT") - end - - # Calls #logout then, after receiving the TaggedResponse for the +LOGOUT+, - # calls #disconnect. Returns the TaggedResponse from +LOGOUT+. Returns - # +nil+ when the client is already disconnected, in contrast to #logout - # which raises an exception. - # - # If #logout raises a StandardError, a warning will be printed but the - # exception will not be re-raised. - # - # This is useful in situations where the connection must be dropped, for - # example for security or after tests. If logout errors need to be handled, - # use #logout and #disconnect instead. - # - # Related: #logout, #disconnect - def logout! - logout unless disconnected? - rescue => ex - warn "%s during logout!: %s" % [ - ex.class, host, port, ex - ] - ensure - disconnect - end - - # Sends a {STARTTLS command [IMAP4rev1 §6.2.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.2.1] - # to start a TLS session. - # - # Any +options+ are forwarded directly to - # {OpenSSL::SSL::SSLContext#set_params}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-set_params]; - # the keys are names of attribute assignment methods on - # SSLContext[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html]. - # - # See DeprecatedClientOptions#starttls for deprecated arguments. - # - # This method returns after TLS negotiation and hostname verification are - # both successful. Any error indicates that the connection has not been - # secured. - # - # *Note:* - # >>> - # Any #response_handlers added before STARTTLS should be aware that the - # TaggedResponse to STARTTLS is sent clear-text, _before_ TLS negotiation. - # TLS starts immediately _after_ that response. Any response code sent - # with the response (e.g. CAPABILITY) is insecure and cannot be trusted. - # - # Related: Net::IMAP.new, #login, #authenticate - # - # ===== Capability - # Clients should not call #starttls unless the server advertises the - # +STARTTLS+ capability. - # - # Server capabilities may change after #starttls, #login, and #authenticate. - # Cached #capabilities will be cleared when this method completes. - # - def starttls(**options) - @ssl_ctx_params, @ssl_ctx = build_ssl_ctx(options) - error = nil - ok = send_command("STARTTLS") do |resp| - if resp.kind_of?(TaggedResponse) && resp.name == "OK" - clear_cached_capabilities - clear_responses - start_tls_session - end - rescue Exception => error - raise # note that the error backtrace is in the receiver_thread - end - if error - disconnect - raise error - end - ok - end - - # :call-seq: - # authenticate(mechanism, *, sasl_ir: config.sasl_ir, registry: Net::IMAP::SASL.authenticators, **, &) -> ok_resp - # - # Sends an {AUTHENTICATE command [IMAP4rev1 §6.2.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.2.2] - # to authenticate the client. If successful, the connection enters the - # "_authenticated_" state. - # - # +mechanism+ is the name of the \SASL authentication mechanism to be used. - # - # +sasl_ir+ allows or disallows sending an "initial response" (see the - # +SASL-IR+ capability, below). Defaults to the #config value for - # {sasl_ir}[rdoc-ref:Config#sasl_ir], which defaults to +true+. - # - # All other arguments are forwarded to the registered SASL authenticator for - # the requested mechanism. The documentation for each individual - # mechanism must be consulted for its specific parameters. - # - # Related: #login, #starttls, #auth_capable?, #auth_mechanisms - # - # ==== Mechanisms - # - # Each mechanism has different properties and requirements. Please consult - # the documentation for the specific mechanisms you are using: - # - # +ANONYMOUS+:: - # See AnonymousAuthenticator[rdoc-ref:Net::IMAP::SASL::AnonymousAuthenticator]. - # - # Allows the user to gain access to public services or resources without - # authenticating or disclosing an identity. - # - # +EXTERNAL+:: - # See ExternalAuthenticator[rdoc-ref:Net::IMAP::SASL::ExternalAuthenticator]. - # - # Authenticates using already established credentials, such as a TLS - # certificate or IPsec. - # - # +OAUTHBEARER+:: - # See OAuthBearerAuthenticator[rdoc-ref:Net::IMAP::SASL::OAuthBearerAuthenticator]. - # - # Login using an OAuth2 Bearer token. This is the standard mechanism - # for using OAuth2 with \SASL, but it is not yet deployed as widely as - # +XOAUTH2+. - # - # +PLAIN+:: - # See PlainAuthenticator[rdoc-ref:Net::IMAP::SASL::PlainAuthenticator]. - # - # Login using clear-text username and password. - # - # +SCRAM-SHA-1+:: - # +SCRAM-SHA-256+:: - # See ScramAuthenticator[rdoc-ref:Net::IMAP::SASL::ScramAuthenticator]. - # - # Login by username and password. The password is not sent to the - # server but is used in a salted challenge/response exchange. - # +SCRAM-SHA-1+ and +SCRAM-SHA-256+ are directly supported by - # Net::IMAP::SASL. New authenticators can easily be added for any other - # SCRAM-* mechanism if the digest algorithm is supported by - # OpenSSL::Digest. - # - # +XOAUTH2+:: - # See XOAuth2Authenticator[rdoc-ref:Net::IMAP::SASL::XOAuth2Authenticator]. - # - # Login using a username and an OAuth2 access token. Non-standard and - # obsoleted by +OAUTHBEARER+, but widely supported. - # - # See the {SASL mechanism - # registry}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] - # for a list of all SASL mechanisms and their specifications. To register - # new authenticators, see Authenticators. - # - # ===== Deprecated mechanisms - # - # Obsolete mechanisms should be avoided, but are still available for - # backwards compatibility. See Net::IMAP::SASL@Deprecated+mechanisms. - # Using a deprecated mechanism will print a warning. - # - # ==== Capabilities - # - # "AUTH=#{mechanism}" capabilities indicate server support for - # mechanisms. Use #auth_capable? or #auth_mechanisms to check for support - # before using a particular mechanism. - # - # if imap.auth_capable? "XOAUTH2" - # imap.authenticate "XOAUTH2", username, oauth2_access_token - # elsif imap.auth_capable? "PLAIN" - # imap.authenticate "PLAIN", username, password - # elsif !imap.capability? "LOGINDISABLED" - # imap.login username, password - # else - # raise "No acceptable authentication mechanism is available" - # end - # - # Although servers should list all supported \SASL mechanisms, they may - # allow authentication with an unlisted +mechanism+. - # - # If [SASL-IR[https://www.rfc-editor.org/rfc/rfc4959.html]] is supported - # and the appropriate "AUTH=#{mechanism}" capability is present, - # an "initial response" may be sent as an argument to the +AUTHENTICATE+ - # command, saving a round-trip. The SASL exchange allows for server - # challenges and client responses, but many mechanisms expect the client to - # "respond" first. The initial response will only be sent for - # "client-first" mechanisms. - # - # Server capabilities may change after #starttls, #login, and #authenticate. - # Previously cached #capabilities will be cleared when this method - # completes. If the TaggedResponse to #authenticate includes updated - # capabilities, they will be cached. - def authenticate(mechanism, *creds, - sasl_ir: config.sasl_ir, - **props, &callback) - mechanism = mechanism.to_s.tr("_", "-").upcase - authenticator = SASL.authenticator(mechanism, *creds, **props, &callback) - cmdargs = ["AUTHENTICATE", mechanism] - if sasl_ir && capable?("SASL-IR") && auth_capable?(mechanism) && - authenticator.respond_to?(:initial_response?) && - authenticator.initial_response? - response = authenticator.process(nil) - cmdargs << (response.empty? ? "=" : [response].pack("m0")) - end - result = send_command_with_continuations(*cmdargs) {|data| - challenge = data.unpack1("m") - response = authenticator.process challenge - [response].pack("m0") - } - if authenticator.respond_to?(:done?) && !authenticator.done? - logout! - raise SASL::AuthenticationIncomplete, result - end - @capabilities = capabilities_from_resp_code result - result - end - - # Sends a {LOGIN command [IMAP4rev1 §6.2.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.2.3] - # to identify the client and carries the plaintext +password+ authenticating - # this +user+. If successful, the connection enters the "_authenticated_" - # state. - # - # Using #authenticate {should be - # preferred}[https://www.rfc-editor.org/rfc/rfc9051.html#name-login-command] - # over #login. The LOGIN command is not the same as #authenticate with the - # "LOGIN" +mechanism+. - # - # A Net::IMAP::NoResponseError is raised if authentication fails. - # - # Related: #authenticate, #starttls - # - # ===== Capabilities - # - # An IMAP client MUST NOT call #login when the server advertises the - # +LOGINDISABLED+ capability. - # - # if imap.capability? "LOGINDISABLED" - # raise "Remote server has disabled the login command" - # else - # imap.login username, password - # end - # - # Server capabilities may change after #starttls, #login, and #authenticate. - # Cached capabilities _must_ be invalidated after this method completes. - # The TaggedResponse to #login may include updated capabilities in its - # ResponseCode. - # - def login(user, password) - send_command("LOGIN", user, password) - .tap { @capabilities = capabilities_from_resp_code _1 } - end - - # Sends a {SELECT command [IMAP4rev1 §6.3.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.1] - # to select a +mailbox+ so that messages in the +mailbox+ can be accessed. - # - # After you have selected a mailbox, you may retrieve the number of items in - # that mailbox from imap.responses("EXISTS", &:last), and the - # number of recent messages from imap.responses("RECENT", &:last). - # Note that these values can change if new messages arrive during a session - # or when existing messages are expunged; see #add_response_handler for a - # way to detect these events. - # - # When the +condstore+ keyword argument is true, the server is told to - # enable the extension. If +mailbox+ supports persistence of mod-sequences, - # the +HIGHESTMODSEQ+ ResponseCode will be sent as an untagged response to - # #select and all `FETCH` responses will include FetchData#modseq. - # Otherwise, the +NOMODSEQ+ ResponseCode will be sent. - # - # A Net::IMAP::NoResponseError is raised if the mailbox does not - # exist or is for some reason non-selectable. - # - # Related: #examine - # - # ===== Capabilities - # - # If [UIDPLUS[https://www.rfc-editor.org/rfc/rfc4315.html]] is supported, - # the server may return an untagged "NO" response with a "UIDNOTSTICKY" - # response code indicating that the mailstore does not support persistent - # UIDs: - # imap.responses("NO", &:last)&.code&.name == "UIDNOTSTICKY" - # - # If [CONDSTORE[https://www.rfc-editor.org/rfc/rfc7162.html]] is supported, - # the +condstore+ keyword parameter may be used. - # imap.select("mbox", condstore: true) - # modseq = imap.responses("HIGHESTMODSEQ", &:last) - def select(mailbox, condstore: false) - args = ["SELECT", mailbox] - args << ["CONDSTORE"] if condstore - synchronize do - @responses.clear - send_command(*args) - end - end - - # Sends a {EXAMINE command [IMAP4rev1 §6.3.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.2] - # to select a +mailbox+ so that messages in the +mailbox+ can be accessed. - # Behaves the same as #select, except that the selected +mailbox+ is - # identified as read-only. - # - # A Net::IMAP::NoResponseError is raised if the mailbox does not - # exist or is for some reason non-examinable. - # - # Related: #select - def examine(mailbox, condstore: false) - args = ["EXAMINE", mailbox] - args << ["CONDSTORE"] if condstore - synchronize do - @responses.clear - send_command(*args) - end - end - - # Sends a {CREATE command [IMAP4rev1 §6.3.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.3] - # to create a new +mailbox+. - # - # A Net::IMAP::NoResponseError is raised if a mailbox with that name - # cannot be created. - # - # Related: #rename, #delete - def create(mailbox) - send_command("CREATE", mailbox) - end - - # Sends a {DELETE command [IMAP4rev1 §6.3.4]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.4] - # to remove the +mailbox+. - # - # A Net::IMAP::NoResponseError is raised if a mailbox with that name - # cannot be deleted, either because it does not exist or because the - # client does not have permission to delete it. - # - # Related: #create, #rename - def delete(mailbox) - send_command("DELETE", mailbox) - end - - # Sends a {RENAME command [IMAP4rev1 §6.3.5]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.5] - # to change the name of the +mailbox+ to +newname+. - # - # A Net::IMAP::NoResponseError is raised if a mailbox with the - # name +mailbox+ cannot be renamed to +newname+ for whatever - # reason; for instance, because +mailbox+ does not exist, or - # because there is already a mailbox with the name +newname+. - # - # Related: #create, #delete - def rename(mailbox, newname) - send_command("RENAME", mailbox, newname) - end - - # Sends a {SUBSCRIBE command [IMAP4rev1 §6.3.6]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.6] - # to add the specified +mailbox+ name to the server's set of "active" or - # "subscribed" mailboxes as returned by #lsub. - # - # A Net::IMAP::NoResponseError is raised if +mailbox+ cannot be - # subscribed to; for instance, because it does not exist. - # - # Related: #unsubscribe, #lsub, #list - def subscribe(mailbox) - send_command("SUBSCRIBE", mailbox) - end - - # Sends an {UNSUBSCRIBE command [IMAP4rev1 §6.3.7]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.7] - # to remove the specified +mailbox+ name from the server's set of "active" - # or "subscribed" mailboxes. - # - # A Net::IMAP::NoResponseError is raised if +mailbox+ cannot be - # unsubscribed from; for instance, because the client is not currently - # subscribed to it. - # - # Related: #subscribe, #lsub, #list - def unsubscribe(mailbox) - send_command("UNSUBSCRIBE", mailbox) - end - - # Sends a {LIST command [IMAP4rev1 §6.3.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.8] - # and returns a subset of names from the complete set of all names available - # to the client. +refname+ provides a context (for instance, a base - # directory in a directory-based mailbox hierarchy). +mailbox+ specifies a - # mailbox or (via wildcards) mailboxes under that context. Two wildcards - # may be used in +mailbox+: "*", which matches all characters - # *including* the hierarchy delimiter (for instance, "/" on a UNIX-hosted - # directory-based mailbox hierarchy); and "%", which matches all - # characters *except* the hierarchy delimiter. - # - # If +refname+ is empty, +mailbox+ is used directly to determine - # which mailboxes to match. If +mailbox+ is empty, the root - # name of +refname+ and the hierarchy delimiter are returned. - # - # The return value is an array of MailboxList. - # - # Related: #lsub, MailboxList - # - # ===== For example: - # - # imap.create("foo/bar") - # imap.create("foo/baz") - # p imap.list("", "foo/%") - # #=> [#, \\ - # #, \\ - # #] - # - #-- - # TODO: support LIST-EXTENDED extension [RFC5258]. Needed for IMAP4rev2. - #++ - def list(refname, mailbox) - synchronize do - send_command("LIST", refname, mailbox) - clear_responses("LIST") - end - end - - # Sends a {NAMESPACE command [RFC2342 §5]}[https://www.rfc-editor.org/rfc/rfc2342#section-5] - # and returns the namespaces that are available. The NAMESPACE command - # allows a client to discover the prefixes of namespaces used by a server - # for personal mailboxes, other users' mailboxes, and shared mailboxes. - # - # The return value is a Namespaces object which has +personal+, +other+, and - # +shared+ fields, each an array of Namespace objects. These arrays will be - # empty when the server responds with +nil+. - # - # Many \IMAP servers are configured with the default personal namespaces as - # ("" "/"): no prefix and the "+/+" hierarchy delimiter. In that - # common case, the naive client may not have any trouble naming mailboxes. - # But many servers are configured with the default personal namespace as - # e.g. ("INBOX." "."), placing all personal folders under INBOX, - # with "+.+" as the hierarchy delimiter. If the client does not check for - # this, but naively assumes it can use the same folder names for all - # servers, then folder creation (and listing, moving, etc) can lead to - # errors. - # - # From RFC2342[https://tools.ietf.org/html/rfc2342]: - # >>> - # Although typically a server will support only a single Personal - # Namespace, and a single Other User's Namespace, circumstances exist - # where there MAY be multiples of these, and a client MUST be prepared - # for them. If a client is configured such that it is required to create - # a certain mailbox, there can be circumstances where it is unclear which - # Personal Namespaces it should create the mailbox in. In these - # situations a client SHOULD let the user select which namespaces to - # create the mailbox in. - # - # Related: #list, Namespaces, Namespace - # - # ===== For example: - # - # if capable?("NAMESPACE") - # namespaces = imap.namespace - # if namespace = namespaces.personal.first - # prefix = namespace.prefix # e.g. "" or "INBOX." - # delim = namespace.delim # e.g. "/" or "." - # # personal folders should use the prefix and delimiter - # imap.create(prefix + "foo") - # imap.create(prefix + "bar") - # imap.create(prefix + %w[path to my folder].join(delim)) - # end - # end - # - # ===== Capabilities - # - # The server's capabilities must include +NAMESPACE+ - # [RFC2342[https://tools.ietf.org/html/rfc2342]]. - def namespace - synchronize do - send_command("NAMESPACE") - clear_responses("NAMESPACE").last - end - end - - # Sends a XLIST command, and returns a subset of names from - # the complete set of all names available to the client. - # +refname+ provides a context (for instance, a base directory - # in a directory-based mailbox hierarchy). +mailbox+ specifies - # a mailbox or (via wildcards) mailboxes under that context. - # Two wildcards may be used in +mailbox+: '*', which matches - # all characters *including* the hierarchy delimiter (for instance, - # '/' on a UNIX-hosted directory-based mailbox hierarchy); and '%', - # which matches all characters *except* the hierarchy delimiter. - # - # If +refname+ is empty, +mailbox+ is used directly to determine - # which mailboxes to match. If +mailbox+ is empty, the root - # name of +refname+ and the hierarchy delimiter are returned. - # - # The XLIST command is like the LIST command except that the flags - # returned refer to the function of the folder/mailbox, e.g. :Sent - # - # The return value is an array of MailboxList objects. For example: - # - # imap.create("foo/bar") - # imap.create("foo/baz") - # p imap.xlist("", "foo/%") - # #=> [#, \\ - # #, \\ - # #] - # - # Related: #list, MailboxList - # - # ===== Capabilities - # - # The server's capabilities must include +XLIST+, - # a deprecated Gmail extension (replaced by +SPECIAL-USE+). - #-- - # TODO: Net::IMAP doesn't yet have full SPECIAL-USE support. Supporting - # servers MAY return SPECIAL-USE attributes, but are not *required* to - # unless the SPECIAL-USE return option is supplied. - #++ - def xlist(refname, mailbox) - synchronize do - send_command("XLIST", refname, mailbox) - clear_responses("XLIST") - end - end - - # Sends a {GETQUOTAROOT command [RFC2087 §4.3]}[https://www.rfc-editor.org/rfc/rfc2087#section-4.3] - # along with the specified +mailbox+. This command is generally available - # to both admin and user. If this mailbox exists, it returns an array - # containing objects of type MailboxQuotaRoot and MailboxQuota. - # - # Related: #getquota, #setquota, MailboxQuotaRoot, MailboxQuota - # - # ===== Capabilities - # - # The server's capabilities must include +QUOTA+ - # [RFC2087[https://tools.ietf.org/html/rfc2087]]. - def getquotaroot(mailbox) - synchronize do - send_command("GETQUOTAROOT", mailbox) - result = [] - result.concat(clear_responses("QUOTAROOT")) - result.concat(clear_responses("QUOTA")) - return result - end - end - - # Sends a {GETQUOTA command [RFC2087 §4.2]}[https://www.rfc-editor.org/rfc/rfc2087#section-4.2] - # along with specified +mailbox+. If this mailbox exists, then an array - # containing a MailboxQuota object is returned. This command is generally - # only available to server admin. - # - # Related: #getquotaroot, #setquota, MailboxQuota - # - # ===== Capabilities - # - # The server's capabilities must include +QUOTA+ - # [RFC2087[https://tools.ietf.org/html/rfc2087]]. - def getquota(mailbox) - synchronize do - send_command("GETQUOTA", mailbox) - clear_responses("QUOTA") - end - end - - # Sends a {SETQUOTA command [RFC2087 §4.1]}[https://www.rfc-editor.org/rfc/rfc2087#section-4.1] - # along with the specified +mailbox+ and +quota+. If +quota+ is nil, then - # +quota+ will be unset for that mailbox. Typically one needs to be logged - # in as a server admin for this to work. - # - # Related: #getquota, #getquotaroot - # - # ===== Capabilities - # - # The server's capabilities must include +QUOTA+ - # [RFC2087[https://tools.ietf.org/html/rfc2087]]. - def setquota(mailbox, quota) - if quota.nil? - data = '()' - else - data = '(STORAGE ' + quota.to_s + ')' - end - send_command("SETQUOTA", mailbox, RawData.new(data)) - end - - # Sends a {SETACL command [RFC4314 §3.1]}[https://www.rfc-editor.org/rfc/rfc4314#section-3.1] - # along with +mailbox+, +user+ and the +rights+ that user is to have on that - # mailbox. If +rights+ is nil, then that user will be stripped of any - # rights to that mailbox. - # - # Related: #getacl - # - # ===== Capabilities - # - # The server's capabilities must include +ACL+ - # [RFC4314[https://tools.ietf.org/html/rfc4314]]. - def setacl(mailbox, user, rights) - if rights.nil? - send_command("SETACL", mailbox, user, "") - else - send_command("SETACL", mailbox, user, rights) - end - end - - # Sends a {GETACL command [RFC4314 §3.3]}[https://www.rfc-editor.org/rfc/rfc4314#section-3.3] - # along with a specified +mailbox+. If this mailbox exists, an array - # containing objects of MailboxACLItem will be returned. - # - # Related: #setacl, MailboxACLItem - # - # ===== Capabilities - # - # The server's capabilities must include +ACL+ - # [RFC4314[https://tools.ietf.org/html/rfc4314]]. - def getacl(mailbox) - synchronize do - send_command("GETACL", mailbox) - clear_responses("ACL").last - end - end - - # Sends a {LSUB command [IMAP4rev1 §6.3.9]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.9] - # and returns a subset of names from the set of names that the user has - # declared as being "active" or "subscribed." +refname+ and +mailbox+ are - # interpreted as for #list. - # - # The return value is an array of MailboxList objects. - # - # Related: #subscribe, #unsubscribe, #list, MailboxList - def lsub(refname, mailbox) - synchronize do - send_command("LSUB", refname, mailbox) - clear_responses("LSUB") - end - end - - # Sends a {STATUS command [IMAP4rev1 §6.3.10]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.10] - # and returns the status of the indicated +mailbox+. +attr+ is a list of one - # or more attributes whose statuses are to be requested. - # - # The return value is a hash of attributes. Most status attributes return - # integer values, but some return other value types (documented below). - # - # A Net::IMAP::NoResponseError is raised if status values - # for +mailbox+ cannot be returned; for instance, because it - # does not exist. - # - # ===== Supported attributes - # - # +MESSAGES+:: The number of messages in the mailbox. - # - # +UIDNEXT+:: The next unique identifier value of the mailbox. - # - # +UIDVALIDITY+:: The unique identifier validity value of the mailbox. - # - # +UNSEEN+:: The number of messages without the \Seen flag. - # - # +DELETED+:: The number of messages with the \Deleted flag. - # - # +SIZE+:: - # The approximate size of the mailbox---must be greater than or equal to - # the sum of all messages' +RFC822.SIZE+ fetch item values. - # - # +HIGHESTMODSEQ+:: - # The highest mod-sequence value of all messages in the mailbox. See - # +CONDSTORE+ {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. - # - # +MAILBOXID+:: - # A server-allocated unique _string_ identifier for the mailbox. See - # +OBJECTID+ {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. - # - # +RECENT+:: - # The number of messages with the \Recent flag. - # _NOTE:_ +RECENT+ was removed from IMAP4rev2. - # - # Unsupported attributes may be requested. The attribute value will be - # either an Integer or an ExtensionData object. - # - # ===== For example: - # - # p imap.status("inbox", ["MESSAGES", "RECENT"]) - # #=> {"RECENT"=>0, "MESSAGES"=>44} - # - # ===== Capabilities - # - # +SIZE+ requires the server's capabilities to include either +IMAP4rev2+ or - # STATUS=SIZE - # {[RFC8483]}[https://www.rfc-editor.org/rfc/rfc8483.html]. - # - # +DELETED+ requires the server's capabilities to include +IMAP4rev2+. - # - # +HIGHESTMODSEQ+ requires the server's capabilities to include +CONDSTORE+ - # {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. - # - # +MAILBOXID+ requires the server's capabilities to include +OBJECTID+ - # {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. - def status(mailbox, attr) - synchronize do - send_command("STATUS", mailbox, attr) - clear_responses("STATUS").last&.attr - end - end - - # Sends an {APPEND command [IMAP4rev1 §6.3.11]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.11] - # to append the +message+ to the end of the +mailbox+. The optional +flags+ - # argument is an array of flags initially passed to the new message. The - # optional +date_time+ argument specifies the creation time to assign to the - # new message; it defaults to the current time. - # - # For example: - # - # imap.append("inbox", <\\Deleted - # flag set. - # - # Related: #unselect - def close - send_command("CLOSE") - end - - # Sends an {UNSELECT command [RFC3691 §2]}[https://www.rfc-editor.org/rfc/rfc3691#section-3] - # {[IMAP4rev2 §6.4.2]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.2] - # to free the session resources for a mailbox and return to the - # "_authenticated_" state. This is the same as #close, except that - # \\Deleted messages are not removed from the mailbox. - # - # Related: #close - # - # ===== Capabilities - # - # The server's capabilities must include +UNSELECT+ - # [RFC3691[https://tools.ietf.org/html/rfc3691]]. - def unselect - send_command("UNSELECT") - end - - # Sends an {EXPUNGE command [IMAP4rev1 §6.4.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.3] - # Sends a EXPUNGE command to permanently remove from the currently - # selected mailbox all messages that have the \Deleted flag set. - # - # Related: #uid_expunge - def expunge - synchronize do - send_command("EXPUNGE") - clear_responses("EXPUNGE") - end - end - - # Sends a {UID EXPUNGE command [RFC4315 §2.1]}[https://www.rfc-editor.org/rfc/rfc4315#section-2.1] - # {[IMAP4rev2 §6.4.9]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.9] - # to permanently remove all messages that have both the \\Deleted - # flag set and a UID that is included in +uid_set+. - # - # By using #uid_expunge instead of #expunge when resynchronizing with - # the server, the client can ensure that it does not inadvertantly - # remove any messages that have been marked as \\Deleted by other - # clients between the time that the client was last connected and - # the time the client resynchronizes. - # - # *Note:* - # >>> - # Although the command takes a set of UIDs for its argument, the - # server still returns regular EXPUNGE responses, which contain - # a sequence number. These will be deleted from - # #responses and this method returns them as an array of - # sequence number integers. - # - # Related: #expunge - # - # ===== Capabilities - # - # The server's capabilities must include +UIDPLUS+ - # [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]]. - def uid_expunge(uid_set) - synchronize do - send_command("UID EXPUNGE", MessageSet.new(uid_set)) - clear_responses("EXPUNGE") - end - end - - # Sends a {SEARCH command [IMAP4rev1 §6.4.4]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.4] - # to search the mailbox for messages that match the given searching - # criteria, and returns message sequence numbers. +keys+ can either be a - # string holding the entire search string, or a single-dimension array of - # search keywords and arguments. - # - # Returns a SearchResult object. SearchResult inherits from Array (for - # backward compatibility) but adds SearchResult#modseq when the +CONDSTORE+ - # capability has been enabled. - # - # Related: #uid_search - # - # ===== Search criteria - # - # For a full list of search criteria, - # see [{IMAP4rev1 §6.4.4}[https://www.rfc-editor.org/rfc/rfc3501.html#section-6.4.4]], - # or [{IMAP4rev2 §6.4.4}[https://www.rfc-editor.org/rfc/rfc9051.html#section-6.4.4]], - # in addition to documentation for - # any [CAPABILITIES[https://www.iana.org/assignments/imap-capabilities/imap-capabilities.xhtml]] - # reported by #capabilities which may define additional search filters, e.g: - # +CONDSTORE+, +WITHIN+, +FILTERS+, SEARCH=FUZZY, +OBJECTID+, or - # +SAVEDATE+. The following are some common search criteria: - # - # :: a set of message sequence numbers. "," indicates - # an interval, "+:+" indicates a range. For instance, - # "2,10:12,15" means "2,10,11,12,15". - # - # BEFORE :: messages with an internal date strictly before - # . The date argument has a format similar - # to 8-Aug-2002, and can be formatted using - # Net::IMAP.format_date. - # - # BODY :: messages that contain within their body. - # - # CC :: messages containing in their CC field. - # - # FROM :: messages that contain in their FROM field. - # - # NEW:: messages with the \Recent, but not the \Seen, flag set. - # - # NOT :: negate the following search key. - # - # OR :: "or" two search keys together. - # - # ON :: messages with an internal date exactly equal to , - # which has a format similar to 8-Aug-2002. - # - # SINCE :: messages with an internal date on or after . - # - # SUBJECT :: messages with in their subject. - # - # TO :: messages with in their TO field. - # - # ===== For example: - # - # p imap.search(["SUBJECT", "hello", "NOT", "NEW"]) - # #=> [1, 6, 7, 8] - # - # ===== Capabilities - # - # If [CONDSTORE[https://www.rfc-editor.org/rfc/rfc7162.html]] is supported - # and enabled for the selected mailbox, a non-empty SearchResult will - # include a +MODSEQ+ value. - # imap.select("mbox", condstore: true) - # result = imap.search(["SUBJECT", "hi there", "not", "new") - # #=> Net::IMAP::SearchResult[1, 6, 7, 8, modseq: 5594] - # result.modseq # => 5594 - def search(keys, charset = nil) - return search_internal("SEARCH", keys, charset) - end - - # Sends a {UID SEARCH command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] - # to search the mailbox for messages that match the given searching - # criteria, and returns unique identifiers (UIDs). - # - # Returns a SearchResult object. SearchResult inherits from Array (for - # backward compatibility) but adds SearchResult#modseq when the +CONDSTORE+ - # capability has been enabled. - # - # See #search for documentation of search criteria. - def uid_search(keys, charset = nil) - return search_internal("UID SEARCH", keys, charset) - end - - # :call-seq: - # fetch(set, attr, changedsince: nil) -> array of FetchData - # - # Sends a {FETCH command [IMAP4rev1 §6.4.5]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.5] - # to retrieve data associated with a message in the mailbox. - # - # The +set+ parameter is a number or a range between two numbers, - # or an array of those. The number is a message sequence number, - # where -1 represents a '*' for use in range notation like 100..-1 - # being interpreted as '100:*'. Beware that the +exclude_end?+ - # property of a Range object is ignored, and the contents of a - # range are independent of the order of the range endpoints as per - # the protocol specification, so 1...5, 5..1 and 5...1 are all - # equivalent to 1..5. - # - # +attr+ is a list of attributes to fetch; see the documentation - # for FetchData for a list of valid attributes. - # - # +changedsince+ is an optional integer mod-sequence. It limits results to - # messages with a mod-sequence greater than +changedsince+. - # - # The return value is an array of FetchData. - # - # Related: #uid_search, FetchData - # - # ===== For example: - # - # p imap.fetch(6..8, "UID") - # #=> [#98}>, \\ - # #99}>, \\ - # #100}>] - # p imap.fetch(6, "BODY[HEADER.FIELDS (SUBJECT)]") - # #=> [#"Subject: test\r\n\r\n"}>] - # data = imap.uid_fetch(98, ["RFC822.SIZE", "INTERNALDATE"])[0] - # p data.seqno - # #=> 6 - # p data.attr["RFC822.SIZE"] - # #=> 611 - # p data.attr["INTERNALDATE"] - # #=> "12-Oct-2000 22:40:59 +0900" - # p data.attr["UID"] - # #=> 98 - # - # ===== Capabilities - # - # Many extensions define new message +attr+ names. See FetchData for a list - # of supported extension fields. - # - # The server's capabilities must include +CONDSTORE+ - # {[RFC7162]}[https://tools.ietf.org/html/rfc7162] in order to use the - # +changedsince+ argument. Using +changedsince+ implicitly enables the - # +CONDSTORE+ extension. - def fetch(set, attr, mod = nil, changedsince: nil) - fetch_internal("FETCH", set, attr, mod, changedsince: changedsince) - end - - # :call-seq: - # uid_fetch(set, attr, changedsince: nil) -> array of FetchData - # - # Sends a {UID FETCH command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] - # to retrieve data associated with a message in the mailbox. - # - # Similar to #fetch, but the +set+ parameter contains unique identifiers - # instead of message sequence numbers. - # - # >>> - # *Note:* Servers _MUST_ implicitly include the +UID+ message data item as - # part of any +FETCH+ response caused by a +UID+ command, regardless of - # whether a +UID+ was specified as a message data item to the +FETCH+. - # - # Related: #fetch, FetchData - # - # ===== Capabilities - # Same as #fetch. - def uid_fetch(set, attr, mod = nil, changedsince: nil) - fetch_internal("UID FETCH", set, attr, mod, changedsince: changedsince) - end - - # :call-seq: - # store(set, attr, value, unchangedsince: nil) -> array of FetchData - # - # Sends a {STORE command [IMAP4rev1 §6.4.6]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.6] - # to alter data associated with messages in the mailbox, in particular their - # flags. - # - # +set+ is a number, an array of numbers, or a Range object. Each number is - # a message sequence number. - # - # +attr+ is the name of a data item to store. The semantics of +value+ - # varies based on +attr+: - # * When +attr+ is "FLAGS", the flags in +value+ replace the - # message's flag list. - # * When +attr+ is "+FLAGS", the flags in +value+ are added to - # the flags for the message. - # * When +attr+ is "-FLAGS", the flags in +value+ are removed - # from the message. - # - # +unchangedsince+ is an optional integer mod-sequence. It prohibits any - # changes to messages with +mod-sequence+ greater than the specified - # +unchangedsince+ value. A SequenceSet of any messages that fail this - # check will be returned in a +MODIFIED+ ResponseCode. - # - # The return value is an array of FetchData. - # - # Related: #uid_store - # - # ===== For example: - # - # p imap.store(6..8, "+FLAGS", [:Deleted]) - # #=> [#[:Seen, :Deleted]}>, - # #[:Seen, :Deleted]}>, - # #[:Seen, :Deleted]}>] - # - # ===== Capabilities - # - # Extensions may define new data items to be used with #store. - # - # The server's capabilities must include +CONDSTORE+ - # {[RFC7162]}[https://tools.ietf.org/html/rfc7162] in order to use the - # +unchangedsince+ argument. Using +unchangedsince+ implicitly enables the - # +CONDSTORE+ extension. - def store(set, attr, flags, unchangedsince: nil) - store_internal("STORE", set, attr, flags, unchangedsince: unchangedsince) - end - - # :call-seq: - # uid_store(set, attr, value, unchangedsince: nil) -> array of FetchData - # - # Sends a {UID STORE command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] - # to alter data associated with messages in the mailbox, in particular their - # flags. - # - # Similar to #store, but +set+ contains unique identifiers instead of - # message sequence numbers. - # - # Related: #store - # - # ===== Capabilities - # Same as #store. - def uid_store(set, attr, flags, unchangedsince: nil) - store_internal("UID STORE", set, attr, flags, unchangedsince: unchangedsince) - end - - # Sends a {COPY command [IMAP4rev1 §6.4.7]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.7] - # to copy the specified message(s) to the end of the specified destination - # +mailbox+. The +set+ parameter is a number, an array of numbers, or a - # Range object. The number is a message sequence number. - # - # Related: #uid_copy - # - # ===== Capabilities - # - # If +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]] is - # supported, the server's response should include a +COPYUID+ response code - # with UIDPlusData. This will report the UIDVALIDITY of the destination - # mailbox, the UID set of the source messages, and the assigned UID set of - # the moved messages. - def copy(set, mailbox) - copy_internal("COPY", set, mailbox) - end - - # Sends a {UID COPY command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] - # to copy the specified message(s) to the end of the specified destination - # +mailbox+. - # - # Similar to #copy, but +set+ contains unique identifiers. - # - # ===== Capabilities - # - # +UIDPLUS+ affects #uid_copy the same way it affects #copy. - def uid_copy(set, mailbox) - copy_internal("UID COPY", set, mailbox) - end - - # Sends a {MOVE command [RFC6851 §3.1]}[https://www.rfc-editor.org/rfc/rfc6851#section-3.1] - # {[IMAP4rev2 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.8] - # to move the specified message(s) to the end of the specified destination - # +mailbox+. The +set+ parameter is a number, an array of numbers, or a - # Range object. The number is a message sequence number. - # - # Related: #uid_move - # - # ===== Capabilities - # - # The server's capabilities must include +MOVE+ - # [RFC6851[https://tools.ietf.org/html/rfc6851]]. - # - # If +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]] is - # supported, the server's response should include a +COPYUID+ response code - # with UIDPlusData. This will report the UIDVALIDITY of the destination - # mailbox, the UID set of the source messages, and the assigned UID set of - # the moved messages. - # - def move(set, mailbox) - copy_internal("MOVE", set, mailbox) - end - - # Sends a {UID MOVE command [RFC6851 §3.2]}[https://www.rfc-editor.org/rfc/rfc6851#section-3.2] - # {[IMAP4rev2 §6.4.9]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.9] - # to move the specified message(s) to the end of the specified destination - # +mailbox+. - # - # Similar to #move, but +set+ contains unique identifiers. - # - # Related: #move - # - # ===== Capabilities - # - # Same as #move: The server's capabilities must include +MOVE+ - # [RFC6851[https://tools.ietf.org/html/rfc6851]]. +UIDPLUS+ also affects - # #uid_move the same way it affects #move. - def uid_move(set, mailbox) - copy_internal("UID MOVE", set, mailbox) - end - - # Sends a {SORT command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] - # to search a mailbox for messages that match +search_keys+ and return an - # array of message sequence numbers, sorted by +sort_keys+. +search_keys+ - # are interpreted the same as for #search. - # - #-- - # TODO: describe +sort_keys+ - #++ - # - # Related: #uid_sort, #search, #uid_search, #thread, #uid_thread - # - # ===== For example: - # - # p imap.sort(["FROM"], ["ALL"], "US-ASCII") - # #=> [1, 2, 3, 5, 6, 7, 8, 4, 9] - # p imap.sort(["DATE"], ["SUBJECT", "hello"], "US-ASCII") - # #=> [6, 7, 8, 1] - # - # ===== Capabilities - # - # The server's capabilities must include +SORT+ - # [RFC5256[https://tools.ietf.org/html/rfc5256]]. - def sort(sort_keys, search_keys, charset) - return sort_internal("SORT", sort_keys, search_keys, charset) - end - - # Sends a {UID SORT command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] - # to search a mailbox for messages that match +search_keys+ and return an - # array of unique identifiers, sorted by +sort_keys+. +search_keys+ are - # interpreted the same as for #search. - # - # Related: #sort, #search, #uid_search, #thread, #uid_thread - # - # ===== Capabilities - # - # The server's capabilities must include +SORT+ - # [RFC5256[https://tools.ietf.org/html/rfc5256]]. - def uid_sort(sort_keys, search_keys, charset) - return sort_internal("UID SORT", sort_keys, search_keys, charset) - end - - # Sends a {THREAD command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] - # to search a mailbox and return message sequence numbers in threaded - # format, as a ThreadMember tree. +search_keys+ are interpreted the same as - # for #search. - # - # The supported algorithms are: - # - # ORDEREDSUBJECT:: split into single-level threads according to subject, - # ordered by date. - # REFERENCES:: split into threads by parent/child relationships determined - # by which message is a reply to which. - # - # Unlike #search, +charset+ is a required argument. US-ASCII - # and UTF-8 are sample values. - # - # Related: #uid_thread, #search, #uid_search, #sort, #uid_sort - # - # ===== Capabilities - # - # The server's capabilities must include +THREAD+ - # [RFC5256[https://tools.ietf.org/html/rfc5256]]. - def thread(algorithm, search_keys, charset) - return thread_internal("THREAD", algorithm, search_keys, charset) - end - - # Sends a {UID THREAD command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] - # Similar to #thread, but returns unique identifiers instead of - # message sequence numbers. - # - # Related: #thread, #search, #uid_search, #sort, #uid_sort - # - # ===== Capabilities - # - # The server's capabilities must include +THREAD+ - # [RFC5256[https://tools.ietf.org/html/rfc5256]]. - def uid_thread(algorithm, search_keys, charset) - return thread_internal("UID THREAD", algorithm, search_keys, charset) - end - - # Sends an {ENABLE command [RFC5161 §3.2]}[https://www.rfc-editor.org/rfc/rfc5161#section-3.1] - # {[IMAP4rev2 §6.3.1]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.3.1] - # to enable the specified server +capabilities+. Each capability may be an - # array, string, or symbol. Returns a list of the capabilities that were - # enabled. - # - # The +ENABLE+ command is only valid in the _authenticated_ state, before - # any mailbox is selected. - # - # Related: #capable?, #capabilities, #capability - # - # ===== Capabilities - # - # The server's capabilities must include - # +ENABLE+ [RFC5161[https://tools.ietf.org/html/rfc5161]] - # or +IMAP4REV2+ [RFC9051[https://tools.ietf.org/html/rfc9051]]. - # - # Additionally, the server capabilities must include a capability matching - # each enabled extension (usually the same name as the enabled extension). - # The following capabilities may be enabled: - # - # [+CONDSTORE+ {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]] - # - # Updates various commands to return +CONDSTORE+ extension responses. It - # is not necessary to explicitly enable +CONDSTORE+—using any of the - # command parameters defined by the extension will implicitly enable it. - # See {[RFC7162 §3.1]}[https://www.rfc-editor.org/rfc/rfc7162.html#section-3.1]. - # - # [+:utf8+ --- an alias for "UTF8=ACCEPT"] - # - # In a future release, enable(:utf8) will enable either - # "UTF8=ACCEPT" or "IMAP4rev2", depending on server - # capabilities. - # - # ["UTF8=ACCEPT" [RFC6855[https://tools.ietf.org/html/rfc6855]]] - # - # The server's capabilities must include UTF8=ACCEPT _or_ - # UTF8=ONLY. - # - # This allows the server to send strings encoded as UTF-8 which might - # otherwise need to use a 7-bit encoding, such as {modified - # UTF-7}[::decode_utf7] for mailbox names, or RFC2047 encoded-words for - # message headers. - # - # *Note:* A future update may set string encodings slightly - # differently, e.g: "US-ASCII" when UTF-8 is not enabled, and "UTF-8" - # when it is. Currently, the encoding of strings sent as "quoted" or - # "text" will _always_ be "UTF-8", even when only ASCII characters are - # used (e.g. "Subject: Agenda") And currently, string "literals" sent - # by the server will always have an "ASCII-8BIT" (binary) - # encoding, even if they generally contain UTF-8 data, if they are - # text at all. - # - # ["UTF8=ONLY" [RFC6855[https://tools.ietf.org/html/rfc6855]]] - # - # A server that reports the UTF8=ONLY capability _requires_ that - # the client enable("UTF8=ACCEPT") before any mailboxes may be - # selected. For convenience, enable("UTF8=ONLY") is aliased to - # enable("UTF8=ACCEPT"). - # - # ===== Unsupported capabilities - # - # *Note:* Some extensions that use ENABLE permit the server to send syntax - # that Net::IMAP cannot parse, which may raise an exception and disconnect. - # Some extensions may work, but the support may be incomplete, untested, or - # experimental. - # - # Until a capability is documented here as supported, enabling it may result - # in undocumented behavior and a future release may update with incompatible - # behavior without warning or deprecation. - # - # Caution is advised. - # - def enable(*capabilities) - capabilities = capabilities - .flatten - .map {|e| ENABLE_ALIASES[e] || e } - .uniq - .join(' ') - synchronize do - send_command("ENABLE #{capabilities}") - result = clear_responses("ENABLED").last || [] - @utf8_strings ||= result.include? "UTF8=ACCEPT" - @utf8_strings ||= result.include? "IMAP4REV2" - result - end - end - - # Sends an {IDLE command [RFC2177 §3]}[https://www.rfc-editor.org/rfc/rfc6851#section-3] - # {[IMAP4rev2 §6.3.13]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.3.13] - # that waits for notifications of new or expunged messages. Yields - # responses from the server during the IDLE. - # - # Use #idle_done to leave IDLE. - # - # If +timeout+ is given, this method returns after +timeout+ seconds passed. - # +timeout+ can be used for keep-alive. For example, the following code - # checks the connection for each 60 seconds. - # - # loop do - # imap.idle(60) do |response| - # do_something_with(response) - # imap.idle_done if some_condition?(response) - # end - # end - # - # Returns the server's response to indicate the IDLE state has ended. - # Returns +nil+ if the server does not respond to #idle_done within - # {config.idle_response_timeout}[rdoc-ref:Config#idle_response_timeout] - # seconds. - # - # Related: #idle_done, #noop, #check - # - # ===== Capabilities - # - # The server's capabilities must include +IDLE+ - # [RFC2177[https://tools.ietf.org/html/rfc2177]]. - def idle(timeout = nil, &response_handler) - raise LocalJumpError, "no block given" unless response_handler - - response = nil - - synchronize do - tag = Thread.current[:net_imap_tag] = generate_tag - put_string("#{tag} IDLE#{CRLF}") - - begin - add_response_handler(&response_handler) - @idle_done_cond = new_cond - @idle_done_cond.wait(timeout) - @idle_done_cond = nil - if @receiver_thread_terminating - raise @exception || Net::IMAP::Error.new("connection closed") - end - ensure - unless @receiver_thread_terminating - remove_response_handler(response_handler) - put_string("DONE#{CRLF}") - response = get_tagged_response(tag, "IDLE", idle_response_timeout) - end - end - end - - return response - end - - # Leaves IDLE, allowing #idle to return. - # - # If the server does not respond within - # {config.idle_response_timeout}[rdoc-ref:Config#idle_response_timeout] - # seconds, #idle will return +nil+. - # - # Related: #idle - def idle_done - synchronize do - if @idle_done_cond.nil? - raise Net::IMAP::Error, "not during IDLE" - end - @idle_done_cond.signal - end - end - - RESPONSES_DEPRECATION_MSG = - "Pass a type or block to #responses, " \ - "set config.responses_without_block to :frozen_dup " \ - "or :silence_deprecation_warning, " \ - "or use #extract_responses or #clear_responses." - private_constant :RESPONSES_DEPRECATION_MSG - - # :call-seq: - # responses -> hash of {String => Array} (see config.responses_without_block) - # responses(type) -> frozen array - # responses {|hash| ...} -> block result - # responses(type) {|array| ...} -> block result - # - # Yields or returns unhandled server responses. Unhandled responses are - # stored in a hash, with arrays of UntaggedResponse#data keyed by - # UntaggedResponse#name and non-+nil+ untagged ResponseCode#data - # keyed by ResponseCode#name. - # - # When a block is given, yields unhandled responses and returns the block's - # result. Without a block, returns the unhandled responses. - # - # [With +type+] - # Yield or return only the array of responses for that +type+. - # When no block is given, the returned array is a frozen copy. - # [Without +type+] - # Yield or return the entire responses hash. - # - # When no block is given, the behavior is determined by - # Config#responses_without_block: - # >>> - # [+:silence_deprecation_warning+ (original behavior)] - # Returns the mutable responses hash (without any warnings). - # This is not thread-safe. - # - # [+:warn+ (default since +v0.5+)] - # Prints a warning and returns the mutable responses hash. - # This is not thread-safe. - # - # [+:frozen_dup+ (planned default for +v0.6+)] - # Returns a frozen copy of the unhandled responses hash, with frozen - # array values. - # - # [+:raise+] - # Raise an +ArgumentError+ with the deprecation warning. - # - # For example: - # - # imap.select("inbox") - # p imap.responses("EXISTS").last - # #=> 2 - # p imap.responses("UIDNEXT", &:last) - # #=> 123456 - # p imap.responses("UIDVALIDITY", &:last) - # #=> 968263756 - # p imap.responses {|responses| - # { - # exists: responses.delete("EXISTS").last, - # uidnext: responses.delete("UIDNEXT").last, - # uidvalidity: responses.delete("UIDVALIDITY").last, - # } - # } - # #=> {:exists=>2, :uidnext=>123456, :uidvalidity=>968263756} - # # "EXISTS", "UIDNEXT", and "UIDVALIDITY" have been removed: - # p imap.responses(&:keys) - # #=> ["FLAGS", "OK", "PERMANENTFLAGS", "RECENT", "HIGHESTMODSEQ"] - # - # Related: #extract_responses, #clear_responses, #response_handlers, #greeting - # - # ===== Thread safety - # >>> - # *Note:* Access to the responses hash is synchronized for thread-safety. - # The receiver thread and response_handlers cannot process new responses - # until the block completes. Accessing either the response hash or its - # response type arrays outside of the block is unsafe. They can be safely - # updated inside the block. Consider using #clear_responses or - # #extract_responses instead. - # - # Net::IMAP will add and remove responses from the responses hash and its - # array values, in the calling threads for commands and in the receiver - # thread, but will not modify any responses after adding them to the - # responses hash. - # - # ===== Clearing responses - # - # Previously unhandled responses are automatically cleared before entering a - # mailbox with #select or #examine. Long-lived connections can receive many - # unhandled server responses, which must be pruned or they will continually - # consume more memory. Update or clear the responses hash or arrays inside - # the block, or remove responses with #extract_responses, #clear_responses, - # or #add_response_handler. - # - # ===== Missing responses - # - # Only non-+nil+ data is stored. Many important response codes have no data - # of their own, but are used as "tags" on the ResponseText object they are - # attached to. ResponseText will be accessible by its response types: - # "+OK+", "+NO+", "+BAD+", "+BYE+", or "+PREAUTH+". - # - # TaggedResponse#data is not saved to #responses, nor is any - # ResponseCode#data on tagged responses. Although some command methods do - # return the TaggedResponse directly, #add_response_handler must be used to - # handle all response codes. - def responses(type = nil) - if block_given? - synchronize { yield(type ? @responses[type.to_s.upcase] : @responses) } - elsif type - synchronize { @responses[type.to_s.upcase].dup.freeze } - else - case config.responses_without_block - when :raise - raise ArgumentError, RESPONSES_DEPRECATION_MSG - when :warn - warn(RESPONSES_DEPRECATION_MSG, uplevel: 1) - when :frozen_dup - synchronize { - responses = @responses.transform_values(&:freeze) - responses.default_proc = nil - responses.default = [].freeze - return responses.freeze - } - end - @responses - end - end - - # :call-seq: - # clear_responses -> hash - # clear_responses(type) -> array - # - # Clears and returns the unhandled #responses hash or the unhandled - # responses array for a single response +type+. - # - # Clearing responses is synchronized with other threads. The lock is - # released before returning. - # - # Related: #extract_responses, #responses, #response_handlers - def clear_responses(type = nil) - synchronize { - if type - @responses.delete(type) || [] - else - @responses.dup.transform_values(&:freeze) - .tap { _1.default = [].freeze } - .tap { @responses.clear } - end - } - .freeze - end - - # :call-seq: - # extract_responses(type) {|response| ... } -> array - # - # Yields all of the unhandled #responses for a single response +type+. - # Removes and returns the responses for which the block returns a true - # value. - # - # Extracting responses is synchronized with other threads. The lock is - # released before returning. - # - # Related: #responses, #clear_responses - def extract_responses(type) - type = String.try_convert(type) or - raise ArgumentError, "type must be a string" - raise ArgumentError, "must provide a block" unless block_given? - extracted = [] - responses(type) do |all| - all.reject! do |response| - extracted << response if yield response - end - end - extracted - end - - # Returns all response handlers, including those that are added internally - # by commands. Each response handler will be called with every new - # UntaggedResponse, TaggedResponse, and ContinuationRequest. - # - # Response handlers are called with a mutex inside the receiver thread. New - # responses cannot be processed and commands from other threads must wait - # until all response_handlers return. An exception will shut-down the - # receiver thread and close the connection. - # - # For thread-safety, the returned array is a frozen copy of the internal - # array. - # - # Related: #add_response_handler, #remove_response_handler - def response_handlers - synchronize { @response_handlers.clone.freeze } - end - - # Adds a response handler. For example, to detect when - # the server sends a new EXISTS response (which normally - # indicates new messages being added to the mailbox), - # add the following handler after selecting the - # mailbox: - # - # imap.add_response_handler { |resp| - # if resp.kind_of?(Net::IMAP::UntaggedResponse) and resp.name == "EXISTS" - # puts "Mailbox now has #{resp.data} messages" - # end - # } - # - # Related: #remove_response_handler, #response_handlers - def add_response_handler(handler = nil, &block) - raise ArgumentError, "two Procs are passed" if handler && block - synchronize do - @response_handlers.push(block || handler) - end - end - - # Removes the response handler. - # - # Related: #add_response_handler, #response_handlers - def remove_response_handler(handler) - synchronize do - @response_handlers.delete(handler) - end - end - - private - - CRLF = "\r\n" # :nodoc: - PORT = 143 # :nodoc: - SSL_PORT = 993 # :nodoc: - - def start_imap_connection - @greeting = get_server_greeting - @capabilities = capabilities_from_resp_code @greeting - @receiver_thread = start_receiver_thread - rescue Exception - @sock.close - raise - end - - def get_server_greeting - greeting = get_response - raise Error, "No server greeting - connection closed" unless greeting - record_untagged_response_code greeting - raise ByeResponseError, greeting if greeting.name == "BYE" - greeting - end - - def start_receiver_thread - Thread.start do - receive_responses - rescue Exception => ex - @receiver_thread_exception = ex - # don't exit the thread with an exception - end - end - - def tcp_socket(host, port) - s = Socket.tcp(host, port, :connect_timeout => open_timeout) - s.setsockopt(:SOL_SOCKET, :SO_KEEPALIVE, true) - s - rescue Errno::ETIMEDOUT - raise Net::OpenTimeout, "Timeout to open TCP connection to " + - "#{host}:#{port} (exceeds #{open_timeout} seconds)" - end - - def receive_responses - connection_closed = false - until connection_closed - synchronize do - @exception = nil - end - begin - resp = get_response - rescue Exception => e - synchronize do - @sock.close - @exception = e - end - break - end - unless resp - synchronize do - @exception = EOFError.new("end of file reached") - end - break - end - begin - synchronize do - case resp - when TaggedResponse - @tagged_responses[resp.tag] = resp - @tagged_response_arrival.broadcast - case resp.tag - when @logout_command_tag - return - when @continued_command_tag - @continuation_request_exception = - RESPONSE_ERRORS[resp.name].new(resp) - @continuation_request_arrival.signal - end - when UntaggedResponse - record_untagged_response(resp) - if resp.name == "BYE" && @logout_command_tag.nil? - @sock.close - @exception = ByeResponseError.new(resp) - connection_closed = true - end - when ContinuationRequest - @continuation_request_arrival.signal - end - @response_handlers.each do |handler| - handler.call(resp) - end - end - rescue Exception => e - @exception = e - synchronize do - @tagged_response_arrival.broadcast - @continuation_request_arrival.broadcast - end - end - end - synchronize do - @receiver_thread_terminating = true - @tagged_response_arrival.broadcast - @continuation_request_arrival.broadcast - if @idle_done_cond - @idle_done_cond.signal - end - end - end - - def get_tagged_response(tag, cmd, timeout = nil) - if timeout - deadline = Time.now + timeout - end - until @tagged_responses.key?(tag) - raise @exception if @exception - if timeout - timeout = deadline - Time.now - if timeout <= 0 - return nil - end - end - @tagged_response_arrival.wait(timeout) - end - resp = @tagged_responses.delete(tag) - case resp.name - when /\A(?:OK)\z/ni - return resp - when /\A(?:NO)\z/ni - raise NoResponseError, resp - when /\A(?:BAD)\z/ni - raise BadResponseError, resp - else - disconnect - raise InvalidResponseError, "invalid tagged resp: %p" % [resp.raw.chomp] - end - end - - def get_response - buff = String.new - while true - s = @sock.gets(CRLF) - break unless s - buff.concat(s) - if /\{(\d+)\}\r\n/n =~ s - s = @sock.read($1.to_i) - buff.concat(s) - else - break - end - end - return nil if buff.length == 0 - if config.debug? - $stderr.print(buff.gsub(/^/n, "S: ")) - end - return @parser.parse(buff) - end - - ############################# - # built-in response handlers - - # store name => [..., data] - def record_untagged_response(resp) - @responses[resp.name] << resp.data - record_untagged_response_code resp - end - - # store code.name => [..., code.data] - def record_untagged_response_code(resp) - return unless resp.data.is_a?(ResponseText) - return unless (code = resp.data.code) - @responses[code.name] << code.data - end - - # NOTE: only call this for greeting, login, and authenticate - def capabilities_from_resp_code(resp) - return unless %w[PREAUTH OK].any? { _1.casecmp? resp.name } - return unless (code = resp.data.code) - return unless code.name.casecmp?("CAPABILITY") - code.data.freeze - end - - ############################# - - # Calls send_command, yielding the text of each ContinuationRequest and - # responding with each block result. Returns TaggedResponse. Raises - # NoResponseError or BadResponseError. - def send_command_with_continuations(cmd, *args) - send_command(cmd, *args) do |server_response| - if server_response.instance_of?(ContinuationRequest) - client_response = yield server_response.data.text - put_string(client_response + CRLF) - end - end - end - - def send_command(cmd, *args, &block) - synchronize do - args.each do |i| - validate_data(i) - end - tag = generate_tag - put_string(tag + " " + cmd) - args.each do |i| - put_string(" ") - send_data(i, tag) - end - put_string(CRLF) - if cmd == "LOGOUT" - @logout_command_tag = tag - end - if block - add_response_handler(&block) - end - begin - return get_tagged_response(tag, cmd) - ensure - if block - remove_response_handler(block) - end - end - end - end - - def generate_tag - @tagno += 1 - return format("%s%04d", @tag_prefix, @tagno) - end - - def put_string(str) - @sock.print(str) - if config.debug? - if @debug_output_bol - $stderr.print("C: ") - end - $stderr.print(str.gsub(/\n/n) { $'.empty? ? $& : "\nC: " }) - if /\n\z/n.match(str) - @debug_output_bol = true - else - @debug_output_bol = false - end - end - end - - def search_internal(cmd, keys, charset) - if keys.instance_of?(String) - keys = [RawData.new(keys)] - else - normalize_searching_criteria(keys) - end - synchronize do - if charset - send_command(cmd, "CHARSET", charset, *keys) - else - send_command(cmd, *keys) - end - clear_responses("SEARCH").last || [] - end - end - - def fetch_internal(cmd, set, attr, mod = nil, changedsince: nil) - if changedsince - mod ||= [] - mod << "CHANGEDSINCE" << Integer(changedsince) - end - case attr - when String then - attr = RawData.new(attr) - when Array then - attr = attr.map { |arg| - arg.is_a?(String) ? RawData.new(arg) : arg - } - end - - synchronize do - clear_responses("FETCH") - if mod - send_command(cmd, MessageSet.new(set), attr, mod) - else - send_command(cmd, MessageSet.new(set), attr) - end - clear_responses("FETCH") - end - end - - def store_internal(cmd, set, attr, flags, unchangedsince: nil) - attr = RawData.new(attr) if attr.instance_of?(String) - args = [MessageSet.new(set)] - args << ["UNCHANGEDSINCE", Integer(unchangedsince)] if unchangedsince - args << attr << flags - synchronize do - clear_responses("FETCH") - send_command(cmd, *args) - clear_responses("FETCH") - end - end - - def copy_internal(cmd, set, mailbox) - send_command(cmd, MessageSet.new(set), mailbox) - end - - def sort_internal(cmd, sort_keys, search_keys, charset) - if search_keys.instance_of?(String) - search_keys = [RawData.new(search_keys)] - else - normalize_searching_criteria(search_keys) - end - synchronize do - send_command(cmd, sort_keys, charset, *search_keys) - clear_responses("SORT").last || [] - end - end - - def thread_internal(cmd, algorithm, search_keys, charset) - if search_keys.instance_of?(String) - search_keys = [RawData.new(search_keys)] - else - normalize_searching_criteria(search_keys) - end - synchronize do - send_command(cmd, algorithm, charset, *search_keys) - clear_responses("THREAD").last || [] - end - end - - def normalize_searching_criteria(keys) - keys.collect! do |i| - case i - when -1, Range, Array - MessageSet.new(i) - else - i - end - end - end - - def build_ssl_ctx(ssl) - if ssl - params = (Hash.try_convert(ssl) || {}).freeze - context = SSLContext.new - context.set_params(params) - if defined?(VerifyCallbackProc) - context.verify_callback = VerifyCallbackProc - end - context.freeze - [params, context] - else - false - end - end - - def start_tls_session - raise "SSL extension not installed" unless defined?(OpenSSL::SSL) - raise "already using SSL" if @sock.kind_of?(OpenSSL::SSL::SSLSocket) - raise "cannot start TLS without SSLContext" unless ssl_ctx - @sock = SSLSocket.new(@sock, ssl_ctx) - @sock.sync_close = true - @sock.hostname = @host if @sock.respond_to? :hostname= - ssl_socket_connect(@sock, open_timeout) - if ssl_ctx.verify_mode != VERIFY_NONE - @sock.post_connection_check(@host) - @tls_verified = true - end - end - - def sasl_adapter - SASLAdapter.new(self, &method(:send_command_with_continuations)) - end - - #-- - # We could get the saslprep method by extending the SASLprep module - # directly. It's done indirectly, so SASLprep can be lazily autoloaded, - # because most users won't need it. - #++ - # Delegates to Net::IMAP::StringPrep::SASLprep#saslprep. - def self.saslprep(string, **opts) - Net::IMAP::StringPrep::SASLprep.saslprep(string, **opts) - end - - end -end - -require_relative "imap/errors" -require_relative "imap/config" -require_relative "imap/command_data" -require_relative "imap/data_encoding" -require_relative "imap/flags" -require_relative "imap/response_data" -require_relative "imap/response_parser" -require_relative "imap/authenticators" - -require_relative "imap/deprecated_client_options" -Net::IMAP.prepend Net::IMAP::DeprecatedClientOptions diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/net-imap.gemspec ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/net-imap.gemspec --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/net-imap.gemspec 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/net-imap.gemspec 1970-01-01 00:00:00.000000000 +0000 @@ -1,38 +0,0 @@ -# frozen_string_literal: true - -name = File.basename(__FILE__, ".gemspec") -version = ["lib", Array.new(name.count("-"), "..").join("/")].find do |dir| - break File.foreach(File.join(__dir__, dir, "#{name.tr('-', '/')}.rb"), :encoding=> 'utf-8') do |line| - /^\s*VERSION\s*=\s*"(.*)"/ =~ line and break $1 - end rescue nil -end - -Gem::Specification.new do |spec| - spec.name = name - spec.version = version - spec.authors = ["Shugo Maeda", "nicholas a. evans"] - spec.email = ["shugo@ruby-lang.org", "nick@rubinick.dev"] - - spec.summary = %q{Ruby client api for Internet Message Access Protocol} - spec.description = %q{Ruby client api for Internet Message Access Protocol} - spec.homepage = "https://github.com/ruby/net-imap" - spec.required_ruby_version = Gem::Requirement.new(">= 2.7.3") - spec.licenses = ["Ruby", "BSD-2-Clause"] - - spec.metadata["homepage_uri"] = spec.homepage - spec.metadata["source_code_uri"] = spec.homepage - spec.metadata["changelog_uri"] = spec.homepage + "/releases" - - # Specify which files should be added to the gem when it is released. - # The `git ls-files -z` loads the files in the RubyGem that have been added into git. - spec.files = Dir.chdir(__dir__) do - `git ls-files -z 2>/dev/null`.split("\x0") - .grep_v(%r{^(\.git(ignore)?|\.mailmap|(\.github|bin|test|spec|benchmarks|features|rfcs)/)}) - end - spec.bindir = "exe" - spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) } - spec.require_paths = ["lib"] - - spec.add_dependency "net-protocol" - spec.add_dependency "date" -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/rakelib/benchmarks.rake ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/rakelib/benchmarks.rake --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/rakelib/benchmarks.rake 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/rakelib/benchmarks.rake 1970-01-01 00:00:00.000000000 +0000 @@ -1,91 +0,0 @@ -# frozen_string_literal: true - -PARSER_TEST_FIXTURES = FileList.new "test/net/imap/fixtures/response_parser/*.yml" -CLOBBER.include "benchmarks/parser.yml" -CLEAN.include "benchmarks/Gemfile-*" - -BENCHMARK_INIT = < PARSER_TEST_FIXTURES do |t| - require "yaml" - require "pathname" - require "net/imap" - - path = Pathname.new(__dir__) / "../test/net/imap/fixtures/response_parser" - files = path.glob("*.yml") - tests = files.flat_map {|file| - file.read - .gsub(%r{([-:]) !ruby/(object|struct|array):\S+}) { $1 } - .then { - YAML.safe_load(_1, filename: file, - permitted_classes: [Symbol, Regexp], aliases: true) - } - .fetch(:tests) - .select {|test_name, test| - :parser_assert_equal == test.fetch(:test_type) { - test.key?(:expected) ? :parser_assert_equal : :parser_pending - } - } - .map {|test_name, test| [test_name.to_s, test.fetch(:response)] } - } - - benchmarks = tests.map {|fixture_name, response| - {"name" => fixture_name.delete_prefix("test_"), - "prelude" => "response = -%s.b" % [response.dump], - "script" => "parser.parse(response)"} - } - .sort_by { _1["name"] } - - YAML.dump({"prelude" => BENCHMARK_INIT, "benchmark" => benchmarks}) - .then { File.write t.name, _1 } -end - -namespace :benchmarks do - desc "Generate benchmarks from fixture data" - task :generate => "benchmarks/parser.yml" - - desc "run the parser benchmarks comparing multiple gem versions" - task :compare => :generate do |task, args| - cd Pathname.new(__dir__) + ".." - current = `git describe --tags --dirty`.chomp - current = "dev" if current.empty? - versions = args.to_a - if versions.empty? - latest = %x{git describe --tags --abbrev=0 --match 'v*.*.*'}.chomp - versions = latest.empty? ? [] : [latest.delete_prefix("v")] - end - versions = versions.to_h { [_1, "Gemfile-v#{_1}"] } - cd "benchmarks" do - versions.each do |version, gemfile| - File.write gemfile, <<~RUBY - # frozen_string_literal: true - source "https://rubygems.org" - gem "net-imap", #{version.dump} - RUBY - end - versions = {current => "../Gemfile" , **versions}.map { - "%s::/usr/bin/env BUNDLE_GEMFILE=%s ruby" % _1 - }.join(";") - - extra = ENV.fetch("BENCHMARK_ARGS", "").shellsplit - - sh("benchmark-driver", - "--bundler", - "-e", versions, - "parser.yml", - *extra) - end - end - -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/rakelib/rdoc.rake ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/rakelib/rdoc.rake --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/rakelib/rdoc.rake 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/rakelib/rdoc.rake 1970-01-01 00:00:00.000000000 +0000 @@ -1,70 +0,0 @@ -# require "sdoc" -require "rdoc/task" -require_relative "../lib/net/imap" -require 'rdoc/rdoc' unless defined?(RDoc::Markup::ToHtml) - -module RDoc::Generator - module NetIMAP - - module RemoveRedundantParens - def param_seq - super.sub(/^\(\)\s*/, "") - end - end - - # See https://github.com/ruby/rdoc/pull/936 - module FixSectionComments - def markup(text) - @store ||= @parent&.store - super - end - def description; markup comment end - def comment; super || @comments&.first end - def parse(_comment_location = nil) super() end - end - - # render "[label] data" lists as tables. adapted from "hanna-nouveau" gem. - module LabelListTable - def list_item_start(list_item, list_type) - case list_type - when :NOTE - %(#{Array(list_item.label).map{|label| to_html(label)}.join("
")}) - else - super - end - end - - def list_end_for(list_type) - case list_type - when :NOTE then - "" - else - super - end - end - end - - end -end - -class RDoc::AnyMethod - prepend RDoc::Generator::NetIMAP::RemoveRedundantParens -end - -class RDoc::Context::Section - prepend RDoc::Generator::NetIMAP::FixSectionComments -end - -class RDoc::Markup::ToHtml - LIST_TYPE_TO_HTML[:NOTE] = ['', '
'] - prepend RDoc::Generator::NetIMAP::LabelListTable -end - -RDoc::Task.new do |doc| - doc.main = "README.md" - doc.title = "net-imap #{Net::IMAP::VERSION}" - doc.rdoc_dir = "doc" - doc.rdoc_files = FileList.new %w[lib/**/*.rb *.rdoc *.md] - doc.options << "--template-stylesheets" << "docs/styles.css" - # doc.generator = "hanna" -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/rakelib/rfcs.rake ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/rakelib/rfcs.rake --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/rakelib/rfcs.rake 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/rakelib/rfcs.rake 1970-01-01 00:00:00.000000000 +0000 @@ -1,168 +0,0 @@ -# frozen_string_literal: true - -RFCS = { - - # Historic IMAP RFCs - 822 => "Internet Message Format (OBSOLETE)", - 1730 => "IMAP4 (OBSOLETE)", - 1731 => "IMAP4 Authentication Mechanisms (OBSOLETE)", - 2060 => "IMAP4rev1 (OBSOLETE)", - 2061 => "IMAP4 Compatibility with IMAP2bis", - 2062 => "Internet Message Access Protocol - Obsolete Syntax", - 2086 => "IMAP ACL (OBSOLETE)", - 2087 => "IMAP QUOTA (OBSOLETE)", - 2088 => "IMAP LITERAL+ (OBSOLETE)", - 2095 => "IMAP/POP AUTHorize Extension for CRAM-MD5 (OBSOLETE)", - 2192 => "IMAP URL Scheme (OBSOLETE)", - 2222 => "SASL (OBSOLETE)", - 2359 => "IMAP UIDPLUS (OBSOLETE)", - 2822 => "Internet Message Format (OBSOLETE)", - 3348 => "IMAP CHILDREN (OBSOLETED)", - 4551 => "IMAP CONDSTORE (OBSOLETE)", - 5162 => "IMAP QRESYNC (OBSOLETE)", - 6237 => "IMAP MULTISEARCH (OBSOLETE)", - - # Core IMAP RFCs - 3501 => "IMAP4rev1", # supported by nearly all email servers - 4466 => "Collected Extensions to IMAP4 ABNF", - 9051 => "IMAP4rev2", # not widely supported yet - - # RFC-9051 Normative References (not a complete list) - 2152 => "UTF-7", - 2180 => "IMAP4 Multi-Accessed Mailbox Practice", - 2683 => "IMAP4 Implementation Recommendations", - 3503 => "Message Disposition Notification (MDN) profile IMAP", - 5234 => "ABNF", - 5788 => "IMAP4 keyword registry", - - # Internet Message format and envelope and body structure - 5322 => "Internet Message Format (current)", - - 1864 => "[MD5]: The Content-MD5 Header Field", - 2045 => "[MIME-IMB]: MIME Part One: Format of Internet Message Bodies", - 2046 => "[MIME-IMT]: MIME Part Two: Media Types", - 2047 => "[MIME-HDRS]: MIME Part Three: Header Extensions for Non-ASCII Text", - 2183 => "[DISPOSITION]: The Content-Disposition Header", - 2231 => "MIME Parameter Value and Encoded Word Extensions: " \ - "Character Sets, Languages, and Continuations", - 2557 => "[LOCATION]: MIME Encapsulation of Aggregate Documents", - 2978 => "[CHARSET]: IANA Charset Registration Procedures, BCP 19", - 3282 => "[LANGUAGE-TAGS]: Content Language Headers", - 6532 => "[I18N-HDRS]: Internationalized Email Headers", - - # SASL - 4422 => "SASL, EXTERNAL", - - # stringprep - 3454 => "stringprep", - 4013 => "SASLprep", - 8265 => "PRECIS", # obsoletes SASLprep? - - # SASL mechanisms (not a complete list) - 2195 => "SASL CRAM-MD5", - 4505 => "SASL ANONYMOUS", - 4616 => "SASL PLAIN", - 4752 => "SASL GSSAPI (Kerberos V5)", - 5801 => "SASL GS2-*, GS2-KRB5", - 5802 => "SASL SCRAM-*, SCRAM-SHA-1, SCRAM-SHA1-PLUS", - 5803 => "LDAP Schema for Storing SCRAM Secrets", - 6331 => "SASL DIGEST-MD5", - 6595 => "SASL SAML20", - 6616 => "SASL OPENID20", - 7628 => "SASL OAUTH10A, OAUTHBEARER", - 7677 => "SASL SCRAM-SHA-256, SCRAM-SHA256-PLUS", - - # "Informational" RFCs - 1733 => "Distributed E-Mail Models in IMAP4", - 4549 => "Synchronization Operations for Disconnected IMAP4 Clients", - - # TLS and other security concerns - 2595 => "Using TLS with IMAP, POP3 and ACAP", - 6151 => "Updated Security Considerations for MD5 Message-Digest and HMAC-MD5", - 7525 => "Recommendations for Secure Use of TLS and DTLS", - 7818 => "Updated TLS Server Identity Check Procedure for Email Protocols", - 8314 => "Cleartext Considered Obsolete: Use of TLS for Email", - 8996 => "Deprecating TLS 1.0 and TLS 1.1,", - - # related email specifications - 6376 => "DomainKeys Identified Mail (DKIM) Signatures", - 6409 => "Message Submission for Mail", - - # Other IMAP4 "Standards Track" RFCs - 5092 => "IMAP URL Scheme", - 5593 => "IMAP URL Access Identifier Extension", - 5530 => "IMAP Response Codes", - 6186 => "Use of SRV Records for Locating Email Submission/Access Services", - 8305 => "Happy Eyeballs Version 2: Better Connectivity Using Concurrency", - - # IMAP4 Extensions - 2177 => "IMAP IDLE", - 2193 => "IMAP MAILBOX-REFERRALS", - 2221 => "IMAP LOGIN-REFERRALS", - 2342 => "IMAP NAMESPACE", - 2971 => "IMAP ID", - 3502 => "IMAP MULTIAPPEND", - 3516 => "IMAP BINARY", - 3691 => "IMAP UNSELECT", - 4314 => "IMAP ACL, RIGHTS=", - 4315 => "IMAP UIDPLUS", - 4467 => "IMAP URLAUTH", - 4469 => "IMAP CATENATE", - 4731 => "IMAP ESEARCH", - 4959 => "IMAP SASL-IR", - 4978 => "IMAP COMPRESS=DEFLATE", - 5032 => "IMAP WITHIN", - 5161 => "IMAP ENABLE", - 5182 => "IMAP SEARCHRES", - 5255 => "IMAP I18NLEVEL=1, I18NLEVEL=2, LANGUAGE", - 5256 => "IMAP SORT, THREAD", - 5257 => "IMAP ANNOTATE-EXPERIMENT-1", - 5258 => "IMAP LIST-EXTENDED", - 5259 => "IMAP CONVERT", - 5267 => "IMAP CONTEXT=SEARCH, CONTEXT=SORT, ESORT", - 5464 => "IMAP METADATA, METADATA-SERVER", - 5465 => "IMAP NOTIFY", - 5466 => "IMAP FILTERS", - 5524 => "IMAP URLAUTH=BINARY", # see also: [RFC Errata 6214] - 5550 => "IMAP URL-PARTIAL", - 5738 => "IMAP UTF8=ALL, UTF8=APPEND, UTF8=USER", # OBSOLETED by RFC6855 - 5819 => "IMAP LIST-STATUS", - 5957 => "IMAP SORT=DISPLAY", - 6154 => "IMAP SPECIAL-USE, CREATE-SPECIAL-USE", - 6203 => "IMAP SEARCH=FUZZY", - 6785 => "IMAP IMAPSIEVE=", - 6851 => "IMAP MOVE", - 6855 => "IMAP UTF8=ACCEPT, UTF8=ONLY", - 7162 => "IMAP CONDSTORE, QRESYNC", - 7377 => "IMAP MULTISEARCH", - 7888 => "IMAP LITERAL+, LITERAL-", - 7889 => "IMAP APPENDLIMIT", - 8437 => "IMAP UNAUTHENTICATE", - 8438 => "IMAP STATUS=SIZE", - 8440 => "IMAP LIST-MYRIGHTS", - 8474 => "IMAP OBJECTID", - 8508 => "IMAP REPLACE", - 8514 => "IMAP SAVEDATE", - 8970 => "IMAP PREVIEW", - 9208 => "IMAP QUOTA, QUOTA=, QUOTASET", - - # etc... - 3629 => "UTF8", - 6857 => "Post-Delivery Message Downgrading for I18n Email Messages", - -}.freeze - -task :rfcs => RFCS.keys.map {|n| "rfcs/rfc%04d.txt" % [n] } - -RFC_RE = %r{rfcs/rfc(\d+).*\.txt}.freeze -rule RFC_RE do |t| - require "fileutils" - FileUtils.mkpath "rfcs" - require "net/http" - t.name =~ RFC_RE - rfc_url = URI("https://www.rfc-editor.org/rfc/rfc#$1.txt") - rfc_txt = Net::HTTP.get(rfc_url) - File.write(t.name, rfc_txt) -end - -CLEAN.include "rfcs/rfc*.txt" diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/rakelib/saslprep.rake ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/rakelib/saslprep.rake --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/rakelib/saslprep.rake 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/rakelib/saslprep.rake 1970-01-01 00:00:00.000000000 +0000 @@ -1,30 +0,0 @@ -# frozen_string_literal: true - -require_relative "string_prep_tables_generator" - -generator = StringPrepTablesGenerator.new - -file generator.json_filename => generator.json_deps do |t| - generator.generate_json_data_file -end - -directory "lib/net/imap/sasl" - -file "lib/net/imap/stringprep/tables.rb" => generator.rb_deps do |t| - File.write t.name, generator.stringprep_rb -end - -file "lib/net/imap/stringprep/saslprep_tables.rb" => generator.rb_deps do |t| - File.write t.name, generator.saslprep_rb -end - -GENERATED_RUBY = FileList.new( - "lib/net/imap/stringprep/tables.rb", - "lib/net/imap/stringprep/saslprep_tables.rb", -) - -CLEAN.include generator.clean_deps -CLOBBER.include GENERATED_RUBY - -task saslprep_rb: GENERATED_RUBY -task test: :saslprep_rb diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/rakelib/string_prep_tables_generator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/rakelib/string_prep_tables_generator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/rakelib/string_prep_tables_generator.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/rakelib/string_prep_tables_generator.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,445 +0,0 @@ -# frozen_string_literal: true - -# Generator for stringprep regexps. -# -# Combines Unicode character classes with generated tables. Generated regexps -# are still used to test that the written regexps conform to the specification. -# Some tables don't match up well with any character properties available to -# ruby's regexp engine. Those use the table-generated regexps. -class StringPrepTablesGenerator - STRINGPREP_RFC_FILE = "rfcs/rfc3454.txt" - STRINGPREP_JSON_FILE = "rfcs/rfc3454-stringprep_tables.json" - - # valid UTF-8 can't contain these codepoints - # checking for them anyway, using /\p{Cs}/ ;) - SURROGATES_RANGE = 0xD800..0xDFFF - - attr_reader :json_filename, :rfc_filename - - def initialize(rfc_filename: STRINGPREP_RFC_FILE, - json_filename: STRINGPREP_JSON_FILE) - @rfc_filename = rfc_filename - @json_filename = json_filename - end - - # for rake deps - def json_deps; Rake::FileList.new __FILE__, STRINGPREP_RFC_FILE end - def rb_deps; Rake::FileList.new __FILE__, STRINGPREP_JSON_FILE end - def clean_deps; Rake::FileList.new STRINGPREP_JSON_FILE end - - def generate_json_data_file - require "json" - rfc_filename - .then(&File.method(:read)) - .then(&method(:parse_rfc_text)) - .then(&JSON.method(:pretty_generate)) - .then {|data| File.write json_filename, data } - end - - def tables; @tables ||= load_tables_and_titles_from_json!.first end - def titles; @titles ||= load_tables_and_titles_from_json!.last end - def ranges; @ranges ||= tables.transform_values(&method(:to_ranges)) end - def arrays; @arrays ||= ranges.transform_values{|t| t.flat_map(&:to_a) } end - def sets; @sets ||= arrays.transform_values(&:to_set) end - def regexps; @regexps ||= arrays.transform_values(&method(:to_regexp)) end - def asgn_regexps; @asgn_regexps || asgn_regexps! end - - def merged_tables_regex(*table_names, negate: false) - table_names - .flat_map(&arrays.method(:fetch)) - .then {|array| to_regexp(array, negate: negate) } - end - - def regexp_for(*names, negate: false) - asgn_regexps[[*names, negate]] ||= merged_tables_regex(*names, negate: negate) - end - - def stringprep_rb - <<~RUBY - # frozen_string_literal: true - - #-- - # This file is generated from RFC3454, by rake. Don't edit directly. - #++ - - module Net::IMAP::StringPrep - - module Tables - - #{asgn_table "A.1"} - - #{asgn_table "B.1"} - - #{asgn_table "B.2"} - - #{asgn_table "B.3"} - - #{asgn_mapping "B.1", ""} - - #{asgn_mapping "B.2"} - - #{asgn_mapping "B.3"} - - #{asgn_table "C.1.1"} - - #{asgn_table "C.1.2"} - - #{asgn_table "C.2.1"} - - #{asgn_table "C.2.2"} - - #{asgn_table "C.3"} - - #{asgn_table "C.4"} - - #{asgn_table "C.5"} - - #{asgn_table "C.6"} - - #{asgn_table "C.7"} - - #{asgn_table "C.8"} - - #{asgn_table "C.9"} - - #{asgn_table "D.1"} - - # Used to check req3 of bidirectional checks - #{asgn_table "D.1", negate: true} - - #{asgn_table "D.2"} - - BIDI_DESC_REQ2 = "A string with RandALCat characters must not contain LCat characters." - - # Bidirectional Characters [StringPrep, §6], Requirement 2 - # >>> - # If a string contains any RandALCat character, the string MUST NOT - # contain any LCat character. - BIDI_FAILS_REQ2 = #{bidi_fails_req2.inspect}.freeze - - BIDI_DESC_REQ3 = "A string with RandALCat characters must start and end with RandALCat characters." - - # Bidirectional Characters [StringPrep, §6], Requirement 3 - # >>> - # If a string contains any RandALCat character, a RandALCat - # character MUST be the first character of the string, and a - # RandALCat character MUST be the last character of the string. - BIDI_FAILS_REQ3 = #{bidi_fails_req3.inspect}.freeze - - # Bidirectional Characters [StringPrep, §6] - BIDI_FAILURE = #{bidi_failure_regexp.inspect}.freeze - - # Names of each codepoint table in the RFC-3454 appendices - TITLES = { - #{table_titles_rb} - }.freeze - - # Regexps matching each codepoint table in the RFC-3454 appendices - REGEXPS = { - #{table_regexps_rb} - }.freeze - - MAPPINGS = { - "B.1" => [IN_B_1, MAP_B_1].freeze, - "B.2" => [IN_B_2, MAP_B_2].freeze, - "B.3" => [IN_B_3, MAP_B_3].freeze, - }.freeze - - end - end - RUBY - end - - def table_titles_rb(indent = 3) - titles - .map{|t| "%p => %p," % t } - .join("\n#{" "*indent}") - end - - def table_regexps_rb(indent = 3) - asgn_regexps # => { ["A.1", false] => regexp, ... } - .reject {|(_, n), _| n } - .map {|(t, _), _| "%p => %s," % [t, regexp_const_name(t)] } - .join("\n#{" "*indent}") - end - - def saslprep_rb - <<~RUBY - # frozen_string_literal: true - - #-- - # This file is generated from RFC3454, by rake. Don't edit directly. - #++ - - module Net::IMAP::StringPrep - - module SASLprep - - # RFC4013 §2.1 Mapping - mapped to space - # >>> - # non-ASCII space characters (\\StringPrep\\[\\"C.1.2\\"]) that can - # be mapped to SPACE (U+0020) - # - # Equal to \\StringPrep\\[\\"C.1.2\\"]. - # Redefined here to avoid loading StringPrep::Tables unless necessary. - MAP_TO_SPACE = #{regex_str "C.1.2"} - - # RFC4013 §2.1 Mapping - mapped to nothing - # >>> - # the "commonly mapped to nothing" characters - # (\\StringPrep\\[\\"B.1\\"]) that can be mapped to nothing. - # - # Equal to \\StringPrep\\[\\"B.1\\"]. - # Redefined here to avoid loading StringPrep::Tables unless necessary. - MAP_TO_NOTHING = #{regex_str "B.1"} - - # RFC4013 §2.3 Prohibited Output - # >>> - # * Non-ASCII space characters — \\StringPrep\\[\\"C.1.2\\"] - # * ASCII control characters — \\StringPrep\\[\\"C.2.1\\"] - # * Non-ASCII control characters — \\StringPrep\\[\\"C.2.2\\"] - # * Private Use characters — \\StringPrep\\[\\"C.3\\"] - # * Non-character code points — \\StringPrep\\[\\"C.4\\"] - # * Surrogate code points — \\StringPrep\\[\\"C.5\\"] - # * Inappropriate for plain text characters — \\StringPrep\\[\\"C.6\\"] - # * Inappropriate for canonical representation characters — \\StringPrep\\[\\"C.7\\"] - # * Change display properties or deprecated characters — \\StringPrep\\[\\"C.8\\"] - # * Tagging characters — \\StringPrep\\[\\"C.9\\"] - TABLES_PROHIBITED = #{SASL_TABLES_PROHIBITED.inspect}.freeze - - # Adds unassigned (by Unicode 3.2) codepoints to TABLES_PROHIBITED. - # - # RFC4013 §2.5 Unassigned Code Points - # >>> - # This profile specifies the \\StringPrep\\[\\"A.1\\"] table as its - # list of unassigned code points. - TABLES_PROHIBITED_STORED = ["A.1", *TABLES_PROHIBITED].freeze - - # A Regexp matching codepoints prohibited by RFC4013 §2.3. - # - # This combines all of the TABLES_PROHIBITED tables. - PROHIBITED_OUTPUT = #{regex_str(*SASL_TABLES_PROHIBITED)} - - # RFC4013 §2.5 Unassigned Code Points - # >>> - # This profile specifies the \\StringPrep\\[\\"A.1\\"] table as its - # list of unassigned code points. - # - # Equal to \\StringPrep\\[\\"A.1\\"]. - # Redefined here to avoid loading StringPrep::Tables unless necessary. - UNASSIGNED = #{regex_str "A.1"} - - # A Regexp matching codepoints prohibited by RFC4013 §2.3 and §2.5. - # - # This combines PROHIBITED_OUTPUT and UNASSIGNED. - PROHIBITED_OUTPUT_STORED = Regexp.union( - UNASSIGNED, PROHIBITED_OUTPUT - ).freeze - - # Bidirectional Characters [StringPrep, §6] - # - # A Regexp for strings that don't satisfy StringPrep's Bidirectional - # Characters rules. - # - # Equal to StringPrep::Tables::BIDI_FAILURE. - # Redefined here to avoid loading StringPrep::Tables unless necessary. - BIDI_FAILURE = #{bidi_failure_regexp.inspect}.freeze - - # A Regexp matching strings prohibited by RFC4013 §2.3 and §2.4. - # - # This combines PROHIBITED_OUTPUT and BIDI_FAILURE. - PROHIBITED = Regexp.union( - PROHIBITED_OUTPUT, BIDI_FAILURE, - ) - - # A Regexp matching strings prohibited by RFC4013 §2.3, §2.4, and §2.5. - # - # This combines PROHIBITED_OUTPUT_STORED and BIDI_FAILURE. - PROHIBITED_STORED = Regexp.union( - PROHIBITED_OUTPUT_STORED, BIDI_FAILURE, - ) - - end - end - RUBY - end - - private - - def parse_rfc_text(rfc3454_text) - titles = {} - tables, = rfc3454_text - .lines - .each_with_object([]) {|line, acc| - current, table = acc.last - case line - when /^([A-D]\.[1-9](?:\.[1-9])?) (.*)/ - titles[$1] = $2 - when /^ {3}-{5} Start Table (\S*)/ - acc << [$1, []] - when /^ {3}-{5} End Table / - acc << [nil, nil] - when /^ {3}([0-9A-F]+); ([ 0-9A-F]*)(?:;[^;]*)$/ # mapping tables - table << [$1, $2.split(/ +/)] if current - when /^ {3}([-0-9A-F]+)(?:;[^;]*)?$/ # regular tables - table << $1 if current - when /^ {3}(.*)/ - raise "expected to match %p" % $1 if current - end - } - .to_h.compact - .transform_values {|t| t.first.size == 2 ? t.to_h : t } - tables["titles"] = titles - tables - end - - def load_tables_and_titles_from_json! - require "json" - @tables = json_filename - .then(&File.method(:read)) - .then(&JSON.method(:parse)) - @titles = @tables.delete "titles" - [@tables, @titles] - end - - def to_ranges(table) - (table.is_a?(Hash) ? table.keys : table) - .map{|range| range.split(?-).map{|cp| Integer cp, 16} } - .map{|s,e| s..(e || s)} - end - - # TODO: DRY with unicode_normalize - def to_map(table) - table = table.to_hash - .transform_keys { Integer _1, 16 } - .transform_keys { [_1].pack("U*") } - .transform_values {|cps| cps.map { Integer _1, 16 } } - .transform_values { _1.pack("U*") } - end - - # Starting from a codepoints array (rather than ranges) to deduplicate merged - # tables. - def to_regexp(codepoints, negate: false) - codepoints - .grep_v(SURROGATES_RANGE) # remove surrogate codepoints from C.5 and D.2 - .uniq - .sort - .chunk_while {|cp1,cp2| cp1 + 1 == cp2 } # find contiguous chunks - .map {|chunk| chunk.map{|cp| "%04x" % cp } } # convert to hex strings - .partition {|chunk| chunk[1] } # ranges vs singles - .then {|ranges, singles| - singles.flatten! - [ - negate ? "^" : "", - singles.flatten.any? ? "\\u{%s}" % singles.join(" ") : "", - ranges.map {|r| "\\u{%s}-\\u{%s}" % [r.first, r.last] }.join, - codepoints.any?(SURROGATES_RANGE) ? "\\p{Cs}" : "", # not necessary :) - ].join - } - .then {|char_class| Regexp.new "[#{char_class}]" } - end - - def asgn_regexps! - @asgn_regexps = {} - # preset the regexp for each table - asgn_regex "A.1", /\p{^AGE=3.2}/ - # If ruby supported all unicode properties (i.e. line break = word joiner): - # /[\u{00ad 034f 1806}\p{join_c}\p{VS}\p{lb=WJ}&&\p{age=3.2}]/ - asgn_table "B.1" - asgn_table "B.2" - asgn_table "B.3" - asgn_regex "C.1.1", / / - asgn_regex "C.1.2", /[\u200b\p{Zs}&&[^ ]]/ - asgn_regex "C.2.1", /[\x00-\x1f\x7f]/ - # C.2.2 is a union: - # Cc + Cf (as defined by Unicode 3.2) + Zl + Zp + 0xfffc - # - any codepoints covered by C.2.1 or C.8 or C.9 - # - # But modern Unicode properties are significantly different, so it's better - # to just load the table definition. - asgn_table "C.2.2" - asgn_regex "C.3", /\p{private use}/ - asgn_regex "C.4", /\p{noncharacter code point}/ - asgn_regex "C.5", /\p{surrogate}/ - asgn_regex "C.6", /[\p{in specials}&&\p{AGE=3.2}&&\p{^NChar}]/ - asgn_regex "C.7", /[\p{in ideographic description characters}&&\p{AGE=3.2}]/ - # C.8 is a union of \p{Bidi Control} and Unicode 3.2 properties. But those properties - # have changed for modern Unicode, and thus for modern ruby's regexp - # character properties. It's better to just load the table definition. - asgn_table "C.8" - asgn_regex "C.9", /[\p{in Tags}&&\p{AGE=3.2}]/ - # Unfortunately, ruby doesn't (currently) support /[\p{Bidi - # Class=R}\p{bc=AL}]/. On the other hand, StringPrep (based on Unicode 3.2) - # might not be a good match for the modern (14.0) property value anyway. - asgn_table "D.1" - asgn_table "D.1", negate: true # used by BIDI_FAILS_REQ3 - asgn_table "D.2" - @asgn_regexps - end - - def regex_str(*names, negate: false) - "%p.freeze" % regexp_for(*names, negate: negate) - end - - def asgn_table(name, negate: false) - asgn_regex(name, regexp_for(name, negate: negate), negate: negate) - end - - def asgn_mapping(name, replacement = to_map(tables[name])) - cname = name.tr(?., ?_).upcase - "# Replacements for %s\n%s%s = %p.freeze" % [ - "IN_#{name}", " " * 2, "MAP_#{cname}", replacement, - ] - end - - def regexp_const_desc(name, negate: false) - if negate then "Matches the negation of the %s table" % [name] - else %q{%s \\StringPrep\\[\\"%s\\"]} % [titles.fetch(name), name] - end - end - - def regexp_const_name(table_name, negate: false) - "IN_%s%s" % [table_name.tr(".", "_"), negate ? "_NEGATED" : ""] - end - - def asgn_regex(name, regexp, negate: false) - asgn_regexps[[name, negate]] = regexp - "# %s\n%s%s = %p.freeze" % [ - regexp_const_desc(name, negate: negate), " " * 4, - regexp_const_name(name, negate: negate), - regexp, - ] - end - - def bidi_R_AL ; regexp_for "D.1" end - def bidi_not_R_AL ; regexp_for "D.1", negate: true end - def bidi_L ; regexp_for "D.2" end - - def bidi_fails_req2 - Regexp.union( - /#{bidi_R_AL}.*?#{bidi_L}/mu, # RandALCat followed by LCat - /#{bidi_L}.*?#{bidi_R_AL}/mu, # RandALCat preceded by LCat - ) - end - - def bidi_fails_req3 - # contains RandALCat: - Regexp.union( - /\A#{bidi_not_R_AL}.*?#{bidi_R_AL}/mu, # but doesn't start with RandALCat - /#{bidi_R_AL}.*?#{bidi_not_R_AL}\z/mu, # but doesn't end with RandALCat - ) - end - - def bidi_failure_regexp - Regexp.union(bidi_fails_req2, bidi_fails_req3) - end - - SASL_TABLES_PROHIBITED = %w[ - C.1.2 C.2.1 C.2.2 C.3 C.4 C.5 C.6 C.7 C.8 C.9 - ].freeze - - SASL_TABLES_PROHIBITED_STORED = %w[ - A.1 C.1.2 C.2.1 C.2.2 C.3 C.4 C.5 C.6 C.7 C.8 C.9 - ].freeze - -end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/sample/net-imap.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/sample/net-imap.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.19/sample/net-imap.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.19/sample/net-imap.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,167 +0,0 @@ -require 'net/imap' -require "getoptlong" - -$stdout.sync = true -$port = nil -$user = ENV["USER"] || ENV["LOGNAME"] -$auth = "login" -$ssl = false -$starttls = false - -def usage - < - - --help print this message - --port=PORT specifies port - --user=USER specifies user - --auth=AUTH specifies auth type - --starttls use starttls - --ssl use ssl -EOF -end - -begin - require 'io/console' -rescue LoadError - def _noecho(&block) - system("stty", "-echo") - begin - yield STDIN - ensure - system("stty", "echo") - end - end -else - def _noecho(&block) - STDIN.noecho(&block) - end -end - -def get_password - print "password: " - begin - return _noecho(&:gets).chomp - ensure - puts - end -end - -def get_command - printf("%s@%s> ", $user, $host) - if line = gets - return line.strip.split(/\s+/) - else - return nil - end -end - -parser = GetoptLong.new -parser.set_options(['--debug', GetoptLong::NO_ARGUMENT], - ['--help', GetoptLong::NO_ARGUMENT], - ['--port', GetoptLong::REQUIRED_ARGUMENT], - ['--user', GetoptLong::REQUIRED_ARGUMENT], - ['--auth', GetoptLong::REQUIRED_ARGUMENT], - ['--starttls', GetoptLong::NO_ARGUMENT], - ['--ssl', GetoptLong::NO_ARGUMENT]) -begin - parser.each_option do |name, arg| - case name - when "--port" - $port = arg - when "--user" - $user = arg - when "--auth" - $auth = arg - when "--ssl" - $ssl = true - when "--starttls" - $starttls = true - when "--debug" - Net::IMAP.debug = true - when "--help" - usage - exit - end - end -rescue - abort usage -end - -$host = ARGV.shift -unless $host - abort usage -end - -imap = Net::IMAP.new($host, :port => $port, :ssl => $ssl) -begin - imap.starttls if $starttls - class << password = method(:get_password) - alias to_str call - end - imap.authenticate($auth, $user, password) - while true - cmd, *args = get_command - break unless cmd - begin - case cmd - when "list" - for mbox in imap.list("", args[0] || "*") - if mbox.attr.include?(Net::IMAP::NOSELECT) - prefix = "!" - elsif mbox.attr.include?(Net::IMAP::MARKED) - prefix = "*" - else - prefix = " " - end - print prefix, mbox.name, "\n" - end - when "select" - imap.select(args[0] || "inbox") - print "ok\n" - when "close" - imap.close - print "ok\n" - when "summary" - unless messages = imap.responses["EXISTS"][-1] - puts "not selected" - next - end - if messages > 0 - for data in imap.fetch(1..-1, ["ENVELOPE"]) - print data.seqno, ": ", data.attr["ENVELOPE"].subject, "\n" - end - else - puts "no message" - end - when "fetch" - if args[0] - data = imap.fetch(args[0].to_i, ["RFC822.HEADER", "RFC822.TEXT"])[0] - puts data.attr["RFC822.HEADER"] - puts data.attr["RFC822.TEXT"] - else - puts "missing argument" - end - when "logout", "exit", "quit" - break - when "help", "?" - print <. +You can redistribute it and/or modify it under either the terms of the +2-clause BSDL (see the file BSDL), or the conditions below: + +1. You may make and give away verbatim copies of the source form of the + software without restriction, provided that you duplicate all of the + original copyright notices and associated disclaimers. + +2. You may modify your copy of the software in any way, provided that + you do at least ONE of the following: + + a. place your modifications in the Public Domain or otherwise + make them Freely Available, such as by posting said + modifications to Usenet or an equivalent medium, or by allowing + the author to include your modifications in the software. + + b. use the modified software only within your corporation or + organization. + + c. give non-standard binaries non-standard names, with + instructions on where to get the original software distribution. + + d. make other distribution arrangements with the author. + +3. You may distribute the software in object code or binary form, + provided that you do at least ONE of the following: + + a. distribute the binaries and library files of the software, + together with instructions (in the manual page or equivalent) + on where to get the original distribution. + + b. accompany the distribution with the machine-readable source of + the software. + + c. give non-standard binaries non-standard names, with + instructions on where to get the original software distribution. + + d. make other distribution arrangements with the author. + +4. You may modify and include the part of the software into any other + software (possibly commercial). But some files in the distribution + are not written by the author, so that they are not under these terms. + + For the list of those files and their copying conditions, see the + file LEGAL. + +5. The scripts and library files supplied as input to or produced as + output from the software do not automatically fall under the + copyright of the software, but belong to whomever generated them, + and may be sold commercially, and may be aggregated with this + software. + +6. THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR + IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED + WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + PURPOSE. diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/Gemfile ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/Gemfile --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/Gemfile 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/Gemfile 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,16 @@ +# frozen_string_literal: true + +source "https://rubygems.org" + +gemspec + +# gem "digest" # not included as a workaround for #576 +gem "strscan" +gem "base64" + +gem "rake" +gem "rdoc" +gem "test-unit" +gem "test-unit-ruby-core", git: "https://github.com/ruby/test-unit-ruby-core" + +gem "benchmark-driver" diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/LICENSE.txt ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/LICENSE.txt --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/LICENSE.txt 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/LICENSE.txt 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,65 @@ +All the files in this distribution are covered under either the Ruby license or +the BSD-2-Clause license (see the file COPYING) except some documentation mentioned +below. + +------------------------------------------------------------------------- + +This software includes documentation which has been copied from the relevant +RFCs. The copied documentation is covered by the following licenses: + +RFC 3501 (Editor: M. Crispin) +Full Copyright Statement + + Copyright (C) The Internet Society (2003). All Rights Reserved. + + This document and translations of it may be copied and furnished to + others, and derivative works that comment on or otherwise explain it + or assist in its implementation may be prepared, copied, published + and distributed, in whole or in part, without restriction of any + kind, provided that the above copyright notice and this paragraph are + included on all such copies and derivative works. However, this + document itself may not be modified in any way, such as by removing + the copyright notice or references to the Internet Society or other + Internet organizations, except as needed for the purpose of + developing Internet standards in which case the procedures for + copyrights defined in the Internet Standards process must be + followed, or as required to translate it into languages other than + English. + + The limited permissions granted above are perpetual and will not be + revoked by the Internet Society or its successors or assigns. v This + document and the information contained herein is provided on an "AS + IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING TASK + FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT + LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL + NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY + OR FITNESS FOR A PARTICULAR PURPOSE. + + +RFC9051 (Editors: A. Melnikov, B. Leiba) +Copyright Notice + + Copyright (c) 2021 IETF Trust and the persons identified as the + document authors. All rights reserved. + + This document is subject to BCP 78 and the IETF Trust's Legal + Provisions Relating to IETF Documents + (https://trustee.ietf.org/license-info) in effect on the date of + publication of this document. Please review these documents + carefully, as they describe your rights and restrictions with respect + to this document. Code Components extracted from this document must + include Simplified BSD License text as described in Section 4.e of + the Trust Legal Provisions and are provided without warranty as + described in the Simplified BSD License. + + This document may contain material from IETF Documents or IETF + Contributions published or made publicly available before November + 10, 2008. The person(s) controlling the copyright in some of this + material may not have granted the IETF Trust the right to allow + modifications of such material outside the IETF Standards Process. + Without obtaining an adequate license from the person(s) controlling + the copyright in such materials, this document may not be modified + outside the IETF Standards Process, and derivative works of it may + not be created outside the IETF Standards Process, except to format + it for publication as an RFC or to translate it into languages other + than English. diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/README.md ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/README.md --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/README.md 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/README.md 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,71 @@ +# Net::IMAP + +Net::IMAP implements Internet Message Access Protocol (IMAP) client +functionality. The protocol is described in [IMAP](https://tools.ietf.org/html/rfc3501). + +## Installation + +Add this line to your application's Gemfile: + +```ruby +gem 'net-imap' +``` + +And then execute: + + $ bundle install + +Or install it yourself as: + + $ gem install net-imap + +## Usage + +### Connect with TLS to port 993 + +```ruby +imap = Net::IMAP.new('mail.example.com', ssl: true) +imap.port => 993 +imap.tls_verified? => true +case imap.greeting.name +in /OK/i + # The client is connected in the "Not Authenticated" state. + imap.authenticate("PLAIN", "joe_user", "joes_password") +in /PREAUTH/i + # The client is connected in the "Authenticated" state. +end +``` + +### List sender and subject of all recent messages in the default mailbox + +```ruby +imap.examine('INBOX') +imap.search(["RECENT"]).each do |message_id| + envelope = imap.fetch(message_id, "ENVELOPE")[0].attr["ENVELOPE"] + puts "#{envelope.from[0].name}: \t#{envelope.subject}" +end +``` + +### Move all messages from April 2003 from "Mail/sent-mail" to "Mail/sent-apr03" + +```ruby +imap.select('Mail/sent-mail') +if not imap.list('Mail/', 'sent-apr03') + imap.create('Mail/sent-apr03') +end +imap.search(["BEFORE", "30-Apr-2003", "SINCE", "1-Apr-2003"]).each do |message_id| + imap.copy(message_id, "Mail/sent-apr03") + imap.store(message_id, "+FLAGS", [:Deleted]) +end +imap.expunge +``` + +## Development + +After checking out the repo, run `bin/setup` to install dependencies. Then, run `bundle exec rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment. + +To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org). + +## Contributing + +Bug reports and pull requests are welcome on GitHub at https://github.com/ruby/net-imap. diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/Rakefile ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/Rakefile --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/Rakefile 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/Rakefile 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,13 @@ +# frozen_string_literal: true + +require "bundler/gem_tasks" +require "rake/testtask" +require "rake/clean" + +Rake::TestTask.new(:test) do |t| + t.libs << "test/lib" + t.ruby_opts << "-rhelper" + t.test_files = FileList["test/**/test_*.rb"] +end + +task :default => :test diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/docs/styles.css ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/docs/styles.css --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/docs/styles.css 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/docs/styles.css 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,24 @@ +/* this is a work in progress. :) */ + +main .method-header { + background: rgba(27,31,35,0.05); + border: 1px solid #6C8C22; + padding: 0.5em; + border-radius: 4px; + /* padding: 0 0.5em; */ + /* border-width: 0 1px; */ + /* border-color: #6C8C22; */ + /* border-style: solid; */ +} + +main .method-description, main .aliases { + padding-left: 1em; +} + +body { + /* + * The default (300) can be too low contrast. Also, many fonts don't + * distinguish between 300->400, so ... had no effect. + */ + font-weight: 400; +} diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/authenticators.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/authenticators.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/authenticators.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/authenticators.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,37 @@ +# frozen_string_literal: true + +# Backward compatible delegators from Net::IMAP to Net::IMAP::SASL. +module Net::IMAP::Authenticators + + # Deprecated. Use Net::IMAP::SASL.add_authenticator instead. + def add_authenticator(...) + warn( + "%s.%s is deprecated. Use %s.%s instead." % [ + Net::IMAP, __method__, Net::IMAP::SASL, __method__ + ], + uplevel: 1 + ) + Net::IMAP::SASL.add_authenticator(...) + end + + # Deprecated. Use Net::IMAP::SASL.authenticator instead. + def authenticator(...) + warn( + "%s.%s is deprecated. Use %s.%s instead." % [ + Net::IMAP, __method__, Net::IMAP::SASL, __method__ + ], + uplevel: 1 + ) + Net::IMAP::SASL.authenticator(...) + end + + Net::IMAP.extend self +end + +class Net::IMAP + PlainAuthenticator = SASL::PlainAuthenticator # :nodoc: + deprecate_constant :PlainAuthenticator + + XOauth2Authenticator = SASL::XOAuth2Authenticator # :nodoc: + deprecate_constant :XOauth2Authenticator +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/command_data.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/command_data.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/command_data.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/command_data.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,507 @@ +# frozen_string_literal: true + +require "date" + +require_relative "errors" + +module Net + class IMAP < Protocol + + private + + def validate_data(data) + case data + when nil + when String + when Integer + # Covers modseq-valzer, which is the largest valid IMAP integer + if data.negative? + raise DataFormatError, "Integer argument must be unsigned: #{data}" + elsif 0xffff_ffff_ffff_ffff < data + raise DataFormatError, "Integer argument must fit in 64 bits: #{data}" + end + when Array + data.each do |i| + validate_data(i) + end + when Time, Date, DateTime + when Symbol + Flag.validate(data) + else + data.validate + end + end + + def send_data(data, tag = nil) + case data + when nil + put_string("NIL") + when String + send_string_data(data, tag) + when Integer + send_number_data(data) + when Array + send_list_data(data, tag) + when Time, DateTime + send_time_data(data) + when Date + send_date_data(data) + when Symbol + Flag[data].send_data(self, tag) + else + data.send_data(self, tag) + end + end + + def send_string_data(str, tag = nil) + if str.empty? + put_string('""') + elsif str.match?(/[\r\n]/n) + # literal, because multiline + send_literal(str, tag) + elsif !str.ascii_only? + if @utf8_strings + # quoted string + send_quoted_string(str) + else + # literal, because of non-ASCII bytes + send_literal(str, tag) + end + elsif str.match?(/[(){ \x00-\x1f\x7f%*"\\]/n) + # quoted string + send_quoted_string(str) + else + put_string(str) + end + end + + def send_quoted_string(str) + put_string('"' + str.gsub(/["\\]/, "\\\\\\&") + '"') + end + + def send_binary_literal(*a, **kw) send_literal(*a, **kw, binary: true) end + + # `non_sync` is an optional tri-state flag: + # * `true` -> Force non-synchronizing `LITERAL+`/`LITERAL-` behavior. + # NOTE: raises DataFormatError when server doesn't support + # non-synchronizing literal, or literal is too large for LITERAL-. + # * `false` -> Force normal synchronizing literal behavior. + # * `nil` -> (default) Currently behaves like `false` (will be dynamic). + # TODO: Dynamic, based on capabilities and bytesize. + def send_literal(str, tag = nil, binary: false, non_sync: nil) + bytesize = str.bytesize + synchronize do + if non_sync && !non_sync_literal_allowed?(bytesize) + # TODO: check in Printer, so we don't need to close the connection. + @sock.close + raise DataFormatError, "Connection closed: " \ + "Cannot send non-synchronizing literal without known server support" + end + prefix = "~" if binary + plus = "+" if non_sync + put_string("#{prefix}{#{bytesize}#{plus}}\r\n") + if non_sync + put_string(str) + return + end + @continued_command_tag = tag + @continuation_request_exception = nil + begin + @continuation_request_arrival.wait + e = @continuation_request_exception || @exception + raise e if e + put_string(str) + ensure + @continued_command_tag = nil + @continuation_request_exception = nil + end + end + end + + def non_sync_literal_allowed?(bytesize) + return unless capabilities_cached? + return "+" if capable?("LITERAL+") + return "-" if capable_literal_minus? && bytesize <= 4096 + false + end + + def capable_literal_minus?; capable?("LITERAL-") || capable?("IMAP4rev2") end + + # NOTE: +num+ should already be an Integer + def send_number_data(num) + put_string(Integer(num).to_s) + end + + def send_list_data(list, tag = nil) + put_string("(") + first = true + list.each do |i| + if first + first = false + else + put_string(" ") + end + send_data(i, tag) + end + put_string(")") + end + + def send_date_data(date) put_string Net::IMAP.encode_date(date) end + def send_time_data(time) put_string Net::IMAP.encode_time(time) end + + # simplistic emulation of CommandData = Data.define(:data) + class CommandData # :nodoc: + class << self + def new(arg = nil, data: arg) super(data: data) end + alias :[] :new + end + + def initialize(data:) + @data = data + freeze + end + + attr_reader :data + + def to_h(&block) block ? to_h.to_h(&block) : { data: data } end + def ==(other) self.class === other && to_h == other.to_h end + def eql?(other) self.class === other && to_h.eql?(other.to_h) end + + # following class definition goes beyond the basic Data.define(:data) + ## + + def self.validate(...) + data = new(...) + data.validate + data + end + + def send_data(imap, tag) + raise NoMethodError, "#{self.class} must implement #{__method__}" + end + + def validate + end + end + + # Represents IMAP +text+ or +quoted+ data, which share the same + # validations of decoded #data, and differ only in how they are formatted. + # + # +data+ may contain any 7-bit ASCII character except +NULL+, +CR+, or +LF+. + # Any multibyte +UTF-8+ character is also allowed when the connection + # supports UTF8: either +UTF8=ACCEPT+ or +IMAP4rev2+ have been enabled, or + # the server supports only +IMAP4rev2+ and not earlier IMAP revisions, or + # the server advertises +UTF8=ONLY+. + # + # NOTE: This does not verify whether the connection supports UTF-8, but that + # may change in future versions. + # + # The string's bytes must be valid ASCII or valid UTF-8. The string's + # reported encoding is ignored, but the string is _not_ transcoded. + class ValidNonLiteralData < CommandData + def initialize(data:) + data = String(data.to_str) + unless [Encoding::ASCII, Encoding::UTF_8].include?(data.encoding) + data = data.dup.force_encoding(data.ascii_only? ? "ASCII" : "UTF-8") + end + data = -data + super + validate + end + + def validate + if ![Encoding::ASCII, Encoding::UTF_8].include?(data.encoding) + raise DataFormatError, "must use ASCII or UTF-8 encoding" + elsif !data.valid_encoding? + raise DataFormatError, "invalid UTF-8 must be literal encoded" + elsif data.include?("\0") + raise DataFormatError, "NULL byte must be binary literal encoded" + elsif /[\r\n]/.match?(data) + raise DataFormatError, "CR and LF bytes must be literal encoded" + end + end + + def ascii_only?; data.ascii_only? end + + def send_data(imap, tag = nil) imap.__send__(:put_string, formatted) end + end + + # Represents IMAP +text+ data, which covers everything in the IMAP grammar, + # except for +literal+, +literal8+, and the concluding +CRLF+. + # + # NOTE: The current implementation does not verify that the connection + # supports UTF-8. Future versions may validate this. + class RawText < ValidNonLiteralData # :nodoc: + # raw: no formatting necessary + alias formatted data + end + + class RawData < CommandData # :nodoc: + def initialize(data:) + case data + when String + data = self.class.split(data) + when Array + unless data.all? { |part| RawText === part || Literal === part } + raise TypeError, "expected String or Array[#{RawText} | #{Literal}]" + end + else + raise TypeError, "expected String or Array[#{RawText} | #{Literal}]" + end + super + validate + end + + def send_data(imap, tag) data.each do _1.send_data(imap, tag) end end + + def validate + return unless RawText === data.last + text = data.last.data + if text.rindex(/\{\d+\+?\}\z/n) + raise DataFormatError, "RawData cannot end with literal continuation" + end + end + + # Splits an input +string+ into an array of RawText and Literal/Literal8. + # + # NOTE: unlike RawData#validate, this does not prevent the final RawText + # from ending with a literal prefix. + def self.split(data) + data = data.b # dups and ensures BINARY encoding + parts = [] + while data.match(/(~)?\{(0|[1-9]\d*)(\+)?\}\r\n/n) + text, binary, bytesize, non_sync, data = $`, !!$1, $2, !!$3, $' + bytesize = Integer bytesize, 10 + parts << RawText[text] unless text.empty? + parts << extract_literal(data, + binary: binary, + bytesize: bytesize, + non_sync: non_sync) + data[0, bytesize] = "" + end + parts << RawText[data] unless data.empty? + parts + end + + def self.extract_literal(data, binary:, bytesize:, non_sync:) + if data.bytesize < bytesize + raise DataFormatError, "Too few bytes in string for literal, " \ + "expected: %s, remaining: %s" % [bytesize, data.bytesize] + end + literal = data.byteslice(0, bytesize) + (binary ? Literal8 : Literal).new(data: literal, non_sync: non_sync) + end + private_class_method :extract_literal + end + + class Atom < CommandData # :nodoc: + def initialize(**) + super + validate + end + + def validate + data.to_s.ascii_only? \ + or raise DataFormatError, "#{self.class} must be ASCII only" + data.match?(ResponseParser::Patterns::ATOM_SPECIALS) \ + and raise DataFormatError, "#{self.class} must not contain atom-specials" + data.empty? \ + and raise DataFormatError, "#{self.class} must not be empty" + end + + def send_data(imap, tag) + imap.__send__(:put_string, data.to_s) + end + end + + class Flag < Atom # :nodoc: + def send_data(imap, tag) + imap.__send__(:put_string, "\\#{data}") + end + end + + # Represents a IMAP +quoted+ string, which can encode any valid ASCII or + # UTF-8 string, unless it contains any +CR+, +LF+, or +NULL+ bytes. + # + # NOTE: The current implementation does not verify that the connection + # supports UTF-8. Future versions may validate this. + class QuotedString < ValidNonLiteralData # :nodoc: + def formatted; %("#{data.gsub(/["\\]/, "\\\\\\&")}") end + end + + class Literal # :nodoc: + class << self + def new(_data = nil, _non_sync = nil, data: _data, non_sync: _non_sync) + super(data: data, non_sync: non_sync) + end + alias :[] :new + end + + attr_reader :data, :non_sync + + def to_h(&block) block ? to_h.to_h(&block) : { data: data, non_sync: non_sync } end + def ==(other) self.class === other && to_h == other.to_h end + def eql?(other) self.class === other && to_h.eql?(other.to_h) end + + def initialize(data:, non_sync: nil) + data = -String(data.to_str).b or + raise DataFormatError, "#{self.class} expects string input" + @data, @non_sync = data, non_sync + validate + freeze + end + + def self.validate(...) + data = new(...) + data.validate + data + end + + def bytesize; data.bytesize end + + def validate + if data.include?("\0") + raise DataFormatError, "NULL byte not allowed in #{self.class}. " \ + "Use #{Literal8} or a null-safe encoding." + end + end + + def send_data(imap, tag) + imap.__send__(:send_literal, data, tag, non_sync: non_sync) + end + end + + class Literal8 < Literal # :nodoc: + def validate; nil end # all bytes are okay + + def send_data(imap, tag) + imap.__send__(:send_binary_literal, data, tag, non_sync: non_sync) + end + end + + class MessageSet # :nodoc: + def send_data(imap, tag) + imap.__send__(:put_string, format_internal(@data)) + end + + def validate + validate_internal(@data) + end + + private + + def initialize(data) + @data = data + end + + def format_internal(data) + case data + when "*" + return data + when Integer + if data == -1 + return "*" + else + return data.to_s + end + when Range + return format_internal(data.first) + + ":" + format_internal(data.last) + when Array + return data.collect {|i| format_internal(i)}.join(",") + when ThreadMember + return data.seqno.to_s + + ":" + data.children.collect {|i| format_internal(i).join(",")} + end + end + + def validate_internal(data) + case data + when "*" + when Integer + NumValidator.ensure_nz_number(data) + when Range + when Array + data.each do |i| + validate_internal(i) + end + when ThreadMember + data.children.each do |i| + validate_internal(i) + end + else + raise DataFormatError, data.inspect + end + end + end + + class ClientID # :nodoc: + + def send_data(imap, tag) + imap.__send__(:send_data, format_internal(@data), tag) + end + + def validate + validate_internal(@data) + end + + private + + def initialize(data) + @data = data + end + + def validate_internal(client_id) + client_id.to_h.each do |k,v| + unless StringFormatter.valid_string?(k) + raise DataFormatError, client_id.inspect + end + end + rescue NoMethodError, TypeError # to_h failed + raise DataFormatError, client_id.inspect + end + + def format_internal(client_id) + return nil if client_id.nil? + client_id.to_h.flat_map {|k,v| + [StringFormatter.string(k), StringFormatter.nstring(v)] + } + end + + end + + module StringFormatter + + LITERAL_REGEX = /[\x80-\xff\r\n]/n + + module_function + + # Allows symbols in addition to strings + def valid_string?(str) + str.is_a?(Symbol) || str.respond_to?(:to_str) + end + + # Allows nil, symbols, and strings + def valid_nstring?(str) + str.nil? || valid_string?(str) + end + + # coerces using +to_s+ + def string(str) + str = str.to_s + if str =~ LITERAL_REGEX + Literal.new(str) + else + QuotedString.new(str) + end + end + + # coerces non-nil using +to_s+ + def nstring(str) + str.nil? ? nil : string(str) + end + + end + + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_accessors.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_accessors.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_accessors.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_accessors.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,75 @@ +# frozen_string_literal: true + +require "forwardable" + +module Net + class IMAP + class Config + # >>> + # *NOTE:* This module is an internal implementation detail, with no + # guarantee of backward compatibility. + # + # +attr_accessor+ values are stored in a struct rather than ivars, making + # it simpler to ensure that all config objects share a single object + # shape. This also simplifies iteration over all defined attributes. + module AttrAccessors + module Macros # :nodoc: internal API + def attr_accessor(name) AttrAccessors.attr_accessor(name) end + end + private_constant :Macros + + def self.included(mod) + mod.extend Macros + end + private_class_method :included + + extend Forwardable + + def self.attr_accessor(name) # :nodoc: internal API + name = name.to_sym + def_delegators :data, name, :"#{name}=" + end + + def self.attributes + instance_methods.grep(/=\z/).map { _1.to_s.delete_suffix("=").to_sym } + end + private_class_method :attributes + + def self.struct # :nodoc: internal API + unless defined?(self::Struct) + const_set :Struct, Struct.new(*attributes) + end + self::Struct + end + + def initialize # :notnew: + super() + @data = AttrAccessors.struct.new + end + + # Freezes the internal attributes struct, in addition to +self+. + def freeze + data.freeze + super + end + + protected + + attr_reader :data # :nodoc: internal API + + private + + def initialize_clone(other) + super + @data = other.data.clone + end + + def initialize_dup(other) + super + @data = other.data.dup + end + + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_inheritance.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_inheritance.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_inheritance.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_inheritance.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,90 @@ +# frozen_string_literal: true + +module Net + class IMAP + class Config + # >>> + # *NOTE:* The public methods on this module are part of the stable + # public API of Net::IMAP::Config. But the module itself is an internal + # implementation detail, with no guarantee of backward compatibility. + # + # +attr_accessor+ methods will delegate to their #parent when the local + # value does not contain an override. Inheritance forms a singly linked + # list, so lookup will be O(n) on the number of ancestors. In + # practice, the ancestor chain is not expected to be long. Without + # customization, it is only three deep: + # >>> + # IMAP#config → Config.global → Config.default + # + # When creating a client with the +config+ keyword, for example to use + # the appropriate defaults for an application or a library while still + # relying on global for configuration of +debug+ or +logger+, most likely + # the ancestor chain is still only four deep: + # >>> + # IMAP#config → alternate defaults → Config.global → Config.default + module AttrInheritance + INHERITED = Module.new.freeze + private_constant :INHERITED + + module Macros # :nodoc: internal API + def attr_accessor(name) super; AttrInheritance.attr_accessor(name) end + end + private_constant :Macros + + def self.included(mod) + mod.extend Macros + end + private_class_method :included + + def self.attr_accessor(name) # :nodoc: internal API + module_eval <<~RUBY, __FILE__, __LINE__ + 1 + def #{name}; (val = super) == INHERITED ? parent&.#{name} : val end + RUBY + end + + # The parent Config object + attr_reader :parent + + def initialize(parent = nil) # :notnew: + super() + @parent = Config[parent] + reset + end + + # Creates a new config, which inherits from +self+. + def new(**attrs) self.class.new(self, **attrs) end + + # Returns +true+ if +attr+ is inherited from #parent and not overridden + # by this config. + def inherited?(attr) data[attr] == INHERITED end + + # :call-seq: + # reset -> self + # reset(attr) -> attribute value + # + # Resets an +attr+ to inherit from the #parent config. + # + # When +attr+ is nil or not given, all attributes are reset. + def reset(attr = nil) + if attr.nil? + data.members.each do |attr| data[attr] = INHERITED end + self + elsif inherited?(attr) + nil + else + old, data[attr] = data[attr], INHERITED + old + end + end + + private + + def initialize_copy(other) + super + @parent ||= other # only default has nil parent + end + + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_type_coercion.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_type_coercion.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_type_coercion.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/config/attr_type_coercion.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,62 @@ +# frozen_string_literal: true + +module Net + class IMAP + class Config + # >>> + # *NOTE:* This module is an internal implementation detail, with no + # guarantee of backward compatibility. + # + # Adds a +type+ keyword parameter to +attr_accessor+, to enforce that + # config attributes have valid types, for example: boolean, numeric, + # enumeration, non-nullable, etc. + module AttrTypeCoercion + # :stopdoc: internal APIs only + + module Macros # :nodoc: internal API + def attr_accessor(attr, type: nil) + super(attr) + AttrTypeCoercion.attr_accessor(attr, type: type) + end + + module_function def Integer?; NilOrInteger end + end + private_constant :Macros + + def self.included(mod) + mod.extend Macros + end + private_class_method :included + + # Used in v0.5.8+ for Ractor sharability. + def self.safe(...) nil.instance_eval(...).freeze end + private_class_method :safe + + Types = Hash.new do |h, type| + type.nil? || Proc === type or raise TypeError, "type not nil or Proc" + safe{type} + end + Types[:boolean] = Boolean = safe{-> {!!_1}} + Types[Integer] = safe{->{Integer(_1)}} + + def self.attr_accessor(attr, type: nil) + type = Types[type] or return + define_method :"#{attr}=" do |val| super type[val] end + define_method :"#{attr}?" do send attr end if type == Boolean + end + + NilOrInteger = safe{->val { Integer val unless val.nil? }} + + Enum = ->(*enum) { + enum = safe{enum} + expected = -"one of #{enum.map(&:inspect).join(", ")}" + safe{->val { + return val if enum.include?(val) + raise ArgumentError, "expected %s, got %p" % [expected, val] + }} + } + + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/config.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/config.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/config.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/config.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,524 @@ +# frozen_string_literal: true + +require_relative "config/attr_accessors" +require_relative "config/attr_inheritance" +require_relative "config/attr_type_coercion" + +module Net + class IMAP + + # Net::IMAP::Config (available since +v0.4.13+) stores + # configuration options for Net::IMAP clients. The global configuration can + # be seen at either Net::IMAP.config or Net::IMAP::Config.global, and the + # client-specific configuration can be seen at Net::IMAP#config. + # + # When creating a new client, all unhandled keyword arguments to + # Net::IMAP.new are delegated to Config.new. Every client has its own + # config. + # + # debug_client = Net::IMAP.new(hostname, debug: true) + # quiet_client = Net::IMAP.new(hostname, debug: false) + # debug_client.config.debug? # => true + # quiet_client.config.debug? # => false + # + # == Inheritance + # + # Configs have a parent[rdoc-ref:Config::AttrInheritance#parent] config, and + # any attributes which have not been set locally will inherit the parent's + # value. Every client creates its own specific config. By default, client + # configs inherit from Config.global. + # + # plain_client = Net::IMAP.new(hostname) + # debug_client = Net::IMAP.new(hostname, debug: true) + # quiet_client = Net::IMAP.new(hostname, debug: false) + # + # plain_client.config.inherited?(:debug) # => true + # debug_client.config.inherited?(:debug) # => false + # quiet_client.config.inherited?(:debug) # => false + # + # plain_client.config.debug? # => false + # debug_client.config.debug? # => true + # quiet_client.config.debug? # => false + # + # # Net::IMAP.debug is delegated to Net::IMAP::Config.global.debug + # Net::IMAP.debug = true + # plain_client.config.debug? # => true + # debug_client.config.debug? # => true + # quiet_client.config.debug? # => false + # + # Net::IMAP.debug = false + # plain_client.config.debug = true + # plain_client.config.inherited?(:debug) # => false + # plain_client.config.debug? # => true + # plain_client.config.reset(:debug) + # plain_client.config.inherited?(:debug) # => true + # plain_client.config.debug? # => false + # + # == Versioned defaults + # + # The effective default configuration for a specific +x.y+ version of + # +net-imap+ can be loaded with the +config+ keyword argument to + # Net::IMAP.new. Requesting default configurations for previous versions + # enables extra backward compatibility with those versions: + # + # client = Net::IMAP.new(hostname, config: 0.3) + # client.config.sasl_ir # => false + # client.config.responses_without_block # => :silence_deprecation_warning + # + # client = Net::IMAP.new(hostname, config: 0.4) + # client.config.sasl_ir # => true + # client.config.responses_without_block # => :silence_deprecation_warning + # + # client = Net::IMAP.new(hostname, config: 0.5) + # client.config.sasl_ir # => true + # client.config.responses_without_block # => :warn + # + # client = Net::IMAP.new(hostname, config: :future) + # client.config.sasl_ir # => true + # client.config.responses_without_block # => :raise + # + # The versioned default configs inherit certain specific config options from + # Config.global, for example #debug: + # + # client = Net::IMAP.new(hostname, config: 0.4) + # Net::IMAP.debug = false + # client.config.debug? # => false + # + # Net::IMAP.debug = true + # client.config.debug? # => true + # + # Use #load_defaults to globally behave like a specific version: + # client = Net::IMAP.new(hostname) + # client.config.sasl_ir # => true + # Net::IMAP.config.load_defaults 0.3 + # client.config.sasl_ir # => false + # + # === Named defaults + # In addition to +x.y+ version numbers, the following aliases are supported: + # + # [+:default+] + # An alias for +:current+. + # + # >>> + # *NOTE*: This is _not_ the same as Config.default. It inherits some + # attributes from Config.global, for example: #debug. + # [+:current+] + # An alias for the current +x.y+ version's defaults. + # [+:next+] + # The _planned_ config for the next +x.y+ version. + # [+:future+] + # The _planned_ eventual config for some future +x.y+ version. + # + # For example, to raise exceptions for all current deprecations: + # client = Net::IMAP.new(hostname, config: :future) + # client.responses # raises an ArgumentError + # + # == Thread Safety + # + # *NOTE:* Updates to config objects are not synchronized for thread-safety. + # + class Config + # Array of attribute names that are _not_ loaded by #load_defaults. + DEFAULT_TO_INHERIT = %i[debug].freeze + private_constant :DEFAULT_TO_INHERIT + + # The default config, which is hardcoded and frozen. + def self.default; @default end + + # The global config object. Also available from Net::IMAP.config. + def self.global; @global if defined?(@global) end + + # A hash of hard-coded configurations, indexed by version number or name. + # Values can be accessed with any object that responds to +to_sym+ or + # +to_r+/+to_f+ with a non-zero number. + # + # Config::[] gets named or numbered versions from this hash. + # + # For example: + # Net::IMAP::Config.version_defaults[0.5] == Net::IMAP::Config[0.5] + # Net::IMAP::Config[0.5] == Net::IMAP::Config[0.5r] # => true + # Net::IMAP::Config["current"] == Net::IMAP::Config[:current] # => true + # Net::IMAP::Config["0.5.6"] == Net::IMAP::Config[0.5r] # => true + def self.version_defaults; @version_defaults end + @version_defaults = Hash.new {|h, k| + # NOTE: String responds to both so the order is significant. + # And ignore non-numeric conversion to zero, because: "wat!?".to_r == 0 + (h.fetch(k.to_r, nil) || h.fetch(k.to_f, nil) if k.is_a?(Numeric)) || + (h.fetch(k.to_sym, nil) if k.respond_to?(:to_sym)) || + (h.fetch(k.to_r, nil) if k.respond_to?(:to_r) && k.to_r != 0r) || + (h.fetch(k.to_f, nil) if k.respond_to?(:to_f) && k.to_f != 0.0) + } + + # :call-seq: + # Net::IMAP::Config[number] -> versioned config + # Net::IMAP::Config[symbol] -> named config + # Net::IMAP::Config[hash] -> new frozen config + # Net::IMAP::Config[config] -> same config + # + # Given a version number, returns the default configuration for the target + # version. See Config@Versioned+defaults. + # + # Given a version name, returns the default configuration for the target + # version. See Config@Named+defaults. + # + # Given a Hash, creates a new _frozen_ config which inherits from + # Config.global. Use Config.new for an unfrozen config. + # + # Given a config, returns that same config. + def self.[](config) + if config.is_a?(Config) then config + elsif config.nil? && global.nil? then nil + elsif config.respond_to?(:to_hash) then new(global, **config).freeze + else + version_defaults[config] or + case config + when Numeric + raise RangeError, "unknown config version: %p" % [config] + when String, Symbol + raise KeyError, "unknown config name: %p" % [config] + else + raise TypeError, "no implicit conversion of %s to %s" % [ + config.class, Config + ] + end + end + end + + include AttrAccessors + include AttrInheritance + include AttrTypeCoercion + + # The debug mode (boolean). The default value is +false+. + # + # When #debug is +true+: + # * Data sent to and received from the server will be logged. + # * ResponseParser will print warnings with extra detail for parse + # errors. _This may include recoverable errors._ + # * ResponseParser makes extra assertions. + # + # *NOTE:* Versioned default configs inherit #debug from Config.global, and + # #load_defaults will not override #debug. + attr_accessor :debug, type: :boolean + + # method: debug? + # :call-seq: debug? -> boolean + # + # Alias for #debug + + # Seconds to wait until a connection is opened. + # + # Applied separately for establishing TCP connection and starting a TLS + # connection. + # + # If the IMAP object cannot open a connection within this time, + # it raises a Net::OpenTimeout exception. + # + # See Net::IMAP.new and Net::IMAP#starttls. + # + # The default value is +30+ seconds. + attr_accessor :open_timeout, type: Integer + + # Seconds to wait until an IDLE response is received, after + # the client asks to leave the IDLE state. + # + # See Net::IMAP#idle and Net::IMAP#idle_done. + # + # The default value is +5+ seconds. + attr_accessor :idle_response_timeout, type: Integer + + # Whether to use the +SASL-IR+ extension when the server and \SASL + # mechanism both support it. Can be overridden by the +sasl_ir+ keyword + # parameter to Net::IMAP#authenticate. + # + # (Support for +SASL-IR+ was added in +v0.4.0+.) + # + # ==== Valid options + # + # [+false+ (original behavior, before support was added)] + # Do not use +SASL-IR+, even when it is supported by the server and the + # mechanism. + # + # [+true+ (default since +v0.4+)] + # Use +SASL-IR+ when it is supported by the server and the mechanism. + attr_accessor :sasl_ir, type: :boolean + + # The maximum allowed server response size. When +nil+, there is no limit + # on response size. + # + # The default value (512 MiB, since +v0.5.7+) is very high and + # unlikely to be reached. To use a lower limit, fetch message bodies in + # chunks rather than all at once. A _much_ lower value should be used + # with untrusted servers (for example, when connecting to a user-provided + # hostname). + # + # Please Note: this only limits the size per response. It does + # not prevent a flood of individual responses and it does not limit how + # many unhandled responses may be stored on the responses hash. See + # Net::IMAP@Unbounded+memory+use. + # + # Socket reads are limited to the maximum remaining bytes for the current + # response: max_response_size minus the bytes that have already been read. + # When the limit is reached, or reading a +literal+ _would_ go over the + # limit, ResponseTooLargeError is raised and the connection is closed. + # See also #socket_read_limit. + # + # Note that changes will not take effect immediately, because the receiver + # thread may already be waiting for the next response using the previous + # value. Net::IMAP#noop can force a response and enforce the new setting + # immediately. + # + # ==== Versioned Defaults + # + # Net::IMAP#max_response_size was added in +v0.2.5+ and +v0.3.9+ as an + # attr_accessor, and in +v0.4.20+ and +v0.5.7+ as a delegator to this + # config attribute. + # + # * original: +nil+ (no limit) + # * +0.5+: 512 MiB + attr_accessor :max_response_size, type: Integer? + + # Controls the behavior of Net::IMAP#responses when called without any + # arguments (+type+ or +block+). + # + # ==== Valid options + # + # [+:silence_deprecation_warning+ (original behavior)] + # Returns the mutable responses hash (without any warnings). + # This is not thread-safe. + # + # [+:warn+ (default since +v0.5+)] + # Prints a warning and returns the mutable responses hash. + # This is not thread-safe. + # + # [+:frozen_dup+ (planned default for +v0.6+)] + # Returns a frozen copy of the unhandled responses hash, with frozen + # array values. + # + # Note that calling IMAP#responses with a +type+ and without a block is + # not configurable and always behaves like +:frozen_dup+. + # + # (+:frozen_dup+ config option was added in +v0.4.17+) + # + # [+:raise+] + # Raise an ArgumentError with the deprecation warning. + # + # Note: #responses_without_args is an alias for #responses_without_block. + attr_accessor :responses_without_block, type: Enum[ + :silence_deprecation_warning, :warn, :frozen_dup, :raise, + ] + + alias responses_without_args responses_without_block # :nodoc: + alias responses_without_args= responses_without_block= # :nodoc: + + ## + # :attr_accessor: responses_without_args + # + # Alias for responses_without_block + + # Whether ResponseParser should use the deprecated UIDPlusData or + # CopyUIDData for +COPYUID+ response codes, and UIDPlusData or + # AppendUIDData for +APPENDUID+ response codes. + # + # UIDPlusData stores its data in arrays of numbers, which is vulnerable to + # a memory exhaustion denial of service attack from an untrusted or + # compromised server. Set this option to +false+ to completely block this + # vulnerability. Otherwise, parser_max_deprecated_uidplus_data_size + # mitigates this vulnerability. + # + # AppendUIDData and CopyUIDData are _mostly_ backward-compatible with + # UIDPlusData. Most applications should be able to upgrade with little + # or no changes. + # + # (Parser support for +UIDPLUS+ added in +v0.3.2+.) + # + # (Config option added in +v0.4.19+ and +v0.5.6+.) + # + # UIDPlusData will be removed in +v0.6+ and this config setting will + # be ignored. + # + # ==== Valid options + # + # [+true+ (original default)] + # ResponseParser only uses UIDPlusData. + # + # [+:up_to_max_size+ (default since +v0.5.6+)] + # ResponseParser uses UIDPlusData when the +uid-set+ size is below + # parser_max_deprecated_uidplus_data_size. Above that size, + # ResponseParser uses AppendUIDData or CopyUIDData. + # + # [+false+ (planned default for +v0.6+)] + # ResponseParser _only_ uses AppendUIDData and CopyUIDData. + attr_accessor :parser_use_deprecated_uidplus_data, type: Enum[ + true, :up_to_max_size, false + ] + + # The maximum +uid-set+ size that ResponseParser will parse into + # deprecated UIDPlusData. This limit only applies when + # parser_use_deprecated_uidplus_data is not +false+. + # + # (Parser support for +UIDPLUS+ added in +v0.3.2+.) + # + # Support for limiting UIDPlusData to a maximum size was added in + # +v0.3.8+, +v0.4.19+, and +v0.5.6+. + # + # UIDPlusData will be removed in +v0.6+. + # + # ==== Versioned Defaults + # + # Because this limit guards against a remote server causing catastrophic + # memory exhaustion, the versioned default (used by #load_defaults) also + # applies to versions without the feature. + # + # * +0.3+ and prior: 10,000 + # * +0.4+: 1,000 + # * +0.5+: 100 + # * +0.6+: 0 + # + attr_accessor :parser_max_deprecated_uidplus_data_size, type: Integer + + # Creates a new config object and initialize its attribute with +attrs+. + # + # If +parent+ is not given, the global config is used by default. + # + # If a block is given, the new config object is yielded to it. + def initialize(parent = Config.global, **attrs) + super(parent) + update(**attrs) + yield self if block_given? + end + + # :call-seq: update(**attrs) -> self + # + # Assigns all of the provided +attrs+ to this config, and returns +self+. + # + # An ArgumentError is raised unless every key in +attrs+ matches an + # assignment method on Config. + # + # >>> + # *NOTE:* #update is not atomic. If an exception is raised due to an + # invalid attribute value, +attrs+ may be partially applied. + def update(**attrs) + unless (bad = attrs.keys.reject { respond_to?(:"#{_1}=") }).empty? + raise ArgumentError, "invalid config options: #{bad.join(", ")}" + end + attrs.each do send(:"#{_1}=", _2) end + self + end + + # :call-seq: + # with(**attrs) -> config + # with(**attrs) {|config| } -> result + # + # Without a block, returns a new config which inherits from self. With a + # block, yields the new config and returns the block's result. + # + # If no keyword arguments are given, an ArgumentError will be raised. + # + # If +self+ is frozen, the copy will also be frozen. + def with(**attrs) + attrs.empty? and + raise ArgumentError, "expected keyword arguments, none given" + copy = new(**attrs) + copy.freeze if frozen? + block_given? ? yield(copy) : copy + end + + # :call-seq: load_defaults(version) -> self + # + # Resets the current config to behave like the versioned default + # configuration for +version+. #parent will not be changed. + # + # Some config attributes default to inheriting from their #parent (which + # is usually Config.global) and are left unchanged, for example: #debug. + # + # See Config@Versioned+defaults and Config@Named+defaults. + def load_defaults(version) + [Numeric, Symbol, String].any? { _1 === version } or + raise ArgumentError, "expected number or symbol, got %p" % [version] + update(**Config[version].defaults_hash) + end + + # :call-seq: to_h -> hash + # + # Returns all config attributes in a hash. + def to_h; data.members.to_h { [_1, send(_1)] } end + + protected + + def defaults_hash + to_h.reject {|k,v| DEFAULT_TO_INHERIT.include?(k) } + end + + @default = new( + debug: false, + open_timeout: 30, + idle_response_timeout: 5, + sasl_ir: true, + max_response_size: nil, + responses_without_block: :silence_deprecation_warning, + parser_use_deprecated_uidplus_data: true, + parser_max_deprecated_uidplus_data_size: 1000, + ).freeze + + @global = default.new + + version_defaults[:default] = Config[default.send(:defaults_hash)] + + version_defaults[0r] = Config[:default].dup.update( + sasl_ir: false, + max_response_size: nil, + parser_use_deprecated_uidplus_data: true, + parser_max_deprecated_uidplus_data_size: 10_000, + ).freeze + version_defaults[0.0r] = Config[0r] + version_defaults[0.1r] = Config[0r] + version_defaults[0.2r] = Config[0r] + version_defaults[0.3r] = Config[0r] + + version_defaults[0.4r] = Config[0.3r].dup.update( + sasl_ir: true, + parser_max_deprecated_uidplus_data_size: 1000, + ).freeze + + version_defaults[0.5r] = Config[0.4r].dup.update( + max_response_size: 512 << 20, # 512 MiB + responses_without_block: :warn, + parser_use_deprecated_uidplus_data: :up_to_max_size, + parser_max_deprecated_uidplus_data_size: 100, + ).freeze + + version_defaults[0.6r] = Config[0.5r].dup.update( + responses_without_block: :frozen_dup, + parser_use_deprecated_uidplus_data: false, + parser_max_deprecated_uidplus_data_size: 0, + ).freeze + + version_defaults[0.7r] = Config[0.6r].dup.update( + ).freeze + + # Safe conversions one way only: + # 0.6r.to_f == 0.6 # => true + # 0.6 .to_r == 0.6r # => false + version_defaults.to_a.each do |k, v| + next unless k.is_a? Rational + version_defaults[k.to_f] = v + end + + current = VERSION.to_r + version_defaults[:original] = Config[0] + version_defaults[:current] = Config[current] + version_defaults[:next] = Config[current + 0.1r] + + version_defaults[:future] = Config[0.7r] + + version_defaults.freeze + + if ($VERBOSE || $DEBUG) && self[:current].to_h != self[:default].to_h + warn "Misconfigured Net::IMAP::Config[:current] => %p,\n" \ + " not equal to Net::IMAP::Config[:default] => %p" % [ + self[:current].to_h, self[:default].to_h + ] + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/data_encoding.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/data_encoding.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/data_encoding.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/data_encoding.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,214 @@ +# frozen_string_literal: true + +require "date" +require "time" + +require_relative "errors" + +module Net + class IMAP < Protocol + + # strftime/strptime format for an IMAP4 +date+, excluding optional dquotes. + # Use via the encode_date and decode_date methods. + # + # date = date-text / DQUOTE date-text DQUOTE + # date-text = date-day "-" date-month "-" date-year + # + # date-day = 1*2DIGIT + # ; Day of month + # date-month = "Jan" / "Feb" / "Mar" / "Apr" / "May" / "Jun" / + # "Jul" / "Aug" / "Sep" / "Oct" / "Nov" / "Dec" + # date-year = 4DIGIT + STRFDATE = "%d-%b-%Y" + + # strftime/strptime format for an IMAP4 +date-time+, including dquotes. + # See the encode_datetime and decode_datetime methods. + # + # date-time = DQUOTE date-day-fixed "-" date-month "-" date-year + # SP time SP zone DQUOTE + # + # date-day-fixed = (SP DIGIT) / 2DIGIT + # ; Fixed-format version of date-day + # date-month = "Jan" / "Feb" / "Mar" / "Apr" / "May" / "Jun" / + # "Jul" / "Aug" / "Sep" / "Oct" / "Nov" / "Dec" + # date-year = 4DIGIT + # time = 2DIGIT ":" 2DIGIT ":" 2DIGIT + # ; Hours minutes seconds + # zone = ("+" / "-") 4DIGIT + # ; Signed four-digit value of hhmm representing + # ; hours and minutes east of Greenwich (that is, + # ; the amount that the given time differs from + # ; Universal Time). Subtracting the timezone + # ; from the given time will give the UT form. + # ; The Universal Time zone is "+0000". + # + # Note that Time.strptime "%d" flexibly parses either space or zero + # padding. However, the DQUOTEs are *not* optional. + STRFTIME = '"%d-%b-%Y %H:%M:%S %z"' + + # Decode a string from modified UTF-7 format to UTF-8. + # + # UTF-7 is a 7-bit encoding of Unicode [UTF7]. IMAP uses a + # slightly modified version of this to encode mailbox names + # containing non-ASCII characters; see [IMAP] section 5.1.3. + # + # Net::IMAP does _not_ automatically encode and decode + # mailbox names to and from UTF-7. + def self.decode_utf7(s) + return s.gsub(/&([A-Za-z0-9+,]+)?-/n) { + if base64 = $1 + (base64.tr(",", "/") + "===").unpack1("m").encode(Encoding::UTF_8, Encoding::UTF_16BE) + else + "&" + end + } + end + + # Encode a string from UTF-8 format to modified UTF-7. + def self.encode_utf7(s) + return s.gsub(/(&)|[^\x20-\x7e]+/) { + if $1 + "&-" + else + base64 = [$&.encode(Encoding::UTF_16BE)].pack("m0") + "&" + base64.delete("=").tr("/", ",") + "-" + end + }.force_encoding("ASCII-8BIT") + end + + # Formats +time+ as an IMAP4 date. + def self.encode_date(date) + date.to_date.strftime STRFDATE + end + + # :call-seq: decode_date(string) -> Date + # + # Decodes +string+ as an IMAP formatted "date". + # + # Double quotes are optional. Day of month may be padded with zero or + # space. See STRFDATE. + def self.decode_date(string) + string = string.delete_prefix('"').delete_suffix('"') + Date.strptime(string, STRFDATE) + end + + # :call-seq: encode_datetime(time) -> string + # + # Formats +time+ as an IMAP4 date-time. + def self.encode_datetime(time) + time.to_datetime.strftime STRFTIME + end + + # :call-seq: decode_datetime(string) -> DateTime + # + # Decodes +string+ as an IMAP4 formatted "date-time". + # + # NOTE: Although double-quotes are not optional in the IMAP grammar, + # Net::IMAP currently parses "date-time" values as "quoted" strings and this + # removes the quotation marks. To be useful for strings which have already + # been parsed as a quoted string, this method makes double-quotes optional. + # + # See STRFTIME. + def self.decode_datetime(string) + unless string.start_with?(?") && string.end_with?(?") + string = '"%s"' % [string] + end + DateTime.strptime(string, STRFTIME) + end + + # :call-seq: decode_time(string) -> Time + # + # Decodes +string+ as an IMAP4 formatted "date-time". + # + # Same as +decode_datetime+, but returning a Time instead. + def self.decode_time(string) + unless string.start_with?(?") && string.end_with?(?") + string = '"%s"' % [string] + end + Time.strptime(string, STRFTIME) + end + + class << self + alias encode_time encode_datetime + alias format_date encode_date + alias format_time encode_time + alias parse_date decode_date + alias parse_datetime decode_datetime + alias parse_time decode_time + + # alias format_datetime encode_datetime # n.b: this is overridden below... + end + + # DEPRECATED:: The original version returned incorrectly formatted strings. + # Strings returned by encode_datetime or format_time use the + # correct IMAP4rev1 syntax for "date-time". + # + # This invalid format has been temporarily retained for backward + # compatibility. A future release will change this method to return the + # correct format. + def self.format_datetime(time) + warn("#{self}.format_datetime incorrectly formats IMAP date-time. " \ + "Convert to #{self}.encode_datetime or #{self}.format_time instead.", + uplevel: 1, category: :deprecated) + time.strftime("%d-%b-%Y %H:%M %z") + end + + # Common validators of number and nz_number types + module NumValidator # :nodoc + module_function + + # Check is passed argument valid 'number' in RFC 3501 terminology + def valid_number?(num) + # [RFC 3501] + # number = 1*DIGIT + # ; Unsigned 32-bit integer + # ; (0 <= n < 4,294,967,296) + num >= 0 && num < 4294967296 + end + + # Check is passed argument valid 'nz_number' in RFC 3501 terminology + def valid_nz_number?(num) + # [RFC 3501] + # nz-number = digit-nz *DIGIT + # ; Non-zero unsigned 32-bit integer + # ; (0 < n < 4,294,967,296) + num != 0 && valid_number?(num) + end + + # Check is passed argument valid 'mod_sequence_value' in RFC 4551 terminology + def valid_mod_sequence_value?(num) + # mod-sequence-value = 1*DIGIT + # ; Positive unsigned 64-bit integer + # ; (mod-sequence) + # ; (1 <= n < 18,446,744,073,709,551,615) + num >= 1 && num < 18446744073709551615 + end + + # Ensure argument is 'number' or raise DataFormatError + def ensure_number(num) + return if valid_number?(num) + + msg = "number must be unsigned 32-bit integer: #{num}" + raise DataFormatError, msg + end + + # Ensure argument is 'nz_number' or raise DataFormatError + def ensure_nz_number(num) + return if valid_nz_number?(num) + + msg = "nz_number must be non-zero unsigned 32-bit integer: #{num}" + raise DataFormatError, msg + end + + # Ensure argument is 'mod_sequence_value' or raise DataFormatError + def ensure_mod_sequence_value(num) + return if valid_mod_sequence_value?(num) + + msg = "mod_sequence_value must be unsigned 64-bit integer: #{num}" + raise DataFormatError, msg + end + + end + + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/deprecated_client_options.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/deprecated_client_options.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/deprecated_client_options.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/deprecated_client_options.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,139 @@ +# frozen_string_literal: true + +module Net + class IMAP < Protocol + + # This module handles deprecated arguments to various Net::IMAP methods. + module DeprecatedClientOptions + + # :call-seq: + # Net::IMAP.new(host, **options) # standard keyword options + # Net::IMAP.new(host, options) # obsolete hash options + # Net::IMAP.new(host, port) # obsolete port argument + # Net::IMAP.new(host, port, usessl, certs = nil, verify = true) # deprecated SSL arguments + # + # Translates Net::IMAP.new arguments for backward compatibility. + # + # ==== Obsolete arguments + # + # Use of obsolete arguments does not print a warning. Obsolete arguments + # will be deprecated by a future release. + # + # If a second positional argument is given and it is a hash (or is + # convertible via +#to_hash+), it is converted to keyword arguments. + # + # # Obsolete: + # Net::IMAP.new("imap.example.com", options_hash) + # # Use instead: + # Net::IMAP.new("imap.example.com", **options_hash) + # + # If a second positional argument is given and it is not a hash, it is + # converted to the +port+ keyword argument. + # # Obsolete: + # Net::IMAP.new("imap.example.com", 114433) + # # Use instead: + # Net::IMAP.new("imap.example.com", port: 114433) + # + # ==== Deprecated arguments + # + # Using deprecated arguments prints a warning. Convert to keyword + # arguments to avoid the warning. Deprecated arguments will be removed in + # a future release. + # + # If +usessl+ is false, +certs+, and +verify+ are ignored. When it true, + # all three arguments are converted to the +ssl+ keyword argument. + # Without +certs+ or +verify+, it is converted to ssl: true. + # # DEPRECATED: + # Net::IMAP.new("imap.example.com", nil, true) # => prints a warning + # # Use instead: + # Net::IMAP.new("imap.example.com", ssl: true) + # + # When +certs+ is a path to a directory, it is converted to ca_path: + # certs. + # # DEPRECATED: + # Net::IMAP.new("imap.example.com", nil, true, "/path/to/certs") # => prints a warning + # # Use instead: + # Net::IMAP.new("imap.example.com", ssl: {ca_path: "/path/to/certs"}) + # + # When +certs+ is a path to a file, it is converted to ca_file: + # certs. + # # DEPRECATED: + # Net::IMAP.new("imap.example.com", nil, true, "/path/to/cert.pem") # => prints a warning + # # Use instead: + # Net::IMAP.new("imap.example.com", ssl: {ca_file: "/path/to/cert.pem"}) + # + # When +verify+ is +false+, it is converted to verify_mode: + # OpenSSL::SSL::VERIFY_NONE. + # # DEPRECATED: + # Net::IMAP.new("imap.example.com", nil, true, nil, false) # => prints a warning + # # Use instead: + # Net::IMAP.new("imap.example.com", ssl: {verify_mode: OpenSSL::SSL::VERIFY_NONE}) + # + def initialize(host, port_or_options = nil, *deprecated, **options) + if port_or_options.nil? && deprecated.empty? + super host, **options + elsif options.any? + # Net::IMAP.new(host, *__invalid__, **options) + raise ArgumentError, "Do not combine deprecated and keyword arguments" + elsif port_or_options.respond_to?(:to_hash) and deprecated.any? + # Net::IMAP.new(host, options, *__invalid__) + raise ArgumentError, "Do not use deprecated SSL params with options hash" + elsif port_or_options.respond_to?(:to_hash) + super host, **Hash.try_convert(port_or_options) + elsif deprecated.empty? + super host, port: port_or_options + elsif deprecated.shift + warn "DEPRECATED: Call Net::IMAP.new with keyword options", uplevel: 1 + super host, port: port_or_options, ssl: create_ssl_params(*deprecated) + else + warn "DEPRECATED: Call Net::IMAP.new with keyword options", uplevel: 1 + super host, port: port_or_options, ssl: false + end + end + + # :call-seq: + # starttls(**options) # standard + # starttls(options = {}) # obsolete + # starttls(certs = nil, verify = true) # deprecated + # + # Translates Net::IMAP#starttls arguments for backward compatibility. + # + # Support for +certs+ and +verify+ will be dropped in a future release. + # + # See ::new for interpretation of +certs+ and +verify+. + def starttls(*deprecated, **options) + if deprecated.empty? + super(**options) + elsif options.any? + # starttls(*__invalid__, **options) + raise ArgumentError, "Do not combine deprecated and keyword options" + elsif deprecated.first.respond_to?(:to_hash) && deprecated.length > 1 + # starttls(*__invalid__, **options) + raise ArgumentError, "Do not use deprecated verify param with options hash" + elsif deprecated.first.respond_to?(:to_hash) + super(**Hash.try_convert(deprecated.first)) + else + warn "DEPRECATED: Call Net::IMAP#starttls with keyword options", uplevel: 1 + super(**create_ssl_params(*deprecated)) + end + end + + private + + def create_ssl_params(certs = nil, verify = true) + params = {} + if certs + if File.file?(certs) + params[:ca_file] = certs + elsif File.directory?(certs) + params[:ca_path] = certs + end + end + params[:verify_mode] = + verify ? OpenSSL::SSL::VERIFY_PEER : OpenSSL::SSL::VERIFY_NONE + params + end + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/errors.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/errors.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/errors.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/errors.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,112 @@ +# frozen_string_literal: true + +module Net + class IMAP < Protocol + + # Superclass of IMAP errors. + class Error < StandardError + end + + # Error raised when data is in the incorrect format. + class DataFormatError < Error + end + + # Error raised when the socket cannot be read, due to a Config limit. + class ResponseReadError < Error + end + + # Error raised when a response is larger than IMAP#max_response_size. + class ResponseTooLargeError < ResponseReadError + attr_reader :bytes_read, :literal_size + attr_reader :max_response_size + + def initialize(msg = nil, *args, + bytes_read: nil, + literal_size: nil, + max_response_size: nil, + **kwargs) + @bytes_read = bytes_read + @literal_size = literal_size + @max_response_size = max_response_size + msg ||= [ + "Response size", response_size_msg, "exceeds max_response_size", + max_response_size && "(#{max_response_size}B)", + ].compact.join(" ") + super(msg, *args, **kwargs) + end + + private + + def response_size_msg + if bytes_read && literal_size + "(#{bytes_read}B read + #{literal_size}B literal)" + end + end + end + + # Error raised when a response from the server is non-parsable. + class ResponseParseError < Error + end + + # Superclass of all errors used to encapsulate "fail" responses + # from the server. + class ResponseError < Error + + # The response that caused this error + attr_accessor :response + + def initialize(response) + @response = response + + super @response.data.text + end + + end + + # Error raised upon a "NO" response from the server, indicating + # that the client command could not be completed successfully. + class NoResponseError < ResponseError + end + + # Error raised upon a "BAD" response from the server, indicating + # that the client command violated the IMAP protocol, or an internal + # server failure has occurred. + class BadResponseError < ResponseError + end + + # Error raised upon a "BYE" response from the server, indicating + # that the client is not being allowed to login, or has been timed + # out due to inactivity. + class ByeResponseError < ResponseError + end + + # Error raised when the server sends an invalid response. + # + # This is different from UnknownResponseError: the response has been + # rejected. Although it may be parsable, the server is forbidden from + # sending it in the current context. The client should automatically + # disconnect, abruptly (without logout). + # + # Note that InvalidResponseError does not inherit from ResponseError: it + # can be raised before the response is fully parsed. A related + # ResponseParseError or ResponseError may be the #cause. + class InvalidResponseError < Error + end + + # Error raised upon an unknown response from the server. + # + # This is different from InvalidResponseError: the response may be a + # valid extension response and the server may be allowed to send it in + # this context, but Net::IMAP either does not know how to parse it or + # how to handle it. This could result from enabling unknown or + # unhandled extensions. The connection may still be usable, + # but—depending on context—it may be prudent to disconnect. + class UnknownResponseError < ResponseError + end + + RESPONSE_ERRORS = Hash.new(ResponseError) # :nodoc: + RESPONSE_ERRORS["NO"] = NoResponseError + RESPONSE_ERRORS["BAD"] = BadResponseError + + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/fetch_data.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/fetch_data.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/fetch_data.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/fetch_data.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,518 @@ +# frozen_string_literal: true + +module Net + class IMAP < Protocol + + # Net::IMAP::FetchData represents the contents of a FETCH response. + # Net::IMAP#fetch and Net::IMAP#uid_fetch both return an array of + # FetchData objects. + # + # === Fetch attributes + # + # See {[IMAP4rev1 §7.4.2]}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2] + # and {[IMAP4rev2 §7.5.2]}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2] + # for a full description of the standard fetch response data items, and + # Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. + # + # ==== Static fetch data items + # + # Most message attributes are static, and must never change for a given + # (server, account, mailbox, UIDVALIDITY, UID) tuple. + # + # The static fetch data items defined by both + # IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] and + # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] are: + # + # * "UID" --- See #uid. + # * "BODY" --- See #body. + # * "BODY[#{section_spec}]", + # "BODY[#{section_spec}]<#{offset}>" --- See #message, + # #part, #header, #header_fields, #header_fields_not, #mime, and #text. + # * "BODYSTRUCTURE" --- See #bodystructure. + # * "ENVELOPE" --- See #envelope. + # * "INTERNALDATE" --- See #internaldate. + # * "RFC822.SIZE" --- See #rfc822_size. + # + # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] adds the + # additional fetch items from the +BINARY+ extension + # {[RFC3516]}[https://www.rfc-editor.org/rfc/rfc3516.html]: + # + # * "BINARY[#{part}]", + # "BINARY[#{part}]<#{offset}>" -- See #binary. + # * "BINARY.SIZE[#{part}]" -- See #binary_size. + # + # Several static message attributes in + # IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] are obsolete and + # been removed from + # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html]: + # + # * "RFC822" --- See #rfc822 or replace with + # "BODY[]" and #message. + # * "RFC822.HEADER" --- See #rfc822_header or replace with + # "BODY[HEADER]" and #header. + # * "RFC822.TEXT" --- See #rfc822_text or replace with + # "BODY[TEXT]" and #text. + # + # Net::IMAP supports static attributes defined by the following extensions: + # * +OBJECTID+ {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html] + # * "EMAILID" --- See #emailid. + # * "THREADID" --- See #threadid. + # + # * +X-GM-EXT-1+ {[non-standard Gmail + # extension]}[https://developers.google.com/gmail/imap/imap-extensions] + # * "X-GM-MSGID" --- unique message ID. Access via #attr. + # * "X-GM-THRID" --- Thread ID. Access via #attr. + # + # [Note:] + # >>> + # Additional static fields are defined in other \IMAP extensions, but + # Net::IMAP can't parse them yet. + # + # ==== Dynamic message attributes + # + # Some message attributes can be dynamically changed, for example using the + # {STORE command}[rdoc-ref:Net::IMAP#store]. + # + # The only dynamic message attribute defined by + # IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] and + # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] is: + # + # * "FLAGS" --- See #flags. + # + # Net::IMAP supports dynamic attributes defined by the following extensions: + # + # * +CONDSTORE+ {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]: + # * "MODSEQ" --- See #modseq. + # * +X-GM-EXT-1+ {[non-standard Gmail + # extension]}[https://developers.google.com/gmail/imap/imap-extensions] + # * "X-GM-LABELS" --- Gmail labels. Access via #attr. + # + # [Note:] + # >>> + # Additional dynamic fields are defined in other \IMAP extensions, but + # Net::IMAP can't parse them yet. + # + # === Implicitly setting \Seen and using +PEEK+ + # + # Unless the mailbox is has been opened as read-only, fetching + # BODY[#{section}] or BINARY[#{section}] + # will implicitly set the \Seen flag. To avoid this, fetch using + # BODY.PEEK[#{section}] or BINARY.PEEK[#{section}] + # instead. + # + # Note that the data will always be _returned_ without ".PEEK", in + # BODY[#{specifier}] or BINARY[#{section}]. + # + class FetchData < Struct.new(:seqno, :attr) + ## + # method: seqno + # :call-seq: seqno -> Integer + # + # The message sequence number. + # + # [Note] + # This is never the unique identifier (UID), not even for the + # Net::IMAP#uid_fetch result. The UID is available from #uid, if it was + # returned. + + ## + # method: attr + # :call-seq: attr -> hash + # + # Each key specifies a message attribute, and the value is the + # corresponding data item. Standard data items have corresponding + # accessor methods. The definitions of each attribute type is documented + # on its accessor. + # + # >>> + # *Note:* #seqno is not a message attribute. + + # :call-seq: attr_upcase -> hash + # + # A transformation of #attr, with all the keys converted to upper case. + # + # Header field names are case-preserved but not case-sensitive, so this is + # used by #header_fields and #header_fields_not. + def attr_upcase; attr.transform_keys(&:upcase) end + + # :call-seq: + # body -> body structure or nil + # + # Returns an alternate form of #bodystructure, without any extension data. + # + # This is the same as getting the value for "BODY" from #attr. + # + # [Note] + # Use #message, #part, #header, #header_fields, #header_fields_not, + # #text, or #mime to retrieve BODY[#{section_spec}] attributes. + def body; attr["BODY"] end + + # :call-seq: + # message(offset: bytes) -> string or nil + # + # The RFC5322[https://www.rfc-editor.org/rfc/rfc5322.html] + # expression of the entire message, as a string. + # + # See #part for a description of +offset+. + # + # RFC5322 messages can be parsed using the "mail" gem. + # + # This is the same as getting the value for "BODY[]" or + # "BODY[]<#{offset}>" from #attr. + # + # See also: #header, #text, and #mime. + def message(offset: nil) attr[body_section_attr(offset: offset)] end + + # :call-seq: + # part(*part_nums, offset: bytes) -> string or nil + # + # The string representation of a particular MIME part. + # + # +part_nums+ forms a path of MIME part numbers, counting up from +1+, + # which may specify an arbitrarily nested part, similarly to Array#dig. + # Messages that don't use MIME, or MIME messages that are not multipart + # and don't hold an encapsulated message, only have part +1+. + # + # If a zero-based +offset+ is given, the returned string is a substring of + # the entire contents, starting at that origin octet. This means that + # BODY[]<0> MAY be truncated, but BODY[] is never + # truncated. + # + # This is the same as getting the value of + # "BODY[#{part_nums.join(".")}]" or + # "BODY[#{part_nums.join(".")}]<#{offset}>" from #attr. + # + # See also: #message, #header, #text, and #mime. + def part(index, *subparts, offset: nil) + attr[body_section_attr([index, *subparts], offset: offset)] + end + + # :call-seq: + # header(*part_nums, offset: nil) -> string or nil + # header(*part_nums, fields: names, offset: nil) -> string or nil + # header(*part_nums, except: names, offset: nil) -> string or nil + # + # The {[RFC5322]}[https://www.rfc-editor.org/rfc/rfc5322.html] header of a + # message or of an encapsulated + # {[MIME-IMT]}[https://www.rfc-editor.org/rfc/rfc2046.html] + # MESSAGE/RFC822 or MESSAGE/GLOBAL message. + # + # Headers can be parsed using the "mail" gem. + # + # See #part for a description of +part_nums+ and +offset+. + # + # ==== Without +fields+ or +except+ + # This is the same as getting the value from #attr for one of: + # * BODY[HEADER] + # * BODY[HEADER]<#{offset}> + # * BODY[#{part_nums.join "."}.HEADER]" + # * BODY[#{part_nums.join "."}.HEADER]<#{offset}>" + # + # ==== With +fields+ + # When +fields+ is sent, returns a subset of the header which contains + # only the header fields that match one of the names in the list. + # + # This is the same as getting the value from #attr_upcase for one of: + # * BODY[HEADER.FIELDS (#{names.join " "})] + # * BODY[HEADER.FIELDS (#{names.join " "})]<#{offset}> + # * BODY[#{part_nums.join "."}.HEADER.FIELDS (#{names.join " "})] + # * BODY[#{part_nums.join "."}.HEADER.FIELDS (#{names.join " "})]<#{offset}> + # + # See also: #header_fields + # + # ==== With +except+ + # When +except+ is sent, returns a subset of the header which contains + # only the header fields that do _not_ match one of the names in the list. + # + # This is the same as getting the value from #attr_upcase for one of: + # * BODY[HEADER.FIELDS.NOT (#{names.join " "})] + # * BODY[HEADER.FIELDS.NOT (#{names.join " "})]<#{offset}> + # * BODY[#{part_nums.join "."}.HEADER.FIELDS.NOT (#{names.join " "})] + # * BODY[#{part_nums.join "."}.HEADER.FIELDS.NOT (#{names.join " "})]<#{offset}> + # + # See also: #header_fields_not + def header(*part_nums, fields: nil, except: nil, offset: nil) + fields && except and + raise ArgumentError, "conflicting 'fields' and 'except' arguments" + if fields + text = "HEADER.FIELDS (%s)" % [fields.join(" ").upcase] + attr_upcase[body_section_attr(part_nums, text, offset: offset)] + elsif except + text = "HEADER.FIELDS.NOT (%s)" % [except.join(" ").upcase] + attr_upcase[body_section_attr(part_nums, text, offset: offset)] + else + attr[body_section_attr(part_nums, "HEADER", offset: offset)] + end + end + + # :call-seq: + # header_fields(*names, part: [], offset: nil) -> string or nil + # + # The result from #header when called with fields: names. + def header_fields(first, *rest, part: [], offset: nil) + header(*part, fields: [first, *rest], offset: offset) + end + + # :call-seq: + # header_fields_not(*names, part: [], offset: nil) -> string or nil + # + # The result from #header when called with except: names. + def header_fields_not(first, *rest, part: [], offset: nil) + header(*part, except: [first, *rest], offset: offset) + end + + # :call-seq: + # mime(*part_nums) -> string or nil + # mime(*part_nums, offset: bytes) -> string or nil + # + # The {[MIME-IMB]}[https://www.rfc-editor.org/rfc/rfc2045.html] header for + # a message part, if it was fetched. + # + # See #part for a description of +part_nums+ and +offset+. + # + # This is the same as getting the value for + # "BODY[#{part_nums}.MIME]" or + # "BODY[#{part_nums}.MIME]<#{offset}>" from #attr. + # + # See also: #message, #header, and #text. + def mime(part, *subparts, offset: nil) + attr[body_section_attr([part, *subparts], "MIME", offset: offset)] + end + + # :call-seq: + # text(*part_nums) -> string or nil + # text(*part_nums, offset: bytes) -> string or nil + # + # The text body of a message or a message part, if it was fetched, + # omitting the {[RFC5322]}[https://www.rfc-editor.org/rfc/rfc5322.html] + # header. + # + # See #part for a description of +part_nums+ and +offset+. + # + # This is the same as getting the value from #attr for one of: + # * "BODY[TEXT]", + # * "BODY[TEXT]<#{offset}>", + # * "BODY[#{section}.TEXT]", or + # * "BODY[#{section}.TEXT]<#{offset}>". + # + # See also: #message, #header, and #mime. + def text(*part, offset: nil) + attr[body_section_attr(part, "TEXT", offset: offset)] + end + + # :call-seq: + # bodystructure -> BodyStructure struct or nil + # + # A BodyStructure object that describes the message, if it was fetched. + # + # This is the same as getting the value for "BODYSTRUCTURE" from + # #attr. + def bodystructure; attr["BODYSTRUCTURE"] end + alias body_structure bodystructure + + # :call-seq: envelope -> Envelope or nil + # + # An Envelope object that describes the envelope structure of a message. + # See the documentation for Envelope for a description of the envelope + # structure attributes. + # + # This is the same as getting the value for "ENVELOPE" from + # #attr. + def envelope; attr["ENVELOPE"] end + + # :call-seq: flags -> array of Symbols and Strings + # + # A array of flags that are set for this message. System flags are + # symbols that have been capitalized by String#capitalize. Keyword flags + # are strings and their case is not changed. + # + # This is the same as getting the value for "FLAGS" from #attr. + # + # [Note] + # The +FLAGS+ field is dynamic, and can change for a uniquely identified + # message. + def flags; attr["FLAGS"] end + + # :call-seq: internaldate -> Time or nil + # + # The internal date and time of the message on the server. This is not + # the date and time in the [RFC5322[https://tools.ietf.org/html/rfc5322]] + # header, but rather a date and time which reflects when the message was + # received. + # + # This is similar to getting the value for "INTERNALDATE" from + # #attr. + # + # [Note] + # attr["INTERNALDATE"] returns a string, and this method + # returns a Time object. + def internaldate + attr["INTERNALDATE"]&.then { IMAP.decode_time _1 } + end + alias internal_date internaldate + + # :call-seq: rfc822 -> String + # + # Semantically equivalent to #message with no arguments. + # + # This is the same as getting the value for "RFC822" from #attr. + # + # [Note] + # +IMAP4rev2+ deprecates RFC822. + def rfc822; attr["RFC822"] end + + # :call-seq: rfc822_size -> Integer + # + # A number expressing the [RFC5322[https://tools.ietf.org/html/rfc5322]] + # size of the message. + # + # This is the same as getting the value for "RFC822.SIZE" from + # #attr. + # + # [Note] + # \IMAP was originally developed for the older + # RFC822[https://www.rfc-editor.org/rfc/rfc822.html] standard, and as a + # consequence several fetch items in \IMAP incorporate "RFC822" in their + # name. With the exception of +RFC822.SIZE+, there are more modern + # replacements; for example, the modern version of +RFC822.HEADER+ is + # BODY.PEEK[HEADER]. In all cases, "RFC822" should be + # interpreted as a reference to the updated + # RFC5322[https://www.rfc-editor.org/rfc/rfc5322.html] standard. + def rfc822_size; attr["RFC822.SIZE"] end + alias size rfc822_size + + # :call-seq: rfc822_header -> String + # + # Semantically equivalent to #header, with no arguments. + # + # This is the same as getting the value for "RFC822.HEADER" from #attr. + # + # [Note] + # +IMAP4rev2+ deprecates RFC822.HEADER. + def rfc822_header; attr["RFC822.HEADER"] end + + # :call-seq: rfc822_text -> String + # + # Semantically equivalent to #text, with no arguments. + # + # This is the same as getting the value for "RFC822.TEXT" from + # #attr. + # + # [Note] + # +IMAP4rev2+ deprecates RFC822.TEXT. + def rfc822_text; attr["RFC822.TEXT"] end + + # :call-seq: uid -> Integer + # + # A number expressing the unique identifier of the message. + # + # This is the same as getting the value for "UID" from #attr. + def uid; attr["UID"] end + + # :call-seq: + # binary(*part_nums, offset: nil) -> string or nil + # + # Returns the binary representation of a particular MIME part, which has + # already been decoded according to its Content-Transfer-Encoding. + # + # See #part for a description of +part_nums+ and +offset+. + # + # This is the same as getting the value of + # "BINARY[#{part_nums.join(".")}]" or + # "BINARY[#{part_nums.join(".")}]<#{offset}>" from #attr. + # + # The server must support either + # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] + # or the +BINARY+ extension + # {[RFC3516]}[https://www.rfc-editor.org/rfc/rfc3516.html]. + # + # See also: #binary_size, #mime + def binary(*part_nums, offset: nil) + attr[section_attr("BINARY", part_nums, offset: offset)] + end + + # :call-seq: + # binary_size(*part_nums) -> integer or nil + # + # Returns the decoded size of a particular MIME part (the size to expect + # in response to a BINARY fetch request). + # + # See #part for a description of +part_nums+. + # + # This is the same as getting the value of + # "BINARY.SIZE[#{part_nums.join(".")}]" from #attr. + # + # The server must support either + # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] + # or the +BINARY+ extension + # {[RFC3516]}[https://www.rfc-editor.org/rfc/rfc3516.html]. + # + # See also: #binary, #mime + def binary_size(*part_nums) + attr[section_attr("BINARY.SIZE", part_nums)] + end + + # :call-seq: modseq -> Integer + # + # The modification sequence number associated with this IMAP message. + # + # This is the same as getting the value for "MODSEQ" from #attr. + # + # The server must support the +CONDSTORE+ extension + # {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. + # + # [Note] + # The +MODSEQ+ field is dynamic, and can change for a uniquely + # identified message. + def modseq; attr["MODSEQ"] end + + # :call-seq: emailid -> string or nil + # + # An ObjectID that uniquely identifies the immutable content of a single + # message. + # + # The server must return the same +EMAILID+ for both the source and + # destination messages after a COPY or MOVE command. However, it is + # possible for different messages with the same EMAILID to have different + # mutable attributes, such as flags. + # + # This is the same as getting the value for "EMAILID" from + # #attr. + # + # The server must support the +OBJECTID+ extension + # {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. + def emailid; attr["EMAILID"] end + + # :call-seq: threadid -> string or nil + # + # An ObjectID that uniquely identifies a set of messages that the server + # believes should be grouped together. + # + # It is generally based on some combination of References, In-Reply-To, + # and Subject, but the exact implementation is left up to the server + # implementation. The server should return the same thread identifier for + # related messages, even if they are in different mailboxes. + # + # This is the same as getting the value for "THREADID" from + # #attr. + # + # The server must support the +OBJECTID+ extension + # {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. + def threadid; attr["THREADID"] end + + private + + def body_section_attr(...) section_attr("BODY", ...) end + + def section_attr(attr, part = [], text = nil, offset: nil) + spec = Array(part).flatten.map { Integer(_1) } + spec << text if text + spec = spec.join(".") + if offset then "%s[%s]<%d>" % [attr, spec, Integer(offset)] + else "%s[%s]" % [attr, spec] + end + end + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/flags.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/flags.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/flags.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/flags.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,262 @@ +# frozen_string_literal: true + +module Net + class IMAP < Protocol + + # ------------------------------------------------------------------------- + # :section: System Flags + # + # A message has a list of zero or more named tokens, known as "flags", + # associated with it. A flag is set by its addition to this list and is + # cleared by its removal. There are two types of flags in + # IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] and + # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html]: flags and + # keywords. A flag of either type can be permanent or session-only. + # + # A "system flag" is a message flag name that is predefined in the \IMAP + # specifications and begins with "\". Net::IMAP returns all + # system flags as symbols, without the "\" prefix. + # + # The descriptions here were copied from {[RFC-9051 + # §2.3.2]}[https://www.rfc-editor.org/rfc/rfc9051.html#section-2.3.2]. + # See also {[RFC-3501 + # §2.3.2]}[https://www.rfc-editor.org/rfc/rfc3501.html#section-2.3.2], + # which describes the flags message attribute semantics under + # IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html]. + # ------------------------------------------------------------------------- + + ## + # Flag indicating a message has been read. + SEEN = :Seen + + # Flag indicating a message has been answered. + ANSWERED = :Answered + + # A message flag indicating a message has been flagged for special or urgent + # attention. + # + # Also a mailbox special use attribute, which indicates that this mailbox + # presents all messages marked in some way as "important". When this + # special use is supported, it is likely to represent a virtual mailbox + # collecting messages (from other mailboxes) that are marked with the + # "\Flagged" message flag. + FLAGGED = :Flagged + + # Flag indicating a message has been marked for deletion. This + # will occur when the mailbox is closed or expunged. + DELETED = :Deleted + + # Flag indicating a message is only a draft or work-in-progress version. + DRAFT = :Draft + + # Flag indicating that the message is "recent," meaning that this + # session is the first session in which the client has been notified + # of this message. + # + # This flag was defined by + # IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] + # and is deprecated by + # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html]. + RECENT = :Recent + + # ------------------------------------------------------------------------- + # :section: Basic Mailbox Attributes + # Mailbox name attributes will be returned in #list responses. Base + # attributes must be returned according to the server's capabilities. + # + # IMAP4 specifies that all mailbox name attributes, including future + # extensions, begin with "\". Net::IMAP returns all mailbox + # attributes as symbols, without the "\" prefix. + # + # Mailbox name attributes are not case-sensitive. The current + # implementation normalizes mailbox attribute case using + # String#capitalize, such as +:Noselect+ (not +:NoSelect+). The constants + # (such as NO_SELECT) can also be used for comparison. The constants have + # been defined both with and without underscores between words. + # + # The descriptions here were copied from {[RFC-9051 § + # 7.3.1]}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.3.1]. + # + # Other mailbox name attributes can be found in the {IANA IMAP Mailbox Name + # Attributes registry}[https://www.iana.org/assignments/imap-mailbox-name-attributes/imap-mailbox-name-attributes.xhtml]. + # ------------------------------------------------------------------------- + + ## + # The +\NonExistent+ attribute indicates that a mailbox name does not refer + # to an existing mailbox. Note that this attribute is not meaningful by + # itself, as mailbox names that match the canonical #list pattern but don't + # exist must not be returned unless one of the two conditions listed below + # is also satisfied: + # + # 1. The mailbox name also satisfies the selection criteria (for example, + # it is subscribed and the "SUBSCRIBED" selection option has been + # specified). + # + # 2. "RECURSIVEMATCH" has been specified, and the mailbox name has at least + # one descendant mailbox name that does not match the #list pattern and + # does match the selection criteria. + # + # In practice, this means that the +\NonExistent+ attribute is usually + # returned with one or more of +\Subscribed+, +\Remote+, +\HasChildren+, or + # the CHILDINFO extended data item. + # + # The client must treat the presence of the +\NonExistent+ attribute as if the + # +\NoSelect+ attribute was also sent by the server + NONEXISTENT = :Nonexistent + + # Mailbox attribute indicating it is not possible for any child levels of + # hierarchy to exist under this name; no child levels exist now and none can + # be created in the future children. + # + # The client must treat the presence of the +\NoInferiors+ attribute as if the + # +\HasNoChildren+ attribute was also sent by the server + NO_INFERIORS = :Noinferiors + + # Mailbox attribute indicating it is not possible to use this name as a + # selectable mailbox. + NO_SELECT = :Noselect + + # The presence of this attribute indicates that the mailbox has child + # mailboxes. A server SHOULD NOT set this attribute if there are child + # mailboxes and the user does not have permission to access any of them. In + # this case, +\HasNoChildren+ SHOULD be used. In many cases, however, a + # server may not be able to efficiently compute whether a user has access to + # any child mailboxes. Note that even though the +\HasChildren+ attribute + # for a mailbox must be correct at the time of processing the mailbox, a + # client must be prepared to deal with a situation when a mailbox is marked + # with the +\HasChildren+ attribute, but no child mailbox appears in the + # response to the #list command. This might happen, for example, due to child + # mailboxes being deleted or made inaccessible to the user (using access + # control) by another client before the server is able to list them. + # + # It is an error for the server to return both a +\HasChildren+ and a + # +\HasNoChildren+ attribute in the same #list response. A client that + # encounters a #list response with both +\HasChildren+ and +\HasNoChildren+ + # attributes present should act as if both are absent in the #list response. + HAS_CHILDREN = :Haschildren + + # The presence of this attribute indicates that the mailbox has NO child + # mailboxes that are accessible to the currently authenticated user. + # + # It is an error for the server to return both a +\HasChildren+ and a + # +\HasNoChildren+ attribute in the same #list response. A client that + # encounters a #list response with both +\HasChildren+ and +\HasNoChildren+ + # attributes present should act as if both are absent in the #list response. + # + # Note: the +\HasNoChildren+ attribute should not be confused with the + # +\NoInferiors+ attribute, which indicates that no child mailboxes exist + # now and none can be created in the future. + HAS_NO_CHILDREN = :Hasnochildren + + # The mailbox has been marked "interesting" by the server; the mailbox + # probably contains messages that have been added since the last time the + # mailbox was selected. + # + # If it is not feasible for the server to determine whether or not the + # mailbox is "interesting", the server SHOULD NOT send either +\Marked+ or + # +\Unmarked+. The server MUST NOT send more than one of +\Marked+, + # +\Unmarked+, and +\NoSelect+ for a single mailbox, and it MAY send none of + # these. + MARKED = :Marked + + # The mailbox does not contain any additional messages since the last time + # the mailbox was selected. + # + # If it is not feasible for the server to determine whether or not the + # mailbox is "interesting", the server SHOULD NOT send either +\Marked+ or + # +\Unmarked+. The server MUST NOT send more than one of +\Marked+, + # +\Unmarked+, and +\NoSelect+ for a single mailbox, and it MAY send none of + # these. + UNMARKED = :Unmarked + + # The mailbox name was subscribed to using the #subscribe command. + SUBSCRIBED = :Subscribed + + # The mailbox is a remote mailbox. + REMOTE = :Remove + + # Alias for NO_INFERIORS, to match the \IMAP spelling. + NOINFERIORS = NO_INFERIORS + # Alias for NO_SELECT, to match the \IMAP spelling. + NOSELECT = NO_SELECT + # Alias for HAS_CHILDREN, to match the \IMAP spelling. + HASCHILDREN = HAS_CHILDREN + # Alias for HAS_NO_CHILDREN, to match the \IMAP spelling. + HASNOCHILDREN = HAS_NO_CHILDREN + + # ------------------------------------------------------------------------- + # :section: Mailbox role attributes + # + # Mailbox name attributes will be returned in #list responses. In addition + # to the base mailbox name attributes defined above, an \IMAP server MAY + # also include any or all of the following attributes that denote "role" (or + # "special-use") of a mailbox. These attributes are included along with base + # attributes defined above. A given mailbox may have none, one, or more than + # one of these attributes. In some cases, a special use is advice to a + # client about what to put in that mailbox. In other cases, it's advice to a + # client about what to expect to find there. + # + # IMAP4 specifies that all mailbox name attributes, including future + # extensions, begin with "\". Net::IMAP returns all mailbox + # attributes as symbols, without the "\" prefix. + # + # The special use attributes were first defined as part of the + # SPECIAL-USE[https://www.rfc-editor.org/rfc/rfc6154.html] extension, but + # servers may return them without including the +SPECIAL-USE+ #capability. + # + # The descriptions here were copied from {[RFC-9051 § + # 7.3.1]}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.3.1]. + # + # Other mailbox name attributes can be found in the {IANA IMAP Mailbox Name + # Attributes registry}[https://www.iana.org/assignments/imap-mailbox-name-attributes/imap-mailbox-name-attributes.xhtml]. + # ------------------------------------------------------------------------- + + # Mailbox attribute indicating that this mailbox presents all messages in + # the user's message store. Implementations MAY omit some messages, such as, + # perhaps, those in \Trash and \Junk. When this special use is supported, it + # is almost certain to represent a virtual mailbox + ALL = :All + + # Mailbox attribute indicating that this mailbox is used to archive + # messages. The meaning of an "archival" mailbox is server dependent; + # typically, it will be used to get messages out of the inbox, or otherwise + # keep them out of the user's way, while still making them accessible + ARCHIVE = :Archive + + # Mailbox attribute indicating that this mailbox is used to hold draft + # messages -- typically, messages that are being composed but have not yet + # been sent. In some server implementations, this might be a virtual + # mailbox, containing messages from other mailboxes that are marked with the + # "\Draft" message flag. Alternatively, this might just be advice that a + # client put drafts here + DRAFTS = :Drafts + + #-- + # n.b. FLAGGED is defined in the system flags section. + #++ + + # Mailbox attribute indicating that this mailbox is where messages deemed to + # be junk mail are held. Some server implementations might put messages here + # automatically. Alternatively, this might just be advice to a client-side + # spam filter. + JUNK = :Junk + + # Mailbox attribute indicating that this mailbox is used to hold copies of + # messages that have been sent. Some server implementations might put + # messages here automatically. Alternatively, this might just be advice that + # a client save sent messages here. + SENT = :Sent + + # Mailbox attribute indicating that this mailbox is used to hold messages + # that have been deleted or marked for deletion. In some server + # implementations, this might be a virtual mailbox, containing messages from + # other mailboxes that are marked with the +\Deleted+ message flag. + # Alternatively, this might just be advice that a client that chooses not to + # use the \IMAP +\Deleted+ model should use as its trash location. In server + # implementations that strictly expect the \IMAP +\Deleted+ model, this + # special use is likely not to be supported. + TRASH = :Trash + + # :section: + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_data.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_data.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_data.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_data.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,1179 @@ +# frozen_string_literal: true + +module Net + class IMAP < Protocol + autoload :FetchData, "#{__dir__}/fetch_data" + autoload :SearchResult, "#{__dir__}/search_result" + autoload :SequenceSet, "#{__dir__}/sequence_set" + autoload :UIDPlusData, "#{__dir__}/uidplus_data" + autoload :AppendUIDData, "#{__dir__}/uidplus_data" + autoload :CopyUIDData, "#{__dir__}/uidplus_data" + + # Net::IMAP::ContinuationRequest represents command continuation requests. + # + # The command continuation request response is indicated by a "+" token + # instead of a tag. This form of response indicates that the server is + # ready to accept the continuation of a command from the client. The + # remainder of this response is a line of text. + # + class ContinuationRequest < Struct.new(:data, :raw_data) + ## + # method: data + # :call-seq: data -> ResponseText + # + # Returns a ResponseText object + + ## + # method: raw_data + # :call-seq: raw_data -> string + # + # the raw response data + end + + # Net::IMAP::UntaggedResponse represents untagged responses. + # + # Data transmitted by the server to the client and status responses + # that do not indicate command completion are prefixed with the token + # "*", and are called untagged responses. + # + class UntaggedResponse < Struct.new(:name, :data, :raw_data) + ## + # method: name + # :call-seq: name -> string + # + # The uppercase response name, e.g. "FLAGS", "LIST", "FETCH", etc. + + ## + # method: data + # :call-seq: data -> object or nil + # + # The parsed response data, e.g: an array of flag symbols, an array of + # capabilities strings, a ResponseText object, a MailboxList object, a + # FetchData object, a Namespaces object, etc. The response #name + # determines what form the data can take. + + ## + # method: raw_data + # :call-seq: raw_data -> string + # + # The raw response data. + end + + # Net::IMAP::IgnoredResponse represents intentionally ignored responses. + # + # This includes untagged response "NOOP" sent by e.g. Zimbra to avoid + # some clients to close the connection. + # + # It matches no IMAP standard. + class IgnoredResponse < UntaggedResponse + end + + # **Note:** This represents an intentionally _unstable_ API. Where + # instances of this class are returned, future releases may return a + # different (incompatible) object without deprecation or warning. + # + # Net::IMAP::UnparsedData represents data for unknown response types or + # unknown extensions to response types without a well-defined extension + # grammar. + # + # See also: UnparsedNumericResponseData, ExtensionData, IgnoredResponse + class UnparsedData < Struct.new(:unparsed_data) + ## + # method: unparsed_data + # :call-seq: unparsed_data -> string + # + # The unparsed data + end + + # **Note:** This represents an intentionally _unstable_ API. Where + # instances of this class are returned, future releases may return a + # different (incompatible) object without deprecation or warning. + # + # Net::IMAP::UnparsedNumericResponseData represents data for unhandled + # response types with a numeric prefix. See the documentation for #number. + # + # See also: UnparsedData, ExtensionData, IgnoredResponse + class UnparsedNumericResponseData < Struct.new(:number, :unparsed_data) + ## + # method: number + # :call-seq: number -> integer + # + # Returns a numeric response data prefix, when available. + # + # Many response types are prefixed with a non-negative #number. For + # message data, #number may represent a sequence number or a UID. For + # mailbox data, #number may represent a message count. + + ## + # method: unparsed_data + # :call-seq: unparsed_data -> string + # + # The unparsed data, not including #number or UntaggedResponse#name. + end + + # **Note:** This represents an intentionally _unstable_ API. Where + # instances of this class are returned, future releases may return a + # different (incompatible) object without deprecation or warning. + # + # Net::IMAP::ExtensionData represents data that is parsable according to the + # forward-compatible extension syntax in RFC3501, RFC4466, or RFC9051, but + # isn't directly known or understood by Net::IMAP yet. + # + # See also: UnparsedData, UnparsedNumericResponseData, IgnoredResponse + class ExtensionData < Struct.new(:data) + ## + # method: data + # :call-seq: data -> string + # + # The parsed extension data. + end + + # Net::IMAP::TaggedResponse represents tagged responses. + # + # The server completion result response indicates the success or + # failure of the operation. It is tagged with the same tag as the + # client command which began the operation. + # + class TaggedResponse < Struct.new(:tag, :name, :data, :raw_data) + ## + # method: tag + # :call-seq: tag -> string + # + # Returns the command tag + + ## + # method: name + # :call-seq: name -> string + # + # Returns the name, one of "OK", "NO", or "BAD". + + ## + # method: data + # :call-seq: data -> ResponseText + # + # Returns a ResponseText object + + ## + # method: raw_data + # :call-seq: raw_data -> string + # + # The raw response data. + end + + # Net::IMAP::ResponseText represents texts of responses. + # + # The text may be prefixed by a ResponseCode. + # + # ResponseText is returned from TaggedResponse#data, or from + # UntaggedResponse#data when the response type is a "condition" ("OK", "NO", + # "BAD", "PREAUTH", or "BYE"). + class ResponseText < Struct.new(:code, :text) + # Used to avoid an allocation when ResponseText is empty + EMPTY = new(nil, "").freeze + + ## + # method: code + # :call-seq: code -> ResponseCode or nil + # + # Returns a ResponseCode, if the response contains one + + ## + # method: text + # :call-seq: text -> string + # + # Returns the response text, not including any response code + end + + # Net::IMAP::ResponseCode represents response codes. Response codes can be + # retrieved from ResponseText#code and can be included in any "condition" + # response: any TaggedResponse and UntaggedResponse when the response type + # is a "condition" ("OK", "NO", "BAD", "PREAUTH", or "BYE"). + # + # Some response codes come with additional data which will be parsed by + # Net::IMAP. Others return +nil+ for #data, but are used as a + # machine-readable annotation for the human-readable ResponseText#text in + # the same response. When Net::IMAP does not know how to parse response + # code text, #data returns the unparsed string. + # + # Untagged response code #data is pushed directly onto Net::IMAP#responses, + # keyed by #name, unless it is removed by the command that generated it. + # Use Net::IMAP#add_response_handler to view tagged response codes for + # command methods that do not return their TaggedResponse. + # + # \IMAP extensions may define new codes and the data that comes with them. + # The IANA {IMAP Response + # Codes}[https://www.iana.org/assignments/imap-response-codes/imap-response-codes.xhtml] + # registry has links to specifications for all standard response codes. + # Response codes are backwards compatible: Servers are allowed to send new + # response codes even if the client has not enabled the extension that + # defines them. When unknown response code data is encountered, #data + # will return an unparsed string. + # + # ==== +IMAP4rev1+ Response Codes + # See [IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501]] {§7.1, "Server + # Responses - Status + # Responses"}[https://www.rfc-editor.org/rfc/rfc3501#section-7.1] for full + # definitions of the basic set of IMAP4rev1 response codes: + # * +ALERT+, the ResponseText#text contains a special alert that MUST be + # brought to the user's attention. + # * +BADCHARSET+, #data will be an array of charset strings, or +nil+. + # * +CAPABILITY+, #data will be an array of capability strings. + # * +PARSE+, the ResponseText#text presents an error parsing a message's + # \[RFC5322] or [MIME-IMB] headers. + # * +PERMANENTFLAGS+, followed by an array of flags. System flags will be + # symbols, and keyword flags will be strings. See + # rdoc-ref:Net::IMAP@System+flags + # * +READ-ONLY+, the mailbox was selected read-only, or changed to read-only + # * +READ-WRITE+, the mailbox was selected read-write, or changed to + # read-write + # * +TRYCREATE+, when #append or #copy fail because the target mailbox + # doesn't exist. + # * +UIDNEXT+, #data is an Integer, the next UID value of the mailbox. See + # [{IMAP4rev1}[https://www.rfc-editor.org/rfc/rfc3501]], + # {§2.3.1.1, "Unique Identifier (UID) Message + # Attribute}[https://www.rfc-editor.org/rfc/rfc3501#section-2.3.1.1]. + # * +UIDVALIDITY+, #data is an Integer, the UID validity value of the + # mailbox. See [{IMAP4rev1}[https://www.rfc-editor.org/rfc/rfc3501]], + # {§2.3.1.1, "Unique Identifier (UID) Message + # Attribute}[https://www.rfc-editor.org/rfc/rfc3501#section-2.3.1.1]. + # * +UNSEEN+, #data is an Integer, the number of messages which do not have + # the \Seen flag set. + # DEPRECATED by IMAP4rev2. + # + # ==== +BINARY+ extension + # See {[RFC3516]}[https://www.rfc-editor.org/rfc/rfc3516]. + # * +UNKNOWN-CTE+, with a tagged +NO+ response, when the server does not + # known how to decode a CTE (content-transfer-encoding). #data is +nil+. + # See IMAP#fetch. + # + # ==== +UIDPLUS+ extension + # See {[RFC4315 §3]}[https://www.rfc-editor.org/rfc/rfc4315#section-3]. + # * +APPENDUID+, #data is UIDPlusData. See IMAP#append. + # * +COPYUID+, #data is UIDPlusData. See IMAP#copy. + # * +UIDNOTSTICKY+, #data is +nil+. See IMAP#select. + # + # ==== +SEARCHRES+ extension + # See {[RFC5182]}[https://www.rfc-editor.org/rfc/rfc5182]. + # * +NOTSAVED+, with a tagged +NO+ response, when the search result variable + # is not saved. #data is +nil+. + # + # ==== +RFC5530+ Response Codes + # See {[RFC5530]}[https://www.rfc-editor.org/rfc/rfc5530], "IMAP Response + # Codes" for the definition of the following response codes, which are all + # machine-readable annotations for the human-readable ResponseText#text, and + # have +nil+ #data of their own: + # * +UNAVAILABLE+ + # * +AUTHENTICATIONFAILED+ + # * +AUTHORIZATIONFAILED+ + # * +EXPIRED+ + # * +PRIVACYREQUIRED+ + # * +CONTACTADMIN+ + # * +NOPERM+ + # * +INUSE+ + # * +EXPUNGEISSUED+ + # * +CORRUPTION+ + # * +SERVERBUG+ + # * +CLIENTBUG+ + # * +CANNOT+ + # * +LIMIT+ + # * +OVERQUOTA+ + # * +ALREADYEXISTS+ + # * +NONEXISTENT+ + # + # ==== +QRESYNC+ extension + # See {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. + # * +CLOSED+, returned when the currently selected mailbox is closed + # implicitly by selecting or examining another mailbox. #data is +nil+. + # + # ==== +IMAP4rev2+ Response Codes + # See {[RFC9051]}[https://www.rfc-editor.org/rfc/rfc9051] {§7.1, "Server + # Responses - Status + # Responses"}[https://www.rfc-editor.org/rfc/rfc9051#section-7.1] for full + # descriptions of IMAP4rev2 response codes. IMAP4rev2 includes all of the + # response codes listed above (except "UNSEEN") and adds the following: + # * +HASCHILDREN+, with a tagged +NO+ response, when a mailbox delete failed + # because the server doesn't allow deletion of mailboxes with children. + # #data is +nil+. + # + # ==== QUOTA=RES-* response codes + # See {[RFC9208]}[https://www.rfc-editor.org/rfc/rfc9208.html#section-4.3]. + # * +OVERQUOTA+ (also in RFC5530[https://www.rfc-editor.org/rfc/rfc5530]), + # with a tagged +NO+ response to an +APPEND+/+COPY+/+MOVE+ command when + # the command would put the target mailbox over any quota, and with an + # untagged +NO+ when a mailbox exceeds a soft quota (which may be caused + # be external events). #data is +nil+. + # + # ==== +CONDSTORE+ extension + # See {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. + # * +NOMODSEQ+, when selecting a mailbox that does not support + # mod-sequences. #data is +nil+. See IMAP#select. + # * +HIGHESTMODSEQ+, #data is an Integer, the highest mod-sequence value of + # all messages in the mailbox. See IMAP#select. + # * +MODIFIED+, #data is a SequenceSet, the messages that have been modified + # since the +UNCHANGEDSINCE+ mod-sequence given to +STORE+ or UID + # STORE. + # + # ==== +OBJECTID+ extension + # See {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. + # * +MAILBOXID+, #data is a string + # + class ResponseCode < Struct.new(:name, :data) + ## + # method: name + # :call-seq: name -> string + # + # Returns the response code name, such as "ALERT", "PERMANENTFLAGS", or + # "UIDVALIDITY". + + ## + # method: data + # :call-seq: data -> object or nil + # + # Returns the parsed response code data, e.g: an array of capabilities + # strings, an array of character set strings, a list of permanent flags, + # an Integer, etc. The response #code determines what form the response + # code data can take. + end + + # Net::IMAP::MailboxList represents contents of the LIST response, + # representing a single mailbox path. + # + # Net::IMAP#list returns an array of MailboxList objects. + # + class MailboxList < Struct.new(:attr, :delim, :name) + ## + # method: attr + # :call-seq: attr -> array of Symbols + # + # Returns the name attributes. Each name attribute is a symbol capitalized + # by String#capitalize, such as :Noselect (not :NoSelect). For the + # semantics of each attribute, see: + # * rdoc-ref:Net::IMAP@Basic+Mailbox+Attributes + # * rdoc-ref:Net::IMAP@Mailbox+role+Attributes + # * Net::IMAP@SPECIAL-USE + # * The IANA {IMAP Mailbox Name Attributes + # registry}[https://www.iana.org/assignments/imap-mailbox-name-attributes/imap-mailbox-name-attributes.xhtml] + + ## + # method: delim + # :call-seq: delim -> single character string + # + # Returns the hierarchy delimiter for the mailbox path. + + ## + # method: name + # :call-seq: name -> string + # + # Returns the mailbox name. + end + + # Net::IMAP::MailboxQuota represents contents of GETQUOTA response. + # This object can also be a response to GETQUOTAROOT. In the syntax + # specification below, the delimiter used with the "#" construct is a + # single space (SPACE). + # + # Net:IMAP#getquota returns an array of MailboxQuota objects. + # + # Net::IMAP#getquotaroot returns an array containing both MailboxQuotaRoot + # and MailboxQuota objects. + # + # ==== Required capability + # + # Requires +QUOTA+ [RFC2087[https://www.rfc-editor.org/rfc/rfc2087]] + # or QUOTA=RES-STORAGE + # [RFC9208[https://www.rfc-editor.org/rfc/rfc9208]] capability. + class MailboxQuota < Struct.new(:mailbox, :usage, :quota) + ## + # method: mailbox + # :call-seq: mailbox -> string + # + # The quota root with the associated quota. + # + # NOTE: this was mistakenly named "mailbox". But the quota root's name may + # differ from the mailbox. A single quota root may cover multiple + # mailboxes, and a single mailbox may be governed by multiple quota roots. + + # The quota root with the associated quota. + alias quota_root mailbox + + ## + # method: usage + # :call-seq: usage -> Integer + # + # Current storage usage of the mailbox. + + ## + # method: quota + # :call-seq: quota -> Integer + # + # Storage limit imposed on the mailbox. + # + end + + # Net::IMAP::MailboxQuotaRoot represents part of the GETQUOTAROOT + # response. (GETQUOTAROOT can also return Net::IMAP::MailboxQuota.) + # + # Net::IMAP#getquotaroot returns an array containing both MailboxQuotaRoot + # and MailboxQuota objects. + # + class MailboxQuotaRoot < Struct.new(:mailbox, :quotaroots) + ## + # method: mailbox + # :call-seq: mailbox -> string + # + # The mailbox with the associated quota. + + ## + # method: mailbox + # :call-seq: quotaroots -> array of strings + # + # Zero or more quotaroots that affect the quota on the specified mailbox. + end + + # Net::IMAP::MailboxACLItem represents the response from GETACL. + # + # Net::IMAP#getacl returns an array of MailboxACLItem objects. + # + # ==== Required capability + # +ACL+ - described in [ACL[https://tools.ietf.org/html/rfc4314]] + class MailboxACLItem < Struct.new(:user, :rights, :mailbox) + ## + # method: mailbox + # :call-seq: mailbox -> string + # + # The mailbox to which the indicated #user has the specified #rights. + + ## + # method: user + # :call-seq: user -> string + # + # Login name that has certain #rights to the #mailbox that was specified + # with the getacl command. + + ## + # method: rights + # :call-seq: rights -> string + # + # The access rights the indicated #user has to the #mailbox. + end + + # Net::IMAP::Namespace represents a single namespace contained inside a + # NAMESPACE response. + # + # Returned by Net::IMAP#namespace, contained inside a Namespaces object. + # + class Namespace < Struct.new(:prefix, :delim, :extensions) + ## + # method: prefix + # :call-seq: prefix -> string + # + # Returns the namespace prefix string. + + ## + # method: delim + # :call-seq: delim -> single character string or nil + # + # Returns a hierarchy delimiter character, if it exists. + + ## + # method: extensions + # :call-seq: extensions -> Hash[String, Array[String]] + # + # A hash of parameters mapped to arrays of strings, for extensibility. + # Extension parameter semantics would be defined by the extension. + end + + # Net::IMAP::Namespaces represents a +NAMESPACE+ server response, which + # contains lists of #personal, #shared, and #other namespaces. + # + # Net::IMAP#namespace returns a Namespaces object. + # + class Namespaces < Struct.new(:personal, :other, :shared) + ## + # method: personal + # :call-seq: personal -> array of Namespace + # + # Returns an array of Personal Namespace objects. + + ## + # method: other + # :call-seq: other -> array of Namespace + # + # Returns an array of Other Users' Namespace objects. + + ## + # method: shared + # :call-seq: shared -> array of Namespace + # + # Returns an array of Shared Namespace objects. + end + + # Net::IMAP::StatusData represents the contents of the STATUS response. + # + # Net::IMAP#status returns the contents of #attr. + class StatusData < Struct.new(:mailbox, :attr) + ## + # method: mailbox + # :call-seq: mailbox -> string + # + # The mailbox name. + + ## + # method: attr + # :call-seq: attr -> Hash[String, Integer] + # + # A hash. Each key is one of "MESSAGES", "RECENT", "UIDNEXT", + # "UIDVALIDITY", "UNSEEN". Each value is a number. + end + + # Net::IMAP::Envelope represents envelope structures of messages. + # + # [Note] + # When the #sender and #reply_to fields are absent or empty, they will + # return the same value as #from. Also, fields may return values that are + # invalid for well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] + # messages when the message is malformed or a draft message. + # + # See [{IMAP4rev1 §7.4.2}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2]] + # and [{IMAP4rev2 §7.5.2}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2]] + # for full description of the envelope fields, and + # Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. + # + # Returned by FetchData#envelope + class Envelope < Struct.new(:date, :subject, :from, :sender, :reply_to, + :to, :cc, :bcc, :in_reply_to, :message_id) + ## + # method: date + # call-seq: date -> string + # + # Returns a string that represents the +Date+ header. + # + # [Note] + # For a well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] + # message, the #date field must not be +nil+. However it can be +nil+ + # for a malformed or draft message. + + ## + # method: subject + # call-seq: subject -> string or nil + # + # Returns a string that represents the +Subject+ header, if it is present. + # + # [Note] + # Servers should return +nil+ when the header is absent and an empty + # string when it is present but empty. Some servers may return a +nil+ + # envelope member in the "present but empty" case. Clients should treat + # +nil+ and empty string as identical. + + ## + # method: from + # call-seq: from -> array of Net::IMAP::Address or nil + # + # Returns an array of Address that represents the +From+ header. + # + # If the +From+ header is absent, or is present but empty, the server + # returns +nil+ for this envelope field. + # + # [Note] + # For a well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] + # message, the #from field must not be +nil+. However it can be +nil+ + # for a malformed or draft message. + + ## + # method: sender + # call-seq: sender -> array of Net::IMAP::Address or nil + # + # Returns an array of Address that represents the +Sender+ header. + # + # [Note] + # If the Sender header is absent, or is present but empty, the + # server sets this field to be the same value as #from. Therefore, in a + # well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] message, + # the #sender envelope field must not be +nil+. However it can be + # +nil+ for a malformed or draft message. + + ## + # method: reply_to + # call-seq: reply_to -> array of Net::IMAP::Address or nil + # + # Returns an array of Address that represents the Reply-To + # header. + # + # [Note] + # If the Reply-To header is absent, or is present but empty, + # the server sets this field to be the same value as #from. Therefore, + # in a well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] + # message, the #reply_to envelope field must not be +nil+. However it + # can be +nil+ for a malformed or draft message. + + ## + # method: to + # call-seq: to -> array of Net::IMAP::Address + # + # Returns an array of Address that represents the +To+ header. + + ## + # method: cc + # call-seq: cc -> array of Net::IMAP::Address + # + # Returns an array of Address that represents the +Cc+ header. + + ## + # method: bcc + # call-seq: bcc -> array of Net::IMAP::Address + # + # Returns an array of Address that represents the +Bcc+ header. + + ## + # method: in_reply_to + # call-seq: in_reply_to -> string + # + # Returns a string that represents the In-Reply-To header. + # + # [Note] + # For a well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] + # message, the #in_reply_to field, if present, must not be empty. But + # it can still return an empty string for malformed messages. + # + # Servers should return +nil+ when the header is absent and an empty + # string when it is present but empty. Some servers may return a +nil+ + # envelope member in the "present but empty" case. Clients should treat + # +nil+ and empty string as identical. + + ## + # method: message_id + # call-seq: message_id -> string + # + # Returns a string that represents the Message-ID. + # + # [Note] + # For a well-formed [RFC5322[https://tools.ietf.org/html/rfc5322]] + # message, the #message_id field, if present, must not be empty. But it + # can still return an empty string for malformed messages. + # + # Servers should return +nil+ when the header is absent and an empty + # string when it is present but empty. Some servers may return a +nil+ + # envelope member in the "present but empty" case. Clients should treat + # +nil+ and empty string as identical. + end + + # Net::IMAP::Address represents an electronic mail address, which has been + # parsed into its component parts by the server. Address objects are + # returned within Envelope fields. + # + # === Group syntax + # + # When the #host field is +nil+, this is a special form of address structure + # that indicates the [RFC5322[https://tools.ietf.org/html/rfc5322]] group + # syntax. If the #mailbox name field is also +nil+, this is an end-of-group + # marker (semicolon in RFC-822 syntax). If the #mailbox name field is + # non-+NIL+, this is the start of a group marker, and the mailbox #name + # field holds the group name phrase. + class Address < Struct.new(:name, :route, :mailbox, :host) + ## + # method: name + # :call-seq: name -> string or nil + # + # Returns the [RFC5322[https://tools.ietf.org/html/rfc5322]] address + # +display-name+ (or the mailbox +phrase+ in the RFC-822 grammar). + + ## + # method: route + # :call-seq: route -> string or nil + # + # Returns the route from RFC-822 route-addr. + # + # Note:: Generating this obsolete route addressing syntax is not allowed + # by [RFC5322[https://tools.ietf.org/html/rfc5322]]. However, + # addresses with this syntax must still be accepted and parsed. + + ## + # method: mailbox + # :call-seq: mailbox -> string or nil + # + # Returns the [RFC5322[https://tools.ietf.org/html/rfc5322]] address + # +local-part+, if #host is not +nil+. + # + # When #host is +nil+, this returns + # an [RFC5322[https://tools.ietf.org/html/rfc5322]] group name and a +nil+ + # mailbox indicates the end of a group. + + ## + # method: host + # :call-seq: host -> string or nil + # + # Returns the [RFC5322[https://tools.ietf.org/html/rfc5322]] addr-spec + # +domain+ name. + # + # +nil+ indicates [RFC5322[https://tools.ietf.org/html/rfc5322]] group + # syntax. + end + + # Net::IMAP::ContentDisposition represents Content-Disposition fields. + # + class ContentDisposition < Struct.new(:dsp_type, :param) + ## + # method: dsp_type + # :call-seq: dsp_type -> string + # + # Returns the content disposition type, as defined by + # [DISPOSITION[https://tools.ietf.org/html/rfc2183]]. + + ## + # method: param + # :call-seq: param -> hash + # + # Returns a hash representing parameters of the Content-Disposition + # field, as defined by [DISPOSITION[https://tools.ietf.org/html/rfc2183]]. + end + + # Net::IMAP::ThreadMember represents a thread-node returned + # by Net::IMAP#thread. + # + class ThreadMember < Struct.new(:seqno, :children) + ## + # method: seqno + # :call-seq: seqno -> Integer + # + # The message sequence number. + + ## + # method: children + # :call-seq: children -> array of ThreadMember + # + # An array of Net::IMAP::ThreadMember objects for mail items that are + # children of this in the thread. + + # Returns a SequenceSet containing #seqno and all #children's seqno, + # recursively. + def to_sequence_set + SequenceSet.new all_seqnos + end + + protected + + def all_seqnos(node = self) + [node.seqno].concat node.children.flat_map { _1.all_seqnos } + end + + end + + # Net::IMAP::BodyStructure is included by all of the structs that can be + # returned from a "BODYSTRUCTURE" or "BODY" + # FetchData#attr value. Although these classes don't share a base class, + # this module can be used to pattern match all of them. + # + # See {[IMAP4rev1] §7.4.2}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2] + # and {[IMAP4rev2] §7.5.2}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2-4.9] + # for full description of all +BODYSTRUCTURE+ fields, and also + # Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. + # + # === Classes that include BodyStructure + # BodyTypeBasic:: Represents any message parts that are not handled by + # BodyTypeText, BodyTypeMessage, or BodyTypeMultipart. + # BodyTypeText:: Used by text/* parts. Contains all of the + # BodyTypeBasic fields. + # BodyTypeMessage:: Used by message/rfc822 and + # message/global parts. Contains all of the + # BodyTypeBasic fields. Other message/* types + # should use BodyTypeBasic. + # BodyTypeMultipart:: for multipart/* parts + # + module BodyStructure + end + + # Net::IMAP::BodyTypeBasic represents basic body structures of messages and + # message parts, unless they have a Content-Type that is handled by + # BodyTypeText, BodyTypeMessage, or BodyTypeMultipart. + # + # See {[IMAP4rev1] §7.4.2}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2] + # and {[IMAP4rev2] §7.5.2}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2-4.9] + # for full description of all +BODYSTRUCTURE+ fields, and also + # Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. + # + class BodyTypeBasic < Struct.new(:media_type, :subtype, + :param, :content_id, + :description, :encoding, :size, + :md5, :disposition, :language, + :location, + :extension) + include BodyStructure + + ## + # method: media_type + # :call-seq: media_type -> string + # + # The top-level media type as defined in + # [MIME-IMB[https://tools.ietf.org/html/rfc2045]]. + + ## + # method: subtype + # :call-seq: subtype -> string + # + # The media subtype name as defined in + # [MIME-IMB[https://tools.ietf.org/html/rfc2045]]. + + ## + # method: param + # :call-seq: param -> string + # + # Returns a hash that represents parameters as defined in + # [MIME-IMB[https://tools.ietf.org/html/rfc2045]]. + + ## + # method: content_id + # :call-seq: content_id -> string + # + # Returns a string giving the content id as defined + # in [MIME-IMB[https://tools.ietf.org/html/rfc2045]] + # {§7}[https://tools.ietf.org/html/rfc2045#section-7]. + + ## + # method: description + # :call-seq: description -> string + # + # Returns a string giving the content description as defined + # in [MIME-IMB[https://tools.ietf.org/html/rfc2045]] + # {§8}[https://tools.ietf.org/html/rfc2045#section-8]. + + ## + # method: encoding + # :call-seq: encoding -> string + # + # Returns a string giving the content transfer encoding as defined + # in [MIME-IMB[https://tools.ietf.org/html/rfc2045]] + # {§6}[https://tools.ietf.org/html/rfc2045#section-6]. + + ## + # method: size + # :call-seq: size -> integer + # + # Returns a number giving the size of the body in octets. + + ## + # method: md5 + # :call-seq: md5 -> string + # + # Returns a string giving the body MD5 value as defined in + # [MD5[https://tools.ietf.org/html/rfc1864]]. + + ## + # method: disposition + # :call-seq: disposition -> ContentDisposition + # + # Returns a ContentDisposition object giving the content + # disposition, as defined by + # [DISPOSITION[https://tools.ietf.org/html/rfc2183]]. + + ## + # method: language + # :call-seq: language -> string + # + # Returns a string or an array of strings giving the body + # language value as defined in + # [LANGUAGE-TAGS[https://www.rfc-editor.org/info/rfc3282]]. + + #-- + ## + # method: location + # :call-seq: location -> string + # + # A string list giving the body content URI as defined in + # [LOCATION[https://www.rfc-editor.org/info/rfc2557]]. + #++ + + ## + # method: extension + # :call-seq: extension -> string + # + # Returns extension data. The +BODYSTRUCTURE+ fetch attribute + # contains extension data, but +BODY+ does not. + + ## + # :call-seq: multipart? -> false + # + # BodyTypeBasic is not used for multipart MIME parts. + def multipart? + return false + end + + # :call-seq: media_subtype -> subtype + # + # >>> + # [Obsolete] + # Use +subtype+ instead. Calling this will generate a warning message + # to +stderr+, then return the value of +subtype+. + #-- + # TODO: why not just keep this as an alias? Would "media_subtype" be used + # for something else? + #++ + def media_subtype + warn("media_subtype is obsolete, use subtype instead.\n", uplevel: 1) + return subtype + end + end + + # Net::IMAP::BodyTypeText represents the body structures of messages and + # message parts, when Content-Type is text/*. + # + # BodyTypeText contains all of the fields of BodyTypeBasic. See + # BodyTypeBasic for documentation of the following: + # * {media_type}[rdoc-ref:BodyTypeBasic#media_type] + # * subtype[rdoc-ref:BodyTypeBasic#subtype] + # * param[rdoc-ref:BodyTypeBasic#param] + # * {content_id}[rdoc-ref:BodyTypeBasic#content_id] + # * description[rdoc-ref:BodyTypeBasic#description] + # * encoding[rdoc-ref:BodyTypeBasic#encoding] + # * size[rdoc-ref:BodyTypeBasic#size] + # + class BodyTypeText < Struct.new(:media_type, :subtype, + :param, :content_id, + :description, :encoding, :size, + :lines, + :md5, :disposition, :language, + :location, + :extension) + include BodyStructure + + ## + # method: lines + # :call-seq: lines -> Integer + # + # Returns the size of the body in text lines. + + ## + # :call-seq: multipart? -> false + # + # BodyTypeText is not used for multipart MIME parts. + def multipart? + return false + end + + # Obsolete: use +subtype+ instead. Calling this will + # generate a warning message to +stderr+, then return + # the value of +subtype+. + def media_subtype + warn("media_subtype is obsolete, use subtype instead.\n", uplevel: 1) + return subtype + end + end + + # Net::IMAP::BodyTypeMessage represents the body structures of messages and + # message parts, when Content-Type is message/rfc822 or + # message/global. + # + # BodyTypeMessage contains all of the fields of BodyTypeBasic. See + # BodyTypeBasic for documentation of the following fields: + # * {media_type}[rdoc-ref:BodyTypeBasic#media_type] + # * subtype[rdoc-ref:BodyTypeBasic#subtype] + # * param[rdoc-ref:BodyTypeBasic#param] + # * {content_id}[rdoc-ref:BodyTypeBasic#content_id] + # * description[rdoc-ref:BodyTypeBasic#description] + # * encoding[rdoc-ref:BodyTypeBasic#encoding] + # * size[rdoc-ref:BodyTypeBasic#size] + class BodyTypeMessage < Struct.new(:media_type, :subtype, + :param, :content_id, + :description, :encoding, :size, + :envelope, :body, :lines, + :md5, :disposition, :language, + :location, + :extension) + include BodyStructure + + ## + # method: envelope + # :call-seq: envelope -> Envelope + # + # Returns a Net::IMAP::Envelope giving the envelope structure. + + ## + # method: body + # :call-seq: body -> BodyStructure + # + # Returns a Net::IMAP::BodyStructure for the message's body structure. + + ## + # :call-seq: multipart? -> false + # + # BodyTypeMessage is not used for multipart MIME parts. + def multipart? + return false + end + + # Obsolete: use +subtype+ instead. Calling this will + # generate a warning message to +stderr+, then return + # the value of +subtype+. + def media_subtype + warn("media_subtype is obsolete, use subtype instead.\n", uplevel: 1) + return subtype + end + end + + # BodyTypeAttachment is not used and will be removed in an upcoming release. + # + # === Bug Analysis + # + # \IMAP body structures are parenthesized lists and assign their fields + # positionally, so missing fields change the interpretation of all + # following fields. Additionally, different body types have a different + # number of required fields, followed by optional "extension" fields. + # + # BodyTypeAttachment was previously returned when a "message/rfc822" part, + # which should be sent as body-type-msg with ten required fields, + # was actually sent as a body-type-basic with _seven_ required + # fields. + # + # basic => type, subtype, param, id, desc, enc, octets, md5=nil, dsp=nil, lang=nil, loc=nil, *ext + # msg => type, subtype, param, id, desc, enc, octets, envelope, body, lines, md5=nil, ... + # + # Normally, +envelope+ and +md5+ are incompatible, but Net::IMAP leniently + # allowed buggy servers to send +NIL+ for +envelope+. As a result, when a + # server sent a message/rfc822 part with +NIL+ for +md5+ and a + # non-NIL +dsp+, Net::IMAP misinterpreted the + # Content-Disposition as if it were a strange body type. In all + # reported cases, the Content-Disposition was "attachment", so + # BodyTypeAttachment was created as the workaround. + # + # === Current behavior + # + # When interpreted strictly, +envelope+ and +md5+ are incompatible. So the + # current parsing algorithm peeks ahead after it has received the seventh + # body field. If the next token is not the start of an +envelope+, we assume + # the server has incorrectly sent us a body-type-basic and return + # BodyTypeBasic. As a result, what was previously BodyTypeMessage#body => + # BodyTypeAttachment is now BodyTypeBasic#disposition => ContentDisposition. + # + class BodyTypeAttachment < Struct.new(:dsp_type, :_unused_, :param) + # *invalid for BodyTypeAttachment* + def media_type + warn(<<~WARN, uplevel: 1) + BodyTypeAttachment#media_type is obsolete. Use dsp_type instead. + WARN + dsp_type + end + + # *invalid for BodyTypeAttachment* + def subtype + warn("BodyTypeAttachment#subtype is obsolete.\n", uplevel: 1) + nil + end + + ## + # method: dsp_type + # :call-seq: dsp_type -> string + # + # Returns the content disposition type, as defined by + # [DISPOSITION[https://tools.ietf.org/html/rfc2183]]. + + ## + # method: param + # :call-seq: param -> hash + # + # Returns a hash representing parameters of the Content-Disposition + # field, as defined by [DISPOSITION[https://tools.ietf.org/html/rfc2183]]. + + ## + def multipart? + return false + end + end + + deprecate_constant :BodyTypeAttachment + + # Net::IMAP::BodyTypeMultipart represents body structures of messages and + # message parts, when Content-Type is multipart/*. + class BodyTypeMultipart < Struct.new(:media_type, :subtype, + :parts, + :param, :disposition, :language, + :location, + :extension) + include BodyStructure + + ## + # method: media_type + # call-seq: media_type -> "multipart" + # + # BodyTypeMultipart is only used with multipart/* media types. + + ## + # method: subtype + # call-seq: subtype -> string + # + # Returns the content subtype name + # as defined in [MIME-IMB[https://tools.ietf.org/html/rfc2045]]. + + ## + # method: parts + # call-seq: parts -> array of BodyStructure objects + # + # Returns an array with a BodyStructure object for each part contained in + # this part. + + ## + # method: param + # call-seq: param -> hash + # + # Returns a hash that represents parameters + # as defined in [MIME-IMB[https://tools.ietf.org/html/rfc2045]]. + + ## + # method: disposition + # call-seq: disposition -> ContentDisposition + # + # Returns a Net::IMAP::ContentDisposition object giving the content + # disposition. + + ## + # method: language + # :call-seq: language -> string + # + # Returns a string or an array of strings giving the body + # language value as defined in + # [LANGUAGE-TAGS[https://www.rfc-editor.org/info/rfc3282]]. + + ## + # method: extension + # call-seq: extension -> array + # + # Returns extension data as an array of numbers strings, and nested + # arrays (of numbers, strings, etc). + + ## + # :call-seq: multipart? -> true + # + # BodyTypeMultipart is used for multipart MIME parts. + def multipart? + return true + end + + ## + # Obsolete: use +subtype+ instead. Calling this will + # generate a warning message to +stderr+, then return + # the value of +subtype+. + def media_subtype + warn("media_subtype is obsolete, use subtype instead.\n", uplevel: 1) + return subtype + end + end + + # === Obsolete + # BodyTypeExtension is not used and will be removed in an upcoming release. + # + # >>> + # BodyTypeExtension was (incorrectly) used for message/* parts + # (besides message/rfc822, which correctly uses BodyTypeMessage). + # + # Net::IMAP now (correctly) parses all message types (other than + # message/rfc822 or message/global) as BodyTypeBasic. + class BodyTypeExtension < Struct.new(:media_type, :subtype, + :params, :content_id, + :description, :encoding, :size) + def multipart? + return false + end + end + + deprecate_constant :BodyTypeExtension + + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_parser/parser_utils.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_parser/parser_utils.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_parser/parser_utils.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_parser/parser_utils.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,240 @@ +# frozen_string_literal: true + +module Net + class IMAP < Protocol + class ResponseParser + # basic utility methods for parsing. + # + # (internal API, subject to change) + module ParserUtils # :nodoc: + + module Generator # :nodoc: + + LOOKAHEAD = "(@token ||= next_token)" + SHIFT_TOKEN = "(@token = nil)" + + # we can skip lexer for single character matches, as a shortcut + def def_char_matchers(name, char, token) + byte = char.ord + match_name = name.match(/\A[A-Z]/) ? "#{name}!" : name + char = char.dump + class_eval <<~RUBY, __FILE__, __LINE__ + 1 + # frozen_string_literal: true + + # force use of #next_token; no string peeking + def lookahead_#{name}? + #{LOOKAHEAD}&.symbol == #{token} + end + + # use token or string peek + def peek_#{name}? + @token ? @token.symbol == #{token} : @str.getbyte(@pos) == #{byte} + end + + # like accept(token_symbols); returns token or nil + def #{name}? + if @token&.symbol == #{token} + #{SHIFT_TOKEN} + #{char} + elsif !@token && @str.getbyte(@pos) == #{byte} + @pos += 1 + #{char} + end + end + + # like match(token_symbols); returns token or raises parse_error + def #{match_name} + if @token&.symbol == #{token} + #{SHIFT_TOKEN} + #{char} + elsif !@token && @str.getbyte(@pos) == #{byte} + @pos += 1 + #{char} + else + parse_error("unexpected %s (expected %p)", + @token&.symbol || @str[@pos].inspect, #{char}) + end + end + RUBY + end + + # TODO: move coersion to the token.value method? + def def_token_matchers(name, *token_symbols, coerce: nil, send: nil) + match_name = name.match(/\A[A-Z]/) ? "#{name}!" : name + + if token_symbols.size == 1 + token = token_symbols.first + matcher = "token&.symbol == %p" % [token] + desc = token + else + matcher = "%p.include? token&.symbol" % [token_symbols] + desc = token_symbols.join(" or ") + end + + value = "(token.value)" + value = coerce.to_s + value if coerce + value = [value, send].join(".") if send + + raise_parse_error = <<~RUBY + parse_error("unexpected %s (expected #{desc})", token&.symbol) + RUBY + + class_eval <<~RUBY, __FILE__, __LINE__ + 1 + # frozen_string_literal: true + + # lookahead version of match, returning the value + def lookahead_#{name}! + token = #{LOOKAHEAD} + if #{matcher} + #{value} + else + #{raise_parse_error} + end + end + + def #{name}? + token = #{LOOKAHEAD} + if #{matcher} + #{SHIFT_TOKEN} + #{value} + end + end + + def #{match_name} + token = #{LOOKAHEAD} + if #{matcher} + #{SHIFT_TOKEN} + #{value} + else + #{raise_parse_error} + end + end + RUBY + end + + end + + private + + # TODO: after checking the lookahead, use a regexp for remaining chars. + # That way a loop isn't needed. + def combine_adjacent(*tokens) + result = "".b + while token = accept(*tokens) + result << token.value + end + if result.empty? + parse_error('unexpected token %s (expected %s)', + lookahead.symbol, tokens.join(" or ")) + end + result + end + + def match(*args) + token = lookahead + unless args.include?(token.symbol) + parse_error('unexpected token %s (expected %s)', + token.symbol.id2name, + args.collect {|i| i.id2name}.join(" or ")) + end + shift_token + token + end + + # like match, but does not raise error on failure. + # + # returns and shifts token on successful match + # returns nil and leaves @token unshifted on no match + def accept(*args) + token = lookahead + if args.include?(token.symbol) + shift_token + token + end + end + + # To be used conditionally: + # assert_no_lookahead if config.debug? + def assert_no_lookahead + @token.nil? or + parse_error("assertion failed: expected @token.nil?, actual %s: %p", + @token.symbol, @token.value) + end + + # like accept, without consuming the token + def lookahead?(*symbols) + @token if symbols.include?((@token ||= next_token)&.symbol) + end + + def lookahead + @token ||= next_token + end + + # like match, without consuming the token + def lookahead!(*args) + if args.include?((@token ||= next_token)&.symbol) + @token + else + parse_error('unexpected token %s (expected %s)', + @token&.symbol, args.join(" or ")) + end + end + + def peek_str?(str) + assert_no_lookahead if config.debug? + @str[@pos, str.length] == str + end + + def peek_re(re) + assert_no_lookahead if config.debug? + re.match(@str, @pos) + end + + def accept_re(re) + assert_no_lookahead if config.debug? + re.match(@str, @pos) and @pos = $~.end(0) + $~ + end + + def match_re(re, name) + assert_no_lookahead if config.debug? + if re.match(@str, @pos) + @pos = $~.end(0) + $~ + else + parse_error("invalid #{name}") + end + end + + def shift_token + @token = nil + end + + def parse_error(fmt, *args) + msg = format(fmt, *args) + if config.debug? + local_path = File.dirname(__dir__) + tok = @token ? "%s: %p" % [@token.symbol, @token.value] : "nil" + warn "%s %s: %s" % [self.class, __method__, msg] + warn " tokenized : %s" % [@str[...@pos].dump] + warn " remaining : %s" % [@str[@pos..].dump] + warn " @lex_state: %s" % [@lex_state] + warn " @pos : %d" % [@pos] + warn " @token : %s" % [tok] + caller_locations(1..20).each_with_index do |cloc, idx| + next unless cloc.path&.start_with?(local_path) + warn " caller[%2d]: %-30s (%s:%d)" % [ + idx, + cloc.base_label, + File.basename(cloc.path, ".rb"), + cloc.lineno + ] + end + end + raise ResponseParseError, msg + end + + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_parser.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_parser.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_parser.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_parser.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,2148 @@ +# frozen_string_literal: true + +require_relative "errors" +require_relative "response_parser/parser_utils" + +module Net + class IMAP < Protocol + + # Parses an \IMAP server response. + class ResponseParser + include ParserUtils + extend ParserUtils::Generator + + attr_reader :config + + # Creates a new ResponseParser. + # + # When +config+ is frozen or global, the parser #config inherits from it. + # Otherwise, +config+ will be used directly. + def initialize(config: Config.global) + @str = nil + @pos = nil + @lex_state = nil + @token = nil + @config = Config[config] + @config = @config.new if @config == Config.global || @config.frozen? + end + + # :call-seq: + # parse(str) -> ContinuationRequest + # parse(str) -> UntaggedResponse + # parse(str) -> TaggedResponse + # + # Raises ResponseParseError for unparsable strings. + def parse(str) + @str = str + @pos = 0 + @lex_state = EXPR_BEG + @token = nil + return response + end + + private + + # :stopdoc: + + EXPR_BEG = :EXPR_BEG # the default, used in most places + EXPR_DATA = :EXPR_DATA # envelope, body(structure), namespaces + + T_SPACE = :SPACE # atom special + T_ATOM = :ATOM # atom (subset of astring chars) + T_NIL = :NIL # subset of atom and label + T_NUMBER = :NUMBER # subset of atom + T_LBRA = :LBRA # subset of atom + T_PLUS = :PLUS # subset of atom; tag special + T_RBRA = :RBRA # atom special; resp_special; valid astring char + T_QUOTED = :QUOTED # starts/end with atom special + T_BSLASH = :BSLASH # atom special; quoted special + T_LPAR = :LPAR # atom special; paren list delimiter + T_RPAR = :RPAR # atom special; paren list delimiter + T_STAR = :STAR # atom special; list wildcard + T_PERCENT = :PERCENT # atom special; list wildcard + T_LITERAL = :LITERAL # starts with atom special + T_LITERAL8 = :LITERAL8 # starts with atom char "~" + T_CRLF = :CRLF # atom special; text special; quoted special + T_TEXT = :TEXT # any char except CRLF + T_EOF = :EOF # end of response string + + module ResponseConditions + OK = "OK" + NO = "NO" + BAD = "BAD" + BYE = "BYE" + PREAUTH = "PREAUTH" + + RESP_COND_STATES = [OK, NO, BAD ].freeze + RESP_DATA_CONDS = [OK, NO, BAD, BYE, ].freeze + AUTH_CONDS = [OK, PREAUTH].freeze + GREETING_CONDS = [OK, BYE, PREAUTH].freeze + RESP_CONDS = [OK, NO, BAD, BYE, PREAUTH].freeze + end + include ResponseConditions + + module Patterns + + module CharClassSubtraction + refine Regexp do + def -(rhs); /[#{source}&&[^#{rhs.source}]]/n.freeze end + end + end + using CharClassSubtraction + + # From RFC5234, "Augmented BNF for Syntax Specifications: ABNF" + # >>> + # ALPHA = %x41-5A / %x61-7A ; A-Z / a-z + # CHAR = %x01-7F + # CRLF = CR LF + # ; Internet standard newline + # CTL = %x00-1F / %x7F + # ; controls + # DIGIT = %x30-39 + # ; 0-9 + # DQUOTE = %x22 + # ; " (Double Quote) + # HEXDIG = DIGIT / "A" / "B" / "C" / "D" / "E" / "F" + # OCTET = %x00-FF + # SP = %x20 + module RFC5234 + ALPHA = /[A-Za-z]/n + CHAR = /[\x01-\x7f]/n + CRLF = /\r\n/n + CTL = /[\x00-\x1F\x7F]/n + DIGIT = /\d/n + DQUOTE = /"/n + HEXDIG = /\h/ + OCTET = /[\x00-\xFF]/n # not using /./m for embedding purposes + SP = / /n + end + + # UTF-8, a transformation format of ISO 10646 + # >>> + # UTF8-1 = %x00-7F + # UTF8-tail = %x80-BF + # UTF8-2 = %xC2-DF UTF8-tail + # UTF8-3 = %xE0 %xA0-BF UTF8-tail / %xE1-EC 2( UTF8-tail ) / + # %xED %x80-9F UTF8-tail / %xEE-EF 2( UTF8-tail ) + # UTF8-4 = %xF0 %x90-BF 2( UTF8-tail ) / %xF1-F3 3( UTF8-tail ) / + # %xF4 %x80-8F 2( UTF8-tail ) + # UTF8-char = UTF8-1 / UTF8-2 / UTF8-3 / UTF8-4 + # UTF8-octets = *( UTF8-char ) + # + # n.b. String * Integer is used for repetition, rather than /x{3}/, + # because ruby 3.2's linear-time cache-based optimization doesn't work + # with "bounded or fixed times repetition nesting in another repetition + # (e.g. /(a{2,3})*/). It is an implementation issue entirely, but we + # believe it is hard to support this case correctly." + # See https://bugs.ruby-lang.org/issues/19104 + module RFC3629 + UTF8_1 = /[\x00-\x7f]/n # aka ASCII 7bit + UTF8_TAIL = /[\x80-\xBF]/n + UTF8_2 = /[\xC2-\xDF]#{UTF8_TAIL}/n + UTF8_3 = Regexp.union(/\xE0[\xA0-\xBF]#{UTF8_TAIL}/n, + /\xED[\x80-\x9F]#{UTF8_TAIL}/n, + /[\xE1-\xEC]#{ UTF8_TAIL.source * 2}/n, + /[\xEE-\xEF]#{ UTF8_TAIL.source * 2}/n) + UTF8_4 = Regexp.union(/[\xF1-\xF3]#{ UTF8_TAIL.source * 3}/n, + /\xF0[\x90-\xBF]#{UTF8_TAIL.source * 2}/n, + /\xF4[\x80-\x8F]#{UTF8_TAIL.source * 2}/n) + UTF8_CHAR = Regexp.union(UTF8_1, UTF8_2, UTF8_3, UTF8_4) + UTF8_OCTETS = /#{UTF8_CHAR}*/n + end + + include RFC5234 + include RFC3629 + + # CHAR8 = %x01-ff + # ; any OCTET except NUL, %x00 + CHAR8 = /[\x01-\xff]/n + + # list-wildcards = "%" / "*" + LIST_WILDCARDS = /[%*]/n + # quoted-specials = DQUOTE / "\" + QUOTED_SPECIALS = /["\\]/n + # resp-specials = "]" + RESP_SPECIALS = /[\]]/n + + # atomish = 1* + # ; We use "atomish" for msg-att and section, in order + # ; to simplify "BODY[HEADER.FIELDS (foo bar)]". + # + # atom-specials = "(" / ")" / "{" / SP / CTL / list-wildcards / + # quoted-specials / resp-specials + # ATOM-CHAR = + # atom = 1*ATOM-CHAR + # ASTRING-CHAR = ATOM-CHAR / resp-specials + # tag = 1* + + ATOM_SPECIALS = /[(){ \x00-\x1f\x7f%*"\\\]]/n + ASTRING_SPECIALS = /[(){ \x00-\x1f\x7f%*"\\]/n + + ASTRING_CHAR = CHAR - ASTRING_SPECIALS + ATOM_CHAR = CHAR - ATOM_SPECIALS + + ATOM = /#{ATOM_CHAR}+/n + ASTRING_CHARS = /#{ASTRING_CHAR}+/n + ATOMISH = /#{ATOM_CHAR - /[\[]/ }+/ + TAG = /#{ASTRING_CHAR - /[+]/ }+/ + + # TEXT-CHAR = + TEXT_CHAR = CHAR - /[\r\n]/ + + # resp-text-code = ... / atom [SP 1*] + CODE_TEXT_CHAR = TEXT_CHAR - RESP_SPECIALS + CODE_TEXT = /#{CODE_TEXT_CHAR}+/n + + # flag = "\Answered" / "\Flagged" / "\Deleted" / + # "\Seen" / "\Draft" / flag-keyword / flag-extension + # ; Does not include "\Recent" + # flag-extension = "\" atom + # ; Future expansion. Client implementations + # ; MUST accept flag-extension flags. Server + # ; implementations MUST NOT generate + # ; flag-extension flags except as defined by + # ; a future Standard or Standards Track + # ; revisions of this specification. + # flag-keyword = "$MDNSent" / "$Forwarded" / "$Junk" / + # "$NotJunk" / "$Phishing" / atom + # + # flag-perm = flag / "\*" + # + # Not checking for max one mbx-list-sflag in the parser. + # >>> + # mbx-list-oflag = "\Noinferiors" / child-mbox-flag / + # "\Subscribed" / "\Remote" / flag-extension + # ; Other flags; multiple from this list are + # ; possible per LIST response, but each flag + # ; can only appear once per LIST response + # mbx-list-sflag = "\NonExistent" / "\Noselect" / "\Marked" / + # "\Unmarked" + # ; Selectability flags; only one per LIST response + # child-mbox-flag = "\HasChildren" / "\HasNoChildren" + # ; attributes for the CHILDREN return option, at most + # ; one possible per LIST response + FLAG = /\\?#{ATOM}/n + FLAG_EXTENSION = /\\#{ATOM}/n + FLAG_KEYWORD = ATOM + FLAG_PERM = Regexp.union(FLAG, "\\*") + MBX_FLAG = FLAG_EXTENSION + + # flag-list = "(" [flag *(SP flag)] ")" + # resp-text-code =/ "PERMANENTFLAGS" SP + # "(" [flag-perm *(SP flag-perm)] ")" + # mbx-list-flags = *(mbx-list-oflag SP) mbx-list-sflag + # *(SP mbx-list-oflag) / + # mbx-list-oflag *(SP mbx-list-oflag) + # (Not checking for max one mbx-list-sflag in the parser.) + FLAG_LIST = /\G\((#{FLAG }(?:#{SP}#{FLAG })*|)\)/ni + FLAG_PERM_LIST = /\G\((#{FLAG_PERM}(?:#{SP}#{FLAG_PERM})*|)\)/ni + MBX_LIST_FLAGS = /\G (#{MBX_FLAG }(?:#{SP}#{MBX_FLAG })*) /nix + + # Gmail allows SP and "]" in flags....... + QUIRKY_FLAG = Regexp.union(/\\?#{ASTRING_CHARS}/n, "\\*") + QUIRKY_FLAGS_LIST = /\G\(( [^)]* )\)/nx + + # RFC3501: + # QUOTED-CHAR = / + # "\" quoted-specials + # RFC9051: + # QUOTED-CHAR = / + # "\" quoted-specials / UTF8-2 / UTF8-3 / UTF8-4 + # RFC3501 & RFC9051: + # quoted = DQUOTE *QUOTED-CHAR DQUOTE + QUOTED_CHAR_safe = TEXT_CHAR - QUOTED_SPECIALS + QUOTED_CHAR_esc = /\\#{QUOTED_SPECIALS}/n + QUOTED_CHAR_rev1 = Regexp.union(QUOTED_CHAR_safe, QUOTED_CHAR_esc) + QUOTED_CHAR_rev2 = Regexp.union(QUOTED_CHAR_rev1, + UTF8_2, UTF8_3, UTF8_4) + QUOTED_rev1 = /"(#{QUOTED_CHAR_rev1}*)"/n + QUOTED_rev2 = /"(#{QUOTED_CHAR_rev2}*)"/n + + # RFC3501: + # text = 1*TEXT-CHAR + # RFC9051: + # text = 1*(TEXT-CHAR / UTF8-2 / UTF8-3 / UTF8-4) + # ; Non-ASCII text can only be returned + # ; after ENABLE IMAP4rev2 command + TEXT_rev1 = /#{TEXT_CHAR}+/ + TEXT_rev2 = /#{Regexp.union TEXT_CHAR, UTF8_2, UTF8_3, UTF8_4}+/ + + # tagged-label-fchar = ALPHA / "-" / "_" / "." + TAGGED_LABEL_FCHAR = /[a-zA-Z\-_.]/n + # tagged-label-char = tagged-label-fchar / DIGIT / ":" + TAGGED_LABEL_CHAR = /[a-zA-Z\-_.0-9:]*/n + # tagged-ext-label = tagged-label-fchar *tagged-label-char + # ; Is a valid RFC 3501 "atom". + TAGGED_EXT_LABEL = /#{TAGGED_LABEL_FCHAR}#{TAGGED_LABEL_CHAR}*/n + + # nz-number = digit-nz *DIGIT + # ; Non-zero unsigned 32-bit integer + # ; (0 < n < 4,294,967,296) + NZ_NUMBER = /[1-9]\d*/n + + # seq-number = nz-number / "*" + # ; message sequence number (COPY, FETCH, STORE + # ; commands) or unique identifier (UID COPY, + # ; UID FETCH, UID STORE commands). + # ; * represents the largest number in use. In + # ; the case of message sequence numbers, it is + # ; the number of messages in a non-empty mailbox. + # ; In the case of unique identifiers, it is the + # ; unique identifier of the last message in the + # ; mailbox or, if the mailbox is empty, the + # ; mailbox's current UIDNEXT value. + # ; The server should respond with a tagged BAD + # ; response to a command that uses a message + # ; sequence number greater than the number of + # ; messages in the selected mailbox. This + # ; includes "*" if the selected mailbox is empty. + SEQ_NUMBER = /#{NZ_NUMBER}|\*/n + + # seq-range = seq-number ":" seq-number + # ; two seq-number values and all values between + # ; these two regardless of order. + # ; Example: 2:4 and 4:2 are equivalent and + # ; indicate values 2, 3, and 4. + # ; Example: a unique identifier sequence range of + # ; 3291:* includes the UID of the last message in + # ; the mailbox, even if that value is less than + # ; 3291. + SEQ_RANGE = /#{SEQ_NUMBER}:#{SEQ_NUMBER}/n + + # sequence-set = (seq-number / seq-range) ["," sequence-set] + # ; set of seq-number values, regardless of order. + # ; Servers MAY coalesce overlaps and/or execute + # ; the sequence in any order. + # ; Example: a message sequence number set of + # ; 2,4:7,9,12:* for a mailbox with 15 messages is + # ; equivalent to 2,4,5,6,7,9,12,13,14,15 + # ; Example: a message sequence number set of + # ; *:4,5:7 for a mailbox with 10 messages is + # ; equivalent to 10,9,8,7,6,5,4,5,6,7 and MAY + # ; be reordered and overlap coalesced to be + # ; 4,5,6,7,8,9,10. + SEQUENCE_SET_ITEM = /#{SEQ_NUMBER}|#{SEQ_RANGE}/n + SEQUENCE_SET = /#{SEQUENCE_SET_ITEM}(?:,#{SEQUENCE_SET_ITEM})*/n + SEQUENCE_SET_STR = /\A#{SEQUENCE_SET}\z/n + + # RFC3501: + # literal = "{" number "}" CRLF *CHAR8 + # ; Number represents the number of CHAR8s + # RFC9051: + # literal = "{" number64 ["+"] "}" CRLF *CHAR8 + # ; represents the number of CHAR8s. + # ; A non-synchronizing literal is distinguished + # ; from a synchronizing literal by the presence of + # ; "+" before the closing "}". + # ; Non-synchronizing literals are not allowed when + # ; sent from server to the client. + LITERAL = /\{(\d+)\}\r\n/n + + # RFC3516 (BINARY): + # literal8 = "~{" number "}" CRLF *OCTET + # ; represents the number of OCTETs + # ; in the response string. + # RFC9051: + # literal8 = "~{" number64 "}" CRLF *OCTET + # ; represents the number of OCTETs + # ; in the response string. + LITERAL8 = /~\{(\d+)\}\r\n/n + + module_function + + def unescape_quoted!(quoted) + quoted + &.gsub!(/\\(#{QUOTED_SPECIALS})/n, "\\1") + &.force_encoding("UTF-8") + end + + def unescape_quoted(quoted) + quoted + &.gsub(/\\(#{QUOTED_SPECIALS})/n, "\\1") + &.force_encoding("UTF-8") + end + + end + + # the default, used in most places + BEG_REGEXP = /\G(?:\ +(?# 1: SPACE )( )|\ +(?# 2: LITERAL8)#{Patterns::LITERAL8}|\ +(?# 3: ATOM prefixed with a compatible subtype)\ +((?:\ +(?# 4: NIL )(NIL)|\ +(?# 5: NUMBER )(\d+)|\ +(?# 6: PLUS )(\+))\ +(?# 7: ATOM remaining after prefix )(#{Patterns::ATOMISH})?\ +(?# This enables greedy alternation without lookahead, in linear time.)\ +)|\ +(?# Also need to check for ATOM without a subtype prefix.)\ +(?# 8: ATOM )(#{Patterns::ATOMISH})|\ +(?# 9: QUOTED )#{Patterns::QUOTED_rev2}|\ +(?# 10: LPAR )(\()|\ +(?# 11: RPAR )(\))|\ +(?# 12: BSLASH )(\\)|\ +(?# 13: STAR )(\*)|\ +(?# 14: LBRA )(\[)|\ +(?# 15: RBRA )(\])|\ +(?# 16: LITERAL )#{Patterns::LITERAL}|\ +(?# 17: PERCENT )(%)|\ +(?# 18: CRLF )(\r\n)|\ +(?# 19: EOF )(\z))/ni + + # envelope, body(structure), namespaces + DATA_REGEXP = /\G(?:\ +(?# 1: SPACE )( )|\ +(?# 2: NIL )(NIL)|\ +(?# 3: NUMBER )(\d+)|\ +(?# 4: QUOTED )#{Patterns::QUOTED_rev2}|\ +(?# 5: LITERAL )#{Patterns::LITERAL}|\ +(?# 6: LPAR )(\()|\ +(?# 7: RPAR )(\)))/ni + + # text, after 'resp-text-code "]"' + TEXT_REGEXP = /\G(#{Patterns::TEXT_rev2})/n + + # resp-text-code, after 'atom SP' + CTEXT_REGEXP = /\G(#{Patterns::CODE_TEXT})/n + + Token = Struct.new(:symbol, :value) + + def_char_matchers :SP, " ", :T_SPACE + def_char_matchers :PLUS, "+", :T_PLUS + def_char_matchers :STAR, "*", :T_STAR + + def_char_matchers :lpar, "(", :T_LPAR + def_char_matchers :rpar, ")", :T_RPAR + + def_char_matchers :lbra, "[", :T_LBRA + def_char_matchers :rbra, "]", :T_RBRA + + # valid number ranges are not enforced by parser + # number = 1*DIGIT + # ; Unsigned 32-bit integer + # ; (0 <= n < 4,294,967,296) + def_token_matchers :number, T_NUMBER, coerce: Integer + + def_token_matchers :quoted, T_QUOTED + + # string = quoted / literal + def_token_matchers :string, T_QUOTED, T_LITERAL + + # used by nstring8 = nstring / literal8 + def_token_matchers :string8, T_QUOTED, T_LITERAL, T_LITERAL8 + + # use where string represents "LABEL" values + def_token_matchers :case_insensitive__string, + T_QUOTED, T_LITERAL, + send: :upcase + + # n.b: NIL? and NIL! return the "NIL" atom string (truthy) on success. + # NIL? returns nil when it does *not* match + def_token_matchers :NIL, T_NIL + + # In addition to explicitly uses of +tagged-ext-label+, use this to match + # keywords when the grammar has not provided any extension syntax. + # + # Do *not* use this for labels where the grammar specifies extensions + # can be +atom+, even if all currently defined labels would match. For + # example response codes in +resp-text-code+. + # + # tagged-ext-label = tagged-label-fchar *tagged-label-char + # ; Is a valid RFC 3501 "atom". + # tagged-label-fchar = ALPHA / "-" / "_" / "." + # tagged-label-char = tagged-label-fchar / DIGIT / ":" + # + # TODO: add to lexer and only match tagged-ext-label + def_token_matchers :tagged_ext_label, T_ATOM, T_NIL, send: :upcase + + def_token_matchers :CRLF, T_CRLF + def_token_matchers :EOF, T_EOF + + # atom = 1*ATOM-CHAR + # ATOM-CHAR = + ATOM_TOKENS = [T_ATOM, T_NUMBER, T_NIL, T_LBRA, T_PLUS] + + SEQUENCE_SET_TOKENS = [T_ATOM, T_NUMBER, T_STAR] + + # sequence-set = (seq-number / seq-range) ["," sequence-set] + # sequence-set =/ seq-last-command + # ; Allow for "result of the last command" + # ; indicator. + # seq-last-command = "$" + # + # *note*: doesn't match seq-last-command + def sequence_set + str = combine_adjacent(*SEQUENCE_SET_TOKENS) + if Patterns::SEQUENCE_SET_STR.match?(str) + SequenceSet[str] + else + parse_error("unexpected atom %p, expected sequence-set", str) + end + end + + # ASTRING-CHAR = ATOM-CHAR / resp-specials + # resp-specials = "]" + ASTRING_CHARS_TOKENS = [*ATOM_TOKENS, T_RBRA].freeze + + ASTRING_TOKENS = [T_QUOTED, *ASTRING_CHARS_TOKENS, T_LITERAL].freeze + + # tag = 1* + TAG_TOKENS = (ASTRING_CHARS_TOKENS - [T_PLUS]).freeze + + # TODO: handle atom, astring_chars, and tag entirely inside the lexer + def atom; combine_adjacent(*ATOM_TOKENS) end + def astring_chars; combine_adjacent(*ASTRING_CHARS_TOKENS) end + def tag; combine_adjacent(*TAG_TOKENS) end + + # the #accept version of #atom + def atom?; -combine_adjacent(*ATOM_TOKENS) if lookahead?(*ATOM_TOKENS) end + + # Returns atom.upcase + def case_insensitive__atom; -combine_adjacent(*ATOM_TOKENS).upcase end + + # Returns atom?&.upcase + def case_insensitive__atom? + -combine_adjacent(*ATOM_TOKENS).upcase if lookahead?(*ATOM_TOKENS) + end + + # astring = 1*ASTRING-CHAR / string + def astring + lookahead?(*ASTRING_CHARS_TOKENS) ? astring_chars : string + end + + def astring? + lookahead?(*ASTRING_CHARS_TOKENS) ? astring_chars : string? + end + + # Use #label or #label_in to assert specific known labels + # (+tagged-ext-label+ only, not +atom+). + def label(word) + (val = tagged_ext_label) == word and return val + parse_error("unexpected atom %p, expected %p instead", val, word) + end + + # Use #label or #label_in to assert specific known labels + # (+tagged-ext-label+ only, not +atom+). + def label_in(*labels) + lbl = tagged_ext_label and labels.include?(lbl) and return lbl + parse_error("unexpected atom %p, expected one of %s instead", + lbl, labels.join(" or ")) + end + + # expects "OK" or "PREAUTH" and raises InvalidResponseError on failure + def resp_cond_auth__name + lbl = tagged_ext_label and AUTH_CONDS.include? lbl and return lbl + raise InvalidResponseError, "bad response type %p, expected %s" % [ + lbl, AUTH_CONDS.join(" or ") + ] + end + + # expects "OK" or "NO" or "BAD" and raises InvalidResponseError on failure + def resp_cond_state__name + lbl = tagged_ext_label and RESP_COND_STATES.include? lbl and return lbl + raise InvalidResponseError, "bad response type %p, expected %s" % [ + lbl, RESP_COND_STATES.join(" or ") + ] + end + + # nstring = string / nil + def nstring + NIL? ? nil : string + end + + def nstring8 + NIL? ? nil : string8 + end + + def nquoted + NIL? ? nil : quoted + end + + # use where nstring represents "LABEL" values + def case_insensitive__nstring + NIL? ? nil : case_insensitive__string + end + + # tagged-ext-comp = astring / + # tagged-ext-comp *(SP tagged-ext-comp) / + # "(" tagged-ext-comp ")" + # ; Extensions that follow this general + # ; syntax should use nstring instead of + # ; astring when appropriate in the context + # ; of the extension. + # ; Note that a message set or a "number" + # ; can always be represented as an "atom". + # ; A URL should be represented as + # ; a "quoted" string. + def tagged_ext_comp + vals = [] + while true + vals << case lookahead!(*ASTRING_TOKENS, T_LPAR).symbol + when T_LPAR then lpar; ary = tagged_ext_comp; rpar; ary + when T_NUMBER then number + else astring + end + SP? or break + end + vals + end + + # tagged-ext-simple is a subset of atom + # TODO: recognize sequence-set in the lexer + # + # tagged-ext-simple = sequence-set / number / number64 + def tagged_ext_simple + number? || sequence_set + end + + # tagged-ext-val = tagged-ext-simple / + # "(" [tagged-ext-comp] ")" + def tagged_ext_val + if lpar? + _ = peek_rpar? ? [] : tagged_ext_comp + rpar + _ + else + tagged_ext_simple + end + end + + # mailbox = "INBOX" / astring + # ; INBOX is case-insensitive. All case variants of + # ; INBOX (e.g., "iNbOx") MUST be interpreted as INBOX + # ; not as an astring. An astring which consists of + # ; the case-insensitive sequence "I" "N" "B" "O" "X" + # ; is considered to be INBOX and not an astring. + # ; Refer to section 5.1 for further + # ; semantic details of mailbox names. + alias mailbox astring + + # valid number ranges are not enforced by parser + # number64 = 1*DIGIT + # ; Unsigned 63-bit integer + # ; (0 <= n <= 9,223,372,036,854,775,807) + alias number64 number + alias number64? number? + + # valid number ranges are not enforced by parser + # nz-number = digit-nz *DIGIT + # ; Non-zero unsigned 32-bit integer + # ; (0 < n < 4,294,967,296) + alias nz_number number + alias nz_number? number? + + # valid number ranges are not enforced by parser + # nz-number64 = digit-nz *DIGIT + # ; Unsigned 63-bit integer + # ; (0 < n <= 9,223,372,036,854,775,807) + alias nz_number64 nz_number + + # valid number ranges are not enforced by parser + # uniqueid = nz-number + # ; Strictly ascending + alias uniqueid nz_number + + # valid number ranges are not enforced by parser + # + # a 64-bit unsigned integer and is the decimal equivalent for the ID hex + # string used in the web interface and the Gmail API. + alias x_gm_id number + + # [RFC3501 & RFC9051:] + # response = *(continue-req / response-data) response-done + # + # For simplicity, response isn't interpreted as the combination of the + # three response types, but instead represents any individual server + # response. Our simplified interpretation is defined as: + # response = continue-req | response_data | response-tagged + # + # n.b: our "response-tagged" definition parses "greeting" too. + def response + resp = case lookahead!(T_PLUS, T_STAR, *TAG_TOKENS).symbol + when T_PLUS then continue_req + when T_STAR then response_data + else response_tagged + end + accept_spaces # QUIRKY: Ignore trailing space (MS Exchange Server?) + CRLF! + EOF! + resp + end + + # RFC3501 & RFC9051: + # continue-req = "+" SP (resp-text / base64) CRLF + # + # n.b: base64 is valid resp-text. And in the spirit of RFC9051 Appx E 23 + # (and to workaround existing servers), we use the following grammar: + # + # continue-req = "+" (SP (resp-text)) CRLF + def continue_req + PLUS! + ContinuationRequest.new(SP? ? resp_text : ResponseText::EMPTY, @str) + end + + RE_RESPONSE_TYPE = /\G(?:\d+ )?(?#{Patterns::TAGGED_EXT_LABEL})/n + + # [RFC3501:] + # response-data = "*" SP (resp-cond-state / resp-cond-bye / + # mailbox-data / message-data / capability-data) CRLF + # [RFC4466:] + # response-data = "*" SP response-payload CRLF + # response-payload = resp-cond-state / resp-cond-bye / + # mailbox-data / message-data / capability-data + # RFC5161 (ENABLE capability): + # response-data =/ "*" SP enable-data CRLF + # RFC5255 (LANGUAGE capability) + # response-payload =/ language-data + # RFC5255 (I18NLEVEL=1 and I18NLEVEL=2 capabilities) + # response-payload =/ comparator-data + # [RFC9051:] + # response-data = "*" SP (resp-cond-state / resp-cond-bye / + # mailbox-data / message-data / capability-data / + # enable-data) CRLF + # + # [merging in greeting and response-fatal:] + # greeting = "*" SP (resp-cond-auth / resp-cond-bye) CRLF + # response-fatal = "*" SP resp-cond-bye CRLF + # response-data =/ "*" SP (resp-cond-auth / resp-cond-bye) CRLF + # [removing duplicates, this is simply] + # response-payload =/ resp-cond-auth + # + # TODO: remove resp-cond-auth and handle greeting separately + def response_data + STAR!; SP! + m = peek_re(RE_RESPONSE_TYPE) or parse_error("unparsable response") + case m["type"].upcase + when "OK" then resp_cond_state__untagged # RFC3501, RFC9051 + when "FETCH" then message_data__fetch # RFC3501, RFC9051 + when "EXPUNGE" then message_data__expunge # RFC3501, RFC9051 + when "EXISTS" then mailbox_data__exists # RFC3501, RFC9051 + when "ESEARCH" then esearch_response # RFC4731, RFC9051, etc + when "VANISHED" then expunged_resp # RFC7162 + when "UIDFETCH" then uidfetch_resp # (draft) UIDONLY + when "SEARCH" then mailbox_data__search # RFC3501 (obsolete) + when "CAPABILITY" then capability_data__untagged # RFC3501, RFC9051 + when "FLAGS" then mailbox_data__flags # RFC3501, RFC9051 + when "LIST" then mailbox_data__list # RFC3501, RFC9051 + when "STATUS" then mailbox_data__status # RFC3501, RFC9051 + when "NAMESPACE" then namespace_response # RFC2342, RFC9051 + when "ENABLED" then enable_data # RFC5161, RFC9051 + when "BAD" then resp_cond_state__untagged # RFC3501, RFC9051 + when "NO" then resp_cond_state__untagged # RFC3501, RFC9051 + when "PREAUTH" then resp_cond_auth # RFC3501, RFC9051 + when "BYE" then resp_cond_bye # RFC3501, RFC9051 + when "RECENT" then mailbox_data__recent # RFC3501 (obsolete) + when "SORT" then sort_data # RFC5256, RFC7162 + when "THREAD" then thread_data # RFC5256 + when "QUOTA" then quota_response # RFC2087, RFC9208 + when "QUOTAROOT" then quotaroot_response # RFC2087, RFC9208 + when "ID" then id_response # RFC2971 + when "ACL" then acl_data # RFC4314 + when "LISTRIGHTS" then listrights_data # RFC4314 + when "MYRIGHTS" then myrights_data # RFC4314 + when "METADATA" then metadata_resp # RFC5464 + when "LANGUAGE" then language_data # RFC5255 + when "COMPARATOR" then comparator_data # RFC5255 + when "CONVERTED" then message_data__converted # RFC5259 + when "LSUB" then mailbox_data__lsub # RFC3501 (obsolete) + when "XLIST" then mailbox_data__xlist # deprecated + when "NOOP" then response_data__noop + else response_data__unhandled + end + end + + def response_data__unhandled(klass = UntaggedResponse) + num = number?; SP? + type = tagged_ext_label; SP? + text = remaining_unparsed + data = + if num && text then UnparsedNumericResponseData.new(num, text) + elsif text then UnparsedData.new(text) + else num + end + klass.new(type, data, @str) + end + + # reads all the way up until CRLF + def remaining_unparsed + str = @str[@pos...-2] and @pos += str.bytesize + str&.empty? ? nil : str + end + + def response_data__ignored; response_data__unhandled(IgnoredResponse) end + alias response_data__noop response_data__ignored + + alias esearch_response response_data__unhandled + alias expunged_resp response_data__unhandled + alias uidfetch_resp response_data__unhandled + alias listrights_data response_data__unhandled + alias myrights_data response_data__unhandled + alias metadata_resp response_data__unhandled + alias language_data response_data__unhandled + alias comparator_data response_data__unhandled + alias message_data__converted response_data__unhandled + + # RFC3501 & RFC9051: + # response-tagged = tag SP resp-cond-state CRLF + def response_tagged + TaggedResponse.new(tag, *(SP!; resp_cond_state), @str) + end + + # RFC3501 & RFC9051: + # resp-cond-state = ("OK" / "NO" / "BAD") SP resp-text + # + # NOTE: In the spirit of RFC9051 Appx E 23 (and to workaround existing + # servers), we don't require a final SP and instead parse this as: + # + # resp-cond-state = ("OK" / "NO" / "BAD") [SP resp-text] + def resp_cond_state + [resp_cond_state__name, SP? ? resp_text : ResponseText::EMPTY] + end + + def resp_cond_state__untagged + UntaggedResponse.new(*resp_cond_state, @str) + end + + # resp-cond-auth = ("OK" / "PREAUTH") SP resp-text + # + # NOTE: In the spirit of RFC9051 Appx E 23 (and to workaround existing + # servers), we don't require a final SP and instead parse this as: + # + # resp-cond-auth = ("OK" / "PREAUTH") [SP resp-text] + def resp_cond_auth + UntaggedResponse.new(resp_cond_auth__name, + SP? ? resp_text : ResponseText::EMPTY, + @str) + end + + # resp-cond-bye = "BYE" SP resp-text + # + # NOTE: In the spirit of RFC9051 Appx E 23 (and to workaround existing + # servers), we don't require a final SP and instead parse this as: + # + # resp-cond-bye = "BYE" [SP resp-text] + def resp_cond_bye + UntaggedResponse.new(label(BYE), + SP? ? resp_text : ResponseText::EMPTY, + @str) + end + + # message-data = nz-number SP ("EXPUNGE" / ("FETCH" SP msg-att)) + def message_data__fetch + seq = nz_number; SP! + name = label "FETCH"; SP! + data = FetchData.new(seq, msg_att(seq)) + UntaggedResponse.new(name, data, @str) + end + + def response_data__simple_numeric + data = nz_number; SP! + name = tagged_ext_label + UntaggedResponse.new(name, data, @str) + end + + alias message_data__expunge response_data__simple_numeric + alias mailbox_data__exists response_data__simple_numeric + alias mailbox_data__recent response_data__simple_numeric + + # RFC3501 & RFC9051: + # msg-att = "(" (msg-att-dynamic / msg-att-static) + # *(SP (msg-att-dynamic / msg-att-static)) ")" + # + # msg-att-dynamic = "FLAGS" SP "(" [flag-fetch *(SP flag-fetch)] ")" + # RFC5257 (ANNOTATE extension): + # msg-att-dynamic =/ "ANNOTATION" SP + # ( "(" entry-att *(SP entry-att) ")" / + # "(" entry *(SP entry) ")" ) + # RFC7162 (CONDSTORE extension): + # msg-att-dynamic =/ fetch-mod-resp + # fetch-mod-resp = "MODSEQ" SP "(" permsg-modsequence ")" + # RFC8970 (PREVIEW extension): + # msg-att-dynamic =/ "PREVIEW" SP nstring + # + # RFC3501: + # msg-att-static = "ENVELOPE" SP envelope / + # "INTERNALDATE" SP date-time / + # "RFC822" [".HEADER" / ".TEXT"] SP nstring / + # "RFC822.SIZE" SP number / + # "BODY" ["STRUCTURE"] SP body / + # "BODY" section ["<" number ">"] SP nstring / + # "UID" SP uniqueid + # RFC3516 (BINARY extension): + # msg-att-static =/ "BINARY" section-binary SP (nstring / literal8) + # / "BINARY.SIZE" section-binary SP number + # RFC8514 (SAVEDATE extension): + # msg-att-static =/ "SAVEDATE" SP (date-time / nil) + # RFC8474 (OBJECTID extension): + # msg-att-static =/ fetch-emailid-resp / fetch-threadid-resp + # fetch-emailid-resp = "EMAILID" SP "(" objectid ")" + # fetch-threadid-resp = "THREADID" SP ( "(" objectid ")" / nil ) + # RFC9051: + # msg-att-static = "ENVELOPE" SP envelope / + # "INTERNALDATE" SP date-time / + # "RFC822.SIZE" SP number64 / + # "BODY" ["STRUCTURE"] SP body / + # "BODY" section ["<" number ">"] SP nstring / + # "BINARY" section-binary SP (nstring / literal8) / + # "BINARY.SIZE" section-binary SP number / + # "UID" SP uniqueid + # + # Re https://www.rfc-editor.org/errata/eid7246, I'm adding "offset" to the + # official "BINARY" ABNF, like so: + # + # msg-att-static =/ "BINARY" section-binary ["<" number ">"] SP + # (nstring / literal8) + def msg_att(n) + lpar + attr = {} + while true + name = msg_att__label; SP! + val = + case name + when "UID" then uniqueid + when "FLAGS" then flag_list + when "BODY" then body + when /\ABODY\[/ni then nstring + when "BODYSTRUCTURE" then body + when "ENVELOPE" then envelope + when "INTERNALDATE" then date_time + when "RFC822.SIZE" then number64 + when /\ABINARY\[/ni then nstring8 # BINARY, IMAP4rev2 + when /\ABINARY\.SIZE\[/ni then number # BINARY, IMAP4rev2 + when "RFC822" then nstring # not in rev2 + when "RFC822.HEADER" then nstring # not in rev2 + when "RFC822.TEXT" then nstring # not in rev2 + when "MODSEQ" then parens__modseq # CONDSTORE + when "EMAILID" then parens__objectid # OBJECTID + when "THREADID" then nparens__objectid # OBJECTID + when "X-GM-MSGID" then x_gm_id # GMail + when "X-GM-THRID" then x_gm_id # GMail + when "X-GM-LABELS" then x_gm_labels # GMail + else parse_error("unknown attribute `%s' for {%d}", name, n) + end + attr[name] = val + break unless SP? + break if lookahead_rpar? + end + rpar + attr + end + + # appends "[section]" and "" to the base label + def msg_att__label + case (name = tagged_ext_label) + when /\A(?:RFC822(?:\.HEADER|\.TEXT)?)\z/ni + # ignoring "[]" fixes https://bugs.ruby-lang.org/issues/5620 + lbra? and rbra + when "BODY" + peek_lbra? and name << section and + peek_str?("<") and name << gt__number__lt # partial + when "BINARY", "BINARY.SIZE" + name << section_binary + # see https://www.rfc-editor.org/errata/eid7246 and the note above + peek_str?("<") and name << gt__number__lt # partial + end + name + end + + # this represents the partial size for BODY or BINARY + alias gt__number__lt atom + + # RFC3501 & RFC9051: + # envelope = "(" env-date SP env-subject SP env-from SP + # env-sender SP env-reply-to SP env-to SP env-cc SP + # env-bcc SP env-in-reply-to SP env-message-id ")" + def envelope + @lex_state = EXPR_DATA + lpar; date = env_date + SP!; subject = env_subject + SP!; from = env_from + SP!; sender = env_sender + SP!; reply_to = env_reply_to + SP!; to = env_to + SP!; cc = env_cc + SP!; bcc = env_bcc + SP!; in_reply_to = env_in_reply_to + SP!; message_id = env_message_id + rpar + Envelope.new(date, subject, from, sender, reply_to, + to, cc, bcc, in_reply_to, message_id) + ensure + @lex_state = EXPR_BEG + end + + # env-date = nstring + # env-subject = nstring + # env-in-reply-to = nstring + # env-message-id = nstring + alias env_date nstring + alias env_subject nstring + alias env_in_reply_to nstring + alias env_message_id nstring + + # env-from = "(" 1*address ")" / nil + # env-sender = "(" 1*address ")" / nil + # env-reply-to = "(" 1*address ")" / nil + # env-to = "(" 1*address ")" / nil + # env-cc = "(" 1*address ")" / nil + # env-bcc = "(" 1*address ")" / nil + def nlist__address + return if NIL? + lpar; list = [address]; list << address until (quirky_SP?; rpar?) + list + end + + alias env_from nlist__address + alias env_sender nlist__address + alias env_reply_to nlist__address + alias env_to nlist__address + alias env_cc nlist__address + alias env_bcc nlist__address + + # Used when servers erroneously send an extra SP. + # + # As of 2023-11-28, Outlook.com (still) sends SP + # between +address+ in env-* lists. + alias quirky_SP? SP? + + # date-time = DQUOTE date-day-fixed "-" date-month "-" date-year + # SP time SP zone DQUOTE + alias date_time quoted + alias ndatetime nquoted + + # RFC-3501 & RFC-9051: + # body = "(" (body-type-1part / body-type-mpart) ")" + def body + @lex_state = EXPR_DATA + lpar; result = peek_lpar? ? body_type_mpart : body_type_1part; rpar + result + ensure + @lex_state = EXPR_BEG + end + alias lookahead_body? lookahead_lpar? + + # RFC-3501 & RFC9051: + # body-type-1part = (body-type-basic / body-type-msg / body-type-text) + # [SP body-ext-1part] + def body_type_1part + # This regexp peek is a performance optimization. + # The lookahead fallback would work fine too. + m = peek_re(/\G(?: + (? "TEXT" \s "[^"]+" ) + |(? "MESSAGE" \s "(?:RFC822|GLOBAL)" ) + |(? "[^"]+" \s "[^"]+" ) + |(? "MIXED" ) + )/nix) + choice = m&.named_captures&.compact&.keys&.first + # In practice, the following line should never be used. But the ABNF + # *does* allow literals, and this will handle them. + choice ||= lookahead_case_insensitive__string! + case choice + when "BASIC" then body_type_basic # => BodyTypeBasic + when "MESSAGE" then body_type_msg # => BodyTypeMessage | BodyTypeBasic + when "TEXT" then body_type_text # => BodyTypeText + when "MIXED" then body_type_mixed # => BodyTypeMultipart (server bug) + else body_type_basic # might be a bug; server's or ours? + end + end + + # RFC-3501 & RFC9051: + # body-type-basic = media-basic SP body-fields + def body_type_basic + type = media_basic # n.b. "basic" type isn't enforced here + if lookahead_rpar? then return BodyTypeBasic.new(*type) end # invalid + SP!; flds = body_fields + SP? and exts = body_ext_1part + BodyTypeBasic.new(*type, *flds, *exts) + end + + # RFC-3501 & RFC-9051: + # body-type-text = media-text SP body-fields SP body-fld-lines + def body_type_text + type = media_text + SP!; flds = body_fields + SP!; lines = body_fld_lines + SP? and exts = body_ext_1part + BodyTypeText.new(*type, *flds, lines, *exts) + end + + # RFC-3501 & RFC-9051: + # body-type-msg = media-message SP body-fields SP envelope + # SP body SP body-fld-lines + def body_type_msg + # n.b. "message/rfc822" type isn't enforced here + type = media_message + SP!; flds = body_fields + + # Sometimes servers send body-type-basic when body-type-msg should be. + # E.g: when a message/rfc822 part has "Content-Disposition: attachment". + # + # * SP "(" --> SP envelope --> continue as body-type-msg + # * ")" --> no body-ext-1part --> completed body-type-basic + # * SP nstring --> SP body-fld-md5 + # --> SP body-ext-1part --> continue as body-type-basic + # + # It's probably better to return BodyTypeBasic---even for + # "message/rfc822"---than BodyTypeMessage with invalid fields. + unless peek_str?(" (") + SP? and exts = body_ext_1part + return BodyTypeBasic.new(*type, *flds, *exts) + end + + SP!; env = envelope + SP!; bdy = body + SP!; lines = body_fld_lines + SP? and exts = body_ext_1part + BodyTypeMessage.new(*type, *flds, env, bdy, lines, *exts) + end + + # This is a malformed body-type-mpart with no subparts. + def body_type_mixed + # warn "malformed body-type-mpart: multipart/mixed with no parts." + type = media_subtype # => "MIXED" + SP? and exts = body_ext_mpart + BodyTypeMultipart.new("MULTIPART", type, nil, *exts) + end + + # RFC-3501 & RFC-9051: + # body-type-mpart = 1*body SP media-subtype + # [SP body-ext-mpart] + def body_type_mpart + parts = [body]; parts << body until SP?; msubtype = media_subtype + SP? and exts = body_ext_mpart + BodyTypeMultipart.new("MULTIPART", msubtype, parts, *exts) + end + + # n.b. this handles both type and subtype + # + # RFC-3501 vs RFC-9051: + # media-basic = ((DQUOTE ("APPLICATION" / "AUDIO" / "IMAGE" / + # "MESSAGE" / + # "VIDEO") DQUOTE) / string) SP media-subtype + # media-basic = ((DQUOTE ("APPLICATION" / "AUDIO" / "IMAGE" / + # "FONT" / "MESSAGE" / "MODEL" / + # "VIDEO") DQUOTE) / string) SP media-subtype + # + # media-message = DQUOTE "MESSAGE" DQUOTE SP + # DQUOTE "RFC822" DQUOTE + # media-message = DQUOTE "MESSAGE" DQUOTE SP + # DQUOTE ("RFC822" / "GLOBAL") DQUOTE + # + # RFC-3501 & RFC-9051: + # media-text = DQUOTE "TEXT" DQUOTE SP media-subtype + # media-subtype = string + def media_type + mtype = case_insensitive__string + SP? or return mtype, nil # ??? quirky! + msubtype = media_subtype + return mtype, msubtype + end + + # TODO: check types + alias media_basic media_type # */* --- catchall + alias media_message media_type # message/rfc822, message/global + alias media_text media_type # text/* + + alias media_subtype case_insensitive__string + + # RFC-3501 & RFC-9051: + # body-fields = body-fld-param SP body-fld-id SP body-fld-desc SP + # body-fld-enc SP body-fld-octets + def body_fields + fields = [] + fields << body_fld_param; SP! + fields << body_fld_id; SP! + fields << body_fld_desc; SP! + fields << body_fld_enc; SP! + fields << body_fld_octets + fields + end + + # RFC3501, RFC9051: + # body-fld-param = "(" string SP string *(SP string SP string) ")" / nil + def body_fld_param + quirky_SP? # See comments on test_bodystructure_extra_space + return if NIL? + param = {} + lpar + name = case_insensitive__string; SP!; param[name] = string + while SP? + name = case_insensitive__string; SP!; param[name] = string + end + rpar + param + end + + # RFC2060 + # body_ext_1part ::= body_fld_md5 [SPACE body_fld_dsp + # [SPACE body_fld_lang + # [SPACE 1#body_extension]]] + # ;; MUST NOT be returned on non-extensible + # ;; "BODY" fetch + # RFC3501 & RFC9051 + # body-ext-1part = body-fld-md5 [SP body-fld-dsp [SP body-fld-lang + # [SP body-fld-loc *(SP body-extension)]]] + # ; MUST NOT be returned on non-extensible + # ; "BODY" fetch + def body_ext_1part + fields = []; fields << body_fld_md5 + SP? or return fields; fields << body_fld_dsp + SP? or return fields; fields << body_fld_lang + SP? or return fields; fields << body_fld_loc + SP? or return fields; fields << body_extensions + fields + end + + # RFC-2060: + # body_ext_mpart = body_fld_param [SP body_fld_dsp SP body_fld_lang + # [SP 1#body_extension]] + # ;; MUST NOT be returned on non-extensible + # ;; "BODY" fetch + # RFC-3501 & RFC-9051: + # body-ext-mpart = body-fld-param [SP body-fld-dsp [SP body-fld-lang + # [SP body-fld-loc *(SP body-extension)]]] + # ; MUST NOT be returned on non-extensible + # ; "BODY" fetch + def body_ext_mpart + fields = []; fields << body_fld_param + SP? or return fields; fields << body_fld_dsp + SP? or return fields; fields << body_fld_lang + SP? or return fields; fields << body_fld_loc + SP? or return fields; fields << body_extensions + fields + end + + alias body_fld_desc nstring + alias body_fld_id nstring + alias body_fld_loc nstring + alias body_fld_lines number64 # number in 3501, number64 in 9051 + alias body_fld_md5 nstring + alias body_fld_octets number + + # RFC-3501 & RFC-9051: + # body-fld-enc = (DQUOTE ("7BIT" / "8BIT" / "BINARY" / "BASE64"/ + # "QUOTED-PRINTABLE") DQUOTE) / string + alias body_fld_enc case_insensitive__string + + # body-fld-dsp = "(" string SP body-fld-param ")" / nil + def body_fld_dsp + return if NIL? + lpar; dsp_type = case_insensitive__string + SP!; param = body_fld_param + rpar + ContentDisposition.new(dsp_type, param) + end + + # body-fld-lang = nstring / "(" string *(SP string) ")" + def body_fld_lang + if lpar? + result = [case_insensitive__string] + result << case_insensitive__string while SP? + rpar + result + else + case_insensitive__nstring + end + end + + # body-extension *(SP body-extension) + def body_extensions + result = [] + result << body_extension; while SP? do result << body_extension end + result + end + + # body-extension = nstring / number / number64 / + # "(" body-extension *(SP body-extension) ")" + # ; Future expansion. Client implementations + # ; MUST accept body-extension fields. Server + # ; implementations MUST NOT generate + # ; body-extension fields except as defined by + # ; future Standard or Standards Track + # ; revisions of this specification. + def body_extension + if (uint = number64?) then uint + elsif lpar? then exts = body_extensions; rpar; exts + else nstring + end + end + + # section = "[" [section-spec] "]" + def section + str = +lbra + str << section_spec unless peek_rbra? + str << rbra + end + + # section-binary = "[" [section-part] "]" + def section_binary + str = +lbra + str << section_part unless peek_rbra? + str << rbra + end + + # section-spec = section-msgtext / (section-part ["." section-text]) + # section-msgtext = "HEADER" / + # "HEADER.FIELDS" [".NOT"] SP header-list / + # "TEXT" + # ; top-level or MESSAGE/RFC822 or + # ; MESSAGE/GLOBAL part + # section-part = nz-number *("." nz-number) + # ; body part reference. + # ; Allows for accessing nested body parts. + # section-text = section-msgtext / "MIME" + # ; text other than actual body part (headers, + # ; etc.) + # + # n.b: we could "cheat" here and just grab all text inside the brackets, + # but literals would need special treatment. + def section_spec + str = "".b + str << atom # grabs everything up to "SP header-list" or "]" + str << " " << header_list if SP? + str + end + + # header-list = "(" header-fld-name *(SP header-fld-name) ")" + def header_list + str = +"" + str << lpar << header_fld_name + str << " " << header_fld_name while SP? + str << rpar + end + + # section-part = nz-number *("." nz-number) + # ; body part reference. + # ; Allows for accessing nested body parts. + alias section_part atom + + # RFC3501 & RFC9051: + # header-fld-name = astring + # + # NOTE: Previously, Net::IMAP recreated the raw original source string. + # Now, it grabs the raw encoded value using @str and @pos. A future + # version may simply return the decoded astring value. Although that is + # technically incompatible, it should almost never make a difference: all + # standard header field names are valid atoms: + # + # https://www.iana.org/assignments/message-headers/message-headers.xhtml + # + # Although RFC3501 allows any astring, RFC5322-valid header names are one + # or more of the printable US-ASCII characters, except SP and colon. So + # empty string isn't valid, and literals aren't needed and should not be + # used. This is explicitly unchanged by [I18N-HDRS] (RFC6532). + # + # RFC5233: + # optional-field = field-name ":" unstructured CRLF + # field-name = 1*ftext + # ftext = %d33-57 / ; Printable US-ASCII + # %d59-126 ; characters not including + # ; ":". + def header_fld_name + assert_no_lookahead + start = @pos + astring + end_pos = @token ? @pos - 1 : @pos + @str[start...end_pos] + end + + # mailbox-data = "FLAGS" SP flag-list / "LIST" SP mailbox-list / + # "LSUB" SP mailbox-list / "SEARCH" *(SP nz-number) / + # "STATUS" SP mailbox SP "(" [status-att-list] ")" / + # number SP "EXISTS" / number SP "RECENT" + + def mailbox_data__flags + name = label("FLAGS") + SP! + UntaggedResponse.new(name, flag_list, @str) + end + + def mailbox_data__list + name = label_in("LIST", "LSUB", "XLIST") + SP! + UntaggedResponse.new(name, mailbox_list, @str) + end + alias mailbox_data__lsub mailbox_data__list + alias mailbox_data__xlist mailbox_data__list + + # mailbox-list = "(" [mbx-list-flags] ")" SP + # (DQUOTE QUOTED-CHAR DQUOTE / nil) SP mailbox + # [SP mbox-list-extended] + # ; This is the list information pointed to by the ABNF + # ; item "mailbox-data", which is defined above + def mailbox_list + lpar; attr = peek_rpar? ? [] : mbx_list_flags; rpar + SP!; delim = nquoted + SP!; name = mailbox + # TODO: mbox-list-extended + MailboxList.new(attr, delim, name) + end + + def quota_response + # If quota never established, get back + # `NO Quota root does not exist'. + # If quota removed, get `()' after the + # folder spec with no mention of `STORAGE'. + token = match(T_ATOM) + name = token.value.upcase + match(T_SPACE) + mailbox = astring + match(T_SPACE) + match(T_LPAR) + token = lookahead + case token.symbol + when T_RPAR + shift_token + data = MailboxQuota.new(mailbox, nil, nil) + return UntaggedResponse.new(name, data, @str) + when T_ATOM + shift_token + match(T_SPACE) + token = match(T_NUMBER) + usage = token.value + match(T_SPACE) + token = match(T_NUMBER) + quota = token.value + match(T_RPAR) + data = MailboxQuota.new(mailbox, usage, quota) + return UntaggedResponse.new(name, data, @str) + else + parse_error("unexpected token %s", token.symbol) + end + end + + def quotaroot_response + # Similar to getquota, but only admin can use getquota. + token = match(T_ATOM) + name = token.value.upcase + match(T_SPACE) + mailbox = astring + quotaroots = [] + while true + token = lookahead + break unless token.symbol == T_SPACE + shift_token + quotaroots.push(astring) + end + data = MailboxQuotaRoot.new(mailbox, quotaroots) + return UntaggedResponse.new(name, data, @str) + end + + # acl-data = "ACL" SP mailbox *(SP identifier SP rights) + def acl_data + token = match(T_ATOM) + name = token.value.upcase + match(T_SPACE) + mailbox = astring + data = [] + token = lookahead + if token.symbol == T_SPACE + shift_token + while true + token = lookahead + case token.symbol + when T_CRLF + break + when T_SPACE + shift_token + end + user = astring + match(T_SPACE) + rights = astring + data.push(MailboxACLItem.new(user, rights, mailbox)) + end + end + return UntaggedResponse.new(name, data, @str) + end + + # RFC3501: + # mailbox-data = "SEARCH" *(SP nz-number) / ... + # RFC5256: SORT + # sort-data = "SORT" *(SP nz-number) + # RFC7162: CONDSTORE, QRESYNC + # mailbox-data =/ "SEARCH" [1*(SP nz-number) SP + # search-sort-mod-seq] + # sort-data = "SORT" [1*(SP nz-number) SP + # search-sort-mod-seq] + # ; Updates the SORT response from RFC 5256. + # search-sort-mod-seq = "(" "MODSEQ" SP mod-sequence-value ")" + # RFC9051: + # mailbox-data = obsolete-search-response / ... + # obsolete-search-response = "SEARCH" *(SP nz-number) + def mailbox_data__search + name = label_in("SEARCH", "SORT") + data = [] + while _ = SP? && nz_number? do data << _ end + if lpar? + label("MODSEQ"); SP! + modseq = mod_sequence_value + rpar + end + data = SearchResult.new(data, modseq: modseq) + UntaggedResponse.new(name, data, @str) + end + alias sort_data mailbox_data__search + + # RFC5256: THREAD + # thread-data = "THREAD" [SP 1*thread-list] + def thread_data + name = label("THREAD") + threads = [] + if SP? + threads << thread_list while lookahead_thread_list? + end + UntaggedResponse.new(name, threads, @str) + end + + alias lookahead_thread_list? lookahead_lpar? + alias lookahead_thread_nested? lookahead_thread_list? + + # RFC5256: THREAD + # thread-list = "(" (thread-members / thread-nested) ")" + def thread_list + lpar + thread = if lookahead_thread_nested? + ThreadMember.new(nil, thread_nested) + else + thread_members + end + rpar + thread + end + + # RFC5256: THREAD + # thread-members = nz-number *(SP nz-number) [SP thread-nested] + def thread_members + members = [] + members << nz_number # thread root + while SP? + case lookahead!(T_NUMBER, T_LPAR).symbol + when T_NUMBER then members << nz_number + else nested = thread_nested; break + end + end + members.reverse.inject(nested || []) {|subthreads, number| + [ThreadMember.new(number, subthreads)] + }.first + end + + # RFC5256: THREAD + # thread-nested = 2*thread-list + def thread_nested + nested = [thread_list, thread_list] + while lookahead_thread_list? do nested << thread_list end + nested + end + + # mailbox-data =/ "STATUS" SP mailbox SP "(" [status-att-list] ")" + def mailbox_data__status + resp_name = label("STATUS"); SP! + mbox_name = mailbox; SP! + lpar; attr = status_att_list; rpar + UntaggedResponse.new(resp_name, StatusData.new(mbox_name, attr), @str) + end + + # RFC3501 + # status-att-list = status-att SP number *(SP status-att SP number) + # RFC4466, RFC9051, and RFC3501 Errata + # status-att-list = status-att-val *(SP status-att-val) + def status_att_list + attrs = [status_att_val] + while SP? do attrs << status_att_val end + attrs.to_h + end + + # RFC3501 Errata: + # status-att-val = ("MESSAGES" SP number) / ("RECENT" SP number) / + # ("UIDNEXT" SP nz-number) / ("UIDVALIDITY" SP nz-number) / + # ("UNSEEN" SP number) + # RFC4466: + # status-att-val = ("MESSAGES" SP number) / + # ("RECENT" SP number) / + # ("UIDNEXT" SP nz-number) / + # ("UIDVALIDITY" SP nz-number) / + # ("UNSEEN" SP number) + # ;; Extensions to the STATUS responses + # ;; should extend this production. + # ;; Extensions should use the generic + # ;; syntax defined by tagged-ext. + # RFC9051: + # status-att-val = ("MESSAGES" SP number) / + # ("UIDNEXT" SP nz-number) / + # ("UIDVALIDITY" SP nz-number) / + # ("UNSEEN" SP number) / + # ("DELETED" SP number) / + # ("SIZE" SP number64) + # ; Extensions to the STATUS responses + # ; should extend this production. + # ; Extensions should use the generic + # ; syntax defined by tagged-ext. + # RFC7162: + # status-att-val =/ "HIGHESTMODSEQ" SP mod-sequence-valzer + # ;; Extends non-terminal defined in [RFC4466]. + # ;; Value 0 denotes that the mailbox doesn't + # ;; support persistent mod-sequences + # ;; as described in Section 3.1.2.2. + # RFC7889: + # status-att-val =/ "APPENDLIMIT" SP (number / nil) + # ;; status-att-val is defined in RFC 4466 + # RFC8438: + # status-att-val =/ "SIZE" SP number64 + # RFC8474: + # status-att-val =/ "MAILBOXID" SP "(" objectid ")" + # ; follows tagged-ext production from [RFC4466] + def status_att_val + key = tagged_ext_label + SP! + val = + case key + when "MESSAGES" then number # RFC3501, RFC9051 + when "UNSEEN" then number # RFC3501, RFC9051 + when "DELETED" then number # RFC3501, RFC9051 + when "UIDNEXT" then nz_number # RFC3501, RFC9051 + when "UIDVALIDITY" then nz_number # RFC3501, RFC9051 + when "RECENT" then number # RFC3501 (obsolete) + when "SIZE" then number64 # RFC8483, RFC9051 + when "HIGHESTMODSEQ" then mod_sequence_valzer # RFC7162 + when "MAILBOXID" then parens__objectid # RFC8474 + else + number? || ExtensionData.new(tagged_ext_val) + end + [key, val] + end + + # The presence of "IMAP4rev1" or "IMAP4rev2" is unenforced here. + # The grammar rule is used by both response-data and resp-text-code. + # But this method only returns UntaggedResponse (response-data). + # + # RFC3501: + # capability-data = "CAPABILITY" *(SP capability) SP "IMAP4rev1" + # *(SP capability) + # RFC9051: + # capability-data = "CAPABILITY" *(SP capability) SP "IMAP4rev2" + # *(SP capability) + def capability_data__untagged + UntaggedResponse.new label("CAPABILITY"), capability__list, @str + end + + # enable-data = "ENABLED" *(SP capability) + def enable_data + UntaggedResponse.new label("ENABLED"), capability__list, @str + end + + # As a workaround for buggy servers, allow a trailing SP: + # *(SP capability) [SP] + def capability__list + list = []; while SP? && (capa = capability?) do list << capa end; list + end + + alias resp_code__capability capability__list + + # capability = ("AUTH=" auth-type) / atom + # ; New capabilities MUST begin with "X" or be + # ; registered with IANA as standard or + # ; standards-track + alias capability case_insensitive__atom + alias capability? case_insensitive__atom? + + def id_response + token = match(T_ATOM) + name = token.value.upcase + match(T_SPACE) + token = match(T_LPAR, T_NIL) + if token.symbol == T_NIL + return UntaggedResponse.new(name, nil, @str) + else + data = {} + while true + token = lookahead + case token.symbol + when T_RPAR + shift_token + break + when T_SPACE + shift_token + next + else + key = string + match(T_SPACE) + val = nstring + data[key] = val + end + end + return UntaggedResponse.new(name, data, @str) + end + end + + # namespace-response = "NAMESPACE" SP namespace + # SP namespace SP namespace + # ; The first Namespace is the Personal Namespace(s). + # ; The second Namespace is the Other Users' + # ; Namespace(s). + # ; The third Namespace is the Shared Namespace(s). + def namespace_response + name = label("NAMESPACE") + @lex_state = EXPR_DATA + data = Namespaces.new((SP!; namespace), + (SP!; namespace), + (SP!; namespace)) + UntaggedResponse.new(name, data, @str) + ensure + @lex_state = EXPR_BEG + end + + # namespace = nil / "(" 1*namespace-descr ")" + def namespace + NIL? and return [] + lpar + list = [namespace_descr] + list << namespace_descr until rpar? + list + end + + # namespace-descr = "(" string SP + # (DQUOTE QUOTED-CHAR DQUOTE / nil) + # [namespace-response-extensions] ")" + def namespace_descr + lpar + prefix = string; SP! + delimiter = nquoted # n.b: should only accept single char + extensions = namespace_response_extensions + rpar + Namespace.new(prefix, delimiter, extensions) + end + + # namespace-response-extensions = *namespace-response-extension + # namespace-response-extension = SP string SP + # "(" string *(SP string) ")" + def namespace_response_extensions + data = {} + while SP? + name = string; SP! + lpar + data[name] ||= [] + data[name] << string + data[name] << string while SP? + rpar + end + data + end + + # TEXT-CHAR = + # RFC3501: + # text = 1*TEXT-CHAR + # RFC9051: + # text = 1*(TEXT-CHAR / UTF8-2 / UTF8-3 / UTF8-4) + # ; Non-ASCII text can only be returned + # ; after ENABLE IMAP4rev2 command + def text + match_re(TEXT_REGEXP, "text")[0].force_encoding("UTF-8") + end + + # an "accept" versiun of #text + def text? + accept_re(TEXT_REGEXP)&.[](0)&.force_encoding("UTF-8") + end + + # RFC3501: + # resp-text = ["[" resp-text-code "]" SP] text + # RFC9051: + # resp-text = ["[" resp-text-code "]" SP] [text] + # + # We leniently re-interpret this as + # resp-text = ["[" resp-text-code "]" [SP [text]] / [text] + def resp_text + if lbra? + code = resp_text_code; rbra + ResponseText.new(code, SP? && text? || "") + else + ResponseText.new(nil, text? || "") + end + end + + # RFC3501 (See https://www.rfc-editor.org/errata/rfc3501): + # resp-text-code = "ALERT" / + # "BADCHARSET" [SP "(" charset *(SP charset) ")" ] / + # capability-data / "PARSE" / + # "PERMANENTFLAGS" SP "(" [flag-perm *(SP flag-perm)] ")" / + # "READ-ONLY" / "READ-WRITE" / "TRYCREATE" / + # "UIDNEXT" SP nz-number / "UIDVALIDITY" SP nz-number / + # "UNSEEN" SP nz-number / + # atom [SP 1*] + # capability-data = "CAPABILITY" *(SP capability) SP "IMAP4rev1" + # *(SP capability) + # + # RFC5530: + # resp-text-code =/ "UNAVAILABLE" / "AUTHENTICATIONFAILED" / + # "AUTHORIZATIONFAILED" / "EXPIRED" / + # "PRIVACYREQUIRED" / "CONTACTADMIN" / "NOPERM" / + # "INUSE" / "EXPUNGEISSUED" / "CORRUPTION" / + # "SERVERBUG" / "CLIENTBUG" / "CANNOT" / + # "LIMIT" / "OVERQUOTA" / "ALREADYEXISTS" / + # "NONEXISTENT" + # RFC9051: + # resp-text-code = "ALERT" / + # "BADCHARSET" [SP "(" charset *(SP charset) ")" ] / + # capability-data / "PARSE" / + # "PERMANENTFLAGS" SP "(" [flag-perm *(SP flag-perm)] ")" / + # "READ-ONLY" / "READ-WRITE" / "TRYCREATE" / + # "UIDNEXT" SP nz-number / "UIDVALIDITY" SP nz-number / + # resp-code-apnd / resp-code-copy / "UIDNOTSTICKY" / + # "UNAVAILABLE" / "AUTHENTICATIONFAILED" / + # "AUTHORIZATIONFAILED" / "EXPIRED" / + # "PRIVACYREQUIRED" / "CONTACTADMIN" / "NOPERM" / + # "INUSE" / "EXPUNGEISSUED" / "CORRUPTION" / + # "SERVERBUG" / "CLIENTBUG" / "CANNOT" / + # "LIMIT" / "OVERQUOTA" / "ALREADYEXISTS" / + # "NONEXISTENT" / "NOTSAVED" / "HASCHILDREN" / + # "CLOSED" / + # "UNKNOWN-CTE" / + # atom [SP 1*] + # capability-data = "CAPABILITY" *(SP capability) SP "IMAP4rev2" + # *(SP capability) + # + # RFC4315 (UIDPLUS), RFC9051 (IMAP4rev2): + # resp-code-apnd = "APPENDUID" SP nz-number SP append-uid + # resp-code-copy = "COPYUID" SP nz-number SP uid-set SP uid-set + # resp-text-code =/ resp-code-apnd / resp-code-copy / "UIDNOTSTICKY" + # + # RFC7162 (CONDSTORE): + # resp-text-code =/ "HIGHESTMODSEQ" SP mod-sequence-value / + # "NOMODSEQ" / + # "MODIFIED" SP sequence-set + # RFC7162 (QRESYNC): + # resp-text-code =/ "CLOSED" + # + # RFC8474: OBJECTID + # resp-text-code =/ "MAILBOXID" SP "(" objectid ")" + def resp_text_code + name = resp_text_code__name + data = + case name + when "CAPABILITY" then resp_code__capability + when "PERMANENTFLAGS" then SP? ? flag_perm__list : [] + when "UIDNEXT" then SP!; nz_number + when "UIDVALIDITY" then SP!; nz_number + when "UNSEEN" then SP!; nz_number # rev1 only + when "APPENDUID" then SP!; resp_code_apnd__data # rev2, UIDPLUS + when "COPYUID" then SP!; resp_code_copy__data # rev2, UIDPLUS + when "BADCHARSET" then SP? ? charset__list : [] + when "ALERT", "PARSE", "READ-ONLY", "READ-WRITE", "TRYCREATE", + "UNAVAILABLE", "AUTHENTICATIONFAILED", "AUTHORIZATIONFAILED", + "EXPIRED", "PRIVACYREQUIRED", "CONTACTADMIN", "NOPERM", "INUSE", + "EXPUNGEISSUED", "CORRUPTION", "SERVERBUG", "CLIENTBUG", "CANNOT", + "LIMIT", "OVERQUOTA", "ALREADYEXISTS", "NONEXISTENT", "CLOSED", + "NOTSAVED", "UIDNOTSTICKY", "UNKNOWN-CTE", "HASCHILDREN" + when "NOMODSEQ" then nil # CONDSTORE + when "HIGHESTMODSEQ" then SP!; mod_sequence_value # CONDSTORE + when "MODIFIED" then SP!; sequence_set # CONDSTORE + when "MAILBOXID" then SP!; parens__objectid # RFC8474: OBJECTID + else + SP? and text_chars_except_rbra + end + ResponseCode.new(name, data) + end + + alias resp_text_code__name case_insensitive__atom + + # 1* + def text_chars_except_rbra + match_re(CTEXT_REGEXP, '1*')[0] + end + + # "(" charset *(SP charset) ")" + def charset__list + lpar; list = [charset]; while SP? do list << charset end; rpar; list + end + + # already matched: "APPENDUID" + # + # +UIDPLUS+ ABNF:: https://www.rfc-editor.org/rfc/rfc4315.html#section-4 + # resp-code-apnd = "APPENDUID" SP nz-number SP append-uid + # append-uid = uniqueid + # append-uid =/ uid-set + # ; only permitted if client uses [MULTIAPPEND] + # ; to append multiple messages. + # + # n.b, uniqueid ⊂ uid-set. To avoid inconsistent return types, we always + # match uid_set even if that returns a single-member array. + def resp_code_apnd__data + validity = number; SP! + dst_uids = uid_set # uniqueid ⊂ uid-set + AppendUID(validity, dst_uids) + end + + # already matched: "COPYUID" + # + # resp-code-copy = "COPYUID" SP nz-number SP uid-set SP uid-set + def resp_code_copy__data + validity = number; SP! + src_uids = uid_set; SP! + dst_uids = uid_set + CopyUID(validity, src_uids, dst_uids) + end + + def AppendUID(...) DeprecatedUIDPlus(...) || AppendUIDData.new(...) end + def CopyUID(...) DeprecatedUIDPlus(...) || CopyUIDData.new(...) end + + # TODO: remove this code in the v0.6.0 release + def DeprecatedUIDPlus(validity, src_uids = nil, dst_uids) + return unless config.parser_use_deprecated_uidplus_data + compact_uid_sets = [src_uids, dst_uids].compact + count = compact_uid_sets.map { _1.count_with_duplicates }.max + max = config.parser_max_deprecated_uidplus_data_size + if count <= max + src_uids &&= src_uids.each_ordered_number.to_a + dst_uids = dst_uids.each_ordered_number.to_a + UIDPlusData.new(validity, src_uids, dst_uids) + elsif config.parser_use_deprecated_uidplus_data != :up_to_max_size + parse_error("uid-set is too large: %d > %d", count, max) + end + end + + ADDRESS_REGEXP = /\G + \( (?: NIL | #{Patterns::QUOTED_rev2} ) # 1: NAME + \s (?: NIL | #{Patterns::QUOTED_rev2} ) # 2: ROUTE + \s (?: NIL | #{Patterns::QUOTED_rev2} ) # 3: MAILBOX + \s (?: NIL | #{Patterns::QUOTED_rev2} ) # 4: HOST + \) + /nix + + # address = "(" addr-name SP addr-adl SP addr-mailbox SP + # addr-host ")" + # addr-adl = nstring + # addr-host = nstring + # addr-mailbox = nstring + # addr-name = nstring + def address + if (match = accept_re(ADDRESS_REGEXP)) + # note that "NIL" isn't captured by the regexp + name, route, mailbox, host = match.captures + .map { Patterns.unescape_quoted _1 } + else # address may include literals + lpar; name = addr_name + SP!; route = addr_adl + SP!; mailbox = addr_mailbox + SP!; host = addr_host + rpar + end + Address.new(name, route, mailbox, host) + end + + alias addr_adl nstring + alias addr_host nstring + alias addr_mailbox nstring + alias addr_name nstring + + # flag-list = "(" [flag *(SP flag)] ")" + def flag_list + if (match = accept_re(Patterns::FLAG_LIST)) + match[1].split(nil) + .map! { _1.delete_prefix!("\\") ? _1.capitalize.to_sym : _1 } + else + quirky__flag_list "flags-list" + end + end + + # "(" [flag-perm *(SP flag-perm)] ")" + def flag_perm__list + if (match = accept_re(Patterns::FLAG_PERM_LIST)) + match[1].split(nil) + .map! { _1.delete_prefix!("\\") ? _1.capitalize.to_sym : _1 } + else + quirky__flag_list "PERMANENTFLAGS flag-perm list" + end + end + + # This allows illegal "]" in flag names (Gmail), + # or "\*" in a FLAGS response (greenmail). + def quirky__flag_list(name) + match_re(Patterns::QUIRKY_FLAGS_LIST, "quirks mode #{name}")[1] + .scan(Patterns::QUIRKY_FLAG) + .map! { _1.delete_prefix!("\\") ? _1.capitalize.to_sym : _1 } + end + + # See Patterns::MBX_LIST_FLAGS + def mbx_list_flags + match_re(Patterns::MBX_LIST_FLAGS, "mbx-list-flags")[1] + .split(nil) + .map! { _1.delete_prefix!("\\"); _1.capitalize.to_sym } + end + + # See https://developers.google.com/gmail/imap/imap-extensions + def x_gm_label; accept(T_BSLASH) ? atom.capitalize.to_sym : astring end + + # See https://developers.google.com/gmail/imap/imap-extensions + def x_gm_labels + lpar; return [] if rpar? + labels = [] + labels << x_gm_label + labels << x_gm_label while SP? + rpar + labels + end + + # See https://www.rfc-editor.org/errata/rfc3501 + # + # charset = atom / quoted + def charset; quoted? || atom end + + # RFC7162: + # mod-sequence-value = 1*DIGIT + # ;; Positive unsigned 63-bit integer + # ;; (mod-sequence) + # ;; (1 <= n <= 9,223,372,036,854,775,807). + alias mod_sequence_value nz_number64 + + # RFC7162: + # permsg-modsequence = mod-sequence-value + # ;; Per-message mod-sequence. + alias permsg_modsequence mod_sequence_value + + # RFC7162: + # mod-sequence-valzer = "0" / mod-sequence-value + alias mod_sequence_valzer number64 + + def parens__modseq; lpar; _ = permsg_modsequence; rpar; _ end + + # RFC8474: + # objectid = 1*255(ALPHA / DIGIT / "_" / "-") + # ; characters in object identifiers are case + # ; significant + alias objectid atom + + def parens__objectid; lpar; _ = objectid; rpar; _ end + def nparens__objectid; NIL? ? nil : parens__objectid end + + # RFC-4315 (UIDPLUS) or RFC9051 (IMAP4rev2): + # uid-set = (uniqueid / uid-range) *("," uid-set) + # uid-range = (uniqueid ":" uniqueid) + # ; two uniqueid values and all values + # ; between these two regardless of order. + # ; Example: 2:4 and 4:2 are equivalent. + # uniqueid = nz-number + # ; Strictly ascending + def uid_set + set = sequence_set + parse_error("uid-set cannot contain '*'") if set.include_star? + set + end + + def nil_atom + match(T_NIL) + return nil + end + + SPACES_REGEXP = /\G */n + + # The RFC is very strict about this and usually we should be too. + # But skipping spaces is usually a safe workaround for buggy servers. + # + # This advances @pos directly so it's safe before changing @lex_state. + def accept_spaces + return false unless SP? + @str.index(SPACES_REGEXP, @pos) and + @pos = $~.end(0) + true + end + + def next_token + case @lex_state + when EXPR_BEG + if @str.index(BEG_REGEXP, @pos) + @pos = $~.end(0) + if $1 + return Token.new(T_SPACE, $+) + elsif $2 + literal_token($+, T_LITERAL8) + elsif $3 && $7 + # greedily match ATOM, prefixed with NUMBER, NIL, or PLUS. + return Token.new(T_ATOM, $3) + elsif $4 + return Token.new(T_NIL, $+) + elsif $5 + return Token.new(T_NUMBER, $+) + elsif $6 + return Token.new(T_PLUS, $+) + elsif $8 + # match ATOM, without a NUMBER, NIL, or PLUS prefix + return Token.new(T_ATOM, $+) + elsif $9 + return Token.new(T_QUOTED, Patterns.unescape_quoted($+)) + elsif $10 + return Token.new(T_LPAR, $+) + elsif $11 + return Token.new(T_RPAR, $+) + elsif $12 + return Token.new(T_BSLASH, $+) + elsif $13 + return Token.new(T_STAR, $+) + elsif $14 + return Token.new(T_LBRA, $+) + elsif $15 + return Token.new(T_RBRA, $+) + elsif $16 + literal_token($+) + elsif $17 + return Token.new(T_PERCENT, $+) + elsif $18 + return Token.new(T_CRLF, $+) + elsif $19 + return Token.new(T_EOF, $+) + else + parse_error("[Net::IMAP BUG] BEG_REGEXP is invalid") + end + else + @str.index(/\S*/n, @pos) + parse_error("unknown token - %s", $&.dump) + end + when EXPR_DATA + if @str.index(DATA_REGEXP, @pos) + @pos = $~.end(0) + if $1 + return Token.new(T_SPACE, $+) + elsif $2 + return Token.new(T_NIL, $+) + elsif $3 + return Token.new(T_NUMBER, $+) + elsif $4 + return Token.new(T_QUOTED, Patterns.unescape_quoted($+)) + elsif $5 + literal_token($+) + elsif $6 + return Token.new(T_LPAR, $+) + elsif $7 + return Token.new(T_RPAR, $+) + else + parse_error("[Net::IMAP BUG] DATA_REGEXP is invalid") + end + else + @str.index(/\S*/n, @pos) + parse_error("unknown token - %s", $&.dump) + end + else + parse_error("invalid @lex_state - %s", @lex_state.inspect) + end + rescue DataFormatError => error + parse_error error.message + end + + def literal_token(len, type = T_LITERAL) + len = coerce_number64 len.to_i + val = @str[@pos, len] + @pos += len + Token.new(type, val) + end + + # copied/adapted from NumValidator in v0.6 + def coerce_number64(num) + int = num.to_i + return int if 0 <= int && int <= 0x7fff_ffff_ffff_ffff + raise DataFormatError, + "number64 must be unsigned 63-bit integer: #{num}" + end + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_reader.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_reader.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_reader.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/response_reader.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,94 @@ +# frozen_string_literal: true + +module Net + class IMAP + # See https://www.rfc-editor.org/rfc/rfc9051#section-2.2.2 + class ResponseReader # :nodoc: + include NumValidator + + attr_reader :client + + def initialize(client, sock) + @client, @sock = client, sock + @buff = @literal_size = nil + end + + def read_response_buffer + @buff = String.new + catch :eof do + while true + read_line + break unless literal_size + read_literal + end + end + buff + ensure + @buff = @literal_size = nil + end + + private + + attr_reader :buff, :literal_size + + def bytes_read; buff.bytesize end + def empty?; buff.empty? end + def done?; line_done? && !literal_size end + def line_done?; buff.end_with?(CRLF) end + + def get_literal_size(buff) + buff.end_with?("}\r\n") && buff.rindex(/\{(\d+)\}\r\n\z/n) && + coerce_number64($1) + rescue DataFormatError + raise DataFormatError, format("invalid response literal size (%s)", $1) + end + + def read_line + line = (@sock.gets(CRLF, read_limit) or throw :eof) + buff << line + max_response_remaining! unless line_done? + @literal_size = get_literal_size(line) + end + + def read_literal + # check before allocating memory for literal + max_response_remaining! + literal = String.new(capacity: literal_size) + buff << (@sock.read(read_limit(literal_size), literal) or throw :eof) + ensure + @literal_size = nil + end + + def read_limit(limit = nil) + [limit, max_response_remaining!].compact.min + end + + def max_response_size; client.max_response_size end + def max_response_remaining; max_response_size &.- bytes_read end + def response_too_large?; max_response_size &.< min_response_size end + def min_response_size; bytes_read + min_response_remaining end + + def min_response_remaining + empty? ? 3 : done? ? 0 : (literal_size || 0) + 2 + end + + def max_response_remaining! + return max_response_remaining unless response_too_large? + raise ResponseTooLargeError.new( + max_response_size: max_response_size, + bytes_read: bytes_read, + literal_size: literal_size, + ) + end + + # copied/adapted from NumValidator in v0.6 + def coerce_number64(num) + int = num.to_i + return int if 0 <= int && int <= 0x7fff_ffff_ffff_ffff + raise DataFormatError, + "number64 must be unsigned 63-bit integer: #{num}" + end + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/anonymous_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/anonymous_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/anonymous_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/anonymous_authenticator.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,69 @@ +# frozen_string_literal: true + +module Net + class IMAP < Protocol + module SASL + + # Authenticator for the "+ANONYMOUS+" SASL mechanism, as specified by + # RFC-4505[https://tools.ietf.org/html/rfc4505]. See + # Net::IMAP#authenticate. + class AnonymousAuthenticator + + # An optional token sent for the +ANONYMOUS+ mechanism., up to 255 UTF-8 + # characters in length. + # + # If it contains an "@" sign, the message must be a valid email address + # (+addr-spec+ from RFC-2822[https://tools.ietf.org/html/rfc2822]). + # Email syntax is _not_ validated by AnonymousAuthenticator. + # + # Otherwise, it can be any UTF8 string which is permitted by the + # StringPrep::Trace profile. + attr_reader :anonymous_message + + # :call-seq: + # new(anonymous_message = "", **) -> authenticator + # new(anonymous_message: "", **) -> authenticator + # + # Creates an Authenticator for the "+ANONYMOUS+" SASL mechanism, as + # specified in RFC-4505[https://tools.ietf.org/html/rfc4505]. To use + # this, see Net::IMAP#authenticate or your client's authentication + # method. + # + # ==== Parameters + # + # * _optional_ #anonymous_message — a message to send to the server. + # + # Any other keyword arguments are silently ignored. + def initialize(anon_msg = nil, anonymous_message: nil, **) + message = (anonymous_message || anon_msg || "").to_str + @anonymous_message = StringPrep::Trace.stringprep_trace message + if (size = @anonymous_message&.length)&.> 255 + raise ArgumentError, + "anonymous_message is too long. (%d codepoints)" % [size] + end + @done = false + end + + # :call-seq: + # initial_response? -> true + # + # +ANONYMOUS+ can send an initial client response. + def initial_response?; true end + + # Returns #anonymous_message. + def process(_server_challenge_string) + anonymous_message + ensure + @done = true + end + + # Returns true when the initial client response was sent. + # + # The authentication should not succeed unless this returns true, but it + # does *not* indicate success. + def done?; @done end + + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/authentication_exchange.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/authentication_exchange.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/authentication_exchange.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/authentication_exchange.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,107 @@ +# frozen_string_literal: true + +module Net + class IMAP + module SASL + + # This API is *experimental*, and may change. + # + # TODO: catch exceptions in #process and send #cancel_response. + # TODO: raise an error if the command succeeds after being canceled. + # TODO: use with more clients, to verify the API can accommodate them. + # + # Create an AuthenticationExchange from a client adapter and a mechanism + # authenticator: + # def authenticate(mechanism, ...) + # authenticator = SASL.authenticator(mechanism, ...) + # SASL::AuthenticationExchange.new( + # sasl_adapter, mechanism, authenticator + # ).authenticate + # end + # + # private + # + # def sasl_adapter = MyClientAdapter.new(self, &method(:send_command)) + # + # Or delegate creation of the authenticator to ::build: + # def authenticate(...) + # SASL::AuthenticationExchange.build(sasl_adapter, ...) + # .authenticate + # end + # + # As a convenience, ::authenticate combines ::build and #authenticate: + # def authenticate(...) + # SASL::AuthenticationExchange.authenticate(sasl_adapter, ...) + # end + # + # Likewise, ClientAdapter#authenticate delegates to #authenticate: + # def authenticate(...) = sasl_adapter.authenticate(...) + # + class AuthenticationExchange + # Convenience method for build(...).authenticate + def self.authenticate(...) build(...).authenticate end + + # Use +registry+ to override the global Authenticators registry. + def self.build(client, mechanism, *args, sasl_ir: true, **kwargs, &block) + authenticator = SASL.authenticator(mechanism, *args, **kwargs, &block) + new(client, mechanism, authenticator, sasl_ir: sasl_ir) + end + + attr_reader :mechanism, :authenticator + + def initialize(client, mechanism, authenticator, sasl_ir: true) + @client = client + @mechanism = -mechanism.to_s.upcase.tr(?_, ?-) + @authenticator = authenticator + @sasl_ir = sasl_ir + @processed = false + end + + # Call #authenticate to execute an authentication exchange for #client + # using #authenticator. Authentication failures will raise an + # exception. Any exceptions other than those in RESPONSE_ERRORS will + # drop the connection. + def authenticate + client.run_command(mechanism, initial_response) { process _1 } + .tap { raise AuthenticationIncomplete, _1 unless done? } + rescue *client.response_errors + raise # but don't drop the connection + rescue + client.drop_connection + raise + rescue Exception # rubocop:disable Lint/RescueException + client.drop_connection! + raise + end + + def send_initial_response? + @sasl_ir && + authenticator.respond_to?(:initial_response?) && + authenticator.initial_response? && + client.sasl_ir_capable? && + client.auth_capable?(mechanism) + end + + def done? + authenticator.respond_to?(:done?) ? authenticator.done? : @processed + end + + private + + attr_reader :client + + def initial_response + return unless send_initial_response? + client.encode_ir authenticator.process nil + end + + def process(challenge) + client.encode authenticator.process client.decode challenge + ensure + @processed = true + end + + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/authenticators.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/authenticators.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/authenticators.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/authenticators.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,118 @@ +# frozen_string_literal: true + +module Net::IMAP::SASL + + # Registry for SASL authenticators + # + # Registered authenticators must respond to +#new+ or +#call+ (e.g. a class or + # a proc), receiving any credentials and options and returning an + # authenticator instance. The returned object represents a single + # authentication exchange and must not be reused for multiple + # authentication attempts. + # + # An authenticator instance object must respond to +#process+, receiving the + # server's challenge and returning the client's response. Optionally, it may + # also respond to +#initial_response?+ and +#done?+. When + # +#initial_response?+ returns +true+, +#process+ may be called the first + # time with +nil+. When +#done?+ returns +false+, the exchange is incomplete + # and an exception should be raised if the exchange terminates prematurely. + # + # See the source for PlainAuthenticator, XOAuth2Authenticator, and + # ScramSHA1Authenticator for examples. + class Authenticators + + # Create a new Authenticators registry. + # + # This class is usually not instantiated directly. Use SASL.authenticators + # to reuse the default global registry. + # + # When +use_defaults+ is +false+, the registry will start empty. When + # +use_deprecated+ is +false+, deprecated authenticators will not be + # included with the defaults. + def initialize(use_defaults: true, use_deprecated: true) + @authenticators = {} + return unless use_defaults + add_authenticator "Anonymous" + add_authenticator "External" + add_authenticator "OAuthBearer" + add_authenticator "Plain" + add_authenticator "Scram-SHA-1" + add_authenticator "Scram-SHA-256" + add_authenticator "XOAuth2" + return unless use_deprecated + add_authenticator "Login" # deprecated + add_authenticator "Cram-MD5" # deprecated + add_authenticator "Digest-MD5" # deprecated + end + + # Returns the names of all registered SASL mechanisms. + def names; @authenticators.keys end + + # :call-seq: + # add_authenticator(mechanism) + # add_authenticator(mechanism, authenticator_class) + # add_authenticator(mechanism, authenticator_proc) + # + # Registers an authenticator for #authenticator to use. +mechanism+ is the + # name of the + # {SASL mechanism}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] + # implemented by +authenticator_class+ (for instance, "PLAIN"). + # + # If +mechanism+ refers to an existing authenticator, + # the old authenticator will be replaced. + # + # When only a single argument is given, the authenticator class will be + # lazily loaded from Net::IMAP::SASL::#{name}Authenticator (case is + # preserved and non-alphanumeric characters are removed.. + def add_authenticator(name, authenticator = nil) + key = -name.to_s.upcase.tr(?_, ?-) + authenticator ||= begin + class_name = "#{name.gsub(/[^a-zA-Z0-9]/, "")}Authenticator".to_sym + auth_class = nil + ->(*creds, **props, &block) { + auth_class ||= Net::IMAP::SASL.const_get(class_name) + auth_class.new(*creds, **props, &block) + } + end + @authenticators[key] = authenticator + end + + # Removes the authenticator registered for +name+ + def remove_authenticator(name) + key = -name.to_s.upcase.tr(?_, ?-) + @authenticators.delete(key) + end + + def mechanism?(name) + key = -name.to_s.upcase.tr(?_, ?-) + @authenticators.key?(key) + end + + # :call-seq: + # authenticator(mechanism, ...) -> auth_session + # + # Builds an authenticator instance using the authenticator registered to + # +mechanism+. The returned object represents a single authentication + # exchange and must not be reused for multiple authentication + # attempts. + # + # All arguments (except +mechanism+) are forwarded to the registered + # authenticator's +#new+ or +#call+ method. Each authenticator must + # document its own arguments. + # + # [Note] + # This method is intended for internal use by connection protocol code + # only. Protocol client users should see refer to their client's + # documentation, e.g. Net::IMAP#authenticate. + def authenticator(mechanism, ...) + key = -mechanism.to_s.upcase.tr(?_, ?-) + auth = @authenticators.fetch(key) do + raise ArgumentError, 'unknown auth type - "%s"' % key + end + auth.respond_to?(:new) ? auth.new(...) : auth.call(...) + end + alias new authenticator + + end + +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/client_adapter.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/client_adapter.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/client_adapter.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/client_adapter.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,72 @@ +# frozen_string_literal: true + +module Net + class IMAP + module SASL + + # This API is *experimental*, and may change. + # + # TODO: use with more clients, to verify the API can accommodate them. + # + # An abstract base class for implementing a SASL authentication exchange. + # Different clients will each have their own adapter subclass, overridden + # to match their needs. + # + # Although the default implementations _may_ be sufficient, subclasses + # will probably need to override some methods. Additionally, subclasses + # may need to include a protocol adapter mixin, if the default + # ProtocolAdapters::Generic isn't sufficient. + class ClientAdapter + include ProtocolAdapters::Generic + + attr_reader :client, :command_proc + + # +command_proc+ can used to avoid exposing private methods on #client. + # It should run a command with the arguments sent to it, yield each + # continuation payload, respond to the server with the result of each + # yield, and return the result. Non-successful results *MUST* raise an + # exception. Exceptions in the block *MUST* cause the command to fail. + # + # Subclasses that override #run_command may use #command_proc for + # other purposes. + def initialize(client, &command_proc) + @client, @command_proc = client, command_proc + end + + # Delegates to AuthenticationExchange.authenticate. + def authenticate(...) AuthenticationExchange.authenticate(self, ...) end + + # Do the protocol and server both support an initial response? + def sasl_ir_capable?; client.sasl_ir_capable? end + + # Does the server advertise support for the mechanism? + def auth_capable?(mechanism); client.auth_capable?(mechanism) end + + # Runs the authenticate command with +mechanism+ and +initial_response+. + # When +initial_response+ is nil, an initial response must NOT be sent. + # + # Yields each continuation payload, responds to the server with the + # result of each yield, and returns the result. Non-successful results + # *MUST* raise an exception. Exceptions in the block *MUST* cause the + # command to fail. + # + # Subclasses that override this may use #command_proc differently. + def run_command(mechanism, initial_response = nil, &block) + command_proc or raise Error, "initialize with block or override" + args = [command_name, mechanism, initial_response].compact + command_proc.call(*args, &block) + end + + # Returns an array of server responses errors raised by run_command. + # Exceptions in this array won't drop the connection. + def response_errors; [] end + + # Drop the connection gracefully. + def drop_connection; client.drop_connection end + + # Drop the connection abruptly. + def drop_connection!; client.drop_connection! end + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/cram_md5_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/cram_md5_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/cram_md5_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/cram_md5_authenticator.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,61 @@ +# frozen_string_literal: true + +# Authenticator for the "+CRAM-MD5+" SASL mechanism, specified in +# RFC2195[https://tools.ietf.org/html/rfc2195]. See Net::IMAP#authenticate. +# +# == Deprecated +# +# +CRAM-MD5+ is obsolete and insecure. It is included for compatibility with +# existing servers. +# {draft-ietf-sasl-crammd5-to-historic}[https://tools.ietf.org/html/draft-ietf-sasl-crammd5-to-historic-00.html] +# recommends using +SCRAM-*+ or +PLAIN+ protected by TLS instead. +# +# Additionally, RFC8314[https://tools.ietf.org/html/rfc8314] discourage the use +# of cleartext and recommends TLS version 1.2 or greater be used for all +# traffic. With TLS +CRAM-MD5+ is okay, but so is +PLAIN+ +class Net::IMAP::SASL::CramMD5Authenticator + def initialize(user = nil, pass = nil, + authcid: nil, username: nil, + password: nil, secret: nil, + warn_deprecation: true, + **) + if warn_deprecation + warn "WARNING: CRAM-MD5 mechanism is deprecated." # TODO: recommend SCRAM + end + require "digest/md5" + @user = authcid || username || user + @password = password || secret || pass + @done = false + end + + def initial_response?; false end + + def process(challenge) + digest = hmac_md5(challenge, @password) + return @user + " " + digest + ensure + @done = true + end + + def done?; @done end + + private + + def hmac_md5(text, key) + if key.length > 64 + key = Digest::MD5.digest(key) + end + + k_ipad = key + "\0" * (64 - key.length) + k_opad = key + "\0" * (64 - key.length) + for i in 0..63 + k_ipad[i] = (k_ipad[i].ord ^ 0x36).chr + k_opad[i] = (k_opad[i].ord ^ 0x5c).chr + end + + digest = Digest::MD5.digest(k_ipad + text) + + return Digest::MD5.hexdigest(k_opad + digest) + end + +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/digest_md5_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/digest_md5_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/digest_md5_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/digest_md5_authenticator.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,180 @@ +# frozen_string_literal: true + +# Net::IMAP authenticator for the "`DIGEST-MD5`" SASL mechanism type, specified +# in RFC-2831[https://tools.ietf.org/html/rfc2831]. See Net::IMAP#authenticate. +# +# == Deprecated +# +# "+DIGEST-MD5+" has been deprecated by +# RFC-6331[https://tools.ietf.org/html/rfc6331] and should not be relied on for +# security. It is included for compatibility with existing servers. +class Net::IMAP::SASL::DigestMD5Authenticator + STAGE_ONE = :stage_one + STAGE_TWO = :stage_two + STAGE_DONE = :stage_done + private_constant :STAGE_ONE, :STAGE_TWO, :STAGE_DONE + + # Authentication identity: the identity that matches the #password. + # + # RFC-2831[https://tools.ietf.org/html/rfc2831] uses the term +username+. + # "Authentication identity" is the generic term used by + # RFC-4422[https://tools.ietf.org/html/rfc4422]. + # RFC-4616[https://tools.ietf.org/html/rfc4616] and many later RFCs abbreviate + # this to +authcid+. + attr_reader :username + alias authcid username + + # A password or passphrase that matches the #username. + # + # The +password+ will be used to create the response digest. + attr_reader :password + + # Authorization identity: an identity to act as or on behalf of. The identity + # form is application protocol specific. If not provided or left blank, the + # server derives an authorization identity from the authentication identity. + # The server is responsible for verifying the client's credentials and + # verifying that the identity it associates with the client's authentication + # identity is allowed to act as (or on behalf of) the authorization identity. + # + # For example, an administrator or superuser might take on another role: + # + # imap.authenticate "DIGEST-MD5", "root", ->{passwd}, authzid: "user" + # + attr_reader :authzid + + # :call-seq: + # new(username, password, authzid = nil, **options) -> authenticator + # new(username:, password:, authzid: nil, **options) -> authenticator + # new(authcid:, password:, authzid: nil, **options) -> authenticator + # + # Creates an Authenticator for the "+DIGEST-MD5+" SASL mechanism. + # + # Called by Net::IMAP#authenticate and similar methods on other clients. + # + # ==== Parameters + # + # * #authcid ― Authentication identity that is associated with #password. + # + # #username ― An alias for +authcid+. + # + # * #password ― A password or passphrase associated with this #authcid. + # + # * _optional_ #authzid ― Authorization identity to act as or on behalf of. + # + # When +authzid+ is not set, the server should derive the authorization + # identity from the authentication identity. + # + # * _optional_ +warn_deprecation+ — Set to +false+ to silence the warning. + # + # Any other keyword arguments are silently ignored. + def initialize(user = nil, pass = nil, authz = nil, + username: nil, password: nil, authzid: nil, + authcid: nil, secret: nil, + warn_deprecation: true, **) + username = authcid || username || user or + raise ArgumentError, "missing username (authcid)" + password ||= secret || pass or raise ArgumentError, "missing password" + authzid ||= authz + if warn_deprecation + warn "WARNING: DIGEST-MD5 SASL mechanism was deprecated by RFC6331." + # TODO: recommend SCRAM instead. + end + require "digest/md5" + require "strscan" + @username, @password, @authzid = username, password, authzid + @nc, @stage = {}, STAGE_ONE + end + + def initial_response?; false end + + # Responds to server challenge in two stages. + def process(challenge) + case @stage + when STAGE_ONE + @stage = STAGE_TWO + sparams = {} + c = StringScanner.new(challenge) + while c.scan(/(?:\s*,)?\s*(\w+)=("(?:[^\\"]|\\.)*"|[^,]+)\s*/) + k, v = c[1], c[2] + if v =~ /^"(.*)"$/ + v = $1 + if v =~ /,/ + v = v.split(',') + end + end + sparams[k] = v + end + + raise Net::IMAP::DataFormatError, "Bad Challenge: '#{challenge}'" unless c.eos? and sparams['qop'] + raise Net::IMAP::Error, "Server does not support auth (qop = #{sparams['qop'].join(',')})" unless sparams['qop'].include?("auth") + + response = { + :nonce => sparams['nonce'], + :username => @username, + :realm => sparams['realm'], + :cnonce => Digest::MD5.hexdigest("%.15f:%.15f:%d" % [Time.now.to_f, rand, Process.pid.to_s]), + :'digest-uri' => 'imap/' + sparams['realm'], + :qop => 'auth', + :maxbuf => 65535, + :nc => "%08d" % nc(sparams['nonce']), + :charset => sparams['charset'], + } + + response[:authzid] = @authzid unless @authzid.nil? + + # now, the real thing + a0 = Digest::MD5.digest( [ response.values_at(:username, :realm), @password ].join(':') ) + + a1 = [ a0, response.values_at(:nonce,:cnonce) ].join(':') + a1 << ':' + response[:authzid] unless response[:authzid].nil? + + a2 = "AUTHENTICATE:" + response[:'digest-uri'] + a2 << ":00000000000000000000000000000000" if response[:qop] and response[:qop] =~ /^auth-(?:conf|int)$/ + + response[:response] = Digest::MD5.hexdigest( + [ + Digest::MD5.hexdigest(a1), + response.values_at(:nonce, :nc, :cnonce, :qop), + Digest::MD5.hexdigest(a2) + ].join(':') + ) + + return response.keys.map {|key| qdval(key.to_s, response[key]) }.join(',') + when STAGE_TWO + @stage = STAGE_DONE + # if at the second stage, return an empty string + if challenge =~ /rspauth=/ + return '' + else + raise ResponseParseError, challenge + end + else + raise ResponseParseError, challenge + end + end + + def done?; @stage == STAGE_DONE end + + private + + def nc(nonce) + if @nc.has_key? nonce + @nc[nonce] = @nc[nonce] + 1 + else + @nc[nonce] = 1 + end + return @nc[nonce] + end + + # some responses need quoting + def qdval(k, v) + return if k.nil? or v.nil? + if %w"username authzid realm nonce cnonce digest-uri qop".include? k + v = v.gsub(/([\\"])/, "\\\1") + return '%s="%s"' % [k, v] + else + return '%s=%s' % [k, v] + end + end + +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/external_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/external_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/external_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/external_authenticator.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,83 @@ +# frozen_string_literal: true + +module Net + class IMAP < Protocol + module SASL + + # Authenticator for the "+EXTERNAL+" SASL mechanism, as specified by + # RFC-4422[https://tools.ietf.org/html/rfc4422]. See + # Net::IMAP#authenticate. + # + # The EXTERNAL mechanism requests that the server use client credentials + # established external to SASL, for example by TLS certificate or IPSec. + class ExternalAuthenticator + + # Authorization identity: an identity to act as or on behalf of. The + # identity form is application protocol specific. If not provided or + # left blank, the server derives an authorization identity from the + # authentication identity. The server is responsible for verifying the + # client's credentials and verifying that the identity it associates + # with the client's authentication identity is allowed to act as (or on + # behalf of) the authorization identity. + # + # For example, an administrator or superuser might take on another role: + # + # imap.authenticate "PLAIN", "root", passwd, authzid: "user" + # + attr_reader :authzid + alias username authzid + + # :call-seq: + # new(authzid: nil, **) -> authenticator + # new(username: nil, **) -> authenticator + # new(username = nil, **) -> authenticator + # + # Creates an Authenticator for the "+EXTERNAL+" SASL mechanism, as + # specified in RFC-4422[https://tools.ietf.org/html/rfc4422]. To use + # this, see Net::IMAP#authenticate or your client's authentication + # method. + # + # ==== Parameters + # + # * _optional_ #authzid ― Authorization identity to act as or on behalf of. + # + # _optional_ #username ― An alias for #authzid. + # + # Note that, unlike some other authenticators, +username+ sets the + # _authorization_ identity and not the _authentication_ identity. The + # authentication identity is established for the client by the + # external credentials. + # + # Any other keyword parameters are quietly ignored. + def initialize(user = nil, authzid: nil, username: nil, **) + authzid ||= username || user + @authzid = authzid&.to_str&.encode "UTF-8" + if @authzid&.match?(/\u0000/u) # also validates UTF8 encoding + raise ArgumentError, "contains NULL" + end + @done = false + end + + # :call-seq: + # initial_response? -> true + # + # +EXTERNAL+ can send an initial client response. + def initial_response?; true end + + # Returns #authzid, or an empty string if there is no authzid. + def process(_) + authzid || "" + ensure + @done = true + end + + # Returns true when the initial client response was sent. + # + # The authentication should not succeed unless this returns true, but it + # does *not* indicate success. + def done?; @done end + + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/gs2_header.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/gs2_header.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/gs2_header.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/gs2_header.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,80 @@ +# frozen_string_literal: true + +module Net + class IMAP < Protocol + module SASL + + # Originally defined for the GS2 mechanism family in + # RFC5801[https://tools.ietf.org/html/rfc5801], + # several different mechanisms start with a GS2 header: + # * +GS2-*+ --- RFC5801[https://tools.ietf.org/html/rfc5801] + # * +SCRAM-*+ --- RFC5802[https://tools.ietf.org/html/rfc5802] + # (ScramAuthenticator) + # * +SAML20+ --- RFC6595[https://tools.ietf.org/html/rfc6595] + # * +OPENID20+ --- RFC6616[https://tools.ietf.org/html/rfc6616] + # * +OAUTH10A+ --- RFC7628[https://tools.ietf.org/html/rfc7628] + # * +OAUTHBEARER+ --- RFC7628[https://tools.ietf.org/html/rfc7628] + # (OAuthBearerAuthenticator) + # + # Classes that include this module must implement +#authzid+. + module GS2Header + NO_NULL_CHARS = /\A[^\x00]+\z/u.freeze # :nodoc: + + ## + # Matches {RFC5801 §4}[https://www.rfc-editor.org/rfc/rfc5801#section-4] + # +saslname+. The output from gs2_saslname_encode matches this Regexp. + RFC5801_SASLNAME = /\A(?:[^,=\x00]|=2C|=3D)+\z/u.freeze + + # The {RFC5801 §4}[https://www.rfc-editor.org/rfc/rfc5801#section-4] + # +gs2-header+, which prefixes the #initial_client_response. + # + # >>> + # Note: the actual GS2 header includes an optional flag to + # indicate that the GSS mechanism is not "standard", but since all of + # the SASL mechanisms using GS2 are "standard", we don't include that + # flag. A class for a nonstandard GSSAPI mechanism should prefix with + # "+F,+". + def gs2_header + "#{gs2_cb_flag},#{gs2_authzid}," + end + + # The {RFC5801 §4}[https://www.rfc-editor.org/rfc/rfc5801#section-4] + # +gs2-cb-flag+: + # + # "+n+":: The client doesn't support channel binding. + # "+y+":: The client does support channel binding + # but thinks the server does not. + # "+p+":: The client requires channel binding. + # The selected channel binding follows "+p=+". + # + # The default always returns "+n+". A mechanism that supports channel + # binding must override this method. + # + def gs2_cb_flag; "n" end + + # The {RFC5801 §4}[https://www.rfc-editor.org/rfc/rfc5801#section-4] + # +gs2-authzid+ header, when +#authzid+ is not empty. + # + # If +#authzid+ is empty or +nil+, an empty string is returned. + def gs2_authzid + return "" if authzid.nil? || authzid == "" + "a=#{gs2_saslname_encode(authzid)}" + end + + module_function + + # Encodes +str+ to match RFC5801_SASLNAME. + def gs2_saslname_encode(str) + str = str.encode("UTF-8") + # Regexp#match raises "invalid byte sequence" for invalid UTF-8 + NO_NULL_CHARS.match str or + raise ArgumentError, "invalid saslname: %p" % [str] + str + .gsub(?=, "=3D") + .gsub(?,, "=2C") + end + + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/login_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/login_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/login_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/login_authenticator.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,55 @@ +# frozen_string_literal: true + +# Authenticator for the "+LOGIN+" SASL mechanism. See Net::IMAP#authenticate. +# +# +LOGIN+ authentication sends the password in cleartext. +# RFC3501[https://tools.ietf.org/html/rfc3501] encourages servers to disable +# cleartext authentication until after TLS has been negotiated. +# RFC8314[https://tools.ietf.org/html/rfc8314] recommends TLS version 1.2 or +# greater be used for all traffic, and deprecate cleartext access ASAP. +LOGIN+ +# can be secured by TLS encryption. +# +# == Deprecated +# +# The {SASL mechanisms +# registry}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] +# marks "LOGIN" as obsoleted in favor of "PLAIN". It is included here for +# compatibility with existing servers. See +# {draft-murchison-sasl-login}[https://www.iana.org/go/draft-murchison-sasl-login] +# for both specification and deprecation. +class Net::IMAP::SASL::LoginAuthenticator + STATE_USER = :USER + STATE_PASSWORD = :PASSWORD + STATE_DONE = :DONE + private_constant :STATE_USER, :STATE_PASSWORD, :STATE_DONE + + def initialize(user = nil, pass = nil, + authcid: nil, username: nil, + password: nil, secret: nil, + warn_deprecation: true, + **) + if warn_deprecation + warn "WARNING: LOGIN SASL mechanism is deprecated. Use PLAIN instead." + end + @user = authcid || username || user + @password = password || secret || pass + @state = STATE_USER + end + + def initial_response?; false end + + def process(data) + case @state + when STATE_USER + @state = STATE_PASSWORD + return @user + when STATE_PASSWORD + @state = STATE_DONE + return @password + when STATE_DONE + raise ResponseParseError, data + end + end + + def done?; @state == STATE_DONE end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/oauthbearer_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/oauthbearer_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/oauthbearer_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/oauthbearer_authenticator.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,199 @@ +# frozen_string_literal: true + +require_relative "gs2_header" + +module Net + class IMAP < Protocol + module SASL + + # Abstract base class for the SASL mechanisms defined in + # RFC7628[https://tools.ietf.org/html/rfc7628]: + # * OAUTHBEARER[rdoc-ref:OAuthBearerAuthenticator] + # (OAuthBearerAuthenticator) + # * OAUTH10A + class OAuthAuthenticator + include GS2Header + + # Authorization identity: an identity to act as or on behalf of. The + # identity form is application protocol specific. If not provided or + # left blank, the server derives an authorization identity from the + # authentication identity. The server is responsible for verifying the + # client's credentials and verifying that the identity it associates + # with the client's authentication identity is allowed to act as (or on + # behalf of) the authorization identity. + # + # For example, an administrator or superuser might take on another role: + # + # imap.authenticate "PLAIN", "root", passwd, authzid: "user" + # + attr_reader :authzid + alias username authzid + + # Hostname to which the client connected. (optional) + attr_reader :host + + # Service port to which the client connected. (optional) + attr_reader :port + + # HTTP method. (optional) + attr_reader :mthd + + # HTTP path data. (optional) + attr_reader :path + + # HTTP post data. (optional) + attr_reader :post + + # The query string. (optional) + attr_reader :qs + alias query qs + + # Stores the most recent server "challenge". When authentication fails, + # this may hold information about the failure reason, as JSON. + attr_reader :last_server_response + + # Creates an RFC7628[https://tools.ietf.org/html/rfc7628] OAuth + # authenticator. + # + # ==== Parameters + # + # See child classes for required parameter(s). The following parameters + # are all optional, but it is worth noting that application protocols + # are allowed to require #authzid (or other parameters, such as + # #host or #port) as are specific server implementations. + # + # * _optional_ #authzid ― Authorization identity to act as or on behalf of. + # + # _optional_ #username — An alias for #authzid. + # + # Note that, unlike some other authenticators, +username+ sets the + # _authorization_ identity and not the _authentication_ identity. The + # authentication identity is established for the client by the OAuth + # token. + # + # * _optional_ #host — Hostname to which the client connected. + # * _optional_ #port — Service port to which the client connected. + # * _optional_ #mthd — HTTP method + # * _optional_ #path — HTTP path data + # * _optional_ #post — HTTP post data + # * _optional_ #qs — HTTP query string + # + # _optional_ #query — An alias for #qs + # + # Any other keyword parameters are quietly ignored. + def initialize(authzid: nil, host: nil, port: nil, + username: nil, query: nil, + mthd: nil, path: nil, post: nil, qs: nil, **) + @authzid = authzid || username + @host = host + @port = port + @mthd = mthd + @path = path + @post = post + @qs = qs || query + @done = false + end + + # The {RFC7628 §3.1}[https://www.rfc-editor.org/rfc/rfc7628#section-3.1] + # formatted response. + def initial_client_response + kv_pairs = { + host: host, port: port, mthd: mthd, path: path, post: post, qs: qs, + auth: authorization, # authorization is implemented by subclasses + }.compact + [gs2_header, *kv_pairs.map {|kv| kv.join("=") }, "\1"].join("\1") + end + + # Returns initial_client_response the first time, then "^A". + def process(data) + @last_server_response = data + done? ? "\1" : initial_client_response + ensure + @done = true + end + + # Returns true when the initial client response was sent. + # + # The authentication should not succeed unless this returns true, but it + # does *not* indicate success. + def done?; @done end + + # Value of the HTTP Authorization header + # + # Implemented by subclasses. + def authorization; raise "must be implemented by subclass" end + + end + + # Authenticator for the "+OAUTHBEARER+" SASL mechanism, specified in + # RFC7628[https://tools.ietf.org/html/rfc7628]. Authenticates using OAuth + # 2.0 bearer tokens, as described in + # RFC6750[https://tools.ietf.org/html/rfc6750]. Use via + # Net::IMAP#authenticate. + # + # RFC6750[https://tools.ietf.org/html/rfc6750] requires Transport Layer + # Security (TLS) to secure the protocol interaction between the client and + # the resource server. TLS _MUST_ be used for +OAUTHBEARER+ to protect + # the bearer token. + class OAuthBearerAuthenticator < OAuthAuthenticator + + # An OAuth 2.0 bearer token. See {RFC-6750}[https://www.rfc-editor.org/rfc/rfc6750] + attr_reader :oauth2_token + alias secret oauth2_token + + # :call-seq: + # new(oauth2_token, **options) -> authenticator + # new(authzid, oauth2_token, **options) -> authenticator + # new(oauth2_token:, **options) -> authenticator + # + # Creates an Authenticator for the "+OAUTHBEARER+" SASL mechanism. + # + # Called by Net::IMAP#authenticate and similar methods on other clients. + # + # ==== Parameters + # + # * #oauth2_token — An OAuth2 bearer token + # + # All other keyword parameters are passed to + # {super}[rdoc-ref:OAuthAuthenticator::new] (see OAuthAuthenticator). + # The most common ones are: + # + # * _optional_ #authzid ― Authorization identity to act as or on behalf of. + # + # _optional_ #username — An alias for #authzid. + # + # Note that, unlike some other authenticators, +username+ sets the + # _authorization_ identity and not the _authentication_ identity. The + # authentication identity is established for the client by + # #oauth2_token. + # + # * _optional_ #host — Hostname to which the client connected. + # * _optional_ #port — Service port to which the client connected. + # + # Although only oauth2_token is required by this mechanism, it is worth + # noting that application protocols are allowed to + # require #authzid (or other parameters, such as #host + # _or_ #port) as are specific server implementations. + def initialize(arg1 = nil, arg2 = nil, + oauth2_token: nil, secret: nil, + **args, &blk) + username, oauth2_token_arg = arg2.nil? ? [nil, arg1] : [arg1, arg2] + super(username: username, **args, &blk) + @oauth2_token = oauth2_token || secret || oauth2_token_arg or + raise ArgumentError, "missing oauth2_token" + end + + # :call-seq: + # initial_response? -> true + # + # +OAUTHBEARER+ sends an initial client response. + def initial_response?; true end + + # Value of the HTTP Authorization header + def authorization; "Bearer #{oauth2_token}" end + + end + end + + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/plain_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/plain_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/plain_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/plain_authenticator.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,101 @@ +# frozen_string_literal: true + +# Authenticator for the "+PLAIN+" SASL mechanism, specified in +# RFC-4616[https://tools.ietf.org/html/rfc4616]. See Net::IMAP#authenticate. +# +# +PLAIN+ authentication sends the password in cleartext. +# RFC-3501[https://tools.ietf.org/html/rfc3501] encourages servers to disable +# cleartext authentication until after TLS has been negotiated. +# RFC-8314[https://tools.ietf.org/html/rfc8314] recommends TLS version 1.2 or +# greater be used for all traffic, and deprecate cleartext access ASAP. +PLAIN+ +# can be secured by TLS encryption. +class Net::IMAP::SASL::PlainAuthenticator + + NULL = -"\0".b + private_constant :NULL + + # Authentication identity: the identity that matches the #password. + # + # RFC-2831[https://tools.ietf.org/html/rfc2831] uses the term +username+. + # "Authentication identity" is the generic term used by + # RFC-4422[https://tools.ietf.org/html/rfc4422]. + # RFC-4616[https://tools.ietf.org/html/rfc4616] and many later RFCs abbreviate + # this to +authcid+. + attr_reader :username + alias authcid username + + # A password or passphrase that matches the #username. + attr_reader :password + alias secret password + + # Authorization identity: an identity to act as or on behalf of. The identity + # form is application protocol specific. If not provided or left blank, the + # server derives an authorization identity from the authentication identity. + # The server is responsible for verifying the client's credentials and + # verifying that the identity it associates with the client's authentication + # identity is allowed to act as (or on behalf of) the authorization identity. + # + # For example, an administrator or superuser might take on another role: + # + # imap.authenticate "PLAIN", "root", passwd, authzid: "user" + # + attr_reader :authzid + + # :call-seq: + # new(username, password, authzid: nil, **) -> authenticator + # new(username:, password:, authzid: nil, **) -> authenticator + # new(authcid:, password:, authzid: nil, **) -> authenticator + # + # Creates an Authenticator for the "+PLAIN+" SASL mechanism. + # + # Called by Net::IMAP#authenticate and similar methods on other clients. + # + # ==== Parameters + # + # * #authcid ― Authentication identity that is associated with #password. + # + # #username ― An alias for #authcid. + # + # * #password ― A password or passphrase associated with the #authcid. + # + # * _optional_ #authzid ― Authorization identity to act as or on behalf of. + # + # When +authzid+ is not set, the server should derive the authorization + # identity from the authentication identity. + # + # Any other keyword parameters are quietly ignored. + def initialize(user = nil, pass = nil, + authcid: nil, secret: nil, + username: nil, password: nil, authzid: nil, **) + username ||= authcid || user or + raise ArgumentError, "missing username (authcid)" + password ||= secret || pass or raise ArgumentError, "missing password" + raise ArgumentError, "username contains NULL" if username.include?(NULL) + raise ArgumentError, "password contains NULL" if password.include?(NULL) + raise ArgumentError, "authzid contains NULL" if authzid&.include?(NULL) + @username = username + @password = password + @authzid = authzid + @done = false + end + + # :call-seq: + # initial_response? -> true + # + # +PLAIN+ can send an initial client response. + def initial_response?; true end + + # Responds with the client's credentials. + def process(data) + return "#@authzid\0#@username\0#@password" + ensure + @done = true + end + + # Returns true when the initial client response was sent. + # + # The authentication should not succeed unless this returns true, but it + # does *not* indicate success. + def done?; @done end + +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/protocol_adapters.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/protocol_adapters.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/protocol_adapters.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/protocol_adapters.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,45 @@ +# frozen_string_literal: true + +module Net + class IMAP + module SASL + + module ProtocolAdapters + # This API is experimental, and may change. + module Generic + def command_name; "AUTHENTICATE" end + def service; raise "Implement in subclass or module" end + def host; client.host end + def port; client.port end + def encode_ir(string) string.empty? ? "=" : encode(string) end + def encode(string) [string].pack("m0") end + def decode(string) string.unpack1("m0") end + def cancel_response; "*" end + end + + # See RFC-3501 (IMAP4rev1), RFC-4959 (SASL-IR capability), + # and RFC-9051 (IMAP4rev2). + module IMAP + include Generic + def service; "imap" end + end + + # See RFC-4954 (AUTH capability). + module SMTP + include Generic + def command_name; "AUTH" end + def service; "smtp" end + end + + # See RFC-5034 (SASL capability). + module POP + include Generic + def command_name; "AUTH" end + def service; "pop" end + end + + end + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/scram_algorithm.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/scram_algorithm.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/scram_algorithm.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/scram_algorithm.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,58 @@ +# frozen_string_literal: true + +module Net + class IMAP + module SASL + + # For method descriptions, + # see {RFC5802 §2.2}[https://www.rfc-editor.org/rfc/rfc5802#section-2.2] + # and {RFC5802 §3}[https://www.rfc-editor.org/rfc/rfc5802#section-3]. + module ScramAlgorithm + def Normalize(str) SASL.saslprep(str) end + + def Hi(str, salt, iterations) + length = digest.digest_length + OpenSSL::KDF.pbkdf2_hmac( + str, + salt: salt, + iterations: iterations, + length: length, + hash: digest, + ) + end + + def H(str) digest.digest str end + + def HMAC(key, data) OpenSSL::HMAC.digest(digest, key, data) end + + def XOR(str1, str2) + str1.unpack("C*") + .zip(str2.unpack("C*")) + .map {|a, b| a ^ b } + .pack("C*") + end + + def auth_message + [ + client_first_message_bare, + server_first_message, + client_final_message_without_proof, + ] + .join(",") + end + + def salted_password + Hi(Normalize(password), salt, iterations) + end + + def client_key; HMAC(salted_password, "Client Key") end + def server_key; HMAC(salted_password, "Server Key") end + def stored_key; H(client_key) end + def client_signature; HMAC(stored_key, auth_message) end + def server_signature; HMAC(server_key, auth_message) end + def client_proof; XOR(client_key, client_signature) end + end + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/scram_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/scram_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/scram_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/scram_authenticator.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,361 @@ +# frozen_string_literal: true + +require "openssl" +require "securerandom" + +require_relative "gs2_header" +require_relative "scram_algorithm" + +module Net + class IMAP + module SASL + + # Abstract base class for the "+SCRAM-*+" family of SASL mechanisms, + # defined in RFC5802[https://tools.ietf.org/html/rfc5802]. Use via + # Net::IMAP#authenticate. + # + # Directly supported: + # * +SCRAM-SHA-1+ --- ScramSHA1Authenticator + # * +SCRAM-SHA-256+ --- ScramSHA256Authenticator + # + # New +SCRAM-*+ mechanisms can easily be added for any hash algorithm + # supported by + # OpenSSL::Digest[https://ruby.github.io/openssl/OpenSSL/Digest.html]. + # Subclasses need only set an appropriate +DIGEST_NAME+ constant. + # + # === SCRAM algorithm + # + # See the documentation and method definitions on ScramAlgorithm for an + # overview of the algorithm. The different mechanisms differ only by + # which hash function that is used (or by support for channel binding with + # +-PLUS+). + # + # See also the methods on GS2Header. + # + # ==== Server messages + # + # As server messages are received, they are validated and loaded into + # the various attributes, e.g: #snonce, #salt, #iterations, #verifier, + # #server_error, etc. + # + # Unlike many other SASL mechanisms, the +SCRAM-*+ family supports mutual + # authentication and can return server error data in the server messages. + # If #process raises an Error for the server-final-message, then + # server_error may contain error details. + # + # === TLS Channel binding + # + # The SCRAM-*-PLUS mechanisms and channel binding are not + # supported yet. + # + # === Caching SCRAM secrets + # + # Caching of salted_password, client_key, stored_key, and server_key + # is not supported yet. + # + class ScramAuthenticator + include GS2Header + include ScramAlgorithm + + # :call-seq: + # new(username, password, **options) -> auth_ctx + # new(username:, password:, **options) -> auth_ctx + # new(authcid:, password:, **options) -> auth_ctx + # + # Creates an authenticator for one of the "+SCRAM-*+" SASL mechanisms. + # Each subclass defines #digest to match a specific mechanism. + # + # Called by Net::IMAP#authenticate and similar methods on other clients. + # + # === Parameters + # + # * #authcid ― Identity whose #password is used. + # + # #username - An alias for #authcid. + # * #password ― Password or passphrase associated with this #username. + # * _optional_ #authzid ― Alternate identity to act as or on behalf of. + # * _optional_ #min_iterations - Overrides the default value (4096). + # * _optional_ #max_iterations - Overrides the default value (2³¹ - 1). + # + # Any other keyword parameters are quietly ignored. + # + # *NOTE:* It is the user's responsibility to enforce minimum + # and maximum iteration counts that are appropriate for their security + # context. + def initialize(username_arg = nil, password_arg = nil, + authcid: nil, username: nil, + authzid: nil, + password: nil, secret: nil, + min_iterations: 4096, # see both RFC5802 and RFC7677 + max_iterations: 2**31 - 1, # max int32 + cnonce: nil, # must only be set in tests + **options) + @username = username || username_arg || authcid or + raise ArgumentError, "missing username (authcid)" + @password = password || secret || password_arg or + raise ArgumentError, "missing password" + @authzid = authzid + + @min_iterations = Integer min_iterations + @min_iterations.positive? or + raise ArgumentError, "min_iterations must be positive" + + @max_iterations = Integer max_iterations.to_int + @min_iterations <= @max_iterations or + raise ArgumentError, "max_iterations must be more than min_iterations" + + @cnonce = cnonce || SecureRandom.base64(32) + + # These attrs are set from the server challenges + @server_first_message = @snonce = @salt = @iterations = nil + @server_error = nil + + # Memoized after @salt and @iterations have been sent. + @salted_password = @client_key = @server_key = nil + + # These values are created and cached in response to server challenges + @client_first_message_bare = nil + @client_final_message_without_proof = nil + end + + # Authentication identity: the identity that matches the #password. + # + # RFC-2831[https://tools.ietf.org/html/rfc2831] uses the term +username+. + # "Authentication identity" is the generic term used by + # RFC-4422[https://tools.ietf.org/html/rfc4422]. + # RFC-4616[https://tools.ietf.org/html/rfc4616] and many later RFCs abbreviate + # this to +authcid+. + attr_reader :username + alias authcid username + + # A password or passphrase that matches the #username. + attr_reader :password + alias secret password + + # Authorization identity: an identity to act as or on behalf of. The + # identity form is application protocol specific. If not provided or + # left blank, the server derives an authorization identity from the + # authentication identity. For example, an administrator or superuser + # might take on another role: + # + # imap.authenticate "SCRAM-SHA-256", "root", passwd, authzid: "user" + # + # The server is responsible for verifying the client's credentials and + # verifying that the identity it associates with the client's + # authentication identity is allowed to act as (or on behalf of) the + # authorization identity. + attr_reader :authzid + + # The minimal allowed iteration count. Lower #iterations will raise an + # Error. + # + # *WARNING:* The default value (4096) is set to match guidance from + # both {RFC5802}[https://www.rfc-editor.org/rfc/rfc5802#page-12] + # and RFC7677[https://www.rfc-editor.org/rfc/rfc7677#section-4], but + # {modern recommendations}[https://cheatsheetseries.owasp.org/cheatsheets/Password_Storage_Cheat_Sheet.html#pbkdf2] + # are significantly higher. + # + # It is ultimately the server's responsibility to securely store + # password hashes. While this parameter can alert the user to + # insecure password storage and prevent insecure authentication + # exchange, updating the iteration count generally requires resetting + # the password on the server. + attr_reader :min_iterations + + # The maximal allowed iteration count. Higher #iterations will raise an + # Error. + # + # As noted in {RFC5802}[https://www.rfc-editor.org/rfc/rfc5802#section-9] + # >>> + # A hostile server can perform a computational denial-of-service + # attack on clients by sending a big iteration count value. + # + # *WARNING:* The default value is 2³¹ - 1, the maximum signed + # 32-bit integer. This is large enough for the computation to take + # several minutes, and insufficient protection against hostile servers. + # + # Note that OpenSSL::KDF.pbkdf2_hmac is implemented by a + # blocking C function, and cannot be interrupted by +Timeout+ or + # Thread.raise. And it keeps the Global VM lock, as of v4.0 of + # the +openssl+ gem, so other ruby threads will not be able to run. + # + # To prevent a denial of service attack, this must be set to a + # safe value, depending on hardware and version of OpenSSL. It is + # the user's responsibility to enforce minimum and maximum + # iteration counts that are appropriate for their security context. + attr_reader :max_iterations + + # The client nonce, generated by SecureRandom + attr_reader :cnonce + + # The server nonce, which must start with #cnonce + attr_reader :snonce + + # The salt used by the server for this user + attr_reader :salt + + # The iteration count for the selected hash function and user + attr_reader :iterations + + # An error reported by the server during the \SASL exchange. + # + # Does not include errors reported by the protocol, e.g. + # Net::IMAP::NoResponseError. + attr_reader :server_error + + # Memoized ScramAlgorithm#salted_password (needs #salt and #iterations) + def salted_password; @salted_password ||= compute_salted { super } end + + # Memoized ScramAlgorithm#client_key (needs #salt and #iterations) + def client_key; @client_key ||= compute_salted { super } end + + # Memoized ScramAlgorithm#server_key (needs #salt and #iterations) + def server_key; @server_key ||= compute_salted { super } end + + # Returns a new OpenSSL::Digest object, set to the appropriate hash + # function for the chosen mechanism. + # + # The class's +DIGEST_NAME+ constant must be set to the name of an + # algorithm supported by OpenSSL::Digest. + def digest; OpenSSL::Digest.new self.class::DIGEST_NAME end + + # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] + # +client-first-message+. + def initial_client_response + "#{gs2_header}#{client_first_message_bare}" + end + + # responds to the server's challenges + def process(challenge) + case (@state ||= :initial_client_response) + when :initial_client_response + initial_client_response.tap { @state = :server_first_message } + when :server_first_message + recv_server_first_message challenge + final_message_with_proof.tap { @state = :server_final_message } + when :server_final_message + recv_server_final_message challenge + "".tap { @state = :done } + else + raise Error, "server sent after complete, %p" % [challenge] + end + rescue Exception => ex + @state = ex + raise + end + + # Is the authentication exchange complete? + # + # If false, another server continuation is required. + def done?; @state == :done end + + private + + # Checks for +salt+ and +iterations+ before yielding + def compute_salted + String === salt or raise Error, "unknown salt" + Integer === iterations or raise Error, "unknown iterations" + yield + end + + # Need to store this for auth_message + attr_reader :server_first_message + + def format_message(hash) hash.map { _1.join("=") }.join(",") end + + def recv_server_first_message(server_first_message) + @server_first_message = server_first_message + sparams = parse_challenge server_first_message + @snonce = sparams["r"] or + raise Error, "server did not send nonce" + @salt = sparams["s"]&.unpack1("m") or + raise Error, "server did not send salt" + @iterations = sparams["i"]&.then {|i| Integer i } or + raise Error, "server did not send iteration count" + min_iterations <= iterations or + raise Error, "too few iterations: %d" % [iterations] + max_iterations.nil? || iterations <= max_iterations or + raise Error, "too many iterations: %d" % [iterations] + mext = sparams["m"] and + raise Error, "mandatory extension: %p" % [mext] + snonce.start_with? cnonce or + raise Error, "invalid server nonce" + end + + def recv_server_final_message(server_final_message) + sparams = parse_challenge server_final_message + @server_error = sparams["e"] and + raise Error, "server error: %s" % [server_error] + verifier = sparams["v"].unpack1("m") or + raise Error, "server did not send verifier" + verifier == server_signature or + raise Error, "server verify failed: %p != %p" % [ + server_signature, verifier + ] + end + + # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] + # +client-first-message-bare+. + def client_first_message_bare + @client_first_message_bare ||= + format_message(n: gs2_saslname_encode(SASL.saslprep(username)), + r: cnonce) + end + + # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] + # +client-final-message+. + def final_message_with_proof + proof = [client_proof].pack("m0") + "#{client_final_message_without_proof},p=#{proof}" + end + + # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] + # +client-final-message-without-proof+. + def client_final_message_without_proof + @client_final_message_without_proof ||= + format_message(c: [cbind_input].pack("m0"), # channel-binding + r: snonce) # nonce + end + + # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] + # +cbind-input+. + # + # >>> + # *TODO:* implement channel binding, appending +cbind-data+ here. + alias cbind_input gs2_header + + # RFC5802 specifies "that the order of attributes in client or server + # messages is fixed, with the exception of extension attributes", but + # this parses it simply as a hash, without respect to order. Note that + # repeated keys (violating the spec) will use the last value. + def parse_challenge(challenge) + challenge.split(/,/).to_h {|pair| pair.split(/=/, 2) } + rescue ArgumentError + raise Error, "unparsable challenge: %p" % [challenge] + end + + end + + # Authenticator for the "+SCRAM-SHA-1+" SASL mechanism, defined in + # RFC5802[https://tools.ietf.org/html/rfc5802]. + # + # Uses the "SHA-1" digest algorithm from OpenSSL::Digest. + # + # See ScramAuthenticator. + class ScramSHA1Authenticator < ScramAuthenticator + DIGEST_NAME = "SHA1" + end + + # Authenticator for the "+SCRAM-SHA-256+" SASL mechanism, defined in + # RFC7677[https://tools.ietf.org/html/rfc7677]. + # + # Uses the "SHA-256" digest algorithm from OpenSSL::Digest. + # + # See ScramAuthenticator. + class ScramSHA256Authenticator < ScramAuthenticator + DIGEST_NAME = "SHA256" + end + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/stringprep.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/stringprep.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/stringprep.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/stringprep.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,12 @@ +# frozen_string_literal: true + +module Net::IMAP::SASL + + # Alias for Net::IMAP::StringPrep::SASLprep. + SASLprep = Net::IMAP::StringPrep::SASLprep + StringPrep = Net::IMAP::StringPrep # :nodoc: + BidiStringError = Net::IMAP::StringPrep::BidiStringError # :nodoc: + ProhibitedCodepoint = Net::IMAP::StringPrep::ProhibitedCodepoint # :nodoc: + StringPrepError = Net::IMAP::StringPrep::StringPrepError # :nodoc: + +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/xoauth2_authenticator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/xoauth2_authenticator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/xoauth2_authenticator.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl/xoauth2_authenticator.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,106 @@ +# frozen_string_literal: true + +# Authenticator for the "+XOAUTH2+" SASL mechanism. This mechanism was +# originally created for GMail and widely adopted by hosted email providers. +# +XOAUTH2+ has been documented by +# Google[https://developers.google.com/gmail/imap/xoauth2-protocol] and +# Microsoft[https://learn.microsoft.com/en-us/exchange/client-developer/legacy-protocols/how-to-authenticate-an-imap-pop-smtp-application-by-using-oauth]. +# +# This mechanism requires an OAuth2 access token which has been authorized +# with the appropriate OAuth2 scopes to access the user's services. Most of +# these scopes are not standardized---consult each service provider's +# documentation for their scopes. +# +# Although this mechanism was never standardized and has been obsoleted by +# "+OAUTHBEARER+", it is still very widely supported. +# +# See Net::IMAP::SASL::OAuthBearerAuthenticator. +class Net::IMAP::SASL::XOAuth2Authenticator + + # It is unclear from {Google's original XOAUTH2 + # documentation}[https://developers.google.com/gmail/imap/xoauth2-protocol], + # whether "User" refers to the authentication identity (+authcid+) or the + # authorization identity (+authzid+). The authentication identity is + # established for the client by the OAuth token, so it seems that +username+ + # must be the authorization identity. + # + # {Microsoft's documentation for shared + # mailboxes}[https://learn.microsoft.com/en-us/exchange/client-developer/legacy-protocols/how-to-authenticate-an-imap-pop-smtp-application-by-using-oauth#sasl-xoauth2-authentication-for-shared-mailboxes-in-office-365] + # _clearly_ indicates that the Office 365 server interprets it as the + # authorization identity. + # + # Although they _should_ validate that the token has been authorized to access + # the service for +username+, _some_ servers appear to ignore this field, + # relying only the identity and scope authorized by the token. + attr_reader :username + + # Note that, unlike most other authenticators, #username is an alias for the + # authorization identity and not the authentication identity. The + # authenticated identity is established for the client by the #oauth2_token. + alias authzid username + + # An OAuth2 access token which has been authorized with the appropriate OAuth2 + # scopes to use the service for #username. + attr_reader :oauth2_token + alias secret oauth2_token + + # :call-seq: + # new(username, oauth2_token, **) -> authenticator + # new(username:, oauth2_token:, **) -> authenticator + # new(authzid:, oauth2_token:, **) -> authenticator + # + # Creates an Authenticator for the "+XOAUTH2+" SASL mechanism, as specified by + # Google[https://developers.google.com/gmail/imap/xoauth2-protocol], + # Microsoft[https://learn.microsoft.com/en-us/exchange/client-developer/legacy-protocols/how-to-authenticate-an-imap-pop-smtp-application-by-using-oauth] + # and Yahoo[https://senders.yahooinc.com/developer/documentation]. + # + # === Properties + # + # * #username --- the username for the account being accessed. + # + # #authzid --- an alias for #username. + # + # Note that, unlike some other authenticators, +username+ sets the + # _authorization_ identity and not the _authentication_ identity. The + # authenticated identity is established for the client with the OAuth token. + # + # * #oauth2_token --- An OAuth2.0 access token which is authorized to access + # the service for #username. + # + # Any other keyword parameters are quietly ignored. + def initialize(user = nil, token = nil, username: nil, oauth2_token: nil, + authzid: nil, secret: nil, **) + @username = authzid || username || user or + raise ArgumentError, "missing username (authzid)" + @oauth2_token = oauth2_token || secret || token or + raise ArgumentError, "missing oauth2_token" + @done = false + end + + # :call-seq: + # initial_response? -> true + # + # +XOAUTH2+ can send an initial client response. + def initial_response?; true end + + # Returns the XOAUTH2 formatted response, which combines the +username+ + # with the +oauth2_token+. + def process(_data) + build_oauth2_string(@username, @oauth2_token) + ensure + @done = true + end + + # Returns true when the initial client response was sent. + # + # The authentication should not succeed unless this returns true, but it + # does *not* indicate success. + def done?; @done end + + private + + def build_oauth2_string(username, oauth2_token) + format("user=%s\1auth=Bearer %s\1\1", username, oauth2_token) + end + +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,179 @@ +# frozen_string_literal: true + +module Net + class IMAP + + # Pluggable authentication mechanisms for protocols which support SASL + # (Simple Authentication and Security Layer), such as IMAP4, SMTP, LDAP, and + # XMPP. {RFC-4422}[https://tools.ietf.org/html/rfc4422] specifies the + # common \SASL framework: + # >>> + # SASL is conceptually a framework that provides an abstraction layer + # between protocols and mechanisms as illustrated in the following + # diagram. + # + # SMTP LDAP XMPP Other protocols ... + # \ | | / + # \ | | / + # SASL abstraction layer + # / | | \ + # / | | \ + # EXTERNAL GSSAPI PLAIN Other mechanisms ... + # + # Net::IMAP uses SASL via the Net::IMAP#authenticate method. + # + # == Mechanisms + # + # Each mechanism has different properties and requirements. Please consult + # the documentation for the specific mechanisms you are using: + # + # +ANONYMOUS+:: + # See AnonymousAuthenticator. + # + # Allows the user to gain access to public services or resources without + # authenticating or disclosing an identity. + # + # +EXTERNAL+:: + # See ExternalAuthenticator. + # + # Authenticates using already established credentials, such as a TLS + # certificate or IPSec. + # + # +OAUTHBEARER+:: + # See OAuthBearerAuthenticator. + # + # Login using an OAuth2 Bearer token. This is the standard mechanism + # for using OAuth2 with \SASL, but it is not yet deployed as widely as + # +XOAUTH2+. + # + # +PLAIN+:: + # See PlainAuthenticator. + # + # Login using clear-text username and password. + # + # +SCRAM-SHA-1+:: + # +SCRAM-SHA-256+:: + # See ScramAuthenticator. + # + # Login by username and password. The password is not sent to the + # server but is used in a salted challenge/response exchange. + # +SCRAM-SHA-1+ and +SCRAM-SHA-256+ are directly supported by + # Net::IMAP::SASL. New authenticators can easily be added for any other + # SCRAM-* mechanism if the digest algorithm is supported by + # OpenSSL::Digest. + # + # +XOAUTH2+:: + # See XOAuth2Authenticator. + # + # Login using a username and an OAuth2 access token. Non-standard and + # obsoleted by +OAUTHBEARER+, but widely supported. + # + # See the {SASL mechanism + # registry}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] + # for a list of all SASL mechanisms and their specifications. To register + # new authenticators, see Authenticators. + # + # === Deprecated mechanisms + # + # Obsolete mechanisms should be avoided, but are still available for + # backwards compatibility. + # + # >>> + # For +DIGEST-MD5+ see DigestMD5Authenticator. + # + # For +LOGIN+, see LoginAuthenticator. + # + # For +CRAM-MD5+, see CramMD5Authenticator. + # + # Using a deprecated mechanism will print a warning. + # + module SASL + # Exception class for any client error detected during the authentication + # exchange. + # + # When the _server_ reports an authentication failure, it will respond + # with a protocol specific error instead, e.g: +BAD+ or +NO+ in IMAP. + # + # When the client encounters any error, it *must* consider the + # authentication exchange to be unsuccessful and it might need to drop the + # connection. For example, if the server reports that the authentication + # exchange was successful or the protocol does not allow additional + # authentication attempts. + Error = Class.new(StandardError) + + # Indicates an authentication exchange that will be or has been canceled + # by the client, not due to any error or failure during processing. + AuthenticationCanceled = Class.new(Error) + + # Indicates an error when processing a server challenge, e.g: an invalid + # or unparsable challenge. An underlying exception may be available as + # the exception's #cause. + AuthenticationError = Class.new(Error) + + # Indicates that authentication cannot proceed because one of the server's + # messages has not passed integrity checks. + AuthenticationFailed = Class.new(Error) + + # Indicates that authentication cannot proceed because one of the server's + # ended authentication prematurely. + class AuthenticationIncomplete < AuthenticationFailed + # The success response from the server + attr_reader :response + + def initialize(response, message = "authentication ended prematurely") + super(message) + @response = response + end + end + + # autoloading to avoid loading all of the regexps when they aren't used. + sasl_stringprep_rb = File.expand_path("sasl/stringprep", __dir__) + autoload :StringPrep, sasl_stringprep_rb + autoload :SASLprep, sasl_stringprep_rb + autoload :StringPrepError, sasl_stringprep_rb + autoload :ProhibitedCodepoint, sasl_stringprep_rb + autoload :BidiStringError, sasl_stringprep_rb + + sasl_dir = File.expand_path("sasl", __dir__) + autoload :AuthenticationExchange, "#{sasl_dir}/authentication_exchange" + autoload :ClientAdapter, "#{sasl_dir}/client_adapter" + autoload :ProtocolAdapters, "#{sasl_dir}/protocol_adapters" + + autoload :Authenticators, "#{sasl_dir}/authenticators" + autoload :GS2Header, "#{sasl_dir}/gs2_header" + autoload :ScramAlgorithm, "#{sasl_dir}/scram_algorithm" + + autoload :AnonymousAuthenticator, "#{sasl_dir}/anonymous_authenticator" + autoload :ExternalAuthenticator, "#{sasl_dir}/external_authenticator" + autoload :OAuthBearerAuthenticator, "#{sasl_dir}/oauthbearer_authenticator" + autoload :PlainAuthenticator, "#{sasl_dir}/plain_authenticator" + autoload :ScramAuthenticator, "#{sasl_dir}/scram_authenticator" + autoload :ScramSHA1Authenticator, "#{sasl_dir}/scram_authenticator" + autoload :ScramSHA256Authenticator, "#{sasl_dir}/scram_authenticator" + autoload :XOAuth2Authenticator, "#{sasl_dir}/xoauth2_authenticator" + + autoload :CramMD5Authenticator, "#{sasl_dir}/cram_md5_authenticator" + autoload :DigestMD5Authenticator, "#{sasl_dir}/digest_md5_authenticator" + autoload :LoginAuthenticator, "#{sasl_dir}/login_authenticator" + + # Returns the default global SASL::Authenticators instance. + def self.authenticators; @authenticators ||= Authenticators.new end + + # Delegates to registry.new See Authenticators#new. + def self.authenticator(*args, registry: authenticators, **kwargs, &block) + registry.new(*args, **kwargs, &block) + end + + # Delegates to ::authenticators. See Authenticators#add_authenticator. + def self.add_authenticator(...) authenticators.add_authenticator(...) end + + module_function + + # See Net::IMAP::StringPrep::SASLprep#saslprep. + def saslprep(string, **opts) + Net::IMAP::StringPrep::SASLprep.saslprep(string, **opts) + end + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl_adapter.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl_adapter.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl_adapter.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sasl_adapter.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,21 @@ +# frozen_string_literal: true + +module Net + class IMAP + + # Experimental + class SASLAdapter < SASL::ClientAdapter + include SASL::ProtocolAdapters::IMAP + + RESPONSE_ERRORS = [NoResponseError, BadResponseError, ByeResponseError] + .freeze + + def response_errors; RESPONSE_ERRORS end + def sasl_ir_capable?; client.capable?("SASL-IR") end + def auth_capable?(mechanism); client.auth_capable?(mechanism) end + def drop_connection; client.logout! end + def drop_connection!; client.disconnect end + end + + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/search_result.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/search_result.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/search_result.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/search_result.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,146 @@ +# frozen_string_literal: true + +module Net + class IMAP + + # An array of sequence numbers returned by Net::IMAP#search, or unique + # identifiers returned by Net::IMAP#uid_search. + # + # For backward compatibility, SearchResult inherits from Array. + class SearchResult < Array + + # Returns a SearchResult populated with the given +seq_nums+. + # + # Net::IMAP::SearchResult[1, 3, 5, modseq: 9] + # # => Net::IMAP::SearchResult[1, 3, 5, modseq: 9] + def self.[](*seq_nums, modseq: nil) + new(seq_nums, modseq: modseq) + end + + # A modification sequence number, as described by the +CONDSTORE+ + # extension in {[RFC7162 + # §3.1.6]}[https://www.rfc-editor.org/rfc/rfc7162.html#section-3.1.6]. + attr_reader :modseq + + # Returns a SearchResult populated with the given +seq_nums+. + # + # Net::IMAP::SearchResult.new([1, 3, 5], modseq: 9) + # # => Net::IMAP::SearchResult[1, 3, 5, modseq: 9] + def initialize(seq_nums, modseq: nil) + super(seq_nums.to_ary.map { Integer _1 }) + @modseq = Integer modseq if modseq + end + + # Returns whether +other+ is a SearchResult with the same values and the + # same #modseq. The order of numbers is irrelevant. + # + # Net::IMAP::SearchResult[123, 456, modseq: 789] == + # Net::IMAP::SearchResult[123, 456, modseq: 789] + # # => true + # Net::IMAP::SearchResult[123, 456, modseq: 789] == + # Net::IMAP::SearchResult[456, 123, modseq: 789] + # # => true + # + # Net::IMAP::SearchResult[123, 456, modseq: 789] == + # Net::IMAP::SearchResult[987, 654, modseq: 789] + # # => false + # Net::IMAP::SearchResult[123, 456, modseq: 789] == + # Net::IMAP::SearchResult[1, 2, 3, modseq: 9999] + # # => false + # + # SearchResult can be compared directly with Array, if #modseq is nil and + # the array is sorted. + # + # Net::IMAP::SearchResult[9, 8, 6, 4, 1] == [1, 4, 6, 8, 9] # => true + # Net::IMAP::SearchResult[3, 5, 7, modseq: 99] == [3, 5, 7] # => false + # + # Note that Array#== does require matching order and ignores #modseq. + # + # [9, 8, 6, 4, 1] == Net::IMAP::SearchResult[1, 4, 6, 8, 9] # => false + # [3, 5, 7] == Net::IMAP::SearchResult[3, 5, 7, modseq: 99] # => true + # + def ==(other) + (modseq ? + other.is_a?(self.class) && modseq == other.modseq : + other.is_a?(Array)) && + size == other.size && + sort == other.sort + end + + # Hash equality. Unlike #==, order will be taken into account. + def hash + return super if modseq.nil? + [super, self.class, modseq].hash + end + + # Hash equality. Unlike #==, order will be taken into account. + def eql?(other) + return super if modseq.nil? + self.class == other.class && hash == other.hash + end + + # Returns a string that represents the SearchResult. + # + # Net::IMAP::SearchResult[123, 456, 789].inspect + # # => "[123, 456, 789]" + # + # Net::IMAP::SearchResult[543, 210, 678, modseq: 2048].inspect + # # => "Net::IMAP::SearchResult[543, 210, 678, modseq: 2048]" + # + def inspect + return super if modseq.nil? + "%s[%s, modseq: %p]" % [self.class, join(", "), modseq] + end + + # Returns a string that follows the formal \IMAP syntax. + # + # data = Net::IMAP::SearchResult[2, 8, 32, 128, 256, 512] + # data.to_s # => "* SEARCH 2 8 32 128 256 512" + # data.to_s("SEARCH") # => "* SEARCH 2 8 32 128 256 512" + # data.to_s("SORT") # => "* SORT 2 8 32 128 256 512" + # data.to_s(nil) # => "2 8 32 128 256 512" + # + # data = Net::IMAP::SearchResult[1, 3, 16, 1024, modseq: 2048].to_s + # data.to_s # => "* SEARCH 1 3 16 1024 (MODSEQ 2048)" + # data.to_s("SORT") # => "* SORT 1 3 16 1024 (MODSEQ 2048)" + # data.to_s # => "1 3 16 1024 (MODSEQ 2048)" + # + def to_s(type = "SEARCH") + str = +"" + str << "* %s " % [type.to_str] unless type.nil? + str << join(" ") + str << " (MODSEQ %d)" % [modseq] if modseq + -str + end + + # Converts the SearchResult into a SequenceSet. + # + # Net::IMAP::SearchResult[9, 1, 2, 4, 10, 12, 3, modseq: 123_456] + # .to_sequence_set + # # => Net::IMAP::SequenceSet["1:4,9:10,12"] + def to_sequence_set; SequenceSet[*self] end + + def pretty_print(pp) + return super if modseq.nil? + pp.text self.class.name + "[" + pp.group_sub do + pp.nest(2) do + pp.breakable "" + each do |num| + pp.pp num + pp.text "," + pp.fill_breakable + end + pp.breakable "" + pp.text "modseq: " + pp.pp modseq + end + pp.breakable "" + pp.text "]" + end + end + + end + + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sequence_set.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sequence_set.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/sequence_set.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/sequence_set.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,1577 @@ +# frozen_string_literal: true + +module Net + class IMAP + + ## + # An \IMAP sequence set is a set of message sequence numbers or unique + # identifier numbers ("UIDs"). It contains numbers and ranges of numbers. + # The numbers are all non-zero unsigned 32-bit integers and one special + # value ("*") that represents the largest value in the mailbox. + # + # Certain types of \IMAP responses will contain a SequenceSet, for example + # the data for a "MODIFIED" ResponseCode. Some \IMAP commands may + # receive a SequenceSet as an argument, for example IMAP#search, IMAP#fetch, + # and IMAP#store. + # + # == EXPERIMENTAL API + # + # SequenceSet is currently experimental. Only two methods, ::[] and + # #valid_string, are considered stable. Although the API isn't expected to + # change much, any other methods may be removed or changed without + # deprecation. + # + # == Creating sequence sets + # + # SequenceSet.new with no arguments creates an empty sequence set. Note + # that an empty sequence set is invalid in the \IMAP grammar. + # + # set = Net::IMAP::SequenceSet.new + # set.empty? #=> true + # set.valid? #=> false + # set.valid_string #!> raises DataFormatError + # set << 1..10 + # set.empty? #=> false + # set.valid? #=> true + # set.valid_string #=> "1:10" + # + # SequenceSet.new may receive a single optional argument: a non-zero 32 bit + # unsigned integer, a range, a sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # set = Net::IMAP::SequenceSet.new(1) + # set.valid_string #=> "1" + # set = Net::IMAP::SequenceSet.new(1..100) + # set.valid_string #=> "1:100" + # set = Net::IMAP::SequenceSet.new(1...100) + # set.valid_string #=> "1:99" + # set = Net::IMAP::SequenceSet.new([1, 2, 5..]) + # set.valid_string #=> "1:2,5:*" + # set = Net::IMAP::SequenceSet.new("1,2,3:7,5,6:10,2048,1024") + # set.valid_string #=> "1,2,3:7,5,6:10,2048,1024" + # set = Net::IMAP::SequenceSet.new(1, 2, 3..7, 5, 6..10, 2048, 1024) + # set.valid_string #=> "1:10,55,1024:2048" + # + # Use ::[] with one or more arguments to create a frozen SequenceSet. An + # invalid (empty) set cannot be created with ::[]. + # + # set = Net::IMAP::SequenceSet["1,2,3:7,5,6:10,2048,1024"] + # set.valid_string #=> "1,2,3:7,5,6:10,2048,1024" + # set = Net::IMAP::SequenceSet[1, 2, [3..7, 5], 6..10, 2048, 1024] + # set.valid_string #=> "1:10,55,1024:2048" + # + # == Ordered and Normalized sets + # + # Sometimes the order of the set's members is significant, such as with the + # +ESORT+, CONTEXT=SORT, and +UIDPLUS+ extensions. So, when a + # sequence set is created by the parser or with a single string value, that + # #string representation is preserved. + # + # Internally, SequenceSet stores a normalized representation which sorts all + # entries, de-duplicates numbers, and coalesces adjacent or overlapping + # ranges. Most methods use this normalized representation to achieve + # O(lg n) porformance. Use #entries or #each_entry to enumerate + # the set in its original order. + # + # Most modification methods convert #string to its normalized form. To + # preserve #string order while modifying a set, use #append, #string=, or + # #replace. + # + # == Using * + # + # \IMAP sequence sets may contain a special value "*", which + # represents the largest number in use. From +seq-number+ in + # {RFC9051 §9}[https://www.rfc-editor.org/rfc/rfc9051.html#section-9-5]: + # >>> + # In the case of message sequence numbers, it is the number of messages + # in a non-empty mailbox. In the case of unique identifiers, it is the + # unique identifier of the last message in the mailbox or, if the + # mailbox is empty, the mailbox's current UIDNEXT value. + # + # When creating a SequenceSet, * may be input as -1, + # "*", :*, an endless range, or a range ending in + # -1. When converting to #elements, #ranges, or #numbers, it will + # output as either :* or an endless range. For example: + # + # Net::IMAP::SequenceSet["1,3,*"].to_a #=> [1, 3, :*] + # Net::IMAP::SequenceSet["1,234:*"].to_a #=> [1, 234..] + # Net::IMAP::SequenceSet[1234..-1].to_a #=> [1234..] + # Net::IMAP::SequenceSet[1234..].to_a #=> [1234..] + # + # Net::IMAP::SequenceSet[1234..].to_s #=> "1234:*" + # Net::IMAP::SequenceSet[1234..-1].to_s #=> "1234:*" + # + # Use #limit to convert "*" to a maximum value. When a range + # includes "*", the maximum value will always be matched: + # + # Net::IMAP::SequenceSet["9999:*"].limit(max: 25) + # #=> Net::IMAP::SequenceSet["25"] + # + # === Surprising * behavior + # + # When a set includes *, some methods may have surprising behavior. + # + # For example, #complement treats * as its own number. This way, + # the #intersection of a set and its #complement will always be empty. + # This is not how an \IMAP server interprets the set: it will convert + # * to either the number of messages in the mailbox or +UIDNEXT+, + # as appropriate. And there _will_ be overlap between a set and its + # complement after #limit is applied to each: + # + # ~Net::IMAP::SequenceSet["*"] == Net::IMAP::SequenceSet[1..(2**32-1)] + # ~Net::IMAP::SequenceSet[1..5] == Net::IMAP::SequenceSet["6:*"] + # + # set = Net::IMAP::SequenceSet[1..5] + # (set & ~set).empty? => true + # + # (set.limit(max: 4) & (~set).limit(max: 4)).to_a => [4] + # + # When counting the number of numbers in a set, * will be counted + # _except_ when UINT32_MAX is also in the set: + # UINT32_MAX = 2**32 - 1 + # Net::IMAP::SequenceSet["*"].count => 1 + # Net::IMAP::SequenceSet[1..UINT32_MAX - 1, :*].count => UINT32_MAX + # + # Net::IMAP::SequenceSet["1:*"].count => UINT32_MAX + # Net::IMAP::SequenceSet[UINT32_MAX, :*].count => 1 + # Net::IMAP::SequenceSet[UINT32_MAX..].count => 1 + # + # == What's here? + # + # SequenceSet provides methods for: + # * {Creating a SequenceSet}[rdoc-ref:SequenceSet@Methods+for+Creating+a+SequenceSet] + # * {Comparing}[rdoc-ref:SequenceSet@Methods+for+Comparing] + # * {Querying}[rdoc-ref:SequenceSet@Methods+for+Querying] + # * {Iterating}[rdoc-ref:SequenceSet@Methods+for+Iterating] + # * {Set Operations}[rdoc-ref:SequenceSet@Methods+for+Set+Operations] + # * {Assigning}[rdoc-ref:SequenceSet@Methods+for+Assigning] + # * {Deleting}[rdoc-ref:SequenceSet@Methods+for+Deleting] + # * {IMAP String Formatting}[rdoc-ref:SequenceSet@Methods+for+IMAP+String+Formatting] + # + # === Methods for Creating a \SequenceSet + # * ::[]: Creates a validated frozen sequence set from one or more inputs. + # * ::new: Creates a new mutable sequence set, which may be empty (invalid). + # * ::try_convert: Calls +to_sequence_set+ on an object and verifies that + # the result is a SequenceSet. + # * ::empty: Returns a frozen empty (invalid) SequenceSet. + # * ::full: Returns a frozen SequenceSet containing every possible number. + # + # === Methods for Comparing + # + # Comparison to another \SequenceSet: + # - #==: Returns whether a given set contains the same numbers as +self+. + # - #eql?: Returns whether a given set uses the same #string as +self+. + # + # Comparison to objects which are convertible to \SequenceSet: + # - #===: + # Returns whether a given object is fully contained within +self+, or + # +nil+ if the object cannot be converted to a compatible type. + # - #cover?: + # Returns whether a given object is fully contained within +self+. + # - #intersect? (aliased as #overlap?): + # Returns whether +self+ and a given object have any common elements. + # - #disjoint?: + # Returns whether +self+ and a given object have no common elements. + # + # === Methods for Querying + # These methods do not modify +self+. + # + # Set membership: + # - #include? (aliased as #member?): + # Returns whether a given element (nz-number, range, or *) is + # contained by the set. + # - #include_star?: Returns whether the set contains *. + # + # Minimum and maximum value elements: + # - #min: Returns the minimum number in the set. + # - #max: Returns the maximum number in the set. + # - #minmax: Returns the minimum and maximum numbers in the set. + # + # Accessing value by offset in sorted set: + # - #[] (aliased as #slice): Returns the number or consecutive subset at a + # given offset or range of offsets in the sorted set. + # - #at: Returns the number at a given offset in the sorted set. + # - #find_index: Returns the given number's offset in the sorted set. + # + # Accessing value by offset in ordered entries + # - #ordered_at: Returns the number at a given offset in the ordered entries. + # - #find_ordered_index: Returns the index of the given number's first + # occurrence in entries. + # + # Set cardinality: + # - #count (aliased as #size): Returns the count of numbers in the set. + # Duplicated numbers are not counted. + # - #empty?: Returns whether the set has no members. \IMAP syntax does not + # allow empty sequence sets. + # - #valid?: Returns whether the set has any members. + # - #full?: Returns whether the set contains every possible value, including + # *. + # + # Denormalized properties: + # - #has_duplicates?: Returns whether the ordered entries repeat any + # numbers. + # - #count_duplicates: Returns the count of repeated numbers in the ordered + # entries. + # - #count_with_duplicates: Returns the count of numbers in the ordered + # entries, including any repeated numbers. + # + # === Methods for Iterating + # + # Normalized (sorted and coalesced): + # - #each_element: Yields each number and range in the set, sorted and + # coalesced, and returns +self+. + # - #elements (aliased as #to_a): Returns an Array of every number and range + # in the set, sorted and coalesced. + # - #each_range: + # Yields each element in the set as a Range and returns +self+. + # - #ranges: Returns an Array of every element in the set, converting + # numbers into ranges of a single value. + # - #each_number: Yields each number in the set and returns +self+. + # - #numbers: Returns an Array with every number in the set, expanding + # ranges into all of their contained numbers. + # - #to_set: Returns a Set containing all of the #numbers in the set. + # + # Order preserving: + # - #each_entry: Yields each number and range in the set, unsorted and + # without deduplicating numbers or coalescing ranges, and returns +self+. + # - #entries: Returns an Array of every number and range in the set, + # unsorted and without deduplicating numbers or coalescing ranges. + # - #each_ordered_number: Yields each number in the ordered entries and + # returns +self+. + # + # === Methods for \Set Operations + # These methods do not modify +self+. + # + # - #| (aliased as #union and #+): Returns a new set combining all members + # from +self+ with all members from the other set. + # - #& (aliased as #intersection): Returns a new set containing all members + # common to +self+ and the other set. + # - #- (aliased as #difference): Returns a copy of +self+ with all members + # in the other set removed. + # - #^ (aliased as #xor): Returns a new set containing all members from + # +self+ and the other set except those common to both. + # - #~ (aliased as #complement): Returns a new set containing all members + # that are not in +self+ + # - #limit: Returns a copy of +self+ which has replaced * with a + # given maximum value and removed all members over that maximum. + # + # === Methods for Assigning + # These methods add or replace elements in +self+. + # + # Normalized (sorted and coalesced): + # + # These methods always update #string to be fully sorted and coalesced. + # + # - #add (aliased as #<<): Adds a given element to the set; returns +self+. + # - #add?: If the given element is not fully included the set, adds it and + # returns +self+; otherwise, returns +nil+. + # - #merge: Adds all members of the given sets into this set; returns +self+. + # - #complement!: Replaces the contents of the set with its own #complement. + # + # Order preserving: + # + # These methods _may_ cause #string to not be sorted or coalesced. + # + # - #append: Adds the given entry to the set, appending it to the existing + # string, and returns +self+. + # - #string=: Assigns a new #string value and replaces #elements to match. + # - #replace: Replaces the contents of the set with the contents + # of a given object. + # + # === Methods for Deleting + # These methods remove elements from +self+, and update #string to be fully + # sorted and coalesced. + # + # - #clear: Removes all elements in the set; returns +self+. + # - #delete: Removes a given element from the set; returns +self+. + # - #delete?: If the given element is included in the set, removes it and + # returns it; otherwise, returns +nil+. + # - #delete_at: Removes the number at a given offset. + # - #slice!: Removes the number or consecutive numbers at a given offset or + # range of offsets. + # - #subtract: Removes all members of the given sets from this set; returns + # +self+. + # - #limit!: Replaces * with a given maximum value and removes all + # members over that maximum; returns +self+. + # + # === Methods for \IMAP String Formatting + # + # - #to_s: Returns the +sequence-set+ string, or an empty string when the + # set is empty. + # - #string: Returns the +sequence-set+ string, or nil when empty. + # - #valid_string: Returns the +sequence-set+ string, or raises + # DataFormatError when the set is empty. + # - #normalized_string: Returns a sequence-set string with its + # elements sorted and coalesced, or nil when the set is empty. + # - #normalize: Returns a new set with this set's normalized +sequence-set+ + # representation. + # - #normalize!: Updates #string to its normalized +sequence-set+ + # representation and returns +self+. + # + class SequenceSet + # The largest possible non-zero unsigned 32-bit integer + UINT32_MAX = 2**32 - 1 + + # represents "*" internally, to simplify sorting (etc) + STAR_INT = UINT32_MAX + 1 + private_constant :STAR_INT + + # valid inputs for "*" + STARS = [:*, ?*, -1].freeze + private_constant :STAR_INT, :STARS + + COERCIBLE = ->{ _1.respond_to? :to_sequence_set } + ENUMABLE = ->{ _1.respond_to?(:each) && _1.respond_to?(:empty?) } + private_constant :COERCIBLE, :ENUMABLE + + class << self + + # :call-seq: + # SequenceSet[*inputs] -> valid frozen sequence set + # + # Returns a frozen SequenceSet, constructed from +inputs+. + # + # When only a single valid frozen SequenceSet is given, that same set is + # returned. + # + # An empty SequenceSet is invalid and will raise a DataFormatError. + # + # Use ::new to create a mutable or empty SequenceSet. + def [](first, *rest) + if rest.empty? + if first.is_a?(SequenceSet) && first.frozen? && first.valid? + first + else + new(first).validate.freeze + end + else + new(first).merge(*rest).validate.freeze + end + end + + # :call-seq: + # SequenceSet.try_convert(obj) -> sequence set or nil + # + # If +obj+ is a SequenceSet, returns +obj+. If +obj+ responds_to + # +to_sequence_set+, calls +obj.to_sequence_set+ and returns the result. + # Otherwise returns +nil+. + # + # If +obj.to_sequence_set+ doesn't return a SequenceSet, an exception is + # raised. + def try_convert(obj) + return obj if obj.is_a?(SequenceSet) + return nil unless obj.respond_to?(:to_sequence_set) + obj = obj.to_sequence_set + return obj if obj.is_a?(SequenceSet) + raise DataFormatError, "invalid object returned from to_sequence_set" + end + + # Returns a frozen empty set singleton. Note that valid \IMAP sequence + # sets cannot be empty, so this set is _invalid_. + def empty; EMPTY end + + # Returns a frozen full set singleton: "1:*" + def full; FULL end + + end + + # Create a new SequenceSet object from +input+, which may be another + # SequenceSet, an IMAP formatted +sequence-set+ string, a number, a + # range, :*, or an enumerable of these. + # + # Use ::[] to create a frozen (non-empty) SequenceSet. + def initialize(input = nil) input ? replace(input) : clear end + + # Removes all elements and returns self. + def clear; @tuples, @string = [], nil; self end + + # Replace the contents of the set with the contents of +other+ and returns + # +self+. + # + # +other+ may be another SequenceSet, or it may be an IMAP +sequence-set+ + # string, a number, a range, *, or an enumerable of these. + def replace(other) + case other + when SequenceSet then initialize_dup(other) + when String then self.string = other + else clear; merge other + end + self + end + + # Returns the \IMAP +sequence-set+ string representation, or raises a + # DataFormatError when the set is empty. + # + # Use #string to return +nil+ or #to_s to return an empty string without + # error. + # + # Related: #string, #normalized_string, #to_s + def valid_string + raise DataFormatError, "empty sequence-set" if empty? + string + end + + # Returns the \IMAP +sequence-set+ string representation, or +nil+ when + # the set is empty. Note that an empty set is invalid in the \IMAP + # syntax. + # + # Use #valid_string to raise an exception when the set is empty, or #to_s + # to return an empty string. + # + # If the set was created from a single string, it is not normalized. If + # the set is updated the string will be normalized. + # + # Related: #valid_string, #normalized_string, #to_s + def string; @string ||= normalized_string if valid? end + + # Assigns a new string to #string and resets #elements to match. It + # cannot be set to an empty string—assign +nil+ or use #clear instead. + # The string is validated but not normalized. + # + # Use #add or #merge to add a string to an existing set. + # + # Related: #replace, #clear + def string=(str) + if str.nil? + clear + else + str = String.try_convert(str) or raise ArgumentError, "not a string" + tuples = str_to_tuples str + @tuples, @string = [], -str + tuples_add tuples + end + end + + # Returns the \IMAP +sequence-set+ string representation, or an empty + # string when the set is empty. Note that an empty set is invalid in the + # \IMAP syntax. + # + # Related: #valid_string, #normalized_string, #to_s + def to_s; string || "" end + + # Freezes and returns the set. A frozen SequenceSet is Ractor-safe. + def freeze + return self if frozen? + string + @tuples.each(&:freeze).freeze + super + end + + # :call-seq: self == other -> true or false + # + # Returns true when the other SequenceSet represents the same message + # identifiers. Encoding difference—such as order, overlaps, or + # duplicates—are ignored. + # + # Net::IMAP::SequenceSet["1:3"] == Net::IMAP::SequenceSet["1:3"] + # #=> true + # Net::IMAP::SequenceSet["1,2,3"] == Net::IMAP::SequenceSet["1:3"] + # #=> true + # Net::IMAP::SequenceSet["1,3"] == Net::IMAP::SequenceSet["3,1"] + # #=> true + # Net::IMAP::SequenceSet["9,1:*"] == Net::IMAP::SequenceSet["1:*"] + # #=> true + # + # Related: #eql?, #normalize + def ==(other) + self.class == other.class && + (to_s == other.to_s || tuples == other.tuples) + end + + # :call-seq: eql?(other) -> true or false + # + # Hash equality requires the same encoded #string representation. + # + # Net::IMAP::SequenceSet["1:3"] .eql? Net::IMAP::SequenceSet["1:3"] + # #=> true + # Net::IMAP::SequenceSet["1,2,3"].eql? Net::IMAP::SequenceSet["1:3"] + # #=> false + # Net::IMAP::SequenceSet["1,3"] .eql? Net::IMAP::SequenceSet["3,1"] + # #=> false + # Net::IMAP::SequenceSet["9,1:*"].eql? Net::IMAP::SequenceSet["1:*"] + # #=> false + # + # Related: #==, #normalize + def eql?(other) self.class == other.class && string == other.string end + + # See #eql? + def hash; [self.class, string].hash end + + # :call-seq: self === other -> true | false | nil + # + # Returns whether +other+ is contained within the set. Returns +nil+ if a + # StandardError is raised while converting +other+ to a comparable type. + # + # Related: #cover?, #include?, #include_star? + def ===(other) + cover?(other) + rescue + nil + end + + # :call-seq: cover?(other) -> true | false | nil + # + # Returns whether +other+ is contained within the set. +other+ may be any + # object that would be accepted by ::new. + # + # Related: #===, #include?, #include_star? + def cover?(other) input_to_tuples(other).none? { !include_tuple?(_1) } end + + # Returns +true+ when a given number or range is in +self+, and +false+ + # otherwise. Returns +false+ unless +number+ is an Integer, Range, or + # *. + # + # set = Net::IMAP::SequenceSet["5:10,100,111:115"] + # set.include? 1 #=> false + # set.include? 5..10 #=> true + # set.include? 11..20 #=> false + # set.include? 100 #=> true + # set.include? 6 #=> true, covered by "5:10" + # set.include? 4..9 #=> true, covered by "5:10" + # set.include? "4:9" #=> true, strings are parsed + # set.include? 4..9 #=> false, intersection is not sufficient + # set.include? "*" #=> false, use #limit to re-interpret "*" + # set.include? -1 #=> false, -1 is interpreted as "*" + # + # set = Net::IMAP::SequenceSet["5:10,100,111:*"] + # set.include? :* #=> true + # set.include? "*" #=> true + # set.include? -1 #=> true + # set.include? 200.. #=> true + # set.include? 100.. #=> false + # + # Related: #include_star?, #cover?, #=== + def include?(element) include_tuple? input_to_tuple element end + + alias member? include? + + # Returns +true+ when the set contains *. + def include_star?; @tuples.last&.last == STAR_INT end + + # Returns +true+ if the set and a given object have any common elements, + # +false+ otherwise. + # + # Net::IMAP::SequenceSet["5:10"].intersect? "7,9,11" #=> true + # Net::IMAP::SequenceSet["5:10"].intersect? "11:33" #=> false + # + # Related: #intersection, #disjoint? + def intersect?(other) + valid? && input_to_tuples(other).any? { intersect_tuple? _1 } + end + alias overlap? intersect? + + # Returns +true+ if the set and a given object have no common elements, + # +false+ otherwise. + # + # Net::IMAP::SequenceSet["5:10"].disjoint? "7,9,11" #=> false + # Net::IMAP::SequenceSet["5:10"].disjoint? "11:33" #=> true + # + # Related: #intersection, #intersect? + def disjoint?(other) + empty? || input_to_tuples(other).none? { intersect_tuple? _1 } + end + + # :call-seq: max(star: :*) => integer or star or nil + # + # Returns the maximum value in +self+, +star+ when the set includes + # *, or +nil+ when the set is empty. + def max(star: :*) + (val = @tuples.last&.last) && val == STAR_INT ? star : val + end + + # :call-seq: min(star: :*) => integer or star or nil + # + # Returns the minimum value in +self+, +star+ when the only value in the + # set is *, or +nil+ when the set is empty. + def min(star: :*) + (val = @tuples.first&.first) && val == STAR_INT ? star : val + end + + # :call-seq: minmax(star: :*) => nil or [integer, integer or star] + # + # Returns a 2-element array containing the minimum and maximum numbers in + # +self+, or +nil+ when the set is empty. + def minmax(star: :*); [min(star: star), max(star: star)] unless empty? end + + # Returns false when the set is empty. + def valid?; !empty? end + + # Returns true if the set contains no elements + def empty?; @tuples.empty? end + + # Returns true if the set contains every possible element. + def full?; @tuples == [[1, STAR_INT]] end + + # :call-seq: + # self + other -> sequence set + # self | other -> sequence set + # union(other) -> sequence set + # + # Returns a new sequence set that has every number in the +other+ object + # added. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet["1:5"] | 2 | [4..6, 99] + # #=> Net::IMAP::SequenceSet["1:6,99"] + # + # Related: #add, #merge + def |(other) remain_frozen dup.merge other end + alias :+ :| + alias union :| + + # :call-seq: + # self - other -> sequence set + # difference(other) -> sequence set + # + # Returns a new sequence set built by duplicating this set and removing + # every number that appears in +other+. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet[1..5] - 2 - 4 - 6 + # #=> Net::IMAP::SequenceSet["1,3,5"] + # + # Related: #subtract + def -(other) remain_frozen dup.subtract other end + alias difference :- + + # :call-seq: + # self & other -> sequence set + # intersection(other) -> sequence set + # + # Returns a new sequence set containing only the numbers common to this + # set and +other+. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet[1..5] & [2, 4, 6] + # #=> Net::IMAP::SequenceSet["2,4"] + # + # (seqset & other) is equivalent to (seqset - ~other). + def &(other) + remain_frozen dup.subtract SequenceSet.new(other).complement! + end + alias intersection :& + + # :call-seq: + # self ^ other -> sequence set + # xor(other) -> sequence set + # + # Returns a new sequence set containing numbers that are exclusive between + # this set and +other+. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet[1..5] ^ [2, 4, 6] + # #=> Net::IMAP::SequenceSet["1,3,5:6"] + # + # (seqset ^ other) is equivalent to ((seqset | other) - + # (seqset & other)). + def ^(other) remain_frozen (dup | other).subtract(self & other) end + alias xor :^ + + # :call-seq: + # ~ self -> sequence set + # complement -> sequence set + # + # Returns the complement of self, a SequenceSet which contains all numbers + # _except_ for those in this set. + # + # ~Net::IMAP::SequenceSet.full #=> Net::IMAP::SequenceSet.empty + # ~Net::IMAP::SequenceSet.empty #=> Net::IMAP::SequenceSet.full + # ~Net::IMAP::SequenceSet["1:5,100:222"] + # #=> Net::IMAP::SequenceSet["6:99,223:*"] + # ~Net::IMAP::SequenceSet["6:99,223:*"] + # #=> Net::IMAP::SequenceSet["1:5,100:222"] + # + # Related: #complement! + def ~; remain_frozen dup.complement! end + alias complement :~ + + # :call-seq: + # add(element) -> self + # self << other -> self + # + # Adds a range or number to the set and returns +self+. + # + # #string will be regenerated. Use #merge to add many elements at once. + # + # Related: #add?, #merge, #union + def add(element) + tuple_add input_to_tuple element + normalize! + end + alias << add + + # Adds a range or number to the set and returns +self+. + # + # Unlike #add, #merge, or #union, the new value is appended to #string. + # This may result in a #string which has duplicates or is out-of-order. + def append(entry) + modifying! + tuple = input_to_tuple entry + entry = tuple_to_str tuple + string unless empty? # write @string before tuple_add + tuple_add tuple + @string = -(@string ? "#{@string},#{entry}" : entry) + self + end + + # :call-seq: add?(element) -> self or nil + # + # Adds a range or number to the set and returns +self+. Returns +nil+ + # when the element is already included in the set. + # + # #string will be regenerated. Use #merge to add many elements at once. + # + # Related: #add, #merge, #union, #include? + def add?(element) + add element unless include? element + end + + # :call-seq: delete(element) -> self + # + # Deletes the given range or number from the set and returns +self+. + # + # #string will be regenerated after deletion. Use #subtract to remove + # many elements at once. + # + # Related: #delete?, #delete_at, #subtract, #difference + def delete(element) + tuple_subtract input_to_tuple element + normalize! + end + + # :call-seq: + # delete?(number) -> integer or nil + # delete?(star) -> :* or nil + # delete?(range) -> sequence set or nil + # + # Removes a specified value from the set, and returns the removed value. + # Returns +nil+ if nothing was removed. + # + # Returns an integer when the specified +number+ argument was removed: + # set = Net::IMAP::SequenceSet.new [5..10, 20] + # set.delete?(7) #=> 7 + # set #=> # + # set.delete?("20") #=> 20 + # set #=> # + # set.delete?(30) #=> nil + # + # Returns :* when * or -1 is specified and + # removed: + # set = Net::IMAP::SequenceSet.new "5:9,20,35,*" + # set.delete?(-1) #=> :* + # set #=> # + # + # And returns a new SequenceSet when a range is specified: + # + # set = Net::IMAP::SequenceSet.new [5..10, 20] + # set.delete?(9..) #=> # + # set #=> # + # set.delete?(21..) #=> nil + # + # #string will be regenerated after deletion. + # + # Related: #delete, #delete_at, #subtract, #difference, #disjoint? + def delete?(element) + tuple = input_to_tuple element + if tuple.first == tuple.last + return unless include_tuple? tuple + tuple_subtract tuple + normalize! + from_tuple_int tuple.first + else + copy = dup + tuple_subtract tuple + normalize! + copy if copy.subtract(self).valid? + end + end + + # :call-seq: delete_at(index) -> number or :* or nil + # + # Deletes a number the set, indicated by the given +index+. Returns the + # number that was removed, or +nil+ if nothing was removed. + # + # #string will be regenerated after deletion. + # + # Related: #delete, #delete?, #slice!, #subtract, #difference + def delete_at(index) + slice! Integer(index.to_int) + end + + # :call-seq: + # slice!(index) -> integer or :* or nil + # slice!(start, length) -> sequence set or nil + # slice!(range) -> sequence set or nil + # + # Deletes a number or consecutive numbers from the set, indicated by the + # given +index+, +start+ and +length+, or +range+ of offsets. Returns the + # number or sequence set that was removed, or +nil+ if nothing was + # removed. Arguments are interpreted the same as for #slice or #[]. + # + # #string will be regenerated after deletion. + # + # Related: #slice, #delete_at, #delete, #delete?, #subtract, #difference + def slice!(index, length = nil) + deleted = slice(index, length) and subtract deleted + deleted + end + + # Merges all of the elements that appear in any of the +sets+ into the + # set, and returns +self+. + # + # The +sets+ may be any objects that would be accepted by ::new: non-zero + # 32 bit unsigned integers, ranges, sequence-set formatted + # strings, other sequence sets, or enumerables containing any of these. + # + # #string will be regenerated after all sets have been merged. + # + # Related: #add, #add?, #union + def merge(*sets) + tuples_add input_to_tuples sets + normalize! + end + + # Removes all of the elements that appear in any of the given +sets+ from + # the set, and returns +self+. + # + # The +sets+ may be any objects that would be accepted by ::new: non-zero + # 32 bit unsigned integers, ranges, sequence-set formatted + # strings, other sequence sets, or enumerables containing any of these. + # + # Related: #difference + def subtract(*sets) + tuples_subtract input_to_tuples sets + normalize! + end + + # Returns an array of ranges and integers and :*. + # + # The entries are in the same order they appear in #string, with no + # sorting, deduplication, or coalescing. When #string is in its + # normalized form, this will return the same result as #elements. + # This is useful when the given order is significant, for example in a + # ESEARCH response to IMAP#sort. + # + # Related: #each_entry, #elements + def entries; each_entry.to_a end + + # Returns an array of ranges and integers and :*. + # + # The returned elements are sorted and coalesced, even when the input + # #string is not. * will sort last. See #normalize. + # + # By itself, * translates to :*. A range containing + # * translates to an endless range. Use #limit to translate both + # cases to a maximum value. + # + # The returned elements will be sorted and coalesced, even when the input + # #string is not. * will sort last. See #normalize. + # + # Net::IMAP::SequenceSet["2,5:9,6,*,12:11"].elements + # #=> [2, 5..9, 11..12, :*] + # + # Related: #each_element, #ranges, #numbers + def elements; each_element.to_a end + alias to_a elements + + # Returns an array of ranges + # + # The returned elements are sorted and coalesced, even when the input + # #string is not. * will sort last. See #normalize. + # + # * translates to an endless range. By itself, * + # translates to :*... Use #limit to set * to a maximum + # value. + # + # The returned ranges will be sorted and coalesced, even when the input + # #string is not. * will sort last. See #normalize. + # + # Net::IMAP::SequenceSet["2,5:9,6,*,12:11"].ranges + # #=> [2..2, 5..9, 11..12, :*..] + # Net::IMAP::SequenceSet["123,999:*,456:789"].ranges + # #=> [123..123, 456..789, 999..] + # + # Related: #each_range, #elements, #numbers, #to_set + def ranges; each_range.to_a end + + # Returns a sorted array of all of the number values in the sequence set. + # + # The returned numbers are sorted and de-duplicated, even when the input + # #string is not. See #normalize. + # + # Net::IMAP::SequenceSet["2,5:9,6,12:11"].numbers + # #=> [2, 5, 6, 7, 8, 9, 11, 12] + # + # If the set contains a *, RangeError is raised. See #limit. + # + # Net::IMAP::SequenceSet["10000:*"].numbers + # #!> RangeError + # + # *WARNING:* Even excluding sets with *, an enormous result can + # easily be created. An array with over 4 billion integers could be + # returned, requiring up to 32GiB of memory on a 64-bit architecture. + # + # Net::IMAP::SequenceSet[10000..2**32-1].numbers + # # ...probably freezes the process for a while... + # #!> NoMemoryError (probably) + # + # For safety, consider using #limit or #intersection to set an upper + # bound. Alternatively, use #each_element, #each_range, or even + # #each_number to avoid allocation of a result array. + # + # Related: #elements, #ranges, #to_set + def numbers; each_number.to_a end + + # Yields each number or range in #string to the block and returns +self+. + # Returns an enumerator when called without a block. + # + # The entries are yielded in the same order they appear in #string, with + # no sorting, deduplication, or coalescing. When #string is in its + # normalized form, this will yield the same values as #each_element. + # + # Related: #entries, #each_element + def each_entry(&block) # :yields: integer or range or :* + return to_enum(__method__) unless block_given? + each_entry_tuple do yield tuple_to_entry _1 end + end + + # Yields each number or range (or :*) in #elements to the block + # and returns self. Returns an enumerator when called without a block. + # + # The returned numbers are sorted and de-duplicated, even when the input + # #string is not. See #normalize. + # + # Related: #elements, #each_entry + def each_element # :yields: integer or range or :* + return to_enum(__method__) unless block_given? + @tuples.each do yield tuple_to_entry _1 end + self + end + + private + + def each_entry_tuple(&block) + return to_enum(__method__) unless block_given? + if @string + @string.split(",") do block.call str_to_tuple _1 end + else + @tuples.each(&block) + end + self + end + + def tuple_to_entry((min, max)) + if min == STAR_INT then :* + elsif max == STAR_INT then min.. + elsif min == max then min + else min..max + end + end + + public + + # Yields each range in #ranges to the block and returns self. + # Returns an enumerator when called without a block. + # + # Related: #ranges + def each_range # :yields: range + return to_enum(__method__) unless block_given? + @tuples.each do |min, max| + if min == STAR_INT then yield :*.. + elsif max == STAR_INT then yield min.. + else yield min..max + end + end + self + end + + # Yields each number in #numbers to the block and returns self. + # If the set contains a *, RangeError will be raised. + # + # Returns an enumerator when called without a block (even if the set + # contains *). + # + # Related: #numbers, #each_ordered_number + def each_number(&block) # :yields: integer + return to_enum(__method__) unless block_given? + raise RangeError, '%s contains "*"' % [self.class] if include_star? + @tuples.each do each_number_in_tuple _1, _2, &block end + self + end + + # Yields each number in #entries to the block and returns self. + # If the set contains a *, RangeError will be raised. + # + # Returns an enumerator when called without a block (even if the set + # contains *). + # + # Related: #entries, #each_number + def each_ordered_number(&block) + return to_enum(__method__) unless block_given? + raise RangeError, '%s contains "*"' % [self.class] if include_star? + each_entry_tuple do each_number_in_tuple _1, _2, &block end + end + + private def each_number_in_tuple(min, max, &block) + if min == STAR_INT then yield :* + elsif min == max then yield min + elsif max != STAR_INT then (min..max).each(&block) + else + raise RangeError, "#{SequenceSet} cannot enumerate range with '*'" + end + end + + # Returns a Set with all of the #numbers in the sequence set. + # + # If the set contains a *, RangeError will be raised. + # + # See #numbers for the warning about very large sets. + # + # Related: #elements, #ranges, #numbers + def to_set; Set.new(numbers) end + + # Returns the count of #numbers in the set. + # + # * will be counted as 2**32 - 1 (the maximum 32-bit + # unsigned integer value). + # + # Related: #count_with_duplicates + def count + @tuples.sum(@tuples.count) { _2 - _1 } + + (include_star? && include?(UINT32_MAX) ? -1 : 0) + end + + alias size count + + # Returns the count of numbers in the ordered #entries, including any + # repeated numbers. + # + # * will be counted as 2**32 - 1 (the maximum 32-bit + # unsigned integer value). + # + # When #string is normalized, this behaves the same as #count. + # + # Related: #entries, #count_duplicates, #has_duplicates? + def count_with_duplicates + return count unless @string + each_entry_tuple.sum {|min, max| + max - min + ((max == STAR_INT && min != STAR_INT) ? 0 : 1) + } + end + + # Returns the count of repeated numbers in the ordered #entries, the + # difference between #count_with_duplicates and #count. + # + # When #string is normalized, this is zero. + # + # Related: #entries, #count_with_duplicates, #has_duplicates? + def count_duplicates + return 0 unless @string + count_with_duplicates - count + end + + # :call-seq: has_duplicates? -> true | false + # + # Returns whether or not the ordered #entries repeat any numbers. + # + # Always returns +false+ when #string is normalized. + # + # Related: #entries, #count_with_duplicates, #count_duplicates? + def has_duplicates? + return false unless @string + count_with_duplicates != count + end + + # Returns the (sorted and deduplicated) index of +number+ in the set, or + # +nil+ if +number+ isn't in the set. + # + # Related: #[], #at, #find_ordered_index + def find_index(number) + number = to_tuple_int number + each_tuple_with_index(@tuples) do |min, max, idx_min| + number < min and return nil + number <= max and return from_tuple_int(idx_min + (number - min)) + end + nil + end + + # Returns the first index of +number+ in the ordered #entries, or + # +nil+ if +number+ isn't in the set. + # + # Related: #find_index + def find_ordered_index(number) + number = to_tuple_int number + each_tuple_with_index(each_entry_tuple) do |min, max, idx_min| + if min <= number && number <= max + return from_tuple_int(idx_min + (number - min)) + end + end + nil + end + + private + + def each_tuple_with_index(tuples) + idx_min = 0 + tuples.each do |min, max| + idx_max = idx_min + (max - min) + yield min, max, idx_min, idx_max + idx_min = idx_max + 1 + end + idx_min + end + + def reverse_each_tuple_with_index(tuples) + idx_max = -1 + tuples.reverse_each do |min, max| + yield min, max, (idx_min = idx_max - (max - min)), idx_max + idx_max = idx_min - 1 + end + idx_max + end + + public + + # :call-seq: at(index) -> integer or nil + # + # Returns the number at the given +index+ in the sorted set, without + # modifying the set. + # + # +index+ is interpreted the same as in #[], except that #at only allows a + # single integer argument. + # + # Related: #[], #slice, #ordered_at + def at(index) + lookup_number_by_tuple_index(tuples, index) + end + + # :call-seq: ordered_at(index) -> integer or nil + # + # Returns the number at the given +index+ in the ordered #entries, without + # modifying the set. + # + # +index+ is interpreted the same as in #at (and #[]), except that + # #ordered_at applies to the ordered #entries, not the sorted set. + # + # Related: #[], #slice, #ordered_at + def ordered_at(index) + lookup_number_by_tuple_index(each_entry_tuple, index) + end + + private def lookup_number_by_tuple_index(tuples, index) + index = Integer(index.to_int) + if index.negative? + reverse_each_tuple_with_index(tuples) do |min, max, idx_min, idx_max| + idx_min <= index and return from_tuple_int(min + (index - idx_min)) + end + else + each_tuple_with_index(tuples) do |min, _, idx_min, idx_max| + index <= idx_max and return from_tuple_int(min + (index - idx_min)) + end + end + nil + end + + # :call-seq: + # seqset[index] -> integer or :* or nil + # slice(index) -> integer or :* or nil + # seqset[start, length] -> sequence set or nil + # slice(start, length) -> sequence set or nil + # seqset[range] -> sequence set or nil + # slice(range) -> sequence set or nil + # + # Returns a number or a subset from the _sorted_ set, without modifying + # the set. + # + # When an Integer argument +index+ is given, the number at offset +index+ + # in the sorted set is returned: + # + # set = Net::IMAP::SequenceSet["10:15,20:23,26"] + # set[0] #=> 10 + # set[5] #=> 15 + # set[10] #=> 26 + # + # If +index+ is negative, it counts relative to the end of the sorted set: + # set = Net::IMAP::SequenceSet["10:15,20:23,26"] + # set[-1] #=> 26 + # set[-3] #=> 22 + # set[-6] #=> 15 + # + # If +index+ is out of range, +nil+ is returned. + # + # set = Net::IMAP::SequenceSet["10:15,20:23,26"] + # set[11] #=> nil + # set[-12] #=> nil + # + # The result is based on the sorted and de-duplicated set, not on the + # ordered #entries in #string. + # + # set = Net::IMAP::SequenceSet["12,20:23,11:16,21"] + # set[0] #=> 11 + # set[-1] #=> 23 + # + # Related: #at + def [](index, length = nil) + if length then slice_length(index, length) + elsif index.is_a?(Range) then slice_range(index) + else at(index) + end + end + + alias slice :[] + + private + + def slice_length(start, length) + start = Integer(start.to_int) + length = Integer(length.to_int) + raise ArgumentError, "length must be positive" unless length.positive? + last = start + length - 1 unless start.negative? && start.abs <= length + slice_range(start..last) + end + + def slice_range(range) + first = range.begin || 0 + last = range.end || -1 + if range.exclude_end? + return remain_frozen_empty if last.zero? + last -= 1 if range.end && last != STAR_INT + end + if (first * last).positive? && last < first + remain_frozen_empty + elsif (min = at(first)) + max = at(last) + max = :* if max.nil? + if max == :* then self & (min..) + elsif min <= max then self & (min..max) + else remain_frozen_empty + end + end + end + + public + + # Returns a frozen SequenceSet with * converted to +max+, numbers + # and ranges over +max+ removed, and ranges containing +max+ converted to + # end at +max+. + # + # Net::IMAP::SequenceSet["5,10:22,50"].limit(max: 20).to_s + # #=> "5,10:20" + # + # * is always interpreted as the maximum value. When the set + # contains *, it will be set equal to the limit. + # + # Net::IMAP::SequenceSet["*"].limit(max: 37) + # #=> Net::IMAP::SequenceSet["37"] + # Net::IMAP::SequenceSet["5:*"].limit(max: 37) + # #=> Net::IMAP::SequenceSet["5:37"] + # Net::IMAP::SequenceSet["500:*"].limit(max: 37) + # #=> Net::IMAP::SequenceSet["37"] + # + def limit(max:) + max = to_tuple_int(max) + if empty? then self.class.empty + elsif !include_star? && max < min then self.class.empty + elsif max(star: STAR_INT) <= max then frozen? ? self : dup.freeze + else dup.limit!(max: max).freeze + end + end + + # Removes all members over +max+ and returns self. If * is a + # member, it will be converted to +max+. + # + # Related: #limit + def limit!(max:) + star = include_star? + max = to_tuple_int(max) + tuple_subtract [max + 1, STAR_INT] + tuple_add [max, max ] if star + normalize! + end + + # :call-seq: complement! -> self + # + # Converts the SequenceSet to its own #complement. It will contain all + # possible values _except_ for those currently in the set. + # + # Related: #complement + def complement! + return replace(self.class.full) if empty? + return clear if full? + flat = @tuples.flat_map { [_1 - 1, _2 + 1] } + if flat.first < 1 then flat.shift else flat.unshift 1 end + if STAR_INT < flat.last then flat.pop else flat.push STAR_INT end + @tuples = flat.each_slice(2).to_a + normalize! + end + + # Returns a new SequenceSet with a normalized string representation. + # + # The returned set's #string is sorted and deduplicated. Adjacent or + # overlapping elements will be merged into a single larger range. + # + # Net::IMAP::SequenceSet["1:5,3:7,10:9,10:11"].normalize + # #=> Net::IMAP::SequenceSet["1:7,9:11"] + # + # Related: #normalize!, #normalized_string + def normalize + str = normalized_string + return self if frozen? && str == string + remain_frozen dup.instance_exec { @string = str&.-@; self } + end + + # Resets #string to be sorted, deduplicated, and coalesced. Returns + # +self+. + # + # Related: #normalize, #normalized_string + def normalize! + @string = nil + self + end + + # Returns a normalized +sequence-set+ string representation, sorted + # and deduplicated. Adjacent or overlapping elements will be merged into + # a single larger range. Returns +nil+ when the set is empty. + # + # Net::IMAP::SequenceSet["1:5,3:7,10:9,10:11"].normalized_string + # #=> "1:7,9:11" + # + # Related: #normalize!, #normalize + def normalized_string + @tuples.empty? ? nil : -@tuples.map { tuple_to_str _1 }.join(",") + end + + def inspect + if empty? + (frozen? ? "%s.empty" : "#<%s empty>") % [self.class] + elsif frozen? + "%s[%p]" % [self.class, to_s] + else + "#<%s %p>" % [self.class, to_s] + end + end + + # Returns self + alias to_sequence_set itself + + # Unstable API: currently for internal use only (Net::IMAP#validate_data) + def validate # :nodoc: + empty? and raise DataFormatError, "empty sequence-set is invalid" + self + end + + # Unstable API: for internal use only (Net::IMAP#send_data) + def send_data(imap, tag) # :nodoc: + imap.__send__(:put_string, valid_string) + end + + protected + + attr_reader :tuples # :nodoc: + + private + + def remain_frozen(set) frozen? ? set.freeze : set end + def remain_frozen_empty; frozen? ? SequenceSet.empty : SequenceSet.new end + + # frozen clones are shallow copied + def initialize_clone(other) + other.frozen? ? super : initialize_dup(other) + end + + def initialize_dup(other) + @tuples = other.tuples.map(&:dup) + @string = other.string&.-@ + super + end + + def input_to_tuple(entry) + entry = input_try_convert entry + case entry + when *STARS, Integer then [int = to_tuple_int(entry), int] + when Range then range_to_tuple(entry) + when String then str_to_tuple(entry) + else + raise DataFormatError, "expected number or range, got %p" % [entry] + end + end + + def input_to_tuples(set) + set = input_try_convert set + case set + when *STARS, Integer, Range then [input_to_tuple(set)] + when String then str_to_tuples set + when SequenceSet then set.tuples + when ENUMABLE then set.flat_map { input_to_tuples _1 } + when nil then [] + else + raise DataFormatError, + "expected nz-number, range, string, or enumerable; " \ + "got %p" % [set] + end + end + + # unlike SequenceSet#try_convert, this returns an Integer, Range, + # String, Set, Array, or... any type of object. + def input_try_convert(input) + SequenceSet.try_convert(input) || + # Integer.try_convert(input) || # ruby 3.1+ + input.respond_to?(:to_int) && Integer(input.to_int) || + String.try_convert(input) || + input + end + + def range_to_tuple(range) + first = to_tuple_int(range.begin || 1) + last = to_tuple_int(range.end || :*) + last -= 1 if range.exclude_end? && range.end && last != STAR_INT + unless first <= last + raise DataFormatError, "invalid range for sequence-set: %p" % [range] + end + [first, last] + end + + def to_tuple_int(obj) STARS.include?(obj) ? STAR_INT : nz_number(obj) end + def from_tuple_int(num) num == STAR_INT ? :* : num end + + def tuple_to_str(tuple) tuple.uniq.map{ from_tuple_int _1 }.join(":") end + def str_to_tuples(str) str.split(",", -1).map! { str_to_tuple _1 } end + def str_to_tuple(str) + raise DataFormatError, "invalid sequence set string" if str.empty? + str.split(":", 2).map! { to_tuple_int _1 }.minmax + end + + def include_tuple?((min, max)) range_gte_to(min)&.cover?(min..max) end + + def intersect_tuple?((min, max)) + range = range_gte_to(min) and + range.include?(min) || range.include?(max) || (min..max).cover?(range) + end + + def modifying! + if frozen? + raise FrozenError, "can't modify frozen #{self.class}: %p" % [self] + end + end + + def tuples_add(tuples) tuples.each do tuple_add _1 end; self end + def tuples_subtract(tuples) tuples.each do tuple_subtract _1 end; self end + + # + # --|=====| |=====new tuple=====| append + # ?????????-|=====new tuple=====|-|===lower===|-- insert + # + # |=====new tuple=====| + # ---------??=======lower=======??--------------- noop + # + # ---------??===lower==|--|==| join remaining + # ---------??===lower==|--|==|----|===upper===|-- join until upper + # ---------??===lower==|--|==|--|=====upper===|-- join to upper + def tuple_add(tuple) + modifying! + min, max = tuple + lower, lower_idx = tuple_gte_with_index(min - 1) + if lower.nil? then tuples << [min, max] + elsif (max + 1) < lower.first then tuples.insert(lower_idx, [min, max]) + else tuple_coalesce(lower, lower_idx, min, max) + end + end + + def tuple_coalesce(lower, lower_idx, min, max) + return if lower.first <= min && max <= lower.last + lower[0] = [min, lower.first].min + lower[1] = [max, lower.last].max + lower_idx += 1 + return if lower_idx == tuples.count + tmax_adj = lower.last + 1 + upper, upper_idx = tuple_gte_with_index(tmax_adj) + if upper + tmax_adj < upper.first ? (upper_idx -= 1) : (lower[1] = upper.last) + end + tuples.slice!(lower_idx..upper_idx) + end + + # |====tuple================| + # --|====| no more 1. noop + # --|====|---------------------------|====lower====|-- 2. noop + # -------|======lower================|---------------- 3. split + # --------|=====lower================|---------------- 4. trim beginning + # + # -------|======lower====????????????----------------- trim lower + # --------|=====lower====????????????----------------- delete lower + # + # -------??=====lower===============|----------------- 5. trim/delete one + # -------??=====lower====|--|====| no more 6. delete rest + # -------??=====lower====|--|====|---|====upper====|-- 7. delete until + # -------??=====lower====|--|====|--|=====upper====|-- 8. delete and trim + def tuple_subtract(tuple) + modifying! + min, max = tuple + lower, idx = tuple_gte_with_index(min) + if lower.nil? then nil # case 1. + elsif max < lower.first then nil # case 2. + elsif max < lower.last then tuple_trim_or_split lower, idx, min, max + else tuples_trim_or_delete lower, idx, min, max + end + end + + def tuple_trim_or_split(lower, idx, tmin, tmax) + if lower.first < tmin # split + tuples.insert(idx, [lower.first, tmin - 1]) + end + lower[0] = tmax + 1 + end + + def tuples_trim_or_delete(lower, lower_idx, tmin, tmax) + if lower.first < tmin # trim lower + lower[1] = tmin - 1 + lower_idx += 1 + end + if tmax == lower.last # case 5 + upper_idx = lower_idx + elsif (upper, upper_idx = tuple_gte_with_index(tmax + 1)) + upper_idx -= 1 # cases 7 and 8 + upper[0] = tmax + 1 if upper.first <= tmax # case 8 (else case 7) + end + tuples.slice!(lower_idx..upper_idx) + end + + def tuple_gte_with_index(num) + idx = tuples.bsearch_index { _2 >= num } and [tuples[idx], idx] + end + + def range_gte_to(num) + first, last = tuples.bsearch { _2 >= num } + first..last if first + end + + def nz_number(num) + case num + when Integer, /\A[1-9]\d*\z/ then num = Integer(num) + else raise DataFormatError, "%p is not a valid nz-number" % [num] + end + NumValidator.ensure_nz_number(num) + num + end + + # intentionally defined after the class implementation + + EMPTY = new.freeze + FULL = self["1:*"] + private_constant :EMPTY, :FULL + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/nameprep.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/nameprep.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/nameprep.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/nameprep.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,70 @@ +# frozen_string_literal: true + +module Net + class IMAP + module StringPrep + + # Defined in RFC3491[https://tools.ietf.org/html/rfc3491], the +nameprep+ + # profile of "Stringprep" is: + # >>> + # used by the IDNA protocol for preparing domain names; it is not + # designed for any other purpose. It is explicitly not designed for + # processing arbitrary free text and SHOULD NOT be used for that + # purpose. + # + # ... + # + # This profile specifies prohibiting using the following tables...: + # + # - C.1.2 (Non-ASCII space characters) + # - C.2.2 (Non-ASCII control characters) + # - C.3 (Private use characters) + # - C.4 (Non-character code points) + # - C.5 (Surrogate codes) + # - C.6 (Inappropriate for plain text) + # - C.7 (Inappropriate for canonical representation) + # - C.8 (Change display properties are deprecated) + # - C.9 (Tagging characters) + # + # IMPORTANT NOTE: This profile MUST be used with the IDNA protocol. + # The IDNA protocol has additional prohibitions that are checked + # outside of this profile. + module NamePrep + + # From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §10 + STRINGPREP_PROFILE = "nameprep" + + # From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §2 + UNASSIGNED_TABLE = "A.1" + + # From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §3 + MAPPING_TABLES = %w[B.1 B.2].freeze + + # From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §4 + NORMALIZATION = :nfkc + + # From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §5 + PROHIBITED_TABLES = %w[C.1.2 C.2.2 C.3 C.4 C.5 C.6 C.7 C.8 C.9].freeze + + # From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §6 + CHECK_BIDI = true + + module_function + + def nameprep(string, **opts) + StringPrep.stringprep( + string, + unassigned: UNASSIGNED_TABLE, + maps: MAPPING_TABLES, + prohibited: PROHIBITED_TABLES, + normalization: NORMALIZATION, + bidi: CHECK_BIDI, + profile: STRINGPREP_PROFILE, + **opts, + ) + end + end + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/saslprep.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/saslprep.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/saslprep.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/saslprep.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,69 @@ +# frozen_string_literal: true + +module Net + class IMAP + module StringPrep + + # SASLprep#saslprep can be used to prepare a string according to [RFC4013]. + # + # \SASLprep maps characters three ways: to nothing, to space, and Unicode + # normalization form KC. \SASLprep prohibits codepoints from nearly all + # standard StringPrep tables (RFC3454, Appendix "C"), and uses + # \StringPrep's standard bidirectional characters requirements (Appendix + # "D"). \SASLprep also uses \StringPrep's definition of "Unassigned" + # codepoints (Appendix "A"). + module SASLprep + + # Used to short-circuit strings that don't need preparation. + ASCII_NO_CTRLS = /\A[\x20-\x7e]*\z/u.freeze + + # Avoid loading these tables unless they are needed (they are only + # needed for non-ASCII). + saslprep_tables = File.expand_path("saslprep_tables", __dir__) + autoload :MAP_TO_NOTHING, saslprep_tables + autoload :MAP_TO_SPACE, saslprep_tables + autoload :PROHIBITED, saslprep_tables + autoload :PROHIBITED_STORED, saslprep_tables + autoload :TABLES_PROHIBITED, saslprep_tables + autoload :TABLES_PROHIBITED_STORED, saslprep_tables + + module_function + + # Prepares a UTF-8 +string+ for comparison, using the \SASLprep profile + # RFC4013 of the StringPrep algorithm RFC3454. + # + # By default, prohibited strings will return +nil+. When +exception+ is + # +true+, a StringPrepError describing the violation will be raised. + # + # When +stored+ is +true+, "unassigned" codepoints will be prohibited. + # For \StringPrep and the \SASLprep profile, "unassigned" refers to + # Unicode 3.2, and not later versions. See RFC3454 §7 for more + # information. + def saslprep(str, stored: false, exception: false) + return str if ASCII_NO_CTRLS.match?(str) # incompatible encoding raises + str = str.encode("UTF-8") # also dups (and raises for invalid encoding) + str.gsub!(MAP_TO_SPACE, " ") + str.gsub!(MAP_TO_NOTHING, "") + str.unicode_normalize!(:nfkc) + # These regexps combine the prohibited and bidirectional checks + return str unless str.match?(stored ? PROHIBITED_STORED : PROHIBITED) + return nil unless exception + # raise helpful errors to indicate *why* it failed: + tables = stored ? TABLES_PROHIBITED_STORED : TABLES_PROHIBITED + StringPrep.check_prohibited! str, *tables, bidi: true, profile: "SASLprep" + raise InvalidStringError.new( + "unknown error", string: string, profile: "SASLprep" + ) + rescue ArgumentError, Encoding::CompatibilityError => ex + if /invalid byte sequence|incompatible encoding/.match? ex.message + return nil unless exception + raise StringPrepError.new(ex.message, string: str, profile: "saslprep") + end + raise ex + end + + end + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/saslprep_tables.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/saslprep_tables.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/saslprep_tables.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/saslprep_tables.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,96 @@ +# frozen_string_literal: true + +#-- +# This file is generated from RFC3454, by rake. Don't edit directly. +#++ + +module Net::IMAP::StringPrep + + module SASLprep + + # RFC4013 §2.1 Mapping - mapped to space + # >>> + # non-ASCII space characters (\StringPrep\[\"C.1.2\"]) that can + # be mapped to SPACE (U+0020) + # + # Equal to \StringPrep\[\"C.1.2\"]. + # Redefined here to avoid loading StringPrep::Tables unless necessary. + MAP_TO_SPACE = /[\u200b\p{Zs}&&[^ ]]/.freeze + + # RFC4013 §2.1 Mapping - mapped to nothing + # >>> + # the "commonly mapped to nothing" characters + # (\StringPrep\[\"B.1\"]) that can be mapped to nothing. + # + # Equal to \StringPrep\[\"B.1\"]. + # Redefined here to avoid loading StringPrep::Tables unless necessary. + MAP_TO_NOTHING = /[\u{00ad 034f 1806 2060 feff}\u{180b}-\u{180d}\u{200b}-\u{200d}\u{fe00}-\u{fe0f}]/.freeze + + # RFC4013 §2.3 Prohibited Output + # >>> + # * Non-ASCII space characters — \StringPrep\[\"C.1.2\"] + # * ASCII control characters — \StringPrep\[\"C.2.1\"] + # * Non-ASCII control characters — \StringPrep\[\"C.2.2\"] + # * Private Use characters — \StringPrep\[\"C.3\"] + # * Non-character code points — \StringPrep\[\"C.4\"] + # * Surrogate code points — \StringPrep\[\"C.5\"] + # * Inappropriate for plain text characters — \StringPrep\[\"C.6\"] + # * Inappropriate for canonical representation characters — \StringPrep\[\"C.7\"] + # * Change display properties or deprecated characters — \StringPrep\[\"C.8\"] + # * Tagging characters — \StringPrep\[\"C.9\"] + TABLES_PROHIBITED = ["C.1.2", "C.2.1", "C.2.2", "C.3", "C.4", "C.5", "C.6", "C.7", "C.8", "C.9"].freeze + + # Adds unassigned (by Unicode 3.2) codepoints to TABLES_PROHIBITED. + # + # RFC4013 §2.5 Unassigned Code Points + # >>> + # This profile specifies the \StringPrep\[\"A.1\"] table as its + # list of unassigned code points. + TABLES_PROHIBITED_STORED = ["A.1", *TABLES_PROHIBITED].freeze + + # A Regexp matching codepoints prohibited by RFC4013 §2.3. + # + # This combines all of the TABLES_PROHIBITED tables. + PROHIBITED_OUTPUT = /[\u{06dd 070f 1680 180e 3000 feff e0001}\u{0000}-\u{001f}\u{007f}-\u{00a0}\u{0340}-\u{0341}\u{2000}-\u{200f}\u{2028}-\u{202f}\u{205f}-\u{2063}\u{206a}-\u{206f}\u{2ff0}-\u{2ffb}\u{e000}-\u{f8ff}\u{fdd0}-\u{fdef}\u{fff9}-\u{ffff}\u{1d173}-\u{1d17a}\u{1fffe}-\u{1ffff}\u{2fffe}-\u{2ffff}\u{3fffe}-\u{3ffff}\u{4fffe}-\u{4ffff}\u{5fffe}-\u{5ffff}\u{6fffe}-\u{6ffff}\u{7fffe}-\u{7ffff}\u{8fffe}-\u{8ffff}\u{9fffe}-\u{9ffff}\u{afffe}-\u{affff}\u{bfffe}-\u{bffff}\u{cfffe}-\u{cffff}\u{dfffe}-\u{dffff}\u{e0020}-\u{e007f}\u{efffe}-\u{10ffff}\p{Cs}]/.freeze + + # RFC4013 §2.5 Unassigned Code Points + # >>> + # This profile specifies the \StringPrep\[\"A.1\"] table as its + # list of unassigned code points. + # + # Equal to \StringPrep\[\"A.1\"]. + # Redefined here to avoid loading StringPrep::Tables unless necessary. + UNASSIGNED = /\p{^AGE=3.2}/.freeze + + # A Regexp matching codepoints prohibited by RFC4013 §2.3 and §2.5. + # + # This combines PROHIBITED_OUTPUT and UNASSIGNED. + PROHIBITED_OUTPUT_STORED = Regexp.union( + UNASSIGNED, PROHIBITED_OUTPUT + ).freeze + + # Bidirectional Characters [StringPrep, §6] + # + # A Regexp for strings that don't satisfy StringPrep's Bidirectional + # Characters rules. + # + # Equal to StringPrep::Tables::BIDI_FAILURE. + # Redefined here to avoid loading StringPrep::Tables unless necessary. + BIDI_FAILURE = /(?-mix:(?m-ix:(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]))|(?m-ix:(?-mix:[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]).*?(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}])))|(?-mix:(?m-ix:\A(?-mix:[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]))|(?m-ix:(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}])\z))/.freeze + + # A Regexp matching strings prohibited by RFC4013 §2.3 and §2.4. + # + # This combines PROHIBITED_OUTPUT and BIDI_FAILURE. + PROHIBITED = Regexp.union( + PROHIBITED_OUTPUT, BIDI_FAILURE, + ) + + # A Regexp matching strings prohibited by RFC4013 §2.3, §2.4, and §2.5. + # + # This combines PROHIBITED_OUTPUT_STORED and BIDI_FAILURE. + PROHIBITED_STORED = Regexp.union( + PROHIBITED_OUTPUT_STORED, BIDI_FAILURE, + ) + + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/tables.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/tables.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/tables.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/tables.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,146 @@ +# frozen_string_literal: true + +#-- +# This file is generated from RFC3454, by rake. Don't edit directly. +#++ + +module Net::IMAP::StringPrep + + module Tables + + # Unassigned code points in Unicode 3.2 \StringPrep\[\"A.1\"] + IN_A_1 = /\p{^AGE=3.2}/.freeze + + # Commonly mapped to nothing \StringPrep\[\"B.1\"] + IN_B_1 = /[\u{00ad 034f 1806 2060 feff}\u{180b}-\u{180d}\u{200b}-\u{200d}\u{fe00}-\u{fe0f}]/.freeze + + # Mapping for case-folding used with NFKC \StringPrep\[\"B.2\"] + IN_B_2 = /[\u{00b5 0100 0102 0104 0106 0108 010a 010c 010e 0110 0112 0114 0116 0118 011a 011c 011e 0120 0122 0124 0126 0128 012a 012c 012e 0130 0132 0134 0136 0139 013b 013d 013f 0141 0143 0145 0147 014c 014e 0150 0152 0154 0156 0158 015a 015c 015e 0160 0162 0164 0166 0168 016a 016c 016e 0170 0172 0174 0176 017b 017d 017f 0184 01a2 01a4 01a9 01ac 01b5 01bc 01cd 01cf 01d1 01d3 01d5 01d7 01d9 01db 01de 01e0 01e2 01e4 01e6 01e8 01ea 01ec 01ee 01f4 01fa 01fc 01fe 0200 0202 0204 0206 0208 020a 020c 020e 0210 0212 0214 0216 0218 021a 021c 021e 0220 0222 0224 0226 0228 022a 022c 022e 0230 0232 0345 037a 0386 038c 03b0 03c2 03d8 03da 03dc 03de 03e0 03e2 03e4 03e6 03e8 03ea 03ec 03ee 0460 0462 0464 0466 0468 046a 046c 046e 0470 0472 0474 0476 0478 047a 047c 047e 0480 048a 048c 048e 0490 0492 0494 0496 0498 049a 049c 049e 04a0 04a2 04a4 04a6 04a8 04aa 04ac 04ae 04b0 04b2 04b4 04b6 04b8 04ba 04bc 04be 04c1 04c3 04c5 04c7 04c9 04cb 04cd 04d0 04d2 04d4 04d6 04d8 04da 04dc 04de 04e0 04e2 04e4 04e6 04e8 04ea 04ec 04ee 04f0 04f2 04f4 04f8 0500 0502 0504 0506 0508 050a 050c 050e 0587 1e00 1e02 1e04 1e06 1e08 1e0a 1e0c 1e0e 1e10 1e12 1e14 1e16 1e18 1e1a 1e1c 1e1e 1e20 1e22 1e24 1e26 1e28 1e2a 1e2c 1e2e 1e30 1e32 1e34 1e36 1e38 1e3a 1e3c 1e3e 1e40 1e42 1e44 1e46 1e48 1e4a 1e4c 1e4e 1e50 1e52 1e54 1e56 1e58 1e5a 1e5c 1e5e 1e60 1e62 1e64 1e66 1e68 1e6a 1e6c 1e6e 1e70 1e72 1e74 1e76 1e78 1e7a 1e7c 1e7e 1e80 1e82 1e84 1e86 1e88 1e8a 1e8c 1e8e 1e90 1e92 1e94 1ea0 1ea2 1ea4 1ea6 1ea8 1eaa 1eac 1eae 1eb0 1eb2 1eb4 1eb6 1eb8 1eba 1ebc 1ebe 1ec0 1ec2 1ec4 1ec6 1ec8 1eca 1ecc 1ece 1ed0 1ed2 1ed4 1ed6 1ed8 1eda 1edc 1ede 1ee0 1ee2 1ee4 1ee6 1ee8 1eea 1eec 1eee 1ef0 1ef2 1ef4 1ef6 1ef8 1f50 1f52 1f54 1f56 1f59 1f5b 1f5d 1f5f 1fbe 20a8 2107 2109 2124 2126 2128 2133 2145 3371 3373 3375 33c3 33cb 33d7 1d49c 1d4a2 1d546 1d6d3 1d70d 1d747 1d781 1d7bb}\u{0041}-\u{005a}\u{00c0}-\u{00d6}\u{00d8}-\u{00df}\u{0149}-\u{014a}\u{0178}-\u{0179}\u{0181}-\u{0182}\u{0186}-\u{0187}\u{0189}-\u{018b}\u{018e}-\u{0191}\u{0193}-\u{0194}\u{0196}-\u{0198}\u{019c}-\u{019d}\u{019f}-\u{01a0}\u{01a6}-\u{01a7}\u{01ae}-\u{01af}\u{01b1}-\u{01b3}\u{01b7}-\u{01b8}\u{01c4}-\u{01c5}\u{01c7}-\u{01c8}\u{01ca}-\u{01cb}\u{01f0}-\u{01f2}\u{01f6}-\u{01f8}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ab}\u{03d0}-\u{03d6}\u{03f0}-\u{03f2}\u{03f4}-\u{03f5}\u{0400}-\u{042f}\u{0531}-\u{0556}\u{1e96}-\u{1e9b}\u{1f08}-\u{1f0f}\u{1f18}-\u{1f1d}\u{1f28}-\u{1f2f}\u{1f38}-\u{1f3f}\u{1f48}-\u{1f4d}\u{1f68}-\u{1f6f}\u{1f80}-\u{1faf}\u{1fb2}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd2}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe2}-\u{1fe4}\u{1fe6}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{2102}-\u{2103}\u{210b}-\u{210d}\u{2110}-\u{2112}\u{2115}-\u{2116}\u{2119}-\u{211d}\u{2120}-\u{2122}\u{212a}-\u{212d}\u{2130}-\u{2131}\u{213e}-\u{213f}\u{2160}-\u{216f}\u{24b6}-\u{24cf}\u{3380}-\u{3387}\u{338a}-\u{338c}\u{3390}-\u{3394}\u{33a9}-\u{33ac}\u{33b4}-\u{33c1}\u{33c6}-\u{33c9}\u{33cd}-\u{33ce}\u{33d9}-\u{33da}\u{33dc}-\u{33dd}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{10400}-\u{10425}\u{1d400}-\u{1d419}\u{1d434}-\u{1d44d}\u{1d468}-\u{1d481}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b5}\u{1d4d0}-\u{1d4e9}\u{1d504}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d538}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d56c}-\u{1d585}\u{1d5a0}-\u{1d5b9}\u{1d5d4}-\u{1d5ed}\u{1d608}-\u{1d621}\u{1d63c}-\u{1d655}\u{1d670}-\u{1d689}\u{1d6a8}-\u{1d6c0}\u{1d6e2}-\u{1d6fa}\u{1d71c}-\u{1d734}\u{1d756}-\u{1d76e}\u{1d790}-\u{1d7a8}]/.freeze + + # Mapping for case-folding used with no normalization \StringPrep\[\"B.3\"] + IN_B_3 = /[\u{00b5 0100 0102 0104 0106 0108 010a 010c 010e 0110 0112 0114 0116 0118 011a 011c 011e 0120 0122 0124 0126 0128 012a 012c 012e 0130 0132 0134 0136 0139 013b 013d 013f 0141 0143 0145 0147 014c 014e 0150 0152 0154 0156 0158 015a 015c 015e 0160 0162 0164 0166 0168 016a 016c 016e 0170 0172 0174 0176 017b 017d 017f 0184 01a2 01a4 01a9 01ac 01b5 01bc 01cd 01cf 01d1 01d3 01d5 01d7 01d9 01db 01de 01e0 01e2 01e4 01e6 01e8 01ea 01ec 01ee 01f4 01fa 01fc 01fe 0200 0202 0204 0206 0208 020a 020c 020e 0210 0212 0214 0216 0218 021a 021c 021e 0220 0222 0224 0226 0228 022a 022c 022e 0230 0232 0345 0386 038c 03b0 03c2 03d8 03da 03dc 03de 03e0 03e2 03e4 03e6 03e8 03ea 03ec 03ee 0460 0462 0464 0466 0468 046a 046c 046e 0470 0472 0474 0476 0478 047a 047c 047e 0480 048a 048c 048e 0490 0492 0494 0496 0498 049a 049c 049e 04a0 04a2 04a4 04a6 04a8 04aa 04ac 04ae 04b0 04b2 04b4 04b6 04b8 04ba 04bc 04be 04c1 04c3 04c5 04c7 04c9 04cb 04cd 04d0 04d2 04d4 04d6 04d8 04da 04dc 04de 04e0 04e2 04e4 04e6 04e8 04ea 04ec 04ee 04f0 04f2 04f4 04f8 0500 0502 0504 0506 0508 050a 050c 050e 0587 1e00 1e02 1e04 1e06 1e08 1e0a 1e0c 1e0e 1e10 1e12 1e14 1e16 1e18 1e1a 1e1c 1e1e 1e20 1e22 1e24 1e26 1e28 1e2a 1e2c 1e2e 1e30 1e32 1e34 1e36 1e38 1e3a 1e3c 1e3e 1e40 1e42 1e44 1e46 1e48 1e4a 1e4c 1e4e 1e50 1e52 1e54 1e56 1e58 1e5a 1e5c 1e5e 1e60 1e62 1e64 1e66 1e68 1e6a 1e6c 1e6e 1e70 1e72 1e74 1e76 1e78 1e7a 1e7c 1e7e 1e80 1e82 1e84 1e86 1e88 1e8a 1e8c 1e8e 1e90 1e92 1e94 1ea0 1ea2 1ea4 1ea6 1ea8 1eaa 1eac 1eae 1eb0 1eb2 1eb4 1eb6 1eb8 1eba 1ebc 1ebe 1ec0 1ec2 1ec4 1ec6 1ec8 1eca 1ecc 1ece 1ed0 1ed2 1ed4 1ed6 1ed8 1eda 1edc 1ede 1ee0 1ee2 1ee4 1ee6 1ee8 1eea 1eec 1eee 1ef0 1ef2 1ef4 1ef6 1ef8 1f50 1f52 1f54 1f56 1f59 1f5b 1f5d 1f5f 1fbe 2126}\u{0041}-\u{005a}\u{00c0}-\u{00d6}\u{00d8}-\u{00df}\u{0149}-\u{014a}\u{0178}-\u{0179}\u{0181}-\u{0182}\u{0186}-\u{0187}\u{0189}-\u{018b}\u{018e}-\u{0191}\u{0193}-\u{0194}\u{0196}-\u{0198}\u{019c}-\u{019d}\u{019f}-\u{01a0}\u{01a6}-\u{01a7}\u{01ae}-\u{01af}\u{01b1}-\u{01b3}\u{01b7}-\u{01b8}\u{01c4}-\u{01c5}\u{01c7}-\u{01c8}\u{01ca}-\u{01cb}\u{01f0}-\u{01f2}\u{01f6}-\u{01f8}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ab}\u{03d0}-\u{03d1}\u{03d5}-\u{03d6}\u{03f0}-\u{03f2}\u{03f4}-\u{03f5}\u{0400}-\u{042f}\u{0531}-\u{0556}\u{1e96}-\u{1e9b}\u{1f08}-\u{1f0f}\u{1f18}-\u{1f1d}\u{1f28}-\u{1f2f}\u{1f38}-\u{1f3f}\u{1f48}-\u{1f4d}\u{1f68}-\u{1f6f}\u{1f80}-\u{1faf}\u{1fb2}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd2}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe2}-\u{1fe4}\u{1fe6}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{212a}-\u{212b}\u{2160}-\u{216f}\u{24b6}-\u{24cf}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{10400}-\u{10425}]/.freeze + + # Replacements for IN_B.1 + MAP_B_1 = "".freeze + + # Replacements for IN_B.2 + MAP_B_2 = {"A"=>"a", "B"=>"b", "C"=>"c", "D"=>"d", "E"=>"e", "F"=>"f", "G"=>"g", "H"=>"h", "I"=>"i", "J"=>"j", "K"=>"k", "L"=>"l", "M"=>"m", "N"=>"n", "O"=>"o", "P"=>"p", "Q"=>"q", "R"=>"r", "S"=>"s", "T"=>"t", "U"=>"u", "V"=>"v", "W"=>"w", "X"=>"x", "Y"=>"y", "Z"=>"z", "µ"=>"μ", "À"=>"à", "Á"=>"á", "Â"=>"â", "Ã"=>"ã", "Ä"=>"ä", "Å"=>"å", "Æ"=>"æ", "Ç"=>"ç", "È"=>"è", "É"=>"é", "Ê"=>"ê", "Ë"=>"ë", "Ì"=>"ì", "Í"=>"í", "Î"=>"î", "Ï"=>"ï", "Ð"=>"ð", "Ñ"=>"ñ", "Ò"=>"ò", "Ó"=>"ó", "Ô"=>"ô", "Õ"=>"õ", "Ö"=>"ö", "Ø"=>"ø", "Ù"=>"ù", "Ú"=>"ú", "Û"=>"û", "Ü"=>"ü", "Ý"=>"ý", "Þ"=>"þ", "ß"=>"ss", "Ā"=>"ā", "Ă"=>"ă", "Ą"=>"ą", "Ć"=>"ć", "Ĉ"=>"ĉ", "Ċ"=>"ċ", "Č"=>"č", "Ď"=>"ď", "Đ"=>"đ", "Ē"=>"ē", "Ĕ"=>"ĕ", "Ė"=>"ė", "Ę"=>"ę", "Ě"=>"ě", "Ĝ"=>"ĝ", "Ğ"=>"ğ", "Ġ"=>"ġ", "Ģ"=>"ģ", "Ĥ"=>"ĥ", "Ħ"=>"ħ", "Ĩ"=>"ĩ", "Ī"=>"ī", "Ĭ"=>"ĭ", "Į"=>"į", "İ"=>"i̇", "IJ"=>"ij", "Ĵ"=>"ĵ", "Ķ"=>"ķ", "Ĺ"=>"ĺ", "Ļ"=>"ļ", "Ľ"=>"ľ", "Ŀ"=>"ŀ", "Ł"=>"ł", "Ń"=>"ń", "Ņ"=>"ņ", "Ň"=>"ň", "ʼn"=>"ʼn", "Ŋ"=>"ŋ", "Ō"=>"ō", "Ŏ"=>"ŏ", "Ő"=>"ő", "Œ"=>"œ", "Ŕ"=>"ŕ", "Ŗ"=>"ŗ", "Ř"=>"ř", "Ś"=>"ś", "Ŝ"=>"ŝ", "Ş"=>"ş", "Š"=>"š", "Ţ"=>"ţ", "Ť"=>"ť", "Ŧ"=>"ŧ", "Ũ"=>"ũ", "Ū"=>"ū", "Ŭ"=>"ŭ", "Ů"=>"ů", "Ű"=>"ű", "Ų"=>"ų", "Ŵ"=>"ŵ", "Ŷ"=>"ŷ", "Ÿ"=>"ÿ", "Ź"=>"ź", "Ż"=>"ż", "Ž"=>"ž", "ſ"=>"s", "Ɓ"=>"ɓ", "Ƃ"=>"ƃ", "Ƅ"=>"ƅ", "Ɔ"=>"ɔ", "Ƈ"=>"ƈ", "Ɖ"=>"ɖ", "Ɗ"=>"ɗ", "Ƌ"=>"ƌ", "Ǝ"=>"ǝ", "Ə"=>"ə", "Ɛ"=>"ɛ", "Ƒ"=>"ƒ", "Ɠ"=>"ɠ", "Ɣ"=>"ɣ", "Ɩ"=>"ɩ", "Ɨ"=>"ɨ", "Ƙ"=>"ƙ", "Ɯ"=>"ɯ", "Ɲ"=>"ɲ", "Ɵ"=>"ɵ", "Ơ"=>"ơ", "Ƣ"=>"ƣ", "Ƥ"=>"ƥ", "Ʀ"=>"ʀ", "Ƨ"=>"ƨ", "Ʃ"=>"ʃ", "Ƭ"=>"ƭ", "Ʈ"=>"ʈ", "Ư"=>"ư", "Ʊ"=>"ʊ", "Ʋ"=>"ʋ", "Ƴ"=>"ƴ", "Ƶ"=>"ƶ", "Ʒ"=>"ʒ", "Ƹ"=>"ƹ", "Ƽ"=>"ƽ", "DŽ"=>"dž", "Dž"=>"dž", "LJ"=>"lj", "Lj"=>"lj", "NJ"=>"nj", "Nj"=>"nj", "Ǎ"=>"ǎ", "Ǐ"=>"ǐ", "Ǒ"=>"ǒ", "Ǔ"=>"ǔ", "Ǖ"=>"ǖ", "Ǘ"=>"ǘ", "Ǚ"=>"ǚ", "Ǜ"=>"ǜ", "Ǟ"=>"ǟ", "Ǡ"=>"ǡ", "Ǣ"=>"ǣ", "Ǥ"=>"ǥ", "Ǧ"=>"ǧ", "Ǩ"=>"ǩ", "Ǫ"=>"ǫ", "Ǭ"=>"ǭ", "Ǯ"=>"ǯ", "ǰ"=>"ǰ", "DZ"=>"dz", "Dz"=>"dz", "Ǵ"=>"ǵ", "Ƕ"=>"ƕ", "Ƿ"=>"ƿ", "Ǹ"=>"ǹ", "Ǻ"=>"ǻ", "Ǽ"=>"ǽ", "Ǿ"=>"ǿ", "Ȁ"=>"ȁ", "Ȃ"=>"ȃ", "Ȅ"=>"ȅ", "Ȇ"=>"ȇ", "Ȉ"=>"ȉ", "Ȋ"=>"ȋ", "Ȍ"=>"ȍ", "Ȏ"=>"ȏ", "Ȑ"=>"ȑ", "Ȓ"=>"ȓ", "Ȕ"=>"ȕ", "Ȗ"=>"ȗ", "Ș"=>"ș", "Ț"=>"ț", "Ȝ"=>"ȝ", "Ȟ"=>"ȟ", "Ƞ"=>"ƞ", "Ȣ"=>"ȣ", "Ȥ"=>"ȥ", "Ȧ"=>"ȧ", "Ȩ"=>"ȩ", "Ȫ"=>"ȫ", "Ȭ"=>"ȭ", "Ȯ"=>"ȯ", "Ȱ"=>"ȱ", "Ȳ"=>"ȳ", "ͅ"=>"ι", "ͺ"=>" ι", "Ά"=>"ά", "Έ"=>"έ", "Ή"=>"ή", "Ί"=>"ί", "Ό"=>"ό", "Ύ"=>"ύ", "Ώ"=>"ώ", "ΐ"=>"ΐ", "Α"=>"α", "Β"=>"β", "Γ"=>"γ", "Δ"=>"δ", "Ε"=>"ε", "Ζ"=>"ζ", "Η"=>"η", "Θ"=>"θ", "Ι"=>"ι", "Κ"=>"κ", "Λ"=>"λ", "Μ"=>"μ", "Ν"=>"ν", "Ξ"=>"ξ", "Ο"=>"ο", "Π"=>"π", "Ρ"=>"ρ", "Σ"=>"σ", "Τ"=>"τ", "Υ"=>"υ", "Φ"=>"φ", "Χ"=>"χ", "Ψ"=>"ψ", "Ω"=>"ω", "Ϊ"=>"ϊ", "Ϋ"=>"ϋ", "ΰ"=>"ΰ", "ς"=>"σ", "ϐ"=>"β", "ϑ"=>"θ", "ϒ"=>"υ", "ϓ"=>"ύ", "ϔ"=>"ϋ", "ϕ"=>"φ", "ϖ"=>"π", "Ϙ"=>"ϙ", "Ϛ"=>"ϛ", "Ϝ"=>"ϝ", "Ϟ"=>"ϟ", "Ϡ"=>"ϡ", "Ϣ"=>"ϣ", "Ϥ"=>"ϥ", "Ϧ"=>"ϧ", "Ϩ"=>"ϩ", "Ϫ"=>"ϫ", "Ϭ"=>"ϭ", "Ϯ"=>"ϯ", "ϰ"=>"κ", "ϱ"=>"ρ", "ϲ"=>"σ", "ϴ"=>"θ", "ϵ"=>"ε", "Ѐ"=>"ѐ", "Ё"=>"ё", "Ђ"=>"ђ", "Ѓ"=>"ѓ", "Є"=>"є", "Ѕ"=>"ѕ", "І"=>"і", "Ї"=>"ї", "Ј"=>"ј", "Љ"=>"љ", "Њ"=>"њ", "Ћ"=>"ћ", "Ќ"=>"ќ", "Ѝ"=>"ѝ", "Ў"=>"ў", "Џ"=>"џ", "А"=>"а", "Б"=>"б", "В"=>"в", "Г"=>"г", "Д"=>"д", "Е"=>"е", "Ж"=>"ж", "З"=>"з", "И"=>"и", "Й"=>"й", "К"=>"к", "Л"=>"л", "М"=>"м", "Н"=>"н", "О"=>"о", "П"=>"п", "Р"=>"р", "С"=>"с", "Т"=>"т", "У"=>"у", "Ф"=>"ф", "Х"=>"х", "Ц"=>"ц", "Ч"=>"ч", "Ш"=>"ш", "Щ"=>"щ", "Ъ"=>"ъ", "Ы"=>"ы", "Ь"=>"ь", "Э"=>"э", "Ю"=>"ю", "Я"=>"я", "Ѡ"=>"ѡ", "Ѣ"=>"ѣ", "Ѥ"=>"ѥ", "Ѧ"=>"ѧ", "Ѩ"=>"ѩ", "Ѫ"=>"ѫ", "Ѭ"=>"ѭ", "Ѯ"=>"ѯ", "Ѱ"=>"ѱ", "Ѳ"=>"ѳ", "Ѵ"=>"ѵ", "Ѷ"=>"ѷ", "Ѹ"=>"ѹ", "Ѻ"=>"ѻ", "Ѽ"=>"ѽ", "Ѿ"=>"ѿ", "Ҁ"=>"ҁ", "Ҋ"=>"ҋ", "Ҍ"=>"ҍ", "Ҏ"=>"ҏ", "Ґ"=>"ґ", "Ғ"=>"ғ", "Ҕ"=>"ҕ", "Җ"=>"җ", "Ҙ"=>"ҙ", "Қ"=>"қ", "Ҝ"=>"ҝ", "Ҟ"=>"ҟ", "Ҡ"=>"ҡ", "Ң"=>"ң", "Ҥ"=>"ҥ", "Ҧ"=>"ҧ", "Ҩ"=>"ҩ", "Ҫ"=>"ҫ", "Ҭ"=>"ҭ", "Ү"=>"ү", "Ұ"=>"ұ", "Ҳ"=>"ҳ", "Ҵ"=>"ҵ", "Ҷ"=>"ҷ", "Ҹ"=>"ҹ", "Һ"=>"һ", "Ҽ"=>"ҽ", "Ҿ"=>"ҿ", "Ӂ"=>"ӂ", "Ӄ"=>"ӄ", "Ӆ"=>"ӆ", "Ӈ"=>"ӈ", "Ӊ"=>"ӊ", "Ӌ"=>"ӌ", "Ӎ"=>"ӎ", "Ӑ"=>"ӑ", "Ӓ"=>"ӓ", "Ӕ"=>"ӕ", "Ӗ"=>"ӗ", "Ә"=>"ә", "Ӛ"=>"ӛ", "Ӝ"=>"ӝ", "Ӟ"=>"ӟ", "Ӡ"=>"ӡ", "Ӣ"=>"ӣ", "Ӥ"=>"ӥ", "Ӧ"=>"ӧ", "Ө"=>"ө", "Ӫ"=>"ӫ", "Ӭ"=>"ӭ", "Ӯ"=>"ӯ", "Ӱ"=>"ӱ", "Ӳ"=>"ӳ", "Ӵ"=>"ӵ", "Ӹ"=>"ӹ", "Ԁ"=>"ԁ", "Ԃ"=>"ԃ", "Ԅ"=>"ԅ", "Ԇ"=>"ԇ", "Ԉ"=>"ԉ", "Ԋ"=>"ԋ", "Ԍ"=>"ԍ", "Ԏ"=>"ԏ", "Ա"=>"ա", "Բ"=>"բ", "Գ"=>"գ", "Դ"=>"դ", "Ե"=>"ե", "Զ"=>"զ", "Է"=>"է", "Ը"=>"ը", "Թ"=>"թ", "Ժ"=>"ժ", "Ի"=>"ի", "Լ"=>"լ", "Խ"=>"խ", "Ծ"=>"ծ", "Կ"=>"կ", "Հ"=>"հ", "Ձ"=>"ձ", "Ղ"=>"ղ", "Ճ"=>"ճ", "Մ"=>"մ", "Յ"=>"յ", "Ն"=>"ն", "Շ"=>"շ", "Ո"=>"ո", "Չ"=>"չ", "Պ"=>"պ", "Ջ"=>"ջ", "Ռ"=>"ռ", "Ս"=>"ս", "Վ"=>"վ", "Տ"=>"տ", "Ր"=>"ր", "Ց"=>"ց", "Ւ"=>"ւ", "Փ"=>"փ", "Ք"=>"ք", "Օ"=>"օ", "Ֆ"=>"ֆ", "և"=>"եւ", "Ḁ"=>"ḁ", "Ḃ"=>"ḃ", "Ḅ"=>"ḅ", "Ḇ"=>"ḇ", "Ḉ"=>"ḉ", "Ḋ"=>"ḋ", "Ḍ"=>"ḍ", "Ḏ"=>"ḏ", "Ḑ"=>"ḑ", "Ḓ"=>"ḓ", "Ḕ"=>"ḕ", "Ḗ"=>"ḗ", "Ḙ"=>"ḙ", "Ḛ"=>"ḛ", "Ḝ"=>"ḝ", "Ḟ"=>"ḟ", "Ḡ"=>"ḡ", "Ḣ"=>"ḣ", "Ḥ"=>"ḥ", "Ḧ"=>"ḧ", "Ḩ"=>"ḩ", "Ḫ"=>"ḫ", "Ḭ"=>"ḭ", "Ḯ"=>"ḯ", "Ḱ"=>"ḱ", "Ḳ"=>"ḳ", "Ḵ"=>"ḵ", "Ḷ"=>"ḷ", "Ḹ"=>"ḹ", "Ḻ"=>"ḻ", "Ḽ"=>"ḽ", "Ḿ"=>"ḿ", "Ṁ"=>"ṁ", "Ṃ"=>"ṃ", "Ṅ"=>"ṅ", "Ṇ"=>"ṇ", "Ṉ"=>"ṉ", "Ṋ"=>"ṋ", "Ṍ"=>"ṍ", "Ṏ"=>"ṏ", "Ṑ"=>"ṑ", "Ṓ"=>"ṓ", "Ṕ"=>"ṕ", "Ṗ"=>"ṗ", "Ṙ"=>"ṙ", "Ṛ"=>"ṛ", "Ṝ"=>"ṝ", "Ṟ"=>"ṟ", "Ṡ"=>"ṡ", "Ṣ"=>"ṣ", "Ṥ"=>"ṥ", "Ṧ"=>"ṧ", "Ṩ"=>"ṩ", "Ṫ"=>"ṫ", "Ṭ"=>"ṭ", "Ṯ"=>"ṯ", "Ṱ"=>"ṱ", "Ṳ"=>"ṳ", "Ṵ"=>"ṵ", "Ṷ"=>"ṷ", "Ṹ"=>"ṹ", "Ṻ"=>"ṻ", "Ṽ"=>"ṽ", "Ṿ"=>"ṿ", "Ẁ"=>"ẁ", "Ẃ"=>"ẃ", "Ẅ"=>"ẅ", "Ẇ"=>"ẇ", "Ẉ"=>"ẉ", "Ẋ"=>"ẋ", "Ẍ"=>"ẍ", "Ẏ"=>"ẏ", "Ẑ"=>"ẑ", "Ẓ"=>"ẓ", "Ẕ"=>"ẕ", "ẖ"=>"ẖ", "ẗ"=>"ẗ", "ẘ"=>"ẘ", "ẙ"=>"ẙ", "ẚ"=>"aʾ", "ẛ"=>"ṡ", "Ạ"=>"ạ", "Ả"=>"ả", "Ấ"=>"ấ", "Ầ"=>"ầ", "Ẩ"=>"ẩ", "Ẫ"=>"ẫ", "Ậ"=>"ậ", "Ắ"=>"ắ", "Ằ"=>"ằ", "Ẳ"=>"ẳ", "Ẵ"=>"ẵ", "Ặ"=>"ặ", "Ẹ"=>"ẹ", "Ẻ"=>"ẻ", "Ẽ"=>"ẽ", "Ế"=>"ế", "Ề"=>"ề", "Ể"=>"ể", "Ễ"=>"ễ", "Ệ"=>"ệ", "Ỉ"=>"ỉ", "Ị"=>"ị", "Ọ"=>"ọ", "Ỏ"=>"ỏ", "Ố"=>"ố", "Ồ"=>"ồ", "Ổ"=>"ổ", "Ỗ"=>"ỗ", "Ộ"=>"ộ", "Ớ"=>"ớ", "Ờ"=>"ờ", "Ở"=>"ở", "Ỡ"=>"ỡ", "Ợ"=>"ợ", "Ụ"=>"ụ", "Ủ"=>"ủ", "Ứ"=>"ứ", "Ừ"=>"ừ", "Ử"=>"ử", "Ữ"=>"ữ", "Ự"=>"ự", "Ỳ"=>"ỳ", "Ỵ"=>"ỵ", "Ỷ"=>"ỷ", "Ỹ"=>"ỹ", "Ἀ"=>"ἀ", "Ἁ"=>"ἁ", "Ἂ"=>"ἂ", "Ἃ"=>"ἃ", "Ἄ"=>"ἄ", "Ἅ"=>"ἅ", "Ἆ"=>"ἆ", "Ἇ"=>"ἇ", "Ἐ"=>"ἐ", "Ἑ"=>"ἑ", "Ἒ"=>"ἒ", "Ἓ"=>"ἓ", "Ἔ"=>"ἔ", "Ἕ"=>"ἕ", "Ἠ"=>"ἠ", "Ἡ"=>"ἡ", "Ἢ"=>"ἢ", "Ἣ"=>"ἣ", "Ἤ"=>"ἤ", "Ἥ"=>"ἥ", "Ἦ"=>"ἦ", "Ἧ"=>"ἧ", "Ἰ"=>"ἰ", "Ἱ"=>"ἱ", "Ἲ"=>"ἲ", "Ἳ"=>"ἳ", "Ἴ"=>"ἴ", "Ἵ"=>"ἵ", "Ἶ"=>"ἶ", "Ἷ"=>"ἷ", "Ὀ"=>"ὀ", "Ὁ"=>"ὁ", "Ὂ"=>"ὂ", "Ὃ"=>"ὃ", "Ὄ"=>"ὄ", "Ὅ"=>"ὅ", "ὐ"=>"ὐ", "ὒ"=>"ὒ", "ὔ"=>"ὔ", "ὖ"=>"ὖ", "Ὑ"=>"ὑ", "Ὓ"=>"ὓ", "Ὕ"=>"ὕ", "Ὗ"=>"ὗ", "Ὠ"=>"ὠ", "Ὡ"=>"ὡ", "Ὢ"=>"ὢ", "Ὣ"=>"ὣ", "Ὤ"=>"ὤ", "Ὥ"=>"ὥ", "Ὦ"=>"ὦ", "Ὧ"=>"ὧ", "ᾀ"=>"ἀι", "ᾁ"=>"ἁι", "ᾂ"=>"ἂι", "ᾃ"=>"ἃι", "ᾄ"=>"ἄι", "ᾅ"=>"ἅι", "ᾆ"=>"ἆι", "ᾇ"=>"ἇι", "ᾈ"=>"ἀι", "ᾉ"=>"ἁι", "ᾊ"=>"ἂι", "ᾋ"=>"ἃι", "ᾌ"=>"ἄι", "ᾍ"=>"ἅι", "ᾎ"=>"ἆι", "ᾏ"=>"ἇι", "ᾐ"=>"ἠι", "ᾑ"=>"ἡι", "ᾒ"=>"ἢι", "ᾓ"=>"ἣι", "ᾔ"=>"ἤι", "ᾕ"=>"ἥι", "ᾖ"=>"ἦι", "ᾗ"=>"ἧι", "ᾘ"=>"ἠι", "ᾙ"=>"ἡι", "ᾚ"=>"ἢι", "ᾛ"=>"ἣι", "ᾜ"=>"ἤι", "ᾝ"=>"ἥι", "ᾞ"=>"ἦι", "ᾟ"=>"ἧι", "ᾠ"=>"ὠι", "ᾡ"=>"ὡι", "ᾢ"=>"ὢι", "ᾣ"=>"ὣι", "ᾤ"=>"ὤι", "ᾥ"=>"ὥι", "ᾦ"=>"ὦι", "ᾧ"=>"ὧι", "ᾨ"=>"ὠι", "ᾩ"=>"ὡι", "ᾪ"=>"ὢι", "ᾫ"=>"ὣι", "ᾬ"=>"ὤι", "ᾭ"=>"ὥι", "ᾮ"=>"ὦι", "ᾯ"=>"ὧι", "ᾲ"=>"ὰι", "ᾳ"=>"αι", "ᾴ"=>"άι", "ᾶ"=>"ᾶ", "ᾷ"=>"ᾶι", "Ᾰ"=>"ᾰ", "Ᾱ"=>"ᾱ", "Ὰ"=>"ὰ", "Ά"=>"ά", "ᾼ"=>"αι", "ι"=>"ι", "ῂ"=>"ὴι", "ῃ"=>"ηι", "ῄ"=>"ήι", "ῆ"=>"ῆ", "ῇ"=>"ῆι", "Ὲ"=>"ὲ", "Έ"=>"έ", "Ὴ"=>"ὴ", "Ή"=>"ή", "ῌ"=>"ηι", "ῒ"=>"ῒ", "ΐ"=>"ΐ", "ῖ"=>"ῖ", "ῗ"=>"ῗ", "Ῐ"=>"ῐ", "Ῑ"=>"ῑ", "Ὶ"=>"ὶ", "Ί"=>"ί", "ῢ"=>"ῢ", "ΰ"=>"ΰ", "ῤ"=>"ῤ", "ῦ"=>"ῦ", "ῧ"=>"ῧ", "Ῠ"=>"ῠ", "Ῡ"=>"ῡ", "Ὺ"=>"ὺ", "Ύ"=>"ύ", "Ῥ"=>"ῥ", "ῲ"=>"ὼι", "ῳ"=>"ωι", "ῴ"=>"ώι", "ῶ"=>"ῶ", "ῷ"=>"ῶι", "Ὸ"=>"ὸ", "Ό"=>"ό", "Ὼ"=>"ὼ", "Ώ"=>"ώ", "ῼ"=>"ωι", "₨"=>"rs", "ℂ"=>"c", "℃"=>"°c", "ℇ"=>"ɛ", "℉"=>"°f", "ℋ"=>"h", "ℌ"=>"h", "ℍ"=>"h", "ℐ"=>"i", "ℑ"=>"i", "ℒ"=>"l", "ℕ"=>"n", "№"=>"no", "ℙ"=>"p", "ℚ"=>"q", "ℛ"=>"r", "ℜ"=>"r", "ℝ"=>"r", "℠"=>"sm", "℡"=>"tel", "™"=>"tm", "ℤ"=>"z", "Ω"=>"ω", "ℨ"=>"z", "K"=>"k", "Å"=>"å", "ℬ"=>"b", "ℭ"=>"c", "ℰ"=>"e", "ℱ"=>"f", "ℳ"=>"m", "ℾ"=>"γ", "ℿ"=>"π", "ⅅ"=>"d", "Ⅰ"=>"ⅰ", "Ⅱ"=>"ⅱ", "Ⅲ"=>"ⅲ", "Ⅳ"=>"ⅳ", "Ⅴ"=>"ⅴ", "Ⅵ"=>"ⅵ", "Ⅶ"=>"ⅶ", "Ⅷ"=>"ⅷ", "Ⅸ"=>"ⅸ", "Ⅹ"=>"ⅹ", "Ⅺ"=>"ⅺ", "Ⅻ"=>"ⅻ", "Ⅼ"=>"ⅼ", "Ⅽ"=>"ⅽ", "Ⅾ"=>"ⅾ", "Ⅿ"=>"ⅿ", "Ⓐ"=>"ⓐ", "Ⓑ"=>"ⓑ", "Ⓒ"=>"ⓒ", "Ⓓ"=>"ⓓ", "Ⓔ"=>"ⓔ", "Ⓕ"=>"ⓕ", "Ⓖ"=>"ⓖ", "Ⓗ"=>"ⓗ", "Ⓘ"=>"ⓘ", "Ⓙ"=>"ⓙ", "Ⓚ"=>"ⓚ", "Ⓛ"=>"ⓛ", "Ⓜ"=>"ⓜ", "Ⓝ"=>"ⓝ", "Ⓞ"=>"ⓞ", "Ⓟ"=>"ⓟ", "Ⓠ"=>"ⓠ", "Ⓡ"=>"ⓡ", "Ⓢ"=>"ⓢ", "Ⓣ"=>"ⓣ", "Ⓤ"=>"ⓤ", "Ⓥ"=>"ⓥ", "Ⓦ"=>"ⓦ", "Ⓧ"=>"ⓧ", "Ⓨ"=>"ⓨ", "Ⓩ"=>"ⓩ", "㍱"=>"hpa", "㍳"=>"au", "㍵"=>"ov", "㎀"=>"pa", "㎁"=>"na", "㎂"=>"μa", "㎃"=>"ma", "㎄"=>"ka", "㎅"=>"kb", "㎆"=>"mb", "㎇"=>"gb", "㎊"=>"pf", "㎋"=>"nf", "㎌"=>"μf", "㎐"=>"hz", "㎑"=>"khz", "㎒"=>"mhz", "㎓"=>"ghz", "㎔"=>"thz", "㎩"=>"pa", "㎪"=>"kpa", "㎫"=>"mpa", "㎬"=>"gpa", "㎴"=>"pv", "㎵"=>"nv", "㎶"=>"μv", "㎷"=>"mv", "㎸"=>"kv", "㎹"=>"mv", "㎺"=>"pw", "㎻"=>"nw", "㎼"=>"μw", "㎽"=>"mw", "㎾"=>"kw", "㎿"=>"mw", "㏀"=>"kω", "㏁"=>"mω", "㏃"=>"bq", "㏆"=>"c∕kg", "㏇"=>"co.", "㏈"=>"db", "㏉"=>"gy", "㏋"=>"hp", "㏍"=>"kk", "㏎"=>"km", "㏗"=>"ph", "㏙"=>"ppm", "㏚"=>"pr", "㏜"=>"sv", "㏝"=>"wb", "ff"=>"ff", "fi"=>"fi", "fl"=>"fl", "ffi"=>"ffi", "ffl"=>"ffl", "ſt"=>"st", "st"=>"st", "ﬓ"=>"մն", "ﬔ"=>"մե", "ﬕ"=>"մի", "ﬖ"=>"վն", "ﬗ"=>"մխ", "A"=>"a", "B"=>"b", "C"=>"c", "D"=>"d", "E"=>"e", "F"=>"f", "G"=>"g", "H"=>"h", "I"=>"i", "J"=>"j", "K"=>"k", "L"=>"l", "M"=>"m", "N"=>"n", "O"=>"o", "P"=>"p", "Q"=>"q", "R"=>"r", "S"=>"s", "T"=>"t", "U"=>"u", "V"=>"v", "W"=>"w", "X"=>"x", "Y"=>"y", "Z"=>"z", "𐐀"=>"𐐨", "𐐁"=>"𐐩", "𐐂"=>"𐐪", "𐐃"=>"𐐫", "𐐄"=>"𐐬", "𐐅"=>"𐐭", "𐐆"=>"𐐮", "𐐇"=>"𐐯", "𐐈"=>"𐐰", "𐐉"=>"𐐱", "𐐊"=>"𐐲", "𐐋"=>"𐐳", "𐐌"=>"𐐴", "𐐍"=>"𐐵", "𐐎"=>"𐐶", "𐐏"=>"𐐷", "𐐐"=>"𐐸", "𐐑"=>"𐐹", "𐐒"=>"𐐺", "𐐓"=>"𐐻", "𐐔"=>"𐐼", "𐐕"=>"𐐽", "𐐖"=>"𐐾", "𐐗"=>"𐐿", "𐐘"=>"𐑀", "𐐙"=>"𐑁", "𐐚"=>"𐑂", "𐐛"=>"𐑃", "𐐜"=>"𐑄", "𐐝"=>"𐑅", "𐐞"=>"𐑆", "𐐟"=>"𐑇", "𐐠"=>"𐑈", "𐐡"=>"𐑉", "𐐢"=>"𐑊", "𐐣"=>"𐑋", "𐐤"=>"𐑌", "𐐥"=>"𐑍", "𝐀"=>"a", "𝐁"=>"b", "𝐂"=>"c", "𝐃"=>"d", "𝐄"=>"e", "𝐅"=>"f", "𝐆"=>"g", "𝐇"=>"h", "𝐈"=>"i", "𝐉"=>"j", "𝐊"=>"k", "𝐋"=>"l", "𝐌"=>"m", "𝐍"=>"n", "𝐎"=>"o", "𝐏"=>"p", "𝐐"=>"q", "𝐑"=>"r", "𝐒"=>"s", "𝐓"=>"t", "𝐔"=>"u", "𝐕"=>"v", "𝐖"=>"w", "𝐗"=>"x", "𝐘"=>"y", "𝐙"=>"z", "𝐴"=>"a", "𝐵"=>"b", "𝐶"=>"c", "𝐷"=>"d", "𝐸"=>"e", "𝐹"=>"f", "𝐺"=>"g", "𝐻"=>"h", "𝐼"=>"i", "𝐽"=>"j", "𝐾"=>"k", "𝐿"=>"l", "𝑀"=>"m", "𝑁"=>"n", "𝑂"=>"o", "𝑃"=>"p", "𝑄"=>"q", "𝑅"=>"r", "𝑆"=>"s", "𝑇"=>"t", "𝑈"=>"u", "𝑉"=>"v", "𝑊"=>"w", "𝑋"=>"x", "𝑌"=>"y", "𝑍"=>"z", "𝑨"=>"a", "𝑩"=>"b", "𝑪"=>"c", "𝑫"=>"d", "𝑬"=>"e", "𝑭"=>"f", "𝑮"=>"g", "𝑯"=>"h", "𝑰"=>"i", "𝑱"=>"j", "𝑲"=>"k", "𝑳"=>"l", "𝑴"=>"m", "𝑵"=>"n", "𝑶"=>"o", "𝑷"=>"p", "𝑸"=>"q", "𝑹"=>"r", "𝑺"=>"s", "𝑻"=>"t", "𝑼"=>"u", "𝑽"=>"v", "𝑾"=>"w", "𝑿"=>"x", "𝒀"=>"y", "𝒁"=>"z", "𝒜"=>"a", "𝒞"=>"c", "𝒟"=>"d", "𝒢"=>"g", "𝒥"=>"j", "𝒦"=>"k", "𝒩"=>"n", "𝒪"=>"o", "𝒫"=>"p", "𝒬"=>"q", "𝒮"=>"s", "𝒯"=>"t", "𝒰"=>"u", "𝒱"=>"v", "𝒲"=>"w", "𝒳"=>"x", "𝒴"=>"y", "𝒵"=>"z", "𝓐"=>"a", "𝓑"=>"b", "𝓒"=>"c", "𝓓"=>"d", "𝓔"=>"e", "𝓕"=>"f", "𝓖"=>"g", "𝓗"=>"h", "𝓘"=>"i", "𝓙"=>"j", "𝓚"=>"k", "𝓛"=>"l", "𝓜"=>"m", "𝓝"=>"n", "𝓞"=>"o", "𝓟"=>"p", "𝓠"=>"q", "𝓡"=>"r", "𝓢"=>"s", "𝓣"=>"t", "𝓤"=>"u", "𝓥"=>"v", "𝓦"=>"w", "𝓧"=>"x", "𝓨"=>"y", "𝓩"=>"z", "𝔄"=>"a", "𝔅"=>"b", "𝔇"=>"d", "𝔈"=>"e", "𝔉"=>"f", "𝔊"=>"g", "𝔍"=>"j", "𝔎"=>"k", "𝔏"=>"l", "𝔐"=>"m", "𝔑"=>"n", "𝔒"=>"o", "𝔓"=>"p", "𝔔"=>"q", "𝔖"=>"s", "𝔗"=>"t", "𝔘"=>"u", "𝔙"=>"v", "𝔚"=>"w", "𝔛"=>"x", "𝔜"=>"y", "𝔸"=>"a", "𝔹"=>"b", "𝔻"=>"d", "𝔼"=>"e", "𝔽"=>"f", "𝔾"=>"g", "𝕀"=>"i", "𝕁"=>"j", "𝕂"=>"k", "𝕃"=>"l", "𝕄"=>"m", "𝕆"=>"o", "𝕊"=>"s", "𝕋"=>"t", "𝕌"=>"u", "𝕍"=>"v", "𝕎"=>"w", "𝕏"=>"x", "𝕐"=>"y", "𝕬"=>"a", "𝕭"=>"b", "𝕮"=>"c", "𝕯"=>"d", "𝕰"=>"e", "𝕱"=>"f", "𝕲"=>"g", "𝕳"=>"h", "𝕴"=>"i", "𝕵"=>"j", "𝕶"=>"k", "𝕷"=>"l", "𝕸"=>"m", "𝕹"=>"n", "𝕺"=>"o", "𝕻"=>"p", "𝕼"=>"q", "𝕽"=>"r", "𝕾"=>"s", "𝕿"=>"t", "𝖀"=>"u", "𝖁"=>"v", "𝖂"=>"w", "𝖃"=>"x", "𝖄"=>"y", "𝖅"=>"z", "𝖠"=>"a", "𝖡"=>"b", "𝖢"=>"c", "𝖣"=>"d", "𝖤"=>"e", "𝖥"=>"f", "𝖦"=>"g", "𝖧"=>"h", "𝖨"=>"i", "𝖩"=>"j", "𝖪"=>"k", "𝖫"=>"l", "𝖬"=>"m", "𝖭"=>"n", "𝖮"=>"o", "𝖯"=>"p", "𝖰"=>"q", "𝖱"=>"r", "𝖲"=>"s", "𝖳"=>"t", "𝖴"=>"u", "𝖵"=>"v", "𝖶"=>"w", "𝖷"=>"x", "𝖸"=>"y", "𝖹"=>"z", "𝗔"=>"a", "𝗕"=>"b", "𝗖"=>"c", "𝗗"=>"d", "𝗘"=>"e", "𝗙"=>"f", "𝗚"=>"g", "𝗛"=>"h", "𝗜"=>"i", "𝗝"=>"j", "𝗞"=>"k", "𝗟"=>"l", "𝗠"=>"m", "𝗡"=>"n", "𝗢"=>"o", "𝗣"=>"p", "𝗤"=>"q", "𝗥"=>"r", "𝗦"=>"s", "𝗧"=>"t", "𝗨"=>"u", "𝗩"=>"v", "𝗪"=>"w", "𝗫"=>"x", "𝗬"=>"y", "𝗭"=>"z", "𝘈"=>"a", "𝘉"=>"b", "𝘊"=>"c", "𝘋"=>"d", "𝘌"=>"e", "𝘍"=>"f", "𝘎"=>"g", "𝘏"=>"h", "𝘐"=>"i", "𝘑"=>"j", "𝘒"=>"k", "𝘓"=>"l", "𝘔"=>"m", "𝘕"=>"n", "𝘖"=>"o", "𝘗"=>"p", "𝘘"=>"q", "𝘙"=>"r", "𝘚"=>"s", "𝘛"=>"t", "𝘜"=>"u", "𝘝"=>"v", "𝘞"=>"w", "𝘟"=>"x", "𝘠"=>"y", "𝘡"=>"z", "𝘼"=>"a", "𝘽"=>"b", "𝘾"=>"c", "𝘿"=>"d", "𝙀"=>"e", "𝙁"=>"f", "𝙂"=>"g", "𝙃"=>"h", "𝙄"=>"i", "𝙅"=>"j", "𝙆"=>"k", "𝙇"=>"l", "𝙈"=>"m", "𝙉"=>"n", "𝙊"=>"o", "𝙋"=>"p", "𝙌"=>"q", "𝙍"=>"r", "𝙎"=>"s", "𝙏"=>"t", "𝙐"=>"u", "𝙑"=>"v", "𝙒"=>"w", "𝙓"=>"x", "𝙔"=>"y", "𝙕"=>"z", "𝙰"=>"a", "𝙱"=>"b", "𝙲"=>"c", "𝙳"=>"d", "𝙴"=>"e", "𝙵"=>"f", "𝙶"=>"g", "𝙷"=>"h", "𝙸"=>"i", "𝙹"=>"j", "𝙺"=>"k", "𝙻"=>"l", "𝙼"=>"m", "𝙽"=>"n", "𝙾"=>"o", "𝙿"=>"p", "𝚀"=>"q", "𝚁"=>"r", "𝚂"=>"s", "𝚃"=>"t", "𝚄"=>"u", "𝚅"=>"v", "𝚆"=>"w", "𝚇"=>"x", "𝚈"=>"y", "𝚉"=>"z", "𝚨"=>"α", "𝚩"=>"β", "𝚪"=>"γ", "𝚫"=>"δ", "𝚬"=>"ε", "𝚭"=>"ζ", "𝚮"=>"η", "𝚯"=>"θ", "𝚰"=>"ι", "𝚱"=>"κ", "𝚲"=>"λ", "𝚳"=>"μ", "𝚴"=>"ν", "𝚵"=>"ξ", "𝚶"=>"ο", "𝚷"=>"π", "𝚸"=>"ρ", "𝚹"=>"θ", "𝚺"=>"σ", "𝚻"=>"τ", "𝚼"=>"υ", "𝚽"=>"φ", "𝚾"=>"χ", "𝚿"=>"ψ", "𝛀"=>"ω", "𝛓"=>"σ", "𝛢"=>"α", "𝛣"=>"β", "𝛤"=>"γ", "𝛥"=>"δ", "𝛦"=>"ε", "𝛧"=>"ζ", "𝛨"=>"η", "𝛩"=>"θ", "𝛪"=>"ι", "𝛫"=>"κ", "𝛬"=>"λ", "𝛭"=>"μ", "𝛮"=>"ν", "𝛯"=>"ξ", "𝛰"=>"ο", "𝛱"=>"π", "𝛲"=>"ρ", "𝛳"=>"θ", "𝛴"=>"σ", "𝛵"=>"τ", "𝛶"=>"υ", "𝛷"=>"φ", "𝛸"=>"χ", "𝛹"=>"ψ", "𝛺"=>"ω", "𝜍"=>"σ", "𝜜"=>"α", "𝜝"=>"β", "𝜞"=>"γ", "𝜟"=>"δ", "𝜠"=>"ε", "𝜡"=>"ζ", "𝜢"=>"η", "𝜣"=>"θ", "𝜤"=>"ι", "𝜥"=>"κ", "𝜦"=>"λ", "𝜧"=>"μ", "𝜨"=>"ν", "𝜩"=>"ξ", "𝜪"=>"ο", "𝜫"=>"π", "𝜬"=>"ρ", "𝜭"=>"θ", "𝜮"=>"σ", "𝜯"=>"τ", "𝜰"=>"υ", "𝜱"=>"φ", "𝜲"=>"χ", "𝜳"=>"ψ", "𝜴"=>"ω", "𝝇"=>"σ", "𝝖"=>"α", "𝝗"=>"β", "𝝘"=>"γ", "𝝙"=>"δ", "𝝚"=>"ε", "𝝛"=>"ζ", "𝝜"=>"η", "𝝝"=>"θ", "𝝞"=>"ι", "𝝟"=>"κ", "𝝠"=>"λ", "𝝡"=>"μ", "𝝢"=>"ν", "𝝣"=>"ξ", "𝝤"=>"ο", "𝝥"=>"π", "𝝦"=>"ρ", "𝝧"=>"θ", "𝝨"=>"σ", "𝝩"=>"τ", "𝝪"=>"υ", "𝝫"=>"φ", "𝝬"=>"χ", "𝝭"=>"ψ", "𝝮"=>"ω", "𝞁"=>"σ", "𝞐"=>"α", "𝞑"=>"β", "𝞒"=>"γ", "𝞓"=>"δ", "𝞔"=>"ε", "𝞕"=>"ζ", "𝞖"=>"η", "𝞗"=>"θ", "𝞘"=>"ι", "𝞙"=>"κ", "𝞚"=>"λ", "𝞛"=>"μ", "𝞜"=>"ν", "𝞝"=>"ξ", "𝞞"=>"ο", "𝞟"=>"π", "𝞠"=>"ρ", "𝞡"=>"θ", "𝞢"=>"σ", "𝞣"=>"τ", "𝞤"=>"υ", "𝞥"=>"φ", "𝞦"=>"χ", "𝞧"=>"ψ", "𝞨"=>"ω", "𝞻"=>"σ"}.freeze + + # Replacements for IN_B.3 + MAP_B_3 = {"A"=>"a", "B"=>"b", "C"=>"c", "D"=>"d", "E"=>"e", "F"=>"f", "G"=>"g", "H"=>"h", "I"=>"i", "J"=>"j", "K"=>"k", "L"=>"l", "M"=>"m", "N"=>"n", "O"=>"o", "P"=>"p", "Q"=>"q", "R"=>"r", "S"=>"s", "T"=>"t", "U"=>"u", "V"=>"v", "W"=>"w", "X"=>"x", "Y"=>"y", "Z"=>"z", "µ"=>"μ", "À"=>"à", "Á"=>"á", "Â"=>"â", "Ã"=>"ã", "Ä"=>"ä", "Å"=>"å", "Æ"=>"æ", "Ç"=>"ç", "È"=>"è", "É"=>"é", "Ê"=>"ê", "Ë"=>"ë", "Ì"=>"ì", "Í"=>"í", "Î"=>"î", "Ï"=>"ï", "Ð"=>"ð", "Ñ"=>"ñ", "Ò"=>"ò", "Ó"=>"ó", "Ô"=>"ô", "Õ"=>"õ", "Ö"=>"ö", "Ø"=>"ø", "Ù"=>"ù", "Ú"=>"ú", "Û"=>"û", "Ü"=>"ü", "Ý"=>"ý", "Þ"=>"þ", "ß"=>"ss", "Ā"=>"ā", "Ă"=>"ă", "Ą"=>"ą", "Ć"=>"ć", "Ĉ"=>"ĉ", "Ċ"=>"ċ", "Č"=>"č", "Ď"=>"ď", "Đ"=>"đ", "Ē"=>"ē", "Ĕ"=>"ĕ", "Ė"=>"ė", "Ę"=>"ę", "Ě"=>"ě", "Ĝ"=>"ĝ", "Ğ"=>"ğ", "Ġ"=>"ġ", "Ģ"=>"ģ", "Ĥ"=>"ĥ", "Ħ"=>"ħ", "Ĩ"=>"ĩ", "Ī"=>"ī", "Ĭ"=>"ĭ", "Į"=>"į", "İ"=>"i̇", "IJ"=>"ij", "Ĵ"=>"ĵ", "Ķ"=>"ķ", "Ĺ"=>"ĺ", "Ļ"=>"ļ", "Ľ"=>"ľ", "Ŀ"=>"ŀ", "Ł"=>"ł", "Ń"=>"ń", "Ņ"=>"ņ", "Ň"=>"ň", "ʼn"=>"ʼn", "Ŋ"=>"ŋ", "Ō"=>"ō", "Ŏ"=>"ŏ", "Ő"=>"ő", "Œ"=>"œ", "Ŕ"=>"ŕ", "Ŗ"=>"ŗ", "Ř"=>"ř", "Ś"=>"ś", "Ŝ"=>"ŝ", "Ş"=>"ş", "Š"=>"š", "Ţ"=>"ţ", "Ť"=>"ť", "Ŧ"=>"ŧ", "Ũ"=>"ũ", "Ū"=>"ū", "Ŭ"=>"ŭ", "Ů"=>"ů", "Ű"=>"ű", "Ų"=>"ų", "Ŵ"=>"ŵ", "Ŷ"=>"ŷ", "Ÿ"=>"ÿ", "Ź"=>"ź", "Ż"=>"ż", "Ž"=>"ž", "ſ"=>"s", "Ɓ"=>"ɓ", "Ƃ"=>"ƃ", "Ƅ"=>"ƅ", "Ɔ"=>"ɔ", "Ƈ"=>"ƈ", "Ɖ"=>"ɖ", "Ɗ"=>"ɗ", "Ƌ"=>"ƌ", "Ǝ"=>"ǝ", "Ə"=>"ə", "Ɛ"=>"ɛ", "Ƒ"=>"ƒ", "Ɠ"=>"ɠ", "Ɣ"=>"ɣ", "Ɩ"=>"ɩ", "Ɨ"=>"ɨ", "Ƙ"=>"ƙ", "Ɯ"=>"ɯ", "Ɲ"=>"ɲ", "Ɵ"=>"ɵ", "Ơ"=>"ơ", "Ƣ"=>"ƣ", "Ƥ"=>"ƥ", "Ʀ"=>"ʀ", "Ƨ"=>"ƨ", "Ʃ"=>"ʃ", "Ƭ"=>"ƭ", "Ʈ"=>"ʈ", "Ư"=>"ư", "Ʊ"=>"ʊ", "Ʋ"=>"ʋ", "Ƴ"=>"ƴ", "Ƶ"=>"ƶ", "Ʒ"=>"ʒ", "Ƹ"=>"ƹ", "Ƽ"=>"ƽ", "DŽ"=>"dž", "Dž"=>"dž", "LJ"=>"lj", "Lj"=>"lj", "NJ"=>"nj", "Nj"=>"nj", "Ǎ"=>"ǎ", "Ǐ"=>"ǐ", "Ǒ"=>"ǒ", "Ǔ"=>"ǔ", "Ǖ"=>"ǖ", "Ǘ"=>"ǘ", "Ǚ"=>"ǚ", "Ǜ"=>"ǜ", "Ǟ"=>"ǟ", "Ǡ"=>"ǡ", "Ǣ"=>"ǣ", "Ǥ"=>"ǥ", "Ǧ"=>"ǧ", "Ǩ"=>"ǩ", "Ǫ"=>"ǫ", "Ǭ"=>"ǭ", "Ǯ"=>"ǯ", "ǰ"=>"ǰ", "DZ"=>"dz", "Dz"=>"dz", "Ǵ"=>"ǵ", "Ƕ"=>"ƕ", "Ƿ"=>"ƿ", "Ǹ"=>"ǹ", "Ǻ"=>"ǻ", "Ǽ"=>"ǽ", "Ǿ"=>"ǿ", "Ȁ"=>"ȁ", "Ȃ"=>"ȃ", "Ȅ"=>"ȅ", "Ȇ"=>"ȇ", "Ȉ"=>"ȉ", "Ȋ"=>"ȋ", "Ȍ"=>"ȍ", "Ȏ"=>"ȏ", "Ȑ"=>"ȑ", "Ȓ"=>"ȓ", "Ȕ"=>"ȕ", "Ȗ"=>"ȗ", "Ș"=>"ș", "Ț"=>"ț", "Ȝ"=>"ȝ", "Ȟ"=>"ȟ", "Ƞ"=>"ƞ", "Ȣ"=>"ȣ", "Ȥ"=>"ȥ", "Ȧ"=>"ȧ", "Ȩ"=>"ȩ", "Ȫ"=>"ȫ", "Ȭ"=>"ȭ", "Ȯ"=>"ȯ", "Ȱ"=>"ȱ", "Ȳ"=>"ȳ", "ͅ"=>"ι", "Ά"=>"ά", "Έ"=>"έ", "Ή"=>"ή", "Ί"=>"ί", "Ό"=>"ό", "Ύ"=>"ύ", "Ώ"=>"ώ", "ΐ"=>"ΐ", "Α"=>"α", "Β"=>"β", "Γ"=>"γ", "Δ"=>"δ", "Ε"=>"ε", "Ζ"=>"ζ", "Η"=>"η", "Θ"=>"θ", "Ι"=>"ι", "Κ"=>"κ", "Λ"=>"λ", "Μ"=>"μ", "Ν"=>"ν", "Ξ"=>"ξ", "Ο"=>"ο", "Π"=>"π", "Ρ"=>"ρ", "Σ"=>"σ", "Τ"=>"τ", "Υ"=>"υ", "Φ"=>"φ", "Χ"=>"χ", "Ψ"=>"ψ", "Ω"=>"ω", "Ϊ"=>"ϊ", "Ϋ"=>"ϋ", "ΰ"=>"ΰ", "ς"=>"σ", "ϐ"=>"β", "ϑ"=>"θ", "ϕ"=>"φ", "ϖ"=>"π", "Ϙ"=>"ϙ", "Ϛ"=>"ϛ", "Ϝ"=>"ϝ", "Ϟ"=>"ϟ", "Ϡ"=>"ϡ", "Ϣ"=>"ϣ", "Ϥ"=>"ϥ", "Ϧ"=>"ϧ", "Ϩ"=>"ϩ", "Ϫ"=>"ϫ", "Ϭ"=>"ϭ", "Ϯ"=>"ϯ", "ϰ"=>"κ", "ϱ"=>"ρ", "ϲ"=>"σ", "ϴ"=>"θ", "ϵ"=>"ε", "Ѐ"=>"ѐ", "Ё"=>"ё", "Ђ"=>"ђ", "Ѓ"=>"ѓ", "Є"=>"є", "Ѕ"=>"ѕ", "І"=>"і", "Ї"=>"ї", "Ј"=>"ј", "Љ"=>"љ", "Њ"=>"њ", "Ћ"=>"ћ", "Ќ"=>"ќ", "Ѝ"=>"ѝ", "Ў"=>"ў", "Џ"=>"џ", "А"=>"а", "Б"=>"б", "В"=>"в", "Г"=>"г", "Д"=>"д", "Е"=>"е", "Ж"=>"ж", "З"=>"з", "И"=>"и", "Й"=>"й", "К"=>"к", "Л"=>"л", "М"=>"м", "Н"=>"н", "О"=>"о", "П"=>"п", "Р"=>"р", "С"=>"с", "Т"=>"т", "У"=>"у", "Ф"=>"ф", "Х"=>"х", "Ц"=>"ц", "Ч"=>"ч", "Ш"=>"ш", "Щ"=>"щ", "Ъ"=>"ъ", "Ы"=>"ы", "Ь"=>"ь", "Э"=>"э", "Ю"=>"ю", "Я"=>"я", "Ѡ"=>"ѡ", "Ѣ"=>"ѣ", "Ѥ"=>"ѥ", "Ѧ"=>"ѧ", "Ѩ"=>"ѩ", "Ѫ"=>"ѫ", "Ѭ"=>"ѭ", "Ѯ"=>"ѯ", "Ѱ"=>"ѱ", "Ѳ"=>"ѳ", "Ѵ"=>"ѵ", "Ѷ"=>"ѷ", "Ѹ"=>"ѹ", "Ѻ"=>"ѻ", "Ѽ"=>"ѽ", "Ѿ"=>"ѿ", "Ҁ"=>"ҁ", "Ҋ"=>"ҋ", "Ҍ"=>"ҍ", "Ҏ"=>"ҏ", "Ґ"=>"ґ", "Ғ"=>"ғ", "Ҕ"=>"ҕ", "Җ"=>"җ", "Ҙ"=>"ҙ", "Қ"=>"қ", "Ҝ"=>"ҝ", "Ҟ"=>"ҟ", "Ҡ"=>"ҡ", "Ң"=>"ң", "Ҥ"=>"ҥ", "Ҧ"=>"ҧ", "Ҩ"=>"ҩ", "Ҫ"=>"ҫ", "Ҭ"=>"ҭ", "Ү"=>"ү", "Ұ"=>"ұ", "Ҳ"=>"ҳ", "Ҵ"=>"ҵ", "Ҷ"=>"ҷ", "Ҹ"=>"ҹ", "Һ"=>"һ", "Ҽ"=>"ҽ", "Ҿ"=>"ҿ", "Ӂ"=>"ӂ", "Ӄ"=>"ӄ", "Ӆ"=>"ӆ", "Ӈ"=>"ӈ", "Ӊ"=>"ӊ", "Ӌ"=>"ӌ", "Ӎ"=>"ӎ", "Ӑ"=>"ӑ", "Ӓ"=>"ӓ", "Ӕ"=>"ӕ", "Ӗ"=>"ӗ", "Ә"=>"ә", "Ӛ"=>"ӛ", "Ӝ"=>"ӝ", "Ӟ"=>"ӟ", "Ӡ"=>"ӡ", "Ӣ"=>"ӣ", "Ӥ"=>"ӥ", "Ӧ"=>"ӧ", "Ө"=>"ө", "Ӫ"=>"ӫ", "Ӭ"=>"ӭ", "Ӯ"=>"ӯ", "Ӱ"=>"ӱ", "Ӳ"=>"ӳ", "Ӵ"=>"ӵ", "Ӹ"=>"ӹ", "Ԁ"=>"ԁ", "Ԃ"=>"ԃ", "Ԅ"=>"ԅ", "Ԇ"=>"ԇ", "Ԉ"=>"ԉ", "Ԋ"=>"ԋ", "Ԍ"=>"ԍ", "Ԏ"=>"ԏ", "Ա"=>"ա", "Բ"=>"բ", "Գ"=>"գ", "Դ"=>"դ", "Ե"=>"ե", "Զ"=>"զ", "Է"=>"է", "Ը"=>"ը", "Թ"=>"թ", "Ժ"=>"ժ", "Ի"=>"ի", "Լ"=>"լ", "Խ"=>"խ", "Ծ"=>"ծ", "Կ"=>"կ", "Հ"=>"հ", "Ձ"=>"ձ", "Ղ"=>"ղ", "Ճ"=>"ճ", "Մ"=>"մ", "Յ"=>"յ", "Ն"=>"ն", "Շ"=>"շ", "Ո"=>"ո", "Չ"=>"չ", "Պ"=>"պ", "Ջ"=>"ջ", "Ռ"=>"ռ", "Ս"=>"ս", "Վ"=>"վ", "Տ"=>"տ", "Ր"=>"ր", "Ց"=>"ց", "Ւ"=>"ւ", "Փ"=>"փ", "Ք"=>"ք", "Օ"=>"օ", "Ֆ"=>"ֆ", "և"=>"եւ", "Ḁ"=>"ḁ", "Ḃ"=>"ḃ", "Ḅ"=>"ḅ", "Ḇ"=>"ḇ", "Ḉ"=>"ḉ", "Ḋ"=>"ḋ", "Ḍ"=>"ḍ", "Ḏ"=>"ḏ", "Ḑ"=>"ḑ", "Ḓ"=>"ḓ", "Ḕ"=>"ḕ", "Ḗ"=>"ḗ", "Ḙ"=>"ḙ", "Ḛ"=>"ḛ", "Ḝ"=>"ḝ", "Ḟ"=>"ḟ", "Ḡ"=>"ḡ", "Ḣ"=>"ḣ", "Ḥ"=>"ḥ", "Ḧ"=>"ḧ", "Ḩ"=>"ḩ", "Ḫ"=>"ḫ", "Ḭ"=>"ḭ", "Ḯ"=>"ḯ", "Ḱ"=>"ḱ", "Ḳ"=>"ḳ", "Ḵ"=>"ḵ", "Ḷ"=>"ḷ", "Ḹ"=>"ḹ", "Ḻ"=>"ḻ", "Ḽ"=>"ḽ", "Ḿ"=>"ḿ", "Ṁ"=>"ṁ", "Ṃ"=>"ṃ", "Ṅ"=>"ṅ", "Ṇ"=>"ṇ", "Ṉ"=>"ṉ", "Ṋ"=>"ṋ", "Ṍ"=>"ṍ", "Ṏ"=>"ṏ", "Ṑ"=>"ṑ", "Ṓ"=>"ṓ", "Ṕ"=>"ṕ", "Ṗ"=>"ṗ", "Ṙ"=>"ṙ", "Ṛ"=>"ṛ", "Ṝ"=>"ṝ", "Ṟ"=>"ṟ", "Ṡ"=>"ṡ", "Ṣ"=>"ṣ", "Ṥ"=>"ṥ", "Ṧ"=>"ṧ", "Ṩ"=>"ṩ", "Ṫ"=>"ṫ", "Ṭ"=>"ṭ", "Ṯ"=>"ṯ", "Ṱ"=>"ṱ", "Ṳ"=>"ṳ", "Ṵ"=>"ṵ", "Ṷ"=>"ṷ", "Ṹ"=>"ṹ", "Ṻ"=>"ṻ", "Ṽ"=>"ṽ", "Ṿ"=>"ṿ", "Ẁ"=>"ẁ", "Ẃ"=>"ẃ", "Ẅ"=>"ẅ", "Ẇ"=>"ẇ", "Ẉ"=>"ẉ", "Ẋ"=>"ẋ", "Ẍ"=>"ẍ", "Ẏ"=>"ẏ", "Ẑ"=>"ẑ", "Ẓ"=>"ẓ", "Ẕ"=>"ẕ", "ẖ"=>"ẖ", "ẗ"=>"ẗ", "ẘ"=>"ẘ", "ẙ"=>"ẙ", "ẚ"=>"aʾ", "ẛ"=>"ṡ", "Ạ"=>"ạ", "Ả"=>"ả", "Ấ"=>"ấ", "Ầ"=>"ầ", "Ẩ"=>"ẩ", "Ẫ"=>"ẫ", "Ậ"=>"ậ", "Ắ"=>"ắ", "Ằ"=>"ằ", "Ẳ"=>"ẳ", "Ẵ"=>"ẵ", "Ặ"=>"ặ", "Ẹ"=>"ẹ", "Ẻ"=>"ẻ", "Ẽ"=>"ẽ", "Ế"=>"ế", "Ề"=>"ề", "Ể"=>"ể", "Ễ"=>"ễ", "Ệ"=>"ệ", "Ỉ"=>"ỉ", "Ị"=>"ị", "Ọ"=>"ọ", "Ỏ"=>"ỏ", "Ố"=>"ố", "Ồ"=>"ồ", "Ổ"=>"ổ", "Ỗ"=>"ỗ", "Ộ"=>"ộ", "Ớ"=>"ớ", "Ờ"=>"ờ", "Ở"=>"ở", "Ỡ"=>"ỡ", "Ợ"=>"ợ", "Ụ"=>"ụ", "Ủ"=>"ủ", "Ứ"=>"ứ", "Ừ"=>"ừ", "Ử"=>"ử", "Ữ"=>"ữ", "Ự"=>"ự", "Ỳ"=>"ỳ", "Ỵ"=>"ỵ", "Ỷ"=>"ỷ", "Ỹ"=>"ỹ", "Ἀ"=>"ἀ", "Ἁ"=>"ἁ", "Ἂ"=>"ἂ", "Ἃ"=>"ἃ", "Ἄ"=>"ἄ", "Ἅ"=>"ἅ", "Ἆ"=>"ἆ", "Ἇ"=>"ἇ", "Ἐ"=>"ἐ", "Ἑ"=>"ἑ", "Ἒ"=>"ἒ", "Ἓ"=>"ἓ", "Ἔ"=>"ἔ", "Ἕ"=>"ἕ", "Ἠ"=>"ἠ", "Ἡ"=>"ἡ", "Ἢ"=>"ἢ", "Ἣ"=>"ἣ", "Ἤ"=>"ἤ", "Ἥ"=>"ἥ", "Ἦ"=>"ἦ", "Ἧ"=>"ἧ", "Ἰ"=>"ἰ", "Ἱ"=>"ἱ", "Ἲ"=>"ἲ", "Ἳ"=>"ἳ", "Ἴ"=>"ἴ", "Ἵ"=>"ἵ", "Ἶ"=>"ἶ", "Ἷ"=>"ἷ", "Ὀ"=>"ὀ", "Ὁ"=>"ὁ", "Ὂ"=>"ὂ", "Ὃ"=>"ὃ", "Ὄ"=>"ὄ", "Ὅ"=>"ὅ", "ὐ"=>"ὐ", "ὒ"=>"ὒ", "ὔ"=>"ὔ", "ὖ"=>"ὖ", "Ὑ"=>"ὑ", "Ὓ"=>"ὓ", "Ὕ"=>"ὕ", "Ὗ"=>"ὗ", "Ὠ"=>"ὠ", "Ὡ"=>"ὡ", "Ὢ"=>"ὢ", "Ὣ"=>"ὣ", "Ὤ"=>"ὤ", "Ὥ"=>"ὥ", "Ὦ"=>"ὦ", "Ὧ"=>"ὧ", "ᾀ"=>"ἀι", "ᾁ"=>"ἁι", "ᾂ"=>"ἂι", "ᾃ"=>"ἃι", "ᾄ"=>"ἄι", "ᾅ"=>"ἅι", "ᾆ"=>"ἆι", "ᾇ"=>"ἇι", "ᾈ"=>"ἀι", "ᾉ"=>"ἁι", "ᾊ"=>"ἂι", "ᾋ"=>"ἃι", "ᾌ"=>"ἄι", "ᾍ"=>"ἅι", "ᾎ"=>"ἆι", "ᾏ"=>"ἇι", "ᾐ"=>"ἠι", "ᾑ"=>"ἡι", "ᾒ"=>"ἢι", "ᾓ"=>"ἣι", "ᾔ"=>"ἤι", "ᾕ"=>"ἥι", "ᾖ"=>"ἦι", "ᾗ"=>"ἧι", "ᾘ"=>"ἠι", "ᾙ"=>"ἡι", "ᾚ"=>"ἢι", "ᾛ"=>"ἣι", "ᾜ"=>"ἤι", "ᾝ"=>"ἥι", "ᾞ"=>"ἦι", "ᾟ"=>"ἧι", "ᾠ"=>"ὠι", "ᾡ"=>"ὡι", "ᾢ"=>"ὢι", "ᾣ"=>"ὣι", "ᾤ"=>"ὤι", "ᾥ"=>"ὥι", "ᾦ"=>"ὦι", "ᾧ"=>"ὧι", "ᾨ"=>"ὠι", "ᾩ"=>"ὡι", "ᾪ"=>"ὢι", "ᾫ"=>"ὣι", "ᾬ"=>"ὤι", "ᾭ"=>"ὥι", "ᾮ"=>"ὦι", "ᾯ"=>"ὧι", "ᾲ"=>"ὰι", "ᾳ"=>"αι", "ᾴ"=>"άι", "ᾶ"=>"ᾶ", "ᾷ"=>"ᾶι", "Ᾰ"=>"ᾰ", "Ᾱ"=>"ᾱ", "Ὰ"=>"ὰ", "Ά"=>"ά", "ᾼ"=>"αι", "ι"=>"ι", "ῂ"=>"ὴι", "ῃ"=>"ηι", "ῄ"=>"ήι", "ῆ"=>"ῆ", "ῇ"=>"ῆι", "Ὲ"=>"ὲ", "Έ"=>"έ", "Ὴ"=>"ὴ", "Ή"=>"ή", "ῌ"=>"ηι", "ῒ"=>"ῒ", "ΐ"=>"ΐ", "ῖ"=>"ῖ", "ῗ"=>"ῗ", "Ῐ"=>"ῐ", "Ῑ"=>"ῑ", "Ὶ"=>"ὶ", "Ί"=>"ί", "ῢ"=>"ῢ", "ΰ"=>"ΰ", "ῤ"=>"ῤ", "ῦ"=>"ῦ", "ῧ"=>"ῧ", "Ῠ"=>"ῠ", "Ῡ"=>"ῡ", "Ὺ"=>"ὺ", "Ύ"=>"ύ", "Ῥ"=>"ῥ", "ῲ"=>"ὼι", "ῳ"=>"ωι", "ῴ"=>"ώι", "ῶ"=>"ῶ", "ῷ"=>"ῶι", "Ὸ"=>"ὸ", "Ό"=>"ό", "Ὼ"=>"ὼ", "Ώ"=>"ώ", "ῼ"=>"ωι", "Ω"=>"ω", "K"=>"k", "Å"=>"å", "Ⅰ"=>"ⅰ", "Ⅱ"=>"ⅱ", "Ⅲ"=>"ⅲ", "Ⅳ"=>"ⅳ", "Ⅴ"=>"ⅴ", "Ⅵ"=>"ⅵ", "Ⅶ"=>"ⅶ", "Ⅷ"=>"ⅷ", "Ⅸ"=>"ⅸ", "Ⅹ"=>"ⅹ", "Ⅺ"=>"ⅺ", "Ⅻ"=>"ⅻ", "Ⅼ"=>"ⅼ", "Ⅽ"=>"ⅽ", "Ⅾ"=>"ⅾ", "Ⅿ"=>"ⅿ", "Ⓐ"=>"ⓐ", "Ⓑ"=>"ⓑ", "Ⓒ"=>"ⓒ", "Ⓓ"=>"ⓓ", "Ⓔ"=>"ⓔ", "Ⓕ"=>"ⓕ", "Ⓖ"=>"ⓖ", "Ⓗ"=>"ⓗ", "Ⓘ"=>"ⓘ", "Ⓙ"=>"ⓙ", "Ⓚ"=>"ⓚ", "Ⓛ"=>"ⓛ", "Ⓜ"=>"ⓜ", "Ⓝ"=>"ⓝ", "Ⓞ"=>"ⓞ", "Ⓟ"=>"ⓟ", "Ⓠ"=>"ⓠ", "Ⓡ"=>"ⓡ", "Ⓢ"=>"ⓢ", "Ⓣ"=>"ⓣ", "Ⓤ"=>"ⓤ", "Ⓥ"=>"ⓥ", "Ⓦ"=>"ⓦ", "Ⓧ"=>"ⓧ", "Ⓨ"=>"ⓨ", "Ⓩ"=>"ⓩ", "ff"=>"ff", "fi"=>"fi", "fl"=>"fl", "ffi"=>"ffi", "ffl"=>"ffl", "ſt"=>"st", "st"=>"st", "ﬓ"=>"մն", "ﬔ"=>"մե", "ﬕ"=>"մի", "ﬖ"=>"վն", "ﬗ"=>"մխ", "A"=>"a", "B"=>"b", "C"=>"c", "D"=>"d", "E"=>"e", "F"=>"f", "G"=>"g", "H"=>"h", "I"=>"i", "J"=>"j", "K"=>"k", "L"=>"l", "M"=>"m", "N"=>"n", "O"=>"o", "P"=>"p", "Q"=>"q", "R"=>"r", "S"=>"s", "T"=>"t", "U"=>"u", "V"=>"v", "W"=>"w", "X"=>"x", "Y"=>"y", "Z"=>"z", "𐐀"=>"𐐨", "𐐁"=>"𐐩", "𐐂"=>"𐐪", "𐐃"=>"𐐫", "𐐄"=>"𐐬", "𐐅"=>"𐐭", "𐐆"=>"𐐮", "𐐇"=>"𐐯", "𐐈"=>"𐐰", "𐐉"=>"𐐱", "𐐊"=>"𐐲", "𐐋"=>"𐐳", "𐐌"=>"𐐴", "𐐍"=>"𐐵", "𐐎"=>"𐐶", "𐐏"=>"𐐷", "𐐐"=>"𐐸", "𐐑"=>"𐐹", "𐐒"=>"𐐺", "𐐓"=>"𐐻", "𐐔"=>"𐐼", "𐐕"=>"𐐽", "𐐖"=>"𐐾", "𐐗"=>"𐐿", "𐐘"=>"𐑀", "𐐙"=>"𐑁", "𐐚"=>"𐑂", "𐐛"=>"𐑃", "𐐜"=>"𐑄", "𐐝"=>"𐑅", "𐐞"=>"𐑆", "𐐟"=>"𐑇", "𐐠"=>"𐑈", "𐐡"=>"𐑉", "𐐢"=>"𐑊", "𐐣"=>"𐑋", "𐐤"=>"𐑌", "𐐥"=>"𐑍"}.freeze + + # ASCII space characters \StringPrep\[\"C.1.1\"] + IN_C_1_1 = / /.freeze + + # Non-ASCII space characters \StringPrep\[\"C.1.2\"] + IN_C_1_2 = /[\u200b\p{Zs}&&[^ ]]/.freeze + + # ASCII control characters \StringPrep\[\"C.2.1\"] + IN_C_2_1 = /[\x00-\x1f\x7f]/.freeze + + # Non-ASCII control characters \StringPrep\[\"C.2.2\"] + IN_C_2_2 = /[\u{06dd 070f 180e feff}\u{0080}-\u{009f}\u{200c}-\u{200d}\u{2028}-\u{2029}\u{2060}-\u{2063}\u{206a}-\u{206f}\u{fff9}-\u{fffc}\u{1d173}-\u{1d17a}]/.freeze + + # Private use \StringPrep\[\"C.3\"] + IN_C_3 = /\p{private use}/.freeze + + # Non-character code points \StringPrep\[\"C.4\"] + IN_C_4 = /\p{noncharacter code point}/.freeze + + # Surrogate codes \StringPrep\[\"C.5\"] + IN_C_5 = /\p{surrogate}/.freeze + + # Inappropriate for plain text \StringPrep\[\"C.6\"] + IN_C_6 = /[\p{in specials}&&\p{AGE=3.2}&&\p{^NChar}]/.freeze + + # Inappropriate for canonical representation \StringPrep\[\"C.7\"] + IN_C_7 = /[\p{in ideographic description characters}&&\p{AGE=3.2}]/.freeze + + # Change display properties or are deprecated \StringPrep\[\"C.8\"] + IN_C_8 = /[\u{0340}-\u{0341}\u{200e}-\u{200f}\u{202a}-\u{202e}\u{206a}-\u{206f}]/.freeze + + # Tagging characters \StringPrep\[\"C.9\"] + IN_C_9 = /[\p{in Tags}&&\p{AGE=3.2}]/.freeze + + # Characters with bidirectional property "R" or "AL" \StringPrep\[\"D.1\"] + IN_D_1 = /[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]/.freeze + + # Used to check req3 of bidirectional checks + # Matches the negation of the D.1 table + IN_D_1_NEGATED = /[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]/.freeze + + # Characters with bidirectional property "L" \StringPrep\[\"D.2\"] + IN_D_2 = /[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]/.freeze + + BIDI_DESC_REQ2 = "A string with RandALCat characters must not contain LCat characters." + + # Bidirectional Characters [StringPrep, §6], Requirement 2 + # >>> + # If a string contains any RandALCat character, the string MUST NOT + # contain any LCat character. + BIDI_FAILS_REQ2 = /(?m-ix:(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]))|(?m-ix:(?-mix:[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]).*?(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]))/.freeze + + BIDI_DESC_REQ3 = "A string with RandALCat characters must start and end with RandALCat characters." + + # Bidirectional Characters [StringPrep, §6], Requirement 3 + # >>> + # If a string contains any RandALCat character, a RandALCat + # character MUST be the first character of the string, and a + # RandALCat character MUST be the last character of the string. + BIDI_FAILS_REQ3 = /(?m-ix:\A(?-mix:[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]))|(?m-ix:(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}])\z)/.freeze + + # Bidirectional Characters [StringPrep, §6] + BIDI_FAILURE = /(?-mix:(?m-ix:(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]))|(?m-ix:(?-mix:[\u{00aa 00b5 00ba 02ee 037a 0386 038c 0589 0903 0950 09b2 09d7 0a5e 0a83 0a8d 0ac9 0ad0 0ae0 0b40 0b57 0b83 0b9c 0bd7 0cbe 0cde 0d57 0dbd 0e84 0e8a 0e8d 0ea5 0ea7 0ebd 0ec6 0f36 0f38 0f7f 0f85 0fcf 102c 1031 1038 10fb 1248 1258 1288 12b0 12c0 1310 17dc 1f59 1f5b 1f5d 1fbe 200e 2071 207f 2102 2107 2115 2124 2126 2128 2395 1d4a2 1d4bb 1d546}\u{0041}-\u{005a}\u{0061}-\u{007a}\u{00c0}-\u{00d6}\u{00d8}-\u{00f6}\u{00f8}-\u{0220}\u{0222}-\u{0233}\u{0250}-\u{02ad}\u{02b0}-\u{02b8}\u{02bb}-\u{02c1}\u{02d0}-\u{02d1}\u{02e0}-\u{02e4}\u{0388}-\u{038a}\u{038e}-\u{03a1}\u{03a3}-\u{03ce}\u{03d0}-\u{03f5}\u{0400}-\u{0482}\u{048a}-\u{04ce}\u{04d0}-\u{04f5}\u{04f8}-\u{04f9}\u{0500}-\u{050f}\u{0531}-\u{0556}\u{0559}-\u{055f}\u{0561}-\u{0587}\u{0905}-\u{0939}\u{093d}-\u{0940}\u{0949}-\u{094c}\u{0958}-\u{0961}\u{0964}-\u{0970}\u{0982}-\u{0983}\u{0985}-\u{098c}\u{098f}-\u{0990}\u{0993}-\u{09a8}\u{09aa}-\u{09b0}\u{09b6}-\u{09b9}\u{09be}-\u{09c0}\u{09c7}-\u{09c8}\u{09cb}-\u{09cc}\u{09dc}-\u{09dd}\u{09df}-\u{09e1}\u{09e6}-\u{09f1}\u{09f4}-\u{09fa}\u{0a05}-\u{0a0a}\u{0a0f}-\u{0a10}\u{0a13}-\u{0a28}\u{0a2a}-\u{0a30}\u{0a32}-\u{0a33}\u{0a35}-\u{0a36}\u{0a38}-\u{0a39}\u{0a3e}-\u{0a40}\u{0a59}-\u{0a5c}\u{0a66}-\u{0a6f}\u{0a72}-\u{0a74}\u{0a85}-\u{0a8b}\u{0a8f}-\u{0a91}\u{0a93}-\u{0aa8}\u{0aaa}-\u{0ab0}\u{0ab2}-\u{0ab3}\u{0ab5}-\u{0ab9}\u{0abd}-\u{0ac0}\u{0acb}-\u{0acc}\u{0ae6}-\u{0aef}\u{0b02}-\u{0b03}\u{0b05}-\u{0b0c}\u{0b0f}-\u{0b10}\u{0b13}-\u{0b28}\u{0b2a}-\u{0b30}\u{0b32}-\u{0b33}\u{0b36}-\u{0b39}\u{0b3d}-\u{0b3e}\u{0b47}-\u{0b48}\u{0b4b}-\u{0b4c}\u{0b5c}-\u{0b5d}\u{0b5f}-\u{0b61}\u{0b66}-\u{0b70}\u{0b85}-\u{0b8a}\u{0b8e}-\u{0b90}\u{0b92}-\u{0b95}\u{0b99}-\u{0b9a}\u{0b9e}-\u{0b9f}\u{0ba3}-\u{0ba4}\u{0ba8}-\u{0baa}\u{0bae}-\u{0bb5}\u{0bb7}-\u{0bb9}\u{0bbe}-\u{0bbf}\u{0bc1}-\u{0bc2}\u{0bc6}-\u{0bc8}\u{0bca}-\u{0bcc}\u{0be7}-\u{0bf2}\u{0c01}-\u{0c03}\u{0c05}-\u{0c0c}\u{0c0e}-\u{0c10}\u{0c12}-\u{0c28}\u{0c2a}-\u{0c33}\u{0c35}-\u{0c39}\u{0c41}-\u{0c44}\u{0c60}-\u{0c61}\u{0c66}-\u{0c6f}\u{0c82}-\u{0c83}\u{0c85}-\u{0c8c}\u{0c8e}-\u{0c90}\u{0c92}-\u{0ca8}\u{0caa}-\u{0cb3}\u{0cb5}-\u{0cb9}\u{0cc0}-\u{0cc4}\u{0cc7}-\u{0cc8}\u{0cca}-\u{0ccb}\u{0cd5}-\u{0cd6}\u{0ce0}-\u{0ce1}\u{0ce6}-\u{0cef}\u{0d02}-\u{0d03}\u{0d05}-\u{0d0c}\u{0d0e}-\u{0d10}\u{0d12}-\u{0d28}\u{0d2a}-\u{0d39}\u{0d3e}-\u{0d40}\u{0d46}-\u{0d48}\u{0d4a}-\u{0d4c}\u{0d60}-\u{0d61}\u{0d66}-\u{0d6f}\u{0d82}-\u{0d83}\u{0d85}-\u{0d96}\u{0d9a}-\u{0db1}\u{0db3}-\u{0dbb}\u{0dc0}-\u{0dc6}\u{0dcf}-\u{0dd1}\u{0dd8}-\u{0ddf}\u{0df2}-\u{0df4}\u{0e01}-\u{0e30}\u{0e32}-\u{0e33}\u{0e40}-\u{0e46}\u{0e4f}-\u{0e5b}\u{0e81}-\u{0e82}\u{0e87}-\u{0e88}\u{0e94}-\u{0e97}\u{0e99}-\u{0e9f}\u{0ea1}-\u{0ea3}\u{0eaa}-\u{0eab}\u{0ead}-\u{0eb0}\u{0eb2}-\u{0eb3}\u{0ec0}-\u{0ec4}\u{0ed0}-\u{0ed9}\u{0edc}-\u{0edd}\u{0f00}-\u{0f17}\u{0f1a}-\u{0f34}\u{0f3e}-\u{0f47}\u{0f49}-\u{0f6a}\u{0f88}-\u{0f8b}\u{0fbe}-\u{0fc5}\u{0fc7}-\u{0fcc}\u{1000}-\u{1021}\u{1023}-\u{1027}\u{1029}-\u{102a}\u{1040}-\u{1057}\u{10a0}-\u{10c5}\u{10d0}-\u{10f8}\u{1100}-\u{1159}\u{115f}-\u{11a2}\u{11a8}-\u{11f9}\u{1200}-\u{1206}\u{1208}-\u{1246}\u{124a}-\u{124d}\u{1250}-\u{1256}\u{125a}-\u{125d}\u{1260}-\u{1286}\u{128a}-\u{128d}\u{1290}-\u{12ae}\u{12b2}-\u{12b5}\u{12b8}-\u{12be}\u{12c2}-\u{12c5}\u{12c8}-\u{12ce}\u{12d0}-\u{12d6}\u{12d8}-\u{12ee}\u{12f0}-\u{130e}\u{1312}-\u{1315}\u{1318}-\u{131e}\u{1320}-\u{1346}\u{1348}-\u{135a}\u{1361}-\u{137c}\u{13a0}-\u{13f4}\u{1401}-\u{1676}\u{1681}-\u{169a}\u{16a0}-\u{16f0}\u{1700}-\u{170c}\u{170e}-\u{1711}\u{1720}-\u{1731}\u{1735}-\u{1736}\u{1740}-\u{1751}\u{1760}-\u{176c}\u{176e}-\u{1770}\u{1780}-\u{17b6}\u{17be}-\u{17c5}\u{17c7}-\u{17c8}\u{17d4}-\u{17da}\u{17e0}-\u{17e9}\u{1810}-\u{1819}\u{1820}-\u{1877}\u{1880}-\u{18a8}\u{1e00}-\u{1e9b}\u{1ea0}-\u{1ef9}\u{1f00}-\u{1f15}\u{1f18}-\u{1f1d}\u{1f20}-\u{1f45}\u{1f48}-\u{1f4d}\u{1f50}-\u{1f57}\u{1f5f}-\u{1f7d}\u{1f80}-\u{1fb4}\u{1fb6}-\u{1fbc}\u{1fc2}-\u{1fc4}\u{1fc6}-\u{1fcc}\u{1fd0}-\u{1fd3}\u{1fd6}-\u{1fdb}\u{1fe0}-\u{1fec}\u{1ff2}-\u{1ff4}\u{1ff6}-\u{1ffc}\u{210a}-\u{2113}\u{2119}-\u{211d}\u{212a}-\u{212d}\u{212f}-\u{2131}\u{2133}-\u{2139}\u{213d}-\u{213f}\u{2145}-\u{2149}\u{2160}-\u{2183}\u{2336}-\u{237a}\u{249c}-\u{24e9}\u{3005}-\u{3007}\u{3021}-\u{3029}\u{3031}-\u{3035}\u{3038}-\u{303c}\u{3041}-\u{3096}\u{309d}-\u{309f}\u{30a1}-\u{30fa}\u{30fc}-\u{30ff}\u{3105}-\u{312c}\u{3131}-\u{318e}\u{3190}-\u{31b7}\u{31f0}-\u{321c}\u{3220}-\u{3243}\u{3260}-\u{327b}\u{327f}-\u{32b0}\u{32c0}-\u{32cb}\u{32d0}-\u{32fe}\u{3300}-\u{3376}\u{337b}-\u{33dd}\u{33e0}-\u{33fe}\u{3400}-\u{4db5}\u{4e00}-\u{9fa5}\u{a000}-\u{a48c}\u{ac00}-\u{d7a3}\u{e000}-\u{fa2d}\u{fa30}-\u{fa6a}\u{fb00}-\u{fb06}\u{fb13}-\u{fb17}\u{ff21}-\u{ff3a}\u{ff41}-\u{ff5a}\u{ff66}-\u{ffbe}\u{ffc2}-\u{ffc7}\u{ffca}-\u{ffcf}\u{ffd2}-\u{ffd7}\u{ffda}-\u{ffdc}\u{10300}-\u{1031e}\u{10320}-\u{10323}\u{10330}-\u{1034a}\u{10400}-\u{10425}\u{10428}-\u{1044d}\u{1d000}-\u{1d0f5}\u{1d100}-\u{1d126}\u{1d12a}-\u{1d166}\u{1d16a}-\u{1d172}\u{1d183}-\u{1d184}\u{1d18c}-\u{1d1a9}\u{1d1ae}-\u{1d1dd}\u{1d400}-\u{1d454}\u{1d456}-\u{1d49c}\u{1d49e}-\u{1d49f}\u{1d4a5}-\u{1d4a6}\u{1d4a9}-\u{1d4ac}\u{1d4ae}-\u{1d4b9}\u{1d4bd}-\u{1d4c0}\u{1d4c2}-\u{1d4c3}\u{1d4c5}-\u{1d505}\u{1d507}-\u{1d50a}\u{1d50d}-\u{1d514}\u{1d516}-\u{1d51c}\u{1d51e}-\u{1d539}\u{1d53b}-\u{1d53e}\u{1d540}-\u{1d544}\u{1d54a}-\u{1d550}\u{1d552}-\u{1d6a3}\u{1d6a8}-\u{1d7c9}\u{20000}-\u{2a6d6}\u{2f800}-\u{2fa1d}\u{f0000}-\u{ffffd}\u{100000}-\u{10fffd}\p{Cs}]).*?(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}])))|(?-mix:(?m-ix:\A(?-mix:[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]))|(?m-ix:(?-mix:[\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}]).*?(?-mix:[^\u{05be 05c0 05c3 061b 061f 06dd 0710 07b1 200f fb1d fb3e}\u{05d0}-\u{05ea}\u{05f0}-\u{05f4}\u{0621}-\u{063a}\u{0640}-\u{064a}\u{066d}-\u{066f}\u{0671}-\u{06d5}\u{06e5}-\u{06e6}\u{06fa}-\u{06fe}\u{0700}-\u{070d}\u{0712}-\u{072c}\u{0780}-\u{07a5}\u{fb1f}-\u{fb28}\u{fb2a}-\u{fb36}\u{fb38}-\u{fb3c}\u{fb40}-\u{fb41}\u{fb43}-\u{fb44}\u{fb46}-\u{fbb1}\u{fbd3}-\u{fd3d}\u{fd50}-\u{fd8f}\u{fd92}-\u{fdc7}\u{fdf0}-\u{fdfc}\u{fe70}-\u{fe74}\u{fe76}-\u{fefc}])\z))/.freeze + + # Names of each codepoint table in the RFC-3454 appendices + TITLES = { + "A.1" => "Unassigned code points in Unicode 3.2", + "B.1" => "Commonly mapped to nothing", + "B.2" => "Mapping for case-folding used with NFKC", + "B.3" => "Mapping for case-folding used with no normalization", + "C.1" => "Space characters", + "C.1.1" => "ASCII space characters", + "C.1.2" => "Non-ASCII space characters", + "C.2" => "Control characters", + "C.2.1" => "ASCII control characters", + "C.2.2" => "Non-ASCII control characters", + "C.3" => "Private use", + "C.4" => "Non-character code points", + "C.5" => "Surrogate codes", + "C.6" => "Inappropriate for plain text", + "C.7" => "Inappropriate for canonical representation", + "C.8" => "Change display properties or are deprecated", + "C.9" => "Tagging characters", + "D.1" => "Characters with bidirectional property \"R\" or \"AL\"", + "D.2" => "Characters with bidirectional property \"L\"", + }.freeze + + # Regexps matching each codepoint table in the RFC-3454 appendices + REGEXPS = { + "A.1" => IN_A_1, + "B.1" => IN_B_1, + "B.2" => IN_B_2, + "B.3" => IN_B_3, + "C.1.1" => IN_C_1_1, + "C.1.2" => IN_C_1_2, + "C.2.1" => IN_C_2_1, + "C.2.2" => IN_C_2_2, + "C.3" => IN_C_3, + "C.4" => IN_C_4, + "C.5" => IN_C_5, + "C.6" => IN_C_6, + "C.7" => IN_C_7, + "C.8" => IN_C_8, + "C.9" => IN_C_9, + "D.1" => IN_D_1, + "D.2" => IN_D_2, + }.freeze + + MAPPINGS = { + "B.1" => [IN_B_1, MAP_B_1].freeze, + "B.2" => [IN_B_2, MAP_B_2].freeze, + "B.3" => [IN_B_3, MAP_B_3].freeze, + }.freeze + + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/trace.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/trace.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/trace.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep/trace.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,85 @@ +# frozen_string_literal: true + +module Net + class IMAP + module StringPrep + + # Defined in RFC-4505[https://tools.ietf.org/html/rfc4505] §3, The +trace+ + # profile of \StringPrep is used by the +ANONYMOUS+ \SASL mechanism. + module Trace + + # Defined in RFC-4505[https://tools.ietf.org/html/rfc4505] §3. + STRINGPREP_PROFILE = "trace" + + # >>> + # The character repertoire of this profile is Unicode 3.2 [Unicode]. + UNASSIGNED_TABLE = "A.1" + + # >>> + # No mapping is required by this profile. + MAPPING_TABLES = nil + + # >>> + # No Unicode normalization is required by this profile. + NORMALIZATION = nil + + # From RFC-4505[https://tools.ietf.org/html/rfc4505] §3, The "trace" + # Profile of "Stringprep": + # >>> + # Characters from the following tables of [StringPrep] are prohibited: + # + # - C.2.1 (ASCII control characters) + # - C.2.2 (Non-ASCII control characters) + # - C.3 (Private use characters) + # - C.4 (Non-character code points) + # - C.5 (Surrogate codes) + # - C.6 (Inappropriate for plain text) + # - C.8 (Change display properties are deprecated) + # - C.9 (Tagging characters) + # + # No additional characters are prohibited. + PROHIBITED_TABLES = %w[C.2.1 C.2.2 C.3 C.4 C.5 C.6 C.8 C.9].freeze + + # >>> + # This profile requires bidirectional character checking per Section 6 + # of [StringPrep]. + CHECK_BIDI = true + + module_function + + # From RFC-4505[https://tools.ietf.org/html/rfc4505] §3, The "trace" + # Profile of "Stringprep": + # >>> + # The character repertoire of this profile is Unicode 3.2 [Unicode]. + # + # No mapping is required by this profile. + # + # No Unicode normalization is required by this profile. + # + # The list of unassigned code points for this profile is that provided + # in Appendix A of [StringPrep]. Unassigned code points are not + # prohibited. + # + # Characters from the following tables of [StringPrep] are prohibited: + # (documented on PROHIBITED_TABLES) + # + # This profile requires bidirectional character checking per Section 6 + # of [StringPrep]. + def stringprep_trace(string, **opts) + StringPrep.stringprep( + string, + unassigned: UNASSIGNED_TABLE, + maps: MAPPING_TABLES, + prohibited: PROHIBITED_TABLES, + normalization: NORMALIZATION, + bidi: CHECK_BIDI, + profile: STRINGPREP_PROFILE, + **opts, + ) + end + + end + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/stringprep.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,159 @@ +# frozen_string_literal: true + +module Net + class IMAP < Protocol + + # Regexps and utility methods for implementing stringprep profiles. The + # \StringPrep algorithm is defined by + # {RFC-3454}[https://www.rfc-editor.org/rfc/rfc3454.html]. Each + # codepoint table defined in the RFC-3454 appendices is matched by a Regexp + # defined in this module. + module StringPrep + autoload :NamePrep, File.expand_path("stringprep/nameprep", __dir__) + autoload :SASLprep, File.expand_path("stringprep/saslprep", __dir__) + autoload :Tables, File.expand_path("stringprep/tables", __dir__) + autoload :Trace, File.expand_path("stringprep/trace", __dir__) + + # ArgumentError raised when +string+ is invalid for the stringprep + # +profile+. + class StringPrepError < ArgumentError + attr_reader :string, :profile + + def initialize(*args, string: nil, profile: nil) + @string = -string.to_str unless string.nil? + @profile = -profile.to_str unless profile.nil? + super(*args) + end + end + + # StringPrepError raised when +string+ contains a codepoint prohibited by + # +table+. + class ProhibitedCodepoint < StringPrepError + attr_reader :table + + def initialize(table, *args, **kwargs) + @table = table + details = (title = Tables::TITLES[table]) ? + "%s [%s]" % [title, table] : table + message = "String contains a prohibited codepoint: %s" % [details] + super(message, *args, **kwargs) + end + end + + # StringPrepError raised when +string+ contains bidirectional characters + # which violate the StringPrep requirements. + class BidiStringError < StringPrepError + end + + # Returns a Regexp matching the given +table+ name. + def self.[](table) + Tables::REGEXPS.fetch(table) + end + + module_function + + # >>> + # 1. Map -- For each character in the input, check if it has a mapping + # and, if so, replace it with its mapping. This is described in + # section 3. + # + # 2. Normalize -- Possibly normalize the result of step 1 using Unicode + # normalization. This is described in section 4. + # + # 3. Prohibit -- Check for any characters that are not allowed in the + # output. If any are found, return an error. This is described in + # section 5. + # + # 4. Check bidi -- Possibly check for right-to-left characters, and if + # any are found, make sure that the whole string satisfies the + # requirements for bidirectional strings. If the string does not + # satisfy the requirements for bidirectional strings, return an + # error. This is described in section 6. + # + # The above steps MUST be performed in the order given to comply with + # this specification. + # + def stringprep(string, + maps:, + normalization:, + prohibited:, + **opts) + string = string.encode("UTF-8") # also dups (and raises invalid encoding) + map_tables!(string, *maps) if maps + string.unicode_normalize!(normalization) if normalization + check_prohibited!(string, *prohibited, **opts) if prohibited + string + end + + def map_tables!(string, *tables) + tables.each do |table| + regexp, replacements = Tables::MAPPINGS.fetch(table) + string.gsub!(regexp, replacements) + end + string + end + + # Checks +string+ for any codepoint in +tables+. Raises a + # ProhibitedCodepoint describing the first matching table. + # + # Also checks bidirectional characters, when bidi: true, which may + # raise a BidiStringError. + # + # +profile+ is an optional string which will be added to any exception that + # is raised (it does not affect behavior). + def check_prohibited!(string, + *tables, + bidi: false, + unassigned: "A.1", + stored: false, + profile: nil) + tables = Tables::TITLES.keys.grep(/^C/) if tables.empty? + tables |= [unassigned] if stored + tables |= %w[C.8] if bidi + table = tables.find {|t| + case t + when String then Tables::REGEXPS.fetch(t).match?(string) + when Regexp then t.match?(string) + else raise ArgumentError, "only table names and regexps can be checked" + end + } + if table + raise ProhibitedCodepoint.new( + table, string: string, profile: profile + ) + end + check_bidi!(string, profile: profile) if bidi + end + + # Checks that +string+ obeys all of the "Bidirectional Characters" + # requirements in RFC-3454, §6: + # + # * The characters in \StringPrep\[\"C.8\"] MUST be prohibited + # * If a string contains any RandALCat character, the string MUST NOT + # contain any LCat character. + # * If a string contains any RandALCat character, a RandALCat + # character MUST be the first character of the string, and a + # RandALCat character MUST be the last character of the string. + # + # This is usually combined with #check_prohibited!, so table "C.8" is only + # checked when c_8: true. + # + # Raises either ProhibitedCodepoint or BidiStringError unless all + # requirements are met. +profile+ is an optional string which will be + # added to any exception that is raised (it does not affect behavior). + def check_bidi!(string, c_8: false, profile: nil) + check_prohibited!(string, "C.8", profile: profile) if c_8 + if Tables::BIDI_FAILS_REQ2.match?(string) + raise BidiStringError.new( + Tables::BIDI_DESC_REQ2, string: string, profile: profile, + ) + elsif Tables::BIDI_FAILS_REQ3.match?(string) + raise BidiStringError.new( + Tables::BIDI_DESC_REQ3, string: string, profile: profile, + ) + end + end + + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/uidplus_data.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/uidplus_data.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap/uidplus_data.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap/uidplus_data.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,326 @@ +# frozen_string_literal: true + +module Net + class IMAP < Protocol + + # *NOTE:* UIDPlusData is deprecated and will be removed in the +0.6.0+ + # release. To use AppendUIDData and CopyUIDData before +0.6.0+, set + # Config#parser_use_deprecated_uidplus_data to +false+. + # + # UIDPlusData represents the ResponseCode#data that accompanies the + # +APPENDUID+ and +COPYUID+ {response codes}[rdoc-ref:ResponseCode]. + # + # A server that supports +UIDPLUS+ should send UIDPlusData in response to + # the append[rdoc-ref:Net::IMAP#append], copy[rdoc-ref:Net::IMAP#copy], + # move[rdoc-ref:Net::IMAP#move], {uid copy}[rdoc-ref:Net::IMAP#uid_copy], + # and {uid move}[rdoc-ref:Net::IMAP#uid_move] commands---unless the + # destination mailbox reports +UIDNOTSTICKY+. + # + # Note that append[rdoc-ref:Net::IMAP#append], copy[rdoc-ref:Net::IMAP#copy] + # and {uid_copy}[rdoc-ref:Net::IMAP#uid_copy] return UIDPlusData in their + # TaggedResponse. But move[rdoc-ref:Net::IMAP#copy] and + # {uid_move}[rdoc-ref:Net::IMAP#uid_move] _should_ send UIDPlusData in an + # UntaggedResponse response before sending their TaggedResponse. However + # some servers do send UIDPlusData in the TaggedResponse for +MOVE+ + # commands---this complies with the older +UIDPLUS+ specification but is + # discouraged by the +MOVE+ extension and disallowed by +IMAP4rev2+. + # + # == Required capability + # Requires either +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315]] + # or +IMAP4rev2+ capability. + # + class UIDPlusData < Struct.new(:uidvalidity, :source_uids, :assigned_uids) + ## + # method: uidvalidity + # :call-seq: uidvalidity -> nonzero uint32 + # + # The UIDVALIDITY of the destination mailbox. + + ## + # method: source_uids + # :call-seq: source_uids -> nil or an array of nonzero uint32 + # + # The UIDs of the copied or moved messages. + # + # Note:: Returns +nil+ for Net::IMAP#append. + + ## + # method: assigned_uids + # :call-seq: assigned_uids -> an array of nonzero uint32 + # + # The newly assigned UIDs of the copied, moved, or appended messages. + # + # Note:: This always returns an array, even when it contains only one UID. + + ## + # :call-seq: uid_mapping -> nil or a hash + # + # Returns a hash mapping each source UID to the newly assigned destination + # UID. + # + # Note:: Returns +nil+ for Net::IMAP#append. + def uid_mapping + source_uids&.zip(assigned_uids)&.to_h + end + end + + # This replaces the `Data.define` polyfill that's used by net-imap 0.5. + class Data_define__uidvalidity___assigned_uids_ # :no-doc: + attr_reader :uidvalidity, :assigned_uids + + def self.[](...) new(...) end + def self.new(uidvalidity = (args = false; nil), + assigned_uids = nil, + **kwargs) + if kwargs.empty? + super(uidvalidity: uidvalidity, assigned_uids: assigned_uids) + elsif !args + super + else + raise ArgumentError, "sent both positional and keyword args" + end + end + + def ==(other) + self.class == other.class && + self.uidvalidity == other.uidvalidity && + self.assigned_uids == other.assigned_uids + end + + def eql?(other) + self.class.eql?(other.class) && + self.uidvalidity.eql?(other.uidvalidity) && + self.assigned_uids.eql?(other.assigned_uids) + end + + def hash; [self.class, uidvalidity, assigned_uids].hash end + + def initialize(uidvalidity:, assigned_uids:) + @uidvalidity = uidvalidity + @assigned_uids = assigned_uids + freeze + end + end + + # >>> + # *NOTE:* AppendUIDData will replace UIDPlusData for +APPENDUID+ in the + # +0.6.0+ release. To use AppendUIDData before +0.6.0+, set + # Config#parser_use_deprecated_uidplus_data to +false+. + # + # AppendUIDData represents the ResponseCode#data that accompanies the + # +APPENDUID+ {response code}[rdoc-ref:ResponseCode]. + # + # A server that supports +UIDPLUS+ (or +IMAP4rev2+) should send + # AppendUIDData inside every TaggedResponse returned by the + # append[rdoc-ref:Net::IMAP#append] command---unless the target mailbox + # reports +UIDNOTSTICKY+. + # + # == Required capability + # Requires either +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315]] + # or +IMAP4rev2+ capability. + class AppendUIDData < Data_define__uidvalidity___assigned_uids_ + def initialize(uidvalidity:, assigned_uids:) + uidvalidity = Integer(uidvalidity) + assigned_uids = SequenceSet[assigned_uids] + NumValidator.ensure_nz_number(uidvalidity) + if assigned_uids.include_star? + raise DataFormatError, "uid-set cannot contain '*'" + end + super + end + + ## + # attr_reader: uidvalidity + # :call-seq: uidvalidity -> nonzero uint32 + # + # The UIDVALIDITY of the destination mailbox. + + ## + # attr_reader: assigned_uids + # + # A SequenceSet with the newly assigned UIDs of the appended messages. + + # Returns the number of messages that have been appended. + def size + assigned_uids.count_with_duplicates + end + end + + # This replaces the `Data.define` polyfill that's used by net-imap 0.5. + class Data_define__uidvalidity___source_uids___assigned_uids_ # :no-doc: + attr_reader :uidvalidity, :source_uids, :assigned_uids + + def self.[](...) new(...) end + def self.new(uidvalidity = (args = false; nil), + source_uids = nil, + assigned_uids = nil, + **kwargs) + if kwargs.empty? + super(uidvalidity: uidvalidity, + source_uids: source_uids, + assigned_uids: assigned_uids) + elsif !args + super(**kwargs) + else + raise ArgumentError, "sent both positional and keyword args" + end + end + + def initialize(uidvalidity:, source_uids:, assigned_uids:) + @uidvalidity = uidvalidity + @source_uids = source_uids + @assigned_uids = assigned_uids + freeze + end + + def ==(other) + self.class == other.class && + self.uidvalidity == other.uidvalidity && + self.source_uids == other.source_uids + self.assigned_uids == other.assigned_uids + end + + def eql?(other) + self.class.eql?(other.class) && + self.uidvalidity.eql?(other.uidvalidity) && + self.source_uids.eql?(other.source_uids) + self.assigned_uids.eql?(other.assigned_uids) + end + + def hash; [self.class, uidvalidity, source_uids, assigned_uids].hash end + end + + # >>> + # *NOTE:* CopyUIDData will replace UIDPlusData for +COPYUID+ in the + # +0.6.0+ release. To use CopyUIDData before +0.6.0+, set + # Config#parser_use_deprecated_uidplus_data to +false+. + # + # CopyUIDData represents the ResponseCode#data that accompanies the + # +COPYUID+ {response code}[rdoc-ref:ResponseCode]. + # + # A server that supports +UIDPLUS+ (or +IMAP4rev2+) should send CopyUIDData + # in response to + # copy[rdoc-ref:Net::IMAP#copy], {uid_copy}[rdoc-ref:Net::IMAP#uid_copy], + # move[rdoc-ref:Net::IMAP#copy], and {uid_move}[rdoc-ref:Net::IMAP#uid_move] + # commands---unless the destination mailbox reports +UIDNOTSTICKY+. + # + # Note that copy[rdoc-ref:Net::IMAP#copy] and + # {uid_copy}[rdoc-ref:Net::IMAP#uid_copy] return CopyUIDData in their + # TaggedResponse. But move[rdoc-ref:Net::IMAP#copy] and + # {uid_move}[rdoc-ref:Net::IMAP#uid_move] _should_ send CopyUIDData in an + # UntaggedResponse response before sending their TaggedResponse. However + # some servers do send CopyUIDData in the TaggedResponse for +MOVE+ + # commands---this complies with the older +UIDPLUS+ specification but is + # discouraged by the +MOVE+ extension and disallowed by +IMAP4rev2+. + # + # == Required capability + # Requires either +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315]] + # or +IMAP4rev2+ capability. + class CopyUIDData < Data_define__uidvalidity___source_uids___assigned_uids_ + def initialize(uidvalidity:, source_uids:, assigned_uids:) + uidvalidity = Integer(uidvalidity) + source_uids = SequenceSet[source_uids] + assigned_uids = SequenceSet[assigned_uids] + NumValidator.ensure_nz_number(uidvalidity) + if source_uids.include_star? || assigned_uids.include_star? + raise DataFormatError, "uid-set cannot contain '*'" + elsif source_uids.count_with_duplicates != assigned_uids.count_with_duplicates + raise DataFormatError, "mismatched uid-set sizes for %s and %s" % [ + source_uids, assigned_uids + ] + end + super + end + + ## + # attr_reader: uidvalidity + # + # The +UIDVALIDITY+ of the destination mailbox (a nonzero unsigned 32 bit + # integer). + + ## + # attr_reader: source_uids + # + # A SequenceSet with the original UIDs of the copied or moved messages. + + ## + # attr_reader: assigned_uids + # + # A SequenceSet with the newly assigned UIDs of the copied or moved + # messages. + + # Returns the number of messages that have been copied or moved. + # source_uids and the assigned_uids will both the same number of UIDs. + def size + assigned_uids.count_with_duplicates + end + + # :call-seq: + # assigned_uid_for(source_uid) -> uid + # self[source_uid] -> uid + # + # Returns the UID in the destination mailbox for the message that was + # copied from +source_uid+ in the source mailbox. + # + # This is the reverse of #source_uid_for. + # + # Related: source_uid_for, each_uid_pair, uid_mapping + def assigned_uid_for(source_uid) + idx = source_uids.find_ordered_index(source_uid) and + assigned_uids.ordered_at(idx) + end + alias :[] :assigned_uid_for + + # :call-seq: + # source_uid_for(assigned_uid) -> uid + # + # Returns the UID in the source mailbox for the message that was copied to + # +assigned_uid+ in the source mailbox. + # + # This is the reverse of #assigned_uid_for. + # + # Related: assigned_uid_for, each_uid_pair, uid_mapping + def source_uid_for(assigned_uid) + idx = assigned_uids.find_ordered_index(assigned_uid) and + source_uids.ordered_at(idx) + end + + # Yields a pair of UIDs for each copied message. The first is the + # message's UID in the source mailbox and the second is the UID in the + # destination mailbox. + # + # Returns an enumerator when no block is given. + # + # Please note the warning on uid_mapping before calling methods like + # +to_h+ or +to_a+ on the returned enumerator. + # + # Related: uid_mapping, assigned_uid_for, source_uid_for + def each_uid_pair + return enum_for(__method__) unless block_given? + source_uids.each_ordered_number.lazy + .zip(assigned_uids.each_ordered_number.lazy) do + |source_uid, assigned_uid| + yield source_uid, assigned_uid + end + end + alias each_pair each_uid_pair + alias each each_uid_pair + + # :call-seq: uid_mapping -> hash + # + # Returns a hash mapping each source UID to the newly assigned destination + # UID. + # + # *Warning:* The hash that is created may consume _much_ more + # memory than the data used to create it. When handling responses from an + # untrusted server, check #size before calling this method. + # + # Related: each_uid_pair, assigned_uid_for, source_uid_for + def uid_mapping + each_uid_pair.to_h + end + + end + + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/lib/net/imap.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/lib/net/imap.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,3273 @@ +# frozen_string_literal: true +# +# = net/imap.rb +# +# Copyright (C) 2000 Shugo Maeda +# +# This library is distributed under the terms of the Ruby license. +# You can freely distribute/modify this library. +# +# Documentation: Shugo Maeda, with RDoc conversion and overview by William +# Webber. +# +# See Net::IMAP for documentation. +# + +require "socket" +require "monitor" +require 'net/protocol' +begin + require "openssl" +rescue LoadError +end + +module Net + + # Net::IMAP implements Internet Message Access Protocol (\IMAP) client + # functionality. The protocol is described + # in {IMAP4rev1 [RFC3501]}[https://tools.ietf.org/html/rfc3501] + # and {IMAP4rev2 [RFC9051]}[https://tools.ietf.org/html/rfc9051]. + # + # == \IMAP Overview + # + # An \IMAP client connects to a server, and then authenticates + # itself using either #authenticate or #login. Having + # authenticated itself, there is a range of commands + # available to it. Most work with mailboxes, which may be + # arranged in an hierarchical namespace, and each of which + # contains zero or more messages. How this is implemented on + # the server is implementation-dependent; on a UNIX server, it + # will frequently be implemented as files in mailbox format + # within a hierarchy of directories. + # + # To work on the messages within a mailbox, the client must + # first select that mailbox, using either #select or #examine + # (for read-only access). Once the client has successfully + # selected a mailbox, they enter the +selected+ state, and that + # mailbox becomes the _current_ mailbox, on which mail-item + # related commands implicitly operate. + # + # === Connection state + # + # Once an IMAP connection is established, the connection is in one of four + # states: not authenticated, +authenticated+, +selected+, and + # +logout+. Most commands are valid only in certain states. + # + # === Sequence numbers and UIDs + # + # Messages have two sorts of identifiers: message sequence + # numbers and UIDs. + # + # Message sequence numbers number messages within a mailbox + # from 1 up to the number of items in the mailbox. If a new + # message arrives during a session, it receives a sequence + # number equal to the new size of the mailbox. If messages + # are expunged from the mailbox, remaining messages have their + # sequence numbers "shuffled down" to fill the gaps. + # + # To avoid sequence number race conditions, servers must not expunge messages + # when no command is in progress, nor when responding to #fetch, #store, or + # #search. Expunges _may_ be sent during any other command, including + # #uid_fetch, #uid_store, and #uid_search. The #noop and #idle commands are + # both useful for this side-effect: they allow the server to send all mailbox + # updates, including expunges. + # + # UIDs, on the other hand, are permanently guaranteed not to + # identify another message within the same mailbox, even if + # the existing message is deleted. UIDs are required to + # be assigned in ascending (but not necessarily sequential) + # order within a mailbox; this means that if a non-IMAP client + # rearranges the order of mail items within a mailbox, the + # UIDs have to be reassigned. An \IMAP client thus cannot + # rearrange message orders. + # + # === Examples of Usage + # + # ==== List sender and subject of all recent messages in the default mailbox + # + # imap = Net::IMAP.new('mail.example.com') + # imap.authenticate('PLAIN', 'joe_user', 'joes_password') + # imap.examine('INBOX') + # imap.search(["RECENT"]).each do |message_id| + # envelope = imap.fetch(message_id, "ENVELOPE")[0].attr["ENVELOPE"] + # puts "#{envelope.from[0].name}: \t#{envelope.subject}" + # end + # + # ==== Move all messages from April 2003 from "Mail/sent-mail" to "Mail/sent-apr03" + # + # imap = Net::IMAP.new('mail.example.com') + # imap.authenticate('PLAIN', 'joe_user', 'joes_password') + # imap.select('Mail/sent-mail') + # if not imap.list('Mail/', 'sent-apr03') + # imap.create('Mail/sent-apr03') + # end + # imap.search(["BEFORE", "30-Apr-2003", "SINCE", "1-Apr-2003"]).each do |message_id| + # imap.copy(message_id, "Mail/sent-apr03") + # imap.store(message_id, "+FLAGS", [:Deleted]) + # end + # imap.expunge + # + # == Capabilities + # + # Most Net::IMAP methods do not _currently_ modify their behaviour according + # to the server's advertised #capabilities. Users of this class must check + # that the server is capable of extension commands or command arguments before + # sending them. Special care should be taken to follow the #capabilities + # requirements for #starttls, #login, and #authenticate. + # + # See #capable?, #auth_capable?, #capabilities, #auth_mechanisms to discover + # server capabilities. For relevant capability requirements, see the + # documentation on each \IMAP command. + # + # imap = Net::IMAP.new("mail.example.com") + # imap.capable?(:IMAP4rev1) or raise "Not an IMAP4rev1 server" + # imap.capable?(:starttls) or raise "Cannot start TLS" + # imap.starttls + # + # if imap.auth_capable?("PLAIN") + # imap.authenticate "PLAIN", username, password + # elsif !imap.capability?("LOGINDISABLED") + # imap.login username, password + # else + # raise "No acceptable authentication mechanisms" + # end + # + # # Support for "UTF8=ACCEPT" implies support for "ENABLE" + # imap.enable :utf8 if imap.capable?("UTF8=ACCEPT") + # + # namespaces = imap.namespace if imap.capable?(:namespace) + # mbox_prefix = namespaces&.personal&.first&.prefix || "" + # mbox_delim = namespaces&.personal&.first&.delim || "/" + # mbox_path = prefix + %w[path to my mailbox].join(delim) + # imap.create mbox_path + # + # === Basic IMAP4rev1 capabilities + # + # IMAP4rev1 servers must advertise +IMAP4rev1+ in their capabilities list. + # IMAP4rev1 servers must _implement_ the +STARTTLS+, AUTH=PLAIN, + # and +LOGINDISABLED+ capabilities. See #starttls, #login, and #authenticate + # for the implications of these capabilities. + # + # === Caching +CAPABILITY+ responses + # + # Net::IMAP automatically stores and discards capability data according to the + # the requirements and recommendations in + # {IMAP4rev2 §6.1.1}[https://www.rfc-editor.org/rfc/rfc9051#section-6.1.1], + # {§6.2}[https://www.rfc-editor.org/rfc/rfc9051#section-6.2], and + # {§7.1}[https://www.rfc-editor.org/rfc/rfc9051#section-7.1]. + # Use #capable?, #auth_capable?, or #capabilities to use this cache and avoid + # sending the #capability command unnecessarily. + # + # The server may advertise its initial capabilities using the +CAPABILITY+ + # ResponseCode in a +PREAUTH+ or +OK+ #greeting. When TLS has started + # (#starttls) and after authentication (#login or #authenticate), the server's + # capabilities may change and cached capabilities are discarded. The server + # may send updated capabilities with an +OK+ TaggedResponse to #login or + # #authenticate, and these will be cached by Net::IMAP. But the + # TaggedResponse to #starttls MUST be ignored--it is sent before TLS starts + # and is unprotected. + # + # When storing capability values to variables, be careful that they are + # discarded or reset appropriately, especially following #starttls. + # + # === Using IMAP4rev1 extensions + # + # See the {IANA IMAP4 capabilities + # registry}[http://www.iana.org/assignments/imap4-capabilities] for a list of + # all standard capabilities, and their reference RFCs. + # + # IMAP4rev1 servers must not activate behavior that is incompatible with the + # base specification until an explicit client action invokes a capability, + # e.g. sending a command or command argument specific to that capability. + # Servers may send data with backward compatible behavior, such as response + # codes or mailbox attributes, at any time without client action. + # + # Invoking capabilities which are unknown to Net::IMAP may cause unexpected + # behavior and errors. For example, ResponseParseError is raised when + # unknown response syntax is received. Invoking commands or command + # parameters that are unsupported by the server may raise NoResponseError, + # BadResponseError, or cause other unexpected behavior. + # + # Some capabilities must be explicitly activated using the #enable command. + # See #enable for details. + # + # == Thread Safety + # + # Net::IMAP supports concurrent threads. For example, + # + # imap = Net::IMAP.new("imap.foo.net", "imap2") + # imap.authenticate("scram-md5", "bar", "password") + # imap.select("inbox") + # fetch_thread = Thread.start { imap.fetch(1..-1, "UID") } + # search_result = imap.search(["BODY", "hello"]) + # fetch_result = fetch_thread.value + # imap.disconnect + # + # This script invokes the FETCH command and the SEARCH command concurrently. + # + # When running multiple commands, care must be taken to avoid ambiguity. For + # example, SEARCH responses are ambiguous about which command they are + # responding to, so search commands should not run simultaneously, unless the + # server supports +ESEARCH+ {[RFC4731]}[https://rfc-editor.org/rfc/rfc4731] or + # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051]. See {RFC9051 + # §5.5}[https://www.rfc-editor.org/rfc/rfc9051.html#section-5.5] for + # other examples of command sequences which should not be pipelined. + # + # == Unbounded memory use + # + # Net::IMAP reads server responses in a separate receiver thread per client. + # Unhandled response data is saved to #responses, and response_handlers run + # inside the receiver thread. See the list of methods for {handling server + # responses}[rdoc-ref:Net::IMAP@Handling+server+responses], below. + # + # Because the receiver thread continuously reads and saves new responses, some + # scenarios must be careful to avoid unbounded memory use: + # + # * Commands such as #list or #fetch can have an enormous number of responses. + # * Commands such as #fetch can result in an enormous size per response. + # * Long-lived connections will gradually accumulate unsolicited server + # responses, especially +EXISTS+, +FETCH+, and +EXPUNGE+ responses. + # * A buggy or untrusted server could send inappropriate responses, which + # could be very numerous, very large, and very rapid. + # + # Use paginated or limited versions of commands whenever possible. + # + # Use Config#max_response_size to impose a limit on incoming server responses + # as they are being read. This is especially important for untrusted + # servers. + # + # Use #add_response_handler to handle responses after each one is received. + # Use the +response_handlers+ argument to ::new to assign response handlers + # before the receiver thread is started. Use #extract_responses, + # #clear_responses, or #responses (with a block) to prune responses. + # + # == Errors + # + # An \IMAP server can send three different types of responses to indicate + # failure: + # + # NO:: the attempted command could not be successfully completed. For + # instance, the username/password used for logging in are incorrect; + # the selected mailbox does not exist; etc. + # + # BAD:: the request from the client does not follow the server's + # understanding of the \IMAP protocol. This includes attempting + # commands from the wrong client state; for instance, attempting + # to perform a SEARCH command without having SELECTed a current + # mailbox. It can also signal an internal server + # failure (such as a disk crash) has occurred. + # + # BYE:: the server is saying goodbye. This can be part of a normal + # logout sequence, and can be used as part of a login sequence + # to indicate that the server is (for some reason) unwilling + # to accept your connection. As a response to any other command, + # it indicates either that the server is shutting down, or that + # the server is timing out the client connection due to inactivity. + # + # These three error response are represented by the errors + # Net::IMAP::NoResponseError, Net::IMAP::BadResponseError, and + # Net::IMAP::ByeResponseError, all of which are subclasses of + # Net::IMAP::ResponseError. Essentially, all methods that involve + # sending a request to the server can generate one of these errors. + # Only the most pertinent instances have been documented below. + # + # Because the IMAP class uses Sockets for communication, its methods + # are also susceptible to the various errors that can occur when + # working with sockets. These are generally represented as + # Errno errors. For instance, any method that involves sending a + # request to the server and/or receiving a response from it could + # raise an Errno::EPIPE error if the network connection unexpectedly + # goes down. See the socket(7), ip(7), tcp(7), socket(2), connect(2), + # and associated man pages. + # + # Finally, a Net::IMAP::DataFormatError is thrown if low-level data + # is found to be in an incorrect format (for instance, when converting + # between UTF-8 and UTF-16), and Net::IMAP::ResponseParseError is + # thrown if a server response is non-parseable. + # + # == What's here? + # + # * {Connection control}[rdoc-ref:Net::IMAP@Connection+control+methods] + # * {Server capabilities}[rdoc-ref:Net::IMAP@Server+capabilities] + # * {Handling server responses}[rdoc-ref:Net::IMAP@Handling+server+responses] + # * {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands] + # * {for any state}[rdoc-ref:Net::IMAP@Any+state] + # * {for the "not authenticated" state}[rdoc-ref:Net::IMAP@Not+Authenticated+state] + # * {for the "authenticated" state}[rdoc-ref:Net::IMAP@Authenticated+state] + # * {for the "selected" state}[rdoc-ref:Net::IMAP@Selected+state] + # * {for the "logout" state}[rdoc-ref:Net::IMAP@Logout+state] + # * {IMAP extension support}[rdoc-ref:Net::IMAP@IMAP+extension+support] + # + # === Connection control methods + # + # - Net::IMAP.new: Creates a new \IMAP client which connects immediately and + # waits for a successful server greeting before the method returns. + # - #connection_state: Returns the connection state. + # - #starttls: Asks the server to upgrade a clear-text connection to use TLS. + # - #logout: Tells the server to end the session. Enters the +logout+ state. + # - #disconnect: Disconnects the connection (without sending #logout first). + # - #disconnected?: True if the connection has been closed. + # + # === Server capabilities + # + # - #capable?: Returns whether the server supports a given capability. + # - #capabilities: Returns the server's capabilities as an array of strings. + # - #auth_capable?: Returns whether the server advertises support for a given + # SASL mechanism, for use with #authenticate. + # - #auth_mechanisms: Returns the #authenticate SASL mechanisms which + # the server claims to support as an array of strings. + # - #clear_cached_capabilities: Clears cached capabilities. + # + # The capabilities cache is automatically cleared after completing + # #starttls, #login, or #authenticate. + # - #capability: Sends the +CAPABILITY+ command and returns the #capabilities. + # + # In general, #capable? should be used rather than explicitly sending a + # +CAPABILITY+ command to the server. + # + # === Handling server responses + # + # - #greeting: The server's initial untagged response, which can indicate a + # pre-authenticated connection. + # - #responses: Yields unhandled UntaggedResponse#data and non-+nil+ + # ResponseCode#data. + # - #extract_responses: Removes and returns the responses for which the block + # returns a true value. + # - #clear_responses: Deletes unhandled data from #responses and returns it. + # - #add_response_handler: Add a block to be called inside the receiver thread + # with every server response. + # - #response_handlers: Returns the list of response handlers. + # - #remove_response_handler: Remove a previously added response handler. + # + # === Core \IMAP commands + # + # The following commands are defined either by + # the [IMAP4rev1[https://tools.ietf.org/html/rfc3501]] base specification, or + # by one of the following extensions: + # [IDLE[https://tools.ietf.org/html/rfc2177]], + # [NAMESPACE[https://tools.ietf.org/html/rfc2342]], + # [UNSELECT[https://tools.ietf.org/html/rfc3691]], + # [ENABLE[https://tools.ietf.org/html/rfc5161]], + # [MOVE[https://tools.ietf.org/html/rfc6851]]. + # These extensions are widely supported by modern IMAP4rev1 servers and have + # all been integrated into [IMAP4rev2[https://tools.ietf.org/html/rfc9051]]. + # *NOTE:* Net::IMAP doesn't support IMAP4rev2 yet. + # + # ==== Any state + # + # - #capability: Returns the server's capabilities as an array of strings. + # + # In general, #capable? should be used rather than explicitly sending a + # +CAPABILITY+ command to the server. + # - #noop: Allows the server to send unsolicited untagged #responses. + # - #logout: Tells the server to end the session. Enters the +logout+ state. + # + # ==== Not Authenticated state + # + # In addition to the commands for any state, the following commands are valid + # in the +not_authenticated+ state: + # + # - #starttls: Upgrades a clear-text connection to use TLS. + # + # Requires the +STARTTLS+ capability. + # - #authenticate: Identifies the client to the server using the given + # {SASL mechanism}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] + # and credentials. Enters the +authenticated+ state. + # + # The server should list "AUTH=#{mechanism}" capabilities for + # supported mechanisms. + # - #login: Identifies the client to the server using a plain text password. + # Using #authenticate is preferred. Enters the +authenticated+ state. + # + # The +LOGINDISABLED+ capability must NOT be listed. + # + # ==== Authenticated state + # + # In addition to the commands for any state, the following commands are valid + # in the +authenticated+ state: + # + # - #enable: Enables backwards incompatible server extensions. + # Requires the +ENABLE+ or +IMAP4rev2+ capability. + # - #select: Open a mailbox and enter the +selected+ state. + # - #examine: Open a mailbox read-only, and enter the +selected+ state. + # - #create: Creates a new mailbox. + # - #delete: Permanently remove a mailbox. + # - #rename: Change the name of a mailbox. + # - #subscribe: Adds a mailbox to the "subscribed" set. + # - #unsubscribe: Removes a mailbox from the "subscribed" set. + # - #list: Returns names and attributes of mailboxes matching a given pattern. + # - #namespace: Returns mailbox namespaces, with path prefixes and delimiters. + # Requires the +NAMESPACE+ or +IMAP4rev2+ capability. + # - #status: Returns mailbox information, e.g. message count, unseen message + # count, +UIDVALIDITY+ and +UIDNEXT+. + # - #append: Appends a message to the end of a mailbox. + # - #idle: Allows the server to send updates to the client, without the client + # needing to poll using #noop. + # Requires the +IDLE+ or +IMAP4rev2+ capability. + # - *Obsolete* #lsub: Replaced by LIST-EXTENDED and removed from + # +IMAP4rev2+. Lists mailboxes in the "subscribed" set. + # + # *Note:* Net::IMAP hasn't implemented LIST-EXTENDED yet. + # + # ==== Selected state + # + # In addition to the commands for any state and the +authenticated+ + # commands, the following commands are valid in the +selected+ state: + # + # - #close: Closes the mailbox and returns to the +authenticated+ state, + # expunging deleted messages, unless the mailbox was opened as read-only. + # - #unselect: Closes the mailbox and returns to the +authenticated+ state, + # without expunging any messages. + # Requires the +UNSELECT+ or +IMAP4rev2+ capability. + # - #expunge: Permanently removes messages which have the Deleted flag set. + # - #uid_expunge: Restricts expunge to only remove the specified UIDs. + # Requires the +UIDPLUS+ or +IMAP4rev2+ capability. + # - #search, #uid_search: Returns sequence numbers or UIDs of messages that + # match the given searching criteria. + # - #fetch, #uid_fetch: Returns data associated with a set of messages, + # specified by sequence number or UID. + # - #store, #uid_store: Alters a message's flags. + # - #copy, #uid_copy: Copies the specified messages to the end of the + # specified destination mailbox. + # - #move, #uid_move: Moves the specified messages to the end of the + # specified destination mailbox, expunging them from the current mailbox. + # Requires the +MOVE+ or +IMAP4rev2+ capability. + # - #check: *Obsolete:* removed from +IMAP4rev2+. + # Can be replaced with #noop or #idle. + # + # ==== Logout state + # + # No \IMAP commands are valid in the +logout+ state. If the socket is still + # open, Net::IMAP will close it after receiving server confirmation. + # Exceptions will be raised by \IMAP commands that have already started and + # are waiting for a response, as well as any that are called after logout. + # + # === \IMAP extension support + # + # ==== RFC9051: +IMAP4rev2+ + # + # Although IMAP4rev2[https://tools.ietf.org/html/rfc9051] is not supported + # yet, Net::IMAP supports several extensions that have been folded into it: + # +ENABLE+, +IDLE+, +MOVE+, +NAMESPACE+, +SASL-IR+, +UIDPLUS+, +UNSELECT+, + # STATUS=SIZE, and the fetch side of +BINARY+. + # Commands for these extensions are listed with the {Core IMAP + # commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands], above. + # + # >>> + # The following are folded into +IMAP4rev2+ but are currently + # unsupported or incompletely supported by Net::IMAP: RFC4466 + # extensions, +ESEARCH+, +SEARCHRES+, +LIST-EXTENDED+, +LIST-STATUS+, + # +LITERAL-+, and +SPECIAL-USE+. + # + # ==== RFC2087: +QUOTA+ + # +NOTE:+ Only the +STORAGE+ quota resource type is currently supported. + # - Obsoleted by QUOTA=RES-* [RFC9208[https://www.rfc-editor.org/rfc/rfc9208]], + # although the commands are backward compatible. + # - #getquota: returns the resource usage and limits for a quota root + # - #getquotaroot: returns the list of quota roots for a mailbox, as well as + # their resource usage and limits. + # - #setquota: sets the resource limits for a given quota root. + # + # ==== RFC2177: +IDLE+ + # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included + # above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. + # - #idle: Allows the server to send updates to the client, without the client + # needing to poll using #noop. + # + # ==== RFC2342: +NAMESPACE+ + # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included + # above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. + # - #namespace: Returns mailbox namespaces, with path prefixes and delimiters. + # + # ==== RFC2971: +ID+ + # - #id: exchanges client and server implementation information. + # + # ==== RFC3516: +BINARY+ + # The fetch side of +BINARY+ has been folded into + # IMAP4rev2[https://tools.ietf.org/html/rfc9051]. + # - Updates #fetch and #uid_fetch with the +BINARY+, +BINARY.PEEK+, and + # +BINARY.SIZE+ items. See FetchData#binary and FetchData#binary_size. + # + # >>> + # *NOTE:* The binary extension the #append command is _not_ supported yet. + # + # ==== RFC3691: +UNSELECT+ + # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included + # above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. + # - #unselect: Closes the mailbox and returns to the +authenticated+ state, + # without expunging any messages. + # + # ==== RFC4314: +ACL+ + # - #getacl: lists the authenticated user's access rights to a mailbox. + # - #setacl: sets the access rights for a user on a mailbox + # >>> + # *NOTE:* +DELETEACL+, +LISTRIGHTS+, and +MYRIGHTS+ are not supported yet. + # + # ==== RFC4315: +UIDPLUS+ + # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included + # above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. + # - #uid_expunge: Restricts #expunge to only remove the specified UIDs. + # - Updates #select, #examine with the +UIDNOTSTICKY+ ResponseCode + # - Updates #append with the +APPENDUID+ ResponseCode + # - Updates #copy, #move with the +COPYUID+ ResponseCode + # + # ==== RFC4959: +SASL-IR+ + # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051]. + # - Updates #authenticate with the option to send an initial response. + # + # ==== RFC5161: +ENABLE+ + # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included + # above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. + # - #enable: Enables backwards incompatible server extensions. + # + # ==== RFC5256: +SORT+ + # - #sort, #uid_sort: An alternate version of #search or #uid_search which + # sorts the results by specified keys. + # ==== RFC5256: +THREAD+ + # - #thread, #uid_thread: An alternate version of #search or #uid_search, + # which arranges the results into ordered groups or threads according to a + # chosen algorithm. + # + # ==== +X-GM-EXT-1+ + # +X-GM-EXT-1+ is a non-standard Gmail extension. See {Google's + # documentation}[https://developers.google.com/gmail/imap/imap-extensions]. + # - Updates #fetch and #uid_fetch with support for +X-GM-MSGID+ (unique + # message ID), +X-GM-THRID+ (thread ID), and +X-GM-LABELS+ (Gmail labels). + # - Updates #search with the +X-GM-RAW+ search attribute. + # - #xlist: replaced by +SPECIAL-USE+ attributes in #list responses. + # + # *NOTE:* The +OBJECTID+ extension should replace +X-GM-MSGID+ and + # +X-GM-THRID+, but Gmail does not support it (as of 2023-11-10). + # + # ==== RFC6851: +MOVE+ + # Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included + # above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. + # - #move, #uid_move: Moves the specified messages to the end of the + # specified destination mailbox, expunging them from the current mailbox. + # + # ==== RFC6855: UTF8=ACCEPT, UTF8=ONLY + # + # - See #enable for information about support for UTF-8 string encoding. + # + # ==== RFC7162: +CONDSTORE+ + # + # - Updates #enable with +CONDSTORE+ parameter. +CONDSTORE+ will also be + # enabled by using any of the extension's command parameters, listed below. + # - Updates #status with the +HIGHESTMODSEQ+ status attribute. + # - Updates #select and #examine with the +condstore+ modifier, and adds + # either a +HIGHESTMODSEQ+ or +NOMODSEQ+ ResponseCode to the responses. + # - Updates #search, #uid_search, #sort, and #uid_sort with the +MODSEQ+ + # search criterion, and adds SearchResult#modseq to the search response. + # - Updates #thread and #uid_thread with the +MODSEQ+ search criterion + # (but thread responses are unchanged). + # - Updates #fetch and #uid_fetch with the +changedsince+ modifier and + # +MODSEQ+ FetchData attribute. + # - Updates #store and #uid_store with the +unchangedsince+ modifier and adds + # the +MODIFIED+ ResponseCode to the tagged response. + # + # ==== RFC8438: STATUS=SIZE + # - Updates #status with the +SIZE+ status attribute. + # + # ==== RFC8474: +OBJECTID+ + # - Adds +MAILBOXID+ ResponseCode to #create tagged response. + # - Adds +MAILBOXID+ ResponseCode to #select and #examine untagged response. + # - Updates #fetch and #uid_fetch with the +EMAILID+ and +THREADID+ items. + # See FetchData#emailid and FetchData#emailid. + # - Updates #status with support for the +MAILBOXID+ status attribute. + # + # ==== RFC9208: QUOTA=RES-* + # +NOTE:+ Only the +STORAGE+ quota resource type is currently supported. + # - Obsoletes the +QUOTA+ [RFC2087[https://www.rfc-editor.org/rfc/rfc2087]] + # extension and provides strict semantics for different resource types. + # - #getquota: returns the resource usage and limits for a quota root + # - #getquotaroot: returns the list of quota roots for a mailbox, as well as + # their resource usage and limits. + # - #setquota: sets the resource limits for a given quota root. + # - Updates #status with "DELETED" and +DELETED-STORAGE+ attributes. + # + # == References + # + # [{IMAP4rev1}[https://www.rfc-editor.org/rfc/rfc3501.html]]:: + # Crispin, M., "INTERNET MESSAGE ACCESS PROTOCOL - \VERSION 4rev1", + # RFC 3501, DOI 10.17487/RFC3501, March 2003, + # . + # + # [IMAP-ABNF-EXT[https://www.rfc-editor.org/rfc/rfc4466.html]]:: + # Melnikov, A. and C. Daboo, "Collected Extensions to IMAP4 ABNF", + # RFC 4466, DOI 10.17487/RFC4466, April 2006, + # . + # + # Note: Net::IMAP cannot parse the entire RFC4466 grammar yet. + # + # [{IMAP4rev2}[https://www.rfc-editor.org/rfc/rfc9051.html]]:: + # Melnikov, A., Ed., and B. Leiba, Ed., "Internet Message Access Protocol + # (\IMAP) - Version 4rev2", RFC 9051, DOI 10.17487/RFC9051, August 2021, + # . + # + # Note: Net::IMAP is not fully compatible with IMAP4rev2 yet. + # + # [IMAP-IMPLEMENTATION[https://www.rfc-editor.org/info/rfc2683]]:: + # Leiba, B., "IMAP4 Implementation Recommendations", + # RFC 2683, DOI 10.17487/RFC2683, September 1999, + # . + # + # [IMAP-MULTIACCESS[https://www.rfc-editor.org/info/rfc2180]]:: + # Gahrns, M., "IMAP4 Multi-Accessed Mailbox Practice", RFC 2180, DOI + # 10.17487/RFC2180, July 1997, . + # + # [UTF7[https://tools.ietf.org/html/rfc2152]]:: + # Goldsmith, D. and M. Davis, "UTF-7 A Mail-Safe Transformation Format of + # Unicode", RFC 2152, DOI 10.17487/RFC2152, May 1997, + # . + # + # === Message envelope and body structure + # + # [RFC5322[https://tools.ietf.org/html/rfc5322]]:: + # Resnick, P., Ed., "Internet Message Format", + # RFC 5322, DOI 10.17487/RFC5322, October 2008, + # . + # + # Note: obsoletes + # RFC-2822[https://tools.ietf.org/html/rfc2822] (April 2001) and + # RFC-822[https://tools.ietf.org/html/rfc822] (August 1982). + # + # [CHARSET[https://tools.ietf.org/html/rfc2978]]:: + # Freed, N. and J. Postel, "IANA Charset Registration Procedures", BCP 19, + # RFC 2978, DOI 10.17487/RFC2978, October 2000, + # . + # + # [DISPOSITION[https://tools.ietf.org/html/rfc2183]]:: + # Troost, R., Dorner, S., and K. Moore, Ed., "Communicating Presentation + # Information in Internet Messages: The Content-Disposition Header + # Field", RFC 2183, DOI 10.17487/RFC2183, August 1997, + # . + # + # [MIME-IMB[https://tools.ietf.org/html/rfc2045]]:: + # Freed, N. and N. Borenstein, "Multipurpose Internet Mail Extensions + # (MIME) Part One: Format of Internet Message Bodies", + # RFC 2045, DOI 10.17487/RFC2045, November 1996, + # . + # + # [MIME-IMT[https://tools.ietf.org/html/rfc2046]]:: + # Freed, N. and N. Borenstein, "Multipurpose Internet Mail Extensions + # (MIME) Part Two: Media Types", RFC 2046, DOI 10.17487/RFC2046, + # November 1996, . + # + # [MIME-HDRS[https://tools.ietf.org/html/rfc2047]]:: + # Moore, K., "MIME (Multipurpose Internet Mail Extensions) Part Three: + # Message Header Extensions for Non-ASCII Text", + # RFC 2047, DOI 10.17487/RFC2047, November 1996, + # . + # + # [RFC2231[https://tools.ietf.org/html/rfc2231]]:: + # Freed, N. and K. Moore, "MIME Parameter Value and Encoded Word + # Extensions: Character Sets, Languages, and Continuations", + # RFC 2231, DOI 10.17487/RFC2231, November 1997, + # . + # + # [I18n-HDRS[https://tools.ietf.org/html/rfc6532]]:: + # Yang, A., Steele, S., and N. Freed, "Internationalized Email Headers", + # RFC 6532, DOI 10.17487/RFC6532, February 2012, + # . + # + # [LANGUAGE-TAGS[https://www.rfc-editor.org/info/rfc3282]]:: + # Alvestrand, H., "Content Language Headers", + # RFC 3282, DOI 10.17487/RFC3282, May 2002, + # . + # + # [LOCATION[https://www.rfc-editor.org/info/rfc2557]]:: + # Palme, J., Hopmann, A., and N. Shelness, "MIME Encapsulation of + # Aggregate Documents, such as HTML (MHTML)", + # RFC 2557, DOI 10.17487/RFC2557, March 1999, + # . + # + # [MD5[https://tools.ietf.org/html/rfc1864]]:: + # Myers, J. and M. Rose, "The Content-MD5 Header Field", + # RFC 1864, DOI 10.17487/RFC1864, October 1995, + # . + # + # [RFC3503[https://tools.ietf.org/html/rfc3503]]:: + # Melnikov, A., "Message Disposition Notification (MDN) + # profile for Internet Message Access Protocol (IMAP)", + # RFC 3503, DOI 10.17487/RFC3503, March 2003, + # . + # + # === \IMAP Extensions + # + # [QUOTA[https://www.rfc-editor.org/rfc/rfc2087]]:: + # Myers, J., "IMAP4 QUOTA extension", RFC 2087, DOI 10.17487/RFC2087, + # January 1997, . + # + # *NOTE*: _obsoleted_ by RFC9208[https://www.rfc-editor.org/rfc/rfc9208] + # (March 2022). + # [IDLE[https://www.rfc-editor.org/rfc/rfc2177]]:: + # Leiba, B., "IMAP4 IDLE command", RFC 2177, DOI 10.17487/RFC2177, + # June 1997, . + # [NAMESPACE[https://tools.ietf.org/html/rfc2342]]:: + # Gahrns, M. and C. Newman, "IMAP4 Namespace", RFC 2342, + # DOI 10.17487/RFC2342, May 1998, . + # [ID[https://tools.ietf.org/html/rfc2971]]:: + # Showalter, T., "IMAP4 ID extension", RFC 2971, DOI 10.17487/RFC2971, + # October 2000, . + # [BINARY[https://tools.ietf.org/html/rfc3516]]:: + # Nerenberg, L., "IMAP4 Binary Content Extension", RFC 3516, + # DOI 10.17487/RFC3516, April 2003, + # . + # [ACL[https://tools.ietf.org/html/rfc4314]]:: + # Melnikov, A., "IMAP4 Access Control List (ACL) Extension", RFC 4314, + # DOI 10.17487/RFC4314, December 2005, + # . + # [UIDPLUS[https://www.rfc-editor.org/rfc/rfc4315.html]]:: + # Crispin, M., "Internet Message Access Protocol (\IMAP) - UIDPLUS + # extension", RFC 4315, DOI 10.17487/RFC4315, December 2005, + # . + # [SORT[https://tools.ietf.org/html/rfc5256]]:: + # Crispin, M. and K. Murchison, "Internet Message Access Protocol - SORT and + # THREAD Extensions", RFC 5256, DOI 10.17487/RFC5256, June 2008, + # . + # [THREAD[https://tools.ietf.org/html/rfc5256]]:: + # Crispin, M. and K. Murchison, "Internet Message Access Protocol - SORT and + # THREAD Extensions", RFC 5256, DOI 10.17487/RFC5256, June 2008, + # . + # [RFC5530[https://www.rfc-editor.org/rfc/rfc5530.html]]:: + # Gulbrandsen, A., "IMAP Response Codes", RFC 5530, DOI 10.17487/RFC5530, + # May 2009, . + # [MOVE[https://tools.ietf.org/html/rfc6851]]:: + # Gulbrandsen, A. and N. Freed, Ed., "Internet Message Access Protocol + # (\IMAP) - MOVE Extension", RFC 6851, DOI 10.17487/RFC6851, January 2013, + # . + # [UTF8=ACCEPT[https://tools.ietf.org/html/rfc6855]]:: + # [UTF8=ONLY[https://tools.ietf.org/html/rfc6855]]:: + # Resnick, P., Ed., Newman, C., Ed., and S. Shen, Ed., + # "IMAP Support for UTF-8", RFC 6855, DOI 10.17487/RFC6855, March 2013, + # . + # [CONDSTORE[https://tools.ietf.org/html/rfc7162]]:: + # [QRESYNC[https://tools.ietf.org/html/rfc7162]]:: + # Melnikov, A. and D. Cridland, "IMAP Extensions: Quick Flag Changes + # Resynchronization (CONDSTORE) and Quick Mailbox Resynchronization + # (QRESYNC)", RFC 7162, DOI 10.17487/RFC7162, May 2014, + # . + # [OBJECTID[https://tools.ietf.org/html/rfc8474]]:: + # Gondwana, B., Ed., "IMAP Extension for Object Identifiers", + # RFC 8474, DOI 10.17487/RFC8474, September 2018, + # . + # [{QUOTA=RES-*}[https://www.rfc-editor.org/rfc/rfc9208]]:: + # Melnikov, A., "IMAP QUOTA Extension", RFC 9208, DOI 10.17487/RFC9208, + # March 2022, . + # + # Obsoletes RFC2087[https://www.rfc-editor.org/rfc/rfc2087]. + # + # === IANA registries + # * {IMAP Capabilities}[http://www.iana.org/assignments/imap4-capabilities] + # * {IMAP Quota Resource Types}[http://www.iana.org/assignments/imap4-capabilities#imap-capabilities-2] + # * {IMAP Response Codes}[https://www.iana.org/assignments/imap-response-codes/imap-response-codes.xhtml] + # * {IMAP Mailbox Name Attributes}[https://www.iana.org/assignments/imap-mailbox-name-attributes/imap-mailbox-name-attributes.xhtml] + # * {IMAP and JMAP Keywords}[https://www.iana.org/assignments/imap-jmap-keywords/imap-jmap-keywords.xhtml] + # * {IMAP Threading Algorithms}[https://www.iana.org/assignments/imap-threading-algorithms/imap-threading-algorithms.xhtml] + # * {SASL Mechanisms and SASL SCRAM Family Mechanisms}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] + # * {Service Name and Transport Protocol Port Number Registry}[https://www.iana.org/assignments/service-names-port-numbers/service-names-port-numbers.xml]: + # +imap+: tcp/143, +imaps+: tcp/993 + # * {GSSAPI/Kerberos/SASL Service Names}[https://www.iana.org/assignments/gssapi-service-names/gssapi-service-names.xhtml]: + # +imap+ + # * {Character sets}[https://www.iana.org/assignments/character-sets/character-sets.xhtml] + # ===== For currently unsupported features: + # * {IMAP Quota Resource Types}[http://www.iana.org/assignments/imap4-capabilities#imap-capabilities-2] + # * {LIST-EXTENDED options and responses}[https://www.iana.org/assignments/imap-list-extended/imap-list-extended.xhtml] + # * {IMAP METADATA Server Entry and Mailbox Entry Registries}[https://www.iana.org/assignments/imap-metadata/imap-metadata.xhtml] + # * {IMAP ANNOTATE Extension Entries and Attributes}[https://www.iana.org/assignments/imap-annotate-extension/imap-annotate-extension.xhtml] + # * {IMAP URLAUTH Access Identifiers and Prefixes}[https://www.iana.org/assignments/urlauth-access-ids/urlauth-access-ids.xhtml] + # * {IMAP URLAUTH Authorization Mechanism Registry}[https://www.iana.org/assignments/urlauth-authorization-mechanism-registry/urlauth-authorization-mechanism-registry.xhtml] + # + class IMAP < Protocol + VERSION = "0.4.25" + + # Aliases for supported capabilities, to be used with the #enable command. + ENABLE_ALIASES = { + utf8: "UTF8=ACCEPT", + "UTF8=ONLY" => "UTF8=ACCEPT", + }.freeze + + autoload :ResponseReader, File.expand_path("imap/response_reader", __dir__) + autoload :SASL, File.expand_path("imap/sasl", __dir__) + autoload :SASLAdapter, File.expand_path("imap/sasl_adapter", __dir__) + autoload :StringPrep, File.expand_path("imap/stringprep", __dir__) + + include MonitorMixin + if defined?(OpenSSL::SSL) + include OpenSSL + include SSL + end + + # Returns the global Config object + def self.config; Config.global end + + # Returns the global debug mode. + # Delegates to {Net::IMAP.config.debug}[rdoc-ref:Config#debug]. + def self.debug; config.debug end + + # Sets the global debug mode. + # Delegates to {Net::IMAP.config.debug=}[rdoc-ref:Config#debug=]. + def self.debug=(val) + config.debug = val + end + + # The default port for IMAP connections, port 143 + def self.default_port + return PORT + end + + # The default port for IMAPS connections, port 993 + def self.default_tls_port + return SSL_PORT + end + + class << self + alias default_imap_port default_port + alias default_imaps_port default_tls_port + alias default_ssl_port default_tls_port + end + + # Returns the initial greeting sent by the server, an UntaggedResponse. + attr_reader :greeting + + # The client configuration. See Net::IMAP::Config. + # + # By default, the client's local configuration inherits from the global + # Net::IMAP.config. + attr_reader :config + + ## + # :attr_reader: open_timeout + # Seconds to wait until a connection is opened. Also used by #starttls. + # Delegates to {config.open_timeout}[rdoc-ref:Config#open_timeout]. + + ## + # :attr_reader: idle_response_timeout + # Seconds to wait until an IDLE response is received. + # Delegates to {config.idle_response_timeout}[rdoc-ref:Config#idle_response_timeout]. + + ## + # :attr_accessor: max_response_size + # + # The maximum allowed server response size, in bytes. + # Delegates to {config.max_response_size}[rdoc-ref:Config#max_response_size]. + + # :stopdoc: + def open_timeout; config.open_timeout end + def idle_response_timeout; config.idle_response_timeout end + def max_response_size; config.max_response_size end + def max_response_size=(val) config.max_response_size = val end + # :startdoc: + + # The hostname this client connected to + attr_reader :host + + # The port this client connected to + attr_reader :port + + # Returns the + # {SSLContext}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html] + # used by the SSLSocket when TLS is attempted, even when the TLS handshake + # is unsuccessful. The context object will be frozen. + # + # Returns +nil+ for a plaintext connection. + attr_reader :ssl_ctx + + # Returns the parameters that were sent to #ssl_ctx + # {set_params}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-set_params] + # when the connection tries to use TLS (even when unsuccessful). + # + # Returns +false+ for a plaintext connection. + attr_reader :ssl_ctx_params + + # Creates a new Net::IMAP object and connects it to the specified + # +host+. + # + # ==== Options + # + # Accepts the following options: + # + # [port] + # Port number. Defaults to 993 when +ssl+ is truthy, and 143 otherwise. + # + # [ssl] + # If +true+, the connection will use TLS with the default params set by + # {OpenSSL::SSL::SSLContext#set_params}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-set_params]. + # If +ssl+ is a hash, it's passed to + # {OpenSSL::SSL::SSLContext#set_params}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-set_params]; + # the keys are names of attribute assignment methods on + # SSLContext[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html]. For example: + # + # [{ca_file}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#attribute-i-ca_file]] + # The path to a file containing a PEM-format CA certificate. + # [{ca_path}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#attribute-i-ca_path]] + # The path to a directory containing CA certificates in PEM format. + # [{min_version}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-min_version-3D]] + # Sets the lower bound on the supported SSL/TLS protocol version. Set to + # an +OpenSSL+ constant such as +OpenSSL::SSL::TLS1_2_VERSION+, + # [{verify_mode}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#attribute-i-verify_mode]] + # SSL session verification mode. Valid modes include + # +OpenSSL::SSL::VERIFY_PEER+ and +OpenSSL::SSL::VERIFY_NONE+. + # + # See {OpenSSL::SSL::SSLContext}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html] for other valid SSL context params. + # + # See DeprecatedClientOptions.new for deprecated SSL arguments. + # + # [response_handlers] + # A list of response handlers to be added before the receiver thread is + # started. This ensures every server response is handled, including the + # #greeting. Note that the greeting is handled in the current thread, but + # all other responses are handled in the receiver thread. + # + # [config] + # A Net::IMAP::Config object to use as the basis for #config. By default, + # the global Net::IMAP.config is used. + # + # >>> + # *NOTE:* +config+ does not set #config directly---it sets the _parent_ + # config for inheritance. Every client creates its own unique #config. + # + # All other keyword arguments are forwarded to Net::IMAP::Config.new, to + # initialize the client's #config. For example: + # + # [{open_timeout}[rdoc-ref:Config#open_timeout]] + # Seconds to wait until a connection is opened + # [{idle_response_timeout}[rdoc-ref:Config#idle_response_timeout]] + # Seconds to wait until an IDLE response is received + # + # See Net::IMAP::Config for other valid options. + # + # ==== Examples + # + # Connect to cleartext port 143 at mail.example.com and receive the server greeting: + # imap = Net::IMAP.new('mail.example.com', ssl: false) # => # + # imap.port => 143 + # imap.tls_verified? => false + # imap.greeting => name: ("OK" | "PREAUTH") => status + # status # => "OK" + # # The client is connected in the "Not Authenticated" state. + # + # Connect with TLS to port 993 + # imap = Net::IMAP.new('mail.example.com', ssl: true) # => # + # imap.port => 993 + # imap.tls_verified? => true + # imap.greeting => name: (/OK/i | /PREAUTH/i) => status + # case status + # in /OK/i + # # The client is connected in the "Not Authenticated" state. + # imap.authenticate("PLAIN", "joe_user", "joes_password") + # in /PREAUTH/i + # # The client is connected in the "Authenticated" state. + # end + # + # Connect with prior authentication, for example using an SSL certificate: + # ssl_ctx_params = { + # cert: OpenSSL::X509::Certificate.new(File.read("client.crt")), + # key: OpenSSL::PKey::EC.new(File.read('client.key')), + # extra_chain_cert: [ + # OpenSSL::X509::Certificate.new(File.read("intermediate.crt")), + # ], + # } + # imap = Net::IMAP.new('mail.example.com', ssl: ssl_ctx_params) + # imap.port => 993 + # imap.tls_verified? => true + # imap.greeting => name: "PREAUTH" + # # The client is connected in the "Authenticated" state. + # + # ==== Exceptions + # + # The most common errors are: + # + # [Errno::ECONNREFUSED] + # Connection refused by +host+ or an intervening firewall. + # [Errno::ETIMEDOUT] + # Connection timed out (possibly due to packets being dropped by an + # intervening firewall). + # [Errno::ENETUNREACH] + # There is no route to that network. + # [SocketError] + # Hostname not known or other socket error. + # [Net::IMAP::ByeResponseError] + # Connected to the host successfully, but it immediately said goodbye. + # + def initialize(host, port: nil, ssl: nil, response_handlers: nil, + config: Config.global, **config_options) + super() + # Config options + @host = host + @config = Config.new(config, **config_options) + @port = port || (ssl ? SSL_PORT : PORT) + @ssl_ctx_params, @ssl_ctx = build_ssl_ctx(ssl) + + # Basic Client State + @utf8_strings = false + @debug_output_bol = true + @exception = nil + @greeting = nil + @capabilities = nil + + # Client Protocol Receiver + @parser = ResponseParser.new(config: @config) + @responses = Hash.new {|h, k| h[k] = [] } + @response_handlers = [] + @receiver_thread = nil + @receiver_thread_exception = nil + @receiver_thread_terminating = false + response_handlers&.each do add_response_handler(_1) end + + # Client Protocol Sender (including state for currently running commands) + @tag_prefix = "RUBY" + @tagno = 0 + @tagged_responses = {} + @tagged_response_arrival = new_cond + @continued_command_tag = nil + @continuation_request_arrival = new_cond + @continuation_request_exception = nil + @idle_done_cond = nil + @logout_command_tag = nil + + # Connection + @tls_verified = false + @sock = tcp_socket(@host, @port) + @reader = ResponseReader.new(self, @sock) + start_tls_session if ssl_ctx + start_imap_connection + + # DEPRECATED: to remove in next version + @client_thread = Thread.current + end + + # Returns true after the TLS negotiation has completed and the remote + # hostname has been verified. Returns false when TLS has been established + # but peer verification was disabled. + def tls_verified?; @tls_verified end + + def client_thread # :nodoc: + warn "Net::IMAP#client_thread is deprecated and will be removed soon." + @client_thread + end + + # Disconnects from the server. + # + # Waits for receiver thread to close before returning. Slow or stuck + # response handlers can cause #disconnect to hang until they complete. + # + # Related: #logout, #logout! + def disconnect + return if disconnected? + in_receiver_thread = Thread.current == @receiver_thread + begin + @sock.to_io.shutdown + rescue Errno::ENOTCONN + # ignore `Errno::ENOTCONN: Socket is not connected' on some platforms. + rescue Exception => e + @receiver_thread.raise(e) unless in_receiver_thread + end + @sock.close + @receiver_thread.join unless mon_owned? || in_receiver_thread + raise e if e + end + + # Returns true if disconnected from the server. + # + # Related: #logout, #disconnect + def disconnected? + return @sock.closed? + end + + # Returns whether the server supports a given +capability+. When available, + # cached #capabilities are used without sending a new #capability command to + # the server. + # + # *NOTE:* Most Net::IMAP methods do not _currently_ modify their + # behaviour according to the server's advertised #capabilities. + # + # See Net::IMAP@Capabilities for more about \IMAP capabilities. + # + # Related: #auth_capable?, #capabilities, #capability, #enable + def capable?(capability) capabilities.include? capability.to_s.upcase end + alias capability? capable? + + # Returns the server capabilities. When available, cached capabilities are + # used without sending a new #capability command to the server. + # + # To ensure a case-insensitive comparison, #capable? can be used instead. + # + # *NOTE:* Most Net::IMAP methods do not _currently_ modify their + # behaviour according to the server's advertised #capabilities. + # + # See Net::IMAP@Capabilities for more about \IMAP capabilities. + # + # Related: #capable?, #auth_capable?, #auth_mechanisms, #capability, #enable + def capabilities + @capabilities || capability + end + + # Returns the #authenticate mechanisms that the server claims to support. + # These are derived from the #capabilities with an AUTH= prefix. + # + # This may be different when the connection is cleartext or using TLS. Most + # servers will drop all AUTH= mechanisms from #capabilities after + # the connection has authenticated. + # + # imap = Net::IMAP.new(hostname, ssl: false) + # imap.capabilities # => ["IMAP4REV1", "LOGINDISABLED"] + # imap.auth_mechanisms # => [] + # + # imap.starttls + # imap.capabilities # => ["IMAP4REV1", "AUTH=PLAIN", "AUTH=XOAUTH2", + # # "AUTH=OAUTHBEARER"] + # imap.auth_mechanisms # => ["PLAIN", "XOAUTH2", "OAUTHBEARER"] + # + # imap.authenticate("XOAUTH2", username, oauth2_access_token) + # imap.auth_mechanisms # => [] + # + # Related: #authenticate, #auth_capable?, #capabilities + def auth_mechanisms + capabilities + .grep(/\AAUTH=/i) + .map { _1.delete_prefix("AUTH=") } + end + + # Returns whether the server supports a given SASL +mechanism+ for use with + # the #authenticate command. The +mechanism+ is supported when + # #capabilities includes "AUTH=#{mechanism.to_s.upcase}". When + # available, cached capabilities are used without sending a new #capability + # command to the server. + # + # imap.capable? "AUTH=PLAIN" # => true + # imap.auth_capable? "PLAIN" # => true + # imap.auth_capable? "blurdybloop" # => false + # + # Related: #authenticate, #auth_mechanisms, #capable?, #capabilities + def auth_capable?(mechanism) + capable? "AUTH=#{mechanism}" + end + + # Returns whether capabilities have been cached. When true, #capable? and + # #capabilities don't require sending a #capability command to the server. + # + # See Net::IMAP@Capabilities for more about \IMAP capabilities. + # + # Related: #capable?, #capability, #clear_cached_capabilities + def capabilities_cached? + !!@capabilities + end + + # Clears capabilities that have been remembered by the Net::IMAP client. + # This forces a #capability command to be sent the next time a #capabilities + # query method is called. + # + # Net::IMAP automatically discards its cached capabilities when they can + # change. Explicitly calling this _should_ be unnecessary for well-behaved + # servers. + # + # Related: #capable?, #capability, #capabilities_cached? + def clear_cached_capabilities + synchronize do + clear_responses("CAPABILITY") + @capabilities = nil + end + end + + # Sends a {CAPABILITY command [IMAP4rev1 §6.1.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.1.1] + # and returns an array of capabilities that are supported by the server. + # The result is stored for use by #capable? and #capabilities. + # + # *NOTE:* Most Net::IMAP methods do not _currently_ modify their + # behaviour according to the server's advertised #capabilities. + # + # Net::IMAP automatically stores and discards capability data according to + # the requirements and recommendations in + # {IMAP4rev2 §6.1.1}[https://www.rfc-editor.org/rfc/rfc9051#section-6.1.1], + # {§6.2}[https://www.rfc-editor.org/rfc/rfc9051#section-6.2], and + # {§7.1}[https://www.rfc-editor.org/rfc/rfc9051#section-7.1]. + # Use #capable?, #auth_capable?, or #capabilities to this cache and avoid + # sending the #capability command unnecessarily. + # + # See Net::IMAP@Capabilities for more about \IMAP capabilities. + # + # Related: #capable?, #auth_capable?, #capability, #enable + def capability + synchronize do + send_command("CAPABILITY") + @capabilities = clear_responses("CAPABILITY").last.freeze + end + end + + # Sends an {ID command [RFC2971 §3.1]}[https://www.rfc-editor.org/rfc/rfc2971#section-3.1] + # and returns a hash of the server's response, or nil if the server does not + # identify itself. + # + # Note that the user should first check if the server supports the ID + # capability. For example: + # + # if capable?(:ID) + # id = imap.id( + # name: "my IMAP client (ruby)", + # version: MyIMAP::VERSION, + # "support-url": "mailto:bugs@example.com", + # os: RbConfig::CONFIG["host_os"], + # ) + # end + # + # See [ID[https://tools.ietf.org/html/rfc2971]] for field definitions. + # + # ===== Capabilities + # + # The server's capabilities must include +ID+ + # [RFC2971[https://tools.ietf.org/html/rfc2971]]. + def id(client_id=nil) + synchronize do + send_command("ID", ClientID.new(client_id)) + clear_responses("ID").last + end + end + + # Sends a {NOOP command [IMAP4rev1 §6.1.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.1.2] + # to the server. + # + # This allows the server to send unsolicited untagged EXPUNGE #responses, + # but does not execute any client request. \IMAP servers are permitted to + # send unsolicited untagged responses at any time, except for +EXPUNGE+: + # + # * +EXPUNGE+ can only be sent while a command is in progress. + # * +EXPUNGE+ must _not_ be sent during #fetch, #store, or #search. + # * +EXPUNGE+ may be sent during #uid_fetch, #uid_store, or #uid_search. + # + # Related: #idle, #check + def noop + send_command("NOOP") + end + + # Sends a {LOGOUT command [IMAP4rev1 §6.1.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.1.3] + # to inform the command to inform the server that the client is done with + # the connection. + # + # Related: #disconnect, #logout! + def logout + send_command("LOGOUT") + end + + # Calls #logout then, after receiving the TaggedResponse for the +LOGOUT+, + # calls #disconnect. Returns the TaggedResponse from +LOGOUT+. Returns + # +nil+ when the client is already disconnected, in contrast to #logout + # which raises an exception. + # + # If #logout raises a StandardError, a warning will be printed but the + # exception will not be re-raised. + # + # This is useful in situations where the connection must be dropped, for + # example for security or after tests. If logout errors need to be handled, + # use #logout and #disconnect instead. + # + # Related: #logout, #disconnect + def logout! + logout unless disconnected? + rescue => ex + warn "%s during logout!: %s" % [ + ex.class, host, port, ex + ] + ensure + disconnect + end + + # Sends a {STARTTLS command [IMAP4rev1 §6.2.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.2.1] + # to start a TLS session. + # + # Any +options+ are forwarded directly to + # {OpenSSL::SSL::SSLContext#set_params}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-set_params]; + # the keys are names of attribute assignment methods on + # SSLContext[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html]. + # + # See DeprecatedClientOptions#starttls for deprecated arguments. + # + # This method returns after TLS negotiation and hostname verification are + # both successful. Any error indicates that the connection has not been + # secured. + # + # After the server agrees to start a TLS connection, this method waits up to + # {config.open_timeout}[rdoc-ref:Config#open_timeout] before raising + # +Net::OpenTimeout+. + # + # *Note:* + # >>> + # Any #response_handlers added before STARTTLS should be aware that the + # TaggedResponse to STARTTLS is sent clear-text, _before_ TLS negotiation. + # TLS starts immediately _after_ that response. Any response code sent + # with the response (e.g. CAPABILITY) is insecure and cannot be trusted. + # + # Related: Net::IMAP.new, #login, #authenticate + # + # ===== Capability + # Clients should not call #starttls unless the server advertises the + # +STARTTLS+ capability. + # + # Server capabilities may change after #starttls, #login, and #authenticate. + # Cached #capabilities will be cleared when this method completes. + # + def starttls(**options) + @ssl_ctx_params, @ssl_ctx = build_ssl_ctx(options) + handled = false + error = nil + ok = send_command("STARTTLS") do |resp| + if resp.kind_of?(TaggedResponse) && resp.name == "OK" + handled = true + clear_cached_capabilities + clear_responses + start_tls_session + end + rescue Exception => error + raise # note that the error backtrace is in the receiver_thread + end + if error + disconnect + raise error + end + unless handled + disconnect + raise InvalidResponseError, + "STARTTLS handler was bypassed, although server responded %p" % [ + ok.raw_data.chomp + ] + end + ok + end + + # :call-seq: + # authenticate(mechanism, *, sasl_ir: config.sasl_ir, registry: Net::IMAP::SASL.authenticators, **, &) -> ok_resp + # + # Sends an {AUTHENTICATE command [IMAP4rev1 §6.2.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.2.2] + # to authenticate the client. If successful, the connection enters the + # "_authenticated_" state. + # + # +mechanism+ is the name of the \SASL authentication mechanism to be used. + # + # +sasl_ir+ allows or disallows sending an "initial response" (see the + # +SASL-IR+ capability, below). Defaults to the #config value for + # {sasl_ir}[rdoc-ref:Config#sasl_ir], which defaults to +true+. + # + # All other arguments are forwarded to the registered SASL authenticator for + # the requested mechanism. The documentation for each individual + # mechanism must be consulted for its specific parameters. + # + # Related: #login, #starttls, #auth_capable?, #auth_mechanisms + # + # ==== Mechanisms + # + # Each mechanism has different properties and requirements. Please consult + # the documentation for the specific mechanisms you are using: + # + # +ANONYMOUS+:: + # See AnonymousAuthenticator[rdoc-ref:Net::IMAP::SASL::AnonymousAuthenticator]. + # + # Allows the user to gain access to public services or resources without + # authenticating or disclosing an identity. + # + # +EXTERNAL+:: + # See ExternalAuthenticator[rdoc-ref:Net::IMAP::SASL::ExternalAuthenticator]. + # + # Authenticates using already established credentials, such as a TLS + # certificate or IPsec. + # + # +OAUTHBEARER+:: + # See OAuthBearerAuthenticator[rdoc-ref:Net::IMAP::SASL::OAuthBearerAuthenticator]. + # + # Login using an OAuth2 Bearer token. This is the standard mechanism + # for using OAuth2 with \SASL, but it is not yet deployed as widely as + # +XOAUTH2+. + # + # +PLAIN+:: + # See PlainAuthenticator[rdoc-ref:Net::IMAP::SASL::PlainAuthenticator]. + # + # Login using clear-text username and password. + # + # +SCRAM-SHA-1+:: + # +SCRAM-SHA-256+:: + # See ScramAuthenticator[rdoc-ref:Net::IMAP::SASL::ScramAuthenticator]. + # + # Login by username and password. The password is not sent to the + # server but is used in a salted challenge/response exchange. + # +SCRAM-SHA-1+ and +SCRAM-SHA-256+ are directly supported by + # Net::IMAP::SASL. New authenticators can easily be added for any other + # SCRAM-* mechanism if the digest algorithm is supported by + # OpenSSL::Digest. + # + # +XOAUTH2+:: + # See XOAuth2Authenticator[rdoc-ref:Net::IMAP::SASL::XOAuth2Authenticator]. + # + # Login using a username and an OAuth2 access token. Non-standard and + # obsoleted by +OAUTHBEARER+, but widely supported. + # + # See the {SASL mechanism + # registry}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] + # for a list of all SASL mechanisms and their specifications. To register + # new authenticators, see Authenticators. + # + # ===== Deprecated mechanisms + # + # Obsolete mechanisms should be avoided, but are still available for + # backwards compatibility. See Net::IMAP::SASL@Deprecated+mechanisms. + # Using a deprecated mechanism will print a warning. + # + # ==== Capabilities + # + # "AUTH=#{mechanism}" capabilities indicate server support for + # mechanisms. Use #auth_capable? or #auth_mechanisms to check for support + # before using a particular mechanism. + # + # if imap.auth_capable? "XOAUTH2" + # imap.authenticate "XOAUTH2", username, oauth2_access_token + # elsif imap.auth_capable? "PLAIN" + # imap.authenticate "PLAIN", username, password + # elsif !imap.capability? "LOGINDISABLED" + # imap.login username, password + # else + # raise "No acceptable authentication mechanism is available" + # end + # + # Although servers should list all supported \SASL mechanisms, they may + # allow authentication with an unlisted +mechanism+. + # + # If [SASL-IR[https://www.rfc-editor.org/rfc/rfc4959.html]] is supported + # and the appropriate "AUTH=#{mechanism}" capability is present, + # an "initial response" may be sent as an argument to the +AUTHENTICATE+ + # command, saving a round-trip. The SASL exchange allows for server + # challenges and client responses, but many mechanisms expect the client to + # "respond" first. The initial response will only be sent for + # "client-first" mechanisms. + # + # Server capabilities may change after #starttls, #login, and #authenticate. + # Previously cached #capabilities will be cleared when this method + # completes. If the TaggedResponse to #authenticate includes updated + # capabilities, they will be cached. + def authenticate(mechanism, *creds, + sasl_ir: config.sasl_ir, + **props, &callback) + mechanism = mechanism.to_s.tr("_", "-").upcase + authenticator = SASL.authenticator(mechanism, *creds, **props, &callback) + cmdargs = ["AUTHENTICATE", mechanism] + if sasl_ir && capable?("SASL-IR") && auth_capable?(mechanism) && + authenticator.respond_to?(:initial_response?) && + authenticator.initial_response? + response = authenticator.process(nil) + cmdargs << (response.empty? ? "=" : [response].pack("m0")) + end + result = send_command_with_continuations(*cmdargs) {|data| + challenge = data.unpack1("m") + response = authenticator.process challenge + [response].pack("m0") + } + if authenticator.respond_to?(:done?) && !authenticator.done? + logout! + raise SASL::AuthenticationIncomplete, result + end + @capabilities = capabilities_from_resp_code result + result + end + + # Sends a {LOGIN command [IMAP4rev1 §6.2.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.2.3] + # to identify the client and carries the plaintext +password+ authenticating + # this +user+. If successful, the connection enters the "_authenticated_" + # state. + # + # Using #authenticate {should be + # preferred}[https://www.rfc-editor.org/rfc/rfc9051.html#name-login-command] + # over #login. The LOGIN command is not the same as #authenticate with the + # "LOGIN" +mechanism+. + # + # A Net::IMAP::NoResponseError is raised if authentication fails. + # + # Related: #authenticate, #starttls + # + # ===== Capabilities + # + # An IMAP client MUST NOT call #login when the server advertises the + # +LOGINDISABLED+ capability. + # + # if imap.capability? "LOGINDISABLED" + # raise "Remote server has disabled the login command" + # else + # imap.login username, password + # end + # + # Server capabilities may change after #starttls, #login, and #authenticate. + # Cached capabilities _must_ be invalidated after this method completes. + # The TaggedResponse to #login may include updated capabilities in its + # ResponseCode. + # + def login(user, password) + send_command("LOGIN", user, password) + .tap { @capabilities = capabilities_from_resp_code _1 } + end + + # Sends a {SELECT command [IMAP4rev1 §6.3.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.1] + # to select a +mailbox+ so that messages in the +mailbox+ can be accessed. + # + # After you have selected a mailbox, you may retrieve the number of items in + # that mailbox from imap.responses("EXISTS", &:last), and the + # number of recent messages from imap.responses("RECENT", &:last). + # Note that these values can change if new messages arrive during a session + # or when existing messages are expunged; see #add_response_handler for a + # way to detect these events. + # + # When the +condstore+ keyword argument is true, the server is told to + # enable the extension. If +mailbox+ supports persistence of mod-sequences, + # the +HIGHESTMODSEQ+ ResponseCode will be sent as an untagged response to + # #select and all `FETCH` responses will include FetchData#modseq. + # Otherwise, the +NOMODSEQ+ ResponseCode will be sent. + # + # A Net::IMAP::NoResponseError is raised if the mailbox does not + # exist or is for some reason non-selectable. + # + # Related: #examine + # + # ===== Capabilities + # + # If [UIDPLUS[https://www.rfc-editor.org/rfc/rfc4315.html]] is supported, + # the server may return an untagged "NO" response with a "UIDNOTSTICKY" + # response code indicating that the mailstore does not support persistent + # UIDs: + # imap.responses("NO", &:last)&.code&.name == "UIDNOTSTICKY" + # + # If [CONDSTORE[https://www.rfc-editor.org/rfc/rfc7162.html]] is supported, + # the +condstore+ keyword parameter may be used. + # imap.select("mbox", condstore: true) + # modseq = imap.responses("HIGHESTMODSEQ", &:last) + def select(mailbox, condstore: false) + args = ["SELECT", mailbox] + args << ["CONDSTORE"] if condstore + synchronize do + @responses.clear + send_command(*args) + end + end + + # Sends a {EXAMINE command [IMAP4rev1 §6.3.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.2] + # to select a +mailbox+ so that messages in the +mailbox+ can be accessed. + # Behaves the same as #select, except that the selected +mailbox+ is + # identified as read-only. + # + # A Net::IMAP::NoResponseError is raised if the mailbox does not + # exist or is for some reason non-examinable. + # + # Related: #select + def examine(mailbox, condstore: false) + args = ["EXAMINE", mailbox] + args << ["CONDSTORE"] if condstore + synchronize do + @responses.clear + send_command(*args) + end + end + + # Sends a {CREATE command [IMAP4rev1 §6.3.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.3] + # to create a new +mailbox+. + # + # A Net::IMAP::NoResponseError is raised if a mailbox with that name + # cannot be created. + # + # Related: #rename, #delete + def create(mailbox) + send_command("CREATE", mailbox) + end + + # Sends a {DELETE command [IMAP4rev1 §6.3.4]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.4] + # to remove the +mailbox+. + # + # A Net::IMAP::NoResponseError is raised if a mailbox with that name + # cannot be deleted, either because it does not exist or because the + # client does not have permission to delete it. + # + # Related: #create, #rename + def delete(mailbox) + send_command("DELETE", mailbox) + end + + # Sends a {RENAME command [IMAP4rev1 §6.3.5]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.5] + # to change the name of the +mailbox+ to +newname+. + # + # A Net::IMAP::NoResponseError is raised if a mailbox with the + # name +mailbox+ cannot be renamed to +newname+ for whatever + # reason; for instance, because +mailbox+ does not exist, or + # because there is already a mailbox with the name +newname+. + # + # Related: #create, #delete + def rename(mailbox, newname) + send_command("RENAME", mailbox, newname) + end + + # Sends a {SUBSCRIBE command [IMAP4rev1 §6.3.6]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.6] + # to add the specified +mailbox+ name to the server's set of "active" or + # "subscribed" mailboxes as returned by #lsub. + # + # A Net::IMAP::NoResponseError is raised if +mailbox+ cannot be + # subscribed to; for instance, because it does not exist. + # + # Related: #unsubscribe, #lsub, #list + def subscribe(mailbox) + send_command("SUBSCRIBE", mailbox) + end + + # Sends an {UNSUBSCRIBE command [IMAP4rev1 §6.3.7]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.7] + # to remove the specified +mailbox+ name from the server's set of "active" + # or "subscribed" mailboxes. + # + # A Net::IMAP::NoResponseError is raised if +mailbox+ cannot be + # unsubscribed from; for instance, because the client is not currently + # subscribed to it. + # + # Related: #subscribe, #lsub, #list + def unsubscribe(mailbox) + send_command("UNSUBSCRIBE", mailbox) + end + + # Sends a {LIST command [IMAP4rev1 §6.3.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.8] + # and returns a subset of names from the complete set of all names available + # to the client. +refname+ provides a context (for instance, a base + # directory in a directory-based mailbox hierarchy). +mailbox+ specifies a + # mailbox or (via wildcards) mailboxes under that context. Two wildcards + # may be used in +mailbox+: "*", which matches all characters + # *including* the hierarchy delimiter (for instance, "/" on a UNIX-hosted + # directory-based mailbox hierarchy); and "%", which matches all + # characters *except* the hierarchy delimiter. + # + # If +refname+ is empty, +mailbox+ is used directly to determine + # which mailboxes to match. If +mailbox+ is empty, the root + # name of +refname+ and the hierarchy delimiter are returned. + # + # The return value is an array of MailboxList. + # + # Related: #lsub, MailboxList + # + # ===== For example: + # + # imap.create("foo/bar") + # imap.create("foo/baz") + # p imap.list("", "foo/%") + # #=> [#, \\ + # #, \\ + # #] + # + #-- + # TODO: support LIST-EXTENDED extension [RFC5258]. Needed for IMAP4rev2. + #++ + def list(refname, mailbox) + synchronize do + send_command("LIST", refname, mailbox) + clear_responses("LIST") + end + end + + # Sends a {NAMESPACE command [RFC2342 §5]}[https://www.rfc-editor.org/rfc/rfc2342#section-5] + # and returns the namespaces that are available. The NAMESPACE command + # allows a client to discover the prefixes of namespaces used by a server + # for personal mailboxes, other users' mailboxes, and shared mailboxes. + # + # The return value is a Namespaces object which has +personal+, +other+, and + # +shared+ fields, each an array of Namespace objects. These arrays will be + # empty when the server responds with +nil+. + # + # Many \IMAP servers are configured with the default personal namespaces as + # ("" "/"): no prefix and the "+/+" hierarchy delimiter. In that + # common case, the naive client may not have any trouble naming mailboxes. + # But many servers are configured with the default personal namespace as + # e.g. ("INBOX." "."), placing all personal folders under INBOX, + # with "+.+" as the hierarchy delimiter. If the client does not check for + # this, but naively assumes it can use the same folder names for all + # servers, then folder creation (and listing, moving, etc) can lead to + # errors. + # + # From RFC2342[https://tools.ietf.org/html/rfc2342]: + # >>> + # Although typically a server will support only a single Personal + # Namespace, and a single Other User's Namespace, circumstances exist + # where there MAY be multiples of these, and a client MUST be prepared + # for them. If a client is configured such that it is required to create + # a certain mailbox, there can be circumstances where it is unclear which + # Personal Namespaces it should create the mailbox in. In these + # situations a client SHOULD let the user select which namespaces to + # create the mailbox in. + # + # Related: #list, Namespaces, Namespace + # + # ===== For example: + # + # if capable?("NAMESPACE") + # namespaces = imap.namespace + # if namespace = namespaces.personal.first + # prefix = namespace.prefix # e.g. "" or "INBOX." + # delim = namespace.delim # e.g. "/" or "." + # # personal folders should use the prefix and delimiter + # imap.create(prefix + "foo") + # imap.create(prefix + "bar") + # imap.create(prefix + %w[path to my folder].join(delim)) + # end + # end + # + # ===== Capabilities + # + # The server's capabilities must include +NAMESPACE+ + # [RFC2342[https://tools.ietf.org/html/rfc2342]]. + def namespace + synchronize do + send_command("NAMESPACE") + clear_responses("NAMESPACE").last + end + end + + # Sends a XLIST command, and returns a subset of names from + # the complete set of all names available to the client. + # +refname+ provides a context (for instance, a base directory + # in a directory-based mailbox hierarchy). +mailbox+ specifies + # a mailbox or (via wildcards) mailboxes under that context. + # Two wildcards may be used in +mailbox+: '*', which matches + # all characters *including* the hierarchy delimiter (for instance, + # '/' on a UNIX-hosted directory-based mailbox hierarchy); and '%', + # which matches all characters *except* the hierarchy delimiter. + # + # If +refname+ is empty, +mailbox+ is used directly to determine + # which mailboxes to match. If +mailbox+ is empty, the root + # name of +refname+ and the hierarchy delimiter are returned. + # + # The XLIST command is like the LIST command except that the flags + # returned refer to the function of the folder/mailbox, e.g. :Sent + # + # The return value is an array of MailboxList objects. For example: + # + # imap.create("foo/bar") + # imap.create("foo/baz") + # p imap.xlist("", "foo/%") + # #=> [#, \\ + # #, \\ + # #] + # + # Related: #list, MailboxList + # + # ===== Capabilities + # + # The server's capabilities must include +XLIST+, + # a deprecated Gmail extension (replaced by +SPECIAL-USE+). + #-- + # TODO: Net::IMAP doesn't yet have full SPECIAL-USE support. Supporting + # servers MAY return SPECIAL-USE attributes, but are not *required* to + # unless the SPECIAL-USE return option is supplied. + #++ + def xlist(refname, mailbox) + synchronize do + send_command("XLIST", refname, mailbox) + clear_responses("XLIST") + end + end + + # Sends a {GETQUOTAROOT command [RFC2087 §4.3]}[https://www.rfc-editor.org/rfc/rfc2087#section-4.3] + # along with the specified +mailbox+. This command is generally available + # to both admin and user. If this mailbox exists, it returns an array + # containing objects of type MailboxQuotaRoot and MailboxQuota. + # + # *NOTE:* Currently, Net::IMAP only supports +QUOTA+ responses with a single + # resource type. This is usually +STORAGE+, but you may need to verify this + # with UntaggedResponse#raw_data. + # + # Related: #getquota, #setquota, MailboxQuotaRoot, MailboxQuota + # + # ===== Capabilities + # + # Requires +QUOTA+ [RFC2087[https://www.rfc-editor.org/rfc/rfc2087]] + # capability, or a capability prefixed with QUOTA=RES-* + # {[RFC9208]}[https://www.rfc-editor.org/rfc/rfc9208] for each supported + # resource type. + def getquotaroot(mailbox) + synchronize do + send_command("GETQUOTAROOT", mailbox) + result = [] + result.concat(clear_responses("QUOTAROOT")) + result.concat(clear_responses("QUOTA")) + return result + end + end + + # Sends a {GETQUOTA command [RFC2087 §4.2]}[https://www.rfc-editor.org/rfc/rfc2087#section-4.2] + # for the +quota_root+. If this quota root exists, then an array + # containing a MailboxQuota object is returned. + # + # The names of quota roots that are applicable to a particular mailbox can + # be discovered with #getquotaroot. + # + # *NOTE:* Currently, Net::IMAP only supports +QUOTA+ responses with a single + # resource type. This is usually +STORAGE+, but you may need to verify this + # with UntaggedResponse#raw_data. + # + # Related: #getquotaroot, #setquota, MailboxQuota + # + # ===== Capabilities + # + # Requires +QUOTA+ [RFC2087[https://www.rfc-editor.org/rfc/rfc2087]] + # capability, or a capability prefixed with QUOTA=RES-* + # {[RFC9208]}[https://www.rfc-editor.org/rfc/rfc9208] for each supported + # resource type. + def getquota(quota_root) + synchronize do + send_command("GETQUOTA", quota_root) + clear_responses("QUOTA") + end + end + + # Sends a {SETQUOTA command [RFC2087 §4.1]}[https://www.rfc-editor.org/rfc/rfc2087#section-4.1] + # along with the specified +quota_root+ and +storage_limit+. If + # +storage_limit+ is +nil+, resource limits are unset for that quota root. + # If +storage_limit+ is a number, it sets the +STORAGE+ resource limit. + # + # imap.setquota "#user/alice", 100 + # imap.getquota "#user/alice" + # # => [#] + # + # Typically one needs to be logged in as a server admin for this to work. + # + # *NOTE:* Currently, Net::IMAP only supports setting +STORAGE+ quota limits. + # + # Related: #getquota, #getquotaroot + # + # ===== Capabilities + # + # Requires +QUOTA+ [RFC2087[https://www.rfc-editor.org/rfc/rfc2087]] + # capability, or both +QUOTASET+ and a capability prefixed with + # QUOTA=RES-* {[RFC9208]}[https://www.rfc-editor.org/rfc/rfc9208] + # for each supported resource type. + def setquota(quota_root, storage_limit) + if storage_limit.nil? + list = [] + else + list = ["STORAGE", Integer(storage_limit)] + end + send_command("SETQUOTA", quota_root, list) + end + + # Sends a {SETACL command [RFC4314 §3.1]}[https://www.rfc-editor.org/rfc/rfc4314#section-3.1] + # along with +mailbox+, +user+ and the +rights+ that user is to have on that + # mailbox. If +rights+ is nil, then that user will be stripped of any + # rights to that mailbox. + # + # Related: #getacl + # + # ===== Capabilities + # + # The server's capabilities must include +ACL+ + # [RFC4314[https://tools.ietf.org/html/rfc4314]]. + def setacl(mailbox, user, rights) + if rights.nil? + send_command("SETACL", mailbox, user, "") + else + send_command("SETACL", mailbox, user, rights) + end + end + + # Sends a {GETACL command [RFC4314 §3.3]}[https://www.rfc-editor.org/rfc/rfc4314#section-3.3] + # along with a specified +mailbox+. If this mailbox exists, an array + # containing objects of MailboxACLItem will be returned. + # + # Related: #setacl, MailboxACLItem + # + # ===== Capabilities + # + # The server's capabilities must include +ACL+ + # [RFC4314[https://tools.ietf.org/html/rfc4314]]. + def getacl(mailbox) + synchronize do + send_command("GETACL", mailbox) + clear_responses("ACL").last + end + end + + # Sends a {LSUB command [IMAP4rev1 §6.3.9]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.9] + # and returns a subset of names from the set of names that the user has + # declared as being "active" or "subscribed." +refname+ and +mailbox+ are + # interpreted as for #list. + # + # The return value is an array of MailboxList objects. + # + # Related: #subscribe, #unsubscribe, #list, MailboxList + def lsub(refname, mailbox) + synchronize do + send_command("LSUB", refname, mailbox) + clear_responses("LSUB") + end + end + + # Sends a {STATUS command [IMAP4rev1 §6.3.10]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.10] + # and returns the status of the indicated +mailbox+. +attr+ is a list of one + # or more attributes whose statuses are to be requested. + # + # The return value is a hash of attributes. Most status attributes return + # integer values, but some return other value types (documented below). + # + # A Net::IMAP::NoResponseError is raised if status values + # for +mailbox+ cannot be returned; for instance, because it + # does not exist. + # + # ===== Supported attributes + # + # +MESSAGES+:: The number of messages in the mailbox. + # + # +UIDNEXT+:: The next unique identifier value of the mailbox. + # + # +UIDVALIDITY+:: The unique identifier validity value of the mailbox. + # + # +UNSEEN+:: The number of messages without the \Seen flag. + # + # +DELETED+:: The number of messages with the \Deleted flag. + # + # +SIZE+:: + # The approximate size of the mailbox---must be greater than or equal to + # the sum of all messages' +RFC822.SIZE+ fetch item values. + # + # +HIGHESTMODSEQ+:: + # The highest mod-sequence value of all messages in the mailbox. See + # +CONDSTORE+ {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. + # + # +MAILBOXID+:: + # A server-allocated unique _string_ identifier for the mailbox. See + # +OBJECTID+ {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. + # + # +RECENT+:: + # The number of messages with the \Recent flag. + # _NOTE:_ +RECENT+ was removed from IMAP4rev2. + # + # Unsupported attributes may be requested. The attribute value will be + # either an Integer or an ExtensionData object. + # + # ===== For example: + # + # p imap.status("inbox", ["MESSAGES", "RECENT"]) + # #=> {"RECENT"=>0, "MESSAGES"=>44} + # + # ===== Capabilities + # + # +SIZE+ requires the server's capabilities to include either +IMAP4rev2+ or + # STATUS=SIZE + # {[RFC8483]}[https://www.rfc-editor.org/rfc/rfc8483.html]. + # + # +DELETED+ must be supported when the server's capabilities includes + # +IMAP4rev2+. + # or QUOTA=RES-MESSAGES + # {[RFC9208]}[https://www.rfc-editor.org/rfc/rfc9208.html]. + # + # +HIGHESTMODSEQ+ requires the server's capabilities to include +CONDSTORE+ + # {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. + # + # +MAILBOXID+ requires the server's capabilities to include +OBJECTID+ + # {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. + def status(mailbox, attr) + synchronize do + send_command("STATUS", mailbox, attr) + clear_responses("STATUS").last&.attr + end + end + + # Sends an {APPEND command [IMAP4rev1 §6.3.11]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.11] + # to append the +message+ to the end of the +mailbox+. The optional +flags+ + # argument is an array of flags initially passed to the new message. The + # optional +date_time+ argument specifies the creation time to assign to the + # new message; it defaults to the current time. + # + # For example: + # + # imap.append("inbox", <\\Deleted + # flag set. + # + # Related: #unselect + def close + send_command("CLOSE") + end + + # Sends an {UNSELECT command [RFC3691 §2]}[https://www.rfc-editor.org/rfc/rfc3691#section-3] + # {[IMAP4rev2 §6.4.2]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.2] + # to free the session resources for a mailbox and return to the + # "_authenticated_" state. This is the same as #close, except that + # \\Deleted messages are not removed from the mailbox. + # + # Related: #close + # + # ===== Capabilities + # + # The server's capabilities must include +UNSELECT+ + # [RFC3691[https://tools.ietf.org/html/rfc3691]]. + def unselect + send_command("UNSELECT") + end + + # Sends an {EXPUNGE command [IMAP4rev1 §6.4.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.3] + # Sends a EXPUNGE command to permanently remove from the currently + # selected mailbox all messages that have the \Deleted flag set. + # + # Related: #uid_expunge + def expunge + synchronize do + send_command("EXPUNGE") + clear_responses("EXPUNGE") + end + end + + # Sends a {UID EXPUNGE command [RFC4315 §2.1]}[https://www.rfc-editor.org/rfc/rfc4315#section-2.1] + # {[IMAP4rev2 §6.4.9]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.9] + # to permanently remove all messages that have both the \\Deleted + # flag set and a UID that is included in +uid_set+. + # + # By using #uid_expunge instead of #expunge when resynchronizing with + # the server, the client can ensure that it does not inadvertantly + # remove any messages that have been marked as \\Deleted by other + # clients between the time that the client was last connected and + # the time the client resynchronizes. + # + # *Note:* + # >>> + # Although the command takes a set of UIDs for its argument, the + # server still returns regular EXPUNGE responses, which contain + # a sequence number. These will be deleted from + # #responses and this method returns them as an array of + # sequence number integers. + # + # Related: #expunge + # + # ===== Capabilities + # + # The server's capabilities must include +UIDPLUS+ + # [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]]. + def uid_expunge(uid_set) + synchronize do + send_command("UID EXPUNGE", MessageSet.new(uid_set)) + clear_responses("EXPUNGE") + end + end + + # Sends a {SEARCH command [IMAP4rev1 §6.4.4]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.4] + # to search the mailbox for messages that match the given searching + # criteria, and returns message sequence numbers. +keys+ can either be a + # string holding the entire search string, or a single-dimension array of + # search keywords and arguments. + # + # Please note the warning (below) when +keys+ is a String. + # + # Returns a SearchResult object. SearchResult inherits from Array (for + # backward compatibility) but adds SearchResult#modseq when the +CONDSTORE+ + # capability has been enabled. + # + # Related: #uid_search + # + # ===== Search criteria + # + # >>> + # When +keys+ is an Array, elements in the array will be validated and + # formatted. When +keys+ is a String, it will be sent with + # minimal validation and no encoding or formatting. + # + # *WARNING:* Although CRLF is prohibited, this is vulnerable to other + # types of attribute injection attack if unvetted user input is used. + # + # For a full list of search criteria, + # see [{IMAP4rev1 §6.4.4}[https://www.rfc-editor.org/rfc/rfc3501.html#section-6.4.4]], + # or [{IMAP4rev2 §6.4.4}[https://www.rfc-editor.org/rfc/rfc9051.html#section-6.4.4]], + # in addition to documentation for + # any [CAPABILITIES[https://www.iana.org/assignments/imap-capabilities/imap-capabilities.xhtml]] + # reported by #capabilities which may define additional search filters, e.g: + # +CONDSTORE+, +WITHIN+, +FILTERS+, SEARCH=FUZZY, +OBJECTID+, or + # +SAVEDATE+. The following are some common search criteria: + # + # :: a set of message sequence numbers. "," indicates + # an interval, "+:+" indicates a range. For instance, + # "2,10:12,15" means "2,10,11,12,15". + # + # BEFORE :: messages with an internal date strictly before + # . The date argument has a format similar + # to 8-Aug-2002, and can be formatted using + # Net::IMAP.format_date. + # + # BODY :: messages that contain within their body. + # + # CC :: messages containing in their CC field. + # + # FROM :: messages that contain in their FROM field. + # + # NEW:: messages with the \Recent, but not the \Seen, flag set. + # + # NOT :: negate the following search key. + # + # OR :: "or" two search keys together. + # + # ON :: messages with an internal date exactly equal to , + # which has a format similar to 8-Aug-2002. + # + # SINCE :: messages with an internal date on or after . + # + # SUBJECT :: messages with in their subject. + # + # TO :: messages with in their TO field. + # + # ===== For example: + # + # p imap.search(["SUBJECT", "hello", "NOT", "NEW"]) + # #=> [1, 6, 7, 8] + # + # ===== Capabilities + # + # If [CONDSTORE[https://www.rfc-editor.org/rfc/rfc7162.html]] is supported + # and enabled for the selected mailbox, a non-empty SearchResult will + # include a +MODSEQ+ value. + # imap.select("mbox", condstore: true) + # result = imap.search(["SUBJECT", "hi there", "not", "new") + # #=> Net::IMAP::SearchResult[1, 6, 7, 8, modseq: 5594] + # result.modseq # => 5594 + def search(keys, charset = nil) + return search_internal("SEARCH", keys, charset) + end + + # Sends a {UID SEARCH command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] + # to search the mailbox for messages that match the given searching + # criteria, and returns unique identifiers (UIDs). + # + # Returns a SearchResult object. SearchResult inherits from Array (for + # backward compatibility) but adds SearchResult#modseq when the +CONDSTORE+ + # capability has been enabled. + # + # See #search for documentation of parameters. Please note the + # warning for when +keys+ is a String. + def uid_search(keys, charset = nil) + return search_internal("UID SEARCH", keys, charset) + end + + # :call-seq: + # fetch(set, attr, changedsince: nil) -> array of FetchData + # + # Sends a {FETCH command [IMAP4rev1 §6.4.5]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.5] + # to retrieve data associated with a message in the mailbox. + # + # The +set+ parameter is a number or a range between two numbers, + # or an array of those. The number is a message sequence number, + # where -1 represents a '*' for use in range notation like 100..-1 + # being interpreted as '100:*'. Beware that the +exclude_end?+ + # property of a Range object is ignored, and the contents of a + # range are independent of the order of the range endpoints as per + # the protocol specification, so 1...5, 5..1 and 5...1 are all + # equivalent to 1..5. + # + # +attr+ is a list of attributes to fetch; see the documentation + # for FetchData for a list of valid attributes. + # >>> + # When +attr+ is a String, it will be sent with minimal validation and + # no encoding or formatting. When +attr+ is an Array, each String in + # +attr+ will be sent this way. + # + # *WARNING:* Although CRLF is prohibited, this is vulnerable to other + # types of attribute injection attack if unvetted user input is used. + # + # +changedsince+ is an optional integer mod-sequence. It limits results to + # messages with a mod-sequence greater than +changedsince+. + # + # The return value is an array of FetchData. + # + # Related: #uid_search, FetchData + # + # ===== For example: + # + # p imap.fetch(6..8, "UID") + # #=> [#98}>, \\ + # #99}>, \\ + # #100}>] + # p imap.fetch(6, "BODY[HEADER.FIELDS (SUBJECT)]") + # #=> [#"Subject: test\r\n\r\n"}>] + # data = imap.uid_fetch(98, ["RFC822.SIZE", "INTERNALDATE"])[0] + # p data.seqno + # #=> 6 + # p data.attr["RFC822.SIZE"] + # #=> 611 + # p data.attr["INTERNALDATE"] + # #=> "12-Oct-2000 22:40:59 +0900" + # p data.attr["UID"] + # #=> 98 + # + # ===== Capabilities + # + # Many extensions define new message +attr+ names. See FetchData for a list + # of supported extension fields. + # + # The server's capabilities must include +CONDSTORE+ + # {[RFC7162]}[https://tools.ietf.org/html/rfc7162] in order to use the + # +changedsince+ argument. Using +changedsince+ implicitly enables the + # +CONDSTORE+ extension. + def fetch(set, attr, mod = nil, changedsince: nil) + fetch_internal("FETCH", set, attr, mod, changedsince: changedsince) + end + + # :call-seq: + # uid_fetch(set, attr, changedsince: nil) -> array of FetchData + # + # Sends a {UID FETCH command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] + # to retrieve data associated with a message in the mailbox. + # + # Similar to #fetch, but the +set+ parameter contains unique identifiers + # instead of message sequence numbers. + # + # +attr+ behaves the same as with #fetch. Please note the #fetch + # warning on the +attr+ argument. + # >>> + # *Note:* Servers _MUST_ implicitly include the +UID+ message data item as + # part of any +FETCH+ response caused by a +UID+ command, regardless of + # whether a +UID+ was specified as a message data item to the +FETCH+. + # + # Related: #fetch, FetchData + # + # ===== Capabilities + # Same as #fetch. + def uid_fetch(set, attr, mod = nil, changedsince: nil) + fetch_internal("UID FETCH", set, attr, mod, changedsince: changedsince) + end + + # :call-seq: + # store(set, attr, value, unchangedsince: nil) -> array of FetchData + # + # Sends a {STORE command [IMAP4rev1 §6.4.6]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.6] + # to alter data associated with messages in the mailbox, in particular their + # flags. + # + # +set+ is a number, an array of numbers, or a Range object. Each number is + # a message sequence number. + # + # +attr+ is the name of a data item to store. The semantics of +value+ + # varies based on +attr+: + # * When +attr+ is "FLAGS", the flags in +value+ replace the + # message's flag list. + # * When +attr+ is "+FLAGS", the flags in +value+ are added to + # the flags for the message. + # * When +attr+ is "-FLAGS", the flags in +value+ are removed + # from the message. + # + # +unchangedsince+ is an optional integer mod-sequence. It prohibits any + # changes to messages with +mod-sequence+ greater than the specified + # +unchangedsince+ value. A SequenceSet of any messages that fail this + # check will be returned in a +MODIFIED+ ResponseCode. + # + # The return value is an array of FetchData. + # + # Related: #uid_store + # + # ===== For example: + # + # p imap.store(6..8, "+FLAGS", [:Deleted]) + # #=> [#[:Seen, :Deleted]}>, + # #[:Seen, :Deleted]}>, + # #[:Seen, :Deleted]}>] + # + # ===== Capabilities + # + # Extensions may define new data items to be used with #store. + # + # The server's capabilities must include +CONDSTORE+ + # {[RFC7162]}[https://tools.ietf.org/html/rfc7162] in order to use the + # +unchangedsince+ argument. Using +unchangedsince+ implicitly enables the + # +CONDSTORE+ extension. + def store(set, attr, flags, unchangedsince: nil) + store_internal("STORE", set, attr, flags, unchangedsince: unchangedsince) + end + + # :call-seq: + # uid_store(set, attr, value, unchangedsince: nil) -> array of FetchData + # + # Sends a {UID STORE command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] + # to alter data associated with messages in the mailbox, in particular their + # flags. + # + # Similar to #store, but +set+ contains unique identifiers instead of + # message sequence numbers. + # + # Related: #store + # + # ===== Capabilities + # Same as #store. + def uid_store(set, attr, flags, unchangedsince: nil) + store_internal("UID STORE", set, attr, flags, unchangedsince: unchangedsince) + end + + # Sends a {COPY command [IMAP4rev1 §6.4.7]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.7] + # to copy the specified message(s) to the end of the specified destination + # +mailbox+. The +set+ parameter is a number, an array of numbers, or a + # Range object. The number is a message sequence number. + # + # Related: #uid_copy + # + # ===== Capabilities + # + # If +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]] is + # supported, the server's response should include a +COPYUID+ response code + # with UIDPlusData. This will report the UIDVALIDITY of the destination + # mailbox, the UID set of the source messages, and the assigned UID set of + # the moved messages. + def copy(set, mailbox) + copy_internal("COPY", set, mailbox) + end + + # Sends a {UID COPY command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] + # to copy the specified message(s) to the end of the specified destination + # +mailbox+. + # + # Similar to #copy, but +set+ contains unique identifiers. + # + # ===== Capabilities + # + # +UIDPLUS+ affects #uid_copy the same way it affects #copy. + def uid_copy(set, mailbox) + copy_internal("UID COPY", set, mailbox) + end + + # Sends a {MOVE command [RFC6851 §3.1]}[https://www.rfc-editor.org/rfc/rfc6851#section-3.1] + # {[IMAP4rev2 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.8] + # to move the specified message(s) to the end of the specified destination + # +mailbox+. The +set+ parameter is a number, an array of numbers, or a + # Range object. The number is a message sequence number. + # + # Related: #uid_move + # + # ===== Capabilities + # + # The server's capabilities must include +MOVE+ + # [RFC6851[https://tools.ietf.org/html/rfc6851]]. + # + # If +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]] is + # supported, the server's response should include a +COPYUID+ response code + # with UIDPlusData. This will report the UIDVALIDITY of the destination + # mailbox, the UID set of the source messages, and the assigned UID set of + # the moved messages. + # + def move(set, mailbox) + copy_internal("MOVE", set, mailbox) + end + + # Sends a {UID MOVE command [RFC6851 §3.2]}[https://www.rfc-editor.org/rfc/rfc6851#section-3.2] + # {[IMAP4rev2 §6.4.9]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.9] + # to move the specified message(s) to the end of the specified destination + # +mailbox+. + # + # Similar to #move, but +set+ contains unique identifiers. + # + # Related: #move + # + # ===== Capabilities + # + # Same as #move: The server's capabilities must include +MOVE+ + # [RFC6851[https://tools.ietf.org/html/rfc6851]]. +UIDPLUS+ also affects + # #uid_move the same way it affects #move. + def uid_move(set, mailbox) + copy_internal("UID MOVE", set, mailbox) + end + + # Sends a {SORT command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] + # to search a mailbox for messages that match +search_keys+ and return an + # array of message sequence numbers, sorted by +sort_keys+. + # + # +search_keys+ are interpreted the same as the +criteria+ argument for + # #search. Please note the #search warning for String +criteria+. + # + #-- + # TODO: describe +sort_keys+ + #++ + # + # Related: #uid_sort, #search, #uid_search, #thread, #uid_thread + # + # ===== For example: + # + # p imap.sort(["FROM"], ["ALL"], "US-ASCII") + # #=> [1, 2, 3, 5, 6, 7, 8, 4, 9] + # p imap.sort(["DATE"], ["SUBJECT", "hello"], "US-ASCII") + # #=> [6, 7, 8, 1] + # + # ===== Capabilities + # + # The server's capabilities must include +SORT+ + # [RFC5256[https://tools.ietf.org/html/rfc5256]]. + def sort(sort_keys, search_keys, charset) + return sort_internal("SORT", sort_keys, search_keys, charset) + end + + # Sends a {UID SORT command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] + # to search a mailbox for messages that match +search_keys+ and return an + # array of unique identifiers, sorted by +sort_keys+. + # + # +search_keys+ are interpreted the same as the +criteria+ argument for + # #search. Please note the #search warning for String +criteria+. + # + # Related: #sort, #search, #uid_search, #thread, #uid_thread + # + # ===== Capabilities + # + # The server's capabilities must include +SORT+ + # [RFC5256[https://tools.ietf.org/html/rfc5256]]. + def uid_sort(sort_keys, search_keys, charset) + return sort_internal("UID SORT", sort_keys, search_keys, charset) + end + + # Sends a {THREAD command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] + # to search a mailbox and return message sequence numbers in threaded + # format, as a ThreadMember tree. + # + # +search_keys+ are interpreted the same as the +criteria+ argument for + # #search. Please note the #search warning for String +criteria+. + # + # The supported algorithms are: + # + # ORDEREDSUBJECT:: split into single-level threads according to subject, + # ordered by date. + # REFERENCES:: split into threads by parent/child relationships determined + # by which message is a reply to which. + # + # Unlike #search, +charset+ is a required argument. US-ASCII + # and UTF-8 are sample values. + # + # Related: #uid_thread, #search, #uid_search, #sort, #uid_sort + # + # ===== Capabilities + # + # The server's capabilities must include +THREAD+ + # [RFC5256[https://tools.ietf.org/html/rfc5256]]. + def thread(algorithm, search_keys, charset) + return thread_internal("THREAD", algorithm, search_keys, charset) + end + + # Sends a {UID THREAD command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] + # Similar to #thread, but returns unique identifiers instead of + # message sequence numbers. + # + # +search_keys+ are interpreted the same as the +criteria+ argument for + # #search. Please note the #search warning for String +criteria+. + # + # Related: #thread, #search, #uid_search, #sort, #uid_sort + # + # ===== Capabilities + # + # The server's capabilities must include +THREAD+ + # [RFC5256[https://tools.ietf.org/html/rfc5256]]. + def uid_thread(algorithm, search_keys, charset) + return thread_internal("UID THREAD", algorithm, search_keys, charset) + end + + # Sends an {ENABLE command [RFC5161 §3.2]}[https://www.rfc-editor.org/rfc/rfc5161#section-3.1] + # {[IMAP4rev2 §6.3.1]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.3.1] + # to enable the specified server +capabilities+. Each capability may be an + # array, string, or symbol. Returns a list of the capabilities that were + # enabled. + # + # The +ENABLE+ command is only valid in the _authenticated_ state, before + # any mailbox is selected. + # + # Related: #capable?, #capabilities, #capability + # + # ===== Capabilities + # + # The server's capabilities must include + # +ENABLE+ [RFC5161[https://tools.ietf.org/html/rfc5161]] + # or +IMAP4REV2+ [RFC9051[https://tools.ietf.org/html/rfc9051]]. + # + # Additionally, the server capabilities must include a capability matching + # each enabled extension (usually the same name as the enabled extension). + # The following capabilities may be enabled: + # + # [+CONDSTORE+ {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]] + # + # Updates various commands to return +CONDSTORE+ extension responses. It + # is not necessary to explicitly enable +CONDSTORE+—using any of the + # command parameters defined by the extension will implicitly enable it. + # See {[RFC7162 §3.1]}[https://www.rfc-editor.org/rfc/rfc7162.html#section-3.1]. + # + # [+:utf8+ --- an alias for "UTF8=ACCEPT"] + # + # In a future release, enable(:utf8) will enable either + # "UTF8=ACCEPT" or "IMAP4rev2", depending on server + # capabilities. + # + # ["UTF8=ACCEPT" [RFC6855[https://tools.ietf.org/html/rfc6855]]] + # + # The server's capabilities must include UTF8=ACCEPT _or_ + # UTF8=ONLY. + # + # This allows the server to send strings encoded as UTF-8 which might + # otherwise need to use a 7-bit encoding, such as {modified + # UTF-7}[::decode_utf7] for mailbox names, or RFC2047 encoded-words for + # message headers. + # + # *Note:* A future update may set string encodings slightly + # differently, e.g: "US-ASCII" when UTF-8 is not enabled, and "UTF-8" + # when it is. Currently, the encoding of strings sent as "quoted" or + # "text" will _always_ be "UTF-8", even when only ASCII characters are + # used (e.g. "Subject: Agenda") And currently, string "literals" sent + # by the server will always have an "ASCII-8BIT" (binary) + # encoding, even if they generally contain UTF-8 data, if they are + # text at all. + # + # ["UTF8=ONLY" [RFC6855[https://tools.ietf.org/html/rfc6855]]] + # + # A server that reports the UTF8=ONLY capability _requires_ that + # the client enable("UTF8=ACCEPT") before any mailboxes may be + # selected. For convenience, enable("UTF8=ONLY") is aliased to + # enable("UTF8=ACCEPT"). + # + # ===== Unsupported capabilities + # + # *Note:* Some extensions that use ENABLE permit the server to send syntax + # that Net::IMAP cannot parse, which may raise an exception and disconnect. + # Some extensions may work, but the support may be incomplete, untested, or + # experimental. + # + # Until a capability is documented here as supported, enabling it may result + # in undocumented behavior and a future release may update with incompatible + # behavior without warning or deprecation. + # + # Caution is advised. + # + def enable(*capabilities) + capabilities = capabilities + .flatten + .map {|e| ENABLE_ALIASES[e] || e } + .flat_map { _1.is_a?(String) && !_1.empty? ? _1.split(/ /, -1) : [_1] } + .uniq + .map { Atom[_1] } + synchronize do + send_command("ENABLE", *capabilities) + result = clear_responses("ENABLED").last || [] + @utf8_strings ||= result.include? "UTF8=ACCEPT" + @utf8_strings ||= result.include? "IMAP4REV2" + result + end + end + + # Sends an {IDLE command [RFC2177 §3]}[https://www.rfc-editor.org/rfc/rfc6851#section-3] + # {[IMAP4rev2 §6.3.13]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.3.13] + # that waits for notifications of new or expunged messages. Yields + # responses from the server during the IDLE. + # + # Use #idle_done to leave IDLE. + # + # If +timeout+ is given, this method returns after +timeout+ seconds passed. + # +timeout+ can be used for keep-alive. For example, the following code + # checks the connection for each 60 seconds. + # + # loop do + # imap.idle(60) do |response| + # do_something_with(response) + # imap.idle_done if some_condition?(response) + # end + # end + # + # Returns the server's response to indicate the IDLE state has ended. + # Returns +nil+ if the server does not respond to #idle_done within + # {config.idle_response_timeout}[rdoc-ref:Config#idle_response_timeout] + # seconds. + # + # Related: #idle_done, #noop, #check + # + # ===== Capabilities + # + # The server's capabilities must include +IDLE+ + # [RFC2177[https://tools.ietf.org/html/rfc2177]]. + def idle(timeout = nil, &response_handler) + raise LocalJumpError, "no block given" unless response_handler + + response = nil + + synchronize do + tag = Thread.current[:net_imap_tag] = generate_tag + put_string("#{tag} IDLE#{CRLF}") + + begin + add_response_handler(&response_handler) + @idle_done_cond = new_cond + @idle_done_cond.wait(timeout) + @idle_done_cond = nil + if @receiver_thread_terminating + raise @exception || Net::IMAP::Error.new("connection closed") + end + ensure + unless @receiver_thread_terminating + remove_response_handler(response_handler) + put_string("DONE#{CRLF}") + response = get_tagged_response(tag, "IDLE", idle_response_timeout) + end + end + end + + return response + end + + # Leaves IDLE, allowing #idle to return. + # + # If the server does not respond within + # {config.idle_response_timeout}[rdoc-ref:Config#idle_response_timeout] + # seconds, #idle will return +nil+. + # + # Related: #idle + def idle_done + synchronize do + if @idle_done_cond.nil? + raise Net::IMAP::Error, "not during IDLE" + end + @idle_done_cond.signal + end + end + + RESPONSES_DEPRECATION_MSG = + "Pass a type or block to #responses, " \ + "set config.responses_without_block to :frozen_dup " \ + "or :silence_deprecation_warning, " \ + "or use #extract_responses or #clear_responses." + private_constant :RESPONSES_DEPRECATION_MSG + + # :call-seq: + # responses -> hash of {String => Array} (see config.responses_without_block) + # responses(type) -> frozen array + # responses {|hash| ...} -> block result + # responses(type) {|array| ...} -> block result + # + # Yields or returns unhandled server responses. Unhandled responses are + # stored in a hash, with arrays of UntaggedResponse#data keyed by + # UntaggedResponse#name and non-+nil+ untagged ResponseCode#data + # keyed by ResponseCode#name. + # + # When a block is given, yields unhandled responses and returns the block's + # result. Without a block, returns the unhandled responses. + # + # [With +type+] + # Yield or return only the array of responses for that +type+. + # When no block is given, the returned array is a frozen copy. + # [Without +type+] + # Yield or return the entire responses hash. + # + # When no block is given, the behavior is determined by + # Config#responses_without_block: + # >>> + # [+:silence_deprecation_warning+ (original behavior)] + # Returns the mutable responses hash (without any warnings). + # This is not thread-safe. + # + # [+:warn+ (default since +v0.5+)] + # Prints a warning and returns the mutable responses hash. + # This is not thread-safe. + # + # [+:frozen_dup+ (planned default for +v0.6+)] + # Returns a frozen copy of the unhandled responses hash, with frozen + # array values. + # + # [+:raise+] + # Raise an +ArgumentError+ with the deprecation warning. + # + # For example: + # + # imap.select("inbox") + # p imap.responses("EXISTS").last + # #=> 2 + # p imap.responses("UIDNEXT", &:last) + # #=> 123456 + # p imap.responses("UIDVALIDITY", &:last) + # #=> 968263756 + # p imap.responses {|responses| + # { + # exists: responses.delete("EXISTS").last, + # uidnext: responses.delete("UIDNEXT").last, + # uidvalidity: responses.delete("UIDVALIDITY").last, + # } + # } + # #=> {:exists=>2, :uidnext=>123456, :uidvalidity=>968263756} + # # "EXISTS", "UIDNEXT", and "UIDVALIDITY" have been removed: + # p imap.responses(&:keys) + # #=> ["FLAGS", "OK", "PERMANENTFLAGS", "RECENT", "HIGHESTMODSEQ"] + # + # Related: #extract_responses, #clear_responses, #response_handlers, #greeting + # + # ===== Thread safety + # >>> + # *Note:* Access to the responses hash is synchronized for thread-safety. + # The receiver thread and response_handlers cannot process new responses + # until the block completes. Accessing either the response hash or its + # response type arrays outside of the block is unsafe. They can be safely + # updated inside the block. Consider using #clear_responses or + # #extract_responses instead. + # + # Net::IMAP will add and remove responses from the responses hash and its + # array values, in the calling threads for commands and in the receiver + # thread, but will not modify any responses after adding them to the + # responses hash. + # + # ===== Clearing responses + # + # Previously unhandled responses are automatically cleared before entering a + # mailbox with #select or #examine. Long-lived connections can receive many + # unhandled server responses, which must be pruned or they will continually + # consume more memory. Update or clear the responses hash or arrays inside + # the block, or remove responses with #extract_responses, #clear_responses, + # or #add_response_handler. + # + # ===== Missing responses + # + # Only non-+nil+ data is stored. Many important response codes have no data + # of their own, but are used as "tags" on the ResponseText object they are + # attached to. ResponseText will be accessible by its response types: + # "+OK+", "+NO+", "+BAD+", "+BYE+", or "+PREAUTH+". + # + # TaggedResponse#data is not saved to #responses, nor is any + # ResponseCode#data on tagged responses. Although some command methods do + # return the TaggedResponse directly, #add_response_handler must be used to + # handle all response codes. + def responses(type = nil) + if block_given? + synchronize { yield(type ? @responses[type.to_s.upcase] : @responses) } + elsif type + synchronize { @responses[type.to_s.upcase].dup.freeze } + else + case config.responses_without_block + when :raise + raise ArgumentError, RESPONSES_DEPRECATION_MSG + when :warn + warn(RESPONSES_DEPRECATION_MSG, uplevel: 1) + when :frozen_dup + synchronize { + responses = @responses.transform_values { _1.dup.freeze } + responses.default_proc = nil + responses.default = [].freeze + return responses.freeze + } + end + @responses + end + end + + # :call-seq: + # clear_responses -> hash + # clear_responses(type) -> array + # + # Clears and returns the unhandled #responses hash or the unhandled + # responses array for a single response +type+. + # + # Clearing responses is synchronized with other threads. The lock is + # released before returning. + # + # Related: #extract_responses, #responses, #response_handlers + def clear_responses(type = nil) + synchronize { + if type + @responses.delete(type) || [] + else + @responses.dup.transform_values(&:freeze) + .tap { _1.default = [].freeze } + .tap { @responses.clear } + end + } + .freeze + end + + # :call-seq: + # extract_responses(type) {|response| ... } -> array + # + # Yields all of the unhandled #responses for a single response +type+. + # Removes and returns the responses for which the block returns a true + # value. + # + # Extracting responses is synchronized with other threads. The lock is + # released before returning. + # + # Related: #responses, #clear_responses + def extract_responses(type) + type = String.try_convert(type) or + raise ArgumentError, "type must be a string" + raise ArgumentError, "must provide a block" unless block_given? + extracted = [] + responses(type) do |all| + all.reject! do |response| + extracted << response if yield response + end + end + extracted + end + + # Returns all response handlers, including those that are added internally + # by commands. Each response handler will be called with every new + # UntaggedResponse, TaggedResponse, and ContinuationRequest. + # + # Response handlers are called with a mutex inside the receiver thread. New + # responses cannot be processed and commands from other threads must wait + # until all response_handlers return. An exception will shut-down the + # receiver thread and close the connection. + # + # For thread-safety, the returned array is a frozen copy of the internal + # array. + # + # Related: #add_response_handler, #remove_response_handler + def response_handlers + synchronize { @response_handlers.clone.freeze } + end + + # Adds a response handler. For example, to detect when + # the server sends a new EXISTS response (which normally + # indicates new messages being added to the mailbox), + # add the following handler after selecting the + # mailbox: + # + # imap.add_response_handler { |resp| + # if resp.kind_of?(Net::IMAP::UntaggedResponse) and resp.name == "EXISTS" + # puts "Mailbox now has #{resp.data} messages" + # end + # } + # + # Response handlers can also be added when the client is created before the + # receiver thread is started, by the +response_handlers+ argument to ::new. + # This ensures every server response is handled, including the #greeting. + # + # Related: #remove_response_handler, #response_handlers + def add_response_handler(handler = nil, &block) + raise ArgumentError, "two Procs are passed" if handler && block + synchronize do + @response_handlers.push(block || handler) + end + end + + # Removes the response handler. + # + # Related: #add_response_handler, #response_handlers + def remove_response_handler(handler) + synchronize do + @response_handlers.delete(handler) + end + end + + private + + CRLF = "\r\n" # :nodoc: + PORT = 143 # :nodoc: + SSL_PORT = 993 # :nodoc: + + def start_imap_connection + @greeting = get_server_greeting + @capabilities = capabilities_from_resp_code @greeting + @response_handlers.each do |handler| handler.call(@greeting) end + @receiver_thread = start_receiver_thread + rescue Exception + @sock.close + raise + end + + def get_server_greeting + greeting = get_response + raise Error, "No server greeting - connection closed" unless greeting + record_untagged_response_code greeting + raise ByeResponseError, greeting if greeting.name == "BYE" + greeting + end + + def start_receiver_thread + Thread.start do + receive_responses + rescue Exception => ex + @receiver_thread_exception = ex + # don't exit the thread with an exception + end + end + + def tcp_socket(host, port) + s = Socket.tcp(host, port, :connect_timeout => open_timeout) + s.setsockopt(:SOL_SOCKET, :SO_KEEPALIVE, true) + s + rescue Errno::ETIMEDOUT + raise Net::OpenTimeout, "Timeout to open TCP connection to " + + "#{host}:#{port} (exceeds #{open_timeout} seconds)" + end + + def receive_responses + connection_closed = false + until connection_closed + synchronize do + @exception = nil + end + begin + resp = get_response + rescue Exception => e + synchronize do + @sock.close + @exception = e + end + break + end + unless resp + synchronize do + @exception = EOFError.new("end of file reached") + end + break + end + begin + synchronize do + case resp + when TaggedResponse + @tagged_responses[resp.tag] = resp + @tagged_response_arrival.broadcast + case resp.tag + when @logout_command_tag + return + when @continued_command_tag + @continuation_request_exception = + RESPONSE_ERRORS[resp.name].new(resp) + @continuation_request_arrival.signal + end + when UntaggedResponse + record_untagged_response(resp) + if resp.name == "BYE" && @logout_command_tag.nil? + @sock.close + @exception = ByeResponseError.new(resp) + connection_closed = true + end + when ContinuationRequest + @continuation_request_arrival.signal + end + @response_handlers.each do |handler| + handler.call(resp) + end + end + rescue Exception => e + @exception = e + synchronize do + @tagged_response_arrival.broadcast + @continuation_request_arrival.broadcast + end + end + end + synchronize do + @receiver_thread_terminating = true + @tagged_response_arrival.broadcast + @continuation_request_arrival.broadcast + if @idle_done_cond + @idle_done_cond.signal + end + end + end + + def get_tagged_response(tag, cmd, timeout = nil) + if timeout + deadline = Time.now + timeout + end + until @tagged_responses.key?(tag) + raise @exception if @exception + if timeout + timeout = deadline - Time.now + if timeout <= 0 + return nil + end + end + @tagged_response_arrival.wait(timeout) + end + resp = @tagged_responses.delete(tag) + case resp.name + when /\A(?:OK)\z/ni + return resp + when /\A(?:NO)\z/ni + raise NoResponseError, resp + when /\A(?:BAD)\z/ni + raise BadResponseError, resp + else + disconnect + raise InvalidResponseError, "invalid tagged resp: %p" % [resp.raw.chomp] + end + end + + def get_response + buff = @reader.read_response_buffer + return nil if buff.length == 0 + $stderr.print(buff.gsub(/^/n, "S: ")) if config.debug? + @parser.parse(buff) + end + + ############################# + # built-in response handlers + + # store name => [..., data] + def record_untagged_response(resp) + @responses[resp.name] << resp.data + record_untagged_response_code resp + end + + # store code.name => [..., code.data] + def record_untagged_response_code(resp) + return unless resp.data.is_a?(ResponseText) + return unless (code = resp.data.code) + @responses[code.name] << code.data + end + + # NOTE: only call this for greeting, login, and authenticate + def capabilities_from_resp_code(resp) + return unless %w[PREAUTH OK].any? { _1.casecmp? resp.name } + return unless (code = resp.data.code) + return unless code.name.casecmp?("CAPABILITY") + code.data.freeze + end + + ############################# + + # Calls send_command, yielding the text of each ContinuationRequest and + # responding with each block result. Returns TaggedResponse. Raises + # NoResponseError or BadResponseError. + def send_command_with_continuations(cmd, *args) + send_command(cmd, *args) do |server_response| + if server_response.instance_of?(ContinuationRequest) + client_response = yield server_response.data.text + put_string(client_response + CRLF) + end + end + end + + def send_command(cmd, *args, &block) + synchronize do + args.each do |i| + validate_data(i) + end + tag = generate_tag + put_string(tag + " " + cmd) + args.each do |i| + put_string(" ") + send_data(i, tag) + end + guard_against_tagged_response_skipping_handler!(tag) + put_string(CRLF) + if cmd == "LOGOUT" + @logout_command_tag = tag + end + if block + add_response_handler(&block) + end + begin + return get_tagged_response(tag, cmd) + ensure + if block + remove_response_handler(block) + end + end + end + rescue InvalidResponseError + disconnect + raise + end + + def guard_against_tagged_response_skipping_handler!(tag) + return unless (resp = @tagged_responses[tag])&.name&.upcase == "OK" + raise(InvalidResponseError, + "Server sent tagged 'OK' before command was finished: %p. " \ + "This could indicate a malicious server or client-side " \ + "command injection. Disconnecting." % [resp.raw_data.chomp]) + end + + def generate_tag + @tagno += 1 + return format("%s%04d", @tag_prefix, @tagno) + end + + def put_string(str) + @sock.print(str) + if config.debug? + if @debug_output_bol + $stderr.print("C: ") + end + $stderr.print(str.gsub(/\n/n) { $'.empty? ? $& : "\nC: " }) + if /\n\z/n.match(str) + @debug_output_bol = true + else + @debug_output_bol = false + end + end + end + + def search_internal(cmd, keys, charset) + if keys.instance_of?(String) + keys = [RawData.new(keys)] + else + normalize_searching_criteria(keys) + end + synchronize do + if charset + send_command(cmd, "CHARSET", charset, *keys) + else + send_command(cmd, *keys) + end + clear_responses("SEARCH").last || [] + end + end + + def fetch_internal(cmd, set, attr, mod = nil, changedsince: nil) + if changedsince + mod ||= [] + mod << "CHANGEDSINCE" << Integer(changedsince) + end + case attr + when String then + attr = RawData.new(attr) + when Array then + attr = attr.map { |arg| + arg.is_a?(String) ? RawData.new(arg) : arg + } + end + + synchronize do + clear_responses("FETCH") + if mod + send_command(cmd, MessageSet.new(set), attr, mod) + else + send_command(cmd, MessageSet.new(set), attr) + end + clear_responses("FETCH") + end + end + + def store_internal(cmd, set, attr, flags, unchangedsince: nil) + attr = Atom.new(attr) if attr.instance_of?(String) + args = [MessageSet.new(set)] + args << ["UNCHANGEDSINCE", Integer(unchangedsince)] if unchangedsince + args << attr << flags + synchronize do + clear_responses("FETCH") + send_command(cmd, *args) + clear_responses("FETCH") + end + end + + def copy_internal(cmd, set, mailbox) + send_command(cmd, MessageSet.new(set), mailbox) + end + + def sort_internal(cmd, sort_keys, search_keys, charset) + if search_keys.instance_of?(String) + search_keys = [RawData.new(search_keys)] + else + normalize_searching_criteria(search_keys) + end + synchronize do + send_command(cmd, sort_keys, charset, *search_keys) + clear_responses("SORT").last || [] + end + end + + def thread_internal(cmd, algorithm, search_keys, charset) + if search_keys.instance_of?(String) + search_keys = [RawData.new(search_keys)] + else + normalize_searching_criteria(search_keys) + end + synchronize do + send_command(cmd, algorithm, charset, *search_keys) + clear_responses("THREAD").last || [] + end + end + + def normalize_searching_criteria(keys) + keys.collect! do |i| + case i + when -1, Range, Array + MessageSet.new(i) + else + i + end + end + end + + def build_ssl_ctx(ssl) + if ssl + params = (Hash.try_convert(ssl) || {}).freeze + context = SSLContext.new + context.set_params(params) + if defined?(VerifyCallbackProc) + context.verify_callback = VerifyCallbackProc + end + context.freeze + [params, context] + else + false + end + end + + def start_tls_session + raise "SSL extension not installed" unless defined?(OpenSSL::SSL) + raise "already using SSL" if @sock.kind_of?(OpenSSL::SSL::SSLSocket) + raise "cannot start TLS without SSLContext" unless ssl_ctx + @sock = SSLSocket.new(@sock, ssl_ctx) + @reader = ResponseReader.new(self, @sock) + @sock.sync_close = true + @sock.hostname = @host if @sock.respond_to? :hostname= + ssl_socket_connect(@sock, open_timeout) + if ssl_ctx.verify_mode != VERIFY_NONE + @sock.post_connection_check(@host) + @tls_verified = true + end + end + + def sasl_adapter + SASLAdapter.new(self, &method(:send_command_with_continuations)) + end + + #-- + # We could get the saslprep method by extending the SASLprep module + # directly. It's done indirectly, so SASLprep can be lazily autoloaded, + # because most users won't need it. + #++ + # Delegates to Net::IMAP::StringPrep::SASLprep#saslprep. + def self.saslprep(string, **opts) + Net::IMAP::StringPrep::SASLprep.saslprep(string, **opts) + end + + end +end + +require_relative "imap/errors" +require_relative "imap/config" +require_relative "imap/command_data" +require_relative "imap/data_encoding" +require_relative "imap/flags" +require_relative "imap/response_data" +require_relative "imap/response_parser" +require_relative "imap/authenticators" + +require_relative "imap/deprecated_client_options" +Net::IMAP.prepend Net::IMAP::DeprecatedClientOptions diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/net-imap.gemspec ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/net-imap.gemspec --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/net-imap.gemspec 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/net-imap.gemspec 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,38 @@ +# frozen_string_literal: true + +name = File.basename(__FILE__, ".gemspec") +version = ["lib", Array.new(name.count("-"), "..").join("/")].find do |dir| + break File.foreach(File.join(__dir__, dir, "#{name.tr('-', '/')}.rb"), :encoding=> 'utf-8') do |line| + /^\s*VERSION\s*=\s*"(.*)"/ =~ line and break $1 + end rescue nil +end + +Gem::Specification.new do |spec| + spec.name = name + spec.version = version + spec.authors = ["Shugo Maeda", "nicholas a. evans"] + spec.email = ["shugo@ruby-lang.org", "nick@rubinick.dev"] + + spec.summary = %q{Ruby client api for Internet Message Access Protocol} + spec.description = %q{Ruby client api for Internet Message Access Protocol} + spec.homepage = "https://github.com/ruby/net-imap" + spec.required_ruby_version = Gem::Requirement.new(">= 2.7.3") + spec.licenses = ["Ruby", "BSD-2-Clause"] + + spec.metadata["homepage_uri"] = spec.homepage + spec.metadata["source_code_uri"] = spec.homepage + spec.metadata["changelog_uri"] = spec.homepage + "/releases" + + # Specify which files should be added to the gem when it is released. + # The `git ls-files -z` loads the files in the RubyGem that have been added into git. + spec.files = Dir.chdir(__dir__) do + `git ls-files -z 2>/dev/null`.split("\x0") + .grep_v(%r{^(\.git(ignore)?|\.mailmap|(\.github|bin|test|spec|benchmarks|features|rfcs)/)}) + end + spec.bindir = "exe" + spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) } + spec.require_paths = ["lib"] + + spec.add_dependency "net-protocol" + spec.add_dependency "date" +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/rakelib/benchmarks.rake ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/rakelib/benchmarks.rake --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/rakelib/benchmarks.rake 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/rakelib/benchmarks.rake 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,91 @@ +# frozen_string_literal: true + +PARSER_TEST_FIXTURES = FileList.new "test/net/imap/fixtures/response_parser/*.yml" +CLOBBER.include "benchmarks/parser.yml" +CLEAN.include "benchmarks/Gemfile-*" + +BENCHMARK_INIT = < PARSER_TEST_FIXTURES do |t| + require "yaml" + require "pathname" + require "net/imap" + + path = Pathname.new(__dir__) / "../test/net/imap/fixtures/response_parser" + files = path.glob("*.yml") + tests = files.flat_map {|file| + file.read + .gsub(%r{([-:]) !ruby/(object|struct|array):\S+}) { $1 } + .then { + YAML.safe_load(_1, filename: file, + permitted_classes: [Symbol, Regexp], aliases: true) + } + .fetch(:tests) + .select {|test_name, test| + :parser_assert_equal == test.fetch(:test_type) { + test.key?(:expected) ? :parser_assert_equal : :parser_pending + } + } + .map {|test_name, test| [test_name.to_s, test.fetch(:response)] } + } + + benchmarks = tests.map {|fixture_name, response| + {"name" => fixture_name.delete_prefix("test_"), + "prelude" => "response = -%s.b" % [response.dump], + "script" => "parser.parse(response)"} + } + .sort_by { _1["name"] } + + YAML.dump({"prelude" => BENCHMARK_INIT, "benchmark" => benchmarks}) + .then { File.write t.name, _1 } +end + +namespace :benchmarks do + desc "Generate benchmarks from fixture data" + task :generate => "benchmarks/parser.yml" + + desc "run the parser benchmarks comparing multiple gem versions" + task :compare => :generate do |task, args| + cd Pathname.new(__dir__) + ".." + current = `git describe --tags --dirty`.chomp + current = "dev" if current.empty? + versions = args.to_a + if versions.empty? + latest = %x{git describe --tags --abbrev=0 --match 'v*.*.*'}.chomp + versions = latest.empty? ? [] : [latest.delete_prefix("v")] + end + versions = versions.to_h { [_1, "Gemfile-v#{_1}"] } + cd "benchmarks" do + versions.each do |version, gemfile| + File.write gemfile, <<~RUBY + # frozen_string_literal: true + source "https://rubygems.org" + gem "net-imap", #{version.dump} + RUBY + end + versions = {current => "../Gemfile" , **versions}.map { + "%s::/usr/bin/env BUNDLE_GEMFILE=%s ruby" % _1 + }.join(";") + + extra = ENV.fetch("BENCHMARK_ARGS", "").shellsplit + + sh("benchmark-driver", + "--bundler", + "-e", versions, + "parser.yml", + *extra) + end + end + +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/rakelib/rdoc.rake ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/rakelib/rdoc.rake --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/rakelib/rdoc.rake 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/rakelib/rdoc.rake 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,70 @@ +# require "sdoc" +require "rdoc/task" +require_relative "../lib/net/imap" +require 'rdoc/rdoc' unless defined?(RDoc::Markup::ToHtml) + +module RDoc::Generator + module NetIMAP + + module RemoveRedundantParens + def param_seq + super.sub(/^\(\)\s*/, "") + end + end + + # See https://github.com/ruby/rdoc/pull/936 + module FixSectionComments + def markup(text) + @store ||= @parent&.store + super + end + def description; markup comment end + def comment; super || @comments&.first end + def parse(_comment_location = nil) super() end + end + + # render "[label] data" lists as tables. adapted from "hanna-nouveau" gem. + module LabelListTable + def list_item_start(list_item, list_type) + case list_type + when :NOTE + %(#{Array(list_item.label).map{|label| to_html(label)}.join("
")}) + else + super + end + end + + def list_end_for(list_type) + case list_type + when :NOTE then + "" + else + super + end + end + end + + end +end + +class RDoc::AnyMethod + prepend RDoc::Generator::NetIMAP::RemoveRedundantParens +end + +class RDoc::Context::Section + prepend RDoc::Generator::NetIMAP::FixSectionComments +end + +class RDoc::Markup::ToHtml + LIST_TYPE_TO_HTML[:NOTE] = ['', '
'] + prepend RDoc::Generator::NetIMAP::LabelListTable +end + +RDoc::Task.new do |doc| + doc.main = "README.md" + doc.title = "net-imap #{Net::IMAP::VERSION}" + doc.rdoc_dir = "doc" + doc.rdoc_files = FileList.new %w[lib/**/*.rb *.rdoc *.md] + doc.options << "--template-stylesheets" << "docs/styles.css" + # doc.generator = "hanna" +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/rakelib/rfcs.rake ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/rakelib/rfcs.rake --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/rakelib/rfcs.rake 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/rakelib/rfcs.rake 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,168 @@ +# frozen_string_literal: true + +RFCS = { + + # Historic IMAP RFCs + 822 => "Internet Message Format (OBSOLETE)", + 1730 => "IMAP4 (OBSOLETE)", + 1731 => "IMAP4 Authentication Mechanisms (OBSOLETE)", + 2060 => "IMAP4rev1 (OBSOLETE)", + 2061 => "IMAP4 Compatibility with IMAP2bis", + 2062 => "Internet Message Access Protocol - Obsolete Syntax", + 2086 => "IMAP ACL (OBSOLETE)", + 2087 => "IMAP QUOTA (OBSOLETE)", + 2088 => "IMAP LITERAL+ (OBSOLETE)", + 2095 => "IMAP/POP AUTHorize Extension for CRAM-MD5 (OBSOLETE)", + 2192 => "IMAP URL Scheme (OBSOLETE)", + 2222 => "SASL (OBSOLETE)", + 2359 => "IMAP UIDPLUS (OBSOLETE)", + 2822 => "Internet Message Format (OBSOLETE)", + 3348 => "IMAP CHILDREN (OBSOLETED)", + 4551 => "IMAP CONDSTORE (OBSOLETE)", + 5162 => "IMAP QRESYNC (OBSOLETE)", + 6237 => "IMAP MULTISEARCH (OBSOLETE)", + + # Core IMAP RFCs + 3501 => "IMAP4rev1", # supported by nearly all email servers + 4466 => "Collected Extensions to IMAP4 ABNF", + 9051 => "IMAP4rev2", # not widely supported yet + + # RFC-9051 Normative References (not a complete list) + 2152 => "UTF-7", + 2180 => "IMAP4 Multi-Accessed Mailbox Practice", + 2683 => "IMAP4 Implementation Recommendations", + 3503 => "Message Disposition Notification (MDN) profile IMAP", + 5234 => "ABNF", + 5788 => "IMAP4 keyword registry", + + # Internet Message format and envelope and body structure + 5322 => "Internet Message Format (current)", + + 1864 => "[MD5]: The Content-MD5 Header Field", + 2045 => "[MIME-IMB]: MIME Part One: Format of Internet Message Bodies", + 2046 => "[MIME-IMT]: MIME Part Two: Media Types", + 2047 => "[MIME-HDRS]: MIME Part Three: Header Extensions for Non-ASCII Text", + 2183 => "[DISPOSITION]: The Content-Disposition Header", + 2231 => "MIME Parameter Value and Encoded Word Extensions: " \ + "Character Sets, Languages, and Continuations", + 2557 => "[LOCATION]: MIME Encapsulation of Aggregate Documents", + 2978 => "[CHARSET]: IANA Charset Registration Procedures, BCP 19", + 3282 => "[LANGUAGE-TAGS]: Content Language Headers", + 6532 => "[I18N-HDRS]: Internationalized Email Headers", + + # SASL + 4422 => "SASL, EXTERNAL", + + # stringprep + 3454 => "stringprep", + 4013 => "SASLprep", + 8265 => "PRECIS", # obsoletes SASLprep? + + # SASL mechanisms (not a complete list) + 2195 => "SASL CRAM-MD5", + 4505 => "SASL ANONYMOUS", + 4616 => "SASL PLAIN", + 4752 => "SASL GSSAPI (Kerberos V5)", + 5801 => "SASL GS2-*, GS2-KRB5", + 5802 => "SASL SCRAM-*, SCRAM-SHA-1, SCRAM-SHA1-PLUS", + 5803 => "LDAP Schema for Storing SCRAM Secrets", + 6331 => "SASL DIGEST-MD5", + 6595 => "SASL SAML20", + 6616 => "SASL OPENID20", + 7628 => "SASL OAUTH10A, OAUTHBEARER", + 7677 => "SASL SCRAM-SHA-256, SCRAM-SHA256-PLUS", + + # "Informational" RFCs + 1733 => "Distributed E-Mail Models in IMAP4", + 4549 => "Synchronization Operations for Disconnected IMAP4 Clients", + + # TLS and other security concerns + 2595 => "Using TLS with IMAP, POP3 and ACAP", + 6151 => "Updated Security Considerations for MD5 Message-Digest and HMAC-MD5", + 7525 => "Recommendations for Secure Use of TLS and DTLS", + 7818 => "Updated TLS Server Identity Check Procedure for Email Protocols", + 8314 => "Cleartext Considered Obsolete: Use of TLS for Email", + 8996 => "Deprecating TLS 1.0 and TLS 1.1,", + + # related email specifications + 6376 => "DomainKeys Identified Mail (DKIM) Signatures", + 6409 => "Message Submission for Mail", + + # Other IMAP4 "Standards Track" RFCs + 5092 => "IMAP URL Scheme", + 5593 => "IMAP URL Access Identifier Extension", + 5530 => "IMAP Response Codes", + 6186 => "Use of SRV Records for Locating Email Submission/Access Services", + 8305 => "Happy Eyeballs Version 2: Better Connectivity Using Concurrency", + + # IMAP4 Extensions + 2177 => "IMAP IDLE", + 2193 => "IMAP MAILBOX-REFERRALS", + 2221 => "IMAP LOGIN-REFERRALS", + 2342 => "IMAP NAMESPACE", + 2971 => "IMAP ID", + 3502 => "IMAP MULTIAPPEND", + 3516 => "IMAP BINARY", + 3691 => "IMAP UNSELECT", + 4314 => "IMAP ACL, RIGHTS=", + 4315 => "IMAP UIDPLUS", + 4467 => "IMAP URLAUTH", + 4469 => "IMAP CATENATE", + 4731 => "IMAP ESEARCH", + 4959 => "IMAP SASL-IR", + 4978 => "IMAP COMPRESS=DEFLATE", + 5032 => "IMAP WITHIN", + 5161 => "IMAP ENABLE", + 5182 => "IMAP SEARCHRES", + 5255 => "IMAP I18NLEVEL=1, I18NLEVEL=2, LANGUAGE", + 5256 => "IMAP SORT, THREAD", + 5257 => "IMAP ANNOTATE-EXPERIMENT-1", + 5258 => "IMAP LIST-EXTENDED", + 5259 => "IMAP CONVERT", + 5267 => "IMAP CONTEXT=SEARCH, CONTEXT=SORT, ESORT", + 5464 => "IMAP METADATA, METADATA-SERVER", + 5465 => "IMAP NOTIFY", + 5466 => "IMAP FILTERS", + 5524 => "IMAP URLAUTH=BINARY", # see also: [RFC Errata 6214] + 5550 => "IMAP URL-PARTIAL", + 5738 => "IMAP UTF8=ALL, UTF8=APPEND, UTF8=USER", # OBSOLETED by RFC6855 + 5819 => "IMAP LIST-STATUS", + 5957 => "IMAP SORT=DISPLAY", + 6154 => "IMAP SPECIAL-USE, CREATE-SPECIAL-USE", + 6203 => "IMAP SEARCH=FUZZY", + 6785 => "IMAP IMAPSIEVE=", + 6851 => "IMAP MOVE", + 6855 => "IMAP UTF8=ACCEPT, UTF8=ONLY", + 7162 => "IMAP CONDSTORE, QRESYNC", + 7377 => "IMAP MULTISEARCH", + 7888 => "IMAP LITERAL+, LITERAL-", + 7889 => "IMAP APPENDLIMIT", + 8437 => "IMAP UNAUTHENTICATE", + 8438 => "IMAP STATUS=SIZE", + 8440 => "IMAP LIST-MYRIGHTS", + 8474 => "IMAP OBJECTID", + 8508 => "IMAP REPLACE", + 8514 => "IMAP SAVEDATE", + 8970 => "IMAP PREVIEW", + 9208 => "IMAP QUOTA, QUOTA=, QUOTASET", + + # etc... + 3629 => "UTF8", + 6857 => "Post-Delivery Message Downgrading for I18n Email Messages", + +}.freeze + +task :rfcs => RFCS.keys.map {|n| "rfcs/rfc%04d.txt" % [n] } + +RFC_RE = %r{rfcs/rfc(\d+).*\.txt}.freeze +rule RFC_RE do |t| + require "fileutils" + FileUtils.mkpath "rfcs" + require "net/http" + t.name =~ RFC_RE + rfc_url = URI("https://www.rfc-editor.org/rfc/rfc#$1.txt") + rfc_txt = Net::HTTP.get(rfc_url) + File.write(t.name, rfc_txt) +end + +CLEAN.include "rfcs/rfc*.txt" diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/rakelib/saslprep.rake ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/rakelib/saslprep.rake --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/rakelib/saslprep.rake 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/rakelib/saslprep.rake 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,30 @@ +# frozen_string_literal: true + +require_relative "string_prep_tables_generator" + +generator = StringPrepTablesGenerator.new + +file generator.json_filename => generator.json_deps do |t| + generator.generate_json_data_file +end + +directory "lib/net/imap/sasl" + +file "lib/net/imap/stringprep/tables.rb" => generator.rb_deps do |t| + File.write t.name, generator.stringprep_rb +end + +file "lib/net/imap/stringprep/saslprep_tables.rb" => generator.rb_deps do |t| + File.write t.name, generator.saslprep_rb +end + +GENERATED_RUBY = FileList.new( + "lib/net/imap/stringprep/tables.rb", + "lib/net/imap/stringprep/saslprep_tables.rb", +) + +CLEAN.include generator.clean_deps +CLOBBER.include GENERATED_RUBY + +task saslprep_rb: GENERATED_RUBY +task test: :saslprep_rb diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/rakelib/string_prep_tables_generator.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/rakelib/string_prep_tables_generator.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/rakelib/string_prep_tables_generator.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/rakelib/string_prep_tables_generator.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,445 @@ +# frozen_string_literal: true + +# Generator for stringprep regexps. +# +# Combines Unicode character classes with generated tables. Generated regexps +# are still used to test that the written regexps conform to the specification. +# Some tables don't match up well with any character properties available to +# ruby's regexp engine. Those use the table-generated regexps. +class StringPrepTablesGenerator + STRINGPREP_RFC_FILE = "rfcs/rfc3454.txt" + STRINGPREP_JSON_FILE = "rfcs/rfc3454-stringprep_tables.json" + + # valid UTF-8 can't contain these codepoints + # checking for them anyway, using /\p{Cs}/ ;) + SURROGATES_RANGE = 0xD800..0xDFFF + + attr_reader :json_filename, :rfc_filename + + def initialize(rfc_filename: STRINGPREP_RFC_FILE, + json_filename: STRINGPREP_JSON_FILE) + @rfc_filename = rfc_filename + @json_filename = json_filename + end + + # for rake deps + def json_deps; Rake::FileList.new __FILE__, STRINGPREP_RFC_FILE end + def rb_deps; Rake::FileList.new __FILE__, STRINGPREP_JSON_FILE end + def clean_deps; Rake::FileList.new STRINGPREP_JSON_FILE end + + def generate_json_data_file + require "json" + rfc_filename + .then(&File.method(:read)) + .then(&method(:parse_rfc_text)) + .then(&JSON.method(:pretty_generate)) + .then {|data| File.write json_filename, data } + end + + def tables; @tables ||= load_tables_and_titles_from_json!.first end + def titles; @titles ||= load_tables_and_titles_from_json!.last end + def ranges; @ranges ||= tables.transform_values(&method(:to_ranges)) end + def arrays; @arrays ||= ranges.transform_values{|t| t.flat_map(&:to_a) } end + def sets; @sets ||= arrays.transform_values(&:to_set) end + def regexps; @regexps ||= arrays.transform_values(&method(:to_regexp)) end + def asgn_regexps; @asgn_regexps || asgn_regexps! end + + def merged_tables_regex(*table_names, negate: false) + table_names + .flat_map(&arrays.method(:fetch)) + .then {|array| to_regexp(array, negate: negate) } + end + + def regexp_for(*names, negate: false) + asgn_regexps[[*names, negate]] ||= merged_tables_regex(*names, negate: negate) + end + + def stringprep_rb + <<~RUBY + # frozen_string_literal: true + + #-- + # This file is generated from RFC3454, by rake. Don't edit directly. + #++ + + module Net::IMAP::StringPrep + + module Tables + + #{asgn_table "A.1"} + + #{asgn_table "B.1"} + + #{asgn_table "B.2"} + + #{asgn_table "B.3"} + + #{asgn_mapping "B.1", ""} + + #{asgn_mapping "B.2"} + + #{asgn_mapping "B.3"} + + #{asgn_table "C.1.1"} + + #{asgn_table "C.1.2"} + + #{asgn_table "C.2.1"} + + #{asgn_table "C.2.2"} + + #{asgn_table "C.3"} + + #{asgn_table "C.4"} + + #{asgn_table "C.5"} + + #{asgn_table "C.6"} + + #{asgn_table "C.7"} + + #{asgn_table "C.8"} + + #{asgn_table "C.9"} + + #{asgn_table "D.1"} + + # Used to check req3 of bidirectional checks + #{asgn_table "D.1", negate: true} + + #{asgn_table "D.2"} + + BIDI_DESC_REQ2 = "A string with RandALCat characters must not contain LCat characters." + + # Bidirectional Characters [StringPrep, §6], Requirement 2 + # >>> + # If a string contains any RandALCat character, the string MUST NOT + # contain any LCat character. + BIDI_FAILS_REQ2 = #{bidi_fails_req2.inspect}.freeze + + BIDI_DESC_REQ3 = "A string with RandALCat characters must start and end with RandALCat characters." + + # Bidirectional Characters [StringPrep, §6], Requirement 3 + # >>> + # If a string contains any RandALCat character, a RandALCat + # character MUST be the first character of the string, and a + # RandALCat character MUST be the last character of the string. + BIDI_FAILS_REQ3 = #{bidi_fails_req3.inspect}.freeze + + # Bidirectional Characters [StringPrep, §6] + BIDI_FAILURE = #{bidi_failure_regexp.inspect}.freeze + + # Names of each codepoint table in the RFC-3454 appendices + TITLES = { + #{table_titles_rb} + }.freeze + + # Regexps matching each codepoint table in the RFC-3454 appendices + REGEXPS = { + #{table_regexps_rb} + }.freeze + + MAPPINGS = { + "B.1" => [IN_B_1, MAP_B_1].freeze, + "B.2" => [IN_B_2, MAP_B_2].freeze, + "B.3" => [IN_B_3, MAP_B_3].freeze, + }.freeze + + end + end + RUBY + end + + def table_titles_rb(indent = 3) + titles + .map{|t| "%p => %p," % t } + .join("\n#{" "*indent}") + end + + def table_regexps_rb(indent = 3) + asgn_regexps # => { ["A.1", false] => regexp, ... } + .reject {|(_, n), _| n } + .map {|(t, _), _| "%p => %s," % [t, regexp_const_name(t)] } + .join("\n#{" "*indent}") + end + + def saslprep_rb + <<~RUBY + # frozen_string_literal: true + + #-- + # This file is generated from RFC3454, by rake. Don't edit directly. + #++ + + module Net::IMAP::StringPrep + + module SASLprep + + # RFC4013 §2.1 Mapping - mapped to space + # >>> + # non-ASCII space characters (\\StringPrep\\[\\"C.1.2\\"]) that can + # be mapped to SPACE (U+0020) + # + # Equal to \\StringPrep\\[\\"C.1.2\\"]. + # Redefined here to avoid loading StringPrep::Tables unless necessary. + MAP_TO_SPACE = #{regex_str "C.1.2"} + + # RFC4013 §2.1 Mapping - mapped to nothing + # >>> + # the "commonly mapped to nothing" characters + # (\\StringPrep\\[\\"B.1\\"]) that can be mapped to nothing. + # + # Equal to \\StringPrep\\[\\"B.1\\"]. + # Redefined here to avoid loading StringPrep::Tables unless necessary. + MAP_TO_NOTHING = #{regex_str "B.1"} + + # RFC4013 §2.3 Prohibited Output + # >>> + # * Non-ASCII space characters — \\StringPrep\\[\\"C.1.2\\"] + # * ASCII control characters — \\StringPrep\\[\\"C.2.1\\"] + # * Non-ASCII control characters — \\StringPrep\\[\\"C.2.2\\"] + # * Private Use characters — \\StringPrep\\[\\"C.3\\"] + # * Non-character code points — \\StringPrep\\[\\"C.4\\"] + # * Surrogate code points — \\StringPrep\\[\\"C.5\\"] + # * Inappropriate for plain text characters — \\StringPrep\\[\\"C.6\\"] + # * Inappropriate for canonical representation characters — \\StringPrep\\[\\"C.7\\"] + # * Change display properties or deprecated characters — \\StringPrep\\[\\"C.8\\"] + # * Tagging characters — \\StringPrep\\[\\"C.9\\"] + TABLES_PROHIBITED = #{SASL_TABLES_PROHIBITED.inspect}.freeze + + # Adds unassigned (by Unicode 3.2) codepoints to TABLES_PROHIBITED. + # + # RFC4013 §2.5 Unassigned Code Points + # >>> + # This profile specifies the \\StringPrep\\[\\"A.1\\"] table as its + # list of unassigned code points. + TABLES_PROHIBITED_STORED = ["A.1", *TABLES_PROHIBITED].freeze + + # A Regexp matching codepoints prohibited by RFC4013 §2.3. + # + # This combines all of the TABLES_PROHIBITED tables. + PROHIBITED_OUTPUT = #{regex_str(*SASL_TABLES_PROHIBITED)} + + # RFC4013 §2.5 Unassigned Code Points + # >>> + # This profile specifies the \\StringPrep\\[\\"A.1\\"] table as its + # list of unassigned code points. + # + # Equal to \\StringPrep\\[\\"A.1\\"]. + # Redefined here to avoid loading StringPrep::Tables unless necessary. + UNASSIGNED = #{regex_str "A.1"} + + # A Regexp matching codepoints prohibited by RFC4013 §2.3 and §2.5. + # + # This combines PROHIBITED_OUTPUT and UNASSIGNED. + PROHIBITED_OUTPUT_STORED = Regexp.union( + UNASSIGNED, PROHIBITED_OUTPUT + ).freeze + + # Bidirectional Characters [StringPrep, §6] + # + # A Regexp for strings that don't satisfy StringPrep's Bidirectional + # Characters rules. + # + # Equal to StringPrep::Tables::BIDI_FAILURE. + # Redefined here to avoid loading StringPrep::Tables unless necessary. + BIDI_FAILURE = #{bidi_failure_regexp.inspect}.freeze + + # A Regexp matching strings prohibited by RFC4013 §2.3 and §2.4. + # + # This combines PROHIBITED_OUTPUT and BIDI_FAILURE. + PROHIBITED = Regexp.union( + PROHIBITED_OUTPUT, BIDI_FAILURE, + ) + + # A Regexp matching strings prohibited by RFC4013 §2.3, §2.4, and §2.5. + # + # This combines PROHIBITED_OUTPUT_STORED and BIDI_FAILURE. + PROHIBITED_STORED = Regexp.union( + PROHIBITED_OUTPUT_STORED, BIDI_FAILURE, + ) + + end + end + RUBY + end + + private + + def parse_rfc_text(rfc3454_text) + titles = {} + tables, = rfc3454_text + .lines + .each_with_object([]) {|line, acc| + current, table = acc.last + case line + when /^([A-D]\.[1-9](?:\.[1-9])?) (.*)/ + titles[$1] = $2 + when /^ {3}-{5} Start Table (\S*)/ + acc << [$1, []] + when /^ {3}-{5} End Table / + acc << [nil, nil] + when /^ {3}([0-9A-F]+); ([ 0-9A-F]*)(?:;[^;]*)$/ # mapping tables + table << [$1, $2.split(/ +/)] if current + when /^ {3}([-0-9A-F]+)(?:;[^;]*)?$/ # regular tables + table << $1 if current + when /^ {3}(.*)/ + raise "expected to match %p" % $1 if current + end + } + .to_h.compact + .transform_values {|t| t.first.size == 2 ? t.to_h : t } + tables["titles"] = titles + tables + end + + def load_tables_and_titles_from_json! + require "json" + @tables = json_filename + .then(&File.method(:read)) + .then(&JSON.method(:parse)) + @titles = @tables.delete "titles" + [@tables, @titles] + end + + def to_ranges(table) + (table.is_a?(Hash) ? table.keys : table) + .map{|range| range.split(?-).map{|cp| Integer cp, 16} } + .map{|s,e| s..(e || s)} + end + + # TODO: DRY with unicode_normalize + def to_map(table) + table = table.to_hash + .transform_keys { Integer _1, 16 } + .transform_keys { [_1].pack("U*") } + .transform_values {|cps| cps.map { Integer _1, 16 } } + .transform_values { _1.pack("U*") } + end + + # Starting from a codepoints array (rather than ranges) to deduplicate merged + # tables. + def to_regexp(codepoints, negate: false) + codepoints + .grep_v(SURROGATES_RANGE) # remove surrogate codepoints from C.5 and D.2 + .uniq + .sort + .chunk_while {|cp1,cp2| cp1 + 1 == cp2 } # find contiguous chunks + .map {|chunk| chunk.map{|cp| "%04x" % cp } } # convert to hex strings + .partition {|chunk| chunk[1] } # ranges vs singles + .then {|ranges, singles| + singles.flatten! + [ + negate ? "^" : "", + singles.flatten.any? ? "\\u{%s}" % singles.join(" ") : "", + ranges.map {|r| "\\u{%s}-\\u{%s}" % [r.first, r.last] }.join, + codepoints.any?(SURROGATES_RANGE) ? "\\p{Cs}" : "", # not necessary :) + ].join + } + .then {|char_class| Regexp.new "[#{char_class}]" } + end + + def asgn_regexps! + @asgn_regexps = {} + # preset the regexp for each table + asgn_regex "A.1", /\p{^AGE=3.2}/ + # If ruby supported all unicode properties (i.e. line break = word joiner): + # /[\u{00ad 034f 1806}\p{join_c}\p{VS}\p{lb=WJ}&&\p{age=3.2}]/ + asgn_table "B.1" + asgn_table "B.2" + asgn_table "B.3" + asgn_regex "C.1.1", / / + asgn_regex "C.1.2", /[\u200b\p{Zs}&&[^ ]]/ + asgn_regex "C.2.1", /[\x00-\x1f\x7f]/ + # C.2.2 is a union: + # Cc + Cf (as defined by Unicode 3.2) + Zl + Zp + 0xfffc + # - any codepoints covered by C.2.1 or C.8 or C.9 + # + # But modern Unicode properties are significantly different, so it's better + # to just load the table definition. + asgn_table "C.2.2" + asgn_regex "C.3", /\p{private use}/ + asgn_regex "C.4", /\p{noncharacter code point}/ + asgn_regex "C.5", /\p{surrogate}/ + asgn_regex "C.6", /[\p{in specials}&&\p{AGE=3.2}&&\p{^NChar}]/ + asgn_regex "C.7", /[\p{in ideographic description characters}&&\p{AGE=3.2}]/ + # C.8 is a union of \p{Bidi Control} and Unicode 3.2 properties. But those properties + # have changed for modern Unicode, and thus for modern ruby's regexp + # character properties. It's better to just load the table definition. + asgn_table "C.8" + asgn_regex "C.9", /[\p{in Tags}&&\p{AGE=3.2}]/ + # Unfortunately, ruby doesn't (currently) support /[\p{Bidi + # Class=R}\p{bc=AL}]/. On the other hand, StringPrep (based on Unicode 3.2) + # might not be a good match for the modern (14.0) property value anyway. + asgn_table "D.1" + asgn_table "D.1", negate: true # used by BIDI_FAILS_REQ3 + asgn_table "D.2" + @asgn_regexps + end + + def regex_str(*names, negate: false) + "%p.freeze" % regexp_for(*names, negate: negate) + end + + def asgn_table(name, negate: false) + asgn_regex(name, regexp_for(name, negate: negate), negate: negate) + end + + def asgn_mapping(name, replacement = to_map(tables[name])) + cname = name.tr(?., ?_).upcase + "# Replacements for %s\n%s%s = %p.freeze" % [ + "IN_#{name}", " " * 2, "MAP_#{cname}", replacement, + ] + end + + def regexp_const_desc(name, negate: false) + if negate then "Matches the negation of the %s table" % [name] + else %q{%s \\StringPrep\\[\\"%s\\"]} % [titles.fetch(name), name] + end + end + + def regexp_const_name(table_name, negate: false) + "IN_%s%s" % [table_name.tr(".", "_"), negate ? "_NEGATED" : ""] + end + + def asgn_regex(name, regexp, negate: false) + asgn_regexps[[name, negate]] = regexp + "# %s\n%s%s = %p.freeze" % [ + regexp_const_desc(name, negate: negate), " " * 4, + regexp_const_name(name, negate: negate), + regexp, + ] + end + + def bidi_R_AL ; regexp_for "D.1" end + def bidi_not_R_AL ; regexp_for "D.1", negate: true end + def bidi_L ; regexp_for "D.2" end + + def bidi_fails_req2 + Regexp.union( + /#{bidi_R_AL}.*?#{bidi_L}/mu, # RandALCat followed by LCat + /#{bidi_L}.*?#{bidi_R_AL}/mu, # RandALCat preceded by LCat + ) + end + + def bidi_fails_req3 + # contains RandALCat: + Regexp.union( + /\A#{bidi_not_R_AL}.*?#{bidi_R_AL}/mu, # but doesn't start with RandALCat + /#{bidi_R_AL}.*?#{bidi_not_R_AL}\z/mu, # but doesn't end with RandALCat + ) + end + + def bidi_failure_regexp + Regexp.union(bidi_fails_req2, bidi_fails_req3) + end + + SASL_TABLES_PROHIBITED = %w[ + C.1.2 C.2.1 C.2.2 C.3 C.4 C.5 C.6 C.7 C.8 C.9 + ].freeze + + SASL_TABLES_PROHIBITED_STORED = %w[ + A.1 C.1.2 C.2.1 C.2.2 C.3 C.4 C.5 C.6 C.7 C.8 C.9 + ].freeze + +end diff -Nru ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/sample/net-imap.rb ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/sample/net-imap.rb --- ruby3.3-3.3.8/.bundle/gems/net-imap-0.4.25/sample/net-imap.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/net-imap-0.4.25/sample/net-imap.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,167 @@ +require 'net/imap' +require "getoptlong" + +$stdout.sync = true +$port = nil +$user = ENV["USER"] || ENV["LOGNAME"] +$auth = "login" +$ssl = false +$starttls = false + +def usage + < + + --help print this message + --port=PORT specifies port + --user=USER specifies user + --auth=AUTH specifies auth type + --starttls use starttls + --ssl use ssl +EOF +end + +begin + require 'io/console' +rescue LoadError + def _noecho(&block) + system("stty", "-echo") + begin + yield STDIN + ensure + system("stty", "echo") + end + end +else + def _noecho(&block) + STDIN.noecho(&block) + end +end + +def get_password + print "password: " + begin + return _noecho(&:gets).chomp + ensure + puts + end +end + +def get_command + printf("%s@%s> ", $user, $host) + if line = gets + return line.strip.split(/\s+/) + else + return nil + end +end + +parser = GetoptLong.new +parser.set_options(['--debug', GetoptLong::NO_ARGUMENT], + ['--help', GetoptLong::NO_ARGUMENT], + ['--port', GetoptLong::REQUIRED_ARGUMENT], + ['--user', GetoptLong::REQUIRED_ARGUMENT], + ['--auth', GetoptLong::REQUIRED_ARGUMENT], + ['--starttls', GetoptLong::NO_ARGUMENT], + ['--ssl', GetoptLong::NO_ARGUMENT]) +begin + parser.each_option do |name, arg| + case name + when "--port" + $port = arg + when "--user" + $user = arg + when "--auth" + $auth = arg + when "--ssl" + $ssl = true + when "--starttls" + $starttls = true + when "--debug" + Net::IMAP.debug = true + when "--help" + usage + exit + end + end +rescue + abort usage +end + +$host = ARGV.shift +unless $host + abort usage +end + +imap = Net::IMAP.new($host, :port => $port, :ssl => $ssl) +begin + imap.starttls if $starttls + class << password = method(:get_password) + alias to_str call + end + imap.authenticate($auth, $user, password) + while true + cmd, *args = get_command + break unless cmd + begin + case cmd + when "list" + for mbox in imap.list("", args[0] || "*") + if mbox.attr.include?(Net::IMAP::NOSELECT) + prefix = "!" + elsif mbox.attr.include?(Net::IMAP::MARKED) + prefix = "*" + else + prefix = " " + end + print prefix, mbox.name, "\n" + end + when "select" + imap.select(args[0] || "inbox") + print "ok\n" + when "close" + imap.close + print "ok\n" + when "summary" + unless messages = imap.responses["EXISTS"][-1] + puts "not selected" + next + end + if messages > 0 + for data in imap.fetch(1..-1, ["ENVELOPE"]) + print data.seqno, ": ", data.attr["ENVELOPE"].subject, "\n" + end + else + puts "no message" + end + when "fetch" + if args[0] + data = imap.fetch(args[0].to_i, ["RFC822.HEADER", "RFC822.TEXT"])[0] + puts data.attr["RFC822.HEADER"] + puts data.attr["RFC822.TEXT"] + else + puts "missing argument" + end + when "logout", "exit", "quit" + break + when "help", "?" + print <` comments. - * GH-147 - * Patch by Hiroya Fujinami. - - * Added support for detecting unclosed `DOCTYPE`. - * GH-152 - * Patch by Hiroya Fujinami. - - * Added `changlog_uri` metadata to gemspec. - * GH-156 - * Patch by fynsta. - - * Improved parse performance. - * GH-157 - * GH-158 - * Patch by NAITOH Jun. - -### Fixes - - * Fixed a bug that large XML can't be parsed. - * GH-154 - * Patch by NAITOH Jun. - - * Fixed a bug that private constants are visible. - * GH-155 - * Patch by NAITOH Jun. - -### Thanks - - * Hiroya Fujinami - - * NAITOH Jun - - * fynsta - -## 3.3.0 - 2024-06-11 {#version-3-3-0} - -### Improvements - - * Added support for strscan 0.7.0 installed with Ruby 2.6. - * GH-142 - * Reported by Fernando Trigoso. - -### Thanks - - * Fernando Trigoso - -## 3.2.9 - 2024-06-09 {#version-3-2-9} - -### Improvements - - * Added support for old strscan. - * GH-132 - * Reported by Adam. - - * Improved attribute value parse performance. - * GH-135 - * Patch by NAITOH Jun. - - * Improved `REXML::Node#each_recursive` performance. - * GH-134 - * GH-139 - * Patch by Hiroya Fujinami. - - * Improved text parse performance. - * Reported by mprogrammer. - -### Thanks - - * Adam - * NAITOH Jun - * Hiroya Fujinami - * mprogrammer - -## 3.2.8 - 2024-05-16 {#version-3-2-8} - -### Fixes - - * Suppressed a warning - -## 3.2.7 - 2024-05-16 {#version-3-2-7} - -### Improvements - - * Improve parse performance by using `StringScanner`. - - * GH-106 - * GH-107 - * GH-108 - * GH-109 - * GH-112 - * GH-113 - * GH-114 - * GH-115 - * GH-116 - * GH-117 - * GH-118 - * GH-119 - * GH-121 - - * Patch by NAITOH Jun. - - * Improved parse performance when an attribute has many `<`s. - - * GH-126 - -### Fixes - - * XPath: Fixed a bug of `normalize_space(array)`. - - * GH-110 - * GH-111 - - * Patch by flatisland. - - * XPath: Fixed a bug that wrong position is used with nested path. - - * GH-110 - * GH-122 - - * Reported by jcavalieri. - * Patch by NAITOH Jun. - - * Fixed a bug that an exception message can't be generated for - invalid encoding XML. - - * GH-29 - * GH-123 - - * Reported by DuKewu. - * Patch by NAITOH Jun. - -### Thanks - - * NAITOH Jun - * flatisland - * jcavalieri - * DuKewu - -## 3.2.6 - 2023-07-27 {#version-3-2-6} - -### Improvements - - * Required Ruby 2.5 or later explicitly. - [GH-69][gh-69] - [Patch by Ivo Anjo] - - * Added documentation for maintenance cycle. - [GH-71][gh-71] - [Patch by Ivo Anjo] - - * Added tutorial. - [GH-77][gh-77] - [GH-78][gh-78] - [Patch by Burdette Lamar] - - * Improved performance and memory usage. - [GH-94][gh-94] - [Patch by fatkodima] - - * `REXML::Parsers::XPathParser#abbreviate`: Added support for - function arguments. - [GH-95][gh-95] - [Reported by pulver] - - * `REXML::Parsers::XPathParser#abbreviate`: Added support for string - literal that contains double-quote. - [GH-96][gh-96] - [Patch by pulver] - - * `REXML::Parsers::XPathParser#abbreviate`: Added missing `/` to - `:descendant_or_self/:self/:parent`. - [GH-97][gh-97] - [Reported by pulver] - - * `REXML::Parsers::XPathParser#abbreviate`: Added support for more patterns. - [GH-97][gh-97] - [Reported by pulver] - -### Fixes - - * Fixed a typo in NEWS. - [GH-72][gh-72] - [Patch by Spencer Goodman] - - * Fixed a typo in NEWS. - [GH-75][gh-75] - [Patch by Andrew Bromwich] - - * Fixed documents. - [GH-87][gh-87] - [Patch by Alexander Ilyin] - - * Fixed a bug that `Attriute` convert `'` and `'` even when - `attribute_quote: :quote` is used. - [GH-92][gh-92] - [Reported by Edouard Brière] - - * Fixed links in tutorial. - [GH-99][gh-99] - [Patch by gemmaro] - - -### Thanks - - * Ivo Anjo - - * Spencer Goodman - - * Andrew Bromwich - - * Burdette Lamar - - * Alexander Ilyin - - * Edouard Brière - - * fatkodima - - * pulver - - * gemmaro - -[gh-69]:https://github.com/ruby/rexml/issues/69 -[gh-71]:https://github.com/ruby/rexml/issues/71 -[gh-72]:https://github.com/ruby/rexml/issues/72 -[gh-75]:https://github.com/ruby/rexml/issues/75 -[gh-77]:https://github.com/ruby/rexml/issues/77 -[gh-87]:https://github.com/ruby/rexml/issues/87 -[gh-92]:https://github.com/ruby/rexml/issues/92 -[gh-94]:https://github.com/ruby/rexml/issues/94 -[gh-95]:https://github.com/ruby/rexml/issues/95 -[gh-96]:https://github.com/ruby/rexml/issues/96 -[gh-97]:https://github.com/ruby/rexml/issues/97 -[gh-98]:https://github.com/ruby/rexml/issues/98 -[gh-99]:https://github.com/ruby/rexml/issues/99 - -## 3.2.5 - 2021-04-05 {#version-3-2-5} - -### Improvements - - * Add more validations to XPath parser. - - * `require "rexml/document"` by default. - [GitHub#36][Patch by Koichi ITO] - - * Don't add `#dclone` method to core classes globally. - [GitHub#37][Patch by Akira Matsuda] - - * Add more documentations. - [Patch by Burdette Lamar] - - * Added `REXML::Elements#parent`. - [GitHub#52][Patch by Burdette Lamar] - -### Fixes - - * Fixed a bug that `REXML::DocType#clone` doesn't copy external ID - information. - - * Fixed round-trip vulnerability bugs. - See also: https://www.ruby-lang.org/en/news/2021/04/05/xml-round-trip-vulnerability-in-rexml-cve-2021-28965/ - [HackerOne#1104077][CVE-2021-28965][Reported by Juho Nurminen] - -### Thanks - - * Koichi ITO - - * Akira Matsuda - - * Burdette Lamar - - * Juho Nurminen - -## 3.2.4 - 2020-01-31 {#version-3-2-4} - -### Improvements - - * Don't use `taint` with Ruby 2.7 or later. - [GitHub#21][Patch by Jeremy Evans] - -### Fixes - - * Fixed a `elsif` typo. - [GitHub#22][Patch by Nobuyoshi Nakada] - -### Thanks - - * Jeremy Evans - - * Nobuyoshi Nakada - -## 3.2.3 - 2019-10-12 {#version-3-2-3} - -### Fixes - - * Fixed a bug that `REXML::XMLDecl#close` doesn't copy `@writethis`. - [GitHub#20][Patch by hirura] - -### Thanks - - * hirura - -## 3.2.2 - 2019-06-03 {#version-3-2-2} - -### Fixes - - * xpath: Fixed a bug for equality and relational expressions. - [GitHub#17][Reported by Mirko Budszuhn] - - * xpath: Fixed `boolean()` implementation. - - * xpath: Fixed `local_name()` with nonexistent node. - - * xpath: Fixed `number()` implementation with node set. - [GitHub#18][Reported by Mirko Budszuhn] - -### Thanks - - * Mirko Budszuhn - -## 3.2.1 - 2019-05-04 {#version-3-2-1} - -### Improvements - - * Improved error message. - [GitHub#12][Patch by FUJI Goro] - - * Improved error message. - [GitHub#16][Patch by ujihisa] - - * Improved documentation markup. - [GitHub#14][Patch by Alyssa Ross] - -### Fixes - - * Fixed a bug that `nil` variable value raises an unexpected exception. - [GitHub#13][Patch by Alyssa Ross] - -### Thanks - - * FUJI Goro - - * Alyssa Ross - - * ujihisa - -## 3.2.0 - 2019-01-01 {#version-3-2-0} - -### Fixes - - * Fixed a bug that no namespace attribute isn't matched with prefix. - - [ruby-list:50731][Reported by Yasuhiro KIMURA] - - * Fixed a bug that the default namespace is applied to attribute names. - - NOTE: It's a backward incompatible change. If your program has any - problem with this change, please report it. We may revert this fix. - - * `REXML::Attribute#prefix` returns `""` for no namespace attribute. - - * `REXML::Attribute#namespace` returns `""` for no namespace attribute. - -### Thanks - - * Yasuhiro KIMURA - -## 3.1.9 - 2018-12-20 {#version-3-1-9} - -### Improvements - - * Improved backward compatibility. - - Restored `REXML::Parsers::BaseParser::UNQME_STR` because it's used - by kramdown. - -## 3.1.8 - 2018-12-20 {#version-3-1-8} - -### Improvements - - * Added support for customizing quote character in prologue. - [GitHub#8][Bug #9367][Reported by Takashi Oguma] - - * You can use `"` as quote character by specifying `:quote` to - `REXML::Document#context[:prologue_quote]`. - - * You can use `'` as quote character by specifying `:apostrophe` - to `REXML::Document#context[:prologue_quote]`. - - * Added processing instruction target check. The target must not nil. - [GitHub#7][Reported by Ariel Zelivansky] - - * Added name check for element and attribute. - [GitHub#7][Reported by Ariel Zelivansky] - - * Stopped to use `Exception`. - [GitHub#9][Patch by Jean Boussier] - -### Fixes - - * Fixed a bug that `REXML::Text#clone` escapes value twice. - [ruby-dev:50626][Bug #15058][Reported by Ryosuke Nanba] - -### Thanks - - * Takashi Oguma - - * Ariel Zelivansky - - * Jean Boussier - - * Ryosuke Nanba diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/README.md ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/README.md --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/README.md 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/README.md 1970-01-01 00:00:00.000000000 +0000 @@ -1,57 +0,0 @@ -# REXML - -REXML was inspired by the Electric XML library for Java, which features an easy-to-use API, small size, and speed. Hopefully, REXML, designed with the same philosophy, has these same features. I've tried to keep the API as intuitive as possible, and have followed the Ruby methodology for method naming and code flow, rather than mirroring the Java API. - -REXML supports both tree and stream document parsing. Stream parsing is faster (about 1.5 times as fast). However, with stream parsing, you don't get access to features such as XPath. - -## API - -See the [API documentation](https://ruby.github.io/rexml/). - -## Usage - -We'll start with parsing an XML document - -```ruby -require "rexml/document" -file = File.new( "mydoc.xml" ) -doc = REXML::Document.new file -``` - -Line 3 creates a new document and parses the supplied file. You can also do the following - -```ruby -require "rexml/document" -include REXML # so that we don't have to prefix everything with REXML::... -string = < - Text, text, text - -EOF -doc = Document.new string -``` - -So parsing a string is just as easy as parsing a file. - -## Support - -REXML support follows the same maintenance cycle as Ruby releases, as shown on . - -If you are running on an end-of-life Ruby, do not expect modern REXML releases to be compatible with it; in fact, it's recommended that you DO NOT use this gem, and instead use the REXML version that came bundled with your end-of-life Ruby version. - -The `required_ruby_version` on the gemspec is kept updated on a [best-effort basis](https://github.com/ruby/rexml/pull/70) by the community. -Up to version 3.2.5, this information was not set. That version [is known broken with at least Ruby < 2.3](https://github.com/ruby/rexml/issues/69). - -## Development - -After checking out the repo, run `rake test` to run the tests. - -To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org). - -## Contributing - -Bug reports and pull requests are welcome on GitHub at https://github.com/ruby/rexml. - -## License - -The gem is available as open source under the terms of the [BSD-2-Clause](LICENSE.txt). diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/context.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/context.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/context.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/context.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,143 +0,0 @@ -== Element Context - -Notes: -- All code on this page presupposes that the following has been executed: - - require 'rexml/document' - -- For convenience, examples on this page use +REXML::Document.new+, not +REXML::Element.new+. - This is completely valid, because REXML::Document is a subclass of REXML::Element. - -The context for an element is a hash of processing directives -that influence the way \XML is read, stored, and written. -The context entries are: - -- +:respect_whitespace+: controls treatment of whitespace. -- +:compress_whitespace+: determines whether whitespace is compressed. -- +:ignore_whitespace_nodes+: determines whether whitespace-only nodes are to be ignored. -- +:raw+: controls treatment of special characters and entities. - -The default context for a new element is {}. -You can set the context at element-creation time: - - d = REXML::Document.new('', {compress_whitespace: :all, raw: :all}) - d.context # => {:compress_whitespace=>:all, :raw=>:all} - -You can reset the entire context by assigning a new hash: - - d.context = {ignore_whitespace_nodes: :all} - d.context # => {:ignore_whitespace_nodes=>:all} - -Or you can create or modify an individual entry: - - d.context[:raw] = :all - d.context # => {:ignore_whitespace_nodes=>:all, :raw=>:all} - -=== +:respect_whitespace+ - -Affects: +REXML::Element.new+, +REXML::Element.text=+. - -By default, all parsed whitespace is respected (that is, stored whitespace not compressed): - - xml_string = 'a b c d e f' - d = REXML::Document.new(xml_string) - d.to_s # => "a b c d e f" - -Use +:respect_whitespace+ with an array of element names -to specify the elements that _are_ to have their whitespace respected; -other elements' whitespace, and whitespace between elements, will be compressed. - -In this example: +foo+ and +baz+ will have their whitespace respected; -+bar+ and the space between elements will have their whitespace compressed: - - d = REXML::Document.new(xml_string, {respect_whitespace: ['foo', 'baz']}) - d.to_s # => "a b c d e f" - bar = d.root[2] # => ... - bar.text = 'X Y' - d.to_s # => "a b X Y e f" - -=== +:compress_whitespace+ - -Affects: +REXML::Element.new+, +REXML::Element.text=+. - -Use compress_whitespace: :all -to compress whitespace both within and between elements: - - xml_string = 'a b c d e f' - d = REXML::Document.new(xml_string, {compress_whitespace: :all}) - d.to_s # => "a b c d e f" - -Use +:compress_whitespace+ with an array of element names -to compress whitespace in those elements, -but not in other elements nor between elements. - -In this example, +foo+ and +baz+ will have their whitespace compressed; -+bar+ and the space between elements will not: - - d = REXML::Document.new(xml_string, {compress_whitespace: ['foo', 'baz']}) - d.to_s # => "a b c d e f" - foo = d.root[0] # => ... - foo.text= 'X Y' - d.to_s # => "X Y c d e f" - -=== +:ignore_whitespace_nodes+ - -Affects: +REXML::Element.new+. - -Use ignore_whitespace_nodes: :all to omit all whitespace-only elements. - -In this example, +bar+ has a text node, while nodes +foo+ and +baz+ do not: - - xml_string = ' BAR ' - d = REXML::Document.new(xml_string, {ignore_whitespace_nodes: :all}) - d.to_s # => " FOO BAZ " - root = d.root # => ... - foo = root[0] # => - bar = root[1] # => ... - baz = root[2] # => - foo.first.class # => NilClass - bar.first.class # => REXML::Text - baz.first.class # => NilClass - -Use +:ignore_whitespace_nodes+ with an array of element names -to specify the elements that are to have whitespace nodes ignored. - -In this example, +bar+ and +baz+ have text nodes, while node +foo+ does not. - - xml_string = ' BAR ' - d = REXML::Document.new(xml_string, {ignore_whitespace_nodes: ['foo']}) - d.to_s # => " BAR " - root = d.root # => ... - foo = root[0] # => - bar = root[1] # => ... - baz = root[2] # => ... - foo.first.class # => NilClass - bar.first.class # => REXML::Text - baz.first.class # => REXML::Text - -=== +:raw+ - -Affects: +Element.text=+, +Element.add_text+, +Text.to_s+. - -Parsing of +a+ elements is not affected by +raw+: - - xml_string = '0 < 11 > 0' - d = REXML::Document.new(xml_string, {:raw => ['a']}) - d.root.to_s # => "0 < 11 > 0" - a, b = *d.root.elements - a.to_s # => "0 < 1" - b.to_s # => "1 > 0" - -But Element#text= is affected: - - a.text = '0 < 1' - b.text = '1 > 0' - a.to_s # => "0 < 1" - b.to_s # => "1 &gt; 0" - -As is Element.add_text: - - a.add_text(' so 1 > 0') - b.add_text(' so 0 < 1') - a.to_s # => "0 < 1 so 1 > 0" - b.to_s # => "1 &gt; 0 so 0 &lt; 1" diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/child.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/child.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/child.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/child.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,87 +0,0 @@ -== Class Child - -Class Child includes module Node; -see {Tasks for Node}[node_rdoc.html]. - -:include: ../tocs/child_toc.rdoc - -=== Relationships - -==== Task: Set the Parent - -Use method {Child#parent=}[../../../../REXML/Parent.html#method-i-parent-3D] -to set the parent: - - e0 = REXML::Element.new('foo') - e1 = REXML::Element.new('bar') - e1.parent # => nil - e1.parent = e0 - e1.parent # => - -==== Task: Insert Previous Sibling - -Use method {Child#previous_sibling=}[../../../../REXML/Parent.html#method-i-previous_sibling-3D] -to insert a previous sibling: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.to_a # => [, ] - c = d.root[1] # => - b = REXML::Element.new('b') - c.previous_sibling = b - d.root.to_a # => [, , ] - -==== Task: Insert Next Sibling - -Use method {Child#next_sibling=}[../../../../REXML/Parent.html#method-i-next-sibling-3D] -to insert a previous sibling: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.to_a # => [, ] - a = d.root[0] # => - b = REXML::Element.new('b') - a.next_sibling = b - d.root.to_a # => [, , ] - -=== Removal or Replacement - -==== Task: Remove Child from Parent - -Use method {Child#remove}[../../../../REXML/Parent.html#method-i-remove] -to remove a child from its parent; returns the removed child: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.to_a # => [, , ] - b = d.root[1] # => - b.remove # => - d.root.to_a # => [, ] - -==== Task: Replace Child - -Use method {Child#replace_with}[../../../../REXML/Parent.html#method-i-replace] -to replace a child; -returns the replaced child: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.to_a # => [, , ] - b = d.root[1] # => - d = REXML::Element.new('d') - b.replace_with(d) # => - d.root.to_a # => [, , ] - -=== Document - -==== Task: Get the Document - -Use method {Child#document}[../../../../REXML/Parent.html#method-i-document] -to get the document for the child: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.to_a # => [, , ] - b = d.root[1] # => - b.document == d # => true - REXML::Child.new.document # => nil diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/document.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/document.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/document.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/document.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,276 +0,0 @@ -== Class Document - -Class Document has methods from its superclasses and included modules; -see: - -- {Tasks for Element}[element_rdoc.html]. -- {Tasks for Parent}[parent_rdoc.html]. -- {Tasks for Child}[child_rdoc.html]. -- {Tasks for Node}[node_rdoc.html]. -- {Module Enumerable}[https://docs.ruby-lang.org/en/master/Enumerable.html]. - -:include: ../tocs/document_toc.rdoc - -=== New Document - -==== Task: Create an Empty Document - -Use method {Document::new}[../../../../REXML/Document.html#method-c-new] -to create an empty document. - - d = REXML::Document.new - -==== Task: Parse a \String into a New Document - -Use method {Document::new}[../../../../REXML/Document.html#method-c-new] -to parse an XML string into a new document: - - xml_string = 'textmore' - d = REXML::Document.new(xml_string) - d.root # => ... - -==== Task: Parse an \IO Stream into a New Document - -Use method {Document::new}[../../../../REXML/Document.html#method-c-new] -to parse an XML \IO stream into a new document: - - xml_string = 'textmore' - File.write('t.xml', xml_string) - d = File.open('t.xml', 'r') do |file| - REXML::Document.new(file) - end - d.root # => ... - -==== Task: Create a Document from an Existing Document - -Use method {Document::new}[../../../../REXML/Document.html#method-c-new] -to create a document from an existing document. -The context and attributes are copied to the new document, -but not the children: - - xml_string = 'textmore' - d = REXML::Document.new(xml_string) - d.children # => [ ... ] - d.context = {raw: :all, compress_whitespace: :all} - d.add_attributes({'bar' => 0, 'baz' => 1}) - d1 = REXML::Document.new(d) - d1.context # => {:raw=>:all, :compress_whitespace=>:all} - d1.attributes # => {"bar"=>bar='0', "baz"=>baz='1'} - d1.children # => [] - -==== Task: Clone a Document - -Use method {Document#clone}[../../../../REXML/Document.html#method-i-clone] -to clone a document. -The context and attributes are copied to the new document, -but not the children: - - xml_string = 'textmore' - d = REXML::Document.new(xml_string) - d.children # => [ ... ] - d.context = {raw: :all, compress_whitespace: :all} - d.add_attributes({'bar' => 0, 'baz' => 1}) - d1 = d.clone # => < bar='0' baz='1'/> - d1.context # => {:raw=>:all, :compress_whitespace=>:all} - d1.attributes # => {"bar"=>bar='0', "baz"=>baz='1'} - d1.children # => [] - -=== Document Type - -==== Task: Get the Document Type - -Use method {Document#doctype}[../../../../REXML/Document.html#method-i-doctype] -to get the document type: - - d = REXML::Document.new('') - d.doctype.class # => REXML::DocType - d = REXML::Document.new('') - d.doctype.class # => nil - -==== Task: Set the Document Type - -Use method {document#add}[../../../../REXML/Document.html#method-i-add] -to add or replace the document type: - - d = REXML::Document.new('') - d.doctype.class # => nil - d.add(REXML::DocType.new('foo')) - d.doctype.class # => REXML::DocType - -=== XML Declaration - -==== Task: Get the XML Declaration - -Use method {document#xml_decl}[../../../../REXML/Document.html#method-i-xml_decl] -to get the XML declaration: - - d = REXML::Document.new('') - d.xml_decl.class # => REXML::XMLDecl - d.xml_decl # => - d = REXML::Document.new('') - d.xml_decl.class # => REXML::XMLDecl - d.xml_decl # => - -==== Task: Set the XML Declaration - -Use method {document#add}[../../../../REXML/Document.html#method-i-add] -to replace the XML declaration: - - d = REXML::Document.new('') - d.add(REXML::XMLDecl.new) - -=== Children - -==== Task: Add an Element Child - -Use method -{document#add_element}[../../../../REXML/Document.html#method-i-add_element] -to add an element to the document: - - d = REXML::Document.new('') - d.add_element(REXML::Element.new('root')) - d.children # => [] - -==== Task: Add a Non-Element Child - -Use method -{document#add}[../../../../REXML/Document.html#method-i-add] -to add a non-element to the document: - - xml_string = 'textmore' - d = REXML::Document.new(xml_string) - d.add(REXML::Text.new('foo')) - d.children # => [ ... , "foo"] - -=== Writing - -==== Task: Write to $stdout - -Use method -{document#write}[../../../../REXML/Document.html#method-i-write] -to write the document to $stdout: - - xml_string = 'textmore' - d = REXML::Document.new(xml_string) - d.write - -Output: - - textmore - -==== Task: Write to IO Stream - -Use method -{document#write}[../../../../REXML/Document.html#method-i-write] -to write the document to $stdout: - - xml_string = 'textmore' - d = REXML::Document.new(xml_string) - File.open('t.xml', 'w') do |file| - d.write(file) - end - p File.read('t.xml') - -Output: - - "textmore" - -==== Task: Write with No Indentation - -Use method -{document#write}[../../../../REXML/Document.html#method-i-write] -to write the document with no indentation: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.write({indent: 0}) - -Output: - - - - - - - - - -==== Task: Write with Specified Indentation - -Use method -{document#write}[../../../../REXML/Document.html#method-i-write] -to write the document with a specified indentation: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.write({indent: 2}) - -Output: - - - - - - - - - -=== Querying - -==== Task: Get the Document - -Use method -{document#document}[../../../../REXML/Document.html#method-i-document] -to get the document (+self+); overrides Element#document: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.document == d # => true - -==== Task: Get the Encoding - -Use method -{document#document}[../../../../REXML/Document.html#method-i-document] -to get the document (+self+); overrides Element#document: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.encoding # => "UTF-8" - -==== Task: Get the Node Type - -Use method -{document#node_type}[../../../../REXML/Document.html#method-i-node_type] -to get the node type (+:document+); overrides Element#node_type: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.node_type # => :document - -==== Task: Get the Root Element - -Use method -{document#root}[../../../../REXML/Document.html#method-i-root] -to get the root element: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root # => ... - -==== Task: Determine Whether Stand-Alone - -Use method -{document#stand_alone?}[../../../../REXML/Document.html#method-i-stand_alone-3F] -to get the stand-alone value: - - d = REXML::Document.new('') - d.stand_alone? # => "yes" - -==== Task: Get the Version - -Use method -{document#version}[../../../../REXML/Document.html#method-i-version] -to get the version: - - d = REXML::Document.new('') - d.version # => "2.0" diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/element.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/element.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/element.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/element.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,602 +0,0 @@ -== Class Element - -Class Element has methods from its superclasses and included modules; -see: - -- {Tasks for Parent}[parent_rdoc.html]. -- {Tasks for Child}[child_rdoc.html]. -- {Tasks for Node}[node_rdoc.html]. -- {Module Enumerable}[https://docs.ruby-lang.org/en/master/Enumerable.html]. - -:include: ../tocs/element_toc.rdoc - -=== New Element - -==== Task: Create a Default Element - -Use method -{Element::new}[../../../../REXML/Element.html#method-c-new] -with no arguments to create a default element: - - e = REXML::Element.new - e.name # => "UNDEFINED" - e.parent # => nil - e.context # => nil - -==== Task: Create a Named Element - -Use method -{Element::new}[../../../../REXML/Element.html#method-c-new] -with a string name argument -to create a named element: - - e = REXML::Element.new('foo') - e.name # => "foo" - e.parent # => nil - e.context # => nil - -==== Task: Create an Element with Name and Parent - -Use method -{Element::new}[../../../../REXML/Element.html#method-c-new] -with name and parent arguments -to create an element with name and parent: - - p = REXML::Parent.new - e = REXML::Element.new('foo', p) - e.name # => "foo" - e.parent # => #]> - e.context # => nil - -==== Task: Create an Element with Name, Parent, and Context - -Use method -{Element::new}[../../../../REXML/Element.html#method-c-new] -with name, parent, and context arguments -to create an element with name, parent, and context: - - p = REXML::Parent.new - e = REXML::Element.new('foo', p, {compress_whitespace: :all}) - e.name # => "foo" - e.parent # => #]> - e.context # => {:compress_whitespace=>:all} - -==== Task: Create a Shallow Clone - -Use method -{Element#clone}[../../../../REXML/Element.html#method-i-clone] -to create a shallow clone of an element, -copying only the name, attributes, and context: - - e0 = REXML::Element.new('foo', nil, {compress_whitespace: :all}) - e0.add_attribute(REXML::Attribute.new('bar', 'baz')) - e0.context = {compress_whitespace: :all} - e1 = e0.clone # => - e1.name # => "foo" - e1.context # => {:compress_whitespace=>:all} - -=== Attributes - -==== Task: Create and Add an Attribute - -Use method -{Element#add_attribute}[../../../../REXML/Element.html#method-i-add_attribute] -to create and add an attribute: - - e = REXML::Element.new - e.add_attribute('attr', 'value') # => "value" - e['attr'] # => "value" - e.add_attribute('attr', 'VALUE') # => "VALUE" - e['attr'] # => "VALUE" - -==== Task: Add an Existing Attribute - -Use method -{Element#add_attribute}[../../../../REXML/Element.html#method-i-add_attribute] -to add an existing attribute: - - e = REXML::Element.new - a = REXML::Attribute.new('attr', 'value') - e.add_attribute(a) - e['attr'] # => "value" - a = REXML::Attribute.new('attr', 'VALUE') - e.add_attribute(a) - e['attr'] # => "VALUE" - -==== Task: Add Multiple Attributes from a Hash - -Use method -{Element#add_attributes}[../../../../REXML/Element.html#method-i-add_attributes] -to add multiple attributes from a hash: - - e = REXML::Element.new - h = {'foo' => 0, 'bar' => 1} - e.add_attributes(h) - e['foo'] # => "0" - e['bar'] # => "1" - -==== Task: Add Multiple Attributes from an Array - -Use method -{Element#add_attributes}[../../../../REXML/Element.html#method-i-add_attributes] -to add multiple attributes from an array: - - e = REXML::Element.new - a = [['foo', 0], ['bar', 1]] - e.add_attributes(a) - e['foo'] # => "0" - e['bar'] # => "1" - -==== Task: Retrieve the Value for an Attribute Name - -Use method -{Element#[]}[../../../../REXML/Element.html#method-i-5B-5D] -to retrieve the value for an attribute name: - - e = REXML::Element.new - e.add_attribute('attr', 'value') # => "value" - e['attr'] # => "value" - -==== Task: Retrieve the Attribute Value for a Name and Namespace - -Use method -{Element#attribute}[../../../../REXML/Element.html#method-i-attribute] -to retrieve the value for an attribute name: - - xml_string = "" - d = REXML::Document.new(xml_string) - e = d.root - e.attribute("x") # => x='x' - e.attribute("x", "a") # => a:x='a:x' - -==== Task: Delete an Attribute - -Use method -{Element#delete_attribute}[../../../../REXML/Element.html#method-i-delete_attribute] -to remove an attribute: - - e = REXML::Element.new('foo') - e.add_attribute('bar', 'baz') - e.delete_attribute('bar') - e.delete_attribute('bar') - e['bar'] # => nil - -==== Task: Determine Whether the Element Has Attributes - -Use method -{Element#has_attributes?}[../../../../REXML/Element.html#method-i-has_attributes-3F] -to determine whether the element has attributes: - - e = REXML::Element.new('foo') - e.has_attributes? # => false - e.add_attribute('bar', 'baz') - e.has_attributes? # => true - -=== Children - -Element Children - -==== Task: Create and Add an Element - -Use method -{Element#add_element}[../../../../REXML/Element.html#method-i-add_element] -to create a new element and add it to this element: - - e0 = REXML::Element.new('foo') - e0.add_element('bar') - e0.children # => [] - -==== Task: Add an Existing Element - -Use method -{Element#add_element}[../../../../REXML/Element.html#method-i-add_element] -to add an element to this element: - - e0 = REXML::Element.new('foo') - e1 = REXML::Element.new('bar') - e0.add_element(e1) - e0.children # => [] - -==== Task: Create and Add an Element with Attributes - -Use method -{Element#add_element}[../../../../REXML/Element.html#method-i-add_element] -to create a new element with attributes, and add it to this element: - - e0 = REXML::Element.new('foo') - e0.add_element('bar', {'name' => 'value'}) - e0.children # => [] - -==== Task: Add an Existing Element with Added Attributes - -Use method -{Element#add_element}[../../../../REXML/Element.html#method-i-add_element] -to add an element to this element: - - e0 = REXML::Element.new('foo') - e1 = REXML::Element.new('bar') - e0.add_element(e1, {'name' => 'value'}) - e0.children # => [] - -==== Task: Delete a Specified Element - -Use method -{Element#delete_element}[../../../../REXML/Element.html#method-i-delete_element] -to remove a specified element from this element: - - e0 = REXML::Element.new('foo') - e1 = REXML::Element.new('bar') - e0.add_element(e1) - e0.children # => [] - e0.delete_element(e1) - e0.children # => [] - -==== Task: Delete an Element by Index - -Use method -{Element#delete_element}[../../../../REXML/Element.html#method-i-delete_element] -to remove an element from this element by index: - - e0 = REXML::Element.new('foo') - e1 = REXML::Element.new('bar') - e0.add_element(e1) - e0.children # => [] - e0.delete_element(1) - e0.children # => [] - -==== Task: Delete an Element by XPath - -Use method -{Element#delete_element}[../../../../REXML/Element.html#method-i-delete_element] -to remove an element from this element by XPath: - - e0 = REXML::Element.new('foo') - e1 = REXML::Element.new('bar') - e0.add_element(e1) - e0.children # => [] - e0.delete_element('//bar/') - e0.children # => [] - -==== Task: Determine Whether Element Children - -Use method -{Element#has_elements?}[../../../../REXML/Element.html#method-i-has_elements-3F] -to determine whether the element has element children: - - e0 = REXML::Element.new('foo') - e0.has_elements? # => false - e0.add_element(REXML::Element.new('bar')) - e0.has_elements? # => true - -==== Task: Get Element Descendants by XPath - -Use method -{Element#get_elements}[../../../../REXML/Element.html#method-i-get_elements] -to fetch all element descendant children by XPath: - - xml_string = <<-EOT - - - - - - EOT - d = REXML::Document.new(xml_string) - d.root.get_elements('//a') # => [ ... , ] - -==== Task: Get Next Element Sibling - -Use method -{Element#next_element}[../../../../REXML/Element.html#method-i-next_element] -to retrieve the next element sibling: - - d = REXML::Document.new 'text' - d.root.elements['b'].next_element #-> - d.root.elements['c'].next_element #-> nil - -==== Task: Get Previous Element Sibling - -Use method -{Element#previous_element}[../../../../REXML/Element.html#method-i-previous_element] -to retrieve the previous element sibling: - - d = REXML::Document.new 'text' - d.root.elements['c'].previous_element #-> - d.root.elements['b'].previous_element #-> nil - -Text Children - -==== Task: Add a Text Node - -Use method -{Element#add_text}[../../../../REXML/Element.html#method-i-add_text] -to add a text node to the element: - - d = REXML::Document.new('foobar') - e = d.root - e.add_text(REXML::Text.new('baz')) - e.to_a # => ["foo", , "bar", "baz"] - e.add_text(REXML::Text.new('baz')) - e.to_a # => ["foo", , "bar", "baz", "baz"] - -==== Task: Replace the First Text Node - -Use method -{Element#text=}[../../../../REXML/Element.html#method-i-text-3D] -to replace the first text node in the element: - - d = REXML::Document.new('textmore') - e = d.root - e.to_a # => [, "text", , "more", ] - e.text = 'oops' - e.to_a # => [, "oops", , "more", ] - -==== Task: Remove the First Text Node - -Use method -{Element#text=}[../../../../REXML/Element.html#method-i-text-3D] -to remove the first text node in the element: - - d = REXML::Document.new('textmore') - e = d.root - e.to_a # => [, "text", , "more", ] - e.text = nil - e.to_a # => [, , "more", ] - -==== Task: Retrieve the First Text Node - -Use method -{Element#get_text}[../../../../REXML/Element.html#method-i-get_text] -to retrieve the first text node in the element: - - d = REXML::Document.new('textmore') - e = d.root - e.to_a # => [, "text", , "more", ] - e.get_text # => "text" - -==== Task: Retrieve a Specific Text Node - -Use method -{Element#get_text}[../../../../REXML/Element.html#method-i-get_text] -to retrieve the first text node in a specified element: - - d = REXML::Document.new "some text this is bold! more text" - e = d.root - e.get_text('//root') # => "some text " - e.get_text('//b') # => "this is bold!" - -==== Task: Determine Whether the Element has Text Nodes - -Use method -{Element#has_text?}[../../../../REXML/Element.html#method-i-has_text-3F] -to determine whether the element has text: - - e = REXML::Element.new('foo') - e.has_text? # => false - e.add_text('bar') - e.has_text? # => true - -Other Children - -==== Task: Get the Child at a Given Index - -Use method -{Element#[]}[../../../../REXML/Element.html#method-i-5B-5D] -to retrieve the child at a given index: - - d = REXML::Document.new '>textmore' - e = d.root - e[0] # => - e[1] # => "text" - e[2] # => - -==== Task: Get All CDATA Children - -Use method -{Element#cdatas}[../../../../REXML/Element.html#method-i-cdatas] -to retrieve all CDATA children: - - xml_string = <<-EOT - - - - - EOT - d = REXML::Document.new(xml_string) - d.root.cdatas # => ["foo", "bar"] - -==== Task: Get All Comment Children - -Use method -{Element#comments}[../../../../REXML/Element.html#method-i-comments] -to retrieve all comment children: - - xml_string = <<-EOT - - - - - EOT - d = REXML::Document.new(xml_string) - d.root.comments.map {|comment| comment.to_s } # => ["foo", "bar"] - -==== Task: Get All Processing Instruction Children - -Use method -{Element#instructions}[../../../../REXML/Element.html#method-i-instructions] -to retrieve all processing instruction children: - - xml_string = <<-EOT - - - - - EOT - d = REXML::Document.new(xml_string) - instructions = d.root.instructions.map {|instruction| instruction.to_s } - instructions # => ["", ""] - -==== Task: Get All Text Children - -Use method -{Element#texts}[../../../../REXML/Element.html#method-i-texts] -to retrieve all text children: - - xml_string = 'textmore' - d = REXML::Document.new(xml_string) - d.root.texts # => ["text", "more"] - -=== Namespaces - -==== Task: Add a Namespace - -Use method -{Element#add_namespace}[../../../../REXML/Element.html#method-i-add_namespace] -to add a namespace to the element: - - e = REXML::Element.new('foo') - e.add_namespace('bar') - e.namespaces # => {"xmlns"=>"bar"} - -==== Task: Delete the Default Namespace - -Use method -{Element#delete_namespace}[../../../../REXML/Element.html#method-i-delete_namespace] -to remove the default namespace from the element: - - d = REXML::Document.new "" - d.to_s # => "" - d.root.delete_namespace # => - d.to_s # => "" - -==== Task: Delete a Specific Namespace - -Use method -{Element#delete_namespace}[../../../../REXML/Element.html#method-i-delete_namespace] -to remove a specific namespace from the element: - - d = REXML::Document.new "" - d.to_s # => "" - d.root.delete_namespace # => - d.to_s # => "" - d.root.delete_namespace('foo') - d.to_s # => "" - -==== Task: Get a Namespace URI - -Use method -{Element#namespace}[../../../../REXML/Element.html#method-i-namespace] -to retrieve a specific namespace URI for the element: - - xml_string = <<-EOT - - - - - - - EOT - d = REXML::Document.new(xml_string) - b = d.elements['//b'] - b.namespace # => "1" - b.namespace('y') # => "2" - -==== Task: Retrieve Namespaces - -Use method -{Element#namespaces}[../../../../REXML/Element.html#method-i-namespaces] -to retrieve all namespaces for the element: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.attributes.namespaces # => {"xmlns"=>"foo", "x"=>"bar", "y"=>"twee"} - -==== Task: Retrieve Namespace Prefixes - -Use method -{Element#prefixes}[../../../../REXML/Element.html#method-i-prefixes] -to retrieve all prefixes (namespace names) for the element: - - xml_string = <<-EOT - - - - - - - EOT - d = REXML::Document.new(xml_string, {compress_whitespace: :all}) - d.elements['//a'].prefixes # => ["x", "y"] - d.elements['//b'].prefixes # => ["x", "y"] - d.elements['//c'].prefixes # => ["x", "y", "z"] - -=== Iteration - -==== Task: Iterate Over Elements - -Use method -{Element#each_element}[../../../../REXML/Element.html#method-i-each_element] -to iterate over element children: - - d = REXML::Document.new 'bbd' - d.root.each_element {|e| p e } - -Output: - - ... - ... - ... - - -==== Task: Iterate Over Elements Having a Specified Attribute - -Use method -{Element#each_element_with_attribute}[../../../../REXML/Element.html#method-i-each_element_with_attribute] -to iterate over element children that have a specified attribute: - - d = REXML::Document.new '' - a = d.root - a.each_element_with_attribute('id') {|e| p e } - -Output: - - - - - -==== Task: Iterate Over Elements Having a Specified Attribute and Value - -Use method -{Element#each_element_with_attribute}[../../../../REXML/Element.html#method-i-each_element_with_attribute] -to iterate over element children that have a specified attribute and value: - - d = REXML::Document.new '' - a = d.root - a.each_element_with_attribute('id', '1') {|e| p e } - -Output: - - - - -==== Task: Iterate Over Elements Having Specified Text - -Use method -{Element#each_element_with_text}[../../../../REXML/Element.html#method-i-each_element_with_text] -to iterate over element children that have specified text: - - -=== Context - -#whitespace -#ignore_whitespace_nodes -#raw - -=== Other Getters - -#document -#root -#root_node -#node_type -#xpath -#inspect diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/node.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/node.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/node.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/node.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,97 +0,0 @@ -== Module Node - -:include: ../tocs/node_toc.rdoc - -=== Siblings - -==== Task: Find Previous Sibling - -Use method -{Node.previous_sibling_node}[../../../../REXML/Node.html#method-i-previous_sibling] -to retrieve the previous sibling: - - d = REXML::Document.new('') - b = d.root[1] # => - b.previous_sibling_node # => - -==== Task: Find Next Sibling - -Use method -{Node.next_sibling_node}[../../../../REXML/Node.html#method-i-next_sibling] -to retrieve the next sibling: - - d = REXML::Document.new('') - b = d.root[1] # => - b.next_sibling_node # => - -=== Position - -==== Task: Find Own Index Among Siblings - -Use method -{Node.index_in_parent}[../../../../REXML/Node.html#method-i-index_in_parent] -to retrieve the 1-based index of this node among its siblings: - - d = REXML::Document.new('') - b = d.root[1] # => - b.index_in_parent # => 2 - -=== Recursive Traversal - -==== Task: Traverse Each Recursively - -Use method -{Node.each_recursive}[../../../../REXML/Node.html#method-i-each_recursive] -to traverse a tree of nodes recursively: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.each_recursive {|node| p node } - -Output: - - ... - ... - - ... - - -=== Recursive Search - -==== Task: Traverse Each Recursively - -Use method -{Node.find_first_recursive}[../../../../REXML/Node.html#method-i-find_first_recursive] -to search a tree of nodes recursively: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.find_first_recursive {|node| node.name == 'c' } # => - -=== Representation - -==== Task: Represent a String - -Use method {Node.to_s}[../../../../REXML/Node.html#method-i-to_s] -to represent the node as a string: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.to_s # => "" - -=== Parent? - -==== Task: Determine Whether the Node is a Parent - -Use method {Node.parent?}[../../../../REXML/Node.html#method-i-parent-3F] -to determine whether the node is a parent; -class Text derives from Node: - - d = REXML::Document.new('textmore') - t = d.root[1] # => "text" - t.parent? # => false - -Class Parent also derives from Node, but overrides this method: - - p = REXML::Parent.new - p.parent? # => true diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/parent.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/parent.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/parent.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/rdoc/parent.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,267 +0,0 @@ -== Class Parent - -Class Parent has methods from its superclasses and included modules; -see: - -- {Tasks for Child}[child_rdoc.html]. -- {Tasks for Node}[node_rdoc.html]. -- {Module Enumerable}[https://docs.ruby-lang.org/en/master/Enumerable.html]. - -:include: ../tocs/parent_toc.rdoc - -=== Queries - -==== Task: Get the Count of Children - -Use method {Parent#size}[../../../../REXML/Parent.html#method-i-size] -(or its alias +length+) to get the count of the parent's children: - - p = REXML::Parent.new - p.size # => 0 - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.size # => 3 - -==== Task: Get the Child at a Given Index - -Use method {Parent#[]}[../../../../REXML/Parent.html#method-i-5B-5D] -to get the child at a given index: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root[1] # => - d.root[-1] # => - d.root[50] # => nil - -==== Task: Get the Index of a Given Child - -Use method {Parent#index}[../../../../REXML/Parent.html#method-i-index] -to get the index (0-based offset) of a child: - - d = REXML::Document.new('') - root = d.root - e0 = REXML::Element.new('foo') - e1 = REXML::Element.new('bar') - root.add(e0) # => - root.add(e1) # => - root.add(e0) # => - root.add(e1) # => - root.index(e0) # => 0 - root.index(e1) # => 1 - -==== Task: Get the Children - -Use method {Parent#children}[../../../../REXML/Parent.html#method-i-children] -(or its alias +to_a+) to get the parent's children: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.children # => [, , ] - -==== Task: Determine Whether the Node is a Parent - -Use method {Parent#parent?}[../../../../REXML/Parent.html#method-i-parent-3F] -to determine whether the node is a parent; -class Text derives from Node: - - d = REXML::Document.new('textmore') - t = d.root[1] # => "text" - t.parent? # => false - -Class Parent also derives from Node, but overrides this method: - - p = REXML::Parent.new - p.parent? # => true - -=== Additions - -==== Task: Add a Child at the Beginning - -Use method {Parent#unshift}[../../../../REXML/Parent.html#method-i-unshift] -to add a child as at the beginning of the children: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.children # => [, , ] - d.root.unshift REXML::Element.new('d') - d.root.children # => [, , , ] - -==== Task: Add a Child at the End - -Use method {Parent#<<}[../../../../REXML/Parent.html#method-i-3C-3C] -(or an alias +push+ or +add+) to add a child as at the end of the children: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.children # => [, , ] - d.root << REXML::Element.new('d') - d.root.children # => [, , , ] - -==== Task: Replace a Child with Another Child - -Use method {Parent#replace}[../../../../REXML/Parent.html#method-i-replace] - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.children # => [, , ] - b = d.root[1] # => - d.replace_child(b, REXML::Element.new('d')) - d.root.children # => [, ] - -==== Task: Replace Multiple Children with Another Child - -Use method {Parent#[]=}[../../../../REXML/Parent.html#method-i-parent-5B-5D-3D] -to replace multiple consecutive children with another child: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.children # => [, , , ] - d.root[1, 2] = REXML::Element.new('x') - d.root.children # => [, , ] - d.root[1, 5] = REXML::Element.new('x') - d.root.children # => [, ] # BUG? - -==== Task: Insert Child Before a Given Child - -Use method {Parent#insert_before}[../../../../REXML/Parent.html#method-i-insert_before] -to insert a child immediately before a given child: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.children # => [, , ] - b = d.root[1] # => - x = REXML::Element.new('x') - d.root.insert_before(b, x) - d.root.children # => [, , , ] - -==== Task: Insert Child After a Given Child - -Use method {Parent#insert_after}[../../../../REXML/Parent.html#method-i-insert_after] -to insert a child immediately after a given child: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.children # => [, , ] - b = d.root[1] # => - x = REXML::Element.new('x') - d.root.insert_after(b, x) - d.root.children # => [, , , ] - -=== Deletions - -==== Task: Remove a Given Child - -Use method {Parent#delete}[../../../../REXML/Parent.html#method-i-delete] -to remove all occurrences of a given child: - - d = REXML::Document.new('') - a = REXML::Element.new('a') - b = REXML::Element.new('b') - d.root.add(a) - d.root.add(b) - d.root.add(a) - d.root.add(b) - d.root.children # => [, , , ] - d.root.delete(b) - d.root.children # => [, ] - -==== Task: Remove the Child at a Specified Offset - -Use method {Parent#delete_at}[../../../../REXML/Parent.html#method-i-delete_at] -to remove the child at a specified offset: - - d = REXML::Document.new('') - a = REXML::Element.new('a') - b = REXML::Element.new('b') - d.root.add(a) - d.root.add(b) - d.root.add(a) - d.root.add(b) - d.root.children # => [, , , ] - d.root.delete_at(2) - d.root.children # => [, , ] - -==== Task: Remove Children That Meet Specified Criteria - -Use method {Parent#delete_if}[../../../../REXML/Parent.html#method-i-delete_if] -to remove children that meet criteria specified in the given block: - - d = REXML::Document.new('') - d.root.add(REXML::Element.new('x')) - d.root.add(REXML::Element.new('xx')) - d.root.add(REXML::Element.new('xxx')) - d.root.add(REXML::Element.new('xxxx')) - d.root.children # => [, , , ] - d.root.delete_if {|child| child.name.size.odd? } - d.root.children # => [, ] - -=== Iterations - -==== Task: Iterate Over Children - -Use method {Parent#each_child}[../../../../REXML/Parent.html#method-i-each_child] -(or its alias +each+) to iterate over all children: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.children # => [, , ] - d.root.each_child {|child| p child } - -Output: - - - - - -==== Task: Iterate Over Child Indexes - -Use method {Parent#each_index}[../../../../REXML/Parent.html#method-i-each_index] -to iterate over all child indexes: - - xml_string = '' - d = REXML::Document.new(xml_string) - d.root.children # => [, , ] - d.root.each_index {|child| p child } - -Output: - - 0 - 1 - 2 - -=== Clones - -==== Task: Clone Deeply - -Use method {Parent#deep_clone}[../../../../REXML/Parent.html#method-i-deep_clone] -to clone deeply; that is, to clone every nested node that is a Parent object: - - xml_string = <<-EOT - - - - Everyday Italian - Giada De Laurentiis - 2005 - 30.00 - - - Harry Potter - J K. Rowling - 2005 - 29.99 - - - Learning XML - Erik T. Ray - 2003 - 39.95 - - - EOT - d = REXML::Document.new(xml_string) - root = d.root - shallow = root.clone - deep = root.deep_clone - shallow.to_s.size # => 12 - deep.to_s.size # => 590 diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/child_toc.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/child_toc.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/child_toc.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/child_toc.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,12 +0,0 @@ -Tasks on this page: - -- {Relationships}[#label-Relationships] - - {Task: Set the Parent}[#label-Task-3A+Set+the+Parent] - - {Task: Insert Previous Sibling}[#label-Task-3A+Insert+Previous+Sibling] - - {Task: Insert Next Sibling}[#label-Task-3A+Insert+Next+Sibling] -- {Removal or Replacement}[#label-Removal+or+Replacement] - - {Task: Remove Child from Parent}[#label-Task-3A+Remove+Child+from+Parent] - - {Task: Replace Child}[#label-Task-3A+Replace+Child] -- {Document}[#label-Document] - - {Task: Get the Document}[#label-Task-3A+Get+the+Document] - diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/document_toc.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/document_toc.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/document_toc.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/document_toc.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,30 +0,0 @@ -Tasks on this page: - -- {New Document}[#label-New+Document] - - {Task: Create an Empty Document}[#label-Task-3A+Create+an+Empty+Document] - - {Task: Parse a String into a New Document}[#label-Task-3A+Parse+a+String+into+a+New+Document] - - {Task: Parse an IO Stream into a New Document}[#label-Task-3A+Parse+an+IO+Stream+into+a+New+Document] - - {Task: Create a Document from an Existing Document}[#label-Task-3A+Create+a+Document+from+an+Existing+Document] - - {Task: Clone a Document}[#label-Task-3A+Clone+a+Document] -- {Document Type}[#label-Document+Type] - - {Task: Get the Document Type}[#label-Task-3A+Get+the+Document+Type] - - {Task: Set the Document Type}[#label-Task-3A+Set+the+Document+Type] -- {XML Declaration}[#label-XML+Declaration] - - {Task: Get the XML Declaration}[#label-Task-3A+Get+the+XML+Declaration] - - {Task: Set the XML Declaration}[#label-Task-3A+Set+the+XML+Declaration] -- {Children}[#label-Children] - - {Task: Add an Element Child}[#label-Task-3A+Add+an+Element+Child] - - {Task: Add a Non-Element Child}[#label-Task-3A+Add+a+Non-Element+Child] -- {Writing}[#label-Writing] - - {Task: Write to $stdout}[#label-Task-3A+Write+to+-24stdout] - - {Task: Write to IO Stream}[#label-Task-3A+Write+to+IO+Stream] - - {Task: Write with No Indentation}[#label-Task-3A+Write+with+No+Indentation] - - {Task: Write with Specified Indentation}[#label-Task-3A+Write+with+Specified+Indentation] -- {Querying}[#label-Querying] - - {Task: Get the Document}[#label-Task-3A+Get+the+Document] - - {Task: Get the Encoding}[#label-Task-3A+Get+the+Encoding] - - {Task: Get the Node Type}[#label-Task-3A+Get+the+Node+Type] - - {Task: Get the Root Element}[#label-Task-3A+Get+the+Root+Element] - - {Task: Determine Whether Stand-Alone}[#label-Task-3A+Determine+Whether+Stand-Alone] - - {Task: Get the Version}[#label-Task-3A+Get+the+Version] - diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/element_toc.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/element_toc.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/element_toc.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/element_toc.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,55 +0,0 @@ -Tasks on this page: - -- {New Element}[#label-New+Element] - - {Task: Create a Default Element}[#label-Task-3A+Create+a+Default+Element] - - {Task: Create a Named Element}[#label-Task-3A+Create+a+Named+Element] - - {Task: Create an Element with Name and Parent}[#label-Task-3A+Create+an+Element+with+Name+and+Parent] - - {Task: Create an Element with Name, Parent, and Context}[#label-Task-3A+Create+an+Element+with+Name-2C+Parent-2C+and+Context] - - {Task: Create a Shallow Clone}[#label-Task-3A+Create+a+Shallow+Clone] -- {Attributes}[#label-Attributes] - - {Task: Create and Add an Attribute}[#label-Task-3A+Create+and+Add+an+Attribute] - - {Task: Add an Existing Attribute}[#label-Task-3A+Add+an+Existing+Attribute] - - {Task: Add Multiple Attributes from a Hash}[#label-Task-3A+Add+Multiple+Attributes+from+a+Hash] - - {Task: Add Multiple Attributes from an Array}[#label-Task-3A+Add+Multiple+Attributes+from+an+Array] - - {Task: Retrieve the Value for an Attribute Name}[#label-Task-3A+Retrieve+the+Value+for+an+Attribute+Name] - - {Task: Retrieve the Attribute Value for a Name and Namespace}[#label-Task-3A+Retrieve+the+Attribute+Value+for+a+Name+and+Namespace] - - {Task: Delete an Attribute}[#label-Task-3A+Delete+an+Attribute] - - {Task: Determine Whether the Element Has Attributes}[#label-Task-3A+Determine+Whether+the+Element+Has+Attributes] -- {Children}[#label-Children] - - {Task: Create and Add an Element}[#label-Task-3A+Create+and+Add+an+Element] - - {Task: Add an Existing Element}[#label-Task-3A+Add+an+Existing+Element] - - {Task: Create and Add an Element with Attributes}[#label-Task-3A+Create+and+Add+an+Element+with+Attributes] - - {Task: Add an Existing Element with Added Attributes}[#label-Task-3A+Add+an+Existing+Element+with+Added+Attributes] - - {Task: Delete a Specified Element}[#label-Task-3A+Delete+a+Specified+Element] - - {Task: Delete an Element by Index}[#label-Task-3A+Delete+an+Element+by+Index] - - {Task: Delete an Element by XPath}[#label-Task-3A+Delete+an+Element+by+XPath] - - {Task: Determine Whether Element Children}[#label-Task-3A+Determine+Whether+Element+Children] - - {Task: Get Element Descendants by XPath}[#label-Task-3A+Get+Element+Descendants+by+XPath] - - {Task: Get Next Element Sibling}[#label-Task-3A+Get+Next+Element+Sibling] - - {Task: Get Previous Element Sibling}[#label-Task-3A+Get+Previous+Element+Sibling] - - {Task: Add a Text Node}[#label-Task-3A+Add+a+Text+Node] - - {Task: Replace the First Text Node}[#label-Task-3A+Replace+the+First+Text+Node] - - {Task: Remove the First Text Node}[#label-Task-3A+Remove+the+First+Text+Node] - - {Task: Retrieve the First Text Node}[#label-Task-3A+Retrieve+the+First+Text+Node] - - {Task: Retrieve a Specific Text Node}[#label-Task-3A+Retrieve+a+Specific+Text+Node] - - {Task: Determine Whether the Element has Text Nodes}[#label-Task-3A+Determine+Whether+the+Element+has+Text+Nodes] - - {Task: Get the Child at a Given Index}[#label-Task-3A+Get+the+Child+at+a+Given+Index] - - {Task: Get All CDATA Children}[#label-Task-3A+Get+All+CDATA+Children] - - {Task: Get All Comment Children}[#label-Task-3A+Get+All+Comment+Children] - - {Task: Get All Processing Instruction Children}[#label-Task-3A+Get+All+Processing+Instruction+Children] - - {Task: Get All Text Children}[#label-Task-3A+Get+All+Text+Children] -- {Namespaces}[#label-Namespaces] - - {Task: Add a Namespace}[#label-Task-3A+Add+a+Namespace] - - {Task: Delete the Default Namespace}[#label-Task-3A+Delete+the+Default+Namespace] - - {Task: Delete a Specific Namespace}[#label-Task-3A+Delete+a+Specific+Namespace] - - {Task: Get a Namespace URI}[#label-Task-3A+Get+a+Namespace+URI] - - {Task: Retrieve Namespaces}[#label-Task-3A+Retrieve+Namespaces] - - {Task: Retrieve Namespace Prefixes}[#label-Task-3A+Retrieve+Namespace+Prefixes] -- {Iteration}[#label-Iteration] - - {Task: Iterate Over Elements}[#label-Task-3A+Iterate+Over+Elements] - - {Task: Iterate Over Elements Having a Specified Attribute}[#label-Task-3A+Iterate+Over+Elements+Having+a+Specified+Attribute] - - {Task: Iterate Over Elements Having a Specified Attribute and Value}[#label-Task-3A+Iterate+Over+Elements+Having+a+Specified+Attribute+and+Value] - - {Task: Iterate Over Elements Having Specified Text}[#label-Task-3A+Iterate+Over+Elements+Having+Specified+Text] -- {Context}[#label-Context] -- {Other Getters}[#label-Other+Getters] - diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/master_toc.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/master_toc.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/master_toc.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/master_toc.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,135 +0,0 @@ -== Tasks - -=== {Child}[../../tasks/rdoc/child_rdoc.html] -- {Relationships}[../../tasks/rdoc/child_rdoc.html#label-Relationships] - - {Task: Set the Parent}[../../tasks/rdoc/child_rdoc.html#label-Task-3A+Set+the+Parent] - - {Task: Insert Previous Sibling}[../../tasks/rdoc/child_rdoc.html#label-Task-3A+Insert+Previous+Sibling] - - {Task: Insert Next Sibling}[../../tasks/rdoc/child_rdoc.html#label-Task-3A+Insert+Next+Sibling] -- {Removal or Replacement}[../../tasks/rdoc/child_rdoc.html#label-Removal+or+Replacement] - - {Task: Remove Child from Parent}[../../tasks/rdoc/child_rdoc.html#label-Task-3A+Remove+Child+from+Parent] - - {Task: Replace Child}[../../tasks/rdoc/child_rdoc.html#label-Task-3A+Replace+Child] -- {Document}[../../tasks/rdoc/child_rdoc.html#label-Document] - - {Task: Get the Document}[../../tasks/rdoc/child_rdoc.html#label-Task-3A+Get+the+Document] - -=== {Document}[../../tasks/rdoc/document_rdoc.html] -- {New Document}[../../tasks/rdoc/document_rdoc.html#label-New+Document] - - {Task: Create an Empty Document}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Create+an+Empty+Document] - - {Task: Parse a String into a New Document}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Parse+a+String+into+a+New+Document] - - {Task: Parse an IO Stream into a New Document}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Parse+an+IO+Stream+into+a+New+Document] - - {Task: Create a Document from an Existing Document}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Create+a+Document+from+an+Existing+Document] - - {Task: Clone a Document}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Clone+a+Document] -- {Document Type}[../../tasks/rdoc/document_rdoc.html#label-Document+Type] - - {Task: Get the Document Type}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+Document+Type] - - {Task: Set the Document Type}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Set+the+Document+Type] -- {XML Declaration}[../../tasks/rdoc/document_rdoc.html#label-XML+Declaration] - - {Task: Get the XML Declaration}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+XML+Declaration] - - {Task: Set the XML Declaration}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Set+the+XML+Declaration] -- {Children}[../../tasks/rdoc/document_rdoc.html#label-Children] - - {Task: Add an Element Child}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Add+an+Element+Child] - - {Task: Add a Non-Element Child}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Add+a+Non-Element+Child] -- {Writing}[../../tasks/rdoc/document_rdoc.html#label-Writing] - - {Task: Write to $stdout}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Write+to+-24stdout] - - {Task: Write to IO Stream}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Write+to+IO+Stream] - - {Task: Write with No Indentation}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Write+with+No+Indentation] - - {Task: Write with Specified Indentation}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Write+with+Specified+Indentation] -- {Querying}[../../tasks/rdoc/document_rdoc.html#label-Querying] - - {Task: Get the Document}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+Document] - - {Task: Get the Encoding}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+Encoding] - - {Task: Get the Node Type}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+Node+Type] - - {Task: Get the Root Element}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+Root+Element] - - {Task: Determine Whether Stand-Alone}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Determine+Whether+Stand-Alone] - - {Task: Get the Version}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+Version] - -=== {Element}[../../tasks/rdoc/element_rdoc.html] -- {New Element}[../../tasks/rdoc/element_rdoc.html#label-New+Element] - - {Task: Create a Default Element}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+a+Default+Element] - - {Task: Create a Named Element}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+a+Named+Element] - - {Task: Create an Element with Name and Parent}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+an+Element+with+Name+and+Parent] - - {Task: Create an Element with Name, Parent, and Context}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+an+Element+with+Name-2C+Parent-2C+and+Context] - - {Task: Create a Shallow Clone}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+a+Shallow+Clone] -- {Attributes}[../../tasks/rdoc/element_rdoc.html#label-Attributes] - - {Task: Create and Add an Attribute}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+and+Add+an+Attribute] - - {Task: Add an Existing Attribute}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+an+Existing+Attribute] - - {Task: Add Multiple Attributes from a Hash}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+Multiple+Attributes+from+a+Hash] - - {Task: Add Multiple Attributes from an Array}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+Multiple+Attributes+from+an+Array] - - {Task: Retrieve the Value for an Attribute Name}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Retrieve+the+Value+for+an+Attribute+Name] - - {Task: Retrieve the Attribute Value for a Name and Namespace}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Retrieve+the+Attribute+Value+for+a+Name+and+Namespace] - - {Task: Delete an Attribute}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Delete+an+Attribute] - - {Task: Determine Whether the Element Has Attributes}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Determine+Whether+the+Element+Has+Attributes] -- {Children}[../../tasks/rdoc/element_rdoc.html#label-Children] - - {Task: Create and Add an Element}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+and+Add+an+Element] - - {Task: Add an Existing Element}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+an+Existing+Element] - - {Task: Create and Add an Element with Attributes}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+and+Add+an+Element+with+Attributes] - - {Task: Add an Existing Element with Added Attributes}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+an+Existing+Element+with+Added+Attributes] - - {Task: Delete a Specified Element}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Delete+a+Specified+Element] - - {Task: Delete an Element by Index}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Delete+an+Element+by+Index] - - {Task: Delete an Element by XPath}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Delete+an+Element+by+XPath] - - {Task: Determine Whether Element Children}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Determine+Whether+Element+Children] - - {Task: Get Element Descendants by XPath}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+Element+Descendants+by+XPath] - - {Task: Get Next Element Sibling}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+Next+Element+Sibling] - - {Task: Get Previous Element Sibling}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+Previous+Element+Sibling] - - {Task: Add a Text Node}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+a+Text+Node] - - {Task: Replace the First Text Node}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Replace+the+First+Text+Node] - - {Task: Remove the First Text Node}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Remove+the+First+Text+Node] - - {Task: Retrieve the First Text Node}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Retrieve+the+First+Text+Node] - - {Task: Retrieve a Specific Text Node}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Retrieve+a+Specific+Text+Node] - - {Task: Determine Whether the Element has Text Nodes}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Determine+Whether+the+Element+has+Text+Nodes] - - {Task: Get the Child at a Given Index}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+the+Child+at+a+Given+Index] - - {Task: Get All CDATA Children}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+All+CDATA+Children] - - {Task: Get All Comment Children}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+All+Comment+Children] - - {Task: Get All Processing Instruction Children}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+All+Processing+Instruction+Children] - - {Task: Get All Text Children}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+All+Text+Children] -- {Namespaces}[../../tasks/rdoc/element_rdoc.html#label-Namespaces] - - {Task: Add a Namespace}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+a+Namespace] - - {Task: Delete the Default Namespace}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Delete+the+Default+Namespace] - - {Task: Delete a Specific Namespace}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Delete+a+Specific+Namespace] - - {Task: Get a Namespace URI}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+a+Namespace+URI] - - {Task: Retrieve Namespaces}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Retrieve+Namespaces] - - {Task: Retrieve Namespace Prefixes}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Retrieve+Namespace+Prefixes] -- {Iteration}[../../tasks/rdoc/element_rdoc.html#label-Iteration] - - {Task: Iterate Over Elements}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Iterate+Over+Elements] - - {Task: Iterate Over Elements Having a Specified Attribute}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Iterate+Over+Elements+Having+a+Specified+Attribute] - - {Task: Iterate Over Elements Having a Specified Attribute and Value}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Iterate+Over+Elements+Having+a+Specified+Attribute+and+Value] - - {Task: Iterate Over Elements Having Specified Text}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Iterate+Over+Elements+Having+Specified+Text] -- {Context}[../../tasks/rdoc/element_rdoc.html#label-Context] -- {Other Getters}[../../tasks/rdoc/element_rdoc.html#label-Other+Getters] - -=== {Node}[../../tasks/rdoc/node_rdoc.html] -- {Siblings}[../../tasks/rdoc/node_rdoc.html#label-Siblings] - - {Task: Find Previous Sibling}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Find+Previous+Sibling] - - {Task: Find Next Sibling}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Find+Next+Sibling] -- {Position}[../../tasks/rdoc/node_rdoc.html#label-Position] - - {Task: Find Own Index Among Siblings}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Find+Own+Index+Among+Siblings] -- {Recursive Traversal}[../../tasks/rdoc/node_rdoc.html#label-Recursive+Traversal] - - {Task: Traverse Each Recursively}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Traverse+Each+Recursively] -- {Recursive Search}[../../tasks/rdoc/node_rdoc.html#label-Recursive+Search] - - {Task: Traverse Each Recursively}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Traverse+Each+Recursively] -- {Representation}[../../tasks/rdoc/node_rdoc.html#label-Representation] - - {Task: Represent a String}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Represent+a+String] -- {Parent?}[../../tasks/rdoc/node_rdoc.html#label-Parent-3F] - - {Task: Determine Whether the Node is a Parent}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Determine+Whether+the+Node+is+a+Parent] - -=== {Parent}[../../tasks/rdoc/parent_rdoc.html] -- {Queries}[../../tasks/rdoc/parent_rdoc.html#label-Queries] - - {Task: Get the Count of Children}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Get+the+Count+of+Children] - - {Task: Get the Child at a Given Index}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Get+the+Child+at+a+Given+Index] - - {Task: Get the Index of a Given Child}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Get+the+Index+of+a+Given+Child] - - {Task: Get the Children}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Get+the+Children] - - {Task: Determine Whether the Node is a Parent}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Determine+Whether+the+Node+is+a+Parent] -- {Additions}[../../tasks/rdoc/parent_rdoc.html#label-Additions] - - {Task: Add a Child at the Beginning}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Add+a+Child+at+the+Beginning] - - {Task: Add a Child at the End}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Add+a+Child+at+the+End] - - {Task: Replace a Child with Another Child}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Replace+a+Child+with+Another+Child] - - {Task: Replace Multiple Children with Another Child}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Replace+Multiple+Children+with+Another+Child] - - {Task: Insert Child Before a Given Child}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Insert+Child+Before+a+Given+Child] - - {Task: Insert Child After a Given Child}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Insert+Child+After+a+Given+Child] -- {Deletions}[../../tasks/rdoc/parent_rdoc.html#label-Deletions] - - {Task: Remove a Given Child}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Remove+a+Given+Child] - - {Task: Remove the Child at a Specified Offset}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Remove+the+Child+at+a+Specified+Offset] - - {Task: Remove Children That Meet Specified Criteria}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Remove+Children+That+Meet+Specified+Criteria] -- {Iterations}[../../tasks/rdoc/parent_rdoc.html#label-Iterations] - - {Task: Iterate Over Children}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Iterate+Over+Children] - - {Task: Iterate Over Child Indexes}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Iterate+Over+Child+Indexes] -- {Clones}[../../tasks/rdoc/parent_rdoc.html#label-Clones] - - {Task: Clone Deeply}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Clone+Deeply] - diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/node_toc.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/node_toc.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/node_toc.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/node_toc.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,16 +0,0 @@ -Tasks on this page: - -- {Siblings}[#label-Siblings] - - {Task: Find Previous Sibling}[#label-Task-3A+Find+Previous+Sibling] - - {Task: Find Next Sibling}[#label-Task-3A+Find+Next+Sibling] -- {Position}[#label-Position] - - {Task: Find Own Index Among Siblings}[#label-Task-3A+Find+Own+Index+Among+Siblings] -- {Recursive Traversal}[#label-Recursive+Traversal] - - {Task: Traverse Each Recursively}[#label-Task-3A+Traverse+Each+Recursively] -- {Recursive Search}[#label-Recursive+Search] - - {Task: Traverse Each Recursively}[#label-Task-3A+Traverse+Each+Recursively] -- {Representation}[#label-Representation] - - {Task: Represent a String}[#label-Task-3A+Represent+a+String] -- {Parent?}[#label-Parent-3F] - - {Task: Determine Whether the Node is a Parent}[#label-Task-3A+Determine+Whether+the+Node+is+a+Parent] - diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/parent_toc.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/parent_toc.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/parent_toc.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tasks/tocs/parent_toc.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,25 +0,0 @@ -Tasks on this page: - -- {Queries}[#label-Queries] - - {Task: Get the Count of Children}[#label-Task-3A+Get+the+Count+of+Children] - - {Task: Get the Child at a Given Index}[#label-Task-3A+Get+the+Child+at+a+Given+Index] - - {Task: Get the Index of a Given Child}[#label-Task-3A+Get+the+Index+of+a+Given+Child] - - {Task: Get the Children}[#label-Task-3A+Get+the+Children] - - {Task: Determine Whether the Node is a Parent}[#label-Task-3A+Determine+Whether+the+Node+is+a+Parent] -- {Additions}[#label-Additions] - - {Task: Add a Child at the Beginning}[#label-Task-3A+Add+a+Child+at+the+Beginning] - - {Task: Add a Child at the End}[#label-Task-3A+Add+a+Child+at+the+End] - - {Task: Replace a Child with Another Child}[#label-Task-3A+Replace+a+Child+with+Another+Child] - - {Task: Replace Multiple Children with Another Child}[#label-Task-3A+Replace+Multiple+Children+with+Another+Child] - - {Task: Insert Child Before a Given Child}[#label-Task-3A+Insert+Child+Before+a+Given+Child] - - {Task: Insert Child After a Given Child}[#label-Task-3A+Insert+Child+After+a+Given+Child] -- {Deletions}[#label-Deletions] - - {Task: Remove a Given Child}[#label-Task-3A+Remove+a+Given+Child] - - {Task: Remove the Child at a Specified Offset}[#label-Task-3A+Remove+the+Child+at+a+Specified+Offset] - - {Task: Remove Children That Meet Specified Criteria}[#label-Task-3A+Remove+Children+That+Meet+Specified+Criteria] -- {Iterations}[#label-Iterations] - - {Task: Iterate Over Children}[#label-Task-3A+Iterate+Over+Children] - - {Task: Iterate Over Child Indexes}[#label-Task-3A+Iterate+Over+Child+Indexes] -- {Clones}[#label-Clones] - - {Task: Clone Deeply}[#label-Task-3A+Clone+Deeply] - diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tutorial.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tutorial.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/doc/rexml/tutorial.rdoc 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/doc/rexml/tutorial.rdoc 1970-01-01 00:00:00.000000000 +0000 @@ -1,1358 +0,0 @@ -= \REXML Tutorial - -== Why \REXML? - -- Ruby's \REXML library is part of the Ruby distribution, - so using it requires no gem installations. -- \REXML is fully maintained. -- \REXML is mature, having been in use for long years. - -== To Include, or Not to Include? - -REXML is a module. -To use it, you must require it: - - require 'rexml' # => true - -If you do not also include it, you must fully qualify references to REXML: - - REXML::Document # => REXML::Document - -If you also include the module, you may optionally omit REXML::: - - include REXML - Document # => REXML::Document - REXML::Document # => REXML::Document - -== Preliminaries - -All examples here assume that the following code has been executed: - - require 'rexml' - include REXML - -The source XML for many examples here is from file -{books.xml}[https://www.w3schools.com/xml/books.xml] at w3schools.com. -You may find it convenient to open that page in a new tab -(Ctrl-click in some browsers). - -Note that your browser may display the XML with modified whitespace -and without the XML declaration, which in this case is: - - - -For convenience, we capture the XML into a string variable: - - require 'open-uri' - source_string = URI.open('https://www.w3schools.com/xml/books.xml').read - -And into a file: - - File.write('source_file.xml', source_string) - -Throughout these examples, variable +doc+ will hold only the document -derived from these sources: - - doc = Document.new(source_string) - -== Parsing \XML \Source - -=== Parsing a Document - -Use method REXML::Document::new to parse XML source. - -The source may be a string: - - doc = Document.new(source_string) - -Or an \IO stream: - - doc = File.open('source_file.xml', 'r') do |io| - Document.new(io) - end - -Method URI.open returns a StringIO object, -so the source can be from a web page: - - require 'open-uri' - io = URI.open("https://www.w3schools.com/xml/books.xml") - io.class # => StringIO - doc = Document.new(io) - -For any of these sources, the returned object is an REXML::Document: - - doc # => ... - doc.class # => REXML::Document - -Note: 'UNDEFINED' is the "name" displayed for a document, -even though doc.name returns an empty string "". - -A parsed document may produce \REXML objects of many classes, -but the two that are likely to be of greatest interest are -REXML::Document and REXML::Element. -These two classes are covered in great detail in this tutorial. - -=== Context (Parsing Options) - -The context for parsing a document is a hash that influences -the way the XML is read and stored. - -The context entries are: - -- +:respect_whitespace+: controls treatment of whitespace. -- +:compress_whitespace+: determines whether whitespace is compressed. -- +:ignore_whitespace_nodes+: determines whether whitespace-only nodes are to be ignored. -- +:raw+: controls treatment of special characters and entities. - -See {Element Context}[../context_rdoc.html]. - -== Exploring the Document - -An REXML::Document object represents an XML document. - -The object inherits from its ancestor classes: - -- REXML::Child (includes module REXML::Node) - - REXML::Parent (includes module {Enumerable}[rdoc-ref:Enumerable]). - - REXML::Element (includes module REXML::Namespace). - - REXML::Document - -This section covers only those properties and methods that are unique to a document -(that is, not inherited or included). - -=== Document Properties - -A document has several properties (other than its children); - -- Document type. -- Node type. -- Name. -- Document. -- XPath - -[Document Type] - - A document may have a document type: - - my_xml = '' - my_doc = Document.new(my_xml) - doc_type = my_doc.doctype - doc_type.class # => REXML::DocType - doc_type.to_s # => "" - -[Node Type] - - A document also has a node type (always +:document+): - - doc.node_type # => :document - -[Name] - - A document has a name (always an empty string): - - doc.name # => "" - -[Document] - - \Method REXML::Document#document returns +self+: - - doc.document == doc # => true - - An object of a different class (\REXML::Element or \REXML::Child) - may have a document, which is the document to which the object belongs; - if so, that document will be an \REXML::Document object. - - doc.root.document.class # => REXML::Document - -[XPath] - - \method REXML::Element#xpath returns the string xpath to the element, - relative to its most distant ancestor: - - doc.root.class # => REXML::Element - doc.root.xpath # => "/bookstore" - doc.root.texts.first # => "\n\n" - doc.root.texts.first.xpath # => "/bookstore/text()" - - If there is no ancestor, returns the expanded name of the element: - - Element.new('foo').xpath # => "foo" - -=== Document Children - -A document may have children of these types: - -- XML declaration. -- Root element. -- Text. -- Processing instructions. -- Comments. -- CDATA. - -[XML Declaration] - - A document may an XML declaration, which is stored as an REXML::XMLDecl object: - - doc.xml_decl # => - doc.xml_decl.class # => REXML::XMLDecl - - Document.new('').xml_decl # => - - my_xml = '"' - my_doc = Document.new(my_xml) - xml_decl = my_doc.xml_decl - xml_decl.to_s # => "" - - The version, encoding, and stand-alone values may be retrieved separately: - - my_doc.version # => "1.0" - my_doc.encoding # => "UTF-8" - my_doc.stand_alone? # => "yes" - -[Root Element] - - A document may have a single element child, called the _root_ _element_, - which is stored as an REXML::Element object; - it may be retrieved with method +root+: - - doc.root # => ... - doc.root.class # => REXML::Element - - Document.new('').root # => nil - -[Text] - - A document may have text passages, each of which is stored - as an REXML::Text object: - - doc.texts.each {|t| p [t.class, t] } - - Output: - - [REXML::Text, "\n"] - -[Processing Instructions] - - A document may have processing instructions, which are stored - as REXML::Instruction objects: - - - - Output: - - [REXML::Instruction, ] - [REXML::Instruction, ] - -[Comments] - - A document may have comments, which are stored - as REXML::Comment objects: - - my_xml = <<-EOT - - - EOT - my_doc = Document.new(my_xml) - my_doc.comments.each {|c| p [c.class, c] } - - Output: - - [REXML::Comment, # ... , @string="foo">] - [REXML::Comment, # ... , @string="bar">] - -[CDATA] - - A document may have CDATA entries, which are stored - as REXML::CData objects: - - my_xml = <<-EOT - - - EOT - my_doc = Document.new(my_xml) - my_doc.cdatas.each {|cd| p [cd.class, cd] } - - Output: - - [REXML::CData, "foo"] - [REXML::CData, "bar"] - -The payload of a document is a tree of nodes, descending from the root element: - - doc.root.children.each do |child| - p [child, child.class] - end - -Output: - - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - -== Exploring an Element - -An REXML::Element object represents an XML element. - -The object inherits from its ancestor classes: - -- REXML::Child (includes module REXML::Node) - - REXML::Parent (includes module {Enumerable}[rdoc-ref:Enumerable]). - - REXML::Element (includes module REXML::Namespace). - -This section covers methods: - -- Defined in REXML::Element itself. -- Inherited from REXML::Parent and REXML::Child. -- Included from REXML::Node. - -=== Inside the Element - -[Brief String Representation] - - Use method REXML::Element#inspect to retrieve a brief string representation. - - doc.root.inspect # => " ... " - - The ellipsis (...) indicates that the element has children. - When there are no children, the ellipsis is omitted: - - Element.new('foo').inspect # => "" - - If the element has attributes, those are also included: - - doc.root.elements.first.inspect # => " ... " - -[Extended String Representation] - - Use inherited method REXML::Child.bytes to retrieve an extended - string representation. - - doc.root.bytes # => "\n\n\n Everyday Italian\n Giada De Laurentiis\n 2005\n 30.00\n\n\n\n Harry Potter\n J K. Rowling\n 2005\n 29.99\n\n\n\n XQuery Kick Start\n James McGovern\n Per Bothner\n Kurt Cagle\n James Linn\n Vaidyanathan Nagarajan\n 2003\n 49.99\n\n\n\n Learning XML\n Erik T. Ray\n 2003\n 39.95\n\n\n" - -[Node Type] - - Use method REXML::Element#node_type to retrieve the node type (always +:element+): - - doc.root.node_type # => :element - -[Raw Mode] - - Use method REXML::Element#raw to retrieve whether (+true+ or +nil+) - raw mode is set. - - doc.root.raw # => nil - -[Context] - - Use method REXML::Element#context to retrieve the context hash - (see {Element Context}[../context_rdoc.html]): - - doc.root.context # => {} - -=== Relationships - -An element may have: - -- Ancestors. -- Siblings. -- Children. - -==== Ancestors - -[Containing Document] - - Use method REXML::Element#document to retrieve the containing document, if any: - - ele = doc.root.elements.first # => ... - ele.document # => ... - ele = Element.new('foo') # => - ele.document # => nil - -[Root Element] - - Use method REXML::Element#root to retrieve the root element: - - ele = doc.root.elements.first # => ... - ele.root # => ... - ele = Element.new('foo') # => - ele.root # => - -[Root Node] - - Use method REXML::Element#root_node to retrieve the most distant ancestor, - which is the containing document, if any, otherwise the root element: - - ele = doc.root.elements.first # => ... - ele.root_node # => ... - ele = Element.new('foo') # => - ele.root_node # => - -[Parent] - - Use inherited method REXML::Child#parent to retrieve the parent - - ele = doc.root # => ... - ele.parent # => ... - ele = doc.root.elements.first # => ... - ele.parent # => ... - - Use included method REXML::Node#index_in_parent to retrieve the index - of the element among all of its parents children (not just the element children). - Note that while the index for doc.root.elements[n] is 1-based, - the returned index is 0-based. - - doc.root.children # => - # ["\n\n", - # ... , - # "\n\n", - # ... , - # "\n\n", - # ... , - # "\n\n", - # ... , - # "\n\n"] - ele = doc.root.elements[1] # => ... - ele.index_in_parent # => 2 - ele = doc.root.elements[2] # => ... - ele.index_in_parent# => 4 - -==== Siblings - -[Next Element] - - Use method REXML::Element#next_element to retrieve the first following - sibling that is itself an element (+nil+ if there is none): - - ele = doc.root.elements[1] - while ele do - p [ele.class, ele] - ele = ele.next_element - end - p ele - - Output: - - [REXML::Element, ... ] - [REXML::Element, ... ] - [REXML::Element, ... ] - [REXML::Element, ... ] - -[Previous Element] - - Use method REXML::Element#previous_element to retrieve the first preceding - sibling that is itself an element (+nil+ if there is none): - - ele = doc.root.elements[4] - while ele do - p [ele.class, ele] - ele = ele.previous_element - end - p ele - - Output: - - [REXML::Element, ... ] - [REXML::Element, ... ] - [REXML::Element, ... ] - [REXML::Element, ... ] - -[Next Node] - - Use included method REXML::Node.next_sibling_node - (or its alias next_sibling) to retrieve the first following node - regardless of its class: - - node = doc.root.children[0] - while node do - p [node.class, node] - node = node.next_sibling - end - p node - - Output: - - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - -[Previous Node] - - Use included method REXML::Node.previous_sibling_node - (or its alias previous_sibling) to retrieve the first preceding node - regardless of its class: - - node = doc.root.children[-1] - while node do - p [node.class, node] - node = node.previous_sibling - end - p node - - Output: - - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - -==== Children - -[Child Count] - - Use inherited method REXML::Parent.size to retrieve the count - of nodes (of all types) in the element: - - doc.root.size # => 9 - -[Child Nodes] - - Use inherited method REXML::Parent.children to retrieve an array - of the child nodes (of all types): - - doc.root.children # => - # ["\n\n", - # ... , - # "\n\n", - # ... , - # "\n\n", - # ... , - # "\n\n", - # ... , - # "\n\n"] - -[Child at Index] - - Use method REXML::Element#[] to retrieve the child at a given numerical index, - or +nil+ if there is no such child: - - doc.root[0] # => "\n\n" - doc.root[1] # => ... - doc.root[7] # => ... - doc.root[8] # => "\n\n" - - doc.root[-1] # => "\n\n" - doc.root[-2] # => ... - - doc.root[50] # => nil - -[Index of Child] - - Use method REXML::Parent#index to retrieve the zero-based child index - of the given object, or #size - 1 if there is no such child: - - ele = doc.root # => ... - ele.index(ele[0]) # => 0 - ele.index(ele[1]) # => 1 - ele.index(ele[7]) # => 7 - ele.index(ele[8]) # => 8 - - ele.index(ele[-1]) # => 8 - ele.index(ele[-2]) # => 7 - - ele.index(ele[50]) # => 8 - -[Element Children] - - Use method REXML::Element#has_elements? to retrieve whether the element - has element children: - - doc.root.has_elements? # => true - REXML::Element.new('foo').has_elements? # => false - - Use method REXML::Element#elements to retrieve the REXML::Elements object - containing the element children: - - eles = doc.root.elements - eles # => # ... > - eles.size # => 4 - eles.each {|e| p [e.class], e } - - Output: - - [ ... , - ... , - ... , - ... - ] - -Note that while in this example, all the element children of the root element are -elements of the same name, 'book', that is not true of all documents; -a root element (or any other element) may have any mixture of child elements. - -[CDATA Children] - - Use method REXML::Element#cdatas to retrieve a frozen array of CDATA children: - - my_xml = <<-EOT - - - - - EOT - my_doc = REXML::Document.new(my_xml) - cdatas my_doc.root.cdatas - cdatas.frozen? # => true - cdatas.map {|cd| cd.class } # => [REXML::CData, REXML::CData] - -[Comment Children] - - Use method REXML::Element#comments to retrieve a frozen array of comment children: - - my_xml = <<-EOT - - - - - EOT - my_doc = REXML::Document.new(my_xml) - comments = my_doc.root.comments - comments.frozen? # => true - comments.map {|c| c.class } # => [REXML::Comment, REXML::Comment] - comments.map {|c| c.to_s } # => ["foo", "bar"] - -[Processing Instruction Children] - - Use method REXML::Element#instructions to retrieve a frozen array - of processing instruction children: - - my_xml = <<-EOT - - - - - EOT - my_doc = REXML::Document.new(my_xml) - instrs = my_doc.root.instructions - instrs.frozen? # => true - instrs.map {|i| i.class } # => [REXML::Instruction, REXML::Instruction] - instrs.map {|i| i.to_s } # => ["", ""] - -[Text Children] - - Use method REXML::Element#has_text? to retrieve whether the element - has text children: - - doc.root.has_text? # => true - REXML::Element.new('foo').has_text? # => false - - Use method REXML::Element#texts to retrieve a frozen array of text children: - - my_xml = 'textmore' - my_doc = REXML::Document.new(my_xml) - texts = my_doc.root.texts - texts.frozen? # => true - texts.map {|t| t.class } # => [REXML::Text, REXML::Text] - texts.map {|t| t.to_s } # => ["text", "more"] - -[Parenthood] - - Use inherited method REXML::Parent.parent? to retrieve whether the element is a parent; - always returns +true+; only REXML::Child#parent returns +false+. - - doc.root.parent? # => true - -=== Element Attributes - -Use method REXML::Element#has_attributes? to return whether the element -has attributes: - - ele = doc.root # => ... - ele.has_attributes? # => false - ele = ele.elements.first # => ... - ele.has_attributes? # => true - -Use method REXML::Element#attributes to return the hash -containing the attributes for the element. -Each hash key is a string attribute name; -each hash value is an REXML::Attribute object. - - ele = doc.root # => ... - attrs = ele.attributes # => {} - - ele = ele.elements.first # => ... - attrs = ele.attributes # => {"category"=>category='cooking'} - attrs.size # => 1 - attr_name = attrs.keys.first # => "category" - attr_name.class # => String - attr_value = attrs.values.first # => category='cooking' - attr_value.class # => REXML::Attribute - -Use method REXML::Element#[] to retrieve the string value for a given attribute, -which may be given as either a string or a symbol: - - ele = doc.root.elements.first # => ... - attr_value = ele['category'] # => "cooking" - attr_value.class # => String - ele['nosuch'] # => nil - -Use method REXML::Element#attribute to retrieve the value of a named attribute: - - my_xml = "" - my_doc = REXML::Document.new(my_xml) - my_doc.root.attribute("x") # => x='x' - my_doc.root.attribute("x", "a") # => a:x='a:x' - -== Whitespace - -Use method REXML::Element#ignore_whitespace_nodes to determine whether -whitespace nodes were ignored when the XML was parsed; -returns +true+ if so, +nil+ otherwise. - -Use method REXML::Element#whitespace to determine whether whitespace -is respected for the element; returns +true+ if so, +false+ otherwise. - -== Namespaces - -Use method REXML::Element#namespace to retrieve the string namespace URI -for the element, which may derive from one of its ancestors: - - xml_string = <<-EOT - - - - - - - EOT - d = Document.new(xml_string) - b = d.elements['//b'] - b.namespace # => "1" - b.namespace('y') # => "2" - b.namespace('nosuch') # => nil - -Use method REXML::Element#namespaces to retrieve a hash of all defined namespaces -in the element and its ancestors: - - xml_string = <<-EOT - - - - - - - EOT - d = Document.new(xml_string) - d.elements['//a'].namespaces # => {"x"=>"1", "y"=>"2"} - d.elements['//b'].namespaces # => {"x"=>"1", "y"=>"2"} - d.elements['//c'].namespaces # => {"x"=>"1", "y"=>"2", "z"=>"3"} - -Use method REXML::Element#prefixes to retrieve an array of the string prefixes (names) -of all defined namespaces in the element and its ancestors: - - xml_string = <<-EOT - - - - - - - EOT - d = Document.new(xml_string, {compress_whitespace: :all}) - d.elements['//a'].prefixes # => ["x", "y"] - d.elements['//b'].prefixes # => ["x", "y"] - d.elements['//c'].prefixes # => ["x", "y", "z"] - -== Traversing - -You can use certain methods to traverse children of the element. -Each child that meets given criteria is yielded to the given block. - -[Traverse All Children] - - Use inherited method REXML::Parent#each (or its alias #each_child) to traverse - all children of the element: - - doc.root.each {|child| p [child.class, child] } - - Output: - - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - [REXML::Element, ... ] - [REXML::Text, "\n\n"] - -[Traverse Element Children] - - Use method REXML::Element#each_element to traverse only the element children - of the element: - - doc.root.each_element {|e| p [e.class, e] } - - Output: - - [REXML::Element, ... ] - [REXML::Element, ... ] - [REXML::Element, ... ] - [REXML::Element, ... ] - -[Traverse Element Children with Attribute] - - Use method REXML::Element#each_element_with_attribute with the single argument - +attr_name+ to traverse each element child that has the given attribute: - - my_doc = Document.new '' - my_doc.root.each_element_with_attribute('id') {|e| p [e.class, e] } - - Output: - - [REXML::Element, ] - [REXML::Element, ] - [REXML::Element, ] - - Use the same method with a second argument +value+ to traverse - each element child element that has the given attribute and value: - - my_doc.root.each_element_with_attribute('id', '1') {|e| p [e.class, e] } - - Output: - - [REXML::Element, ] - [REXML::Element, ] - - Use the same method with a third argument +max+ to traverse - no more than the given number of element children: - - my_doc.root.each_element_with_attribute('id', '1', 1) {|e| p [e.class, e] } - - Output: - - [REXML::Element, ] - - Use the same method with a fourth argument +xpath+ to traverse - only those element children that match the given xpath: - - my_doc.root.each_element_with_attribute('id', '1', 2, '//d') {|e| p [e.class, e] } - - Output: - - [REXML::Element, ] - -[Traverse Element Children with Text] - - Use method REXML::Element#each_element_with_text with no arguments - to traverse those element children that have text: - - my_doc = Document.new 'bbd' - my_doc.root.each_element_with_text {|e| p [e.class, e] } - - Output: - - [REXML::Element, ... ] - [REXML::Element, ... ] - [REXML::Element, ... ] - - Use the same method with the single argument +text+ to traverse - those element children that have exactly that text: - - my_doc.root.each_element_with_text('b') {|e| p [e.class, e] } - - Output: - - [REXML::Element, ... ] - [REXML::Element, ... ] - - Use the same method with additional second argument +max+ to traverse - no more than the given number of element children: - - my_doc.root.each_element_with_text('b', 1) {|e| p [e.class, e] } - - Output: - - [REXML::Element, ... ] - - Use the same method with additional third argument +xpath+ to traverse - only those element children that also match the given xpath: - - my_doc.root.each_element_with_text('b', 2, '//c') {|e| p [e.class, e] } - - Output: - - [REXML::Element, ... ] - -[Traverse Element Children's Indexes] - - Use inherited method REXML::Parent#each_index to traverse all children's indexes - (not just those of element children): - - doc.root.each_index {|i| print i } - - Output: - - 012345678 - -[Traverse Children Recursively] - - Use included method REXML::Node#each_recursive to traverse all children recursively: - - doc.root.each_recursive {|child| p [child.class, child] } - - Output: - - [REXML::Element, ... ] - [REXML::Element, ... </>] - [REXML::Element, <author> ... </>] - [REXML::Element, <year> ... </>] - [REXML::Element, <price> ... </>] - [REXML::Element, <book category='children'> ... </>] - [REXML::Element, <title lang='en'> ... </>] - [REXML::Element, <author> ... </>] - [REXML::Element, <year> ... </>] - [REXML::Element, <price> ... </>] - [REXML::Element, <book category='web'> ... </>] - [REXML::Element, <title lang='en'> ... </>] - [REXML::Element, <author> ... </>] - [REXML::Element, <author> ... </>] - [REXML::Element, <author> ... </>] - [REXML::Element, <author> ... </>] - [REXML::Element, <author> ... </>] - [REXML::Element, <year> ... </>] - [REXML::Element, <price> ... </>] - [REXML::Element, <book category='web' cover='paperback'> ... </>] - [REXML::Element, <title lang='en'> ... </>] - [REXML::Element, <author> ... </>] - [REXML::Element, <year> ... </>] - [REXML::Element, <price> ... </>] - -== Searching - -You can use certain methods to search among the descendants of an element. - -Use method REXML::Element#get_elements to retrieve all element children of the element -that match the given +xpath+: - - xml_string = <<-EOT - <root> - <a level='1'> - <a level='2'/> - </a> - </root> - EOT - d = Document.new(xml_string) - d.root.get_elements('//a') # => [<a level='1'> ... </>, <a level='2'/>] - -Use method REXML::Element#get_text with no argument to retrieve the first text node -in the first child: - - my_doc = Document.new "<p>some text <b>this is bold!</b> more text</p>" - text_node = my_doc.root.get_text - text_node.class # => REXML::Text - text_node.to_s # => "some text " - -Use the same method with argument +xpath+ to retrieve the first text node -in the first child that matches the xpath: - - my_doc.root.get_text(1) # => "this is bold!" - -Use method REXML::Element#text with no argument to retrieve the text -from the first text node in the first child: - - my_doc = Document.new "<p>some text <b>this is bold!</b> more text</p>" - text_node = my_doc.root.text - text_node.class # => String - text_node # => "some text " - -Use the same method with argument +xpath+ to retrieve the text from the first text node -in the first child that matches the xpath: - - my_doc.root.text(1) # => "this is bold!" - -Use included method REXML::Node#find_first_recursive -to retrieve the first descendant element -for which the given block returns a truthy value, or +nil+ if none: - - doc.root.find_first_recursive do |ele| - ele.name == 'price' - end # => <price> ... </> - doc.root.find_first_recursive do |ele| - ele.name == 'nosuch' - end # => nil - -== Editing - -=== Editing a Document - -[Creating a Document] - - Create a new document with method REXML::Document::new: - - doc = Document.new(source_string) - empty_doc = REXML::Document.new - -[Adding to the Document] - - Add an XML declaration with method REXML::Document#add - and an argument of type REXML::XMLDecl: - - my_doc = Document.new - my_doc.xml_decl.to_s # => "" - my_doc.add(XMLDecl.new('2.0')) - my_doc.xml_decl.to_s # => "<?xml version='2.0'?>" - - Add a document type with method REXML::Document#add - and an argument of type REXML::DocType: - - my_doc = Document.new - my_doc.doctype.to_s # => "" - my_doc.add(DocType.new('foo')) - my_doc.doctype.to_s # => "<!DOCTYPE foo>" - - Add a node of any other REXML type with method REXML::Document#add and an argument - that is not of type REXML::XMLDecl or REXML::DocType: - - my_doc = Document.new - my_doc.add(Element.new('foo')) - my_doc.to_s # => "<foo/>" - - Add an existing element as the root element with method REXML::Document#add_element: - - ele = Element.new('foo') - my_doc = Document.new - my_doc.add_element(ele) - my_doc.root # => <foo/> - - Create and add an element as the root element with method REXML::Document#add_element: - - my_doc = Document.new - my_doc.add_element('foo') - my_doc.root # => <foo/> - -=== Editing an Element - -==== Creating an Element - -Create a new element with method REXML::Element::new: - - ele = Element.new('foo') # => <foo/> - -==== Setting Element Properties - -Set the context for an element with method REXML::Element#context= -(see {Element Context}[../context_rdoc.html]): - - ele.context # => nil - ele.context = {ignore_whitespace_nodes: :all} - ele.context # => {:ignore_whitespace_nodes=>:all} - -Set the parent for an element with inherited method REXML::Child#parent= - - ele.parent # => nil - ele.parent = Element.new('bar') - ele.parent # => <bar/> - -Set the text for an element with method REXML::Element#text=: - - ele.text # => nil - ele.text = 'bar' - ele.text # => "bar" - -==== Adding to an Element - -Add a node as the last child with inherited method REXML::Parent#add (or its alias #push): - - ele = Element.new('foo') # => <foo/> - ele.push(Text.new('bar')) - ele.push(Element.new('baz')) - ele.children # => ["bar", <baz/>] - -Add a node as the first child with inherited method REXML::Parent#unshift: - - ele = Element.new('foo') # => <foo/> - ele.unshift(Element.new('bar')) - ele.unshift(Text.new('baz')) - ele.children # => ["bar", <baz/>] - -Add an element as the last child with method REXML::Element#add_element: - - ele = Element.new('foo') # => <foo/> - ele.add_element('bar') - ele.add_element(Element.new('baz')) - ele.children # => [<bar/>, <baz/>] - -Add a text node as the last child with method REXML::Element#add_text: - - ele = Element.new('foo') # => <foo/> - ele.add_text('bar') - ele.add_text(Text.new('baz')) - ele.children # => ["bar", "baz"] - -Insert a node before a given node with method REXML::Parent#insert_before: - - ele = Element.new('foo') # => <foo/> - ele.add_text('bar') - ele.add_text(Text.new('baz')) - ele.children # => ["bar", "baz"] - target = ele[1] # => "baz" - ele.insert_before(target, Text.new('bat')) - ele.children # => ["bar", "bat", "baz"] - -Insert a node after a given node with method REXML::Parent#insert_after: - - ele = Element.new('foo') # => <foo/> - ele.add_text('bar') - ele.add_text(Text.new('baz')) - ele.children # => ["bar", "baz"] - target = ele[0] # => "bar" - ele.insert_after(target, Text.new('bat')) - ele.children # => ["bar", "bat", "baz"] - -Add an attribute with method REXML::Element#add_attribute: - - ele = Element.new('foo') # => <foo/> - ele.add_attribute('bar', 'baz') - ele.add_attribute(Attribute.new('bat', 'bam')) - ele.attributes # => {"bar"=>bar='baz', "bat"=>bat='bam'} - -Add multiple attributes with method REXML::Element#add_attributes: - - ele = Element.new('foo') # => <foo/> - ele.add_attributes({'bar' => 'baz', 'bat' => 'bam'}) - ele.add_attributes([['ban', 'bap'], ['bah', 'bad']]) - ele.attributes # => {"bar"=>bar='baz', "bat"=>bat='bam', "ban"=>ban='bap', "bah"=>bah='bad'} - -Add a namespace with method REXML::Element#add_namespace: - - ele = Element.new('foo') # => <foo/> - ele.add_namespace('bar') - ele.add_namespace('baz', 'bat') - ele.namespaces # => {"xmlns"=>"bar", "baz"=>"bat"} - -==== Deleting from an Element - -Delete a specific child object with inherited method REXML::Parent#delete: - - ele = Element.new('foo') # => <foo/> - ele.add_element('bar') - ele.add_text('baz') - ele.children # => [<bar/>, "baz"] - target = ele[1] # => "baz" - ele.delete(target) # => "baz" - ele.children # => [<bar/>] - target = ele[0] # => <baz/> - ele.delete(target) # => <baz/> - ele.children # => [] - -Delete a child at a specific index with inherited method REXML::Parent#delete_at: - - ele = Element.new('foo') # => <foo/> - ele.add_element('bar') - ele.add_text('baz') - ele.children # => [<bar/>, "baz"] - ele.delete_at(1) - ele.children # => [<bar/>] - ele.delete_at(0) - ele.children # => [] - -Delete all children meeting a specified criterion with inherited method -REXML::Parent#delete_if: - - ele = Element.new('foo') # => <foo/> - ele.add_element('bar') - ele.add_text('baz') - ele.add_element('bat') - ele.add_text('bam') - ele.children # => [<bar/>, "baz", <bat/>, "bam"] - ele.delete_if {|child| child.instance_of?(Text) } - ele.children # => [<bar/>, <bat/>] - -Delete an element at a specific 1-based index with method REXML::Element#delete_element: - - ele = Element.new('foo') # => <foo/> - ele.add_element('bar') - ele.add_text('baz') - ele.add_element('bat') - ele.add_text('bam') - ele.children # => [<bar/>, "baz", <bat/>, "bam"] - ele.delete_element(2) # => <bat/> - ele.children # => [<bar/>, "baz", "bam"] - ele.delete_element(1) # => <bar/> - ele.children # => ["baz", "bam"] - -Delete a specific element with the same method: - - ele = Element.new('foo') # => <foo/> - ele.add_element('bar') - ele.add_text('baz') - ele.add_element('bat') - ele.add_text('bam') - ele.children # => [<bar/>, "baz", <bat/>, "bam"] - target = ele.elements[2] # => <bat/> - ele.delete_element(target) # => <bat/> - ele.children # => [<bar/>, "baz", "bam"] - -Delete an element matching an xpath using the same method: - - ele = Element.new('foo') # => <foo/> - ele.add_element('bar') - ele.add_text('baz') - ele.add_element('bat') - ele.add_text('bam') - ele.children # => [<bar/>, "baz", <bat/>, "bam"] - ele.delete_element('./bat') # => <bat/> - ele.children # => [<bar/>, "baz", "bam"] - ele.delete_element('./bar') # => <bar/> - ele.children # => ["baz", "bam"] - -Delete an attribute by name with method REXML::Element#delete_attribute: - - ele = Element.new('foo') # => <foo/> - ele.add_attributes({'bar' => 'baz', 'bam' => 'bat'}) - ele.attributes # => {"bar"=>bar='baz', "bam"=>bam='bat'} - ele.delete_attribute('bam') - ele.attributes # => {"bar"=>bar='baz'} - -Delete a namespace with method REXML::Element#delete_namespace: - - ele = Element.new('foo') # => <foo/> - ele.add_namespace('bar') - ele.add_namespace('baz', 'bat') - ele.namespaces # => {"xmlns"=>"bar", "baz"=>"bat"} - ele.delete_namespace('xmlns') - ele.namespaces # => {} # => {"baz"=>"bat"} - ele.delete_namespace('baz') - ele.namespaces # => {} # => {} - -Remove an element from its parent with inherited method REXML::Child#remove: - - ele = Element.new('foo') # => <foo/> - parent = Element.new('bar') # => <bar/> - parent.add_element(ele) # => <foo/> - parent.children.size # => 1 - ele.remove # => <foo/> - parent.children.size # => 0 - -==== Replacing Nodes - -Replace the node at a given 0-based index with inherited method REXML::Parent#[]=: - - ele = Element.new('foo') # => <foo/> - ele.add_element('bar') - ele.add_text('baz') - ele.add_element('bat') - ele.add_text('bam') - ele.children # => [<bar/>, "baz", <bat/>, "bam"] - ele[2] = Text.new('bad') # => "bad" - ele.children # => [<bar/>, "baz", "bad", "bam"] - -Replace a given node with another node with inherited method REXML::Parent#replace_child: - - ele = Element.new('foo') # => <foo/> - ele.add_element('bar') - ele.add_text('baz') - ele.add_element('bat') - ele.add_text('bam') - ele.children # => [<bar/>, "baz", <bat/>, "bam"] - target = ele[2] # => <bat/> - ele.replace_child(target, Text.new('bah')) - ele.children # => [<bar/>, "baz", "bah", "bam"] - -Replace +self+ with a given node with inherited method REXML::Child#replace_with: - - ele = Element.new('foo') # => <foo/> - ele.add_element('bar') - ele.add_text('baz') - ele.add_element('bat') - ele.add_text('bam') - ele.children # => [<bar/>, "baz", <bat/>, "bam"] - target = ele[2] # => <bat/> - target.replace_with(Text.new('bah')) - ele.children # => [<bar/>, "baz", "bah", "bam"] - -=== Cloning - -Create a shallow clone of an element with method REXML::Element#clone. -The clone contains the name and attributes, but not the parent or children: - - ele = Element.new('foo') - ele.add_attributes({'bar' => 0, 'baz' => 1}) - ele.clone # => <foo bar='0' baz='1'/> - -Create a shallow clone of a document with method REXML::Document#clone. -The XML declaration is copied; the document type and root element are not cloned: - - my_xml = '<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE foo><root/>' - my_doc = Document.new(my_xml) - clone_doc = my_doc.clone - - my_doc.xml_decl # => <?xml ... ?> - clone_doc.xml_decl # => <?xml ... ?> - - my_doc.doctype.to_s # => "<?xml version='1.0' encoding='UTF-8'?>" - clone_doc.doctype.to_s # => "" - - my_doc.root # => <root/> - clone_doc.root # => nil - -Create a deep clone of an element with inherited method REXML::Parent#deep_clone. -All nodes and attributes are copied: - - doc.to_s.size # => 825 - clone = doc.deep_clone - clone.to_s.size # => 825 - -== Writing the Document - -Write a document to an \IO stream (defaults to <tt>$stdout</tt>) -with method REXML::Document#write: - - doc.write - -Output: - - <?xml version='1.0' encoding='UTF-8'?> - <bookstore> - - <book category='cooking'> - <title lang='en'>Everyday Italian - Giada De Laurentiis - 2005 - 30.00 - - - - Harry Potter - J K. Rowling - 2005 - 29.99 - - - - XQuery Kick Start - James McGovern - Per Bothner - Kurt Cagle - James Linn - Vaidyanathan Nagarajan - 2003 - 49.99 - - - - Learning XML - Erik T. Ray - 2003 - 39.95 - - - diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/attlistdecl.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/attlistdecl.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/attlistdecl.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/attlistdecl.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,63 +0,0 @@ -# frozen_string_literal: false -#vim:ts=2 sw=2 noexpandtab: -require_relative 'child' -require_relative 'source' - -module REXML - # This class needs: - # * Documentation - # * Work! Not all types of attlists are intelligently parsed, so we just - # spew back out what we get in. This works, but it would be better if - # we formatted the output ourselves. - # - # AttlistDecls provide *just* enough support to allow namespace - # declarations. If you need some sort of generalized support, or have an - # interesting idea about how to map the hideous, terrible design of DTD - # AttlistDecls onto an intuitive Ruby interface, let me know. I'm desperate - # for anything to make DTDs more palateable. - class AttlistDecl < Child - include Enumerable - - # What is this? Got me. - attr_reader :element_name - - # Create an AttlistDecl, pulling the information from a Source. Notice - # that this isn't very convenient; to create an AttlistDecl, you basically - # have to format it yourself, and then have the initializer parse it. - # Sorry, but for the foreseeable future, DTD support in REXML is pretty - # weak on convenience. Have I mentioned how much I hate DTDs? - def initialize(source) - super() - if (source.kind_of? Array) - @element_name, @pairs, @contents = *source - end - end - - # Access the attlist attribute/value pairs. - # value = attlist_decl[ attribute_name ] - def [](key) - @pairs[key] - end - - # Whether an attlist declaration includes the given attribute definition - # if attlist_decl.include? "xmlns:foobar" - def include?(key) - @pairs.keys.include? key - end - - # Iterate over the key/value pairs: - # attlist_decl.each { |attribute_name, attribute_value| ... } - def each(&block) - @pairs.each(&block) - end - - # Write out exactly what we got in. - def write out, indent=-1 - out << @contents - end - - def node_type - :attlistdecl - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/attribute.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/attribute.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/attribute.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/attribute.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,211 +0,0 @@ -# frozen_string_literal: true -require_relative "namespace" -require_relative 'text' - -module REXML - # Defines an Element Attribute; IE, a attribute=value pair, as in: - # . Attributes can be in their own - # namespaces. General users of REXML will not interact with the - # Attribute class much. - class Attribute - include Node - include Namespace - - # The element to which this attribute belongs - attr_reader :element - PATTERN = /\s*(#{NAME_STR})\s*=\s*(["'])(.*?)\2/um - - NEEDS_A_SECOND_CHECK = /(<|&((#{Entity::NAME});|(#0*((?:\d+)|(?:x[a-fA-F0-9]+)));)?)/um - - # Constructor. - # FIXME: The parser doesn't catch illegal characters in attributes - # - # first:: - # Either: an Attribute, which this new attribute will become a - # clone of; or a String, which is the name of this attribute - # second:: - # If +first+ is an Attribute, then this may be an Element, or nil. - # If nil, then the Element parent of this attribute is the parent - # of the +first+ Attribute. If the first argument is a String, - # then this must also be a String, and is the content of the attribute. - # If this is the content, it must be fully normalized (contain no - # illegal characters). - # parent:: - # Ignored unless +first+ is a String; otherwise, may be the Element - # parent of this attribute, or nil. - # - # - # Attribute.new( attribute_to_clone ) - # Attribute.new( attribute_to_clone, parent_element ) - # Attribute.new( "attr", "attr_value" ) - # Attribute.new( "attr", "attr_value", parent_element ) - def initialize( first, second=nil, parent=nil ) - @normalized = @unnormalized = @element = nil - if first.kind_of? Attribute - self.name = first.expanded_name - @unnormalized = first.value - if second.kind_of? Element - @element = second - else - @element = first.element - end - elsif first.kind_of? String - @element = parent - self.name = first - @normalized = second.to_s - else - raise "illegal argument #{first.class.name} to Attribute constructor" - end - end - - # Returns the namespace of the attribute. - # - # e = Element.new( "elns:myelement" ) - # e.add_attribute( "nsa:a", "aval" ) - # e.add_attribute( "b", "bval" ) - # e.attributes.get_attribute( "a" ).prefix # -> "nsa" - # e.attributes.get_attribute( "b" ).prefix # -> "" - # a = Attribute.new( "x", "y" ) - # a.prefix # -> "" - def prefix - super - end - - # Returns the namespace URL, if defined, or nil otherwise - # - # e = Element.new("el") - # e.add_namespace("ns", "http://url") - # e.add_attribute("ns:a", "b") - # e.add_attribute("nsx:a", "c") - # e.attribute("ns:a").namespace # => "http://url" - # e.attribute("nsx:a").namespace # => nil - # - # This method always returns "" for no namespace attribute. Because - # the default namespace doesn't apply to attribute names. - # - # From https://www.w3.org/TR/xml-names/#uniqAttrs - # - # > the default namespace does not apply to attribute names - # - # e = REXML::Element.new("el") - # e.add_namespace("", "http://example.com/") - # e.namespace # => "http://example.com/" - # e.add_attribute("a", "b") - # e.attribute("a").namespace # => "" - def namespace arg=nil - arg = prefix if arg.nil? - if arg == "" - "" - else - @element.namespace(arg) - end - end - - # Returns true if other is an Attribute and has the same name and value, - # false otherwise. - def ==( other ) - other.kind_of?(Attribute) and other.name==name and other.value==value - end - - # Creates (and returns) a hash from both the name and value - def hash - name.hash + value.hash - end - - # Returns this attribute out as XML source, expanding the name - # - # a = Attribute.new( "x", "y" ) - # a.to_string # -> "x='y'" - # b = Attribute.new( "ns:x", "y" ) - # b.to_string # -> "ns:x='y'" - def to_string - value = to_s - if @element and @element.context and @element.context[:attribute_quote] == :quote - value = value.gsub('"', '"') if value.include?('"') - %Q^#@expanded_name="#{value}"^ - else - value = value.gsub("'", ''') if value.include?("'") - "#@expanded_name='#{value}'" - end - end - - def doctype - if @element - doc = @element.document - doc.doctype if doc - end - end - - # Returns the attribute value, with entities replaced - def to_s - return @normalized if @normalized - - @normalized = Text::normalize( @unnormalized, doctype ) - @normalized - end - - # Returns the UNNORMALIZED value of this attribute. That is, entities - # have been expanded to their values - def value - return @unnormalized if @unnormalized - - @unnormalized = Text::unnormalize(@normalized, doctype, - entity_expansion_text_limit: @element&.document&.entity_expansion_text_limit) - end - - # The normalized value of this attribute. That is, the attribute with - # entities intact. - def normalized=(new_normalized) - @normalized = new_normalized - @unnormalized = nil - end - - # Returns a copy of this attribute - def clone - Attribute.new self - end - - # Sets the element of which this object is an attribute. Normally, this - # is not directly called. - # - # Returns this attribute - def element=( element ) - @element = element - - if @normalized - Text.check( @normalized, NEEDS_A_SECOND_CHECK, doctype ) - end - - self - end - - # Removes this Attribute from the tree, and returns true if successful - # - # This method is usually not called directly. - def remove - @element.attributes.delete self.name unless @element.nil? - end - - # Writes this attribute (EG, puts 'key="value"' to the output) - def write( output, indent=-1 ) - output << to_string - end - - def node_type - :attribute - end - - def inspect - rv = +"" - write( rv ) - rv - end - - def xpath - path = @element.xpath - path += "/@#{self.expanded_name}" - return path - end - end -end -#vim:ts=2 sw=2 noexpandtab: diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/cdata.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/cdata.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/cdata.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/cdata.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,68 +0,0 @@ -# frozen_string_literal: false -require_relative "text" - -module REXML - class CData < Text - START = '' - ILLEGAL = /(\]\]>)/ - - # Constructor. CData is data between - # - # _Examples_ - # CData.new( source ) - # CData.new( "Here is some CDATA" ) - # CData.new( "Some unprocessed data", respect_whitespace_TF, parent_element ) - def initialize( first, whitespace=true, parent=nil ) - super( first, whitespace, parent, false, true, ILLEGAL ) - end - - # Make a copy of this object - # - # _Examples_ - # c = CData.new( "Some text" ) - # d = c.clone - # d.to_s # -> "Some text" - def clone - CData.new self - end - - # Returns the content of this CData object - # - # _Examples_ - # c = CData.new( "Some text" ) - # c.to_s # -> "Some text" - def to_s - @string - end - - def value - @string - end - - # == DEPRECATED - # See the rexml/formatters package - # - # Generates XML output of this object - # - # output:: - # Where to write the string. Defaults to $stdout - # indent:: - # The amount to indent this node by - # transitive:: - # Ignored - # ie_hack:: - # Ignored - # - # _Examples_ - # c = CData.new( " Some text " ) - # c.write( $stdout ) #-> - def write( output=$stdout, indent=-1, transitive=false, ie_hack=false ) - Kernel.warn( "#{self.class.name}.write is deprecated", uplevel: 1) - indent( output, indent ) - output << START - output << @string - output << STOP - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/child.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/child.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/child.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/child.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,97 +0,0 @@ -# frozen_string_literal: false -require_relative "node" - -module REXML - ## - # A Child object is something contained by a parent, and this class - # contains methods to support that. Most user code will not use this - # class directly. - class Child - include Node - attr_reader :parent # The Parent of this object - - # Constructor. Any inheritors of this class should call super to make - # sure this method is called. - # parent:: - # if supplied, the parent of this child will be set to the - # supplied value, and self will be added to the parent - def initialize( parent = nil ) - @parent = nil - # Declare @parent, but don't define it. The next line sets the - # parent. - parent.add( self ) if parent - end - - # Replaces this object with another object. Basically, calls - # Parent.replace_child - # - # Returns:: self - def replace_with( child ) - @parent.replace_child( self, child ) - self - end - - # Removes this child from the parent. - # - # Returns:: self - def remove - unless @parent.nil? - @parent.delete self - end - self - end - - # Sets the parent of this child to the supplied argument. - # - # other:: - # Must be a Parent object. If this object is the same object as the - # existing parent of this child, no action is taken. Otherwise, this - # child is removed from the current parent (if one exists), and is added - # to the new parent. - # Returns:: The parent added - def parent=( other ) - return @parent if @parent == other - @parent.delete self if defined? @parent and @parent - @parent = other - end - - alias :next_sibling :next_sibling_node - alias :previous_sibling :previous_sibling_node - - # Sets the next sibling of this child. This can be used to insert a child - # after some other child. - # a = Element.new("a") - # b = a.add_element("b") - # c = Element.new("c") - # b.next_sibling = c - # # => - def next_sibling=( other ) - parent.insert_after self, other - end - - # Sets the previous sibling of this child. This can be used to insert a - # child before some other child. - # a = Element.new("a") - # b = a.add_element("b") - # c = Element.new("c") - # b.previous_sibling = c - # # => - def previous_sibling=(other) - parent.insert_before self, other - end - - # Returns:: the document this child belongs to, or nil if this child - # belongs to no document - def document - return parent.document unless parent.nil? - nil - end - - # This doesn't yet handle encodings - def bytes - document.encoding - - to_s - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/comment.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/comment.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/comment.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/comment.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,80 +0,0 @@ -# frozen_string_literal: false -require_relative "child" - -module REXML - ## - # Represents an XML comment; that is, text between \ - class Comment < Child - include Comparable - START = "" - - # The content text - - attr_accessor :string - - ## - # Constructor. The first argument can be one of three types: - # @param first If String, the contents of this comment are set to the - # argument. If Comment, the argument is duplicated. If - # Source, the argument is scanned for a comment. - # @param second If the first argument is a Source, this argument - # should be nil, not supplied, or a Parent to be set as the parent - # of this object - def initialize( first, second = nil ) - super(second) - if first.kind_of? String - @string = first - elsif first.kind_of? Comment - @string = first.string - end - end - - def clone - Comment.new self - end - - # == DEPRECATED - # See REXML::Formatters - # - # output:: - # Where to write the string - # indent:: - # An integer. If -1, no indenting will be used; otherwise, the - # indentation will be this number of spaces, and children will be - # indented an additional amount. - # transitive:: - # Ignored by this class. The contents of comments are never modified. - # ie_hack:: - # Needed for conformity to the child API, but not used by this class. - def write( output, indent=-1, transitive=false, ie_hack=false ) - Kernel.warn("Comment.write is deprecated. See REXML::Formatters", uplevel: 1) - indent( output, indent ) - output << START - output << @string - output << STOP - end - - alias :to_s :string - - ## - # Compares this Comment to another; the contents of the comment are used - # in the comparison. - def <=>(other) - other.to_s <=> @string - end - - ## - # Compares this Comment to another; the contents of the comment are used - # in the comparison. - def ==( other ) - other.kind_of? Comment and - (other <=> self) == 0 - end - - def node_type - :comment - end - end -end -#vim:ts=2 sw=2 noexpandtab: diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/doctype.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/doctype.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/doctype.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/doctype.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,311 +0,0 @@ -# frozen_string_literal: false -require_relative "parent" -require_relative "parseexception" -require_relative "namespace" -require_relative 'entity' -require_relative 'attlistdecl' -require_relative 'xmltokens' - -module REXML - class ReferenceWriter - def initialize(id_type, - public_id_literal, - system_literal, - context=nil) - @id_type = id_type - @public_id_literal = public_id_literal - @system_literal = system_literal - if context and context[:prologue_quote] == :apostrophe - @default_quote = "'" - else - @default_quote = "\"" - end - end - - def write(output) - output << " #{@id_type}" - if @public_id_literal - if @public_id_literal.include?("'") - quote = "\"" - else - quote = @default_quote - end - output << " #{quote}#{@public_id_literal}#{quote}" - end - if @system_literal - if @system_literal.include?("'") - quote = "\"" - elsif @system_literal.include?("\"") - quote = "'" - else - quote = @default_quote - end - output << " #{quote}#{@system_literal}#{quote}" - end - end - end - - # Represents an XML DOCTYPE declaration; that is, the contents of . DOCTYPES can be used to declare the DTD of a document, as well as - # being used to declare entities used in the document. - class DocType < Parent - include XMLTokens - START = "" - SYSTEM = "SYSTEM" - PUBLIC = "PUBLIC" - DEFAULT_ENTITIES = { - 'gt'=>EntityConst::GT, - 'lt'=>EntityConst::LT, - 'quot'=>EntityConst::QUOT, - "apos"=>EntityConst::APOS - } - - # name is the name of the doctype - # external_id is the referenced DTD, if given - attr_reader :name, :external_id, :entities, :namespaces - - # Constructor - # - # dt = DocType.new( 'foo', '-//I/Hate/External/IDs' ) - # # - # dt = DocType.new( doctype_to_clone ) - # # Incomplete. Shallow clone of doctype - # - # +Note+ that the constructor: - # - # Doctype.new( Source.new( "" ) ) - # - # is _deprecated_. Do not use it. It will probably disappear. - def initialize( first, parent=nil ) - @entities = DEFAULT_ENTITIES - @long_name = @uri = nil - if first.kind_of? String - super() - @name = first - @external_id = parent - elsif first.kind_of? DocType - super( parent ) - @name = first.name - @external_id = first.external_id - @long_name = first.instance_variable_get(:@long_name) - @uri = first.instance_variable_get(:@uri) - elsif first.kind_of? Array - super( parent ) - @name = first[0] - @external_id = first[1] - @long_name = first[2] - @uri = first[3] - elsif first.kind_of? Source - super( parent ) - parser = Parsers::BaseParser.new( first ) - event = parser.pull - if event[0] == :start_doctype - @name, @external_id, @long_name, @uri, = event[1..-1] - end - else - super() - end - end - - def node_type - :doctype - end - - def attributes_of element - rv = [] - each do |child| - child.each do |key,val| - rv << Attribute.new(key,val) - end if child.kind_of? AttlistDecl and child.element_name == element - end - rv - end - - def attribute_of element, attribute - att_decl = find do |child| - child.kind_of? AttlistDecl and - child.element_name == element and - child.include? attribute - end - return nil unless att_decl - att_decl[attribute] - end - - def clone - DocType.new self - end - - # output:: - # Where to write the string - # indent:: - # An integer. If -1, no indentation will be used; otherwise, the - # indentation will be this number of spaces, and children will be - # indented an additional amount. - # transitive:: - # Ignored - # ie_hack:: - # Ignored - def write( output, indent=0, transitive=false, ie_hack=false ) - f = REXML::Formatters::Default.new - indent( output, indent ) - output << START - output << ' ' - output << @name - if @external_id - reference_writer = ReferenceWriter.new(@external_id, - @long_name, - @uri, - context) - reference_writer.write(output) - end - unless @children.empty? - output << ' [' - @children.each { |child| - output << "\n" - f.write( child, output ) - } - output << "\n]" - end - output << STOP - end - - def context - if @parent - @parent.context - else - nil - end - end - - def entity( name ) - @entities[name].unnormalized if @entities[name] - end - - def add child - super(child) - @entities = DEFAULT_ENTITIES.clone if @entities == DEFAULT_ENTITIES - @entities[ child.name ] = child if child.kind_of? Entity - end - - # This method retrieves the public identifier identifying the document's - # DTD. - # - # Method contributed by Henrik Martensson - def public - case @external_id - when "SYSTEM" - nil - when "PUBLIC" - @long_name - end - end - - # This method retrieves the system identifier identifying the document's DTD - # - # Method contributed by Henrik Martensson - def system - case @external_id - when "SYSTEM" - @long_name - when "PUBLIC" - @uri.kind_of?(String) ? @uri : nil - end - end - - # This method returns a list of notations that have been declared in the - # _internal_ DTD subset. Notations in the external DTD subset are not - # listed. - # - # Method contributed by Henrik Martensson - def notations - children().select {|node| node.kind_of?(REXML::NotationDecl)} - end - - # Retrieves a named notation. Only notations declared in the internal - # DTD subset can be retrieved. - # - # Method contributed by Henrik Martensson - def notation(name) - notations.find { |notation_decl| - notation_decl.name == name - } - end - end - - # We don't really handle any of these since we're not a validating - # parser, so we can be pretty dumb about them. All we need to be able - # to do is spew them back out on a write() - - # This is an abstract class. You never use this directly; it serves as a - # parent class for the specific declarations. - class Declaration < Child - def initialize src - super() - @string = src - end - - def to_s - @string+'>' - end - - # == DEPRECATED - # See REXML::Formatters - # - def write( output, indent ) - output << to_s - end - end - - public - class ElementDecl < Declaration - def initialize( src ) - super - end - end - - class ExternalEntity < Child - def initialize( src ) - super() - @entity = src - end - def to_s - @entity - end - def write( output, indent ) - output << @entity - end - end - - class NotationDecl < Child - attr_accessor :public, :system - def initialize name, middle, pub, sys - super(nil) - @name = name - @middle = middle - @public = pub - @system = sys - end - - def to_s - context = nil - context = parent.context if parent - notation = "" - notation - end - - def write( output, indent=-1 ) - output << to_s - end - - # This method retrieves the name of the notation. - # - # Method contributed by Henrik Martensson - def name - @name - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/document.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/document.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/document.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/document.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,455 +0,0 @@ -# frozen_string_literal: false -require_relative "security" -require_relative "element" -require_relative "xmldecl" -require_relative "source" -require_relative "comment" -require_relative "doctype" -require_relative "instruction" -require_relative "rexml" -require_relative "parseexception" -require_relative "output" -require_relative "parsers/baseparser" -require_relative "parsers/streamparser" -require_relative "parsers/treeparser" - -module REXML - # Represents an XML document. - # - # A document may have: - # - # - A single child that may be accessed via method #root. - # - An XML declaration. - # - A document type. - # - Processing instructions. - # - # == In a Hurry? - # - # If you're somewhat familiar with XML - # and have a particular task in mind, - # you may want to see the - # {tasks pages}[../doc/rexml/tasks/tocs/master_toc_rdoc.html], - # and in particular, the - # {tasks page for documents}[../doc/rexml/tasks/tocs/document_toc_rdoc.html]. - # - class Document < Element - # A convenient default XML declaration. Use: - # - # mydoc << XMLDecl.default - # - DECLARATION = XMLDecl.default - - # :call-seq: - # new(string = nil, context = {}) -> new_document - # new(io_stream = nil, context = {}) -> new_document - # new(document = nil, context = {}) -> new_document - # - # Returns a new \REXML::Document object. - # - # When no arguments are given, - # returns an empty document: - # - # d = REXML::Document.new - # d.to_s # => "" - # - # When argument +string+ is given, it must be a string - # containing a valid XML document: - # - # xml_string = 'FooBar' - # d = REXML::Document.new(xml_string) - # d.to_s # => "FooBar" - # - # When argument +io_stream+ is given, it must be an \IO object - # that is opened for reading, and when read must return a valid XML document: - # - # File.write('t.xml', xml_string) - # d = File.open('t.xml', 'r') do |io| - # REXML::Document.new(io) - # end - # d.to_s # => "FooBar" - # - # When argument +document+ is given, it must be an existing - # document object, whose context and attributes (but not children) - # are cloned into the new document: - # - # d = REXML::Document.new(xml_string) - # d.children # => [ ... ] - # d.context = {raw: :all, compress_whitespace: :all} - # d.add_attributes({'bar' => 0, 'baz' => 1}) - # d1 = REXML::Document.new(d) - # d1.children # => [] - # d1.context # => {:raw=>:all, :compress_whitespace=>:all} - # d1.attributes # => {"bar"=>bar='0', "baz"=>baz='1'} - # - # When argument +context+ is given, it must be a hash - # containing context entries for the document; - # see {Element Context}[../doc/rexml/context_rdoc.html]: - # - # context = {raw: :all, compress_whitespace: :all} - # d = REXML::Document.new(xml_string, context) - # d.context # => {:raw=>:all, :compress_whitespace=>:all} - # - def initialize( source = nil, context = {} ) - @entity_expansion_count = 0 - @entity_expansion_limit = Security.entity_expansion_limit - @entity_expansion_text_limit = Security.entity_expansion_text_limit - super() - @context = context - return if source.nil? - if source.kind_of? Document - @context = source.context - super source - else - build( source ) - end - end - - # :call-seq: - # node_type -> :document - # - # Returns the symbol +:document+. - # - def node_type - :document - end - - # :call-seq: - # clone -> new_document - # - # Returns the new document resulting from executing - # Document.new(self). See Document.new. - # - def clone - Document.new self - end - - # :call-seq: - # expanded_name -> empty_string - # - # Returns an empty string. - # - def expanded_name - '' - #d = doc_type - #d ? d.name : "UNDEFINED" - end - alias :name :expanded_name - - # :call-seq: - # add(xml_decl) -> self - # add(doc_type) -> self - # add(object) -> self - # - # Adds an object to the document; returns +self+. - # - # When argument +xml_decl+ is given, - # it must be an REXML::XMLDecl object, - # which becomes the XML declaration for the document, - # replacing the previous XML declaration if any: - # - # d = REXML::Document.new - # d.xml_decl.to_s # => "" - # d.add(REXML::XMLDecl.new('2.0')) - # d.xml_decl.to_s # => "" - # - # When argument +doc_type+ is given, - # it must be an REXML::DocType object, - # which becomes the document type for the document, - # replacing the previous document type, if any: - # - # d = REXML::Document.new - # d.doctype.to_s # => "" - # d.add(REXML::DocType.new('foo')) - # d.doctype.to_s # => "" - # - # When argument +object+ (not an REXML::XMLDecl or REXML::DocType object) - # is given it is added as the last child: - # - # d = REXML::Document.new - # d.add(REXML::Element.new('foo')) - # d.to_s # => "" - # - def add( child ) - if child.kind_of? XMLDecl - if @children[0].kind_of? XMLDecl - @children[0] = child - else - @children.unshift child - end - child.parent = self - elsif child.kind_of? DocType - # Find first Element or DocType node and insert the decl right - # before it. If there is no such node, just insert the child at the - # end. If there is a child and it is an DocType, then replace it. - insert_before_index = @children.find_index { |x| - x.kind_of?(Element) || x.kind_of?(DocType) - } - if insert_before_index # Not null = not end of list - if @children[ insert_before_index ].kind_of? DocType - @children[ insert_before_index ] = child - else - @children[ insert_before_index-1, 0 ] = child - end - else # Insert at end of list - @children << child - end - child.parent = self - else - rv = super - raise "attempted adding second root element to document" if @elements.size > 1 - rv - end - end - alias :<< :add - - # :call-seq: - # add_element(name_or_element = nil, attributes = nil) -> new_element - # - # Adds an element to the document by calling REXML::Element.add_element: - # - # REXML::Element.add_element(name_or_element, attributes) - def add_element(arg=nil, arg2=nil) - rv = super - raise "attempted adding second root element to document" if @elements.size > 1 - rv - end - - # :call-seq: - # root -> root_element or nil - # - # Returns the root element of the document, if it exists, otherwise +nil+: - # - # d = REXML::Document.new('') - # d.root # => - # d = REXML::Document.new('') - # d.root # => nil - # - def root - elements[1] - #self - #@children.find { |item| item.kind_of? Element } - end - - # :call-seq: - # doctype -> doc_type or nil - # - # Returns the DocType object for the document, if it exists, otherwise +nil+: - # - # d = REXML::Document.new('') - # d.doctype.class # => REXML::DocType - # d = REXML::Document.new('') - # d.doctype.class # => nil - # - def doctype - @children.find { |item| item.kind_of? DocType } - end - - # :call-seq: - # xml_decl -> xml_decl - # - # Returns the XMLDecl object for the document, if it exists, - # otherwise the default XMLDecl object: - # - # d = REXML::Document.new('') - # d.xml_decl.class # => REXML::XMLDecl - # d.xml_decl.to_s # => "" - # d = REXML::Document.new('') - # d.xml_decl.class # => REXML::XMLDecl - # d.xml_decl.to_s # => "" - # - def xml_decl - rv = @children[0] - return rv if rv.kind_of? XMLDecl - @children.unshift(XMLDecl.default)[0] - end - - # :call-seq: - # version -> version_string - # - # Returns the XMLDecl version of this document as a string, - # if it has been set, otherwise the default version: - # - # d = REXML::Document.new('') - # d.version # => "2.0" - # d = REXML::Document.new('') - # d.version # => "1.0" - # - def version - xml_decl().version - end - - # :call-seq: - # encoding -> encoding_string - # - # Returns the XMLDecl encoding of the document, - # if it has been set, otherwise the default encoding: - # - # d = REXML::Document.new('') - # d.encoding # => "UTF-16" - # d = REXML::Document.new('') - # d.encoding # => "UTF-8" - # - def encoding - xml_decl().encoding - end - - # :call-seq: - # stand_alone? - # - # Returns the XMLDecl standalone value of the document as a string, - # if it has been set, otherwise the default standalone value: - # - # d = REXML::Document.new('') - # d.stand_alone? # => "yes" - # d = REXML::Document.new('') - # d.stand_alone? # => nil - # - def stand_alone? - xml_decl().stand_alone? - end - - # :call-seq: - # doc.write(output=$stdout, indent=-1, transtive=false, ie_hack=false, encoding=nil) - # doc.write(options={:output => $stdout, :indent => -1, :transtive => false, :ie_hack => false, :encoding => nil}) - # - # Write the XML tree out, optionally with indent. This writes out the - # entire XML document, including XML declarations, doctype declarations, - # and processing instructions (if any are given). - # - # A controversial point is whether Document should always write the XML - # declaration () whether or not one is given by the - # user (or source document). REXML does not write one if one was not - # specified, because it adds unnecessary bandwidth to applications such - # as XML-RPC. - # - # Accept Nth argument style and options Hash style as argument. - # The recommended style is options Hash style for one or more - # arguments case. - # - # _Examples_ - # Document.new("").write - # - # output = "" - # Document.new("").write(output) - # - # output = "" - # Document.new("").write(:output => output, :indent => 2) - # - # See also the classes in the rexml/formatters package for the proper way - # to change the default formatting of XML output. - # - # _Examples_ - # - # output = "" - # tr = Transitive.new - # tr.write(Document.new(""), output) - # - # output:: - # output an object which supports '<< string'; this is where the - # document will be written. - # indent:: - # An integer. If -1, no indenting will be used; otherwise, the - # indentation will be twice this number of spaces, and children will be - # indented an additional amount. For a value of 3, every item will be - # indented 3 more levels, or 6 more spaces (2 * 3). Defaults to -1 - # transitive:: - # If transitive is true and indent is >= 0, then the output will be - # pretty-printed in such a way that the added whitespace does not affect - # the absolute *value* of the document -- that is, it leaves the value - # and number of Text nodes in the document unchanged. - # ie_hack:: - # This hack inserts a space before the /> on empty tags to address - # a limitation of Internet Explorer. Defaults to false - # encoding:: - # Encoding name as String. Change output encoding to specified encoding - # instead of encoding in XML declaration. - # Defaults to nil. It means encoding in XML declaration is used. - def write(*arguments) - if arguments.size == 1 and arguments[0].class == Hash - options = arguments[0] - - output = options[:output] - indent = options[:indent] - transitive = options[:transitive] - ie_hack = options[:ie_hack] - encoding = options[:encoding] - else - output, indent, transitive, ie_hack, encoding, = *arguments - end - - output ||= $stdout - indent ||= -1 - transitive = false if transitive.nil? - ie_hack = false if ie_hack.nil? - encoding ||= xml_decl.encoding - - if encoding != 'UTF-8' && !output.kind_of?(Output) - output = Output.new( output, encoding ) - end - formatter = if indent > -1 - if transitive - require_relative "formatters/transitive" - REXML::Formatters::Transitive.new( indent, ie_hack ) - else - REXML::Formatters::Pretty.new( indent, ie_hack ) - end - else - REXML::Formatters::Default.new( ie_hack ) - end - formatter.write( self, output ) - end - - - def Document::parse_stream( source, listener ) - Parsers::StreamParser.new( source, listener ).parse - end - - # Set the entity expansion limit. By default the limit is set to 10000. - # - # Deprecated. Use REXML::Security.entity_expansion_limit= instead. - def Document::entity_expansion_limit=( val ) - Security.entity_expansion_limit = val - end - - # Get the entity expansion limit. By default the limit is set to 10000. - # - # Deprecated. Use REXML::Security.entity_expansion_limit= instead. - def Document::entity_expansion_limit - return Security.entity_expansion_limit - end - - # Set the entity expansion limit. By default the limit is set to 10240. - # - # Deprecated. Use REXML::Security.entity_expansion_text_limit= instead. - def Document::entity_expansion_text_limit=( val ) - Security.entity_expansion_text_limit = val - end - - # Get the entity expansion limit. By default the limit is set to 10240. - # - # Deprecated. Use REXML::Security.entity_expansion_text_limit instead. - def Document::entity_expansion_text_limit - return Security.entity_expansion_text_limit - end - - attr_reader :entity_expansion_count - attr_writer :entity_expansion_limit - attr_accessor :entity_expansion_text_limit - - def record_entity_expansion - @entity_expansion_count += 1 - if @entity_expansion_count > @entity_expansion_limit - raise "number of entity expansions exceeded, processing aborted." - end - end - - def document - self - end - - private - def build( source ) - Parsers::TreeParser.new( source, self ).parse - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/attlistdecl.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/attlistdecl.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/attlistdecl.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/attlistdecl.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,11 +0,0 @@ -# frozen_string_literal: false -require_relative "../child" -module REXML - module DTD - class AttlistDecl < Child - START = ")/um - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/dtd.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/dtd.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/dtd.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/dtd.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,47 +0,0 @@ -# frozen_string_literal: false -require_relative "elementdecl" -require_relative "entitydecl" -require_relative "../comment" -require_relative "notationdecl" -require_relative "attlistdecl" -require_relative "../parent" - -module REXML - module DTD - class Parser - def Parser.parse( input ) - case input - when String - parse_helper input - when File - parse_helper input.read - end - end - - # Takes a String and parses it out - def Parser.parse_helper( input ) - contents = Parent.new - while input.size > 0 - case input - when ElementDecl.PATTERN_RE - match = $& - contents << ElementDecl.new( match ) - when AttlistDecl.PATTERN_RE - matchdata = $~ - contents << AttlistDecl.new( matchdata ) - when EntityDecl.PATTERN_RE - matchdata = $~ - contents << EntityDecl.new( matchdata ) - when Comment.PATTERN_RE - matchdata = $~ - contents << Comment.new( matchdata ) - when NotationDecl.PATTERN_RE - matchdata = $~ - contents << NotationDecl.new( matchdata ) - end - end - contents - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/elementdecl.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/elementdecl.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/elementdecl.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/elementdecl.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,18 +0,0 @@ -# frozen_string_literal: false -require_relative "../child" -module REXML - module DTD - class ElementDecl < Child - START = "/um - PATTERN_RE = /^\s*#{START}\s+((?:[:\w][-\.\w]*:)?[-!\*\.\w]*)(.*?)>/ - #\s*((((["']).*?\5)|[^\/'">]*)*?)(\/)?>/um, true) - - def initialize match - @name = match[1] - @rest = match[2] - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/entitydecl.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/entitydecl.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/entitydecl.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/entitydecl.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,57 +0,0 @@ -# frozen_string_literal: false -require_relative "../child" -module REXML - module DTD - class EntityDecl < Child - START = "/um - SYSTEM = /^\s*#{START}\s+(?:%\s+)?(\w+)\s+SYSTEM\s+((["']).*?\3)(?:\s+NDATA\s+\w+)?\s*>/um - PLAIN = /^\s*#{START}\s+(\w+)\s+((["']).*?\3)\s*>/um - PERCENT = /^\s*#{START}\s+%\s+(\w+)\s+((["']).*?\3)\s*>/um - # - # - def initialize src - super() - md = nil - if src.match( PUBLIC ) - md = src.match( PUBLIC, true ) - @middle = "PUBLIC" - @content = "#{md[2]} #{md[4]}" - elsif src.match( SYSTEM ) - md = src.match( SYSTEM, true ) - @middle = "SYSTEM" - @content = md[2] - elsif src.match( PLAIN ) - md = src.match( PLAIN, true ) - @middle = "" - @content = md[2] - elsif src.match( PERCENT ) - md = src.match( PERCENT, true ) - @middle = "" - @content = md[2] - end - raise ParseException.new("failed Entity match", src) if md.nil? - @name = md[1] - end - - def to_s - rv = " 0 - rv << @content - rv - end - - def write( output, indent ) - indent( output, indent ) - output << to_s - end - - def EntityDecl.parse_source source, listener - md = source.match( PATTERN_RE, true ) - thing = md[0].squeeze(" \t\n\r") - listener.send inspect.downcase, thing - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/notationdecl.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/notationdecl.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/notationdecl.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/dtd/notationdecl.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,40 +0,0 @@ -# frozen_string_literal: false -require_relative "../child" -module REXML - module DTD - class NotationDecl < Child - START = "/um - SYSTEM = /^\s*#{START}\s+(\w[\w-]*)\s+(SYSTEM)\s+((["']).*?\4)\s*>/um - def initialize src - super() - if src.match( PUBLIC ) - md = src.match( PUBLIC, true ) - elsif src.match( SYSTEM ) - md = src.match( SYSTEM, true ) - else - raise ParseException.new( "error parsing notation: no matching pattern", src ) - end - @name = md[1] - @middle = md[2] - @rest = md[3] - end - - def to_s - "" - end - - def write( output, indent ) - indent( output, indent ) - output << to_s - end - - def NotationDecl.parse_source source, listener - md = source.match( PATTERN_RE, true ) - thing = md[0].squeeze(" \t\n\r") - listener.send inspect.downcase, thing - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/element.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/element.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/element.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/element.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,2584 +0,0 @@ -# frozen_string_literal: false -require_relative "parent" -require_relative "namespace" -require_relative "attribute" -require_relative "cdata" -require_relative "xpath" -require_relative "parseexception" - -module REXML - # An \REXML::Element object represents an XML element. - # - # An element: - # - # - Has a name (string). - # - May have a parent (another element). - # - Has zero or more children - # (other elements, text, CDATA, processing instructions, and comments). - # - Has zero or more siblings - # (other elements, text, CDATA, processing instructions, and comments). - # - Has zero or more named attributes. - # - # == In a Hurry? - # - # If you're somewhat familiar with XML - # and have a particular task in mind, - # you may want to see the - # {tasks pages}[../doc/rexml/tasks/tocs/master_toc_rdoc.html], - # and in particular, the - # {tasks page for elements}[../doc/rexml/tasks/tocs/element_toc_rdoc.html]. - # - # === Name - # - # An element has a name, which is initially set when the element is created: - # - # e = REXML::Element.new('foo') - # e.name # => "foo" - # - # The name may be changed: - # - # e.name = 'bar' - # e.name # => "bar" - # - # - # === \Parent - # - # An element may have a parent. - # - # Its parent may be assigned explicitly when the element is created: - # - # e0 = REXML::Element.new('foo') - # e1 = REXML::Element.new('bar', e0) - # e1.parent # => ... - # - # Note: the representation of an element always shows the element's name. - # If the element has children, the representation indicates that - # by including an ellipsis (...). - # - # The parent may be assigned explicitly at any time: - # - # e2 = REXML::Element.new('baz') - # e1.parent = e2 - # e1.parent # => - # - # When an element is added as a child, its parent is set automatically: - # - # e1.add_element(e0) - # e0.parent # => ... - # - # For an element that has no parent, method +parent+ returns +nil+. - # - # === Children - # - # An element has zero or more children. - # The children are an ordered collection - # of all objects whose parent is the element itself. - # - # The children may include any combination of elements, text, comments, - # processing instructions, and CDATA. - # (This example keeps things clean by controlling whitespace - # via a +context+ setting.) - # - # xml_string = <<-EOT - # - # - # text 0 - # - # - # - # - # text 1 - # - # - # - # - # EOT - # context = {ignore_whitespace_nodes: :all, compress_whitespace: :all} - # d = REXML::Document.new(xml_string, context) - # root = d.root - # root.children.size # => 10 - # root.each {|child| p "#{child.class}: #{child}" } - # - # Output: - # - # "REXML::Element: " - # "REXML::Text: \n text 0\n " - # "REXML::Comment: comment 0" - # "REXML::Instruction: " - # "REXML::CData: cdata 0" - # "REXML::Element: " - # "REXML::Text: \n text 1\n " - # "REXML::Comment: comment 1" - # "REXML::Instruction: " - # "REXML::CData: cdata 1" - # - # A child may be added using inherited methods - # Parent#insert_before or Parent#insert_after: - # - # xml_string = '' - # d = REXML::Document.new(xml_string) - # root = d.root - # c = d.root[1] # => - # root.insert_before(c, REXML::Element.new('b')) - # root.to_a # => [, , , ] - # - # A child may be replaced using Parent#replace_child: - # - # root.replace_child(c, REXML::Element.new('x')) - # root.to_a # => [, , , ] - # - # A child may be removed using Parent#delete: - # - # x = root[2] # => - # root.delete(x) - # root.to_a # => [, , ] - # - # === Siblings - # - # An element has zero or more siblings, - # which are the other children of the element's parent. - # - # In the example above, element +ele_1+ is between a CDATA sibling - # and a text sibling: - # - # ele_1 = root[5] # => - # ele_1.previous_sibling # => "cdata 0" - # ele_1.next_sibling # => "\n text 1\n " - # - # === \Attributes - # - # An element has zero or more named attributes. - # - # A new element has no attributes: - # - # e = REXML::Element.new('foo') - # e.attributes # => {} - # - # Attributes may be added: - # - # e.add_attribute('bar', 'baz') - # e.add_attribute('bat', 'bam') - # e.attributes.size # => 2 - # e['bar'] # => "baz" - # e['bat'] # => "bam" - # - # An existing attribute may be modified: - # - # e.add_attribute('bar', 'bad') - # e.attributes.size # => 2 - # e['bar'] # => "bad" - # - # An existing attribute may be deleted: - # - # e.delete_attribute('bar') - # e.attributes.size # => 1 - # e['bar'] # => nil - # - # == What's Here - # - # To begin with, what's elsewhere? - # - # \Class \REXML::Element inherits from its ancestor classes: - # - # - REXML::Child - # - REXML::Parent - # - # \REXML::Element itself and its ancestors also include modules: - # - # - {Enumerable}[https://docs.ruby-lang.org/en/master/Enumerable.html] - # - REXML::Namespace - # - REXML::Node - # - REXML::XMLTokens - # - # === Methods for Creating an \Element - # - # ::new:: Returns a new empty element. - # #clone:: Returns a clone of another element. - # - # === Methods for Attributes - # - # {[attribute_name]}[#method-i-5B-5D]:: Returns an attribute value. - # #add_attribute:: Adds a new attribute. - # #add_attributes:: Adds multiple new attributes. - # #attribute:: Returns the attribute value for a given name and optional namespace. - # #delete_attribute:: Removes an attribute. - # - # === Methods for Children - # - # {[index]}[#method-i-5B-5D]:: Returns the child at the given offset. - # #add_element:: Adds an element as the last child. - # #delete_element:: Deletes a child element. - # #each_element:: Calls the given block with each child element. - # #each_element_with_attribute:: Calls the given block with each child element - # that meets given criteria, - # which can include the attribute name. - # #each_element_with_text:: Calls the given block with each child element - # that meets given criteria, - # which can include text. - # #get_elements:: Returns an array of element children that match a given xpath. - # - # === Methods for \Text Children - # - # #add_text:: Adds a text node to the element. - # #get_text:: Returns a text node that meets specified criteria. - # #text:: Returns the text string from the first node that meets specified criteria. - # #texts:: Returns an array of the text children of the element. - # #text=:: Adds, removes, or replaces the first text child of the element - # - # === Methods for Other Children - # - # #cdatas:: Returns an array of the cdata children of the element. - # #comments:: Returns an array of the comment children of the element. - # #instructions:: Returns an array of the instruction children of the element. - # - # === Methods for Namespaces - # - # #add_namespace:: Adds a namespace to the element. - # #delete_namespace:: Removes a namespace from the element. - # #namespace:: Returns the string namespace URI for the element. - # #namespaces:: Returns a hash of all defined namespaces in the element. - # #prefixes:: Returns an array of the string prefixes (names) - # of all defined namespaces in the element - # - # === Methods for Querying - # - # #document:: Returns the document, if any, that the element belongs to. - # #root:: Returns the most distant element (not document) ancestor of the element. - # #root_node:: Returns the most distant ancestor of the element. - # #xpath:: Returns the string xpath to the element - # relative to the most distant parent - # #has_attributes?:: Returns whether the element has attributes. - # #has_elements?:: Returns whether the element has elements. - # #has_text?:: Returns whether the element has text. - # #next_element:: Returns the next sibling that is an element. - # #previous_element:: Returns the previous sibling that is an element. - # #raw:: Returns whether raw mode is set for the element. - # #whitespace:: Returns whether whitespace is respected for the element. - # #ignore_whitespace_nodes:: Returns whether whitespace nodes - # are to be ignored for the element. - # #node_type:: Returns symbol :element. - # - # === One More Method - # - # #inspect:: Returns a string representation of the element. - # - # === Accessors - # - # #elements:: Returns the REXML::Elements object for the element. - # #attributes:: Returns the REXML::Attributes object for the element. - # #context:: Returns or sets the context hash for the element. - # - class Element < Parent - include Namespace - - UNDEFINED = "UNDEFINED"; # The default name - - # Mechanisms for accessing attributes and child elements of this - # element. - attr_reader :attributes, :elements - # The context holds information about the processing environment, such as - # whitespace handling. - attr_accessor :context - - # :call-seq: - # Element.new(name = 'UNDEFINED', parent = nil, context = nil) -> new_element - # Element.new(element, parent = nil, context = nil) -> new_element - # - # Returns a new \REXML::Element object. - # - # When no arguments are given, - # returns an element with name 'UNDEFINED': - # - # e = REXML::Element.new # => - # e.class # => REXML::Element - # e.name # => "UNDEFINED" - # - # When only argument +name+ is given, - # returns an element of the given name: - # - # REXML::Element.new('foo') # => - # - # When only argument +element+ is given, it must be an \REXML::Element object; - # returns a shallow copy of the given element: - # - # e0 = REXML::Element.new('foo') - # e1 = REXML::Element.new(e0) # => - # - # When argument +parent+ is also given, it must be an REXML::Parent object: - # - # e = REXML::Element.new('foo', REXML::Parent.new) - # e.parent # => #]> - # - # When argument +context+ is also given, it must be a hash - # representing the context for the element; - # see {Element Context}[../doc/rexml/context_rdoc.html]: - # - # e = REXML::Element.new('foo', nil, {raw: :all}) - # e.context # => {:raw=>:all} - # - def initialize( arg = UNDEFINED, parent=nil, context=nil ) - super(parent) - - @elements = Elements.new(self) - @attributes = Attributes.new(self) - @context = context - - if arg.kind_of? String - self.name = arg - elsif arg.kind_of? Element - self.name = arg.expanded_name - arg.attributes.each_attribute{ |attribute| - @attributes << Attribute.new( attribute ) - } - @context = arg.context - end - end - - # :call-seq: - # inspect -> string - # - # Returns a string representation of the element. - # - # For an element with no attributes and no children, shows the element name: - # - # REXML::Element.new.inspect # => "" - # - # Shows attributes, if any: - # - # e = REXML::Element.new('foo') - # e.add_attributes({'bar' => 0, 'baz' => 1}) - # e.inspect # => "" - # - # Shows an ellipsis (...), if there are child elements: - # - # e.add_element(REXML::Element.new('bar')) - # e.add_element(REXML::Element.new('baz')) - # e.inspect # => " ... " - # - def inspect - rv = "<#@expanded_name" - - @attributes.each_attribute do |attr| - rv << " " - attr.write( rv, 0 ) - end - - if children.size > 0 - rv << "> ... " - else - rv << "/>" - end - end - - # :call-seq: - # clone -> new_element - # - # Returns a shallow copy of the element, containing the name and attributes, - # but not the parent or children: - # - # e = REXML::Element.new('foo') - # e.add_attributes({'bar' => 0, 'baz' => 1}) - # e.clone # => - # - def clone - self.class.new self - end - - # :call-seq: - # root_node -> document or element - # - # Returns the most distant ancestor of +self+. - # - # When the element is part of a document, - # returns the root node of the document. - # Note that the root node is different from the document element; - # in this example +a+ is document element and the root node is its parent: - # - # d = REXML::Document.new('') - # top_element = d.first # => ... - # child = top_element.first # => ... - # d.root_node == d # => true - # top_element.root_node == d # => true - # child.root_node == d # => true - # - # When the element is not part of a document, but does have ancestor elements, - # returns the most distant ancestor element: - # - # e0 = REXML::Element.new('foo') - # e1 = REXML::Element.new('bar') - # e1.parent = e0 - # e2 = REXML::Element.new('baz') - # e2.parent = e1 - # e2.root_node == e0 # => true - # - # When the element has no ancestor elements, - # returns +self+: - # - # e = REXML::Element.new('foo') - # e.root_node == e # => true - # - # Related: #root, #document. - # - def root_node - parent.nil? ? self : parent.root_node - end - - # :call-seq: - # root -> element - # - # Returns the most distant _element_ (not document) ancestor of the element: - # - # d = REXML::Document.new('') - # top_element = d.first - # child = top_element.first - # top_element.root == top_element # => true - # child.root == top_element # => true - # - # For a document, returns the topmost element: - # - # d.root == top_element # => true - # - # Related: #root_node, #document. - # - def root - target = self - while target - return target.elements[1] if target.kind_of? Document - parent = target.parent - return target if parent.kind_of? Document or parent.nil? - target = parent - end - nil - end - - # :call-seq: - # document -> document or nil - # - # If the element is part of a document, returns that document: - # - # d = REXML::Document.new('') - # top_element = d.first - # child = top_element.first - # top_element.document == d # => true - # child.document == d # => true - # - # If the element is not part of a document, returns +nil+: - # - # REXML::Element.new.document # => nil - # - # For a document, returns +self+: - # - # d.document == d # => true - # - # Related: #root, #root_node. - # - def document - rt = root - rt.parent if rt - end - - # :call-seq: - # whitespace - # - # Returns +true+ if whitespace is respected for this element, - # +false+ otherwise. - # - # See {Element Context}[../doc/rexml/context_rdoc.html]. - # - # The evaluation is tested against the element's +expanded_name+, - # and so is namespace-sensitive. - def whitespace - @whitespace = nil - if @context - if @context[:respect_whitespace] - @whitespace = (@context[:respect_whitespace] == :all or - @context[:respect_whitespace].include? expanded_name) - end - @whitespace = false if (@context[:compress_whitespace] and - (@context[:compress_whitespace] == :all or - @context[:compress_whitespace].include? expanded_name) - ) - end - @whitespace = true unless @whitespace == false - @whitespace - end - - # :call-seq: - # ignore_whitespace_nodes - # - # Returns +true+ if whitespace nodes are ignored for the element. - # - # See {Element Context}[../doc/rexml/context_rdoc.html]. - # - def ignore_whitespace_nodes - @ignore_whitespace_nodes = false - if @context - if @context[:ignore_whitespace_nodes] - @ignore_whitespace_nodes = - (@context[:ignore_whitespace_nodes] == :all or - @context[:ignore_whitespace_nodes].include? expanded_name) - end - end - end - - # :call-seq: - # raw - # - # Returns +true+ if raw mode is set for the element. - # - # See {Element Context}[../doc/rexml/context_rdoc.html]. - # - # The evaluation is tested against +expanded_name+, and so is namespace - # sensitive. - def raw - @raw = (@context and @context[:raw] and - (@context[:raw] == :all or - @context[:raw].include? expanded_name)) - @raw - end - - #once :whitespace, :raw, :ignore_whitespace_nodes - - ################################################# - # Namespaces # - ################################################# - - # :call-seq: - # prefixes -> array_of_namespace_prefixes - # - # Returns an array of the string prefixes (names) of all defined namespaces - # in the element and its ancestors: - # - # xml_string = <<-EOT - # - # - # - # - # - # - # EOT - # d = REXML::Document.new(xml_string, {compress_whitespace: :all}) - # d.elements['//a'].prefixes # => ["x", "y"] - # d.elements['//b'].prefixes # => ["x", "y"] - # d.elements['//c'].prefixes # => ["x", "y", "z"] - # - def prefixes - prefixes = [] - prefixes = parent.prefixes if parent - prefixes |= attributes.prefixes - return prefixes - end - - # :call-seq: - # namespaces -> array_of_namespace_names - # - # Returns a hash of all defined namespaces - # in the element and its ancestors: - # - # xml_string = <<-EOT - # - # - # - # - # - # - # EOT - # d = REXML::Document.new(xml_string) - # d.elements['//a'].namespaces # => {"x"=>"1", "y"=>"2"} - # d.elements['//b'].namespaces # => {"x"=>"1", "y"=>"2"} - # d.elements['//c'].namespaces # => {"x"=>"1", "y"=>"2", "z"=>"3"} - # - def namespaces - namespaces = {} - namespaces = parent.namespaces if parent - namespaces = namespaces.merge( attributes.namespaces ) - return namespaces - end - - # :call-seq: - # namespace(prefix = nil) -> string_uri or nil - # - # Returns the string namespace URI for the element, - # possibly deriving from one of its ancestors. - # - # xml_string = <<-EOT - # - # - # - # - # - # - # EOT - # d = REXML::Document.new(xml_string) - # b = d.elements['//b'] - # b.namespace # => "1" - # b.namespace('y') # => "2" - # b.namespace('nosuch') # => nil - # - def namespace(prefix=nil) - if prefix.nil? - prefix = prefix() - end - if prefix == '' - prefix = "xmlns" - else - prefix = "xmlns:#{prefix}" unless prefix[0,5] == 'xmlns' - end - ns = nil - target = self - while ns.nil? and target - ns = target.attributes[prefix] - target = target.parent - end - ns = '' if ns.nil? and prefix == 'xmlns' - return ns - end - - # :call-seq: - # add_namespace(prefix, uri = nil) -> self - # - # Adds a namespace to the element; returns +self+. - # - # With the single argument +prefix+, - # adds a namespace using the given +prefix+ and the namespace URI: - # - # e = REXML::Element.new('foo') - # e.add_namespace('bar') - # e.namespaces # => {"xmlns"=>"bar"} - # - # With both arguments +prefix+ and +uri+ given, - # adds a namespace using both arguments: - # - # e.add_namespace('baz', 'bat') - # e.namespaces # => {"xmlns"=>"bar", "baz"=>"bat"} - # - def add_namespace( prefix, uri=nil ) - unless uri - @attributes["xmlns"] = prefix - else - prefix = "xmlns:#{prefix}" unless prefix =~ /^xmlns:/ - @attributes[ prefix ] = uri - end - self - end - - # :call-seq: - # delete_namespace(namespace = 'xmlns') -> self - # - # Removes a namespace from the element. - # - # With no argument, removes the default namespace: - # - # d = REXML::Document.new "" - # d.to_s # => "" - # d.root.delete_namespace # => - # d.to_s # => "" - # - # With argument +namespace+, removes the specified namespace: - # - # d.root.delete_namespace('foo') - # d.to_s # => "" - # - # Does nothing if no such namespace is found: - # - # d.root.delete_namespace('nosuch') - # d.to_s # => "" - # - def delete_namespace namespace="xmlns" - namespace = "xmlns:#{namespace}" unless namespace == 'xmlns' - attribute = attributes.get_attribute(namespace) - attribute.remove unless attribute.nil? - self - end - - ################################################# - # Elements # - ################################################# - - # :call-seq: - # add_element(name, attributes = nil) -> new_element - # add_element(element, attributes = nil) -> element - # - # Adds a child element, optionally setting attributes - # on the added element; returns the added element. - # - # With string argument +name+, creates a new element with that name - # and adds the new element as a child: - # - # e0 = REXML::Element.new('foo') - # e0.add_element('bar') - # e0[0] # => - # - # - # With argument +name+ and hash argument +attributes+, - # sets attributes on the new element: - # - # e0.add_element('baz', {'bat' => '0', 'bam' => '1'}) - # e0[1] # => - # - # With element argument +element+, adds that element as a child: - # - # e0 = REXML::Element.new('foo') - # e1 = REXML::Element.new('bar') - # e0.add_element(e1) - # e0[0] # => - # - # With argument +element+ and hash argument +attributes+, - # sets attributes on the added element: - # - # e0.add_element(e1, {'bat' => '0', 'bam' => '1'}) - # e0[1] # => - # - def add_element element, attrs=nil - raise "First argument must be either an element name, or an Element object" if element.nil? - el = @elements.add(element) - attrs.each do |key, value| - el.attributes[key]=value - end if attrs.kind_of? Hash - el - end - - # :call-seq: - # delete_element(index) -> removed_element or nil - # delete_element(element) -> removed_element or nil - # delete_element(xpath) -> removed_element or nil - # - # Deletes a child element. - # - # When 1-based integer argument +index+ is given, - # removes and returns the child element at that offset if it exists; - # indexing does not include text nodes; - # returns +nil+ if the element does not exist: - # - # d = REXML::Document.new 'text' - # a = d.root # => ... - # a.delete_element(1) # => - # a.delete_element(1) # => - # a.delete_element(1) # => nil - # - # When element argument +element+ is given, - # removes and returns that child element if it exists, - # otherwise returns +nil+: - # - # d = REXML::Document.new 'text' - # a = d.root # => ... - # c = a[2] # => - # a.delete_element(c) # => - # a.delete_element(c) # => nil - # - # When xpath argument +xpath+ is given, - # removes and returns the element at xpath if it exists, - # otherwise returns +nil+: - # - # d = REXML::Document.new 'text' - # a = d.root # => ... - # a.delete_element('//c') # => - # a.delete_element('//c') # => nil - # - def delete_element element - @elements.delete element - end - - # :call-seq: - # has_elements? - # - # Returns +true+ if the element has one or more element children, - # +false+ otherwise: - # - # d = REXML::Document.new 'text' - # a = d.root # => ... - # a.has_elements? # => true - # b = a[0] # => - # b.has_elements? # => false - # - def has_elements? - !@elements.empty? - end - - # :call-seq: - # each_element_with_attribute(attr_name, value = nil, max = 0, xpath = nil) {|e| ... } - # - # Calls the given block with each child element that meets given criteria. - # - # When only string argument +attr_name+ is given, - # calls the block with each child element that has that attribute: - # - # d = REXML::Document.new '' - # a = d.root - # a.each_element_with_attribute('id') {|e| p e } - # - # Output: - # - # - # - # - # - # With argument +attr_name+ and string argument +value+ given, - # calls the block with each child element that has that attribute - # with that value: - # - # a.each_element_with_attribute('id', '1') {|e| p e } - # - # Output: - # - # - # - # - # With arguments +attr_name+, +value+, and integer argument +max+ given, - # calls the block with at most +max+ child elements: - # - # a.each_element_with_attribute('id', '1', 1) {|e| p e } - # - # Output: - # - # - # - # With all arguments given, including +xpath+, - # calls the block with only those child elements - # that meet the first three criteria, - # and also match the given +xpath+: - # - # a.each_element_with_attribute('id', '1', 2, '//d') {|e| p e } - # - # Output: - # - # - # - def each_element_with_attribute( key, value=nil, max=0, name=nil, &block ) # :yields: Element - each_with_something( proc {|child| - if value.nil? - child.attributes[key] != nil - else - child.attributes[key]==value - end - }, max, name, &block ) - end - - # :call-seq: - # each_element_with_text(text = nil, max = 0, xpath = nil) {|e| ... } - # - # Calls the given block with each child element that meets given criteria. - # - # With no arguments, calls the block with each child element that has text: - # - # d = REXML::Document.new 'bbd' - # a = d.root - # a.each_element_with_text {|e| p e } - # - # Output: - # - # ... - # ... - # ... - # - # With the single string argument +text+, - # calls the block with each element that has exactly that text: - # - # a.each_element_with_text('b') {|e| p e } - # - # Output: - # - # ... - # ... - # - # With argument +text+ and integer argument +max+, - # calls the block with at most +max+ elements: - # - # a.each_element_with_text('b', 1) {|e| p e } - # - # Output: - # - # ... - # - # With all arguments given, including +xpath+, - # calls the block with only those child elements - # that meet the first two criteria, - # and also match the given +xpath+: - # - # a.each_element_with_text('b', 2, '//c') {|e| p e } - # - # Output: - # - # ... - # - def each_element_with_text( text=nil, max=0, name=nil, &block ) # :yields: Element - each_with_something( proc {|child| - if text.nil? - child.has_text? - else - child.text == text - end - }, max, name, &block ) - end - - # :call-seq: - # each_element {|e| ... } - # - # Calls the given block with each child element: - # - # d = REXML::Document.new 'bbd' - # a = d.root - # a.each_element {|e| p e } - # - # Output: - # - # ... - # ... - # ... - # - # - def each_element( xpath=nil, &block ) # :yields: Element - @elements.each( xpath, &block ) - end - - # :call-seq: - # get_elements(xpath) - # - # Returns an array of the elements that match the given +xpath+: - # - # xml_string = <<-EOT - # - # - # - # - # - # EOT - # d = REXML::Document.new(xml_string) - # d.root.get_elements('//a') # => [ ... , ] - # - def get_elements( xpath ) - @elements.to_a( xpath ) - end - - # :call-seq: - # next_element - # - # Returns the next sibling that is an element if it exists, - # +niL+ otherwise: - # - # d = REXML::Document.new 'text' - # d.root.elements['b'].next_element #-> - # d.root.elements['c'].next_element #-> nil - # - def next_element - element = next_sibling - element = element.next_sibling until element.nil? or element.kind_of? Element - return element - end - - # :call-seq: - # previous_element - # - # Returns the previous sibling that is an element if it exists, - # +niL+ otherwise: - # - # d = REXML::Document.new 'text' - # d.root.elements['c'].previous_element #-> - # d.root.elements['b'].previous_element #-> nil - # - def previous_element - element = previous_sibling - element = element.previous_sibling until element.nil? or element.kind_of? Element - return element - end - - - ################################################# - # Text # - ################################################# - - # :call-seq: - # has_text? -> true or false - # - # Returns +true+ if the element has one or more text noded, - # +false+ otherwise: - # - # d = REXML::Document.new 'text' - # a = d.root - # a.has_text? # => true - # b = a[0] - # b.has_text? # => false - # - def has_text? - not text().nil? - end - - # :call-seq: - # text(xpath = nil) -> text_string or nil - # - # Returns the text string from the first text node child - # in a specified element, if it exists, +nil+ otherwise. - # - # With no argument, returns the text from the first text node in +self+: - # - # d = REXML::Document.new "

some text this is bold! more text

" - # d.root.text.class # => String - # d.root.text # => "some text " - # - # With argument +xpath+, returns text from the first text node - # in the element that matches +xpath+: - # - # d.root.text(1) # => "this is bold!" - # - # Note that an element may have multiple text nodes, - # possibly separated by other non-text children, as above. - # Even so, the returned value is the string text from the first such node. - # - # Note also that the text note is retrieved by method get_text, - # and so is always normalized text. - # - def text( path = nil ) - rv = get_text(path) - return rv.value unless rv.nil? - nil - end - - # :call-seq: - # get_text(xpath = nil) -> text_node or nil - # - # Returns the first text node child in a specified element, if it exists, - # +nil+ otherwise. - # - # With no argument, returns the first text node from +self+: - # - # d = REXML::Document.new "

some text this is bold! more text

" - # d.root.get_text.class # => REXML::Text - # d.root.get_text # => "some text " - # - # With argument +xpath+, returns the first text node from the element - # that matches +xpath+: - # - # d.root.get_text(1) # => "this is bold!" - # - def get_text path = nil - rv = nil - if path - element = @elements[ path ] - rv = element.get_text unless element.nil? - else - rv = @children.find { |node| node.kind_of? Text } - end - return rv - end - - # :call-seq: - # text = string -> string - # text = nil -> nil - # - # Adds, replaces, or removes the first text node child in the element. - # - # With string argument +string+, - # creates a new \REXML::Text node containing that string, - # honoring the current settings for whitespace and row, - # then places the node as the first text child in the element; - # returns +string+. - # - # If the element has no text child, the text node is added: - # - # d = REXML::Document.new '' - # d.root.text = 'foo' #-> 'foo' - # - # If the element has a text child, it is replaced: - # - # d.root.text = 'bar' #-> 'bar' - # - # With argument +nil+, removes the first text child: - # - # d.root.text = nil #-> '' - # - def text=( text ) - if text.kind_of? String - text = Text.new( text, whitespace(), nil, raw() ) - elsif !text.nil? and !text.kind_of? Text - text = Text.new( text.to_s, whitespace(), nil, raw() ) - end - old_text = get_text - if text.nil? - old_text.remove unless old_text.nil? - else - if old_text.nil? - self << text - else - old_text.replace_with( text ) - end - end - return self - end - - # :call-seq: - # add_text(string) -> nil - # add_text(text_node) -> self - # - # Adds text to the element. - # - # When string argument +string+ is given, returns +nil+. - # - # If the element has no child text node, - # creates a \REXML::Text object using the string, - # honoring the current settings for whitespace and raw, - # then adds that node to the element: - # - # d = REXML::Document.new('') - # a = d.root - # a.add_text('foo') - # a.to_a # => [, "foo"] - # - # If the element has child text nodes, - # appends the string to the _last_ text node: - # - # d = REXML::Document.new('foobar') - # a = d.root - # a.add_text('baz') - # a.to_a # => ["foo", , "barbaz"] - # a.add_text('baz') - # a.to_a # => ["foo", , "barbazbaz"] - # - # When text node argument +text_node+ is given, - # appends the node as the last text node in the element; - # returns +self+: - # - # d = REXML::Document.new('foobar') - # a = d.root - # a.add_text(REXML::Text.new('baz')) - # a.to_a # => ["foo", , "bar", "baz"] - # a.add_text(REXML::Text.new('baz')) - # a.to_a # => ["foo", , "bar", "baz", "baz"] - # - def add_text( text ) - if text.kind_of? String - if @children[-1].kind_of? Text - @children[-1] << text - return - end - text = Text.new( text, whitespace(), nil, raw() ) - end - self << text unless text.nil? - return self - end - - # :call-seq: - # node_type -> :element - # - # Returns symbol :element: - # - # d = REXML::Document.new('') - # a = d.root # => - # a.node_type # => :element - # - def node_type - :element - end - - # :call-seq: - # xpath -> string_xpath - # - # Returns the string xpath to the element - # relative to the most distant parent: - # - # d = REXML::Document.new('') - # a = d.root # => ... - # b = a[0] # => ... - # c = b[0] # => - # d.xpath # => "" - # a.xpath # => "/a" - # b.xpath # => "/a/b" - # c.xpath # => "/a/b/c" - # - # If there is no parent, returns the expanded name of the element: - # - # e = REXML::Element.new('foo') - # e.xpath # => "foo" - # - def xpath - path_elements = [] - cur = self - path_elements << __to_xpath_helper( self ) - while cur.parent - cur = cur.parent - path_elements << __to_xpath_helper( cur ) - end - return path_elements.reverse.join( "/" ) - end - - ################################################# - # Attributes # - ################################################# - - # :call-seq: - # [index] -> object - # [attr_name] -> attr_value - # [attr_sym] -> attr_value - # - # With integer argument +index+ given, - # returns the child at offset +index+, or +nil+ if none: - # - # d = REXML::Document.new '>textmore
' - # root = d.root - # (0..root.size).each do |index| - # node = root[index] - # p "#{index}: #{node} (#{node.class})" - # end - # - # Output: - # - # "0: (REXML::Element)" - # "1: text (REXML::Text)" - # "2: (REXML::Element)" - # "3: more (REXML::Text)" - # "4: (REXML::Element)" - # "5: (NilClass)" - # - # With string argument +attr_name+ given, - # returns the string value for the given attribute name if it exists, - # otherwise +nil+: - # - # d = REXML::Document.new('') - # root = d.root - # root['attr'] # => "value" - # root['nosuch'] # => nil - # - # With symbol argument +attr_sym+ given, - # returns [attr_sym.to_s]: - # - # root[:attr] # => "value" - # root[:nosuch] # => nil - # - def [](name_or_index) - case name_or_index - when String - attributes[name_or_index] - when Symbol - attributes[name_or_index.to_s] - else - super - end - end - - - # :call-seq: - # attribute(name, namespace = nil) - # - # Returns the string value for the given attribute name. - # - # With only argument +name+ given, - # returns the value of the named attribute if it exists, otherwise +nil+: - # - # xml_string = <<-EOT - # - # - # - # - #
- # EOT - # d = REXML::Document.new(xml_string) - # root = d.root - # a = root[1] # => - # a.attribute('attr') # => attr='value' - # a.attribute('nope') # => nil - # - # With arguments +name+ and +namespace+ given, - # returns the value of the named attribute if it exists, otherwise +nil+: - # - # xml_string = "" - # document = REXML::Document.new(xml_string) - # document.root.attribute("x") # => x='x' - # document.root.attribute("x", "a") # => a:x='a:x' - # - def attribute( name, namespace=nil ) - prefix = namespaces.key(namespace) if namespace - prefix = nil if prefix == 'xmlns' - - ret_val = - attributes.get_attribute( prefix ? "#{prefix}:#{name}" : name ) - - return ret_val unless ret_val.nil? - return nil if prefix.nil? - - # now check that prefix'es namespace is not the same as the - # default namespace - return nil unless ( namespaces[ prefix ] == namespaces[ 'xmlns' ] ) - - attributes.get_attribute( name ) - - end - - # :call-seq: - # has_attributes? -> true or false - # - # Returns +true+ if the element has attributes, +false+ otherwise: - # - # d = REXML::Document.new('') - # a, b = *d.root - # a.has_attributes? # => true - # b.has_attributes? # => false - # - def has_attributes? - return !@attributes.empty? - end - - # :call-seq: - # add_attribute(name, value) -> value - # add_attribute(attribute) -> attribute - # - # Adds an attribute to this element, overwriting any existing attribute - # by the same name. - # - # With string argument +name+ and object +value+ are given, - # adds the attribute created with that name and value: - # - # e = REXML::Element.new - # e.add_attribute('attr', 'value') # => "value" - # e['attr'] # => "value" - # e.add_attribute('attr', 'VALUE') # => "VALUE" - # e['attr'] # => "VALUE" - # - # With only attribute object +attribute+ given, - # adds the given attribute: - # - # a = REXML::Attribute.new('attr', 'value') - # e.add_attribute(a) # => attr='value' - # e['attr'] # => "value" - # a = REXML::Attribute.new('attr', 'VALUE') - # e.add_attribute(a) # => attr='VALUE' - # e['attr'] # => "VALUE" - # - def add_attribute( key, value=nil ) - if key.kind_of? Attribute - @attributes << key - else - @attributes[key] = value - end - end - - # :call-seq: - # add_attributes(hash) -> hash - # add_attributes(array) - # - # Adds zero or more attributes to the element; - # returns the argument. - # - # If hash argument +hash+ is given, - # each key must be a string; - # adds each attribute created with the key/value pair: - # - # e = REXML::Element.new - # h = {'foo' => 'bar', 'baz' => 'bat'} - # e.add_attributes(h) - # - # If argument +array+ is given, - # each array member must be a 2-element array [name, value]; - # each name must be a string: - # - # e = REXML::Element.new - # a = [['foo' => 'bar'], ['baz' => 'bat']] - # e.add_attributes(a) - # - def add_attributes hash - if hash.kind_of? Hash - hash.each_pair {|key, value| @attributes[key] = value } - elsif hash.kind_of? Array - hash.each { |value| @attributes[ value[0] ] = value[1] } - end - end - - # :call-seq: - # delete_attribute(name) -> removed_attribute or nil - # - # Removes a named attribute if it exists; - # returns the removed attribute if found, otherwise +nil+: - # - # e = REXML::Element.new('foo') - # e.add_attribute('bar', 'baz') - # e.delete_attribute('bar') # => - # e.delete_attribute('bar') # => nil - # - def delete_attribute(key) - attr = @attributes.get_attribute(key) - attr.remove unless attr.nil? - end - - ################################################# - # Other Utilities # - ################################################# - - # :call-seq: - # cdatas -> array_of_cdata_children - # - # Returns a frozen array of the REXML::CData children of the element: - # - # xml_string = <<-EOT - # - # - # - # - # EOT - # d = REXML::Document.new(xml_string) - # cds = d.root.cdatas # => ["foo", "bar"] - # cds.frozen? # => true - # cds.map {|cd| cd.class } # => [REXML::CData, REXML::CData] - # - def cdatas - find_all { |child| child.kind_of? CData }.freeze - end - - # :call-seq: - # comments -> array_of_comment_children - # - # Returns a frozen array of the REXML::Comment children of the element: - # - # xml_string = <<-EOT - # - # - # - # - # EOT - # d = REXML::Document.new(xml_string) - # cs = d.root.comments - # cs.frozen? # => true - # cs.map {|c| c.class } # => [REXML::Comment, REXML::Comment] - # cs.map {|c| c.to_s } # => ["foo", "bar"] - # - def comments - find_all { |child| child.kind_of? Comment }.freeze - end - - # :call-seq: - # instructions -> array_of_instruction_children - # - # Returns a frozen array of the REXML::Instruction children of the element: - # - # xml_string = <<-EOT - # - # - # - # - # EOT - # d = REXML::Document.new(xml_string) - # is = d.root.instructions - # is.frozen? # => true - # is.map {|i| i.class } # => [REXML::Instruction, REXML::Instruction] - # is.map {|i| i.to_s } # => ["", ""] - # - def instructions - find_all { |child| child.kind_of? Instruction }.freeze - end - - # :call-seq: - # texts -> array_of_text_children - # - # Returns a frozen array of the REXML::Text children of the element: - # - # xml_string = 'textmore' - # d = REXML::Document.new(xml_string) - # ts = d.root.texts - # ts.frozen? # => true - # ts.map {|t| t.class } # => [REXML::Text, REXML::Text] - # ts.map {|t| t.to_s } # => ["text", "more"] - # - def texts - find_all { |child| child.kind_of? Text }.freeze - end - - # == DEPRECATED - # See REXML::Formatters - # - # Writes out this element, and recursively, all children. - # output:: - # output an object which supports '<< string'; this is where the - # document will be written. - # indent:: - # An integer. If -1, no indenting will be used; otherwise, the - # indentation will be this number of spaces, and children will be - # indented an additional amount. Defaults to -1 - # transitive:: - # If transitive is true and indent is >= 0, then the output will be - # pretty-printed in such a way that the added whitespace does not affect - # the parse tree of the document - # ie_hack:: - # This hack inserts a space before the /> on empty tags to address - # a limitation of Internet Explorer. Defaults to false - # - # out = '' - # doc.write( out ) #-> doc is written to the string 'out' - # doc.write( $stdout ) #-> doc written to the console - def write(output=$stdout, indent=-1, transitive=false, ie_hack=false) - Kernel.warn("#{self.class.name}.write is deprecated. See REXML::Formatters", uplevel: 1) - formatter = if indent > -1 - if transitive - require_relative "formatters/transitive" - REXML::Formatters::Transitive.new( indent, ie_hack ) - else - REXML::Formatters::Pretty.new( indent, ie_hack ) - end - else - REXML::Formatters::Default.new( ie_hack ) - end - formatter.write( self, output ) - end - - - private - def __to_xpath_helper node - rv = node.expanded_name.clone - if node.parent - results = node.parent.find_all {|n| - n.kind_of?(REXML::Element) and n.expanded_name == node.expanded_name - } - if results.length > 1 - idx = results.index( node ) - rv << "[#{idx+1}]" - end - end - rv - end - - # A private helper method - def each_with_something( test, max=0, name=nil ) - num = 0 - @elements.each( name ){ |child| - yield child if test.call(child) and num += 1 - return if max>0 and num == max - } - end - end - - ######################################################################## - # ELEMENTS # - ######################################################################## - - # A class which provides filtering of children for Elements, and - # XPath search support. You are expected to only encounter this class as - # the element.elements object. Therefore, you are - # _not_ expected to instantiate this yourself. - # - # xml_string = <<-EOT - # - # - # - # Everyday Italian - # Giada De Laurentiis - # 2005 - # 30.00 - # - # - # Harry Potter - # J K. Rowling - # 2005 - # 29.99 - # - # - # XQuery Kick Start - # James McGovern - # Per Bothner - # Kurt Cagle - # James Linn - # Vaidyanathan Nagarajan - # 2003 - # 49.99 - # - # - # Learning XML - # Erik T. Ray - # 2003 - # 39.95 - # - # - # EOT - # d = REXML::Document.new(xml_string) - # elements = d.root.elements - # elements # => # ... > - # - class Elements - include Enumerable - # :call-seq: - # new(parent) -> new_elements_object - # - # Returns a new \Elements object with the given +parent+. - # Does _not_ assign parent.elements = self: - # - # d = REXML::Document.new(xml_string) - # eles = REXML::Elements.new(d.root) - # eles # => # ... > - # eles == d.root.elements # => false - # - def initialize parent - @element = parent - end - - # :call-seq: - # parent - # - # Returns the parent element cited in creating the \Elements object. - # This element is also the default starting point for searching - # in the \Elements object. - # - # d = REXML::Document.new(xml_string) - # elements = REXML::Elements.new(d.root) - # elements.parent == d.root # => true - # - def parent - @element - end - - # :call-seq: - # elements[index] -> element or nil - # elements[xpath] -> element or nil - # elements[n, name] -> element or nil - # - # Returns the first \Element object selected by the arguments, - # if any found, or +nil+ if none found. - # - # Notes: - # - The +index+ is 1-based, not 0-based, so that: - # - The first element has index 1 - # - The _nth_ element has index +n+. - # - The selection ignores non-\Element nodes. - # - # When the single argument +index+ is given, - # returns the element given by the index, if any; otherwise, +nil+: - # - # d = REXML::Document.new(xml_string) - # eles = d.root.elements - # eles # => # ... > - # eles[1] # => ... - # eles.size # => 4 - # eles[4] # => ... - # eles[5] # => nil - # - # The node at this index is not an \Element, and so is not returned: - # - # eles = d.root.first.first # => ... </> - # eles.to_a # => ["Everyday Italian"] - # eles[1] # => nil - # - # When the single argument +xpath+ is given, - # returns the first element found via that +xpath+, if any; otherwise, +nil+: - # - # eles = d.root.elements # => #<REXML::Elements @element=<bookstore> ... </>> - # eles['/bookstore'] # => <bookstore> ... </> - # eles['//book'] # => <book category='cooking'> ... </> - # eles['//book [@category="children"]'] # => <book category='children'> ... </> - # eles['/nosuch'] # => nil - # eles['//nosuch'] # => nil - # eles['//book [@category="nosuch"]'] # => nil - # eles['.'] # => <bookstore> ... </> - # eles['..'].class # => REXML::Document - # - # With arguments +n+ and +name+ given, - # returns the _nth_ found element that has the given +name+, - # or +nil+ if there is no such _nth_ element: - # - # eles = d.root.elements # => #<REXML::Elements @element=<bookstore> ... </>> - # eles[1, 'book'] # => <book category='cooking'> ... </> - # eles[4, 'book'] # => <book category='web' cover='paperback'> ... </> - # eles[5, 'book'] # => nil - # - def []( index, name=nil) - if index.kind_of? Integer - raise "index (#{index}) must be >= 1" if index < 1 - name = literalize(name) if name - num = 0 - @element.find { |child| - child.kind_of? Element and - (name.nil? ? true : child.has_name?( name )) and - (num += 1) == index - } - else - return XPath::first( @element, index ) - #{ |element| - # return element if element.kind_of? Element - #} - #return nil - end - end - - # :call-seq: - # elements[] = index, replacement_element -> replacement_element or nil - # - # Replaces or adds an element. - # - # When <tt>eles[index]</tt> exists, replaces it with +replacement_element+ - # and returns +replacement_element+: - # - # d = REXML::Document.new(xml_string) - # eles = d.root.elements # => #<REXML::Elements @element=<bookstore> ... </>> - # eles[1] # => <book category='cooking'> ... </> - # eles[1] = REXML::Element.new('foo') - # eles[1] # => <foo/> - # - # Does nothing (or raises an exception) - # if +replacement_element+ is not an \Element: - # eles[2] # => <book category='web' cover='paperback'> ... </> - # eles[2] = REXML::Text.new('bar') - # eles[2] # => <book category='web' cover='paperback'> ... </> - # - # When <tt>eles[index]</tt> does not exist, - # adds +replacement_element+ to the element and returns - # - # d = REXML::Document.new(xml_string) - # eles = d.root.elements # => #<REXML::Elements @element=<bookstore> ... </>> - # eles.size # => 4 - # eles[50] = REXML::Element.new('foo') # => <foo/> - # eles.size # => 5 - # eles[5] # => <foo/> - # - # Does nothing (or raises an exception) - # if +replacement_element+ is not an \Element: - # - # eles[50] = REXML::Text.new('bar') # => "bar" - # eles.size # => 5 - # - def []=( index, element ) - previous = self[index] - if previous.nil? - @element.add element - else - previous.replace_with element - end - return previous - end - - # :call-seq: - # empty? -> true or false - # - # Returns +true+ if there are no children, +false+ otherwise. - # - # d = REXML::Document.new('') - # d.elements.empty? # => true - # d = REXML::Document.new(xml_string) - # d.elements.empty? # => false - # - def empty? - @element.find{ |child| child.kind_of? Element}.nil? - end - - # :call-seq: - # index(element) - # - # Returns the 1-based index of the given +element+, if found; - # otherwise, returns -1: - # - # d = REXML::Document.new(xml_string) - # elements = d.root.elements - # ele_1, ele_2, ele_3, ele_4 = *elements - # elements.index(ele_4) # => 4 - # elements.delete(ele_3) - # elements.index(ele_4) # => 3 - # elements.index(ele_3) # => -1 - # - def index element - rv = 0 - found = @element.find do |child| - child.kind_of? Element and - (rv += 1) and - child == element - end - return rv if found == element - return -1 - end - - # :call-seq: - # delete(index) -> removed_element or nil - # delete(element) -> removed_element or nil - # delete(xpath) -> removed_element or nil - # - # Removes an element; returns the removed element, or +nil+ if none removed. - # - # With integer argument +index+ given, - # removes the child element at that offset: - # - # d = REXML::Document.new(xml_string) - # elements = d.root.elements - # elements.size # => 4 - # elements[2] # => <book category='children'> ... </> - # elements.delete(2) # => <book category='children'> ... </> - # elements.size # => 3 - # elements[2] # => <book category='web'> ... </> - # elements.delete(50) # => nil - # - # With element argument +element+ given, - # removes that child element: - # - # d = REXML::Document.new(xml_string) - # elements = d.root.elements - # ele_1, ele_2, ele_3, ele_4 = *elements - # elements.size # => 4 - # elements[2] # => <book category='children'> ... </> - # elements.delete(ele_2) # => <book category='children'> ... </> - # elements.size # => 3 - # elements[2] # => <book category='web'> ... </> - # elements.delete(ele_2) # => nil - # - # With string argument +xpath+ given, - # removes the first element found via that xpath: - # - # d = REXML::Document.new(xml_string) - # elements = d.root.elements - # elements.delete('//book') # => <book category='cooking'> ... </> - # elements.delete('//book [@category="children"]') # => <book category='children'> ... </> - # elements.delete('//nosuch') # => nil - # - def delete element - if element.kind_of? Element - @element.delete element - else - el = self[element] - el.remove if el - end - end - - # :call-seq: - # delete_all(xpath) - # - # Removes all elements found via the given +xpath+; - # returns the array of removed elements, if any, else +nil+. - # - # d = REXML::Document.new(xml_string) - # elements = d.root.elements - # elements.size # => 4 - # deleted_elements = elements.delete_all('//book [@category="web"]') - # deleted_elements.size # => 2 - # elements.size # => 2 - # deleted_elements = elements.delete_all('//book') - # deleted_elements.size # => 2 - # elements.size # => 0 - # elements.delete_all('//book') # => [] - # - def delete_all( xpath ) - rv = [] - XPath::each( @element, xpath) {|element| - rv << element if element.kind_of? Element - } - rv.each do |element| - @element.delete element - element.remove - end - return rv - end - - # :call-seq: - # add -> new_element - # add(name) -> new_element - # add(element) -> element - # - # Adds an element; returns the element added. - # - # With no argument, creates and adds a new element. - # The new element has: - # - # - No name. - # - \Parent from the \Elements object. - # - Context from the that parent. - # - # Example: - # - # d = REXML::Document.new(xml_string) - # elements = d.root.elements - # parent = elements.parent # => <bookstore> ... </> - # parent.context = {raw: :all} - # elements.size # => 4 - # new_element = elements.add # => </> - # elements.size # => 5 - # new_element.name # => nil - # new_element.parent # => <bookstore> ... </> - # new_element.context # => {:raw=>:all} - # - # With string argument +name+, creates and adds a new element. - # The new element has: - # - # - Name +name+. - # - \Parent from the \Elements object. - # - Context from the that parent. - # - # Example: - # - # d = REXML::Document.new(xml_string) - # elements = d.root.elements - # parent = elements.parent # => <bookstore> ... </> - # parent.context = {raw: :all} - # elements.size # => 4 - # new_element = elements.add('foo') # => <foo/> - # elements.size # => 5 - # new_element.name # => "foo" - # new_element.parent # => <bookstore> ... </> - # new_element.context # => {:raw=>:all} - # - # With argument +element+, - # creates and adds a clone of the given +element+. - # The new element has name, parent, and context from the given +element+. - # - # d = REXML::Document.new(xml_string) - # elements = d.root.elements - # elements.size # => 4 - # e0 = REXML::Element.new('foo') - # e1 = REXML::Element.new('bar', e0, {raw: :all}) - # element = elements.add(e1) # => <bar/> - # elements.size # => 5 - # element.name # => "bar" - # element.parent # => <bookstore> ... </> - # element.context # => {:raw=>:all} - # - def add element=nil - if element.nil? - Element.new("", self, @element.context) - elsif not element.kind_of?(Element) - Element.new(element, self, @element.context) - else - @element << element - element.context = @element.context - element - end - end - - alias :<< :add - - # :call-seq: - # each(xpath = nil) {|element| ... } -> self - # - # Iterates over the elements. - # - # With no argument, calls the block with each element: - # - # d = REXML::Document.new(xml_string) - # elements = d.root.elements - # elements.each {|element| p element } - # - # Output: - # - # <book category='cooking'> ... </> - # <book category='children'> ... </> - # <book category='web'> ... </> - # <book category='web' cover='paperback'> ... </> - # - # With argument +xpath+, calls the block with each element - # that matches the given +xpath+: - # - # elements.each('//book [@category="web"]') {|element| p element } - # - # Output: - # - # <book category='web'> ... </> - # <book category='web' cover='paperback'> ... </> - # - def each( xpath=nil ) - XPath::each( @element, xpath ) {|e| yield e if e.kind_of? Element } - end - - # :call-seq: - # collect(xpath = nil) {|element| ... } -> array - # - # Iterates over the elements; returns the array of block return values. - # - # With no argument, iterates over all elements: - # - # d = REXML::Document.new(xml_string) - # elements = d.root.elements - # elements.collect {|element| element.size } # => [9, 9, 17, 9] - # - # With argument +xpath+, iterates over elements that match - # the given +xpath+: - # - # xpath = '//book [@category="web"]' - # elements.collect(xpath) {|element| element.size } # => [17, 9] - # - def collect( xpath=nil ) - collection = [] - XPath::each( @element, xpath ) {|e| - collection << yield(e) if e.kind_of?(Element) - } - collection - end - - # :call-seq: - # inject(xpath = nil, initial = nil) -> object - # - # Calls the block with elements; returns the last block return value. - # - # With no argument, iterates over the elements, calling the block - # <tt>elements.size - 1</tt> times. - # - # - The first call passes the first and second elements. - # - The second call passes the first block return value and the third element. - # - The third call passes the second block return value and the fourth element. - # - And so on. - # - # In this example, the block returns the passed element, - # which is then the object argument to the next call: - # - # d = REXML::Document.new(xml_string) - # elements = d.root.elements - # elements.inject do |object, element| - # p [elements.index(object), elements.index(element)] - # element - # end - # - # Output: - # - # [1, 2] - # [2, 3] - # [3, 4] - # - # With the single argument +xpath+, calls the block only with - # elements matching that xpath: - # - # elements.inject('//book [@category="web"]') do |object, element| - # p [elements.index(object), elements.index(element)] - # element - # end - # - # Output: - # - # [3, 4] - # - # With argument +xpath+ given as +nil+ - # and argument +initial+ also given, - # calls the block once for each element. - # - # - The first call passes the +initial+ and the first element. - # - The second call passes the first block return value and the second element. - # - The third call passes the second block return value and the third element. - # - And so on. - # - # In this example, the first object index is <tt>-1</tt> - # - # elements.inject(nil, 'Initial') do |object, element| - # p [elements.index(object), elements.index(element)] - # element - # end - # - # Output: - # - # [-1, 1] - # [1, 2] - # [2, 3] - # [3, 4] - # - # In this form the passed object can be used as an accumulator: - # - # elements.inject(nil, 0) do |total, element| - # total += element.size - # end # => 44 - # - # With both arguments +xpath+ and +initial+ are given, - # calls the block only with elements matching that xpath: - # - # elements.inject('//book [@category="web"]', 0) do |total, element| - # total += element.size - # end # => 26 - # - def inject( xpath=nil, initial=nil ) - first = true - XPath::each( @element, xpath ) {|e| - if (e.kind_of? Element) - if (first and initial == nil) - initial = e - first = false - else - initial = yield( initial, e ) if e.kind_of? Element - end - end - } - initial - end - - # :call-seq: - # size -> integer - # - # Returns the count of \Element children: - # - # d = REXML::Document.new '<a>sean<b/>elliott<b/>russell<b/></a>' - # d.root.elements.size # => 3 # Three elements. - # d.root.size # => 6 # Three elements plus three text nodes.. - # - def size - count = 0 - @element.each {|child| count+=1 if child.kind_of? Element } - count - end - - # :call-seq: - # to_a(xpath = nil) -> array_of_elements - # - # Returns an array of element children (not including non-element children). - # - # With no argument, returns an array of all element children: - # - # d = REXML::Document.new '<a>sean<b/>elliott<c/></a>' - # elements = d.root.elements - # elements.to_a # => [<b/>, <c/>] # Omits non-element children. - # children = d.root.children - # children # => ["sean", <b/>, "elliott", <c/>] # Includes non-element children. - # - # With argument +xpath+, returns an array of element children - # that match the xpath: - # - # elements.to_a('//c') # => [<c/>] - # - def to_a( xpath=nil ) - rv = XPath.match( @element, xpath ) - return rv.find_all{|e| e.kind_of? Element} if xpath - rv - end - - private - # Private helper class. Removes quotes from quoted strings - def literalize name - name = name[1..-2] if name[0] == ?' or name[0] == ?" #' - name - end - end - - ######################################################################## - # ATTRIBUTES # - ######################################################################## - - # A class that defines the set of Attributes of an Element and provides - # operations for accessing elements in that set. - class Attributes < Hash - - # :call-seq: - # new(element) - # - # Creates and returns a new \REXML::Attributes object. - # The element given by argument +element+ is stored, - # but its own attributes are not modified: - # - # ele = REXML::Element.new('foo') - # attrs = REXML::Attributes.new(ele) - # attrs.object_id == ele.attributes.object_id # => false - # - # Other instance methods in class \REXML::Attributes may refer to: - # - # - +element.document+. - # - +element.prefix+. - # - +element.expanded_name+. - # - def initialize element - @element = element - end - - # :call-seq: - # [name] -> attribute_value or nil - # - # Returns the value for the attribute given by +name+, - # if it exists; otherwise +nil+. - # The value returned is the unnormalized attribute value, - # with entities expanded: - # - # xml_string = <<-EOT - # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> - # <ele foo:att='1' bar:att='2' att='<'/> - # </root> - # EOT - # d = REXML::Document.new(xml_string) - # ele = d.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> - # ele.attributes['att'] # => "<" - # ele.attributes['bar:att'] # => "2" - # ele.attributes['nosuch'] # => nil - # - # Related: get_attribute (returns an \Attribute object). - # - def [](name) - attr = get_attribute(name) - return attr.value unless attr.nil? - return nil - end - - # :call-seq: - # to_a -> array_of_attribute_objects - # - # Returns an array of \REXML::Attribute objects representing - # the attributes: - # - # xml_string = <<-EOT - # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> - # <ele foo:att='1' bar:att='2' att='<'/> - # </root> - # EOT - # d = REXML::Document.new(xml_string) - # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> - # attrs = ele.attributes.to_a # => [foo:att='1', bar:att='2', att='<'] - # attrs.first.class # => REXML::Attribute - # - def to_a - enum_for(:each_attribute).to_a - end - - # :call-seq: - # length - # - # Returns the count of attributes: - # - # xml_string = <<-EOT - # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> - # <ele foo:att='1' bar:att='2' att='<'/> - # </root> - # EOT - # d = REXML::Document.new(xml_string) - # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> - # ele.attributes.length # => 3 - # - def length - c = 0 - each_attribute { c+=1 } - c - end - alias :size :length - - # :call-seq: - # each_attribute {|attr| ... } - # - # Calls the given block with each \REXML::Attribute object: - # - # xml_string = <<-EOT - # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> - # <ele foo:att='1' bar:att='2' att='<'/> - # </root> - # EOT - # d = REXML::Document.new(xml_string) - # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> - # ele.attributes.each_attribute do |attr| - # p [attr.class, attr] - # end - # - # Output: - # - # [REXML::Attribute, foo:att='1'] - # [REXML::Attribute, bar:att='2'] - # [REXML::Attribute, att='<'] - # - def each_attribute # :yields: attribute - return to_enum(__method__) unless block_given? - each_value do |val| - if val.kind_of? Attribute - yield val - else - val.each_value { |atr| yield atr } - end - end - end - - # :call-seq: - # each {|expanded_name, value| ... } - # - # Calls the given block with each expanded-name/value pair: - # - # xml_string = <<-EOT - # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> - # <ele foo:att='1' bar:att='2' att='<'/> - # </root> - # EOT - # d = REXML::Document.new(xml_string) - # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> - # ele.attributes.each do |expanded_name, value| - # p [expanded_name, value] - # end - # - # Output: - # - # ["foo:att", "1"] - # ["bar:att", "2"] - # ["att", "<"] - # - def each - return to_enum(__method__) unless block_given? - each_attribute do |attr| - yield [attr.expanded_name, attr.value] - end - end - - # :call-seq: - # get_attribute(name) -> attribute_object or nil - # - # Returns the \REXML::Attribute object for the given +name+: - # - # xml_string = <<-EOT - # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> - # <ele foo:att='1' bar:att='2' att='<'/> - # </root> - # EOT - # d = REXML::Document.new(xml_string) - # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> - # attrs = ele.attributes - # attrs.get_attribute('foo:att') # => foo:att='1' - # attrs.get_attribute('foo:att').class # => REXML::Attribute - # attrs.get_attribute('bar:att') # => bar:att='2' - # attrs.get_attribute('att') # => att='<' - # attrs.get_attribute('nosuch') # => nil - # - def get_attribute( name ) - attr = fetch( name, nil ) - if attr.nil? - return nil if name.nil? - # Look for prefix - name =~ Namespace::NAMESPLIT - prefix, n = $1, $2 - if prefix - attr = fetch( n, nil ) - # check prefix - if attr == nil - elsif attr.kind_of? Attribute - return attr if prefix == attr.prefix - else - attr = attr[ prefix ] - return attr - end - end - element_document = @element.document - if element_document and element_document.doctype - expn = @element.expanded_name - expn = element_document.doctype.name if expn.size == 0 - attr_val = element_document.doctype.attribute_of(expn, name) - return Attribute.new( name, attr_val ) if attr_val - end - return nil - end - if attr.kind_of? Hash - attr = attr[ @element.prefix ] - end - return attr - end - - # :call-seq: - # [name] = value -> value - # - # When +value+ is non-+nil+, - # assigns that to the attribute for the given +name+, - # overwriting the previous value if it exists: - # - # xml_string = <<-EOT - # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> - # <ele foo:att='1' bar:att='2' att='<'/> - # </root> - # EOT - # d = REXML::Document.new(xml_string) - # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> - # attrs = ele.attributes - # attrs['foo:att'] = '2' # => "2" - # attrs['baz:att'] = '3' # => "3" - # - # When +value+ is +nil+, deletes the attribute if it exists: - # - # attrs['baz:att'] = nil - # attrs.include?('baz:att') # => false - # - def []=( name, value ) - if value.nil? # Delete the named attribute - attr = get_attribute(name) - delete attr - return - end - - unless value.kind_of? Attribute - if @element.document and @element.document.doctype - value = Text::normalize( value, @element.document.doctype ) - else - value = Text::normalize( value, nil ) - end - value = Attribute.new(name, value) - end - value.element = @element - old_attr = fetch(value.name, nil) - if old_attr.nil? - store(value.name, value) - elsif old_attr.kind_of? Hash - old_attr[value.prefix] = value - elsif old_attr.prefix != value.prefix - store value.name, {old_attr.prefix => old_attr, - value.prefix => value} - else - store value.name, value - end - return @element - end - - # :call-seq: - # prefixes -> array_of_prefix_strings - # - # Returns an array of prefix strings in the attributes. - # The array does not include the default - # namespace declaration, if one exists. - # - # xml_string = '<a xmlns="foo" xmlns:x="bar" xmlns:y="twee" z="glorp"/>' - # d = REXML::Document.new(xml_string) - # d.root.attributes.prefixes # => ["x", "y"] - # - def prefixes - ns = [] - each_attribute do |attribute| - ns << attribute.name if attribute.prefix == 'xmlns' - end - if @element.document and @element.document.doctype - expn = @element.expanded_name - expn = @element.document.doctype.name if expn.size == 0 - @element.document.doctype.attributes_of(expn).each { - |attribute| - ns << attribute.name if attribute.prefix == 'xmlns' - } - end - ns - end - - # :call-seq: - # namespaces - # - # Returns a hash of name/value pairs for the namespaces: - # - # xml_string = '<a xmlns="foo" xmlns:x="bar" xmlns:y="twee" z="glorp"/>' - # d = REXML::Document.new(xml_string) - # d.root.attributes.namespaces # => {"xmlns"=>"foo", "x"=>"bar", "y"=>"twee"} - # - def namespaces - namespaces = {} - each_attribute do |attribute| - namespaces[attribute.name] = attribute.value if attribute.prefix == 'xmlns' or attribute.name == 'xmlns' - end - if @element.document and @element.document.doctype - expn = @element.expanded_name - expn = @element.document.doctype.name if expn.size == 0 - @element.document.doctype.attributes_of(expn).each { - |attribute| - namespaces[attribute.name] = attribute.value if attribute.prefix == 'xmlns' or attribute.name == 'xmlns' - } - end - namespaces - end - - # :call-seq: - # delete(name) -> element - # delete(attribute) -> element - # - # Removes a specified attribute if it exists; - # returns the attributes' element. - # - # When string argument +name+ is given, - # removes the attribute of that name if it exists: - # - # xml_string = <<-EOT - # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> - # <ele foo:att='1' bar:att='2' att='<'/> - # </root> - # EOT - # d = REXML::Document.new(xml_string) - # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> - # attrs = ele.attributes - # attrs.delete('foo:att') # => <ele bar:att='2' att='<'/> - # attrs.delete('foo:att') # => <ele bar:att='2' att='<'/> - # - # When attribute argument +attribute+ is given, - # removes that attribute if it exists: - # - # attr = REXML::Attribute.new('bar:att', '2') - # attrs.delete(attr) # => <ele att='<'/> # => <ele att='<'/> - # attrs.delete(attr) # => <ele att='<'/> # => <ele/> - # - def delete( attribute ) - name = nil - prefix = nil - if attribute.kind_of? Attribute - name = attribute.name - prefix = attribute.prefix - else - attribute =~ Namespace::NAMESPLIT - prefix, name = $1, $2 - prefix = '' unless prefix - end - old = fetch(name, nil) - if old.kind_of? Hash # the supplied attribute is one of many - old.delete(prefix) - if old.size == 1 - repl = nil - old.each_value{|v| repl = v} - store name, repl - end - elsif old.nil? - return @element - else # the supplied attribute is a top-level one - super(name) - end - @element - end - - # :call-seq: - # add(attribute) -> attribute - # - # Adds attribute +attribute+, replacing the previous - # attribute of the same name if it exists; - # returns +attribute+: - # - # xml_string = <<-EOT - # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> - # <ele foo:att='1' bar:att='2' att='<'/> - # </root> - # EOT - # d = REXML::Document.new(xml_string) - # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> - # attrs = ele.attributes - # attrs # => {"att"=>{"foo"=>foo:att='1', "bar"=>bar:att='2', ""=>att='<'}} - # attrs.add(REXML::Attribute.new('foo:att', '2')) # => foo:att='2' - # attrs.add(REXML::Attribute.new('baz', '3')) # => baz='3' - # attrs.include?('baz') # => true - # - def add( attribute ) - self[attribute.name] = attribute - end - - alias :<< :add - - # :call-seq: - # delete_all(name) -> array_of_removed_attributes - # - # Removes all attributes matching the given +name+; - # returns an array of the removed attributes: - # - # xml_string = <<-EOT - # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> - # <ele foo:att='1' bar:att='2' att='<'/> - # </root> - # EOT - # d = REXML::Document.new(xml_string) - # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> - # attrs = ele.attributes - # attrs.delete_all('att') # => [att='<'] - # - def delete_all( name ) - rv = [] - each_attribute { |attribute| - rv << attribute if attribute.expanded_name == name - } - rv.each{ |attr| attr.remove } - return rv - end - - # :call-seq: - # get_attribute_ns(namespace, name) - # - # Returns the \REXML::Attribute object among the attributes - # that matches the given +namespace+ and +name+: - # - # xml_string = <<-EOT - # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> - # <ele foo:att='1' bar:att='2' att='<'/> - # </root> - # EOT - # d = REXML::Document.new(xml_string) - # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> - # attrs = ele.attributes - # attrs.get_attribute_ns('http://foo', 'att') # => foo:att='1' - # attrs.get_attribute_ns('http://foo', 'nosuch') # => nil - # - def get_attribute_ns(namespace, name) - result = nil - each_attribute() { |attribute| - if name == attribute.name && - namespace == attribute.namespace() && - ( !namespace.empty? || !attribute.fully_expanded_name.index(':') ) - # foo will match xmlns:foo, but only if foo isn't also an attribute - result = attribute if !result or !namespace.empty? or - !attribute.fully_expanded_name.index(':') - end - } - result - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/encoding.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/encoding.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/encoding.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/encoding.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,51 +0,0 @@ -# coding: US-ASCII -# frozen_string_literal: false -module REXML - module Encoding - # ID ---> Encoding name - attr_reader :encoding - def encoding=(encoding) - encoding = encoding.name if encoding.is_a?(Encoding) - if encoding.is_a?(String) - original_encoding = encoding - encoding = find_encoding(encoding) - unless encoding - raise ArgumentError, "Bad encoding name #{original_encoding}" - end - end - return false if defined?(@encoding) and encoding == @encoding - if encoding - @encoding = encoding.upcase - else - @encoding = 'UTF-8' - end - true - end - - def encode(string) - string.encode(@encoding) - end - - def decode(string) - string.encode(::Encoding::UTF_8, @encoding) - end - - private - def find_encoding(name) - case name - when /\Ashift-jis\z/i - return "SHIFT_JIS" - when /\ACP-(\d+)\z/ - name = "CP#{$1}" - when /\AUTF-8\z/i - return name - end - begin - ::Encoding::Converter.search_convpath(name, 'UTF-8') - rescue ::Encoding::ConverterNotFoundError - return nil - end - name - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/entity.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/entity.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/entity.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/entity.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,142 +0,0 @@ -# frozen_string_literal: false -require_relative 'child' -require_relative 'source' -require_relative 'xmltokens' - -module REXML - class Entity < Child - include XMLTokens - PUBIDCHAR = "\x20\x0D\x0Aa-zA-Z0-9\\-()+,./:=?;!*@$_%#" - SYSTEMLITERAL = %Q{((?:"[^"]*")|(?:'[^']*'))} - PUBIDLITERAL = %Q{("[#{PUBIDCHAR}']*"|'[#{PUBIDCHAR}]*')} - EXTERNALID = "(?:(?:(SYSTEM)\\s+#{SYSTEMLITERAL})|(?:(PUBLIC)\\s+#{PUBIDLITERAL}\\s+#{SYSTEMLITERAL}))" - NDATADECL = "\\s+NDATA\\s+#{NAME}" - PEREFERENCE = "%#{NAME};" - PEREFERENCE_RE = /#{PEREFERENCE}/um - ENTITYVALUE = %Q{((?:"(?:[^%&"]|#{PEREFERENCE}|#{REFERENCE})*")|(?:'([^%&']|#{PEREFERENCE}|#{REFERENCE})*'))} - PEDEF = "(?:#{ENTITYVALUE}|#{EXTERNALID})" - ENTITYDEF = "(?:#{ENTITYVALUE}|(?:#{EXTERNALID}(#{NDATADECL})?))" - PEDECL = "<!ENTITY\\s+(%)\\s+#{NAME}\\s+#{PEDEF}\\s*>" - GEDECL = "<!ENTITY\\s+#{NAME}\\s+#{ENTITYDEF}\\s*>" - ENTITYDECL = /\s*(?:#{GEDECL})|(?:#{PEDECL})/um - - attr_reader :name, :external, :ref, :ndata, :pubid, :value - - # Create a new entity. Simple entities can be constructed by passing a - # name, value to the constructor; this creates a generic, plain entity - # reference. For anything more complicated, you have to pass a Source to - # the constructor with the entity definition, or use the accessor methods. - # +WARNING+: There is no validation of entity state except when the entity - # is read from a stream. If you start poking around with the accessors, - # you can easily create a non-conformant Entity. - # - # e = Entity.new( 'amp', '&' ) - def initialize stream, value=nil, parent=nil, reference=false - super(parent) - @ndata = @pubid = @value = @external = nil - if stream.kind_of? Array - @name = stream[1] - if stream[-1] == '%' - @reference = true - stream.pop - else - @reference = false - end - if stream[2] =~ /SYSTEM|PUBLIC/ - @external = stream[2] - if @external == 'SYSTEM' - @ref = stream[3] - @ndata = stream[4] if stream.size == 5 - else - @pubid = stream[3] - @ref = stream[4] - end - else - @value = stream[2] - end - else - @reference = reference - @external = nil - @name = stream - @value = value - end - end - - # Evaluates whether the given string matches an entity definition, - # returning true if so, and false otherwise. - def Entity::matches? string - (ENTITYDECL =~ string) == 0 - end - - # Evaluates to the unnormalized value of this entity; that is, replacing - # &ent; entities. - def unnormalized - document&.record_entity_expansion - - return nil if @value.nil? - - @unnormalized = Text::unnormalize(@value, parent, - entity_expansion_text_limit: document&.entity_expansion_text_limit) - end - - #once :unnormalized - - # Returns the value of this entity unprocessed -- raw. This is the - # normalized value; that is, with all %ent; and &ent; entities intact - def normalized - @value - end - - # Write out a fully formed, correct entity definition (assuming the Entity - # object itself is valid.) - # - # out:: - # An object implementing <TT><<</TT> to which the entity will be - # output - # indent:: - # *DEPRECATED* and ignored - def write out, indent=-1 - out << '<!ENTITY ' - out << '% ' if @reference - out << @name - out << ' ' - if @external - out << @external << ' ' - if @pubid - q = @pubid.include?('"')?"'":'"' - out << q << @pubid << q << ' ' - end - q = @ref.include?('"')?"'":'"' - out << q << @ref << q - out << ' NDATA ' << @ndata if @ndata - else - q = @value.include?('"')?"'":'"' - out << q << @value << q - end - out << '>' - end - - # Returns this entity as a string. See write(). - def to_s - rv = '' - write rv - rv - end - end - - # This is a set of entity constants -- the ones defined in the XML - # specification. These are +gt+, +lt+, +amp+, +quot+ and +apos+. - # CAUTION: these entities does not have parent and document - module EntityConst - # +>+ - GT = Entity.new( 'gt', '>' ) - # +<+ - LT = Entity.new( 'lt', '<' ) - # +&+ - AMP = Entity.new( 'amp', '&' ) - # +"+ - QUOT = Entity.new( 'quot', '"' ) - # +'+ - APOS = Entity.new( 'apos', "'" ) - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/formatters/default.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/formatters/default.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/formatters/default.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/formatters/default.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,116 +0,0 @@ -# frozen_string_literal: false - -module REXML - module Formatters - class Default - # Prints out the XML document with no formatting -- except if ie_hack is - # set. - # - # ie_hack:: - # If set to true, then inserts whitespace before the close of an empty - # tag, so that IE's bad XML parser doesn't choke. - def initialize( ie_hack=false ) - @ie_hack = ie_hack - end - - # Writes the node to some output. - # - # node:: - # The node to write - # output:: - # A class implementing <TT><<</TT>. Pass in an Output object to - # change the output encoding. - def write( node, output ) - case node - - when Document - if node.xml_decl.encoding != 'UTF-8' && !output.kind_of?(Output) - output = Output.new( output, node.xml_decl.encoding ) - end - write_document( node, output ) - - when Element - write_element( node, output ) - - when Declaration, ElementDecl, NotationDecl, ExternalEntity, Entity, - Attribute, AttlistDecl - node.write( output,-1 ) - - when Instruction - write_instruction( node, output ) - - when DocType, XMLDecl - node.write( output ) - - when Comment - write_comment( node, output ) - - when CData - write_cdata( node, output ) - - when Text - write_text( node, output ) - - else - raise Exception.new("XML FORMATTING ERROR") - - end - end - - protected - def write_document( node, output ) - node.children.each { |child| write( child, output ) } - end - - def write_element( node, output ) - output << "<#{node.expanded_name}" - - node.attributes.to_a.map { |a| - Hash === a ? a.values : a - }.flatten.sort_by {|attr| attr.name}.each do |attr| - output << " " - attr.write( output ) - end unless node.attributes.empty? - - if node.children.empty? - output << " " if @ie_hack - output << "/" - else - output << ">" - node.children.each { |child| - write( child, output ) - } - output << "</#{node.expanded_name}" - end - output << ">" - end - - def write_text( node, output ) - output << node.to_s() - end - - def write_comment( node, output ) - output << Comment::START - output << node.to_s - output << Comment::STOP - end - - def write_cdata( node, output ) - output << CData::START - output << node.to_s - output << CData::STOP - end - - def write_instruction( node, output ) - output << Instruction::START - output << node.target - content = node.content - if content - output << ' ' - output << content - end - output << Instruction::STOP - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/formatters/pretty.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/formatters/pretty.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/formatters/pretty.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/formatters/pretty.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,142 +0,0 @@ -# frozen_string_literal: true -require_relative 'default' - -module REXML - module Formatters - # Pretty-prints an XML document. This destroys whitespace in text nodes - # and will insert carriage returns and indentations. - # - # TODO: Add an option to print attributes on new lines - class Pretty < Default - - # If compact is set to true, then the formatter will attempt to use as - # little space as possible - attr_accessor :compact - # The width of a page. Used for formatting text - attr_accessor :width - - # Create a new pretty printer. - # - # output:: - # An object implementing '<<(String)', to which the output will be written. - # indentation:: - # An integer greater than 0. The indentation of each level will be - # this number of spaces. If this is < 1, the behavior of this object - # is undefined. Defaults to 2. - # ie_hack:: - # If true, the printer will insert whitespace before closing empty - # tags, thereby allowing Internet Explorer's XML parser to - # function. Defaults to false. - def initialize( indentation=2, ie_hack=false ) - @indentation = indentation - @level = 0 - @ie_hack = ie_hack - @width = 80 - @compact = false - end - - protected - def write_element(node, output) - output << ' '*@level - output << "<#{node.expanded_name}" - - node.attributes.each_attribute do |attr| - output << " " - attr.write( output ) - end unless node.attributes.empty? - - if node.children.empty? - if @ie_hack - output << " " - end - output << "/" - else - output << ">" - # If compact and all children are text, and if the formatted output - # is less than the specified width, then try to print everything on - # one line - skip = false - if compact - if node.children.inject(true) {|s,c| s & c.kind_of?(Text)} - string = +"" - old_level = @level - @level = 0 - node.children.each { |child| write( child, string ) } - @level = old_level - if string.length < @width - output << string - skip = true - end - end - end - unless skip - output << "\n" - @level += @indentation - node.children.each { |child| - next if child.kind_of?(Text) and child.to_s.strip.length == 0 - write( child, output ) - output << "\n" - } - @level -= @indentation - output << ' '*@level - end - output << "</#{node.expanded_name}" - end - output << ">" - end - - def write_text( node, output ) - s = node.to_s() - s.gsub!(/\s/,' ') - s.squeeze!(" ") - s = wrap(s, @width - @level) - s = indent_text(s, @level, " ", true) - output << (' '*@level + s) - end - - def write_comment( node, output) - output << ' ' * @level - super - end - - def write_cdata( node, output) - output << ' ' * @level - super - end - - def write_document( node, output ) - # Ok, this is a bit odd. All XML documents have an XML declaration, - # but it may not write itself if the user didn't specifically add it, - # either through the API or in the input document. If it doesn't write - # itself, then we don't need a carriage return... which makes this - # logic more complex. - node.children.each { |child| - next if child.instance_of?(Text) - unless child == node.children[0] or child.instance_of?(Text) or - (child == node.children[1] and !node.children[0].writethis) - output << "\n" - end - write( child, output ) - } - end - - private - def indent_text(string, level=1, style="\t", indentfirstline=true) - return string if level < 0 - string.gsub(/\n/, "\n#{style*level}") - end - - def wrap(string, width) - parts = [] - while string.length > width and place = string.rindex(' ', width) - parts << string[0...place] - string = string[place+1..-1] - end - parts << string - parts.join("\n") - end - - end - end -end - diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/formatters/transitive.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/formatters/transitive.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/formatters/transitive.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/formatters/transitive.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,58 +0,0 @@ -# frozen_string_literal: false -require_relative 'pretty' - -module REXML - module Formatters - # The Transitive formatter writes an XML document that parses to an - # identical document as the source document. This means that no extra - # whitespace nodes are inserted, and whitespace within text nodes is - # preserved. Within these constraints, the document is pretty-printed, - # with whitespace inserted into the metadata to introduce formatting. - # - # Note that this is only useful if the original XML is not already - # formatted. Since this formatter does not alter whitespace nodes, the - # results of formatting already formatted XML will be odd. - class Transitive < Default - def initialize( indentation=2, ie_hack=false ) - @indentation = indentation - @level = 0 - @ie_hack = ie_hack - end - - protected - def write_element( node, output ) - output << "<#{node.expanded_name}" - - node.attributes.each_attribute do |attr| - output << " " - attr.write( output ) - end unless node.attributes.empty? - - output << "\n" - output << ' '*@level - if node.children.empty? - output << " " if @ie_hack - output << "/" - else - output << ">" - # If compact and all children are text, and if the formatted output - # is less than the specified width, then try to print everything on - # one line - @level += @indentation - node.children.each { |child| - write( child, output ) - } - @level -= @indentation - output << "</#{node.expanded_name}" - output << "\n" - output << ' '*@level - end - output << ">" - end - - def write_text( node, output ) - output << node.to_s() - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/functions.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/functions.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/functions.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/functions.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,446 +0,0 @@ -# frozen_string_literal: false -module REXML - # If you add a method, keep in mind two things: - # (1) the first argument will always be a list of nodes from which to - # filter. In the case of context methods (such as position), the function - # should return an array with a value for each child in the array. - # (2) all method calls from XML will have "-" replaced with "_". - # Therefore, in XML, "local-name()" is identical (and actually becomes) - # "local_name()" - module Functions - @@available_functions = {} - @@context = nil - @@namespace_context = {} - @@variables = {} - - INTERNAL_METHODS = [ - :namespace_context, - :namespace_context=, - :variables, - :variables=, - :context=, - :get_namespace, - :send, - ] - class << self - def singleton_method_added(name) - unless INTERNAL_METHODS.include?(name) - @@available_functions[name] = true - end - end - end - - def Functions::namespace_context=(x) ; @@namespace_context=x ; end - def Functions::variables=(x) ; @@variables=x ; end - def Functions::namespace_context ; @@namespace_context ; end - def Functions::variables ; @@variables ; end - - def Functions::context=(value); @@context = value; end - - def Functions::text( ) - if @@context[:node].node_type == :element - return @@context[:node].find_all{|n| n.node_type == :text}.collect{|n| n.value} - elsif @@context[:node].node_type == :text - return @@context[:node].value - else - return false - end - end - - # Returns the last node of the given list of nodes. - def Functions::last( ) - @@context[:size] - end - - def Functions::position( ) - @@context[:index] - end - - # Returns the size of the given list of nodes. - def Functions::count( node_set ) - node_set.size - end - - # Since REXML is non-validating, this method is not implemented as it - # requires a DTD - def Functions::id( object ) - end - - def Functions::local_name(node_set=nil) - get_namespace(node_set) do |node| - return node.local_name - end - "" - end - - def Functions::namespace_uri( node_set=nil ) - get_namespace( node_set ) {|node| node.namespace} - end - - def Functions::name( node_set=nil ) - get_namespace( node_set ) do |node| - node.expanded_name - end - end - - # Helper method. - def Functions::get_namespace( node_set = nil ) - if node_set == nil - yield @@context[:node] if @@context[:node].respond_to?(:namespace) - else - if node_set.respond_to? :each - result = [] - node_set.each do |node| - result << yield(node) if node.respond_to?(:namespace) - end - result - elsif node_set.respond_to? :namespace - yield node_set - end - end - end - - # A node-set is converted to a string by returning the string-value of the - # node in the node-set that is first in document order. If the node-set is - # empty, an empty string is returned. - # - # A number is converted to a string as follows - # - # NaN is converted to the string NaN - # - # positive zero is converted to the string 0 - # - # negative zero is converted to the string 0 - # - # positive infinity is converted to the string Infinity - # - # negative infinity is converted to the string -Infinity - # - # if the number is an integer, the number is represented in decimal form - # as a Number with no decimal point and no leading zeros, preceded by a - # minus sign (-) if the number is negative - # - # otherwise, the number is represented in decimal form as a Number - # including a decimal point with at least one digit before the decimal - # point and at least one digit after the decimal point, preceded by a - # minus sign (-) if the number is negative; there must be no leading zeros - # before the decimal point apart possibly from the one required digit - # immediately before the decimal point; beyond the one required digit - # after the decimal point there must be as many, but only as many, more - # digits as are needed to uniquely distinguish the number from all other - # IEEE 754 numeric values. - # - # The boolean false value is converted to the string false. The boolean - # true value is converted to the string true. - # - # An object of a type other than the four basic types is converted to a - # string in a way that is dependent on that type. - def Functions::string( object=@@context[:node] ) - if object.respond_to?(:node_type) - case object.node_type - when :attribute - object.value - when :element - string_value(object) - when :document - string_value(object.root) - when :processing_instruction - object.content - else - object.to_s - end - else - case object - when Array - string(object[0]) - when Float - if object.nan? - "NaN" - else - integer = object.to_i - if object == integer - "%d" % integer - else - object.to_s - end - end - else - object.to_s - end - end - end - - # A node-set is converted to a string by - # returning the concatenation of the string-value - # of each of the children of the node in the - # node-set that is first in document order. - # If the node-set is empty, an empty string is returned. - def Functions::string_value( o ) - rv = "" - o.children.each { |e| - if e.node_type == :text - rv << e.to_s - elsif e.node_type == :element - rv << string_value( e ) - end - } - rv - end - - def Functions::concat( *objects ) - concatenated = "" - objects.each do |object| - concatenated << string(object) - end - concatenated - end - - # Fixed by Mike Stok - def Functions::starts_with( string, test ) - string(string).index(string(test)) == 0 - end - - # Fixed by Mike Stok - def Functions::contains( string, test ) - string(string).include?(string(test)) - end - - # Kouhei fixed this - def Functions::substring_before( string, test ) - ruby_string = string(string) - ruby_index = ruby_string.index(string(test)) - if ruby_index.nil? - "" - else - ruby_string[ 0...ruby_index ] - end - end - - # Kouhei fixed this too - def Functions::substring_after( string, test ) - ruby_string = string(string) - return $1 if ruby_string =~ /#{test}(.*)/ - "" - end - - # Take equal portions of Mike Stok and Sean Russell; mix - # vigorously, and pour into a tall, chilled glass. Serves 10,000. - def Functions::substring( string, start, length=nil ) - ruby_string = string(string) - ruby_length = if length.nil? - ruby_string.length.to_f - else - number(length) - end - ruby_start = number(start) - - # Handle the special cases - return '' if ( - ruby_length.nan? or - ruby_start.nan? or - ruby_start.infinite? - ) - - infinite_length = ruby_length.infinite? == 1 - ruby_length = ruby_string.length if infinite_length - - # Now, get the bounds. The XPath bounds are 1..length; the ruby bounds - # are 0..length. Therefore, we have to offset the bounds by one. - ruby_start = round(ruby_start) - 1 - ruby_length = round(ruby_length) - - if ruby_start < 0 - ruby_length += ruby_start unless infinite_length - ruby_start = 0 - end - return '' if ruby_length <= 0 - ruby_string[ruby_start,ruby_length] - end - - # UNTESTED - def Functions::string_length( string ) - string(string).length - end - - def Functions::normalize_space( string=nil ) - string = string(@@context[:node]) if string.nil? - if string.kind_of? Array - string.collect{|x| x.to_s.strip.gsub(/\s+/um, ' ') if x} - else - string.to_s.strip.gsub(/\s+/um, ' ') - end - end - - # This is entirely Mike Stok's beast - def Functions::translate( string, tr1, tr2 ) - from = string(tr1) - to = string(tr2) - - # the map is our translation table. - # - # if a character occurs more than once in the - # from string then we ignore the second & - # subsequent mappings - # - # if a character maps to nil then we delete it - # in the output. This happens if the from - # string is longer than the to string - # - # there's nothing about - or ^ being special in - # http://www.w3.org/TR/xpath#function-translate - # so we don't build ranges or negated classes - - map = Hash.new - 0.upto(from.length - 1) { |pos| - from_char = from[pos] - unless map.has_key? from_char - map[from_char] = - if pos < to.length - to[pos] - else - nil - end - end - } - - if ''.respond_to? :chars - string(string).chars.collect { |c| - if map.has_key? c then map[c] else c end - }.compact.join - else - string(string).unpack('U*').collect { |c| - if map.has_key? c then map[c] else c end - }.compact.pack('U*') - end - end - - def Functions::boolean(object=@@context[:node]) - case object - when true, false - object - when Float - return false if object.zero? - return false if object.nan? - true - when Numeric - not object.zero? - when String - not object.empty? - when Array - not object.empty? - else - object ? true : false - end - end - - # UNTESTED - def Functions::not( object ) - not boolean( object ) - end - - # UNTESTED - def Functions::true( ) - true - end - - # UNTESTED - def Functions::false( ) - false - end - - # UNTESTED - def Functions::lang( language ) - lang = false - node = @@context[:node] - attr = nil - until node.nil? - if node.node_type == :element - attr = node.attributes["xml:lang"] - unless attr.nil? - lang = compare_language(string(language), attr) - break - else - end - end - node = node.parent - end - lang - end - - def Functions::compare_language lang1, lang2 - lang2.downcase.index(lang1.downcase) == 0 - end - - # a string that consists of optional whitespace followed by an optional - # minus sign followed by a Number followed by whitespace is converted to - # the IEEE 754 number that is nearest (according to the IEEE 754 - # round-to-nearest rule) to the mathematical value represented by the - # string; any other string is converted to NaN - # - # boolean true is converted to 1; boolean false is converted to 0 - # - # a node-set is first converted to a string as if by a call to the string - # function and then converted in the same way as a string argument - # - # an object of a type other than the four basic types is converted to a - # number in a way that is dependent on that type - def Functions::number(object=@@context[:node]) - case object - when true - Float(1) - when false - Float(0) - when Array - number(string(object)) - when Numeric - object.to_f - else - str = string(object) - case str.strip - when /\A\s*(-?(?:\d+(?:\.\d*)?|\.\d+))\s*\z/ - $1.to_f - else - Float::NAN - end - end - end - - def Functions::sum( nodes ) - nodes = [nodes] unless nodes.kind_of? Array - nodes.inject(0) { |r,n| r + number(string(n)) } - end - - def Functions::floor( number ) - number(number).floor - end - - def Functions::ceiling( number ) - number(number).ceil - end - - def Functions::round( number ) - number = number(number) - begin - neg = number.negative? - number = number.abs.round - neg ? -number : number - rescue FloatDomainError - number - end - end - - def Functions::processing_instruction( node ) - node.node_type == :processing_instruction - end - - def Functions::send(name, *args) - if @@available_functions[name.to_sym] - super - else - # TODO: Maybe, this is not XPath spec behavior. - # This behavior must be reconsidered. - XPath.match(@@context[:node], name.to_s) - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/instruction.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/instruction.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/instruction.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/instruction.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,79 +0,0 @@ -# frozen_string_literal: false - -require_relative "child" -require_relative "source" - -module REXML - # Represents an XML Instruction; IE, <? ... ?> - # TODO: Add parent arg (3rd arg) to constructor - class Instruction < Child - START = "<?" - STOP = "?>" - - # target is the "name" of the Instruction; IE, the "tag" in <?tag ...?> - # content is everything else. - attr_accessor :target, :content - - # Constructs a new Instruction - # @param target can be one of a number of things. If String, then - # the target of this instruction is set to this. If an Instruction, - # then the Instruction is shallowly cloned (target and content are - # copied). - # @param content Must be either a String, or a Parent. Can only - # be a Parent if the target argument is a Source. Otherwise, this - # String is set as the content of this instruction. - def initialize(target, content=nil) - case target - when String - super() - @target = target - @content = content - when Instruction - super(content) - @target = target.target - @content = target.content - else - message = - "processing instruction target must be String or REXML::Instruction: " - message << "<#{target.inspect}>" - raise ArgumentError, message - end - @content.strip! if @content - end - - def clone - Instruction.new self - end - - # == DEPRECATED - # See the rexml/formatters package - # - def write writer, indent=-1, transitive=false, ie_hack=false - Kernel.warn( "#{self.class.name}.write is deprecated", uplevel: 1) - indent(writer, indent) - writer << START - writer << @target - if @content - writer << ' ' - writer << @content - end - writer << STOP - end - - # @return true if other is an Instruction, and the content and target - # of the other matches the target and content of this object. - def ==( other ) - other.kind_of? Instruction and - other.target == @target and - other.content == @content - end - - def node_type - :processing_instruction - end - - def inspect - "<?p-i #{target} ...?>" - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/light/node.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/light/node.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/light/node.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/light/node.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,188 +0,0 @@ -# frozen_string_literal: false -require_relative '../xmltokens' - -module REXML - module Light - # Represents a tagged XML element. Elements are characterized by - # having children, attributes, and names, and can themselves be - # children. - class Node - NAMESPLIT = /^(?:(#{XMLTokens::NCNAME_STR}):)?(#{XMLTokens::NCNAME_STR})/u - PARENTS = [ :element, :document, :doctype ] - # Create a new element. - def initialize node=nil - @node = node - if node.kind_of? String - node = [ :text, node ] - elsif node.nil? - node = [ :document, nil, nil ] - elsif node[0] == :start_element - node[0] = :element - elsif node[0] == :start_doctype - node[0] = :doctype - elsif node[0] == :start_document - node[0] = :document - end - end - - def size - if PARENTS.include? @node[0] - @node[-1].size - else - 0 - end - end - - def each - size.times { |x| yield( at(x+4) ) } - end - - def name - at(2) - end - - def name=( name_str, ns=nil ) - pfx = '' - pfx = "#{prefix(ns)}:" if ns - _old_put(2, "#{pfx}#{name_str}") - end - - def parent=( node ) - _old_put(1,node) - end - - def local_name - namesplit - @name - end - - def local_name=( name_str ) - _old_put( 1, "#@prefix:#{name_str}" ) - end - - def prefix( namespace=nil ) - prefix_of( self, namespace ) - end - - def namespace( prefix=prefix() ) - namespace_of( self, prefix ) - end - - def namespace=( namespace ) - @prefix = prefix( namespace ) - pfx = '' - pfx = "#@prefix:" if @prefix.size > 0 - _old_put(1, "#{pfx}#@name") - end - - def []( reference, ns=nil ) - if reference.kind_of? String - pfx = '' - pfx = "#{prefix(ns)}:" if ns - at(3)["#{pfx}#{reference}"] - elsif reference.kind_of? Range - _old_get( Range.new(4+reference.begin, reference.end, reference.exclude_end?) ) - else - _old_get( 4+reference ) - end - end - - def =~( path ) - XPath.match( self, path ) - end - - # Doesn't handle namespaces yet - def []=( reference, ns, value=nil ) - if reference.kind_of? String - value = ns unless value - at( 3 )[reference] = value - elsif reference.kind_of? Range - _old_put( Range.new(3+reference.begin, reference.end, reference.exclude_end?), ns ) - else - if value - _old_put( 4+reference, ns, value ) - else - _old_put( 4+reference, ns ) - end - end - end - - # Append a child to this element, optionally under a provided namespace. - # The namespace argument is ignored if the element argument is an Element - # object. Otherwise, the element argument is a string, the namespace (if - # provided) is the namespace the element is created in. - def << element - if node_type() == :text - at(-1) << element - else - newnode = Node.new( element ) - newnode.parent = self - self.push( newnode ) - end - at(-1) - end - - def node_type - _old_get(0) - end - - def text=( foo ) - replace = at(4).kind_of?(String)? 1 : 0 - self._old_put(4,replace, normalizefoo) - end - - def root - context = self - context = context.at(1) while context.at(1) - end - - def has_name?( name, namespace = '' ) - at(3) == name and namespace() == namespace - end - - def children - self - end - - def parent - at(1) - end - - def to_s - - end - - private - - def namesplit - return if @name.defined? - at(2) =~ NAMESPLIT - @prefix = '' || $1 - @name = $2 - end - - def namespace_of( node, prefix=nil ) - if not prefix - name = at(2) - name =~ NAMESPLIT - prefix = $1 - end - to_find = 'xmlns' - to_find = "xmlns:#{prefix}" if not prefix.nil? - ns = at(3)[ to_find ] - ns ? ns : namespace_of( @node[0], prefix ) - end - - def prefix_of( node, namespace=nil ) - if not namespace - name = node.name - name =~ NAMESPLIT - $1 - else - ns = at(3).find { |k,v| v == namespace } - ns ? ns : prefix_of( node.parent, namespace ) - end - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/namespace.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/namespace.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/namespace.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/namespace.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,63 +0,0 @@ -# frozen_string_literal: true - -require_relative 'xmltokens' - -module REXML - # Adds named attributes to an object. - module Namespace - # The name of the object, valid if set - attr_reader :name, :expanded_name - # The expanded name of the object, valid if name is set - attr_accessor :prefix - include XMLTokens - NAME_WITHOUT_NAMESPACE = /\A#{NCNAME_STR}\z/ - NAMESPLIT = /^(?:(#{NCNAME_STR}):)?(#{NCNAME_STR})/u - - # Sets the name and the expanded name - def name=( name ) - @expanded_name = name - if name.match?(NAME_WITHOUT_NAMESPACE) - @prefix = "" - @namespace = "" - @name = name - elsif name =~ NAMESPLIT - if $1 - @prefix = $1 - else - @prefix = "" - @namespace = "" - end - @name = $2 - elsif name == "" - @prefix = nil - @namespace = nil - @name = nil - else - message = "name must be \#{PREFIX}:\#{LOCAL_NAME} or \#{LOCAL_NAME}: " - message += "<#{name.inspect}>" - raise ArgumentError, message - end - end - - # Compares names optionally WITH namespaces - def has_name?( other, ns=nil ) - if ns - return (namespace() == ns and name() == other) - elsif other.include? ":" - return fully_expanded_name == other - else - return name == other - end - end - - alias :local_name :name - - # Fully expand the name, even if the prefix wasn't specified in the - # source file. - def fully_expanded_name - ns = prefix - return "#{ns}:#@name" if ns.size > 0 - return @name - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/node.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/node.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/node.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/node.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,80 +0,0 @@ -# frozen_string_literal: false -require_relative "parseexception" -require_relative "formatters/pretty" -require_relative "formatters/default" - -module REXML - # Represents a node in the tree. Nodes are never encountered except as - # superclasses of other objects. Nodes have siblings. - module Node - # @return the next sibling (nil if unset) - def next_sibling_node - return nil if @parent.nil? - @parent[ @parent.index(self) + 1 ] - end - - # @return the previous sibling (nil if unset) - def previous_sibling_node - return nil if @parent.nil? - ind = @parent.index(self) - return nil if ind == 0 - @parent[ ind - 1 ] - end - - # indent:: - # *DEPRECATED* This parameter is now ignored. See the formatters in the - # REXML::Formatters package for changing the output style. - def to_s indent=nil - unless indent.nil? - Kernel.warn( "#{self.class.name}.to_s(indent) parameter is deprecated", uplevel: 1) - f = REXML::Formatters::Pretty.new( indent ) - f.write( self, rv = "" ) - else - f = REXML::Formatters::Default.new - f.write( self, rv = "" ) - end - return rv - end - - def indent to, ind - if @parent and @parent.context and not @parent.context[:indentstyle].nil? then - indentstyle = @parent.context[:indentstyle] - else - indentstyle = ' ' - end - to << indentstyle*ind unless ind<1 - end - - def parent? - false; - end - - - # Visit all subnodes of +self+ recursively - def each_recursive(&block) # :yields: node - stack = [] - each { |child| stack.unshift child if child.node_type == :element } - until stack.empty? - child = stack.pop - yield child - n = stack.size - child.each { |grandchild| stack.insert n, grandchild if grandchild.node_type == :element } - end - end - - # Find (and return) first subnode (recursively) for which the block - # evaluates to true. Returns +nil+ if none was found. - def find_first_recursive(&block) # :yields: node - each_recursive {|node| - return node if block.call(node) - } - return nil - end - - # Returns the position that +self+ holds in its parent's array, indexed - # from 1. - def index_in_parent - parent.index(self)+1 - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/output.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/output.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/output.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/output.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,30 +0,0 @@ -# frozen_string_literal: false -require_relative 'encoding' - -module REXML - class Output - include Encoding - - attr_reader :encoding - - def initialize real_IO, encd="iso-8859-1" - @output = real_IO - self.encoding = encd - - @to_utf = encoding != 'UTF-8' - - if encoding == "UTF-16" - @output << "\ufeff".encode("UTF-16BE") - self.encoding = "UTF-16BE" - end - end - - def <<( content ) - @output << (@to_utf ? self.encode(content) : content) - end - - def to_s - "Output[#{encoding}]" - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parent.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parent.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parent.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parent.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,166 +0,0 @@ -# frozen_string_literal: false -require_relative "child" - -module REXML - # A parent has children, and has methods for accessing them. The Parent - # class is never encountered except as the superclass for some other - # object. - class Parent < Child - include Enumerable - - # Constructor - # @param parent if supplied, will be set as the parent of this object - def initialize parent=nil - super(parent) - @children = [] - end - - def add( object ) - object.parent = self - @children << object - object - end - - alias :push :add - alias :<< :push - - def unshift( object ) - object.parent = self - @children.unshift object - end - - def delete( object ) - found = false - @children.delete_if {|c| c.equal?(object) and found = true } - object.parent = nil if found - found ? object : nil - end - - def each(&block) - @children.each(&block) - end - - def delete_if( &block ) - @children.delete_if(&block) - end - - def delete_at( index ) - @children.delete_at index - end - - def each_index( &block ) - @children.each_index(&block) - end - - # Fetches a child at a given index - # @param index the Integer index of the child to fetch - def []( index ) - @children[index] - end - - alias :each_child :each - - - - # Set an index entry. See Array.[]= - # @param index the index of the element to set - # @param opt either the object to set, or an Integer length - # @param child if opt is an Integer, this is the child to set - # @return the parent (self) - def []=( *args ) - args[-1].parent = self - @children[*args[0..-2]] = args[-1] - end - - # Inserts an child before another child - # @param child1 this is either an xpath or an Element. If an Element, - # child2 will be inserted before child1 in the child list of the parent. - # If an xpath, child2 will be inserted before the first child to match - # the xpath. - # @param child2 the child to insert - # @return the parent (self) - def insert_before( child1, child2 ) - if child1.kind_of? String - child1 = XPath.first( self, child1 ) - child1.parent.insert_before child1, child2 - else - ind = index(child1) - child2.parent.delete(child2) if child2.parent - @children[ind,0] = child2 - child2.parent = self - end - self - end - - # Inserts an child after another child - # @param child1 this is either an xpath or an Element. If an Element, - # child2 will be inserted after child1 in the child list of the parent. - # If an xpath, child2 will be inserted after the first child to match - # the xpath. - # @param child2 the child to insert - # @return the parent (self) - def insert_after( child1, child2 ) - if child1.kind_of? String - child1 = XPath.first( self, child1 ) - child1.parent.insert_after child1, child2 - else - ind = index(child1)+1 - child2.parent.delete(child2) if child2.parent - @children[ind,0] = child2 - child2.parent = self - end - self - end - - def to_a - @children.dup - end - - # Fetches the index of a given child - # @param child the child to get the index of - # @return the index of the child, or nil if the object is not a child - # of this parent. - def index( child ) - count = -1 - @children.find { |i| count += 1 ; i.hash == child.hash } - count - end - - # @return the number of children of this parent - def size - @children.size - end - - alias :length :size - - # Replaces one child with another, making sure the nodelist is correct - # @param to_replace the child to replace (must be a Child) - # @param replacement the child to insert into the nodelist (must be a - # Child) - def replace_child( to_replace, replacement ) - @children.map! {|c| c.equal?( to_replace ) ? replacement : c } - to_replace.parent = nil - replacement.parent = self - end - - # Deeply clones this object. This creates a complete duplicate of this - # Parent, including all descendants. - def deep_clone - cl = clone() - each do |child| - if child.kind_of? Parent - cl << child.deep_clone - else - cl << child.clone - end - end - cl - end - - alias :children :to_a - - def parent? - true - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parseexception.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parseexception.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parseexception.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parseexception.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,53 +0,0 @@ -# frozen_string_literal: false -module REXML - class ParseException < RuntimeError - attr_accessor :source, :parser, :continued_exception - - def initialize( message, source=nil, parser=nil, exception=nil ) - super(message) - @source = source - @parser = parser - @continued_exception = exception - end - - def to_s - # Quote the original exception, if there was one - if @continued_exception - err = @continued_exception.inspect - err << "\n" - err << @continued_exception.backtrace.join("\n") - err << "\n...\n" - else - err = "" - end - - # Get the stack trace and error message - err << super - - # Add contextual information - if @source - err << "\nLine: #{line}\n" - err << "Position: #{position}\n" - err << "Last 80 unconsumed characters:\n" - err.force_encoding("ASCII-8BIT") - err << @source.buffer[0..80].force_encoding("ASCII-8BIT").gsub(/\n/, ' ') - end - - err - end - - def position - @source.current_line[0] if @source and defined? @source.current_line and - @source.current_line - end - - def line - @source.current_line[2] if @source and defined? @source.current_line and - @source.current_line - end - - def context - @source.current_line - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/baseparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/baseparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/baseparser.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/baseparser.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,862 +0,0 @@ -# frozen_string_literal: true -require_relative '../parseexception' -require_relative '../undefinednamespaceexception' -require_relative '../security' -require_relative '../source' -require 'set' -require "strscan" - -module REXML - module Parsers - unless [].respond_to?(:tally) - module EnumerableTally - refine Enumerable do - def tally - counts = {} - each do |item| - counts[item] ||= 0 - counts[item] += 1 - end - counts - end - end - end - using EnumerableTally - end - - if StringScanner::Version < "3.0.8" - module StringScannerCaptures - refine StringScanner do - def captures - values_at(*(1...size)) - end - end - end - using StringScannerCaptures - end - - # = Using the Pull Parser - # <em>This API is experimental, and subject to change.</em> - # parser = PullParser.new( "<a>text<b att='val'/>txet</a>" ) - # while parser.has_next? - # res = parser.next - # puts res[1]['att'] if res.start_tag? and res[0] == 'b' - # end - # See the PullEvent class for information on the content of the results. - # The data is identical to the arguments passed for the various events to - # the StreamListener API. - # - # Notice that: - # parser = PullParser.new( "<a>BAD DOCUMENT" ) - # while parser.has_next? - # res = parser.next - # raise res[1] if res.error? - # end - # - # Nat Price gave me some good ideas for the API. - class BaseParser - LETTER = '[:alpha:]' - DIGIT = '[:digit:]' - - COMBININGCHAR = '' # TODO - EXTENDER = '' # TODO - - NCNAME_STR= "[#{LETTER}_][-[:alnum:]._#{COMBININGCHAR}#{EXTENDER}]*" - QNAME_STR= "(?:(#{NCNAME_STR}):)?(#{NCNAME_STR})" - QNAME = /(#{QNAME_STR})/ - - # Just for backward compatibility. For example, kramdown uses this. - # It's not used in REXML. - UNAME_STR= "(?:#{NCNAME_STR}:)?#{NCNAME_STR}" - - NAMECHAR = '[\-\w\.:]' - NAME = "([\\w:]#{NAMECHAR}*)" - NMTOKEN = "(?:#{NAMECHAR})+" - NMTOKENS = "#{NMTOKEN}(\\s+#{NMTOKEN})*" - REFERENCE = "&(?:#{NAME};|#\\d+;|#x[0-9a-fA-F]+;)" - REFERENCE_RE = /#{REFERENCE}/ - - DOCTYPE_START = /\A\s*<!DOCTYPE\s/um - DOCTYPE_END = /\A\s*\]\s*>/um - ATTRIBUTE_PATTERN = /\s*(#{QNAME_STR})\s*=\s*(["'])(.*?)\4/um - COMMENT_START = /\A<!--/u - COMMENT_PATTERN = /<!--(.*?)-->/um - CDATA_START = /\A<!\[CDATA\[/u - CDATA_END = /\A\s*\]\s*>/um - CDATA_PATTERN = /<!\[CDATA\[(.*?)\]\]>/um - XMLDECL_START = /\A<\?xml\s/u; - XMLDECL_PATTERN = /<\?xml\s+(.*?)\?>/um - INSTRUCTION_START = /\A<\?/u - INSTRUCTION_PATTERN = /<\?#{NAME}(\s+.*?)?\?>/um - TAG_MATCH = /\A<((?>#{QNAME_STR}))/um - CLOSE_MATCH = /\A\s*<\/(#{QNAME_STR})\s*>/um - - VERSION = /\bversion\s*=\s*["'](.*?)['"]/um - ENCODING = /\bencoding\s*=\s*["'](.*?)['"]/um - STANDALONE = /\bstandalone\s*=\s*["'](.*?)['"]/um - - ENTITY_START = /\A\s*<!ENTITY/ - ELEMENTDECL_START = /\A\s*<!ELEMENT/um - ELEMENTDECL_PATTERN = /\A\s*(<!ELEMENT.*?)>/um - SYSTEMENTITY = /\A\s*(%.*?;)\s*$/um - ENUMERATION = "\\(\\s*#{NMTOKEN}(?:\\s*\\|\\s*#{NMTOKEN})*\\s*\\)" - NOTATIONTYPE = "NOTATION\\s+\\(\\s*#{NAME}(?:\\s*\\|\\s*#{NAME})*\\s*\\)" - ENUMERATEDTYPE = "(?:(?:#{NOTATIONTYPE})|(?:#{ENUMERATION}))" - ATTTYPE = "(CDATA|ID|IDREF|IDREFS|ENTITY|ENTITIES|NMTOKEN|NMTOKENS|#{ENUMERATEDTYPE})" - ATTVALUE = "(?:\"((?:[^<&\"]|#{REFERENCE})*)\")|(?:'((?:[^<&']|#{REFERENCE})*)')" - DEFAULTDECL = "(#REQUIRED|#IMPLIED|(?:(#FIXED\\s+)?#{ATTVALUE}))" - ATTDEF = "\\s+#{NAME}\\s+#{ATTTYPE}\\s+#{DEFAULTDECL}" - ATTDEF_RE = /#{ATTDEF}/ - ATTLISTDECL_START = /\A\s*<!ATTLIST/um - ATTLISTDECL_PATTERN = /\A\s*<!ATTLIST\s+#{NAME}(?:#{ATTDEF})*\s*>/um - - TEXT_PATTERN = /\A([^<]*)/um - - # Entity constants - PUBIDCHAR = "\x20\x0D\x0Aa-zA-Z0-9\\-()+,./:=?;!*@$_%#" - SYSTEMLITERAL = %Q{((?:"[^"]*")|(?:'[^']*'))} - PUBIDLITERAL = %Q{("[#{PUBIDCHAR}']*"|'[#{PUBIDCHAR}]*')} - EXTERNALID = "(?:(?:(SYSTEM)\\s+#{SYSTEMLITERAL})|(?:(PUBLIC)\\s+#{PUBIDLITERAL}\\s+#{SYSTEMLITERAL}))" - NDATADECL = "\\s+NDATA\\s+#{NAME}" - PEREFERENCE = "%#{NAME};" - ENTITYVALUE = %Q{((?:"(?:[^%&"]|#{PEREFERENCE}|#{REFERENCE})*")|(?:'([^%&']|#{PEREFERENCE}|#{REFERENCE})*'))} - PEDEF = "(?:#{ENTITYVALUE}|#{EXTERNALID})" - ENTITYDEF = "(?:#{ENTITYVALUE}|(?:#{EXTERNALID}(#{NDATADECL})?))" - PEDECL = "<!ENTITY\\s+(%)\\s+#{NAME}\\s+#{PEDEF}\\s*>" - GEDECL = "<!ENTITY\\s+#{NAME}\\s+#{ENTITYDEF}\\s*>" - ENTITYDECL = /\s*(?:#{GEDECL})|\s*(?:#{PEDECL})/um - - NOTATIONDECL_START = /\A\s*<!NOTATION/um - EXTERNAL_ID_PUBLIC = /\A\s*PUBLIC\s+#{PUBIDLITERAL}\s+#{SYSTEMLITERAL}\s*/um - EXTERNAL_ID_SYSTEM = /\A\s*SYSTEM\s+#{SYSTEMLITERAL}\s*/um - PUBLIC_ID = /\A\s*PUBLIC\s+#{PUBIDLITERAL}\s*/um - - EREFERENCE = /&(?!#{NAME};)/ - - DEFAULT_ENTITIES = { - 'gt' => [/>/, '>', '>', />/], - 'lt' => [/</, '<', '<', /</], - 'quot' => [/"/, '"', '"', /"/], - "apos" => [/'/, "'", "'", /'/] - } - - module Private - PEREFERENCE_PATTERN = /#{PEREFERENCE}/um - TAG_PATTERN = /((?>#{QNAME_STR}))\s*/um - CLOSE_PATTERN = /(#{QNAME_STR})\s*>/um - ATTLISTDECL_END = /\s+#{NAME}(?:#{ATTDEF})*\s*>/um - NAME_PATTERN = /#{NAME}/um - GEDECL_PATTERN = "\\s+#{NAME}\\s+#{ENTITYDEF}\\s*>" - PEDECL_PATTERN = "\\s+(%)\\s+#{NAME}\\s+#{PEDEF}\\s*>" - ENTITYDECL_PATTERN = /(?:#{GEDECL_PATTERN})|(?:#{PEDECL_PATTERN})/um - CARRIAGE_RETURN_NEWLINE_PATTERN = /\r\n?/ - CHARACTER_REFERENCES = /&#((?:\d+)|(?:x[a-fA-F0-9]+));/ - DEFAULT_ENTITIES_PATTERNS = {} - default_entities = ['gt', 'lt', 'quot', 'apos', 'amp'] - default_entities.each do |term| - DEFAULT_ENTITIES_PATTERNS[term] = /&#{term};/ - end - XML_PREFIXED_NAMESPACE = "http://www.w3.org/XML/1998/namespace" - end - private_constant :Private - - def initialize( source ) - self.stream = source - @listeners = [] - @prefixes = Set.new - @entity_expansion_count = 0 - @entity_expansion_limit = Security.entity_expansion_limit - @entity_expansion_text_limit = Security.entity_expansion_text_limit - @source.ensure_buffer - end - - def add_listener( listener ) - @listeners << listener - end - - attr_reader :source - attr_reader :entity_expansion_count - attr_writer :entity_expansion_limit - attr_writer :entity_expansion_text_limit - - def stream=( source ) - @source = SourceFactory.create_from( source ) - @closed = nil - @have_root = false - @document_status = nil - @tags = [] - @stack = [] - @entities = [] - @namespaces = {"xml" => Private::XML_PREFIXED_NAMESPACE} - @namespaces_restore_stack = [] - end - - def position - if @source.respond_to? :position - @source.position - else - # FIXME - 0 - end - end - - # Returns true if there are no more events - def empty? - return (@source.empty? and @stack.empty?) - end - - # Returns true if there are more events. Synonymous with !empty? - def has_next? - return !(@source.empty? and @stack.empty?) - end - - # Push an event back on the head of the stream. This method - # has (theoretically) infinite depth. - def unshift token - @stack.unshift(token) - end - - # Peek at the +depth+ event in the stack. The first element on the stack - # is at depth 0. If +depth+ is -1, will parse to the end of the input - # stream and return the last event, which is always :end_document. - # Be aware that this causes the stream to be parsed up to the +depth+ - # event, so you can effectively pre-parse the entire document (pull the - # entire thing into memory) using this method. - def peek depth=0 - raise %Q[Illegal argument "#{depth}"] if depth < -1 - temp = [] - if depth == -1 - temp.push(pull()) until empty? - else - while @stack.size+temp.size < depth+1 - temp.push(pull()) - end - end - @stack += temp if temp.size > 0 - @stack[depth] - end - - # Returns the next event. This is a +PullEvent+ object. - def pull - @source.drop_parsed_content - - pull_event.tap do |event| - @listeners.each do |listener| - listener.receive event - end - end - end - - def pull_event - if @closed - x, @closed = @closed, nil - return [ :end_element, x ] - end - if empty? - if @document_status == :in_doctype - raise ParseException.new("Malformed DOCTYPE: unclosed", @source) - end - unless @tags.empty? - path = "/" + @tags.join("/") - raise ParseException.new("Missing end tag for '#{path}'", @source) - end - return [ :end_document ] - end - return @stack.shift if @stack.size > 0 - #STDERR.puts @source.encoding - #STDERR.puts "BUFFER = #{@source.buffer.inspect}" - - @source.ensure_buffer - if @document_status == nil - start_position = @source.position - if @source.match("<?", true) - return process_instruction - elsif @source.match("<!", true) - if @source.match("--", true) - md = @source.match(/(.*?)-->/um, true) - if md.nil? - raise REXML::ParseException.new("Unclosed comment", @source) - end - if /--|-\z/.match?(md[1]) - raise REXML::ParseException.new("Malformed comment", @source) - end - return [ :comment, md[1] ] - elsif @source.match("DOCTYPE", true) - base_error_message = "Malformed DOCTYPE" - unless @source.match(/\s+/um, true) - if @source.match(">") - message = "#{base_error_message}: name is missing" - else - message = "#{base_error_message}: invalid name" - end - @source.position = start_position - raise REXML::ParseException.new(message, @source) - end - name = parse_name(base_error_message) - if @source.match(/\s*\[/um, true) - id = [nil, nil, nil] - @document_status = :in_doctype - elsif @source.match(/\s*>/um, true) - id = [nil, nil, nil] - @document_status = :after_doctype - @source.ensure_buffer - else - id = parse_id(base_error_message, - accept_external_id: true, - accept_public_id: false) - if id[0] == "SYSTEM" - # For backward compatibility - id[1], id[2] = id[2], nil - end - if @source.match(/\s*\[/um, true) - @document_status = :in_doctype - elsif @source.match(/\s*>/um, true) - @document_status = :after_doctype - @source.ensure_buffer - else - message = "#{base_error_message}: garbage after external ID" - raise REXML::ParseException.new(message, @source) - end - end - args = [:start_doctype, name, *id] - if @document_status == :after_doctype - @source.match(/\s*/um, true) - @stack << [ :end_doctype ] - end - return args - else - message = "Invalid XML" - raise REXML::ParseException.new(message, @source) - end - end - end - if @document_status == :in_doctype - @source.match(/\s*/um, true) # skip spaces - start_position = @source.position - if @source.match("<!", true) - if @source.match("ELEMENT", true) - md = @source.match(/(.*?)>/um, true) - raise REXML::ParseException.new( "Bad ELEMENT declaration!", @source ) if md.nil? - return [ :elementdecl, "<!ELEMENT" + md[1] ] - elsif @source.match("ENTITY", true) - match_data = @source.match(Private::ENTITYDECL_PATTERN, true) - unless match_data - raise REXML::ParseException.new("Malformed entity declaration", @source) - end - match = [:entitydecl, *match_data.captures.compact] - ref = false - if match[1] == '%' - ref = true - match.delete_at 1 - end - # Now we have to sort out what kind of entity reference this is - if match[2] == 'SYSTEM' - # External reference - match[3] = match[3][1..-2] # PUBID - match.delete_at(4) if match.size > 4 # Chop out NDATA decl - # match is [ :entity, name, SYSTEM, pubid(, ndata)? ] - elsif match[2] == 'PUBLIC' - # External reference - match[3] = match[3][1..-2] # PUBID - match[4] = match[4][1..-2] # HREF - match.delete_at(5) if match.size > 5 # Chop out NDATA decl - # match is [ :entity, name, PUBLIC, pubid, href(, ndata)? ] - elsif Private::PEREFERENCE_PATTERN.match?(match[2]) - raise REXML::ParseException.new("Parameter entity references forbidden in internal subset: #{match[2]}", @source) - else - match[2] = match[2][1..-2] - match.pop if match.size == 4 - # match is [ :entity, name, value ] - end - match << '%' if ref - return match - elsif @source.match("ATTLIST", true) - md = @source.match(Private::ATTLISTDECL_END, true) - raise REXML::ParseException.new( "Bad ATTLIST declaration!", @source ) if md.nil? - element = md[1] - contents = md[0] - - pairs = {} - values = md[0].strip.scan( ATTDEF_RE ) - values.each do |attdef| - unless attdef[3] == "#IMPLIED" - attdef.compact! - val = attdef[3] - val = attdef[4] if val == "#FIXED " - pairs[attdef[0]] = val - if attdef[0] =~ /^xmlns:(.*)/ - @namespaces[$1] = val - end - end - end - return [ :attlistdecl, element, pairs, contents ] - elsif @source.match("NOTATION", true) - base_error_message = "Malformed notation declaration" - unless @source.match(/\s+/um, true) - if @source.match(">") - message = "#{base_error_message}: name is missing" - else - message = "#{base_error_message}: invalid name" - end - @source.position = start_position - raise REXML::ParseException.new(message, @source) - end - name = parse_name(base_error_message) - id = parse_id(base_error_message, - accept_external_id: true, - accept_public_id: true) - unless @source.match(/\s*>/um, true) - message = "#{base_error_message}: garbage before end >" - raise REXML::ParseException.new(message, @source) - end - return [:notationdecl, name, *id] - elsif md = @source.match(/--(.*?)-->/um, true) - case md[1] - when /--/, /-\z/ - raise REXML::ParseException.new("Malformed comment", @source) - end - return [ :comment, md[1] ] if md - end - elsif match = @source.match(/(%.*?;)\s*/um, true) - return [ :externalentity, match[1] ] - elsif @source.match(/\]\s*>/um, true) - @document_status = :after_doctype - return [ :end_doctype ] - end - if @document_status == :in_doctype - raise ParseException.new("Malformed DOCTYPE: invalid declaration", @source) - end - end - if @document_status == :after_doctype - @source.match(/\s*/um, true) - end - begin - start_position = @source.position - if @source.match("<", true) - # :text's read_until may remain only "<" in buffer. In the - # case, buffer is empty here. So we need to fill buffer - # here explicitly. - @source.ensure_buffer - if @source.match("/", true) - @namespaces_restore_stack.pop - last_tag = @tags.pop - md = @source.match(Private::CLOSE_PATTERN, true) - if md and !last_tag - message = "Unexpected top-level end tag (got '#{md[1]}')" - raise REXML::ParseException.new(message, @source) - end - if md.nil? or last_tag != md[1] - message = "Missing end tag for '#{last_tag}'" - message += " (got '#{md[1]}')" if md - @source.position = start_position if md.nil? - raise REXML::ParseException.new(message, @source) - end - return [ :end_element, last_tag ] - elsif @source.match("!", true) - md = @source.match(/([^>]*>)/um) - #STDERR.puts "SOURCE BUFFER = #{source.buffer}, #{source.buffer.size}" - raise REXML::ParseException.new("Malformed node", @source) unless md - if md[0][0] == ?- - md = @source.match(/--(.*?)-->/um, true) - - if md.nil? || /--|-\z/.match?(md[1]) - raise REXML::ParseException.new("Malformed comment", @source) - end - - return [ :comment, md[1] ] - else - md = @source.match(/\[CDATA\[(.*?)\]\]>/um, true) - return [ :cdata, md[1] ] if md - end - raise REXML::ParseException.new( "Declarations can only occur "+ - "in the doctype declaration.", @source) - elsif @source.match("?", true) - return process_instruction - else - # Get the next tag - md = @source.match(Private::TAG_PATTERN, true) - unless md - @source.position = start_position - raise REXML::ParseException.new("malformed XML: missing tag start", @source) - end - tag = md[1] - @document_status = :in_element - @prefixes.clear - @prefixes << md[2] if md[2] - push_namespaces_restore - attributes, closed = parse_attributes(@prefixes) - # Verify that all of the prefixes have been defined - for prefix in @prefixes - unless @namespaces.key?(prefix) - raise UndefinedNamespaceException.new(prefix,@source,self) - end - end - - if closed - @closed = tag - pop_namespaces_restore - else - if @tags.empty? and @have_root - raise ParseException.new("Malformed XML: Extra tag at the end of the document (got '<#{tag}')", @source) - end - @tags.push( tag ) - end - @have_root = true - return [ :start_element, tag, attributes ] - end - else - text = @source.read_until("<") - if text.chomp!("<") - @source.position -= "<".bytesize - end - if @tags.empty? - unless /\A\s*\z/.match?(text) - if @have_root - raise ParseException.new("Malformed XML: Extra content at the end of the document (got '#{text}')", @source) - else - raise ParseException.new("Malformed XML: Content at the start of the document (got '#{text}')", @source) - end - end - return pull_event if @have_root - end - return [ :text, text ] - end - rescue REXML::UndefinedNamespaceException - raise - rescue REXML::ParseException - raise - rescue => error - raise REXML::ParseException.new( "Exception parsing", - @source, self, (error ? error : $!) ) - end - return [ :dummy ] - end - private :pull_event - - def entity( reference, entities ) - return unless entities - - value = entities[ reference ] - return if value.nil? - - record_entity_expansion - unnormalize( value, entities ) - end - - # Escapes all possible entities - def normalize( input, entities=nil, entity_filter=nil ) - copy = input.clone - # Doing it like this rather than in a loop improves the speed - copy.gsub!( EREFERENCE, '&' ) - entities.each do |key, value| - copy.gsub!( value, "&#{key};" ) unless entity_filter and - entity_filter.include?(entity) - end if entities - copy.gsub!( EREFERENCE, '&' ) - DEFAULT_ENTITIES.each do |key, value| - copy.gsub!( value[3], value[1] ) - end - copy - end - - # Unescapes all possible entities - def unnormalize( string, entities=nil, filter=nil ) - if string.include?("\r") - rv = string.gsub( Private::CARRIAGE_RETURN_NEWLINE_PATTERN, "\n" ) - else - rv = string.dup - end - matches = rv.scan( REFERENCE_RE ) - return rv if matches.size == 0 - rv.gsub!( Private::CHARACTER_REFERENCES ) { - m=$1 - if m.start_with?("x") - code_point = Integer(m[1..-1], 16) - else - code_point = Integer(m, 10) - end - [code_point].pack('U*') - } - matches.collect!{|x|x[0]}.compact! - if filter - matches.reject! do |entity_reference| - filter.include?(entity_reference) - end - end - if matches.size > 0 - matches.tally.each do |entity_reference, n| - entity_expansion_count_before = @entity_expansion_count - entity_value = entity( entity_reference, entities ) - if entity_value - if n > 1 - entity_expansion_count_delta = - @entity_expansion_count - entity_expansion_count_before - record_entity_expansion(entity_expansion_count_delta * (n - 1)) - end - re = Private::DEFAULT_ENTITIES_PATTERNS[entity_reference] || /&#{entity_reference};/ - rv.gsub!( re, entity_value ) - if rv.bytesize > @entity_expansion_text_limit - raise "entity expansion has grown too large" - end - else - er = DEFAULT_ENTITIES[entity_reference] - rv.gsub!( er[0], er[2] ) if er - end - end - rv.gsub!( Private::DEFAULT_ENTITIES_PATTERNS['amp'], '&' ) - end - rv - end - - private - def add_namespace(prefix, uri) - @namespaces_restore_stack.last[prefix] = @namespaces[prefix] - if uri.nil? - @namespaces.delete(prefix) - else - @namespaces[prefix] = uri - end - end - - def push_namespaces_restore - namespaces_restore = {} - @namespaces_restore_stack.push(namespaces_restore) - namespaces_restore - end - - def pop_namespaces_restore - namespaces_restore = @namespaces_restore_stack.pop - namespaces_restore.each do |prefix, uri| - if uri.nil? - @namespaces.delete(prefix) - else - @namespaces[prefix] = uri - end - end - end - - def record_entity_expansion(delta=1) - @entity_expansion_count += delta - if @entity_expansion_count > @entity_expansion_limit - raise "number of entity expansions exceeded, processing aborted." - end - end - - def need_source_encoding_update?(xml_declaration_encoding) - return false if xml_declaration_encoding.nil? - return false if /\AUTF-16\z/i =~ xml_declaration_encoding - true - end - - def parse_name(base_error_message) - md = @source.match(Private::NAME_PATTERN, true) - unless md - if @source.match(/\S/um) - message = "#{base_error_message}: invalid name" - else - message = "#{base_error_message}: name is missing" - end - raise REXML::ParseException.new(message, @source) - end - md[0] - end - - def parse_id(base_error_message, - accept_external_id:, - accept_public_id:) - if accept_external_id and (md = @source.match(EXTERNAL_ID_PUBLIC, true)) - pubid = system = nil - pubid_literal = md[1] - pubid = pubid_literal[1..-2] if pubid_literal # Remove quote - system_literal = md[2] - system = system_literal[1..-2] if system_literal # Remove quote - ["PUBLIC", pubid, system] - elsif accept_public_id and (md = @source.match(PUBLIC_ID, true)) - pubid = system = nil - pubid_literal = md[1] - pubid = pubid_literal[1..-2] if pubid_literal # Remove quote - ["PUBLIC", pubid, nil] - elsif accept_external_id and (md = @source.match(EXTERNAL_ID_SYSTEM, true)) - system = nil - system_literal = md[1] - system = system_literal[1..-2] if system_literal # Remove quote - ["SYSTEM", nil, system] - else - details = parse_id_invalid_details(accept_external_id: accept_external_id, - accept_public_id: accept_public_id) - message = "#{base_error_message}: #{details}" - raise REXML::ParseException.new(message, @source) - end - end - - def parse_id_invalid_details(accept_external_id:, - accept_public_id:) - public = /\A\s*PUBLIC/um - system = /\A\s*SYSTEM/um - if (accept_external_id or accept_public_id) and @source.match(/#{public}/um) - if @source.match(/#{public}(?:\s+[^'"]|\s*[\[>])/um) - return "public ID literal is missing" - end - unless @source.match(/#{public}\s+#{PUBIDLITERAL}/um) - return "invalid public ID literal" - end - if accept_public_id - if @source.match(/#{public}\s+#{PUBIDLITERAL}\s+[^'"]/um) - return "system ID literal is missing" - end - unless @source.match(/#{public}\s+#{PUBIDLITERAL}\s+#{SYSTEMLITERAL}/um) - return "invalid system literal" - end - "garbage after system literal" - else - "garbage after public ID literal" - end - elsif accept_external_id and @source.match(/#{system}/um) - if @source.match(/#{system}(?:\s+[^'"]|\s*[\[>])/um) - return "system literal is missing" - end - unless @source.match(/#{system}\s+#{SYSTEMLITERAL}/um) - return "invalid system literal" - end - "garbage after system literal" - else - unless @source.match(/\A\s*(?:PUBLIC|SYSTEM)\s/um) - return "invalid ID type" - end - "ID type is missing" - end - end - - def process_instruction - name = parse_name("Malformed XML: Invalid processing instruction node") - if @source.match(/\s+/um, true) - match_data = @source.match(/(.*?)\?>/um, true) - unless match_data - raise ParseException.new("Malformed XML: Unclosed processing instruction", @source) - end - content = match_data[1] - else - content = nil - unless @source.match("?>", true) - raise ParseException.new("Malformed XML: Unclosed processing instruction", @source) - end - end - if name == "xml" - if @document_status - raise ParseException.new("Malformed XML: XML declaration is not at the start", @source) - end - version = VERSION.match(content) - version = version[1] unless version.nil? - encoding = ENCODING.match(content) - encoding = encoding[1] unless encoding.nil? - if need_source_encoding_update?(encoding) - @source.encoding = encoding - end - if encoding.nil? and /\AUTF-16(?:BE|LE)\z/i =~ @source.encoding - encoding = "UTF-16" - end - standalone = STANDALONE.match(content) - standalone = standalone[1] unless standalone.nil? - return [ :xmldecl, version, encoding, standalone ] - end - [:processing_instruction, name, content] - end - - def parse_attributes(prefixes) - attributes = {} - expanded_names = {} - closed = false - while true - if @source.match(">", true) - return attributes, closed - elsif @source.match("/>", true) - closed = true - return attributes, closed - elsif match = @source.match(QNAME, true) - name = match[1] - prefix = match[2] - local_part = match[3] - - unless @source.match(/\s*=\s*/um, true) - message = "Missing attribute equal: <#{name}>" - raise REXML::ParseException.new(message, @source) - end - unless match = @source.match(/(['"])/, true) - message = "Missing attribute value start quote: <#{name}>" - raise REXML::ParseException.new(message, @source) - end - quote = match[1] - start_position = @source.position - value = @source.read_until(quote) - unless value.chomp!(quote) - @source.position = start_position - message = "Missing attribute value end quote: <#{name}>: <#{quote}>" - raise REXML::ParseException.new(message, @source) - end - @source.match(/\s*/um, true) - if prefix == "xmlns" - if local_part == "xml" - if value != Private::XML_PREFIXED_NAMESPACE - msg = "The 'xml' prefix must not be bound to any other namespace "+ - "(http://www.w3.org/TR/REC-xml-names/#ns-decl)" - raise REXML::ParseException.new( msg, @source, self ) - end - elsif local_part == "xmlns" - msg = "The 'xmlns' prefix must not be declared "+ - "(http://www.w3.org/TR/REC-xml-names/#ns-decl)" - raise REXML::ParseException.new( msg, @source, self) - end - add_namespace(local_part, value) - elsif prefix - prefixes << prefix unless prefix == "xml" - end - - if attributes[name] - msg = "Duplicate attribute #{name.inspect}" - raise REXML::ParseException.new(msg, @source, self) - end - - unless prefix == "xmlns" - uri = @namespaces[prefix] - expanded_name = [uri, local_part] - existing_prefix = expanded_names[expanded_name] - if existing_prefix - message = "Namespace conflict in adding attribute " + - "\"#{local_part}\": " + - "Prefix \"#{existing_prefix}\" = \"#{uri}\" and " + - "prefix \"#{prefix}\" = \"#{uri}\"" - raise REXML::ParseException.new(message, @source, self) - end - expanded_names[expanded_name] = prefix - end - - attributes[name] = value - else - message = "Invalid attribute name: <#{@source.buffer.split(%r{[/>\s]}).first}>" - raise REXML::ParseException.new(message, @source) - end - end - end - end - end -end - -=begin - case event[0] - when :start_element - when :text - when :end_element - when :processing_instruction - when :cdata - when :comment - when :xmldecl - when :start_doctype - when :end_doctype - when :externalentity - when :elementdecl - when :entity - when :attlistdecl - when :notationdecl - when :end_doctype - end -=end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/lightparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/lightparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/lightparser.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/lightparser.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,59 +0,0 @@ -# frozen_string_literal: false -require_relative 'streamparser' -require_relative 'baseparser' -require_relative '../light/node' - -module REXML - module Parsers - class LightParser - def initialize stream - @stream = stream - @parser = REXML::Parsers::BaseParser.new( stream ) - end - - def add_listener( listener ) - @parser.add_listener( listener ) - end - - def rewind - @stream.rewind - @parser.stream = @stream - end - - def parse - root = context = [ :document ] - while true - event = @parser.pull - case event[0] - when :end_document - break - when :start_element, :start_doctype - new_node = event - context << new_node - new_node[1,0] = [context] - context = new_node - when :end_element, :end_doctype - context = context[1] - else - new_node = event - context << new_node - new_node[1,0] = [context] - end - end - root - end - end - - # An element is an array. The array contains: - # 0 The parent element - # 1 The tag name - # 2 A hash of attributes - # 3..-1 The child elements - # An element is an array of size > 3 - # Text is a String - # PIs are [ :processing_instruction, target, data ] - # Comments are [ :comment, data ] - # DocTypes are DocType structs - # The root is an array with XMLDecls, Text, DocType, Array, Text - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/pullparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/pullparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/pullparser.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/pullparser.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,209 +0,0 @@ -# frozen_string_literal: false -require 'forwardable' - -require_relative '../parseexception' -require_relative 'baseparser' -require_relative '../xmltokens' - -module REXML - module Parsers - # = Using the Pull Parser - # <em>This API is experimental, and subject to change.</em> - # parser = PullParser.new( "<a>text<b att='val'/>txet</a>" ) - # while parser.has_next? - # res = parser.next - # puts res[1]['att'] if res.start_tag? and res[0] == 'b' - # end - # See the PullEvent class for information on the content of the results. - # The data is identical to the arguments passed for the various events to - # the StreamListener API. - # - # Notice that: - # parser = PullParser.new( "<a>BAD DOCUMENT" ) - # while parser.has_next? - # res = parser.next - # raise res[1] if res.error? - # end - # - # Nat Price gave me some good ideas for the API. - class PullParser - include XMLTokens - extend Forwardable - - def_delegators( :@parser, :has_next? ) - def_delegators( :@parser, :entity ) - def_delegators( :@parser, :empty? ) - def_delegators( :@parser, :source ) - - def initialize stream - @entities = {} - @listeners = nil - @parser = BaseParser.new( stream ) - @my_stack = [] - end - - def add_listener( listener ) - @listeners = [] unless @listeners - @listeners << listener - end - - def entity_expansion_count - @parser.entity_expansion_count - end - - def entity_expansion_limit=( limit ) - @parser.entity_expansion_limit = limit - end - - def entity_expansion_text_limit=( limit ) - @parser.entity_expansion_text_limit = limit - end - - def each - while has_next? - yield self.pull - end - end - - def peek depth=0 - if @my_stack.length <= depth - (depth - @my_stack.length + 1).times { - e = PullEvent.new(@parser.pull) - @my_stack.push(e) - } - end - @my_stack[depth] - end - - def pull - return @my_stack.shift if @my_stack.length > 0 - - event = @parser.pull - case event[0] - when :entitydecl - @entities[ event[1] ] = - event[2] unless event[2] =~ /PUBLIC|SYSTEM/ - when :text - unnormalized = @parser.unnormalize( event[1], @entities ) - event << unnormalized - end - PullEvent.new( event ) - end - - def unshift token - @my_stack.unshift token - end - end - - # A parsing event. The contents of the event are accessed as an +Array?, - # and the type is given either by the ...? methods, or by accessing the - # +type+ accessor. The contents of this object vary from event to event, - # but are identical to the arguments passed to +StreamListener+s for each - # event. - class PullEvent - # The type of this event. Will be one of :tag_start, :tag_end, :text, - # :processing_instruction, :comment, :doctype, :attlistdecl, :entitydecl, - # :notationdecl, :entity, :cdata, :xmldecl, or :error. - def initialize(arg) - @contents = arg - end - - def []( start, endd=nil) - if start.kind_of? Range - @contents.slice( start.begin+1 .. start.end ) - elsif start.kind_of? Numeric - if endd.nil? - @contents.slice( start+1 ) - else - @contents.slice( start+1, endd ) - end - else - raise "Illegal argument #{start.inspect} (#{start.class})" - end - end - - def event_type - @contents[0] - end - - # Content: [ String tag_name, Hash attributes ] - def start_element? - @contents[0] == :start_element - end - - # Content: [ String tag_name ] - def end_element? - @contents[0] == :end_element - end - - # Content: [ String raw_text, String unnormalized_text ] - def text? - @contents[0] == :text - end - - # Content: [ String text ] - def instruction? - @contents[0] == :processing_instruction - end - - # Content: [ String text ] - def comment? - @contents[0] == :comment - end - - # Content: [ String name, String pub_sys, String long_name, String uri ] - def doctype? - @contents[0] == :start_doctype - end - - # Content: [ String text ] - def attlistdecl? - @contents[0] == :attlistdecl - end - - # Content: [ String text ] - def elementdecl? - @contents[0] == :elementdecl - end - - # Due to the wonders of DTDs, an entity declaration can be just about - # anything. There's no way to normalize it; you'll have to interpret the - # content yourself. However, the following is true: - # - # * If the entity declaration is an internal entity: - # [ String name, String value ] - # Content: [ String text ] - def entitydecl? - @contents[0] == :entitydecl - end - - # Content: [ String text ] - def notationdecl? - @contents[0] == :notationdecl - end - - # Content: [ String text ] - def entity? - @contents[0] == :entity - end - - # Content: [ String text ] - def cdata? - @contents[0] == :cdata - end - - # Content: [ String version, String encoding, String standalone ] - def xmldecl? - @contents[0] == :xmldecl - end - - def error? - @contents[0] == :error - end - - def inspect - @contents[0].to_s + ": " + @contents[1..-1].inspect - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/sax2parser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/sax2parser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/sax2parser.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/sax2parser.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,270 +0,0 @@ -# frozen_string_literal: false -require_relative 'baseparser' -require_relative '../parseexception' -require_relative '../namespace' -require_relative '../text' - -module REXML - module Parsers - # SAX2Parser - class SAX2Parser - def initialize source - @parser = BaseParser.new(source) - @listeners = [] - @procs = [] - @namespace_stack = [] - @has_listeners = false - @tag_stack = [] - @entities = {} - end - - def source - @parser.source - end - - def entity_expansion_count - @parser.entity_expansion_count - end - - def entity_expansion_limit=( limit ) - @parser.entity_expansion_limit = limit - end - - def entity_expansion_text_limit=( limit ) - @parser.entity_expansion_text_limit = limit - end - - def add_listener( listener ) - @parser.add_listener( listener ) - end - - # Listen arguments: - # - # Symbol, Array, Block - # Listen to Symbol events on Array elements - # Symbol, Block - # Listen to Symbol events - # Array, Listener - # Listen to all events on Array elements - # Array, Block - # Listen to :start_element events on Array elements - # Listener - # Listen to All events - # - # Symbol can be one of: :start_element, :end_element, - # :start_prefix_mapping, :end_prefix_mapping, :characters, - # :processing_instruction, :doctype, :attlistdecl, :elementdecl, - # :entitydecl, :notationdecl, :cdata, :xmldecl, :comment - # - # There is an additional symbol that can be listened for: :progress. - # This will be called for every event generated, passing in the current - # stream position. - # - # Array contains regular expressions or strings which will be matched - # against fully qualified element names. - # - # Listener must implement the methods in SAX2Listener - # - # Block will be passed the same arguments as a SAX2Listener method would - # be, where the method name is the same as the matched Symbol. - # See the SAX2Listener for more information. - def listen( *args, &blok ) - if args[0].kind_of? Symbol - if args.size == 2 - args[1].each { |match| @procs << [args[0], match, blok] } - else - add( [args[0], nil, blok] ) - end - elsif args[0].kind_of? Array - if args.size == 2 - args[0].each { |match| add( [nil, match, args[1]] ) } - else - args[0].each { |match| add( [ :start_element, match, blok ] ) } - end - else - add([nil, nil, args[0]]) - end - end - - def deafen( listener=nil, &blok ) - if listener - @listeners.delete_if {|item| item[-1] == listener } - @has_listeners = false if @listeners.size == 0 - else - @procs.delete_if {|item| item[-1] == blok } - end - end - - def parse - @procs.each { |sym,match,block| block.call if sym == :start_document } - @listeners.each { |sym,match,block| - block.start_document if sym == :start_document or sym.nil? - } - context = [] - while true - event = @parser.pull - case event[0] - when :end_document - handle( :end_document ) - break - when :start_doctype - handle( :doctype, *event[1..-1]) - when :end_doctype - context = context[1] - when :start_element - @tag_stack.push(event[1]) - # find the observers for namespaces - procs = get_procs( :start_prefix_mapping, event[1] ) - listeners = get_listeners( :start_prefix_mapping, event[1] ) - if procs or listeners - # break out the namespace declarations - # The attributes live in event[2] - event[2].each {|n, v| event[2][n] = @parser.normalize(v)} - nsdecl = event[2].find_all { |n, value| n =~ /^xmlns(:|$)/ } - nsdecl.collect! { |n, value| [ n[6..-1], value ] } - @namespace_stack.push({}) - nsdecl.each do |n,v| - @namespace_stack[-1][n] = v - # notify observers of namespaces - procs.each { |ob| ob.call( n, v ) } if procs - listeners.each { |ob| ob.start_prefix_mapping(n, v) } if listeners - end - end - event[1] =~ Namespace::NAMESPLIT - prefix = $1 - local = $2 - uri = get_namespace(prefix) - # find the observers for start_element - procs = get_procs( :start_element, event[1] ) - listeners = get_listeners( :start_element, event[1] ) - # notify observers - procs.each { |ob| ob.call( uri, local, event[1], event[2] ) } if procs - listeners.each { |ob| - ob.start_element( uri, local, event[1], event[2] ) - } if listeners - when :end_element - @tag_stack.pop - event[1] =~ Namespace::NAMESPLIT - prefix = $1 - local = $2 - uri = get_namespace(prefix) - # find the observers for start_element - procs = get_procs( :end_element, event[1] ) - listeners = get_listeners( :end_element, event[1] ) - # notify observers - procs.each { |ob| ob.call( uri, local, event[1] ) } if procs - listeners.each { |ob| - ob.end_element( uri, local, event[1] ) - } if listeners - - namespace_mapping = @namespace_stack.pop - # find the observers for namespaces - procs = get_procs( :end_prefix_mapping, event[1] ) - listeners = get_listeners( :end_prefix_mapping, event[1] ) - if procs or listeners - namespace_mapping.each do |ns_prefix, ns_uri| - # notify observers of namespaces - procs.each { |ob| ob.call( ns_prefix ) } if procs - listeners.each { |ob| ob.end_prefix_mapping(ns_prefix) } if listeners - end - end - when :text - unnormalized = @parser.unnormalize( event[1], @entities ) - handle( :characters, unnormalized ) - when :entitydecl - handle_entitydecl( event ) - when :processing_instruction, :comment, :attlistdecl, - :elementdecl, :cdata, :notationdecl, :xmldecl - handle( *event ) - end - handle( :progress, @parser.position ) - end - end - - private - def handle( symbol, *arguments ) - tag = @tag_stack[-1] - procs = get_procs( symbol, tag ) - listeners = get_listeners( symbol, tag ) - # notify observers - procs.each { |ob| ob.call( *arguments ) } if procs - listeners.each { |l| - l.send( symbol.to_s, *arguments ) - } if listeners - end - - def handle_entitydecl( event ) - @entities[ event[1] ] = event[2] if event.size == 3 - parameter_reference_p = false - case event[2] - when "SYSTEM" - if event.size == 5 - if event.last == "%" - parameter_reference_p = true - else - event[4, 0] = "NDATA" - end - end - when "PUBLIC" - if event.size == 6 - if event.last == "%" - parameter_reference_p = true - else - event[5, 0] = "NDATA" - end - end - else - parameter_reference_p = (event.size == 4) - end - event[1, 0] = event.pop if parameter_reference_p - handle( event[0], event[1..-1] ) - end - - # The following methods are duplicates, but it is faster than using - # a helper - def get_procs( symbol, name ) - return nil if @procs.size == 0 - @procs.find_all do |sym, match, block| - ( - (sym.nil? or symbol == sym) and - ((name.nil? and match.nil?) or match.nil? or ( - (name == match) or - (match.kind_of? Regexp and name =~ match) - ) - ) - ) - end.collect{|x| x[-1]} - end - def get_listeners( symbol, name ) - return nil if @listeners.size == 0 - @listeners.find_all do |sym, match, block| - ( - (sym.nil? or symbol == sym) and - ((name.nil? and match.nil?) or match.nil? or ( - (name == match) or - (match.kind_of? Regexp and name =~ match) - ) - ) - ) - end.collect{|x| x[-1]} - end - - def add( pair ) - if pair[-1].respond_to? :call - @procs << pair unless @procs.include? pair - else - @listeners << pair unless @listeners.include? pair - @has_listeners = true - end - end - - def get_namespace( prefix ) - return nil if @namespace_stack.empty? - - uris = (@namespace_stack.find_all { |ns| not ns[prefix].nil? }) || - (@namespace_stack.find { |ns| not ns[nil].nil? }) - uris[-1][prefix] unless uris.nil? or 0 == uris.size - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/streamparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/streamparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/streamparser.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/streamparser.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,67 +0,0 @@ -# frozen_string_literal: false -require_relative "baseparser" - -module REXML - module Parsers - class StreamParser - def initialize source, listener - @listener = listener - @parser = BaseParser.new( source ) - @entities = {} - end - - def add_listener( listener ) - @parser.add_listener( listener ) - end - - def entity_expansion_count - @parser.entity_expansion_count - end - - def entity_expansion_limit=( limit ) - @parser.entity_expansion_limit = limit - end - - def entity_expansion_text_limit=( limit ) - @parser.entity_expansion_text_limit = limit - end - - def parse - # entity string - while true - event = @parser.pull - case event[0] - when :end_document - return - when :start_element - attrs = event[2].each do |n, v| - event[2][n] = @parser.unnormalize( v ) - end - @listener.tag_start( event[1], attrs ) - when :end_element - @listener.tag_end( event[1] ) - when :text - unnormalized = @parser.unnormalize( event[1], @entities ) - @listener.text( unnormalized ) - when :processing_instruction - @listener.instruction( *event[1,2] ) - when :start_doctype - @listener.doctype( *event[1..-1] ) - when :end_doctype - # FIXME: remove this condition for milestone:3.2 - @listener.doctype_end if @listener.respond_to? :doctype_end - when :comment, :attlistdecl, :cdata, :xmldecl, :elementdecl - @listener.send( event[0].to_s, *event[1..-1] ) - when :entitydecl, :notationdecl - @entities[ event[1] ] = event[2] if event.size == 3 - @listener.send( event[0].to_s, event[1..-1] ) - when :externalentity - entity_reference = event[1] - content = entity_reference.gsub(/\A%|;\z/, "") - @listener.entity(content) - end - end - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/treeparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/treeparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/treeparser.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/treeparser.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,89 +0,0 @@ -# frozen_string_literal: false -require_relative '../validation/validationexception' -require_relative '../undefinednamespaceexception' - -module REXML - module Parsers - class TreeParser - def initialize( source, build_context = Document.new ) - @build_context = build_context - @parser = Parsers::BaseParser.new( source ) - end - - def add_listener( listener ) - @parser.add_listener( listener ) - end - - def parse - entities = nil - begin - while true - event = @parser.pull - #STDERR.puts "TREEPARSER GOT #{event.inspect}" - case event[0] - when :end_document - return - when :start_element - el = @build_context = @build_context.add_element( event[1] ) - event[2].each do |key, value| - el.attributes[key]=Attribute.new(key,value,self) - end - when :end_element - @build_context = @build_context.parent - when :text - if @build_context[-1].instance_of? Text - @build_context[-1] << event[1] - else - @build_context.add( - Text.new(event[1], @build_context.whitespace, nil, true) - ) unless ( - @build_context.ignore_whitespace_nodes and - event[1].strip.size==0 - ) - end - when :comment - c = Comment.new( event[1] ) - @build_context.add( c ) - when :cdata - c = CData.new( event[1] ) - @build_context.add( c ) - when :processing_instruction - @build_context.add( Instruction.new( event[1], event[2] ) ) - when :end_doctype - entities.each { |k,v| entities[k] = @build_context.entities[k].value } - @build_context = @build_context.parent - when :start_doctype - doctype = DocType.new( event[1..-1], @build_context ) - @build_context = doctype - entities = {} - when :attlistdecl - n = AttlistDecl.new( event[1..-1] ) - @build_context.add( n ) - when :externalentity - n = ExternalEntity.new( event[1] ) - @build_context.add( n ) - when :elementdecl - n = ElementDecl.new( event[1] ) - @build_context.add(n) - when :entitydecl - entities[ event[1] ] = event[2] unless event[2] =~ /PUBLIC|SYSTEM/ - @build_context.add(Entity.new(event)) - when :notationdecl - n = NotationDecl.new( *event[1..-1] ) - @build_context.add( n ) - when :xmldecl - x = XMLDecl.new( event[1], event[2], event[3] ) - @build_context.add( x ) - end - end - rescue REXML::Validation::ValidationException - raise - rescue REXML::ParseException - raise - rescue - raise ParseException.new( $!.message, @parser.source, @parser, $! ) - end - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/ultralightparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/ultralightparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/ultralightparser.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/ultralightparser.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,57 +0,0 @@ -# frozen_string_literal: false -require_relative 'streamparser' -require_relative 'baseparser' - -module REXML - module Parsers - class UltraLightParser - def initialize stream - @stream = stream - @parser = REXML::Parsers::BaseParser.new( stream ) - end - - def add_listener( listener ) - @parser.add_listener( listener ) - end - - def rewind - @stream.rewind - @parser.stream = @stream - end - - def parse - root = context = [] - while true - event = @parser.pull - case event[0] - when :end_document - break - when :end_doctype - context = context[1] - when :start_element, :start_doctype - context << event - event[1,0] = [context] - context = event - when :end_element - context = context[1] - else - context << event - end - end - root - end - end - - # An element is an array. The array contains: - # 0 The parent element - # 1 The tag name - # 2 A hash of attributes - # 3..-1 The child elements - # An element is an array of size > 3 - # Text is a String - # PIs are [ :processing_instruction, target, data ] - # Comments are [ :comment, data ] - # DocTypes are DocType structs - # The root is an array with XMLDecls, Text, DocType, Array, Text - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/xpathparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/xpathparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/xpathparser.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/parsers/xpathparser.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,739 +0,0 @@ -# frozen_string_literal: false - -require_relative '../namespace' -require_relative '../xmltokens' - -module REXML - module Parsers - # You don't want to use this class. Really. Use XPath, which is a wrapper - # for this class. Believe me. You don't want to poke around in here. - # There is strange, dark magic at work in this code. Beware. Go back! Go - # back while you still can! - class XPathParser - include XMLTokens - LITERAL = /^'([^']*)'|^"([^"]*)"/u - - def namespaces=( namespaces ) - Functions::namespace_context = namespaces - @namespaces = namespaces - end - - def parse path - path = path.dup - path.gsub!(/([\(\[])\s+/, '\1') # Strip ignorable spaces - path.gsub!( /\s+([\]\)])/, '\1') - parsed = [] - rest = OrExpr(path, parsed) - if rest - unless rest.strip.empty? - raise ParseException.new("Garbage component exists at the end: " + - "<#{rest}>: <#{path}>") - end - end - parsed - end - - def predicate path - parsed = [] - Predicate( "[#{path}]", parsed ) - parsed - end - - def abbreviate(path_or_parsed) - if path_or_parsed.kind_of?(String) - parsed = parse(path_or_parsed) - else - parsed = path_or_parsed - end - components = [] - component = nil - while parsed.size > 0 - op = parsed.shift - case op - when :node - component << "node()" - when :attribute - component = "@" - components << component - when :child - component = "" - components << component - when :descendant_or_self - next_op = parsed[0] - if next_op == :node - parsed.shift - component = "" - components << component - else - component = "descendant-or-self::" - components << component - end - when :self - next_op = parsed[0] - if next_op == :node - parsed.shift - components << "." - else - component = "self::" - components << component - end - when :parent - next_op = parsed[0] - if next_op == :node - parsed.shift - components << ".." - else - component = "parent::" - components << component - end - when :any - component << "*" - when :text - component << "text()" - when :following, :following_sibling, - :ancestor, :ancestor_or_self, :descendant, - :namespace, :preceding, :preceding_sibling - component = op.to_s.tr("_", "-") << "::" - components << component - when :qname - prefix = parsed.shift - name = parsed.shift - component << prefix+":" if prefix.size > 0 - component << name - when :predicate - component << '[' - component << predicate_to_path(parsed.shift) {|x| abbreviate(x)} - component << ']' - when :document - components << "" - when :function - component << parsed.shift - component << "( " - component << predicate_to_path(parsed.shift[0]) {|x| abbreviate(x)} - component << " )" - when :literal - component << quote_literal(parsed.shift) - else - component << "UNKNOWN(" - component << op.inspect - component << ")" - end - end - case components - when [""] - "/" - when ["", ""] - "//" - else - components.join("/") - end - end - - def expand(path_or_parsed) - if path_or_parsed.kind_of?(String) - parsed = parse(path_or_parsed) - else - parsed = path_or_parsed - end - path = "" - document = false - while parsed.size > 0 - op = parsed.shift - case op - when :node - path << "node()" - when :attribute, :child, :following, :following_sibling, - :ancestor, :ancestor_or_self, :descendant, :descendant_or_self, - :namespace, :preceding, :preceding_sibling, :self, :parent - path << "/" unless path.size == 0 - path << op.to_s.tr("_", "-") - path << "::" - when :any - path << "*" - when :qname - prefix = parsed.shift - name = parsed.shift - path << prefix+":" if prefix.size > 0 - path << name - when :predicate - path << '[' - path << predicate_to_path( parsed.shift ) { |x| expand(x) } - path << ']' - when :document - document = true - else - path << "UNKNOWN(" - path << op.inspect - path << ")" - end - end - path = "/"+path if document - path - end - - def predicate_to_path(parsed, &block) - path = "" - case parsed[0] - when :and, :or, :mult, :plus, :minus, :neq, :eq, :lt, :gt, :lteq, :gteq, :div, :mod, :union - op = parsed.shift - case op - when :eq - op = "=" - when :lt - op = "<" - when :gt - op = ">" - when :lteq - op = "<=" - when :gteq - op = ">=" - when :neq - op = "!=" - when :union - op = "|" - end - left = predicate_to_path( parsed.shift, &block ) - right = predicate_to_path( parsed.shift, &block ) - path << left - path << " " - path << op.to_s - path << " " - path << right - when :function - parsed.shift - name = parsed.shift - path << name - path << "(" - parsed.shift.each_with_index do |argument, i| - path << ", " if i > 0 - path << predicate_to_path(argument, &block) - end - path << ")" - when :literal - parsed.shift - path << quote_literal(parsed.shift) - else - path << yield( parsed ) - end - return path.squeeze(" ") - end - # For backward compatibility - alias_method :preciate_to_string, :predicate_to_path - - private - def quote_literal( literal ) - case literal - when String - # XPath 1.0 does not support escape characters. - # Assumes literal does not contain both single and double quotes. - if literal.include?("'") - "\"#{literal}\"" - else - "'#{literal}'" - end - else - literal.inspect - end - end - - #LocationPath - # | RelativeLocationPath - # | '/' RelativeLocationPath? - # | '//' RelativeLocationPath - def LocationPath path, parsed - path = path.lstrip - if path[0] == ?/ - parsed << :document - if path[1] == ?/ - parsed << :descendant_or_self - parsed << :node - path = path[2..-1] - else - path = path[1..-1] - end - end - return RelativeLocationPath( path, parsed ) if path.size > 0 - end - - #RelativeLocationPath - # | Step - # | (AXIS_NAME '::' | '@' | '') AxisSpecifier - # NodeTest - # Predicate - # | '.' | '..' AbbreviatedStep - # | RelativeLocationPath '/' Step - # | RelativeLocationPath '//' Step - AXIS = /^(ancestor|ancestor-or-self|attribute|child|descendant|descendant-or-self|following|following-sibling|namespace|parent|preceding|preceding-sibling|self)::/ - def RelativeLocationPath path, parsed - loop do - original_path = path - path = path.lstrip - - return original_path if path.empty? - - # (axis or @ or <child::>) nodetest predicate > - # OR > / Step - # (. or ..) > - if path[0] == ?. - if path[1] == ?. - parsed << :parent - parsed << :node - path = path[2..-1] - else - parsed << :self - parsed << :node - path = path[1..-1] - end - else - path_before_axis_specifier = path - parsed_not_abberviated = [] - if path[0] == ?@ - parsed_not_abberviated << :attribute - path = path[1..-1] - # Goto Nodetest - elsif path =~ AXIS - parsed_not_abberviated << $1.tr('-','_').intern - path = $' - # Goto Nodetest - else - parsed_not_abberviated << :child - end - - path_before_node_test = path - path = NodeTest(path, parsed_not_abberviated) - if path == path_before_node_test - return path_before_axis_specifier - end - path = Predicate(path, parsed_not_abberviated) - - parsed.concat(parsed_not_abberviated) - end - - original_path = path - path = path.lstrip - return original_path if path.empty? - - return original_path if path[0] != ?/ - - if path[1] == ?/ - parsed << :descendant_or_self - parsed << :node - path = path[2..-1] - else - path = path[1..-1] - end - end - end - - # Returns a 1-1 map of the nodeset - # The contents of the resulting array are either: - # true/false, if a positive match - # String, if a name match - #NodeTest - # | ('*' | NCNAME ':' '*' | QNAME) NameTest - # | '*' ':' NCNAME NameTest since XPath 2.0 - # | NODE_TYPE '(' ')' NodeType - # | PI '(' LITERAL ')' PI - # | '[' expr ']' Predicate - PREFIX_WILDCARD = /^\*:(#{NCNAME_STR})/u - LOCAL_NAME_WILDCARD = /^(#{NCNAME_STR}):\*/u - QNAME = Namespace::NAMESPLIT - NODE_TYPE = /^(comment|text|node)\(\s*\)/m - PI = /^processing-instruction\(/ - def NodeTest path, parsed - original_path = path - path = path.lstrip - case path - when PREFIX_WILDCARD - prefix = nil - name = $1 - path = $' - parsed << :qname - parsed << prefix - parsed << name - when /^\*/ - path = $' - parsed << :any - when NODE_TYPE - type = $1 - path = $' - parsed << type.tr('-', '_').intern - when PI - path = $' - literal = nil - if path =~ /^\s*\)/ - path = $' - else - path =~ LITERAL - literal = $1 - path = $' - raise ParseException.new("Missing ')' after processing instruction") if path[0] != ?) - path = path[1..-1] - end - parsed << :processing_instruction - parsed << (literal || '') - when LOCAL_NAME_WILDCARD - prefix = $1 - path = $' - parsed << :namespace - parsed << prefix - when QNAME - prefix = $1 - name = $2 - path = $' - prefix = "" unless prefix - parsed << :qname - parsed << prefix - parsed << name - else - path = original_path - end - return path - end - - # Filters the supplied nodeset on the predicate(s) - def Predicate path, parsed - original_path = path - path = path.lstrip - return original_path unless path[0] == ?[ - predicates = [] - while path[0] == ?[ - path, expr = get_group(path) - predicates << expr[1..-2] if expr - end - predicates.each{ |pred| - preds = [] - parsed << :predicate - parsed << preds - OrExpr(pred, preds) - } - path - end - - # The following return arrays of true/false, a 1-1 mapping of the - # supplied nodeset, except for axe(), which returns a filtered - # nodeset - - #| OrExpr S 'or' S AndExpr - #| AndExpr - def OrExpr path, parsed - n = [] - rest = AndExpr( path, n ) - if rest != path - while rest =~ /^\s*( or )/ - n = [ :or, n, [] ] - rest = AndExpr( $', n[-1] ) - end - end - if parsed.size == 0 and n.size != 0 - parsed.replace(n) - elsif n.size > 0 - parsed << n - end - rest - end - - #| AndExpr S 'and' S EqualityExpr - #| EqualityExpr - def AndExpr path, parsed - n = [] - rest = EqualityExpr( path, n ) - if rest != path - while rest =~ /^\s*( and )/ - n = [ :and, n, [] ] - rest = EqualityExpr( $', n[-1] ) - end - end - if parsed.size == 0 and n.size != 0 - parsed.replace(n) - elsif n.size > 0 - parsed << n - end - rest - end - - #| EqualityExpr ('=' | '!=') RelationalExpr - #| RelationalExpr - def EqualityExpr path, parsed - n = [] - rest = RelationalExpr( path, n ) - if rest != path - while rest =~ /^\s*(!?=)\s*/ - if $1[0] == ?! - n = [ :neq, n, [] ] - else - n = [ :eq, n, [] ] - end - rest = RelationalExpr( $', n[-1] ) - end - end - if parsed.size == 0 and n.size != 0 - parsed.replace(n) - elsif n.size > 0 - parsed << n - end - rest - end - - #| RelationalExpr ('<' | '>' | '<=' | '>=') AdditiveExpr - #| AdditiveExpr - def RelationalExpr path, parsed - n = [] - rest = AdditiveExpr( path, n ) - if rest != path - while rest =~ /^\s*([<>]=?)\s*/ - if $1[0] == ?< - sym = "lt" - else - sym = "gt" - end - sym << "eq" if $1[-1] == ?= - n = [ sym.intern, n, [] ] - rest = AdditiveExpr( $', n[-1] ) - end - end - if parsed.size == 0 and n.size != 0 - parsed.replace(n) - elsif n.size > 0 - parsed << n - end - rest - end - - #| AdditiveExpr ('+' | '-') MultiplicativeExpr - #| MultiplicativeExpr - def AdditiveExpr path, parsed - n = [] - rest = MultiplicativeExpr( path, n ) - if rest != path - while rest =~ /^\s*(\+|-)\s*/ - if $1[0] == ?+ - n = [ :plus, n, [] ] - else - n = [ :minus, n, [] ] - end - rest = MultiplicativeExpr( $', n[-1] ) - end - end - if parsed.size == 0 and n.size != 0 - parsed.replace(n) - elsif n.size > 0 - parsed << n - end - rest - end - - #| MultiplicativeExpr ('*' | S ('div' | 'mod') S) UnaryExpr - #| UnaryExpr - def MultiplicativeExpr path, parsed - n = [] - rest = UnaryExpr( path, n ) - if rest != path - while rest =~ /^\s*(\*| div | mod )\s*/ - if $1[0] == ?* - n = [ :mult, n, [] ] - elsif $1.include?( "div" ) - n = [ :div, n, [] ] - else - n = [ :mod, n, [] ] - end - rest = UnaryExpr( $', n[-1] ) - end - end - if parsed.size == 0 and n.size != 0 - parsed.replace(n) - elsif n.size > 0 - parsed << n - end - rest - end - - #| '-' UnaryExpr - #| UnionExpr - def UnaryExpr path, parsed - path =~ /^(\-*)/ - path = $' - if $1 and (($1.size % 2) != 0) - mult = -1 - else - mult = 1 - end - parsed << :neg if mult < 0 - - n = [] - path = UnionExpr( path, n ) - parsed.concat( n ) - path - end - - #| UnionExpr '|' PathExpr - #| PathExpr - def UnionExpr path, parsed - n = [] - rest = PathExpr( path, n ) - if rest != path - while rest =~ /^\s*(\|)\s*/ - n = [ :union, n, [] ] - rest = PathExpr( $', n[-1] ) - end - end - if parsed.size == 0 and n.size != 0 - parsed.replace( n ) - elsif n.size > 0 - parsed << n - end - rest - end - - #| LocationPath - #| FilterExpr ('/' | '//') RelativeLocationPath - def PathExpr path, parsed - path = path.lstrip - n = [] - rest = FilterExpr( path, n ) - if rest != path - if rest and rest[0] == ?/ - rest = RelativeLocationPath(rest, n) - parsed.concat(n) - return rest - end - end - rest = LocationPath(rest, n) if rest =~ /\A[\/\.\@\[\w*]/ - parsed.concat(n) - return rest - end - - #| FilterExpr Predicate - #| PrimaryExpr - def FilterExpr path, parsed - n = [] - path_before_primary_expr = path - path = PrimaryExpr(path, n) - return path_before_primary_expr if path == path_before_primary_expr - path = Predicate(path, n) - parsed.concat(n) - path - end - - #| VARIABLE_REFERENCE - #| '(' expr ')' - #| LITERAL - #| NUMBER - #| FunctionCall - VARIABLE_REFERENCE = /^\$(#{NAME_STR})/u - NUMBER = /^(\d*\.?\d+)/ - NT = /^comment|text|processing-instruction|node$/ - def PrimaryExpr path, parsed - case path - when VARIABLE_REFERENCE - varname = $1 - path = $' - parsed << :variable - parsed << varname - #arry << @variables[ varname ] - when /^(\w[-\w]*)(?:\()/ - fname = $1 - tmp = $' - return path if fname =~ NT - path = tmp - parsed << :function - parsed << fname - path = FunctionCall(path, parsed) - when NUMBER - varname = $1.nil? ? $2 : $1 - path = $' - parsed << :literal - parsed << (varname.include?('.') ? varname.to_f : varname.to_i) - when LITERAL - varname = $1.nil? ? $2 : $1 - path = $' - parsed << :literal - parsed << varname - when /^\(/ #/ - path, contents = get_group(path) - contents = contents[1..-2] - n = [] - OrExpr( contents, n ) - parsed.concat(n) - end - path - end - - #| FUNCTION_NAME '(' ( expr ( ',' expr )* )? ')' - def FunctionCall rest, parsed - path, arguments = parse_args(rest) - argset = [] - for argument in arguments - args = [] - OrExpr( argument, args ) - argset << args - end - parsed << argset - path - end - - # get_group( '[foo]bar' ) -> ['bar', '[foo]'] - def get_group string - ind = 0 - depth = 0 - st = string[0,1] - en = (st == "(" ? ")" : "]") - begin - case string[ind,1] - when st - depth += 1 - when en - depth -= 1 - end - ind += 1 - end while depth > 0 and ind < string.length - return nil unless depth==0 - [string[ind..-1], string[0..ind-1]] - end - - def parse_args( string ) - arguments = [] - ind = 0 - inquot = false - inapos = false - depth = 1 - begin - case string[ind] - when ?" - inquot = !inquot unless inapos - when ?' - inapos = !inapos unless inquot - else - unless inquot or inapos - case string[ind] - when ?( - depth += 1 - if depth == 1 - string = string[1..-1] - ind -= 1 - end - when ?) - depth -= 1 - if depth == 0 - s = string[0,ind].strip - arguments << s unless s == "" - string = string[ind+1..-1] - end - when ?, - if depth == 1 - s = string[0,ind].strip - arguments << s unless s == "" - string = string[ind+1..-1] - ind = -1 - end - end - end - end - ind += 1 - end while depth > 0 and ind < string.length - return nil unless depth==0 - [string,arguments] - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/quickpath.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/quickpath.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/quickpath.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/quickpath.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,266 +0,0 @@ -# frozen_string_literal: false -require_relative 'functions' -require_relative 'xmltokens' - -module REXML - class QuickPath - include Functions - include XMLTokens - - # A base Hash object to be used when initializing a - # default empty namespaces set. - EMPTY_HASH = {} - - def QuickPath::first element, path, namespaces=EMPTY_HASH - match(element, path, namespaces)[0] - end - - def QuickPath::each element, path, namespaces=EMPTY_HASH, &block - path = "*" unless path - match(element, path, namespaces).each( &block ) - end - - def QuickPath::match element, path, namespaces=EMPTY_HASH - raise "nil is not a valid xpath" unless path - results = nil - Functions::namespace_context = namespaces - case path - when /^\/([^\/]|$)/u - # match on root - path = path[1..-1] - return [element.root.parent] if path == '' - results = filter([element.root], path) - when /^[-\w]*::/u - results = filter([element], path) - when /^\*/u - results = filter(element.to_a, path) - when /^[\[!\w:]/u - # match on child - children = element.to_a - results = filter(children, path) - else - results = filter([element], path) - end - return results - end - - # Given an array of nodes it filters the array based on the path. The - # result is that when this method returns, the array will contain elements - # which match the path - def QuickPath::filter elements, path - return elements if path.nil? or path == '' or elements.size == 0 - case path - when /^\/\//u # Descendant - return axe( elements, "descendant-or-self", $' ) - when /^\/?\b(\w[-\w]*)\b::/u # Axe - return axe( elements, $1, $' ) - when /^\/(?=\b([:!\w][-\.\w]*:)?[-!\*\.\w]*\b([^:(]|$)|\*)/u # Child - rest = $' - results = [] - elements.each do |element| - results |= filter( element.to_a, rest ) - end - return results - when /^\/?(\w[-\w]*)\(/u # / Function - return function( elements, $1, $' ) - when Namespace::NAMESPLIT # Element name - name = $2 - ns = $1 - rest = $' - elements.delete_if do |element| - !(element.kind_of? Element and - (element.expanded_name == name or - (element.name == name and - element.namespace == Functions.namespace_context[ns]))) - end - return filter( elements, rest ) - when /^\/\[/u - matches = [] - elements.each do |element| - matches |= predicate( element.to_a, path[1..-1] ) if element.kind_of? Element - end - return matches - when /^\[/u # Predicate - return predicate( elements, path ) - when /^\/?\.\.\./u # Ancestor - return axe( elements, "ancestor", $' ) - when /^\/?\.\./u # Parent - return filter( elements.collect{|e|e.parent}, $' ) - when /^\/?\./u # Self - return filter( elements, $' ) - when /^\*/u # Any - results = [] - elements.each do |element| - results |= filter( [element], $' ) if element.kind_of? Element - #if element.kind_of? Element - # children = element.to_a - # children.delete_if { |child| !child.kind_of?(Element) } - # results |= filter( children, $' ) - #end - end - return results - end - return [] - end - - def QuickPath::axe( elements, axe_name, rest ) - matches = [] - matches = filter( elements.dup, rest ) if axe_name =~ /-or-self$/u - case axe_name - when /^descendant/u - elements.each do |element| - matches |= filter( element.to_a, "descendant-or-self::#{rest}" ) if element.kind_of? Element - end - when /^ancestor/u - elements.each do |element| - while element.parent - matches << element.parent - element = element.parent - end - end - matches = filter( matches, rest ) - when "self" - matches = filter( elements, rest ) - when "child" - elements.each do |element| - matches |= filter( element.to_a, rest ) if element.kind_of? Element - end - when "attribute" - elements.each do |element| - matches << element.attributes[ rest ] if element.kind_of? Element - end - when "parent" - matches = filter(elements.collect{|element| element.parent}.uniq, rest) - when "following-sibling" - matches = filter(elements.collect{|element| element.next_sibling}.uniq, - rest) - when "previous-sibling" - matches = filter(elements.collect{|element| - element.previous_sibling}.uniq, rest ) - end - return matches.uniq - end - - OPERAND_ = '((?=(?:(?!and|or).)*[^\s<>=])[^\s<>=]+)' - # A predicate filters a node-set with respect to an axis to produce a - # new node-set. For each node in the node-set to be filtered, the - # PredicateExpr is evaluated with that node as the context node, with - # the number of nodes in the node-set as the context size, and with the - # proximity position of the node in the node-set with respect to the - # axis as the context position; if PredicateExpr evaluates to true for - # that node, the node is included in the new node-set; otherwise, it is - # not included. - # - # A PredicateExpr is evaluated by evaluating the Expr and converting - # the result to a boolean. If the result is a number, the result will - # be converted to true if the number is equal to the context position - # and will be converted to false otherwise; if the result is not a - # number, then the result will be converted as if by a call to the - # boolean function. Thus a location path para[3] is equivalent to - # para[position()=3]. - def QuickPath::predicate( elements, path ) - ind = 1 - bcount = 1 - while bcount > 0 - bcount += 1 if path[ind] == ?[ - bcount -= 1 if path[ind] == ?] - ind += 1 - end - ind -= 1 - predicate = path[1..ind-1] - rest = path[ind+1..-1] - - # have to change 'a [=<>] b [=<>] c' into 'a [=<>] b and b [=<>] c' - # - predicate.gsub!( - /#{OPERAND_}\s*([<>=])\s*#{OPERAND_}\s*([<>=])\s*#{OPERAND_}/u, - '\1 \2 \3 and \3 \4 \5' ) - # Let's do some Ruby trickery to avoid some work: - predicate.gsub!( /&/u, "&&" ) - predicate.gsub!( /=/u, "==" ) - predicate.gsub!( /@(\w[-\w.]*)/u, 'attribute("\1")' ) - predicate.gsub!( /\bmod\b/u, "%" ) - predicate.gsub!( /\b(\w[-\w.]*\()/u ) { - fname = $1 - fname.gsub( /-/u, "_" ) - } - - Functions.pair = [ 0, elements.size ] - results = [] - elements.each do |element| - Functions.pair[0] += 1 - Functions.node = element - res = eval( predicate ) - case res - when true - results << element - when Integer - results << element if Functions.pair[0] == res - when String - results << element - end - end - return filter( results, rest ) - end - - def QuickPath::attribute( name ) - return Functions.node.attributes[name] if Functions.node.kind_of? Element - end - - def QuickPath::name() - return Functions.node.name if Functions.node.kind_of? Element - end - - def QuickPath::method_missing( id, *args ) - begin - Functions.send( id.id2name, *args ) - rescue Exception - raise "METHOD: #{id.id2name}(#{args.join ', '})\n#{$!.message}" - end - end - - def QuickPath::function( elements, fname, rest ) - args = parse_args( elements, rest ) - Functions.pair = [0, elements.size] - results = [] - elements.each do |element| - Functions.pair[0] += 1 - Functions.node = element - res = Functions.send( fname, *args ) - case res - when true - results << element - when Integer - results << element if Functions.pair[0] == res - end - end - return results - end - - def QuickPath::parse_args( element, string ) - # /.*?(?:\)|,)/ - arguments = [] - buffer = "" - while string and string != "" - c = string[0] - string.sub!(/^./u, "") - case c - when ?, - # if depth = 1, then we start a new argument - arguments << evaluate( buffer ) - #arguments << evaluate( string[0..count] ) - when ?( - # start a new method call - function( element, buffer, string ) - buffer = "" - when ?) - # close the method call and return arguments - return arguments - else - buffer << c - end - end - "" - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/rexml.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/rexml.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/rexml.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/rexml.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,39 +0,0 @@ -# -*- coding: utf-8 -*- -# frozen_string_literal: false -# -# \Module \REXML provides classes and methods for parsing, -# editing, and generating XML. -# -# == Implementation -# -# \REXML: -# - Is pure Ruby. -# - Provides tree, stream, SAX2, pull, and lightweight APIs. -# - Conforms to {XML version 1.0}[https://www.w3.org/TR/REC-xml/]. -# - Fully implements {XPath version 1.0}[http://www.w3c.org/tr/xpath]. -# - Is {non-validating}[https://www.w3.org/TR/xml/]. -# - Passes 100% of the non-validating {Oasis tests}[http://www.oasis-open.org/committees/xml-conformance/xml-test-suite.shtml]. -# -# == In a Hurry? -# -# If you're somewhat familiar with XML -# and have a particular task in mind, -# you may want to see {the tasks pages}[doc/rexml/tasks/tocs/master_toc_rdoc.html]. -# -# == API -# -# Among the most important classes for using \REXML are: -# - REXML::Document. -# - REXML::Element. -# -# There's also an {REXML tutorial}[doc/rexml/tutorial_rdoc.html]. -# -module REXML - COPYRIGHT = "Copyright © 2001-2008 Sean Russell <ser@germane-software.com>" - DATE = "2008/019" - VERSION = "3.3.9" - REVISION = "" - - Copyright = COPYRIGHT - Version = VERSION -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/sax2listener.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/sax2listener.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/sax2listener.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/sax2listener.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,98 +0,0 @@ -# frozen_string_literal: false -module REXML - # A template for stream parser listeners. - # Note that the declarations (attlistdecl, elementdecl, etc) are trivially - # processed; REXML doesn't yet handle doctype entity declarations, so you - # have to parse them out yourself. - # === Missing methods from SAX2 - # ignorable_whitespace - # === Methods extending SAX2 - # +WARNING+ - # These methods are certainly going to change, until DTDs are fully - # supported. Be aware of this. - # start_document - # end_document - # doctype - # elementdecl - # attlistdecl - # entitydecl - # notationdecl - # cdata - # xmldecl - # comment - module SAX2Listener - def start_document - end - def end_document - end - def start_prefix_mapping prefix, uri - end - def end_prefix_mapping prefix - end - def start_element uri, localname, qname, attributes - end - def end_element uri, localname, qname - end - def characters text - end - def processing_instruction target, data - end - # Handles a doctype declaration. Any attributes of the doctype which are - # not supplied will be nil. # EG, <!DOCTYPE me PUBLIC "foo" "bar"> - # @p name the name of the doctype; EG, "me" - # @p pub_sys "PUBLIC", "SYSTEM", or nil. EG, "PUBLIC" - # @p long_name the supplied long name, or nil. EG, "foo" - # @p uri the uri of the doctype, or nil. EG, "bar" - def doctype name, pub_sys, long_name, uri - end - # If a doctype includes an ATTLIST declaration, it will cause this - # method to be called. The content is the declaration itself, unparsed. - # EG, <!ATTLIST el attr CDATA #REQUIRED> will come to this method as "el - # attr CDATA #REQUIRED". This is the same for all of the .*decl - # methods. - def attlistdecl(element, pairs, contents) - end - # <!ELEMENT ...> - def elementdecl content - end - # <!ENTITY ...> - # The argument passed to this method is an array of the entity - # declaration. It can be in a number of formats, but in general it - # returns (example, result): - # <!ENTITY % YN '"Yes"'> - # ["%", "YN", "\"Yes\""] - # <!ENTITY % YN 'Yes'> - # ["%", "YN", "Yes"] - # <!ENTITY WhatHeSaid "He said %YN;"> - # ["WhatHeSaid", "He said %YN;"] - # <!ENTITY open-hatch SYSTEM "http://www.textuality.com/boilerplate/OpenHatch.xml"> - # ["open-hatch", "SYSTEM", "http://www.textuality.com/boilerplate/OpenHatch.xml"] - # <!ENTITY open-hatch PUBLIC "-//Textuality//TEXT Standard open-hatch boilerplate//EN" "http://www.textuality.com/boilerplate/OpenHatch.xml"> - # ["open-hatch", "PUBLIC", "-//Textuality//TEXT Standard open-hatch boilerplate//EN", "http://www.textuality.com/boilerplate/OpenHatch.xml"] - # <!ENTITY hatch-pic SYSTEM "../grafix/OpenHatch.gif" NDATA gif> - # ["hatch-pic", "SYSTEM", "../grafix/OpenHatch.gif", "NDATA", "gif"] - def entitydecl declaration - end - # <!NOTATION ...> - def notationdecl name, public_or_system, public_id, system_id - end - # Called when <![CDATA[ ... ]]> is encountered in a document. - # @p content "..." - def cdata content - end - # Called when an XML PI is encountered in the document. - # EG: <?xml version="1.0" encoding="utf"?> - # @p version the version attribute value. EG, "1.0" - # @p encoding the encoding attribute value, or nil. EG, "utf" - # @p standalone the standalone attribute value, or nil. EG, nil - # @p spaced the declaration is followed by a line break - def xmldecl version, encoding, standalone - end - # Called when a comment is encountered. - # @p comment The content of the comment - def comment comment - end - def progress position - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/security.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/security.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/security.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/security.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,28 +0,0 @@ -# frozen_string_literal: false -module REXML - module Security - @@entity_expansion_limit = 10_000 - - # Set the entity expansion limit. By default the limit is set to 10000. - def self.entity_expansion_limit=( val ) - @@entity_expansion_limit = val - end - - # Get the entity expansion limit. By default the limit is set to 10000. - def self.entity_expansion_limit - return @@entity_expansion_limit - end - - @@entity_expansion_text_limit = 10_240 - - # Set the entity expansion limit. By default the limit is set to 10240. - def self.entity_expansion_text_limit=( val ) - @@entity_expansion_text_limit = val - end - - # Get the entity expansion limit. By default the limit is set to 10240. - def self.entity_expansion_text_limit - return @@entity_expansion_text_limit - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/source.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/source.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/source.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/source.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,334 +0,0 @@ -# coding: US-ASCII -# frozen_string_literal: false - -require "strscan" - -require_relative 'encoding' - -module REXML - if StringScanner::Version < "1.0.0" - module StringScannerCheckScanString - refine StringScanner do - def check(pattern) - pattern = /#{Regexp.escape(pattern)}/ if pattern.is_a?(String) - super(pattern) - end - - def scan(pattern) - pattern = /#{Regexp.escape(pattern)}/ if pattern.is_a?(String) - super(pattern) - end - end - end - using StringScannerCheckScanString - end - - # Generates Source-s. USE THIS CLASS. - class SourceFactory - # Generates a Source object - # @param arg Either a String, or an IO - # @return a Source, or nil if a bad argument was given - def SourceFactory::create_from(arg) - if arg.respond_to? :read and - arg.respond_to? :readline and - arg.respond_to? :nil? and - arg.respond_to? :eof? - IOSource.new(arg) - elsif arg.respond_to? :to_str - require 'stringio' - IOSource.new(StringIO.new(arg)) - elsif arg.kind_of? Source - arg - else - raise "#{arg.class} is not a valid input stream. It must walk \n"+ - "like either a String, an IO, or a Source." - end - end - end - - # A Source can be searched for patterns, and wraps buffers and other - # objects and provides consumption of text - class Source - include Encoding - # The line number of the last consumed text - attr_reader :line - attr_reader :encoding - - module Private - SCANNER_RESET_SIZE = 100000 - PRE_DEFINED_TERM_PATTERNS = {} - pre_defined_terms = ["'", '"', "<"] - pre_defined_terms.each do |term| - PRE_DEFINED_TERM_PATTERNS[term] = /#{Regexp.escape(term)}/ - end - end - private_constant :Private - - # Constructor - # @param arg must be a String, and should be a valid XML document - # @param encoding if non-null, sets the encoding of the source to this - # value, overriding all encoding detection - def initialize(arg, encoding=nil) - @orig = arg - @scanner = StringScanner.new(@orig) - if encoding - self.encoding = encoding - else - detect_encoding - end - @line = 0 - @term_encord = {} - end - - # The current buffer (what we're going to read next) - def buffer - @scanner.rest - end - - def drop_parsed_content - if @scanner.pos > Private::SCANNER_RESET_SIZE - @scanner.string = @scanner.rest - end - end - - def buffer_encoding=(encoding) - @scanner.string.force_encoding(encoding) - end - - # Inherited from Encoding - # Overridden to support optimized en/decoding - def encoding=(enc) - return unless super - encoding_updated - end - - def read(term = nil) - end - - def read_until(term) - pattern = Private::PRE_DEFINED_TERM_PATTERNS[term] || /#{Regexp.escape(term)}/ - data = @scanner.scan_until(pattern) - unless data - data = @scanner.rest - @scanner.pos = @scanner.string.bytesize - end - data - end - - def ensure_buffer - end - - def match(pattern, cons=false) - if cons - @scanner.scan(pattern).nil? ? nil : @scanner - else - @scanner.check(pattern).nil? ? nil : @scanner - end - end - - def position - @scanner.pos - end - - def position=(pos) - @scanner.pos = pos - end - - # @return true if the Source is exhausted - def empty? - @scanner.eos? - end - - # @return the current line in the source - def current_line - lines = @orig.split - res = lines.grep @scanner.rest[0..30] - res = res[-1] if res.kind_of? Array - lines.index( res ) if res - end - - private - - def detect_encoding - scanner_encoding = @scanner.rest.encoding - detected_encoding = "UTF-8" - begin - @scanner.string.force_encoding("ASCII-8BIT") - if @scanner.scan(/\xfe\xff/n) - detected_encoding = "UTF-16BE" - elsif @scanner.scan(/\xff\xfe/n) - detected_encoding = "UTF-16LE" - elsif @scanner.scan(/\xef\xbb\xbf/n) - detected_encoding = "UTF-8" - end - ensure - @scanner.string.force_encoding(scanner_encoding) - end - self.encoding = detected_encoding - end - - def encoding_updated - if @encoding != 'UTF-8' - @scanner.string = decode(@scanner.rest) - @to_utf = true - else - @to_utf = false - @scanner.string.force_encoding(::Encoding::UTF_8) - end - end - end - - # A Source that wraps an IO. See the Source class for method - # documentation - class IOSource < Source - #attr_reader :block_size - - # block_size has been deprecated - def initialize(arg, block_size=500, encoding=nil) - @er_source = @source = arg - @to_utf = false - @pending_buffer = nil - - if encoding - super("", encoding) - else - super(@source.read(3) || "") - end - - if !@to_utf and - @orig.respond_to?(:force_encoding) and - @source.respond_to?(:external_encoding) and - @source.external_encoding != ::Encoding::UTF_8 - @force_utf8 = true - else - @force_utf8 = false - end - end - - def read(term = nil, min_bytes = 1) - term = encode(term) if term - begin - str = readline(term) - @scanner << str - read_bytes = str.bytesize - begin - while read_bytes < min_bytes - str = readline(term) - @scanner << str - read_bytes += str.bytesize - end - rescue IOError - end - true - rescue Exception, NameError - @source = nil - false - end - end - - def read_until(term) - pattern = Private::PRE_DEFINED_TERM_PATTERNS[term] || /#{Regexp.escape(term)}/ - term = @term_encord[term] ||= encode(term) - until str = @scanner.scan_until(pattern) - break if @source.nil? - break if @source.eof? - @scanner << readline(term) - end - if str - read if @scanner.eos? and !@source.eof? - str - else - rest = @scanner.rest - @scanner.pos = @scanner.string.bytesize - rest - end - end - - def ensure_buffer - read if @scanner.eos? && @source - end - - def match( pattern, cons=false ) - # To avoid performance issue, we need to increase bytes to read per scan - min_bytes = 1 - while true - if cons - md = @scanner.scan(pattern) - else - md = @scanner.check(pattern) - end - break if md - return nil if pattern.is_a?(String) - return nil if @source.nil? - return nil unless read(nil, min_bytes) - min_bytes *= 2 - end - - md.nil? ? nil : @scanner - end - - def empty? - super and ( @source.nil? || @source.eof? ) - end - - # @return the current line in the source - def current_line - begin - pos = @er_source.pos # The byte position in the source - lineno = @er_source.lineno # The XML < position in the source - @er_source.rewind - line = 0 # The \r\n position in the source - begin - while @er_source.pos < pos - @er_source.readline - line += 1 - end - rescue - end - @er_source.seek(pos) - rescue IOError - pos = -1 - line = -1 - end - [pos, lineno, line] - end - - private - def readline(term = nil) - if @pending_buffer - begin - str = @source.readline(term || @line_break) - rescue IOError - end - if str.nil? - str = @pending_buffer - else - str = @pending_buffer + str - end - @pending_buffer = nil - else - str = @source.readline(term || @line_break) - end - return nil if str.nil? - - if @to_utf - decode(str) - else - str.force_encoding(::Encoding::UTF_8) if @force_utf8 - str - end - end - - def encoding_updated - case @encoding - when "UTF-16BE", "UTF-16LE" - @source.binmode - @source.set_encoding(@encoding, @encoding) - end - @line_break = encode(">") - @pending_buffer, @scanner.string = @scanner.rest, "" - @pending_buffer.force_encoding(@encoding) - super - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/streamlistener.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/streamlistener.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/streamlistener.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/streamlistener.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,93 +0,0 @@ -# frozen_string_literal: false -module REXML - # A template for stream parser listeners. - # Note that the declarations (attlistdecl, elementdecl, etc) are trivially - # processed; REXML doesn't yet handle doctype entity declarations, so you - # have to parse them out yourself. - module StreamListener - # Called when a tag is encountered. - # @p name the tag name - # @p attrs an array of arrays of attribute/value pairs, suitable for - # use with assoc or rassoc. IE, <tag attr1="value1" attr2="value2"> - # will result in - # tag_start( "tag", # [["attr1","value1"],["attr2","value2"]]) - def tag_start name, attrs - end - # Called when the end tag is reached. In the case of <tag/>, tag_end - # will be called immediately after tag_start - # @p the name of the tag - def tag_end name - end - # Called when text is encountered in the document - # @p text the text content. - def text text - end - # Called when an instruction is encountered. EG: <?xsl sheet='foo'?> - # @p name the instruction name; in the example, "xsl" - # @p instruction the rest of the instruction. In the example, - # "sheet='foo'" - def instruction name, instruction - end - # Called when a comment is encountered. - # @p comment The content of the comment - def comment comment - end - # Handles a doctype declaration. Any attributes of the doctype which are - # not supplied will be nil. # EG, <!DOCTYPE me PUBLIC "foo" "bar"> - # @p name the name of the doctype; EG, "me" - # @p pub_sys "PUBLIC", "SYSTEM", or nil. EG, "PUBLIC" - # @p long_name the supplied long name, or nil. EG, "foo" - # @p uri the uri of the doctype, or nil. EG, "bar" - def doctype name, pub_sys, long_name, uri - end - # Called when the doctype is done - def doctype_end - end - # If a doctype includes an ATTLIST declaration, it will cause this - # method to be called. The content is the declaration itself, unparsed. - # EG, <!ATTLIST el attr CDATA #REQUIRED> will come to this method as "el - # attr CDATA #REQUIRED". This is the same for all of the .*decl - # methods. - def attlistdecl element_name, attributes, raw_content - end - # <!ELEMENT ...> - def elementdecl content - end - # <!ENTITY ...> - # The argument passed to this method is an array of the entity - # declaration. It can be in a number of formats, but in general it - # returns (example, result): - # <!ENTITY % YN '"Yes"'> - # ["YN", "\"Yes\"", "%"] - # <!ENTITY % YN 'Yes'> - # ["YN", "Yes", "%"] - # <!ENTITY WhatHeSaid "He said %YN;"> - # ["WhatHeSaid", "He said %YN;"] - # <!ENTITY open-hatch SYSTEM "http://www.textuality.com/boilerplate/OpenHatch.xml"> - # ["open-hatch", "SYSTEM", "http://www.textuality.com/boilerplate/OpenHatch.xml"] - # <!ENTITY open-hatch PUBLIC "-//Textuality//TEXT Standard open-hatch boilerplate//EN" "http://www.textuality.com/boilerplate/OpenHatch.xml"> - # ["open-hatch", "PUBLIC", "-//Textuality//TEXT Standard open-hatch boilerplate//EN", "http://www.textuality.com/boilerplate/OpenHatch.xml"] - # <!ENTITY hatch-pic SYSTEM "../grafix/OpenHatch.gif" NDATA gif> - # ["hatch-pic", "SYSTEM", "../grafix/OpenHatch.gif", "gif"] - def entitydecl content - end - # <!NOTATION ...> - def notationdecl content - end - # Called when %foo; is encountered in a doctype declaration. - # @p content "foo" - def entity content - end - # Called when <![CDATA[ ... ]]> is encountered in a document. - # @p content "..." - def cdata content - end - # Called when an XML PI is encountered in the document. - # EG: <?xml version="1.0" encoding="utf"?> - # @p version the version attribute value. EG, "1.0" - # @p encoding the encoding attribute value, or nil. EG, "utf" - # @p standalone the standalone attribute value, or nil. EG, nil - def xmldecl version, encoding, standalone - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/text.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/text.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/text.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/text.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,448 +0,0 @@ -# frozen_string_literal: true -require_relative 'security' -require_relative 'entity' -require_relative 'doctype' -require_relative 'child' -require_relative 'doctype' -require_relative 'parseexception' - -module REXML - # Represents text nodes in an XML document - class Text < Child - include Comparable - # The order in which the substitutions occur - SPECIALS = [ /&(?!#?[\w-]+;)/u, /</u, />/u, /"/u, /'/u, /\r/u ] - SUBSTITUTES = ['&', '<', '>', '"', ''', ' '] - # Characters which are substituted in written strings - SLAICEPS = [ '<', '>', '"', "'", '&' ] - SETUTITSBUS = [ /</u, />/u, /"/u, /'/u, /&/u ] - - # If +raw+ is true, then REXML leaves the value alone - attr_accessor :raw - - NEEDS_A_SECOND_CHECK = /(<|&((#{Entity::NAME});|(#0*((?:\d+)|(?:x[a-fA-F0-9]+)));)?)/um - NUMERICENTITY = /�*((?:\d+)|(?:x[a-fA-F0-9]+));/ - VALID_CHAR = [ - 0x9, 0xA, 0xD, - (0x20..0xD7FF), - (0xE000..0xFFFD), - (0x10000..0x10FFFF) - ] - - if String.method_defined? :encode - VALID_XML_CHARS = Regexp.new('^['+ - VALID_CHAR.map { |item| - case item - when Integer - [item].pack('U').force_encoding('utf-8') - when Range - [item.first, '-'.ord, item.last].pack('UUU').force_encoding('utf-8') - end - }.join + - ']*$') - else - VALID_XML_CHARS = /^( - [\x09\x0A\x0D\x20-\x7E] # ASCII - | [\xC2-\xDF][\x80-\xBF] # non-overlong 2-byte - | \xE0[\xA0-\xBF][\x80-\xBF] # excluding overlongs - | [\xE1-\xEC\xEE][\x80-\xBF]{2} # straight 3-byte - | \xEF[\x80-\xBE]{2} # - | \xEF\xBF[\x80-\xBD] # excluding U+fffe and U+ffff - | \xED[\x80-\x9F][\x80-\xBF] # excluding surrogates - | \xF0[\x90-\xBF][\x80-\xBF]{2} # planes 1-3 - | [\xF1-\xF3][\x80-\xBF]{3} # planes 4-15 - | \xF4[\x80-\x8F][\x80-\xBF]{2} # plane 16 - )*$/nx; - end - - # Constructor - # +arg+ if a String, the content is set to the String. If a Text, - # the object is shallowly cloned. - # - # +respect_whitespace+ (boolean, false) if true, whitespace is - # respected - # - # +parent+ (nil) if this is a Parent object, the parent - # will be set to this. - # - # +raw+ (nil) This argument can be given three values. - # If true, then the value of used to construct this object is expected to - # contain no unescaped XML markup, and REXML will not change the text. If - # this value is false, the string may contain any characters, and REXML will - # escape any and all defined entities whose values are contained in the - # text. If this value is nil (the default), then the raw value of the - # parent will be used as the raw value for this node. If there is no raw - # value for the parent, and no value is supplied, the default is false. - # Use this field if you have entities defined for some text, and you don't - # want REXML to escape that text in output. - # Text.new( "<&", false, nil, false ) #-> "<&" - # Text.new( "<&", false, nil, false ) #-> "&lt;&amp;" - # Text.new( "<&", false, nil, true ) #-> Parse exception - # Text.new( "<&", false, nil, true ) #-> "<&" - # # Assume that the entity "s" is defined to be "sean" - # # and that the entity "r" is defined to be "russell" - # Text.new( "sean russell" ) #-> "&s; &r;" - # Text.new( "sean russell", false, nil, true ) #-> "sean russell" - # - # +entity_filter+ (nil) This can be an array of entities to match in the - # supplied text. This argument is only useful if +raw+ is set to false. - # Text.new( "sean russell", false, nil, false, ["s"] ) #-> "&s; russell" - # Text.new( "sean russell", false, nil, true, ["s"] ) #-> "sean russell" - # In the last example, the +entity_filter+ argument is ignored. - # - # +illegal+ INTERNAL USE ONLY - def initialize(arg, respect_whitespace=false, parent=nil, raw=nil, - entity_filter=nil, illegal=NEEDS_A_SECOND_CHECK ) - - @raw = false - @parent = nil - @entity_filter = nil - - if parent - super( parent ) - @raw = parent.raw - end - - if arg.kind_of? String - @string = arg.dup - elsif arg.kind_of? Text - @string = arg.instance_variable_get(:@string).dup - @raw = arg.raw - @entity_filter = arg.instance_variable_get(:@entity_filter) - else - raise "Illegal argument of type #{arg.type} for Text constructor (#{arg})" - end - - @string.squeeze!(" \n\t") unless respect_whitespace - @string.gsub!(/\r\n?/, "\n") - @raw = raw unless raw.nil? - @entity_filter = entity_filter if entity_filter - clear_cache - - Text.check(@string, illegal, doctype) if @raw - end - - def parent= parent - super(parent) - Text.check(@string, NEEDS_A_SECOND_CHECK, doctype) if @raw and @parent - end - - # check for illegal characters - def Text.check string, pattern, doctype - - # illegal anywhere - if !string.match?(VALID_XML_CHARS) - if String.method_defined? :encode - string.chars.each do |c| - case c.ord - when *VALID_CHAR - else - raise "Illegal character #{c.inspect} in raw string #{string.inspect}" - end - end - else - string.scan(/[\x00-\x7F]|[\x80-\xBF][\xC0-\xF0]*|[\xC0-\xF0]/n) do |c| - case c.unpack('U') - when *VALID_CHAR - else - raise "Illegal character #{c.inspect} in raw string #{string.inspect}" - end - end - end - end - - pos = 0 - while (index = string.index(/<|&/, pos)) - if string[index] == "<" - raise "Illegal character \"#{string[index]}\" in raw string #{string.inspect}" - end - - unless (end_index = string.index(/[^\s];/, index + 1)) - raise "Illegal character \"#{string[index]}\" in raw string #{string.inspect}" - end - - value = string[(index + 1)..end_index] - if /\s/.match?(value) - raise "Illegal character \"#{string[index]}\" in raw string #{string.inspect}" - end - - if value[0] == "#" - character_reference = value[1..-1] - - unless (/\A(\d+|x[0-9a-fA-F]+)\z/.match?(character_reference)) - if character_reference[0] == "x" || character_reference[-1] == "x" - raise "Illegal character \"#{string[index]}\" in raw string #{string.inspect}" - else - raise "Illegal character #{string.inspect} in raw string #{string.inspect}" - end - end - - case (character_reference[0] == "x" ? character_reference[1..-1].to_i(16) : character_reference[0..-1].to_i) - when *VALID_CHAR - else - raise "Illegal character #{string.inspect} in raw string #{string.inspect}" - end - elsif !(/\A#{Entity::NAME}\z/um.match?(value)) - raise "Illegal character \"#{string[index]}\" in raw string #{string.inspect}" - end - - pos = end_index + 1 - end - - string - end - - def node_type - :text - end - - def empty? - @string.size==0 - end - - - def clone - return Text.new(self, true) - end - - - # Appends text to this text node. The text is appended in the +raw+ mode - # of this text node. - # - # +returns+ the text itself to enable method chain like - # 'text << "XXX" << "YYY"'. - def <<( to_append ) - @string << to_append.gsub( /\r\n?/, "\n" ) - clear_cache - self - end - - - # +other+ a String or a Text - # +returns+ the result of (to_s <=> arg.to_s) - def <=>( other ) - to_s() <=> other.to_s - end - - def doctype - if @parent - doc = @parent.document - doc.doctype if doc - end - end - - REFERENCE = /#{Entity::REFERENCE}/ - # Returns the string value of this text node. This string is always - # escaped, meaning that it is a valid XML text node string, and all - # entities that can be escaped, have been inserted. This method respects - # the entity filter set in the constructor. - # - # # Assume that the entity "s" is defined to be "sean", and that the - # # entity "r" is defined to be "russell" - # t = Text.new( "< & sean russell", false, nil, false, ['s'] ) - # t.to_s #-> "< & &s; russell" - # t = Text.new( "< & &s; russell", false, nil, false ) - # t.to_s #-> "< & &s; russell" - # u = Text.new( "sean russell", false, nil, true ) - # u.to_s #-> "sean russell" - def to_s - return @string if @raw - @normalized ||= Text::normalize( @string, doctype, @entity_filter ) - end - - def inspect - @string.inspect - end - - # Returns the string value of this text. This is the text without - # entities, as it might be used programmatically, or printed to the - # console. This ignores the 'raw' attribute setting, and any - # entity_filter. - # - # # Assume that the entity "s" is defined to be "sean", and that the - # # entity "r" is defined to be "russell" - # t = Text.new( "< & sean russell", false, nil, false, ['s'] ) - # t.value #-> "< & sean russell" - # t = Text.new( "< & &s; russell", false, nil, false ) - # t.value #-> "< & sean russell" - # u = Text.new( "sean russell", false, nil, true ) - # u.value #-> "sean russell" - def value - @unnormalized ||= Text::unnormalize(@string, doctype, - entity_expansion_text_limit: document&.entity_expansion_text_limit) - end - - # Sets the contents of this text node. This expects the text to be - # unnormalized. It returns self. - # - # e = Element.new( "a" ) - # e.add_text( "foo" ) # <a>foo</a> - # e[0].value = "bar" # <a>bar</a> - # e[0].value = "<a>" # <a><a></a> - def value=( val ) - @string = val.gsub( /\r\n?/, "\n" ) - clear_cache - @raw = false - end - - def wrap(string, width, addnewline=false) - # Recursively wrap string at width. - return string if string.length <= width - place = string.rindex(' ', width) # Position in string with last ' ' before cutoff - if addnewline then - return "\n" + string[0,place] + "\n" + wrap(string[place+1..-1], width) - else - return string[0,place] + "\n" + wrap(string[place+1..-1], width) - end - end - - def indent_text(string, level=1, style="\t", indentfirstline=true) - return string if level < 0 - new_string = '' - string.each_line { |line| - indent_string = style * level - new_line = (indent_string + line).sub(/[\s]+$/,'') - new_string << new_line - } - new_string.strip! unless indentfirstline - return new_string - end - - # == DEPRECATED - # See REXML::Formatters - # - def write( writer, indent=-1, transitive=false, ie_hack=false ) - Kernel.warn("#{self.class.name}.write is deprecated. See REXML::Formatters", uplevel: 1) - formatter = if indent > -1 - REXML::Formatters::Pretty.new( indent ) - else - REXML::Formatters::Default.new - end - formatter.write( self, writer ) - end - - # FIXME - # This probably won't work properly - def xpath - path = @parent.xpath - path += "/text()" - return path - end - - # Writes out text, substituting special characters beforehand. - # +out+ A String, IO, or any other object supporting <<( String ) - # +input+ the text to substitute and the write out - # - # z=utf8.unpack("U*") - # ascOut="" - # z.each{|r| - # if r < 0x100 - # ascOut.concat(r.chr) - # else - # ascOut.concat(sprintf("&#x%x;", r)) - # end - # } - # puts ascOut - def write_with_substitution out, input - copy = input.clone - # Doing it like this rather than in a loop improves the speed - copy.gsub!( SPECIALS[0], SUBSTITUTES[0] ) - copy.gsub!( SPECIALS[1], SUBSTITUTES[1] ) - copy.gsub!( SPECIALS[2], SUBSTITUTES[2] ) - copy.gsub!( SPECIALS[3], SUBSTITUTES[3] ) - copy.gsub!( SPECIALS[4], SUBSTITUTES[4] ) - copy.gsub!( SPECIALS[5], SUBSTITUTES[5] ) - out << copy - end - - private - def clear_cache - @normalized = nil - @unnormalized = nil - end - - # Reads text, substituting entities - def Text::read_with_substitution( input, illegal=nil ) - copy = input.clone - - if copy =~ illegal - raise ParseException.new( "malformed text: Illegal character #$& in \"#{copy}\"" ) - end if illegal - - copy.gsub!( /\r\n?/, "\n" ) - if copy.include? ?& - copy.gsub!( SETUTITSBUS[0], SLAICEPS[0] ) - copy.gsub!( SETUTITSBUS[1], SLAICEPS[1] ) - copy.gsub!( SETUTITSBUS[2], SLAICEPS[2] ) - copy.gsub!( SETUTITSBUS[3], SLAICEPS[3] ) - copy.gsub!( SETUTITSBUS[4], SLAICEPS[4] ) - copy.gsub!( /�*((?:\d+)|(?:x[a-f0-9]+));/ ) { - m=$1 - #m='0' if m=='' - m = "0#{m}" if m[0] == ?x - [Integer(m)].pack('U*') - } - end - copy - end - - EREFERENCE = /&(?!#{Entity::NAME};)/ - # Escapes all possible entities - def Text::normalize( input, doctype=nil, entity_filter=nil ) - copy = input.to_s - # Doing it like this rather than in a loop improves the speed - #copy = copy.gsub( EREFERENCE, '&' ) - copy = copy.gsub( "&", "&" ) if copy.include?("&") - if doctype - # Replace all ampersands that aren't part of an entity - doctype.entities.each_value do |entity| - copy = copy.gsub( entity.value, - "&#{entity.name};" ) if entity.value and - not( entity_filter and entity_filter.include?(entity.name) ) - end - else - # Replace all ampersands that aren't part of an entity - DocType::DEFAULT_ENTITIES.each_value do |entity| - if copy.include?(entity.value) - copy = copy.gsub(entity.value, "&#{entity.name};" ) - end - end - end - copy - end - - # Unescapes all possible entities - def Text::unnormalize( string, doctype=nil, filter=nil, illegal=nil, entity_expansion_text_limit: nil ) - entity_expansion_text_limit ||= Security.entity_expansion_text_limit - sum = 0 - string.gsub( /\r\n?/, "\n" ).gsub( REFERENCE ) { - s = Text.expand($&, doctype, filter) - if sum + s.bytesize > entity_expansion_text_limit - raise "entity expansion has grown too large" - else - sum += s.bytesize - end - s - } - end - - def Text.expand(ref, doctype, filter) - if ref[1] == ?# - if ref[2] == ?x - [ref[3...-1].to_i(16)].pack('U*') - else - [ref[2...-1].to_i].pack('U*') - end - elsif ref == '&' - '&' - elsif filter and filter.include?( ref[1...-1] ) - ref - elsif doctype - doctype.entity( ref[1...-1] ) or ref - else - entity_value = DocType::DEFAULT_ENTITIES[ ref[1...-1] ] - entity_value ? entity_value.value : ref - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/undefinednamespaceexception.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/undefinednamespaceexception.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/undefinednamespaceexception.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/undefinednamespaceexception.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,9 +0,0 @@ -# frozen_string_literal: false -require_relative 'parseexception' -module REXML - class UndefinedNamespaceException < ParseException - def initialize( prefix, source, parser ) - super( "Undefined prefix #{prefix} found" ) - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/validation/relaxng.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/validation/relaxng.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/validation/relaxng.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/validation/relaxng.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,539 +0,0 @@ -# frozen_string_literal: false -require_relative "validation" -require_relative "../parsers/baseparser" - -module REXML - module Validation - # Implemented: - # * empty - # * element - # * attribute - # * text - # * optional - # * choice - # * oneOrMore - # * zeroOrMore - # * group - # * value - # * interleave - # * mixed - # * ref - # * grammar - # * start - # * define - # - # Not implemented: - # * data - # * param - # * include - # * externalRef - # * notAllowed - # * anyName - # * nsName - # * except - # * name - class RelaxNG - include Validator - - INFINITY = 1.0 / 0.0 - EMPTY = Event.new( nil ) - TEXT = [:start_element, "text"] - attr_accessor :current - attr_accessor :count - attr_reader :references - - # FIXME: Namespaces - def initialize source - parser = REXML::Parsers::BaseParser.new( source ) - - @count = 0 - @references = {} - @root = @current = Sequence.new(self) - @root.previous = true - states = [ @current ] - begin - event = parser.pull - case event[0] - when :start_element - case event[1] - when "empty" - when "element", "attribute", "text", "value" - states[-1] << event - when "optional" - states << Optional.new( self ) - states[-2] << states[-1] - when "choice" - states << Choice.new( self ) - states[-2] << states[-1] - when "oneOrMore" - states << OneOrMore.new( self ) - states[-2] << states[-1] - when "zeroOrMore" - states << ZeroOrMore.new( self ) - states[-2] << states[-1] - when "group" - states << Sequence.new( self ) - states[-2] << states[-1] - when "interleave" - states << Interleave.new( self ) - states[-2] << states[-1] - when "mixed" - states << Interleave.new( self ) - states[-2] << states[-1] - states[-1] << TEXT - when "define" - states << [ event[2]["name"] ] - when "ref" - states[-1] << Ref.new( event[2]["name"] ) - when "anyName" - states << AnyName.new( self ) - states[-2] << states[-1] - when "nsName" - when "except" - when "name" - when "data" - when "param" - when "include" - when "grammar" - when "start" - when "externalRef" - when "notAllowed" - end - when :end_element - case event[1] - when "element", "attribute" - states[-1] << event - when "zeroOrMore", "oneOrMore", "choice", "optional", - "interleave", "group", "mixed" - states.pop - when "define" - ref = states.pop - @references[ ref.shift ] = ref - #when "empty" - end - when :end_document - states[-1] << event - when :text - states[-1] << event - end - end while event[0] != :end_document - end - - def receive event - validate( event ) - end - end - - class State - def initialize( context ) - @previous = [] - @events = [] - @current = 0 - @count = context.count += 1 - @references = context.references - @value = false - end - - def reset - return if @current == 0 - @current = 0 - @events.each {|s| s.reset if s.kind_of? State } - end - - def previous=( previous ) - @previous << previous - end - - def next( event ) - #print "In next with #{event.inspect}. " - #p @previous - return @previous.pop.next( event ) if @events[@current].nil? - expand_ref_in( @events, @current ) if @events[@current].class == Ref - if ( @events[@current].kind_of? State ) - @current += 1 - @events[@current-1].previous = self - return @events[@current-1].next( event ) - end - if ( @events[@current].matches?(event) ) - @current += 1 - if @events[@current].nil? - return @previous.pop - elsif @events[@current].kind_of? State - @current += 1 - @events[@current-1].previous = self - return @events[@current-1] - else - return self - end - else - return nil - end - end - - def to_s - # Abbreviated: - self.class.name =~ /(?:::)(\w)\w+$/ - # Full: - #self.class.name =~ /(?:::)(\w+)$/ - "#$1.#@count" - end - - def inspect - "< #{to_s} #{@events.collect{|e| - pre = e == @events[@current] ? '#' : '' - pre + e.inspect unless self == e - }.join(', ')} >" - end - - def expected - return [@events[@current]] - end - - def <<( event ) - add_event_to_arry( @events, event ) - end - - - protected - def expand_ref_in( arry, ind ) - new_events = [] - @references[ arry[ind].to_s ].each{ |evt| - add_event_to_arry(new_events,evt) - } - arry[ind,1] = new_events - end - - def add_event_to_arry( arry, evt ) - evt = generate_event( evt ) - if evt.kind_of? String - arry[-1].event_arg = evt if arry[-1].kind_of? Event and @value - @value = false - else - arry << evt - end - end - - def generate_event( event ) - return event if event.kind_of? State or event.class == Ref - evt = nil - arg = nil - case event[0] - when :start_element - case event[1] - when "element" - evt = :start_element - arg = event[2]["name"] - when "attribute" - evt = :start_attribute - arg = event[2]["name"] - when "text" - evt = :text - when "value" - evt = :text - @value = true - end - when :text - return event[1] - when :end_document - return Event.new( event[0] ) - else # then :end_element - case event[1] - when "element" - evt = :end_element - when "attribute" - evt = :end_attribute - end - end - return Event.new( evt, arg ) - end - end - - - class Sequence < State - def matches?(event) - @events[@current].matches?( event ) - end - end - - - class Optional < State - def next( event ) - if @current == 0 - rv = super - return rv if rv - @prior = @previous.pop - return @prior.next( event ) - end - super - end - - def matches?(event) - @events[@current].matches?(event) || - (@current == 0 and @previous[-1].matches?(event)) - end - - def expected - return [ @prior.expected, @events[0] ].flatten if @current == 0 - return [@events[@current]] - end - end - - - class ZeroOrMore < Optional - def next( event ) - expand_ref_in( @events, @current ) if @events[@current].class == Ref - if ( @events[@current].matches?(event) ) - @current += 1 - if @events[@current].nil? - @current = 0 - return self - elsif @events[@current].kind_of? State - @current += 1 - @events[@current-1].previous = self - return @events[@current-1] - else - return self - end - else - @prior = @previous.pop - return @prior.next( event ) if @current == 0 - return nil - end - end - - def expected - return [ @prior.expected, @events[0] ].flatten if @current == 0 - return [@events[@current]] - end - end - - - class OneOrMore < State - def initialize context - super - @ord = 0 - end - - def reset - super - @ord = 0 - end - - def next( event ) - expand_ref_in( @events, @current ) if @events[@current].class == Ref - if ( @events[@current].matches?(event) ) - @current += 1 - @ord += 1 - if @events[@current].nil? - @current = 0 - return self - elsif @events[@current].kind_of? State - @current += 1 - @events[@current-1].previous = self - return @events[@current-1] - else - return self - end - else - return @previous.pop.next( event ) if @current == 0 and @ord > 0 - return nil - end - end - - def matches?( event ) - @events[@current].matches?(event) || - (@current == 0 and @ord > 0 and @previous[-1].matches?(event)) - end - - def expected - if @current == 0 and @ord > 0 - return [@previous[-1].expected, @events[0]].flatten - else - return [@events[@current]] - end - end - end - - - class Choice < State - def initialize context - super - @choices = [] - end - - def reset - super - @events = [] - @choices.each { |c| c.each { |s| s.reset if s.kind_of? State } } - end - - def <<( event ) - add_event_to_arry( @choices, event ) - end - - def next( event ) - # Make the choice if we haven't - if @events.size == 0 - c = 0 ; max = @choices.size - while c < max - if @choices[c][0].class == Ref - expand_ref_in( @choices[c], 0 ) - @choices += @choices[c] - @choices.delete( @choices[c] ) - max -= 1 - else - c += 1 - end - end - @events = @choices.find { |evt| evt[0].matches? event } - # Remove the references - # Find the events - end - unless @events - @events = [] - return nil - end - super - end - - def matches?( event ) - return @events[@current].matches?( event ) if @events.size > 0 - !@choices.find{|evt| evt[0].matches?(event)}.nil? - end - - def expected - return [@events[@current]] if @events.size > 0 - return @choices.collect do |x| - if x[0].kind_of? State - x[0].expected - else - x[0] - end - end.flatten - end - - def inspect - "< #{to_s} #{@choices.collect{|e| e.collect{|f|f.to_s}.join(', ')}.join(' or ')} >" - end - - protected - def add_event_to_arry( arry, evt ) - if evt.kind_of? State or evt.class == Ref - arry << [evt] - elsif evt[0] == :text - if arry[-1] and - arry[-1][-1].kind_of?( Event ) and - arry[-1][-1].event_type == :text and @value - - arry[-1][-1].event_arg = evt[1] - @value = false - end - else - arry << [] if evt[0] == :start_element - arry[-1] << generate_event( evt ) - end - end - end - - - class Interleave < Choice - def initialize context - super - @choice = 0 - end - - def reset - @choice = 0 - end - - def next_current( event ) - # Expand references - c = 0 ; max = @choices.size - while c < max - if @choices[c][0].class == Ref - expand_ref_in( @choices[c], 0 ) - @choices += @choices[c] - @choices.delete( @choices[c] ) - max -= 1 - else - c += 1 - end - end - @events = @choices[@choice..-1].find { |evt| evt[0].matches? event } - @current = 0 - if @events - # reorder the choices - old = @choices[@choice] - idx = @choices.index( @events ) - @choices[@choice] = @events - @choices[idx] = old - @choice += 1 - end - - @events = [] unless @events - end - - - def next( event ) - # Find the next series - next_current(event) unless @events[@current] - return nil unless @events[@current] - - expand_ref_in( @events, @current ) if @events[@current].class == Ref - if ( @events[@current].kind_of? State ) - @current += 1 - @events[@current-1].previous = self - return @events[@current-1].next( event ) - end - return @previous.pop.next( event ) if @events[@current].nil? - if ( @events[@current].matches?(event) ) - @current += 1 - if @events[@current].nil? - return self unless @choices[@choice].nil? - return @previous.pop - elsif @events[@current].kind_of? State - @current += 1 - @events[@current-1].previous = self - return @events[@current-1] - else - return self - end - else - return nil - end - end - - def matches?( event ) - return @events[@current].matches?( event ) if @events[@current] - !@choices[@choice..-1].find{|evt| evt[0].matches?(event)}.nil? - end - - def expected - return [@events[@current]] if @events[@current] - return @choices[@choice..-1].collect do |x| - if x[0].kind_of? State - x[0].expected - else - x[0] - end - end.flatten - end - - def inspect - "< #{to_s} #{@choices.collect{|e| e.collect{|f|f.to_s}.join(', ')}.join(' and ')} >" - end - end - - class Ref - def initialize value - @value = value - end - def to_s - @value - end - def inspect - "{#{to_s}}" - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/validation/validation.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/validation/validation.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/validation/validation.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/validation/validation.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,144 +0,0 @@ -# frozen_string_literal: false -require_relative 'validationexception' - -module REXML - module Validation - module Validator - NILEVENT = [ nil ] - def reset - @current = @root - @root.reset - @root.previous = true - @attr_stack = [] - self - end - def dump - puts @root.inspect - end - def validate( event ) - @attr_stack = [] unless defined? @attr_stack - match = @current.next(event) - raise ValidationException.new( "Validation error. Expected: "+ - @current.expected.join( " or " )+" from #{@current.inspect} "+ - " but got #{Event.new( event[0], event[1] ).inspect}" ) unless match - @current = match - - # Check for attributes - case event[0] - when :start_element - @attr_stack << event[2] - begin - sattr = [:start_attribute, nil] - eattr = [:end_attribute] - text = [:text, nil] - k, = event[2].find { |key,value| - sattr[1] = key - m = @current.next( sattr ) - if m - # If the state has text children... - if m.matches?( eattr ) - @current = m - else - text[1] = value - m = m.next( text ) - text[1] = nil - return false unless m - @current = m if m - end - m = @current.next( eattr ) - if m - @current = m - true - else - false - end - else - false - end - } - event[2].delete(k) if k - end while k - when :end_element - attrs = @attr_stack.pop - raise ValidationException.new( "Validation error. Illegal "+ - " attributes: #{attrs.inspect}") if attrs.length > 0 - end - end - end - - class Event - def initialize(event_type, event_arg=nil ) - @event_type = event_type - @event_arg = event_arg - end - - attr_reader :event_type - attr_accessor :event_arg - - def done? - @done - end - - def single? - return (@event_type != :start_element and @event_type != :start_attribute) - end - - def matches?( event ) - return false unless event[0] == @event_type - case event[0] - when nil - return true - when :start_element - return true if event[1] == @event_arg - when :end_element - return true - when :start_attribute - return true if event[1] == @event_arg - when :end_attribute - return true - when :end_document - return true - when :text - return (@event_arg.nil? or @event_arg == event[1]) -=begin - when :processing_instruction - false - when :xmldecl - false - when :start_doctype - false - when :end_doctype - false - when :externalentity - false - when :elementdecl - false - when :entity - false - when :attlistdecl - false - when :notationdecl - false - when :end_doctype - false -=end - else - false - end - end - - def ==( other ) - return false unless other.kind_of? Event - @event_type == other.event_type and @event_arg == other.event_arg - end - - def to_s - inspect - end - - def inspect - "#{@event_type.inspect}( #@event_arg )" - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/validation/validationexception.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/validation/validationexception.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/validation/validationexception.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/validation/validationexception.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,10 +0,0 @@ -# frozen_string_literal: false -module REXML - module Validation - class ValidationException < RuntimeError - def initialize msg - super - end - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/xmldecl.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/xmldecl.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/xmldecl.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/xmldecl.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,130 +0,0 @@ -# frozen_string_literal: false - -require_relative 'encoding' -require_relative 'source' - -module REXML - # NEEDS DOCUMENTATION - class XMLDecl < Child - include Encoding - - DEFAULT_VERSION = "1.0" - DEFAULT_ENCODING = "UTF-8" - DEFAULT_STANDALONE = "no" - START = "<?xml" - STOP = "?>" - - attr_accessor :version, :standalone - attr_reader :writeencoding, :writethis - - def initialize(version=DEFAULT_VERSION, encoding=nil, standalone=nil) - @writethis = true - @writeencoding = !encoding.nil? - if version.kind_of? XMLDecl - super() - @version = version.version - self.encoding = version.encoding - @writeencoding = version.writeencoding - @standalone = version.standalone - @writethis = version.writethis - else - super() - @version = version - self.encoding = encoding - @standalone = standalone - end - @version = DEFAULT_VERSION if @version.nil? - end - - def clone - XMLDecl.new(self) - end - - # indent:: - # Ignored. There must be no whitespace before an XML declaration - # transitive:: - # Ignored - # ie_hack:: - # Ignored - def write(writer, indent=-1, transitive=false, ie_hack=false) - return nil unless @writethis or writer.kind_of? Output - writer << START - writer << " #{content encoding}" - writer << STOP - end - - def ==( other ) - other.kind_of?(XMLDecl) and - other.version == @version and - other.encoding == self.encoding and - other.standalone == @standalone - end - - def xmldecl version, encoding, standalone - @version = version - self.encoding = encoding - @standalone = standalone - end - - def node_type - :xmldecl - end - - alias :stand_alone? :standalone - alias :old_enc= :encoding= - - def encoding=( enc ) - if enc.nil? - self.old_enc = "UTF-8" - @writeencoding = false - else - self.old_enc = enc - @writeencoding = true - end - self.dowrite - end - - # Only use this if you do not want the XML declaration to be written; - # this object is ignored by the XML writer. Otherwise, instantiate your - # own XMLDecl and add it to the document. - # - # Note that XML 1.1 documents *must* include an XML declaration - def XMLDecl.default - rv = XMLDecl.new( "1.0" ) - rv.nowrite - rv - end - - def nowrite - @writethis = false - end - - def dowrite - @writethis = true - end - - def inspect - "#{START} ... #{STOP}" - end - - private - def content(enc) - context = nil - context = parent.context if parent - if context and context[:prologue_quote] == :quote - quote = "\"" - else - quote = "'" - end - - rv = "version=#{quote}#{@version}#{quote}" - if @writeencoding or enc !~ /\Autf-8\z/i - rv << " encoding=#{quote}#{enc}#{quote}" - end - if @standalone - rv << " standalone=#{quote}#{@standalone}#{quote}" - end - rv - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/xmltokens.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/xmltokens.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/xmltokens.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/xmltokens.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,85 +0,0 @@ -# frozen_string_literal: false -module REXML - # Defines a number of tokens used for parsing XML. Not for general - # consumption. - module XMLTokens - # From http://www.w3.org/TR/REC-xml/#sec-common-syn - # - # [4] NameStartChar ::= - # ":" | - # [A-Z] | - # "_" | - # [a-z] | - # [#xC0-#xD6] | - # [#xD8-#xF6] | - # [#xF8-#x2FF] | - # [#x370-#x37D] | - # [#x37F-#x1FFF] | - # [#x200C-#x200D] | - # [#x2070-#x218F] | - # [#x2C00-#x2FEF] | - # [#x3001-#xD7FF] | - # [#xF900-#xFDCF] | - # [#xFDF0-#xFFFD] | - # [#x10000-#xEFFFF] - name_start_chars = [ - ":", - "A-Z", - "_", - "a-z", - "\\u00C0-\\u00D6", - "\\u00D8-\\u00F6", - "\\u00F8-\\u02FF", - "\\u0370-\\u037D", - "\\u037F-\\u1FFF", - "\\u200C-\\u200D", - "\\u2070-\\u218F", - "\\u2C00-\\u2FEF", - "\\u3001-\\uD7FF", - "\\uF900-\\uFDCF", - "\\uFDF0-\\uFFFD", - "\\u{10000}-\\u{EFFFF}", - ] - # From http://www.w3.org/TR/REC-xml/#sec-common-syn - # - # [4a] NameChar ::= - # NameStartChar | - # "-" | - # "." | - # [0-9] | - # #xB7 | - # [#x0300-#x036F] | - # [#x203F-#x2040] - name_chars = name_start_chars + [ - "\\-", - "\\.", - "0-9", - "\\u00B7", - "\\u0300-\\u036F", - "\\u203F-\\u2040", - ] - NAME_START_CHAR = "[#{name_start_chars.join('')}]" - NAME_CHAR = "[#{name_chars.join('')}]" - NAMECHAR = NAME_CHAR # deprecated. Use NAME_CHAR instead. - - # From http://www.w3.org/TR/xml-names11/#NT-NCName - # - # [6] NCNameStartChar ::= NameStartChar - ':' - ncname_start_chars = name_start_chars - [":"] - # From http://www.w3.org/TR/xml-names11/#NT-NCName - # - # [5] NCNameChar ::= NameChar - ':' - ncname_chars = name_chars - [":"] - NCNAME_STR = "[#{ncname_start_chars.join('')}][#{ncname_chars.join('')}]*" - NAME_STR = "(?:#{NCNAME_STR}:)?#{NCNAME_STR}" - - NAME = "(#{NAME_START_CHAR}#{NAME_CHAR}*)" - NMTOKEN = "(?:#{NAME_CHAR})+" - NMTOKENS = "#{NMTOKEN}(\\s+#{NMTOKEN})*" - REFERENCE = "(?:&#{NAME};|&#\\d+;|&#x[0-9a-fA-F]+;)" - - #REFERENCE = "(?:#{ENTITYREF}|#{CHARREF})" - #ENTITYREF = "&#{NAME};" - #CHARREF = "&#\\d+;|&#x[0-9a-fA-F]+;" - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/xpath.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/xpath.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/xpath.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/xpath.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,81 +0,0 @@ -# frozen_string_literal: false -require_relative 'functions' -require_relative 'xpath_parser' - -module REXML - # Wrapper class. Use this class to access the XPath functions. - class XPath - include Functions - # A base Hash object, supposing to be used when initializing a - # default empty namespaces set, but is currently unused. - # TODO: either set the namespaces=EMPTY_HASH, or deprecate this. - EMPTY_HASH = {} - - # Finds and returns the first node that matches the supplied xpath. - # element:: - # The context element - # path:: - # The xpath to search for. If not supplied or nil, returns the first - # node matching '*'. - # namespaces:: - # If supplied, a Hash which defines a namespace mapping. - # variables:: - # If supplied, a Hash which maps $variables in the query - # to values. This can be used to avoid XPath injection attacks - # or to automatically handle escaping string values. - # - # XPath.first( node ) - # XPath.first( doc, "//b"} ) - # XPath.first( node, "a/x:b", { "x"=>"http://doofus" } ) - # XPath.first( node, '/book/publisher/text()=$publisher', {}, {"publisher"=>"O'Reilly"}) - def XPath::first(element, path=nil, namespaces=nil, variables={}, options={}) - raise "The namespaces argument, if supplied, must be a hash object." unless namespaces.nil? or namespaces.kind_of?(Hash) - raise "The variables argument, if supplied, must be a hash object." unless variables.kind_of?(Hash) - parser = XPathParser.new(**options) - parser.namespaces = namespaces - parser.variables = variables - path = "*" unless path - element = [element] unless element.kind_of? Array - parser.parse(path, element).flatten[0] - end - - # Iterates over nodes that match the given path, calling the supplied - # block with the match. - # element:: - # The context element - # path:: - # The xpath to search for. If not supplied or nil, defaults to '*' - # namespaces:: - # If supplied, a Hash which defines a namespace mapping - # variables:: - # If supplied, a Hash which maps $variables in the query - # to values. This can be used to avoid XPath injection attacks - # or to automatically handle escaping string values. - # - # XPath.each( node ) { |el| ... } - # XPath.each( node, '/*[@attr='v']' ) { |el| ... } - # XPath.each( node, 'ancestor::x' ) { |el| ... } - # XPath.each( node, '/book/publisher/text()=$publisher', {}, {"publisher"=>"O'Reilly"}) \ - # {|el| ... } - def XPath::each(element, path=nil, namespaces=nil, variables={}, options={}, &block) - raise "The namespaces argument, if supplied, must be a hash object." unless namespaces.nil? or namespaces.kind_of?(Hash) - raise "The variables argument, if supplied, must be a hash object." unless variables.kind_of?(Hash) - parser = XPathParser.new(**options) - parser.namespaces = namespaces - parser.variables = variables - path = "*" unless path - element = [element] unless element.kind_of? Array - parser.parse(path, element).each( &block ) - end - - # Returns an array of nodes matching a given XPath. - def XPath::match(element, path=nil, namespaces=nil, variables={}, options={}) - parser = XPathParser.new(**options) - parser.namespaces = namespaces - parser.variables = variables - path = "*" unless path - element = [element] unless element.kind_of? Array - parser.parse(path,element) - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/xpath_parser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/xpath_parser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml/xpath_parser.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml/xpath_parser.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,978 +0,0 @@ -# frozen_string_literal: false - -require "pp" - -require_relative 'namespace' -require_relative 'xmltokens' -require_relative 'attribute' -require_relative 'parsers/xpathparser' - -module REXML - module DClonable - refine Object do - # provides a unified +clone+ operation, for REXML::XPathParser - # to use across multiple Object types - def dclone - clone - end - end - refine Symbol do - # provides a unified +clone+ operation, for REXML::XPathParser - # to use across multiple Object types - def dclone ; self ; end - end - refine Integer do - # provides a unified +clone+ operation, for REXML::XPathParser - # to use across multiple Object types - def dclone ; self ; end - end - refine Float do - # provides a unified +clone+ operation, for REXML::XPathParser - # to use across multiple Object types - def dclone ; self ; end - end - refine Array do - # provides a unified +clone+ operation, for REXML::XPathParser - # to use across multiple Object+ types - def dclone - klone = self.clone - klone.clear - self.each{|v| klone << v.dclone} - klone - end - end - end -end - -using REXML::DClonable - -module REXML - # You don't want to use this class. Really. Use XPath, which is a wrapper - # for this class. Believe me. You don't want to poke around in here. - # There is strange, dark magic at work in this code. Beware. Go back! Go - # back while you still can! - class XPathParser - include XMLTokens - LITERAL = /^'([^']*)'|^"([^"]*)"/u - - DEBUG = (ENV["REXML_XPATH_PARSER_DEBUG"] == "true") - - def initialize(strict: false) - @debug = DEBUG - @parser = REXML::Parsers::XPathParser.new - @namespaces = nil - @variables = {} - @nest = 0 - @strict = strict - end - - def namespaces=( namespaces={} ) - Functions::namespace_context = namespaces - @namespaces = namespaces - end - - def variables=( vars={} ) - Functions::variables = vars - @variables = vars - end - - def parse path, nodeset - path_stack = @parser.parse( path ) - match( path_stack, nodeset ) - end - - def get_first path, nodeset - path_stack = @parser.parse( path ) - first( path_stack, nodeset ) - end - - def predicate path, nodeset - path_stack = @parser.parse( path ) - match( path_stack, nodeset ) - end - - def []=( variable_name, value ) - @variables[ variable_name ] = value - end - - - # Performs a depth-first (document order) XPath search, and returns the - # first match. This is the fastest, lightest way to return a single result. - # - # FIXME: This method is incomplete! - def first( path_stack, node ) - return nil if path.size == 0 - - case path[0] - when :document - # do nothing - return first( path[1..-1], node ) - when :child - for c in node.children - r = first( path[1..-1], c ) - return r if r - end - when :qname - name = path[2] - if node.name == name - return node if path.size == 3 - return first( path[3..-1], node ) - else - return nil - end - when :descendant_or_self - r = first( path[1..-1], node ) - return r if r - for c in node.children - r = first( path, c ) - return r if r - end - when :node - return first( path[1..-1], node ) - when :any - return first( path[1..-1], node ) - end - return nil - end - - - def match(path_stack, nodeset) - nodeset = nodeset.collect.with_index do |node, i| - position = i + 1 - XPathNode.new(node, position: position) - end - result = expr(path_stack, nodeset) - case result - when Array # nodeset - unnode(result) - else - [result] - end - end - - private - def strict? - @strict - end - - # Returns a String namespace for a node, given a prefix - # The rules are: - # - # 1. Use the supplied namespace mapping first. - # 2. If no mapping was supplied, use the context node to look up the namespace - def get_namespace( node, prefix ) - if @namespaces - return @namespaces[prefix] || '' - else - return node.namespace( prefix ) if node.node_type == :element - return '' - end - end - - - # Expr takes a stack of path elements and a set of nodes (either a Parent - # or an Array and returns an Array of matching nodes - def expr( path_stack, nodeset, context=nil ) - enter(:expr, path_stack, nodeset) if @debug - return nodeset if path_stack.length == 0 || nodeset.length == 0 - while path_stack.length > 0 - trace(:while, path_stack, nodeset) if @debug - if nodeset.length == 0 - path_stack.clear - return [] - end - op = path_stack.shift - case op - when :document - first_raw_node = nodeset.first.raw_node - nodeset = [XPathNode.new(first_raw_node.root_node, position: 1)] - when :self - nodeset = step(path_stack) do - [nodeset] - end - when :child - nodeset = step(path_stack) do - child(nodeset) - end - when :literal - trace(:literal, path_stack, nodeset) if @debug - return path_stack.shift - when :attribute - nodeset = step(path_stack, any_type: :attribute) do - nodesets = [] - nodeset.each do |node| - raw_node = node.raw_node - next unless raw_node.node_type == :element - attributes = raw_node.attributes - next if attributes.empty? - nodesets << attributes.each_attribute.collect.with_index do |attribute, i| - XPathNode.new(attribute, position: i + 1) - end - end - nodesets - end - when :namespace - pre_defined_namespaces = { - "xml" => "http://www.w3.org/XML/1998/namespace", - } - nodeset = step(path_stack, any_type: :namespace) do - nodesets = [] - nodeset.each do |node| - raw_node = node.raw_node - case raw_node.node_type - when :element - if @namespaces - nodesets << pre_defined_namespaces.merge(@namespaces) - else - nodesets << pre_defined_namespaces.merge(raw_node.namespaces) - end - when :attribute - if @namespaces - nodesets << pre_defined_namespaces.merge(@namespaces) - else - nodesets << pre_defined_namespaces.merge(raw_node.element.namespaces) - end - end - end - nodesets - end - when :parent - nodeset = step(path_stack) do - nodesets = [] - nodeset.each do |node| - raw_node = node.raw_node - if raw_node.node_type == :attribute - parent = raw_node.element - else - parent = raw_node.parent - end - nodesets << [XPathNode.new(parent, position: 1)] if parent - end - nodesets - end - when :ancestor - nodeset = step(path_stack) do - nodesets = [] - # new_nodes = {} - nodeset.each do |node| - raw_node = node.raw_node - new_nodeset = [] - while raw_node.parent - raw_node = raw_node.parent - # next if new_nodes.key?(node) - new_nodeset << XPathNode.new(raw_node, - position: new_nodeset.size + 1) - # new_nodes[node] = true - end - nodesets << new_nodeset unless new_nodeset.empty? - end - nodesets - end - when :ancestor_or_self - nodeset = step(path_stack) do - nodesets = [] - # new_nodes = {} - nodeset.each do |node| - raw_node = node.raw_node - next unless raw_node.node_type == :element - new_nodeset = [XPathNode.new(raw_node, position: 1)] - # new_nodes[node] = true - while raw_node.parent - raw_node = raw_node.parent - # next if new_nodes.key?(node) - new_nodeset << XPathNode.new(raw_node, - position: new_nodeset.size + 1) - # new_nodes[node] = true - end - nodesets << new_nodeset unless new_nodeset.empty? - end - nodesets - end - when :descendant_or_self - nodeset = step(path_stack) do - descendant(nodeset, true) - end - when :descendant - nodeset = step(path_stack) do - descendant(nodeset, false) - end - when :following_sibling - nodeset = step(path_stack) do - nodesets = [] - nodeset.each do |node| - raw_node = node.raw_node - next unless raw_node.respond_to?(:parent) - next if raw_node.parent.nil? - all_siblings = raw_node.parent.children - current_index = all_siblings.index(raw_node) - following_siblings = all_siblings[(current_index + 1)..-1] - next if following_siblings.empty? - nodesets << following_siblings.collect.with_index do |sibling, i| - XPathNode.new(sibling, position: i + 1) - end - end - nodesets - end - when :preceding_sibling - nodeset = step(path_stack, order: :reverse) do - nodesets = [] - nodeset.each do |node| - raw_node = node.raw_node - next unless raw_node.respond_to?(:parent) - next if raw_node.parent.nil? - all_siblings = raw_node.parent.children - current_index = all_siblings.index(raw_node) - preceding_siblings = all_siblings[0, current_index].reverse - next if preceding_siblings.empty? - nodesets << preceding_siblings.collect.with_index do |sibling, i| - XPathNode.new(sibling, position: i + 1) - end - end - nodesets - end - when :preceding - nodeset = step(path_stack, order: :reverse) do - unnode(nodeset) do |node| - preceding(node) - end - end - when :following - nodeset = step(path_stack) do - unnode(nodeset) do |node| - following(node) - end - end - when :variable - var_name = path_stack.shift - return [@variables[var_name]] - - when :eq, :neq, :lt, :lteq, :gt, :gteq - left = expr( path_stack.shift, nodeset.dup, context ) - right = expr( path_stack.shift, nodeset.dup, context ) - res = equality_relational_compare( left, op, right ) - trace(op, left, right, res) if @debug - return res - - when :or - left = expr(path_stack.shift, nodeset.dup, context) - return true if Functions.boolean(left) - right = expr(path_stack.shift, nodeset.dup, context) - return Functions.boolean(right) - - when :and - left = expr(path_stack.shift, nodeset.dup, context) - return false unless Functions.boolean(left) - right = expr(path_stack.shift, nodeset.dup, context) - return Functions.boolean(right) - - when :div, :mod, :mult, :plus, :minus - left = expr(path_stack.shift, nodeset, context) - right = expr(path_stack.shift, nodeset, context) - left = unnode(left) if left.is_a?(Array) - right = unnode(right) if right.is_a?(Array) - left = Functions::number(left) - right = Functions::number(right) - case op - when :div - return left / right - when :mod - return left % right - when :mult - return left * right - when :plus - return left + right - when :minus - return left - right - else - raise "[BUG] Unexpected operator: <#{op.inspect}>" - end - when :union - left = expr( path_stack.shift, nodeset, context ) - right = expr( path_stack.shift, nodeset, context ) - left = unnode(left) if left.is_a?(Array) - right = unnode(right) if right.is_a?(Array) - return (left | right) - when :neg - res = expr( path_stack, nodeset, context ) - res = unnode(res) if res.is_a?(Array) - return -Functions.number(res) - when :not - when :function - func_name = path_stack.shift.tr('-','_') - arguments = path_stack.shift - - if nodeset.size != 1 - message = "[BUG] Node set size must be 1 for function call: " - message += "<#{func_name}>: <#{nodeset.inspect}>: " - message += "<#{arguments.inspect}>" - raise message - end - - node = nodeset.first - if context - target_context = context - else - target_context = {:size => nodeset.size} - if node.is_a?(XPathNode) - target_context[:node] = node.raw_node - target_context[:index] = node.position - else - target_context[:node] = node - target_context[:index] = 1 - end - end - args = arguments.dclone.collect do |arg| - result = expr(arg, nodeset, target_context) - result = unnode(result) if result.is_a?(Array) - result - end - Functions.context = target_context - return Functions.send(func_name, *args) - - else - raise "[BUG] Unexpected path: <#{op.inspect}>: <#{path_stack.inspect}>" - end - end # while - return nodeset - ensure - leave(:expr, path_stack, nodeset) if @debug - end - - def step(path_stack, any_type: :element, order: :forward) - nodesets = yield - begin - enter(:step, path_stack, nodesets) if @debug - nodesets = node_test(path_stack, nodesets, any_type: any_type) - while path_stack[0] == :predicate - path_stack.shift # :predicate - predicate_expression = path_stack.shift.dclone - nodesets = evaluate_predicate(predicate_expression, nodesets) - end - if nodesets.size == 1 - ordered_nodeset = nodesets[0] - else - raw_nodes = [] - nodesets.each do |nodeset| - nodeset.each do |node| - if node.respond_to?(:raw_node) - raw_nodes << node.raw_node - else - raw_nodes << node - end - end - end - ordered_nodeset = sort(raw_nodes, order) - end - new_nodeset = [] - ordered_nodeset.each do |node| - # TODO: Remove duplicated - new_nodeset << XPathNode.new(node, position: new_nodeset.size + 1) - end - new_nodeset - ensure - leave(:step, path_stack, new_nodeset) if @debug - end - end - - def node_test(path_stack, nodesets, any_type: :element) - enter(:node_test, path_stack, nodesets) if @debug - operator = path_stack.shift - case operator - when :qname - prefix = path_stack.shift - name = path_stack.shift - new_nodesets = nodesets.collect do |nodeset| - filter_nodeset(nodeset) do |node| - raw_node = node.raw_node - case raw_node.node_type - when :element - if prefix.nil? - raw_node.name == name - elsif prefix.empty? - if strict? - raw_node.name == name and raw_node.namespace == "" - else - # FIXME: This DOUBLES the time XPath searches take - ns = get_namespace(raw_node, prefix) - raw_node.name == name and raw_node.namespace == ns - end - else - # FIXME: This DOUBLES the time XPath searches take - ns = get_namespace(raw_node, prefix) - raw_node.name == name and raw_node.namespace == ns - end - when :attribute - if prefix.nil? - raw_node.name == name - elsif prefix.empty? - raw_node.name == name and raw_node.namespace == "" - else - # FIXME: This DOUBLES the time XPath searches take - ns = get_namespace(raw_node.element, prefix) - raw_node.name == name and raw_node.namespace == ns - end - else - false - end - end - end - when :namespace - prefix = path_stack.shift - new_nodesets = nodesets.collect do |nodeset| - filter_nodeset(nodeset) do |node| - raw_node = node.raw_node - case raw_node.node_type - when :element - namespaces = @namespaces || raw_node.namespaces - raw_node.namespace == namespaces[prefix] - when :attribute - namespaces = @namespaces || raw_node.element.namespaces - raw_node.namespace == namespaces[prefix] - else - false - end - end - end - when :any - new_nodesets = nodesets.collect do |nodeset| - filter_nodeset(nodeset) do |node| - raw_node = node.raw_node - raw_node.node_type == any_type - end - end - when :comment - new_nodesets = nodesets.collect do |nodeset| - filter_nodeset(nodeset) do |node| - raw_node = node.raw_node - raw_node.node_type == :comment - end - end - when :text - new_nodesets = nodesets.collect do |nodeset| - filter_nodeset(nodeset) do |node| - raw_node = node.raw_node - raw_node.node_type == :text - end - end - when :processing_instruction - target = path_stack.shift - new_nodesets = nodesets.collect do |nodeset| - filter_nodeset(nodeset) do |node| - raw_node = node.raw_node - (raw_node.node_type == :processing_instruction) and - (target.empty? or (raw_node.target == target)) - end - end - when :node - new_nodesets = nodesets.collect do |nodeset| - filter_nodeset(nodeset) do |node| - true - end - end - else - message = "[BUG] Unexpected node test: " + - "<#{operator.inspect}>: <#{path_stack.inspect}>" - raise message - end - new_nodesets - ensure - leave(:node_test, path_stack, new_nodesets) if @debug - end - - def filter_nodeset(nodeset) - new_nodeset = [] - nodeset.each do |node| - next unless yield(node) - new_nodeset << XPathNode.new(node, position: new_nodeset.size + 1) - end - new_nodeset - end - - def evaluate_predicate(expression, nodesets) - enter(:predicate, expression, nodesets) if @debug - new_nodeset_count = 0 - new_nodesets = nodesets.collect do |nodeset| - new_nodeset = [] - subcontext = { :size => nodeset.size } - nodeset.each_with_index do |node, index| - if node.is_a?(XPathNode) - subcontext[:node] = node.raw_node - subcontext[:index] = node.position - else - subcontext[:node] = node - subcontext[:index] = index + 1 - end - result = expr(expression.dclone, [node], subcontext) - trace(:predicate_evaluate, expression, node, subcontext, result) if @debug - result = result[0] if result.kind_of? Array and result.length == 1 - if result.kind_of? Numeric - if result == node.position - new_nodeset_count += 1 - new_nodeset << XPathNode.new(node, position: new_nodeset_count) - end - elsif result.instance_of? Array - if result.size > 0 and result.inject(false) {|k,s| s or k} - if result.size > 0 - new_nodeset_count += 1 - new_nodeset << XPathNode.new(node, position: new_nodeset_count) - end - end - else - if result - new_nodeset_count += 1 - new_nodeset << XPathNode.new(node, position: new_nodeset_count) - end - end - end - new_nodeset - end - new_nodesets - ensure - leave(:predicate, new_nodesets) if @debug - end - - def trace(*args) - indent = " " * @nest - PP.pp(args, "").each_line do |line| - puts("#{indent}#{line}") - end - end - - def enter(tag, *args) - trace(:enter, tag, *args) - @nest += 1 - end - - def leave(tag, *args) - @nest -= 1 - trace(:leave, tag, *args) - end - - # Reorders an array of nodes so that they are in document order - # It tries to do this efficiently. - # - # FIXME: I need to get rid of this, but the issue is that most of the XPath - # interpreter functions as a filter, which means that we lose context going - # in and out of function calls. If I knew what the index of the nodes was, - # I wouldn't have to do this. Maybe add a document IDX for each node? - # Problems with mutable documents. Or, rewrite everything. - def sort(array_of_nodes, order) - new_arry = [] - array_of_nodes.each { |node| - node_idx = [] - np = node.node_type == :attribute ? node.element : node - while np.parent and np.parent.node_type == :element - node_idx << np.parent.index( np ) - np = np.parent - end - new_arry << [ node_idx.reverse, node ] - } - ordered = new_arry.sort_by do |index, node| - if order == :forward - index - else - -index - end - end - ordered.collect do |_index, node| - node - end - end - - def descendant(nodeset, include_self) - nodesets = [] - nodeset.each do |node| - new_nodeset = [] - new_nodes = {} - descendant_recursive(node.raw_node, new_nodeset, new_nodes, include_self) - nodesets << new_nodeset unless new_nodeset.empty? - end - nodesets - end - - def descendant_recursive(raw_node, new_nodeset, new_nodes, include_self) - if include_self - return if new_nodes.key?(raw_node) - new_nodeset << XPathNode.new(raw_node, position: new_nodeset.size + 1) - new_nodes[raw_node] = true - end - - node_type = raw_node.node_type - if node_type == :element or node_type == :document - raw_node.children.each do |child| - descendant_recursive(child, new_nodeset, new_nodes, true) - end - end - end - - # Builds a nodeset of all of the preceding nodes of the supplied node, - # in reverse document order - # preceding:: includes every element in the document that precedes this node, - # except for ancestors - def preceding(node) - ancestors = [] - parent = node.parent - while parent - ancestors << parent - parent = parent.parent - end - - precedings = [] - preceding_node = preceding_node_of(node) - while preceding_node - if ancestors.include?(preceding_node) - ancestors.delete(preceding_node) - else - precedings << XPathNode.new(preceding_node, - position: precedings.size + 1) - end - preceding_node = preceding_node_of(preceding_node) - end - precedings - end - - def preceding_node_of( node ) - psn = node.previous_sibling_node - if psn.nil? - if node.parent.nil? or node.parent.class == Document - return nil - end - return node.parent - #psn = preceding_node_of( node.parent ) - end - while psn and psn.kind_of? Element and psn.children.size > 0 - psn = psn.children[-1] - end - psn - end - - def following(node) - followings = [] - following_node = next_sibling_node(node) - while following_node - followings << XPathNode.new(following_node, - position: followings.size + 1) - following_node = following_node_of(following_node) - end - followings - end - - def following_node_of( node ) - if node.kind_of? Element and node.children.size > 0 - return node.children[0] - end - return next_sibling_node(node) - end - - def next_sibling_node(node) - psn = node.next_sibling_node - while psn.nil? - if node.parent.nil? or node.parent.class == Document - return nil - end - node = node.parent - psn = node.next_sibling_node - end - return psn - end - - def child(nodeset) - nodesets = [] - nodeset.each do |node| - raw_node = node.raw_node - node_type = raw_node.node_type - # trace(:child, node_type, node) - case node_type - when :element - nodesets << raw_node.children.collect.with_index do |child_node, i| - XPathNode.new(child_node, position: i + 1) - end - when :document - new_nodeset = [] - raw_node.children.each do |child| - case child - when XMLDecl, Text - # Ignore - else - new_nodeset << XPathNode.new(child, position: new_nodeset.size + 1) - end - end - nodesets << new_nodeset unless new_nodeset.empty? - end - end - nodesets - end - - def norm b - case b - when true, false - return b - when 'true', 'false' - return Functions::boolean( b ) - when /^\d+(\.\d+)?$/, Numeric - return Functions::number( b ) - else - return Functions::string( b ) - end - end - - def equality_relational_compare(set1, op, set2) - set1 = unnode(set1) if set1.is_a?(Array) - set2 = unnode(set2) if set2.is_a?(Array) - - if set1.kind_of? Array and set2.kind_of? Array - # If both objects to be compared are node-sets, then the - # comparison will be true if and only if there is a node in the - # first node-set and a node in the second node-set such that the - # result of performing the comparison on the string-values of - # the two nodes is true. - set1.product(set2).any? do |node1, node2| - node_string1 = Functions.string(node1) - node_string2 = Functions.string(node2) - compare(node_string1, op, node_string2) - end - elsif set1.kind_of? Array or set2.kind_of? Array - # If one is nodeset and other is number, compare number to each item - # in nodeset s.t. number op number(string(item)) - # If one is nodeset and other is string, compare string to each item - # in nodeset s.t. string op string(item) - # If one is nodeset and other is boolean, compare boolean to each item - # in nodeset s.t. boolean op boolean(item) - if set1.kind_of? Array - a = set1 - b = set2 - else - a = set2 - b = set1 - end - - case b - when true, false - each_unnode(a).any? do |unnoded| - compare(Functions.boolean(unnoded), op, b) - end - when Numeric - each_unnode(a).any? do |unnoded| - compare(Functions.number(unnoded), op, b) - end - when /\A\d+(\.\d+)?\z/ - b = Functions.number(b) - each_unnode(a).any? do |unnoded| - compare(Functions.number(unnoded), op, b) - end - else - b = Functions::string(b) - each_unnode(a).any? do |unnoded| - compare(Functions::string(unnoded), op, b) - end - end - else - # If neither is nodeset, - # If op is = or != - # If either boolean, convert to boolean - # If either number, convert to number - # Else, convert to string - # Else - # Convert both to numbers and compare - compare(set1, op, set2) - end - end - - def value_type(value) - case value - when true, false - :boolean - when Numeric - :number - when String - :string - else - raise "[BUG] Unexpected value type: <#{value.inspect}>" - end - end - - def normalize_compare_values(a, operator, b) - a_type = value_type(a) - b_type = value_type(b) - case operator - when :eq, :neq - if a_type == :boolean or b_type == :boolean - a = Functions.boolean(a) unless a_type == :boolean - b = Functions.boolean(b) unless b_type == :boolean - elsif a_type == :number or b_type == :number - a = Functions.number(a) unless a_type == :number - b = Functions.number(b) unless b_type == :number - else - a = Functions.string(a) unless a_type == :string - b = Functions.string(b) unless b_type == :string - end - when :lt, :lteq, :gt, :gteq - a = Functions.number(a) unless a_type == :number - b = Functions.number(b) unless b_type == :number - else - message = "[BUG] Unexpected compare operator: " + - "<#{operator.inspect}>: <#{a.inspect}>: <#{b.inspect}>" - raise message - end - [a, b] - end - - def compare(a, operator, b) - a, b = normalize_compare_values(a, operator, b) - case operator - when :eq - a == b - when :neq - a != b - when :lt - a < b - when :lteq - a <= b - when :gt - a > b - when :gteq - a >= b - else - message = "[BUG] Unexpected compare operator: " + - "<#{operator.inspect}>: <#{a.inspect}>: <#{b.inspect}>" - raise message - end - end - - def each_unnode(nodeset) - return to_enum(__method__, nodeset) unless block_given? - nodeset.each do |node| - if node.is_a?(XPathNode) - unnoded = node.raw_node - else - unnoded = node - end - yield(unnoded) - end - end - - def unnode(nodeset) - each_unnode(nodeset).collect do |unnoded| - unnoded = yield(unnoded) if block_given? - unnoded - end - end - end - - # @private - class XPathNode - attr_reader :raw_node, :context - def initialize(node, context=nil) - if node.is_a?(XPathNode) - @raw_node = node.raw_node - else - @raw_node = node - end - @context = context || {} - end - - def position - @context[:position] - end - end -end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.3.9/lib/rexml.rb 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.3.9/lib/rexml.rb 1970-01-01 00:00:00.000000000 +0000 @@ -1,3 +0,0 @@ -# frozen_string_literal: true - -require_relative "rexml/document" diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/LICENSE.txt ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/LICENSE.txt --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/LICENSE.txt 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/LICENSE.txt 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,22 @@ +Copyright (C) 1993-2013 Yukihiro Matsumoto. All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: +1. Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. +2. Redistributions in binary form must reproduce the above copyright +notice, this list of conditions and the following disclaimer in the +documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +SUCH DAMAGE. diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/NEWS.md ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/NEWS.md --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/NEWS.md 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/NEWS.md 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,843 @@ +# News + +## 3.4.4 - 2025-09-10 {#version-3-4-4} + +### Improvement + + * Accept `REXML::Document.new("")` for backward compatibility + * GH-296 + * GH-295 + * Patch by NAITOH Jun + * Reported by Joe Rafaniello + +### Thanks + + * NAITOH Jun + + * Joe Rafaniello + +## 3.4.3 - 2025-09-07 {#version-3-4-3} + +### Improvement + + * Reject no root element XML as an invalid XML + * GH-289 + * GH-291 + * Patch by NAITOH Jun + * Reported by Sutou Kouhei + +### Fixes + + * Fixed an issue with `IOSource#read_until` when reaching the end of a file + * GH-287 + * GH-288 + * Patch by NAITOH Jun + * Reported by Jason Thomas + +### Thanks + + * NAITOH Jun + + * Sutou Kouhei + + * Jason Thomas + +## 3.4.2 - 2025-08-26 {#version-3-4-2} + +### Improvement + + * Improved performance. + * GH-244 + * GH-245 + * GH-246 + * GH-249 + * GH-256 + * Patch by NAITOH Jun + + * Raise appropriate exception when failing to match start tag in DOCTYPE + * GH-247 + * Patch by NAITOH Jun + + * Deprecate accepting array as an element in XPath.match, first and each + * GH-252 + * Patch by tomoya ishida + + * Don't call needless encoding_updated + * GH-259 + * Patch by Sutou Kouhei + + * Reuse XPath::match + * GH-263 + * Patch by pboling + + * Cache redundant calls for doctype + * GH-264 + * Patch by pboling + + * Use Safe Navigation (&.) from Ruby 2.3 + * GH-265 + * Patch by pboling + + * Remove redundant return statements + * GH-266 + * Patch by pboling + + * Added XML declaration check & Source#skip_spaces method + * GH-282 + * Patch by NAITOH Jun + * Reported by Sofi Aberegg + +### Fixes + + * Fix docs typo + * GH-248 + * Patch by James Coleman + + * Fix reverse sort in xpath_parser + * GH-251 + * Patch by tomoya ishida + + * Fix duplicate responses in XPath following, following-sibling, preceding, preceding-sibling + * GH-255 + * Patch by NAITOH Jun + + * Fix wrong Encoding resolution + * GH-258 + * Patch by Sutou Kouhei + + * Handle nil when parsing fragment + * GH-267 + * GH-268 + * Patch by pboling + + * [Documentation] Use # to reference instance methods + * GH-269 + * GH-270 + * Patch by pboling + + * Fix & Deprecate REXML::Text#text_indent + * GH-273 + * GH-275 + * Patch by pboling + + * remove bundler from dev deps + * GH-276 + * GH-277 + * Patch by pboling + + * remove ostruct from dev deps + * GH-280 + * GH-281 + * Patch by pboling + +### Thanks + + * NAITOH Jun + + * tomoya ishida + + * James Coleman + + * pboling + + * Sutou Kouhei + + * Sofi Aberegg + +## 3.4.1 - 2025-02-16 {#version-3-4-1} + +### Improvement + + * Improved performance. + * GH-226 + * GH-227 + * GH-237 + * Patch by NAITOH Jun + +### Fixes + + * Fix serialization of ATTLIST is incorrect + * GH-233 + * GH-234 + * Patch by OlofKalufs + * Reported by OlofKalufs + +### Thanks + + * NAITOH Jun + + * OlofKalufs + +## 3.4.0 - 2024-12-15 {#version-3-4-0} + +### Improvement + + * Improved performance. + * GH-216 + * Patch by NAITOH Jun + + * JRuby: Improved parse performance. + * GH-219 + * Patch by João Duarte + + * Added support for reusing pull parser. + * GH-214 + * GH-220 + * Patch by Dmitry Pogrebnoy + + * Improved error handling when source is `IO`. + * GH-221 + * Patch by NAITOH Jun + +### Thanks + + * NAITOH Jun + + * João Duarte + + * Dmitry Pogrebnoy + +## 3.3.9 - 2024-10-24 {#version-3-3-9} + +### Improvements + + * Improved performance. + * GH-210 + * Patch by NAITOH Jun. + +### Fixes + + * Fixed a parse bug for text only invalid XML. + * GH-215 + * Patch by NAITOH Jun. + + * Fixed a parse bug that `�x...;` is accepted as a character + reference. + +### Thanks + + * NAITOH Jun + +## 3.3.8 - 2024-09-29 {#version-3-3-8} + +### Improvements + + * SAX2: Improve parse performance. + * GH-207 + * Patch by NAITOH Jun. + +### Fixes + + * Fixed a bug that unexpected attribute namespace conflict error for + the predefined "xml" namespace is reported. + * GH-208 + * Patch by KITAITI Makoto + +### Thanks + + * NAITOH Jun + + * KITAITI Makoto + +## 3.3.7 - 2024-09-04 {#version-3-3-7} + +### Improvements + + * Added local entity expansion limit methods + * GH-192 + * GH-202 + * Reported by takuya kodama. + * Patch by NAITOH Jun. + + * Removed explicit strscan dependency + * GH-204 + * Patch by Bo Anderson. + +### Thanks + + * takuya kodama + + * NAITOH Jun + + * Bo Anderson + +## 3.3.6 - 2024-08-22 {#version-3-3-6} + +### Improvements + + * Removed duplicated entity expansions for performance. + * GH-194 + * Patch by Viktor Ivarsson. + + * Improved namespace conflicted attribute check performance. It was + too slow for deep elements. + * Reported by l33thaxor. + +### Fixes + + * Fixed a bug that default entity expansions are counted for + security check. Default entity expansions should not be counted + because they don't have a security risk. + * GH-198 + * GH-199 + * Patch Viktor Ivarsson + + * Fixed a parser bug that parameter entity references in internal + subsets are expanded. It's not allowed in the XML specification. + * GH-191 + * Patch by NAITOH Jun. + + * Fixed a stream parser bug that user-defined entity references in + text aren't expanded. + * GH-200 + * Patch by NAITOH Jun. + +### Thanks + + * Viktor Ivarsson + + * NAITOH Jun + + * l33thaxor + +## 3.3.5 - 2024-08-12 {#version-3-3-5} + +### Fixes + + * Fixed a bug that `REXML::Security.entity_expansion_text_limit` + check has wrong text size calculation in SAX and pull parsers. + * GH-193 + * GH-195 + * Reported by Viktor Ivarsson. + * Patch by NAITOH Jun. + +### Thanks + + * Viktor Ivarsson + + * NAITOH Jun + +## 3.3.4 - 2024-08-01 {#version-3-3-4} + +### Fixes + + * Fixed a bug that `REXML::Security` isn't defined when + `REXML::Parsers::StreamParser` is used and + `rexml/parsers/streamparser` is only required. + * GH-189 + * Patch by takuya kodama. + +### Thanks + + * takuya kodama + +## 3.3.3 - 2024-08-01 {#version-3-3-3} + +### Improvements + + * Added support for detecting invalid XML that has unsupported + content before root element + * GH-184 + * Patch by NAITOH Jun. + + * Added support for `REXML::Security.entity_expansion_limit=` and + `REXML::Security.entity_expansion_text_limit=` in SAX2 and pull + parsers + * GH-187 + * Patch by NAITOH Jun. + + * Added more tests for invalid XMLs. + * GH-183 + * Patch by Watson. + + * Added more performance tests. + * Patch by Watson. + + * Improved parse performance. + * GH-186 + * Patch by tomoya ishida. + +### Thanks + + * NAITOH Jun + + * Watson + + * tomoya ishida + +## 3.3.2 - 2024-07-16 {#version-3-3-2} + +### Improvements + + * Improved parse performance. + * GH-160 + * Patch by NAITOH Jun. + + * Improved parse performance. + * GH-169 + * GH-170 + * GH-171 + * GH-172 + * GH-173 + * GH-174 + * GH-175 + * GH-176 + * GH-177 + * Patch by Watson. + + * Added support for raising a parse exception when an XML has extra + content after the root element. + * GH-161 + * Patch by NAITOH Jun. + + * Added support for raising a parse exception when an XML + declaration exists in wrong position. + * GH-162 + * Patch by NAITOH Jun. + + * Removed needless a space after XML declaration in pretty print mode. + * GH-164 + * Patch by NAITOH Jun. + + * Stopped to emit `:text` event after the root element. + * GH-167 + * Patch by NAITOH Jun. + +### Fixes + + * Fixed a bug that SAX2 parser doesn't expand predefined entities for + `characters` callback. + * GH-168 + * Patch by NAITOH Jun. + +### Thanks + + * NAITOH Jun + + * Watson + +## 3.3.1 - 2024-06-25 {#version-3-3-1} + +### Improvements + + * Added support for detecting malformed top-level comments. + * GH-145 + * Patch by Hiroya Fujinami. + + * Improved `REXML::Element#attribute` performance. + * GH-146 + * Patch by Hiroya Fujinami. + + * Added support for detecting malformed `<!-->` comments. + * GH-147 + * Patch by Hiroya Fujinami. + + * Added support for detecting unclosed `DOCTYPE`. + * GH-152 + * Patch by Hiroya Fujinami. + + * Added `changlog_uri` metadata to gemspec. + * GH-156 + * Patch by fynsta. + + * Improved parse performance. + * GH-157 + * GH-158 + * Patch by NAITOH Jun. + +### Fixes + + * Fixed a bug that large XML can't be parsed. + * GH-154 + * Patch by NAITOH Jun. + + * Fixed a bug that private constants are visible. + * GH-155 + * Patch by NAITOH Jun. + +### Thanks + + * Hiroya Fujinami + + * NAITOH Jun + + * fynsta + +## 3.3.0 - 2024-06-11 {#version-3-3-0} + +### Improvements + + * Added support for strscan 0.7.0 installed with Ruby 2.6. + * GH-142 + * Reported by Fernando Trigoso. + +### Thanks + + * Fernando Trigoso + +## 3.2.9 - 2024-06-09 {#version-3-2-9} + +### Improvements + + * Added support for old strscan. + * GH-132 + * Reported by Adam. + + * Improved attribute value parse performance. + * GH-135 + * Patch by NAITOH Jun. + + * Improved `REXML::Node#each_recursive` performance. + * GH-134 + * GH-139 + * Patch by Hiroya Fujinami. + + * Improved text parse performance. + * Reported by mprogrammer. + +### Thanks + + * Adam + * NAITOH Jun + * Hiroya Fujinami + * mprogrammer + +## 3.2.8 - 2024-05-16 {#version-3-2-8} + +### Fixes + + * Suppressed a warning + +## 3.2.7 - 2024-05-16 {#version-3-2-7} + +### Improvements + + * Improve parse performance by using `StringScanner`. + + * GH-106 + * GH-107 + * GH-108 + * GH-109 + * GH-112 + * GH-113 + * GH-114 + * GH-115 + * GH-116 + * GH-117 + * GH-118 + * GH-119 + * GH-121 + + * Patch by NAITOH Jun. + + * Improved parse performance when an attribute has many `>`s. + + * GH-126 + +### Fixes + + * XPath: Fixed a bug of `normalize_space(array)`. + + * GH-110 + * GH-111 + + * Patch by flatisland. + + * XPath: Fixed a bug that wrong position is used with nested path. + + * GH-110 + * GH-122 + + * Reported by jcavalieri. + * Patch by NAITOH Jun. + + * Fixed a bug that an exception message can't be generated for + invalid encoding XML. + + * GH-29 + * GH-123 + + * Reported by DuKewu. + * Patch by NAITOH Jun. + +### Thanks + + * NAITOH Jun + * flatisland + * jcavalieri + * DuKewu + +## 3.2.6 - 2023-07-27 {#version-3-2-6} + +### Improvements + + * Required Ruby 2.5 or later explicitly. + [GH-69][gh-69] + [Patch by Ivo Anjo] + + * Added documentation for maintenance cycle. + [GH-71][gh-71] + [Patch by Ivo Anjo] + + * Added tutorial. + [GH-77][gh-77] + [GH-78][gh-78] + [Patch by Burdette Lamar] + + * Improved performance and memory usage. + [GH-94][gh-94] + [Patch by fatkodima] + + * `REXML::Parsers::XPathParser#abbreviate`: Added support for + function arguments. + [GH-95][gh-95] + [Reported by pulver] + + * `REXML::Parsers::XPathParser#abbreviate`: Added support for string + literal that contains double-quote. + [GH-96][gh-96] + [Patch by pulver] + + * `REXML::Parsers::XPathParser#abbreviate`: Added missing `/` to + `:descendant_or_self/:self/:parent`. + [GH-97][gh-97] + [Reported by pulver] + + * `REXML::Parsers::XPathParser#abbreviate`: Added support for more patterns. + [GH-97][gh-97] + [Reported by pulver] + +### Fixes + + * Fixed a typo in NEWS. + [GH-72][gh-72] + [Patch by Spencer Goodman] + + * Fixed a typo in NEWS. + [GH-75][gh-75] + [Patch by Andrew Bromwich] + + * Fixed documents. + [GH-87][gh-87] + [Patch by Alexander Ilyin] + + * Fixed a bug that `Attriute` convert `'` and `'` even when + `attribute_quote: :quote` is used. + [GH-92][gh-92] + [Reported by Edouard Brière] + + * Fixed links in tutorial. + [GH-99][gh-99] + [Patch by gemmaro] + + +### Thanks + + * Ivo Anjo + + * Spencer Goodman + + * Andrew Bromwich + + * Burdette Lamar + + * Alexander Ilyin + + * Edouard Brière + + * fatkodima + + * pulver + + * gemmaro + +[gh-69]:https://github.com/ruby/rexml/issues/69 +[gh-71]:https://github.com/ruby/rexml/issues/71 +[gh-72]:https://github.com/ruby/rexml/issues/72 +[gh-75]:https://github.com/ruby/rexml/issues/75 +[gh-77]:https://github.com/ruby/rexml/issues/77 +[gh-87]:https://github.com/ruby/rexml/issues/87 +[gh-92]:https://github.com/ruby/rexml/issues/92 +[gh-94]:https://github.com/ruby/rexml/issues/94 +[gh-95]:https://github.com/ruby/rexml/issues/95 +[gh-96]:https://github.com/ruby/rexml/issues/96 +[gh-97]:https://github.com/ruby/rexml/issues/97 +[gh-98]:https://github.com/ruby/rexml/issues/98 +[gh-99]:https://github.com/ruby/rexml/issues/99 + +## 3.2.5 - 2021-04-05 {#version-3-2-5} + +### Improvements + + * Add more validations to XPath parser. + + * `require "rexml/document"` by default. + [GitHub#36][Patch by Koichi ITO] + + * Don't add `#dclone` method to core classes globally. + [GitHub#37][Patch by Akira Matsuda] + + * Add more documentations. + [Patch by Burdette Lamar] + + * Added `REXML::Elements#parent`. + [GitHub#52][Patch by Burdette Lamar] + +### Fixes + + * Fixed a bug that `REXML::DocType#clone` doesn't copy external ID + information. + + * Fixed round-trip vulnerability bugs. + See also: https://www.ruby-lang.org/en/news/2021/04/05/xml-round-trip-vulnerability-in-rexml-cve-2021-28965/ + [HackerOne#1104077][CVE-2021-28965][Reported by Juho Nurminen] + +### Thanks + + * Koichi ITO + + * Akira Matsuda + + * Burdette Lamar + + * Juho Nurminen + +## 3.2.4 - 2020-01-31 {#version-3-2-4} + +### Improvements + + * Don't use `taint` with Ruby 2.7 or later. + [GitHub#21][Patch by Jeremy Evans] + +### Fixes + + * Fixed a `elsif` typo. + [GitHub#22][Patch by Nobuyoshi Nakada] + +### Thanks + + * Jeremy Evans + + * Nobuyoshi Nakada + +## 3.2.3 - 2019-10-12 {#version-3-2-3} + +### Fixes + + * Fixed a bug that `REXML::XMLDecl#close` doesn't copy `@writethis`. + [GitHub#20][Patch by hirura] + +### Thanks + + * hirura + +## 3.2.2 - 2019-06-03 {#version-3-2-2} + +### Fixes + + * xpath: Fixed a bug for equality and relational expressions. + [GitHub#17][Reported by Mirko Budszuhn] + + * xpath: Fixed `boolean()` implementation. + + * xpath: Fixed `local_name()` with nonexistent node. + + * xpath: Fixed `number()` implementation with node set. + [GitHub#18][Reported by Mirko Budszuhn] + +### Thanks + + * Mirko Budszuhn + +## 3.2.1 - 2019-05-04 {#version-3-2-1} + +### Improvements + + * Improved error message. + [GitHub#12][Patch by FUJI Goro] + + * Improved error message. + [GitHub#16][Patch by ujihisa] + + * Improved documentation markup. + [GitHub#14][Patch by Alyssa Ross] + +### Fixes + + * Fixed a bug that `nil` variable value raises an unexpected exception. + [GitHub#13][Patch by Alyssa Ross] + +### Thanks + + * FUJI Goro + + * Alyssa Ross + + * ujihisa + +## 3.2.0 - 2019-01-01 {#version-3-2-0} + +### Fixes + + * Fixed a bug that no namespace attribute isn't matched with prefix. + + [ruby-list:50731][Reported by Yasuhiro KIMURA] + + * Fixed a bug that the default namespace is applied to attribute names. + + NOTE: It's a backward incompatible change. If your program has any + problem with this change, please report it. We may revert this fix. + + * `REXML::Attribute#prefix` returns `""` for no namespace attribute. + + * `REXML::Attribute#namespace` returns `""` for no namespace attribute. + +### Thanks + + * Yasuhiro KIMURA + +## 3.1.9 - 2018-12-20 {#version-3-1-9} + +### Improvements + + * Improved backward compatibility. + + Restored `REXML::Parsers::BaseParser::UNQME_STR` because it's used + by kramdown. + +## 3.1.8 - 2018-12-20 {#version-3-1-8} + +### Improvements + + * Added support for customizing quote character in prologue. + [GitHub#8][Bug #9367][Reported by Takashi Oguma] + + * You can use `"` as quote character by specifying `:quote` to + `REXML::Document#context[:prologue_quote]`. + + * You can use `'` as quote character by specifying `:apostrophe` + to `REXML::Document#context[:prologue_quote]`. + + * Added processing instruction target check. The target must not nil. + [GitHub#7][Reported by Ariel Zelivansky] + + * Added name check for element and attribute. + [GitHub#7][Reported by Ariel Zelivansky] + + * Stopped to use `Exception`. + [GitHub#9][Patch by Jean Boussier] + +### Fixes + + * Fixed a bug that `REXML::Text#clone` escapes value twice. + [ruby-dev:50626][Bug #15058][Reported by Ryosuke Nanba] + +### Thanks + + * Takashi Oguma + + * Ariel Zelivansky + + * Jean Boussier + + * Ryosuke Nanba diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/README.md ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/README.md --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/README.md 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/README.md 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,57 @@ +# REXML + +REXML was inspired by the Electric XML library for Java, which features an easy-to-use API, small size, and speed. Hopefully, REXML, designed with the same philosophy, has these same features. I've tried to keep the API as intuitive as possible, and have followed the Ruby methodology for method naming and code flow, rather than mirroring the Java API. + +REXML supports both tree and stream document parsing. Stream parsing is faster (about 1.5 times as fast). However, with stream parsing, you don't get access to features such as XPath. + +## API + +See the [API documentation](https://ruby.github.io/rexml/). + +## Usage + +We'll start with parsing an XML document + +```ruby +require "rexml/document" +file = File.new( "mydoc.xml" ) +doc = REXML::Document.new file +``` + +Line 3 creates a new document and parses the supplied file. You can also do the following + +```ruby +require "rexml/document" +include REXML # so that we don't have to prefix everything with REXML::... +string = <<EOF + <mydoc> + <someelement attribute="nanoo">Text, text, text</someelement> + </mydoc> +EOF +doc = Document.new string +``` + +So parsing a string is just as easy as parsing a file. + +## Support + +REXML support follows the same maintenance cycle as Ruby releases, as shown on <https://www.ruby-lang.org/en/downloads/branches/>. + +If you are running on an end-of-life Ruby, do not expect modern REXML releases to be compatible with it; in fact, it's recommended that you DO NOT use this gem, and instead use the REXML version that came bundled with your end-of-life Ruby version. + +The `required_ruby_version` on the gemspec is kept updated on a [best-effort basis](https://github.com/ruby/rexml/pull/70) by the community. +Up to version 3.2.5, this information was not set. That version [is known broken with at least Ruby < 2.3](https://github.com/ruby/rexml/issues/69). + +## Development + +After checking out the repo, run `rake test` to run the tests. + +To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org). + +## Contributing + +Bug reports and pull requests are welcome on GitHub at https://github.com/ruby/rexml. + +## License + +The gem is available as open source under the terms of the [BSD-2-Clause](LICENSE.txt). diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/context.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/context.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/context.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/context.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,143 @@ +== Element Context + +Notes: +- All code on this page presupposes that the following has been executed: + + require 'rexml/document' + +- For convenience, examples on this page use +REXML::Document.new+, not +REXML::Element.new+. + This is completely valid, because REXML::Document is a subclass of REXML::Element. + +The context for an element is a hash of processing directives +that influence the way \XML is read, stored, and written. +The context entries are: + +- +:respect_whitespace+: controls treatment of whitespace. +- +:compress_whitespace+: determines whether whitespace is compressed. +- +:ignore_whitespace_nodes+: determines whether whitespace-only nodes are to be ignored. +- +:raw+: controls treatment of special characters and entities. + +The default context for a new element is <tt>{}</tt>. +You can set the context at element-creation time: + + d = REXML::Document.new('', {compress_whitespace: :all, raw: :all}) + d.context # => {:compress_whitespace=>:all, :raw=>:all} + +You can reset the entire context by assigning a new hash: + + d.context = {ignore_whitespace_nodes: :all} + d.context # => {:ignore_whitespace_nodes=>:all} + +Or you can create or modify an individual entry: + + d.context[:raw] = :all + d.context # => {:ignore_whitespace_nodes=>:all, :raw=>:all} + +=== +:respect_whitespace+ + +Affects: +REXML::Element.new+, +REXML::Element.text=+. + +By default, all parsed whitespace is respected (that is, stored whitespace not compressed): + + xml_string = '<root><foo>a b</foo> <bar>c d</bar> <baz>e f</baz></root>' + d = REXML::Document.new(xml_string) + d.to_s # => "<root><foo>a b</foo> <bar>c d</bar> <baz>e f</baz></root>" + +Use +:respect_whitespace+ with an array of element names +to specify the elements that _are_ to have their whitespace respected; +other elements' whitespace, and whitespace between elements, will be compressed. + +In this example: +foo+ and +baz+ will have their whitespace respected; ++bar+ and the space between elements will have their whitespace compressed: + + d = REXML::Document.new(xml_string, {respect_whitespace: ['foo', 'baz']}) + d.to_s # => "<root><foo>a b</foo> <bar>c d</bar> <baz>e f</baz></root>" + bar = d.root[2] # => <bar> ... </> + bar.text = 'X Y' + d.to_s # => "<root><foo>a b</foo> <bar>X Y</bar> <baz>e f</baz></root>" + +=== +:compress_whitespace+ + +Affects: +REXML::Element.new+, +REXML::Element.text=+. + +Use <tt>compress_whitespace: :all</tt> +to compress whitespace both within and between elements: + + xml_string = '<root><foo>a b</foo> <bar>c d</bar> <baz>e f</baz></root>' + d = REXML::Document.new(xml_string, {compress_whitespace: :all}) + d.to_s # => "<root><foo>a b</foo> <bar>c d</bar> <baz>e f</baz></root>" + +Use +:compress_whitespace+ with an array of element names +to compress whitespace in those elements, +but not in other elements nor between elements. + +In this example, +foo+ and +baz+ will have their whitespace compressed; ++bar+ and the space between elements will not: + + d = REXML::Document.new(xml_string, {compress_whitespace: ['foo', 'baz']}) + d.to_s # => "<root><foo>a b</foo> <bar>c d</bar> <baz>e f</baz></root>" + foo = d.root[0] # => <foo> ... </> + foo.text= 'X Y' + d.to_s # => "<root><foo>X Y</foo> <bar>c d</bar> <baz>e f</baz></root>" + +=== +:ignore_whitespace_nodes+ + +Affects: +REXML::Element.new+. + +Use <tt>ignore_whitespace_nodes: :all</tt> to omit all whitespace-only elements. + +In this example, +bar+ has a text node, while nodes +foo+ and +baz+ do not: + + xml_string = '<root><foo> </foo><bar> BAR </bar><baz> </baz></root>' + d = REXML::Document.new(xml_string, {ignore_whitespace_nodes: :all}) + d.to_s # => "<root><foo> FOO </foo><bar/><baz> BAZ </baz></root>" + root = d.root # => <root> ... </> + foo = root[0] # => <foo/> + bar = root[1] # => <bar> ... </> + baz = root[2] # => <baz/> + foo.first.class # => NilClass + bar.first.class # => REXML::Text + baz.first.class # => NilClass + +Use +:ignore_whitespace_nodes+ with an array of element names +to specify the elements that are to have whitespace nodes ignored. + +In this example, +bar+ and +baz+ have text nodes, while node +foo+ does not. + + xml_string = '<root><foo> </foo><bar> BAR </bar><baz> </baz></root>' + d = REXML::Document.new(xml_string, {ignore_whitespace_nodes: ['foo']}) + d.to_s # => "<root><foo/><bar> BAR </bar><baz> </baz></root>" + root = d.root # => <root> ... </> + foo = root[0] # => <foo/> + bar = root[1] # => <bar> ... </> + baz = root[2] # => <baz> ... </> + foo.first.class # => NilClass + bar.first.class # => REXML::Text + baz.first.class # => REXML::Text + +=== +:raw+ + +Affects: +Element.text=+, +Element.add_text+, +Text.to_s+. + +Parsing of +a+ elements is not affected by +raw+: + + xml_string = '<root><a>0 < 1</a><b>1 > 0</b></root>' + d = REXML::Document.new(xml_string, {:raw => ['a']}) + d.root.to_s # => "<root><a>0 < 1</a><b>1 > 0</b></root>" + a, b = *d.root.elements + a.to_s # => "<a>0 < 1</a>" + b.to_s # => "<b>1 > 0</b>" + +But Element#text= is affected: + + a.text = '0 < 1' + b.text = '1 > 0' + a.to_s # => "<a>0 < 1</a>" + b.to_s # => "<b>1 &gt; 0</b>" + +As is Element.add_text: + + a.add_text(' so 1 > 0') + b.add_text(' so 0 < 1') + a.to_s # => "<a>0 < 1 so 1 > 0</a>" + b.to_s # => "<b>1 &gt; 0 so 0 &lt; 1</b>" diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/child.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/child.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/child.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/child.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,87 @@ +== Class Child + +Class Child includes module Node; +see {Tasks for Node}[node_rdoc.html]. + +:include: ../tocs/child_toc.rdoc + +=== Relationships + +==== Task: Set the Parent + +Use method {Child#parent=}[../../../../REXML/Parent.html#method-i-parent-3D] +to set the parent: + + e0 = REXML::Element.new('foo') + e1 = REXML::Element.new('bar') + e1.parent # => nil + e1.parent = e0 + e1.parent # => <foo/> + +==== Task: Insert Previous Sibling + +Use method {Child#previous_sibling=}[../../../../REXML/Parent.html#method-i-previous_sibling-3D] +to insert a previous sibling: + + xml_string = '<root><a/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.to_a # => [<a/>, <c/>] + c = d.root[1] # => <c/> + b = REXML::Element.new('b') + c.previous_sibling = b + d.root.to_a # => [<a/>, <b/>, <c/>] + +==== Task: Insert Next Sibling + +Use method {Child#next_sibling=}[../../../../REXML/Parent.html#method-i-next-sibling-3D] +to insert a previous sibling: + + xml_string = '<root><a/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.to_a # => [<a/>, <c/>] + a = d.root[0] # => <a/> + b = REXML::Element.new('b') + a.next_sibling = b + d.root.to_a # => [<a/>, <b/>, <c/>] + +=== Removal or Replacement + +==== Task: Remove Child from Parent + +Use method {Child#remove}[../../../../REXML/Parent.html#method-i-remove] +to remove a child from its parent; returns the removed child: + + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.to_a # => [<a/>, <b/>, <c/>] + b = d.root[1] # => <b/> + b.remove # => <b/> + d.root.to_a # => [<a/>, <c/>] + +==== Task: Replace Child + +Use method {Child#replace_with}[../../../../REXML/Parent.html#method-i-replace] +to replace a child; +returns the replaced child: + + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.to_a # => [<a/>, <b/>, <c/>] + b = d.root[1] # => <b/> + d = REXML::Element.new('d') + b.replace_with(d) # => <b/> + d.root.to_a # => [<a/>, <d/>, <c/>] + +=== Document + +==== Task: Get the Document + +Use method {Child#document}[../../../../REXML/Parent.html#method-i-document] +to get the document for the child: + + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.to_a # => [<a/>, <b/>, <c/>] + b = d.root[1] # => <b/> + b.document == d # => true + REXML::Child.new.document # => nil diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/document.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/document.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/document.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/document.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,276 @@ +== Class Document + +Class Document has methods from its superclasses and included modules; +see: + +- {Tasks for Element}[element_rdoc.html]. +- {Tasks for Parent}[parent_rdoc.html]. +- {Tasks for Child}[child_rdoc.html]. +- {Tasks for Node}[node_rdoc.html]. +- {Module Enumerable}[https://docs.ruby-lang.org/en/master/Enumerable.html]. + +:include: ../tocs/document_toc.rdoc + +=== New Document + +==== Task: Create an Empty Document + +Use method {Document::new}[../../../../REXML/Document.html#method-c-new] +to create an empty document. + + d = REXML::Document.new + +==== Task: Parse a \String into a New Document + +Use method {Document::new}[../../../../REXML/Document.html#method-c-new] +to parse an XML string into a new document: + + xml_string = '<root><a/>text<b/>more<c/></root>' + d = REXML::Document.new(xml_string) + d.root # => <root> ... </> + +==== Task: Parse an \IO Stream into a New Document + +Use method {Document::new}[../../../../REXML/Document.html#method-c-new] +to parse an XML \IO stream into a new document: + + xml_string = '<root><a/>text<b/>more<c/></root>' + File.write('t.xml', xml_string) + d = File.open('t.xml', 'r') do |file| + REXML::Document.new(file) + end + d.root # => <root> ... </> + +==== Task: Create a Document from an Existing Document + +Use method {Document::new}[../../../../REXML/Document.html#method-c-new] +to create a document from an existing document. +The context and attributes are copied to the new document, +but not the children: + + xml_string = '<root><a/>text<b/>more<c/></root>' + d = REXML::Document.new(xml_string) + d.children # => [<root> ... </>] + d.context = {raw: :all, compress_whitespace: :all} + d.add_attributes({'bar' => 0, 'baz' => 1}) + d1 = REXML::Document.new(d) + d1.context # => {:raw=>:all, :compress_whitespace=>:all} + d1.attributes # => {"bar"=>bar='0', "baz"=>baz='1'} + d1.children # => [] + +==== Task: Clone a Document + +Use method {Document#clone}[../../../../REXML/Document.html#method-i-clone] +to clone a document. +The context and attributes are copied to the new document, +but not the children: + + xml_string = '<root><a/>text<b/>more<c/></root>' + d = REXML::Document.new(xml_string) + d.children # => [<root> ... </>] + d.context = {raw: :all, compress_whitespace: :all} + d.add_attributes({'bar' => 0, 'baz' => 1}) + d1 = d.clone # => < bar='0' baz='1'/> + d1.context # => {:raw=>:all, :compress_whitespace=>:all} + d1.attributes # => {"bar"=>bar='0', "baz"=>baz='1'} + d1.children # => [] + +=== Document Type + +==== Task: Get the Document Type + +Use method {Document#doctype}[../../../../REXML/Document.html#method-i-doctype] +to get the document type: + + d = REXML::Document.new('<!DOCTYPE document SYSTEM "subjects.dtd">') + d.doctype.class # => REXML::DocType + d = REXML::Document.new('') + d.doctype.class # => nil + +==== Task: Set the Document Type + +Use method {document#add}[../../../../REXML/Document.html#method-i-add] +to add or replace the document type: + + d = REXML::Document.new('') + d.doctype.class # => nil + d.add(REXML::DocType.new('foo')) + d.doctype.class # => REXML::DocType + +=== XML Declaration + +==== Task: Get the XML Declaration + +Use method {document#xml_decl}[../../../../REXML/Document.html#method-i-xml_decl] +to get the XML declaration: + + d = REXML::Document.new('<!DOCTYPE document SYSTEM "subjects.dtd">') + d.xml_decl.class # => REXML::XMLDecl + d.xml_decl # => <?xml ... ?> + d = REXML::Document.new('') + d.xml_decl.class # => REXML::XMLDecl + d.xml_decl # => <?xml ... ?> + +==== Task: Set the XML Declaration + +Use method {document#add}[../../../../REXML/Document.html#method-i-add] +to replace the XML declaration: + + d = REXML::Document.new('<!DOCTYPE document SYSTEM "subjects.dtd">') + d.add(REXML::XMLDecl.new) + +=== Children + +==== Task: Add an Element Child + +Use method +{document#add_element}[../../../../REXML/Document.html#method-i-add_element] +to add an element to the document: + + d = REXML::Document.new('') + d.add_element(REXML::Element.new('root')) + d.children # => [<root/>] + +==== Task: Add a Non-Element Child + +Use method +{document#add}[../../../../REXML/Document.html#method-i-add] +to add a non-element to the document: + + xml_string = '<root><a/>text<b/>more<c/></root>' + d = REXML::Document.new(xml_string) + d.add(REXML::Text.new('foo')) + d.children # => [<root> ... </>, "foo"] + +=== Writing + +==== Task: Write to $stdout + +Use method +{document#write}[../../../../REXML/Document.html#method-i-write] +to write the document to <tt>$stdout</tt>: + + xml_string = '<root><a/>text<b/>more<c/></root>' + d = REXML::Document.new(xml_string) + d.write + +Output: + + <root><a/>text<b/>more<c/></root> + +==== Task: Write to IO Stream + +Use method +{document#write}[../../../../REXML/Document.html#method-i-write] +to write the document to <tt>$stdout</tt>: + + xml_string = '<root><a/>text<b/>more<c/></root>' + d = REXML::Document.new(xml_string) + File.open('t.xml', 'w') do |file| + d.write(file) + end + p File.read('t.xml') + +Output: + + "<root><a/>text<b/>more<c/></root>" + +==== Task: Write with No Indentation + +Use method +{document#write}[../../../../REXML/Document.html#method-i-write] +to write the document with no indentation: + + xml_string = '<root><a><b><c></c></b></a></root>' + d = REXML::Document.new(xml_string) + d.write({indent: 0}) + +Output: + + <root> + <a> + <b> + <c/> + </b> + </a> + </root> + +==== Task: Write with Specified Indentation + +Use method +{document#write}[../../../../REXML/Document.html#method-i-write] +to write the document with a specified indentation: + + xml_string = '<root><a><b><c></c></b></a></root>' + d = REXML::Document.new(xml_string) + d.write({indent: 2}) + +Output: + + <root> + <a> + <b> + <c/> + </b> + </a> + </root> + +=== Querying + +==== Task: Get the Document + +Use method +{document#document}[../../../../REXML/Document.html#method-i-document] +to get the document (+self+); overrides <tt>Element#document</tt>: + + xml_string = '<root><a><b><c></c></b></a></root>' + d = REXML::Document.new(xml_string) + d.document == d # => true + +==== Task: Get the Encoding + +Use method +{document#document}[../../../../REXML/Document.html#method-i-document] +to get the document (+self+); overrides <tt>Element#document</tt>: + + xml_string = '<root><a><b><c></c></b></a></root>' + d = REXML::Document.new(xml_string) + d.encoding # => "UTF-8" + +==== Task: Get the Node Type + +Use method +{document#node_type}[../../../../REXML/Document.html#method-i-node_type] +to get the node type (+:document+); overrides <tt>Element#node_type</tt>: + + xml_string = '<root><a><b><c></c></b></a></root>' + d = REXML::Document.new(xml_string) + d.node_type # => :document + +==== Task: Get the Root Element + +Use method +{document#root}[../../../../REXML/Document.html#method-i-root] +to get the root element: + + xml_string = '<root><a><b><c></c></b></a></root>' + d = REXML::Document.new(xml_string) + d.root # => <root> ... </> + +==== Task: Determine Whether Stand-Alone + +Use method +{document#stand_alone?}[../../../../REXML/Document.html#method-i-stand_alone-3F] +to get the stand-alone value: + + d = REXML::Document.new('<?xml standalone="yes"?>') + d.stand_alone? # => "yes" + +==== Task: Get the Version + +Use method +{document#version}[../../../../REXML/Document.html#method-i-version] +to get the version: + + d = REXML::Document.new('<?xml version="2.0" encoding="UTF-8"?>') + d.version # => "2.0" diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/element.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/element.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/element.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/element.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,602 @@ +== Class Element + +Class Element has methods from its superclasses and included modules; +see: + +- {Tasks for Parent}[parent_rdoc.html]. +- {Tasks for Child}[child_rdoc.html]. +- {Tasks for Node}[node_rdoc.html]. +- {Module Enumerable}[https://docs.ruby-lang.org/en/master/Enumerable.html]. + +:include: ../tocs/element_toc.rdoc + +=== New Element + +==== Task: Create a Default Element + +Use method +{Element::new}[../../../../REXML/Element.html#method-c-new] +with no arguments to create a default element: + + e = REXML::Element.new + e.name # => "UNDEFINED" + e.parent # => nil + e.context # => nil + +==== Task: Create a Named Element + +Use method +{Element::new}[../../../../REXML/Element.html#method-c-new] +with a string name argument +to create a named element: + + e = REXML::Element.new('foo') + e.name # => "foo" + e.parent # => nil + e.context # => nil + +==== Task: Create an Element with Name and Parent + +Use method +{Element::new}[../../../../REXML/Element.html#method-c-new] +with name and parent arguments +to create an element with name and parent: + + p = REXML::Parent.new + e = REXML::Element.new('foo', p) + e.name # => "foo" + e.parent # => #<REXML::Parent @parent=nil, @children=[<foo/>]> + e.context # => nil + +==== Task: Create an Element with Name, Parent, and Context + +Use method +{Element::new}[../../../../REXML/Element.html#method-c-new] +with name, parent, and context arguments +to create an element with name, parent, and context: + + p = REXML::Parent.new + e = REXML::Element.new('foo', p, {compress_whitespace: :all}) + e.name # => "foo" + e.parent # => #<REXML::Parent @parent=nil, @children=[<foo/>]> + e.context # => {:compress_whitespace=>:all} + +==== Task: Create a Shallow Clone + +Use method +{Element#clone}[../../../../REXML/Element.html#method-i-clone] +to create a shallow clone of an element, +copying only the name, attributes, and context: + + e0 = REXML::Element.new('foo', nil, {compress_whitespace: :all}) + e0.add_attribute(REXML::Attribute.new('bar', 'baz')) + e0.context = {compress_whitespace: :all} + e1 = e0.clone # => <foo bar='baz'/> + e1.name # => "foo" + e1.context # => {:compress_whitespace=>:all} + +=== Attributes + +==== Task: Create and Add an Attribute + +Use method +{Element#add_attribute}[../../../../REXML/Element.html#method-i-add_attribute] +to create and add an attribute: + + e = REXML::Element.new + e.add_attribute('attr', 'value') # => "value" + e['attr'] # => "value" + e.add_attribute('attr', 'VALUE') # => "VALUE" + e['attr'] # => "VALUE" + +==== Task: Add an Existing Attribute + +Use method +{Element#add_attribute}[../../../../REXML/Element.html#method-i-add_attribute] +to add an existing attribute: + + e = REXML::Element.new + a = REXML::Attribute.new('attr', 'value') + e.add_attribute(a) + e['attr'] # => "value" + a = REXML::Attribute.new('attr', 'VALUE') + e.add_attribute(a) + e['attr'] # => "VALUE" + +==== Task: Add Multiple Attributes from a Hash + +Use method +{Element#add_attributes}[../../../../REXML/Element.html#method-i-add_attributes] +to add multiple attributes from a hash: + + e = REXML::Element.new + h = {'foo' => 0, 'bar' => 1} + e.add_attributes(h) + e['foo'] # => "0" + e['bar'] # => "1" + +==== Task: Add Multiple Attributes from an Array + +Use method +{Element#add_attributes}[../../../../REXML/Element.html#method-i-add_attributes] +to add multiple attributes from an array: + + e = REXML::Element.new + a = [['foo', 0], ['bar', 1]] + e.add_attributes(a) + e['foo'] # => "0" + e['bar'] # => "1" + +==== Task: Retrieve the Value for an Attribute Name + +Use method +{Element#[]}[../../../../REXML/Element.html#method-i-5B-5D] +to retrieve the value for an attribute name: + + e = REXML::Element.new + e.add_attribute('attr', 'value') # => "value" + e['attr'] # => "value" + +==== Task: Retrieve the Attribute Value for a Name and Namespace + +Use method +{Element#attribute}[../../../../REXML/Element.html#method-i-attribute] +to retrieve the value for an attribute name: + + xml_string = "<root xmlns:a='a' a:x='a:x' x='x'/>" + d = REXML::Document.new(xml_string) + e = d.root + e.attribute("x") # => x='x' + e.attribute("x", "a") # => a:x='a:x' + +==== Task: Delete an Attribute + +Use method +{Element#delete_attribute}[../../../../REXML/Element.html#method-i-delete_attribute] +to remove an attribute: + + e = REXML::Element.new('foo') + e.add_attribute('bar', 'baz') + e.delete_attribute('bar') + e.delete_attribute('bar') + e['bar'] # => nil + +==== Task: Determine Whether the Element Has Attributes + +Use method +{Element#has_attributes?}[../../../../REXML/Element.html#method-i-has_attributes-3F] +to determine whether the element has attributes: + + e = REXML::Element.new('foo') + e.has_attributes? # => false + e.add_attribute('bar', 'baz') + e.has_attributes? # => true + +=== Children + +<em>Element Children</em> + +==== Task: Create and Add an Element + +Use method +{Element#add_element}[../../../../REXML/Element.html#method-i-add_element] +to create a new element and add it to this element: + + e0 = REXML::Element.new('foo') + e0.add_element('bar') + e0.children # => [<bar/>] + +==== Task: Add an Existing Element + +Use method +{Element#add_element}[../../../../REXML/Element.html#method-i-add_element] +to add an element to this element: + + e0 = REXML::Element.new('foo') + e1 = REXML::Element.new('bar') + e0.add_element(e1) + e0.children # => [<bar/>] + +==== Task: Create and Add an Element with Attributes + +Use method +{Element#add_element}[../../../../REXML/Element.html#method-i-add_element] +to create a new element with attributes, and add it to this element: + + e0 = REXML::Element.new('foo') + e0.add_element('bar', {'name' => 'value'}) + e0.children # => [<bar name='value'/>] + +==== Task: Add an Existing Element with Added Attributes + +Use method +{Element#add_element}[../../../../REXML/Element.html#method-i-add_element] +to add an element to this element: + + e0 = REXML::Element.new('foo') + e1 = REXML::Element.new('bar') + e0.add_element(e1, {'name' => 'value'}) + e0.children # => [<bar name='value'/>] + +==== Task: Delete a Specified Element + +Use method +{Element#delete_element}[../../../../REXML/Element.html#method-i-delete_element] +to remove a specified element from this element: + + e0 = REXML::Element.new('foo') + e1 = REXML::Element.new('bar') + e0.add_element(e1) + e0.children # => [<bar/>] + e0.delete_element(e1) + e0.children # => [] + +==== Task: Delete an Element by Index + +Use method +{Element#delete_element}[../../../../REXML/Element.html#method-i-delete_element] +to remove an element from this element by index: + + e0 = REXML::Element.new('foo') + e1 = REXML::Element.new('bar') + e0.add_element(e1) + e0.children # => [<bar/>] + e0.delete_element(1) + e0.children # => [] + +==== Task: Delete an Element by XPath + +Use method +{Element#delete_element}[../../../../REXML/Element.html#method-i-delete_element] +to remove an element from this element by XPath: + + e0 = REXML::Element.new('foo') + e1 = REXML::Element.new('bar') + e0.add_element(e1) + e0.children # => [<bar/>] + e0.delete_element('//bar/') + e0.children # => [] + +==== Task: Determine Whether Element Children + +Use method +{Element#has_elements?}[../../../../REXML/Element.html#method-i-has_elements-3F] +to determine whether the element has element children: + + e0 = REXML::Element.new('foo') + e0.has_elements? # => false + e0.add_element(REXML::Element.new('bar')) + e0.has_elements? # => true + +==== Task: Get Element Descendants by XPath + +Use method +{Element#get_elements}[../../../../REXML/Element.html#method-i-get_elements] +to fetch all element descendant children by XPath: + + xml_string = <<-EOT + <root> + <a level='1'> + <a level='2'/> + </a> + </root> + EOT + d = REXML::Document.new(xml_string) + d.root.get_elements('//a') # => [<a level='1'> ... </>, <a level='2'/>] + +==== Task: Get Next Element Sibling + +Use method +{Element#next_element}[../../../../REXML/Element.html#method-i-next_element] +to retrieve the next element sibling: + + d = REXML::Document.new '<a><b/>text<c/></a>' + d.root.elements['b'].next_element #-> <c/> + d.root.elements['c'].next_element #-> nil + +==== Task: Get Previous Element Sibling + +Use method +{Element#previous_element}[../../../../REXML/Element.html#method-i-previous_element] +to retrieve the previous element sibling: + + d = REXML::Document.new '<a><b/>text<c/></a>' + d.root.elements['c'].previous_element #-> <b/> + d.root.elements['b'].previous_element #-> nil + +<em>Text Children</em> + +==== Task: Add a Text Node + +Use method +{Element#add_text}[../../../../REXML/Element.html#method-i-add_text] +to add a text node to the element: + + d = REXML::Document.new('<a>foo<b/>bar</a>') + e = d.root + e.add_text(REXML::Text.new('baz')) + e.to_a # => ["foo", <b/>, "bar", "baz"] + e.add_text(REXML::Text.new('baz')) + e.to_a # => ["foo", <b/>, "bar", "baz", "baz"] + +==== Task: Replace the First Text Node + +Use method +{Element#text=}[../../../../REXML/Element.html#method-i-text-3D] +to replace the first text node in the element: + + d = REXML::Document.new('<root><a/>text<b/>more<c/></root>') + e = d.root + e.to_a # => [<a/>, "text", <b/>, "more", <c/>] + e.text = 'oops' + e.to_a # => [<a/>, "oops", <b/>, "more", <c/>] + +==== Task: Remove the First Text Node + +Use method +{Element#text=}[../../../../REXML/Element.html#method-i-text-3D] +to remove the first text node in the element: + + d = REXML::Document.new('<root><a/>text<b/>more<c/></root>') + e = d.root + e.to_a # => [<a/>, "text", <b/>, "more", <c/>] + e.text = nil + e.to_a # => [<a/>, <b/>, "more", <c/>] + +==== Task: Retrieve the First Text Node + +Use method +{Element#get_text}[../../../../REXML/Element.html#method-i-get_text] +to retrieve the first text node in the element: + + d = REXML::Document.new('<root><a/>text<b/>more<c/></root>') + e = d.root + e.to_a # => [<a/>, "text", <b/>, "more", <c/>] + e.get_text # => "text" + +==== Task: Retrieve a Specific Text Node + +Use method +{Element#get_text}[../../../../REXML/Element.html#method-i-get_text] +to retrieve the first text node in a specified element: + + d = REXML::Document.new "<root>some text <b>this is bold!</b> more text</root>" + e = d.root + e.get_text('//root') # => "some text " + e.get_text('//b') # => "this is bold!" + +==== Task: Determine Whether the Element has Text Nodes + +Use method +{Element#has_text?}[../../../../REXML/Element.html#method-i-has_text-3F] +to determine whether the element has text: + + e = REXML::Element.new('foo') + e.has_text? # => false + e.add_text('bar') + e.has_text? # => true + +<em>Other Children</em> + +==== Task: Get the Child at a Given Index + +Use method +{Element#[]}[../../../../REXML/Element.html#method-i-5B-5D] +to retrieve the child at a given index: + + d = REXML::Document.new '><root><a/>text<b/>more<c/></root>' + e = d.root + e[0] # => <a/> + e[1] # => "text" + e[2] # => <b/> + +==== Task: Get All CDATA Children + +Use method +{Element#cdatas}[../../../../REXML/Element.html#method-i-cdatas] +to retrieve all CDATA children: + + xml_string = <<-EOT + <root> + <![CDATA[foo]]> + <![CDATA[bar]]> + </root> + EOT + d = REXML::Document.new(xml_string) + d.root.cdatas # => ["foo", "bar"] + +==== Task: Get All Comment Children + +Use method +{Element#comments}[../../../../REXML/Element.html#method-i-comments] +to retrieve all comment children: + + xml_string = <<-EOT + <root> + <!--foo--> + <!--bar--> + </root> + EOT + d = REXML::Document.new(xml_string) + d.root.comments.map {|comment| comment.to_s } # => ["foo", "bar"] + +==== Task: Get All Processing Instruction Children + +Use method +{Element#instructions}[../../../../REXML/Element.html#method-i-instructions] +to retrieve all processing instruction children: + + xml_string = <<-EOT + <root> + <?target0 foo?> + <?target1 bar?> + </root> + EOT + d = REXML::Document.new(xml_string) + instructions = d.root.instructions.map {|instruction| instruction.to_s } + instructions # => ["<?target0 foo?>", "<?target1 bar?>"] + +==== Task: Get All Text Children + +Use method +{Element#texts}[../../../../REXML/Element.html#method-i-texts] +to retrieve all text children: + + xml_string = '<root><a/>text<b/>more<c/></root>' + d = REXML::Document.new(xml_string) + d.root.texts # => ["text", "more"] + +=== Namespaces + +==== Task: Add a Namespace + +Use method +{Element#add_namespace}[../../../../REXML/Element.html#method-i-add_namespace] +to add a namespace to the element: + + e = REXML::Element.new('foo') + e.add_namespace('bar') + e.namespaces # => {"xmlns"=>"bar"} + +==== Task: Delete the Default Namespace + +Use method +{Element#delete_namespace}[../../../../REXML/Element.html#method-i-delete_namespace] +to remove the default namespace from the element: + + d = REXML::Document.new "<a xmlns:foo='bar' xmlns='twiddle'/>" + d.to_s # => "<a xmlns:foo='bar' xmlns='twiddle'/>" + d.root.delete_namespace # => <a xmlns:foo='bar'/> + d.to_s # => "<a xmlns:foo='bar'/>" + +==== Task: Delete a Specific Namespace + +Use method +{Element#delete_namespace}[../../../../REXML/Element.html#method-i-delete_namespace] +to remove a specific namespace from the element: + + d = REXML::Document.new "<a xmlns:foo='bar' xmlns='twiddle'/>" + d.to_s # => "<a xmlns:foo='bar' xmlns='twiddle'/>" + d.root.delete_namespace # => <a xmlns:foo='bar'/> + d.to_s # => "<a xmlns:foo='bar'/>" + d.root.delete_namespace('foo') + d.to_s # => "<a/>" + +==== Task: Get a Namespace URI + +Use method +{Element#namespace}[../../../../REXML/Element.html#method-i-namespace] +to retrieve a specific namespace URI for the element: + + xml_string = <<-EOT + <root> + <a xmlns='1' xmlns:y='2'> + <b/> + <c xmlns:z='3'/> + </a> + </root> + EOT + d = REXML::Document.new(xml_string) + b = d.elements['//b'] + b.namespace # => "1" + b.namespace('y') # => "2" + +==== Task: Retrieve Namespaces + +Use method +{Element#namespaces}[../../../../REXML/Element.html#method-i-namespaces] +to retrieve all namespaces for the element: + + xml_string = '<a xmlns="foo" xmlns:x="bar" xmlns:y="twee" z="glorp"/>' + d = REXML::Document.new(xml_string) + d.root.attributes.namespaces # => {"xmlns"=>"foo", "x"=>"bar", "y"=>"twee"} + +==== Task: Retrieve Namespace Prefixes + +Use method +{Element#prefixes}[../../../../REXML/Element.html#method-i-prefixes] +to retrieve all prefixes (namespace names) for the element: + + xml_string = <<-EOT + <root> + <a xmlns:x='1' xmlns:y='2'> + <b/> + <c xmlns:z='3'/> + </a> + </root> + EOT + d = REXML::Document.new(xml_string, {compress_whitespace: :all}) + d.elements['//a'].prefixes # => ["x", "y"] + d.elements['//b'].prefixes # => ["x", "y"] + d.elements['//c'].prefixes # => ["x", "y", "z"] + +=== Iteration + +==== Task: Iterate Over Elements + +Use method +{Element#each_element}[../../../../REXML/Element.html#method-i-each_element] +to iterate over element children: + + d = REXML::Document.new '<a><b>b</b><c>b</c><d>d</d><e/></a>' + d.root.each_element {|e| p e } + +Output: + + <b> ... </> + <c> ... </> + <d> ... </> + <e/> + +==== Task: Iterate Over Elements Having a Specified Attribute + +Use method +{Element#each_element_with_attribute}[../../../../REXML/Element.html#method-i-each_element_with_attribute] +to iterate over element children that have a specified attribute: + + d = REXML::Document.new '<a><b id="1"/><c id="2"/><d id="1"/><e/></a>' + a = d.root + a.each_element_with_attribute('id') {|e| p e } + +Output: + + <b id='1'/> + <c id='2'/> + <d id='1'/> + +==== Task: Iterate Over Elements Having a Specified Attribute and Value + +Use method +{Element#each_element_with_attribute}[../../../../REXML/Element.html#method-i-each_element_with_attribute] +to iterate over element children that have a specified attribute and value: + + d = REXML::Document.new '<a><b id="1"/><c id="2"/><d id="1"/><e/></a>' + a = d.root + a.each_element_with_attribute('id', '1') {|e| p e } + +Output: + + <b id='1'/> + <d id='1'/> + +==== Task: Iterate Over Elements Having Specified Text + +Use method +{Element#each_element_with_text}[../../../../REXML/Element.html#method-i-each_element_with_text] +to iterate over element children that have specified text: + + +=== Context + +#whitespace +#ignore_whitespace_nodes +#raw + +=== Other Getters + +#document +#root +#root_node +#node_type +#xpath +#inspect diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/node.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/node.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/node.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/node.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,97 @@ +== Module Node + +:include: ../tocs/node_toc.rdoc + +=== Siblings + +==== Task: Find Previous Sibling + +Use method +{Node.previous_sibling_node}[../../../../REXML/Node.html#method-i-previous_sibling] +to retrieve the previous sibling: + + d = REXML::Document.new('<root><a/><b/><c/></root>') + b = d.root[1] # => <b/> + b.previous_sibling_node # => <a/> + +==== Task: Find Next Sibling + +Use method +{Node.next_sibling_node}[../../../../REXML/Node.html#method-i-next_sibling] +to retrieve the next sibling: + + d = REXML::Document.new('<root><a/><b/><c/></root>') + b = d.root[1] # => <b/> + b.next_sibling_node # => <c/> + +=== Position + +==== Task: Find Own Index Among Siblings + +Use method +{Node.index_in_parent}[../../../../REXML/Node.html#method-i-index_in_parent] +to retrieve the 1-based index of this node among its siblings: + + d = REXML::Document.new('<root><a/><b/><c/></root>') + b = d.root[1] # => <b/> + b.index_in_parent # => 2 + +=== Recursive Traversal + +==== Task: Traverse Each Recursively + +Use method +{Node.each_recursive}[../../../../REXML/Node.html#method-i-each_recursive] +to traverse a tree of nodes recursively: + + xml_string = '<root><a><b><c></c></b><b><c></c></b></a></root>' + d = REXML::Document.new(xml_string) + d.root.each_recursive {|node| p node } + +Output: + + <a> ... </> + <b> ... </> + <c/> + <b> ... </> + <c/> + +=== Recursive Search + +==== Task: Traverse Each Recursively + +Use method +{Node.find_first_recursive}[../../../../REXML/Node.html#method-i-find_first_recursive] +to search a tree of nodes recursively: + + xml_string = '<root><a><b><c></c></b><b><c></c></b></a></root>' + d = REXML::Document.new(xml_string) + d.root.find_first_recursive {|node| node.name == 'c' } # => <c/> + +=== Representation + +==== Task: Represent a String + +Use method {Node.to_s}[../../../../REXML/Node.html#method-i-to_s] +to represent the node as a string: + + xml_string = '<root><a><b><c></c></b><b><c></c></b></a></root>' + d = REXML::Document.new(xml_string) + d.root.to_s # => "<root><a><b><c/></b><b><c/></b></a></root>" + +=== Parent? + +==== Task: Determine Whether the Node is a Parent + +Use method {Node.parent?}[../../../../REXML/Node.html#method-i-parent-3F] +to determine whether the node is a parent; +class Text derives from Node: + + d = REXML::Document.new('<root><a/>text<b/>more<c/></root>') + t = d.root[1] # => "text" + t.parent? # => false + +Class Parent also derives from Node, but overrides this method: + + p = REXML::Parent.new + p.parent? # => true diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/parent.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/parent.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/parent.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/rdoc/parent.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,267 @@ +== Class Parent + +Class Parent has methods from its superclasses and included modules; +see: + +- {Tasks for Child}[child_rdoc.html]. +- {Tasks for Node}[node_rdoc.html]. +- {Module Enumerable}[https://docs.ruby-lang.org/en/master/Enumerable.html]. + +:include: ../tocs/parent_toc.rdoc + +=== Queries + +==== Task: Get the Count of Children + +Use method {Parent#size}[../../../../REXML/Parent.html#method-i-size] +(or its alias +length+) to get the count of the parent's children: + + p = REXML::Parent.new + p.size # => 0 + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.size # => 3 + +==== Task: Get the Child at a Given Index + +Use method {Parent#[]}[../../../../REXML/Parent.html#method-i-5B-5D] +to get the child at a given index: + + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root[1] # => <b/> + d.root[-1] # => <c/> + d.root[50] # => nil + +==== Task: Get the Index of a Given Child + +Use method {Parent#index}[../../../../REXML/Parent.html#method-i-index] +to get the index (0-based offset) of a child: + + d = REXML::Document.new('<root></root>') + root = d.root + e0 = REXML::Element.new('foo') + e1 = REXML::Element.new('bar') + root.add(e0) # => <foo/> + root.add(e1) # => <bar/> + root.add(e0) # => <foo/> + root.add(e1) # => <bar/> + root.index(e0) # => 0 + root.index(e1) # => 1 + +==== Task: Get the Children + +Use method {Parent#children}[../../../../REXML/Parent.html#method-i-children] +(or its alias +to_a+) to get the parent's children: + + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.children # => [<a/>, <b/>, <c/>] + +==== Task: Determine Whether the Node is a Parent + +Use method {Parent#parent?}[../../../../REXML/Parent.html#method-i-parent-3F] +to determine whether the node is a parent; +class Text derives from Node: + + d = REXML::Document.new('<root><a/>text<b/>more<c/></root>') + t = d.root[1] # => "text" + t.parent? # => false + +Class Parent also derives from Node, but overrides this method: + + p = REXML::Parent.new + p.parent? # => true + +=== Additions + +==== Task: Add a Child at the Beginning + +Use method {Parent#unshift}[../../../../REXML/Parent.html#method-i-unshift] +to add a child as at the beginning of the children: + + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.children # => [<a/>, <b/>, <c/>] + d.root.unshift REXML::Element.new('d') + d.root.children # => [<d/>, <a/>, <b/>, <c/>] + +==== Task: Add a Child at the End + +Use method {Parent#<<}[../../../../REXML/Parent.html#method-i-3C-3C] +(or an alias +push+ or +add+) to add a child as at the end of the children: + + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.children # => [<a/>, <b/>, <c/>] + d.root << REXML::Element.new('d') + d.root.children # => [<a/>, <b/>, <c/>, <d/>] + +==== Task: Replace a Child with Another Child + +Use method {Parent#replace}[../../../../REXML/Parent.html#method-i-replace] + + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.children # => [<a/>, <b/>, <c/>] + b = d.root[1] # => <b/> + d.replace_child(b, REXML::Element.new('d')) + d.root.children # => [<a/>, <c/>] + +==== Task: Replace Multiple Children with Another Child + +Use method {Parent#[]=}[../../../../REXML/Parent.html#method-i-parent-5B-5D-3D] +to replace multiple consecutive children with another child: + + xml_string = '<root><a/><b/><c/><d/></root>' + d = REXML::Document.new(xml_string) + d.root.children # => [<a/>, <b/>, <c/>, <d/>] + d.root[1, 2] = REXML::Element.new('x') + d.root.children # => [<a/>, <x/>, <d/>] + d.root[1, 5] = REXML::Element.new('x') + d.root.children # => [<a/>, <x/>] # BUG? + +==== Task: Insert Child Before a Given Child + +Use method {Parent#insert_before}[../../../../REXML/Parent.html#method-i-insert_before] +to insert a child immediately before a given child: + + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.children # => [<a/>, <b/>, <c/>] + b = d.root[1] # => <b/> + x = REXML::Element.new('x') + d.root.insert_before(b, x) + d.root.children # => [<a/>, <x/>, <b/>, <c/>] + +==== Task: Insert Child After a Given Child + +Use method {Parent#insert_after}[../../../../REXML/Parent.html#method-i-insert_after] +to insert a child immediately after a given child: + + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.children # => [<a/>, <b/>, <c/>] + b = d.root[1] # => <b/> + x = REXML::Element.new('x') + d.root.insert_after(b, x) + d.root.children # => [<a/>, <b/>, <x/>, <c/>] + +=== Deletions + +==== Task: Remove a Given Child + +Use method {Parent#delete}[../../../../REXML/Parent.html#method-i-delete] +to remove all occurrences of a given child: + + d = REXML::Document.new('<root></root>') + a = REXML::Element.new('a') + b = REXML::Element.new('b') + d.root.add(a) + d.root.add(b) + d.root.add(a) + d.root.add(b) + d.root.children # => [<a/>, <b/>, <a/>, <b/>] + d.root.delete(b) + d.root.children # => [<a/>, <a/>] + +==== Task: Remove the Child at a Specified Offset + +Use method {Parent#delete_at}[../../../../REXML/Parent.html#method-i-delete_at] +to remove the child at a specified offset: + + d = REXML::Document.new('<root></root>') + a = REXML::Element.new('a') + b = REXML::Element.new('b') + d.root.add(a) + d.root.add(b) + d.root.add(a) + d.root.add(b) + d.root.children # => [<a/>, <b/>, <a/>, <b/>] + d.root.delete_at(2) + d.root.children # => [<a/>, <b/>, <b/>] + +==== Task: Remove Children That Meet Specified Criteria + +Use method {Parent#delete_if}[../../../../REXML/Parent.html#method-i-delete_if] +to remove children that meet criteria specified in the given block: + + d = REXML::Document.new('<root></root>') + d.root.add(REXML::Element.new('x')) + d.root.add(REXML::Element.new('xx')) + d.root.add(REXML::Element.new('xxx')) + d.root.add(REXML::Element.new('xxxx')) + d.root.children # => [<x/>, <xx/>, <xxx/>, <xxxx/>] + d.root.delete_if {|child| child.name.size.odd? } + d.root.children # => [<xx/>, <xxxx/>] + +=== Iterations + +==== Task: Iterate Over Children + +Use method {Parent#each_child}[../../../../REXML/Parent.html#method-i-each_child] +(or its alias +each+) to iterate over all children: + + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.children # => [<a/>, <b/>, <c/>] + d.root.each_child {|child| p child } + +Output: + + <a/> + <b/> + <c/> + +==== Task: Iterate Over Child Indexes + +Use method {Parent#each_index}[../../../../REXML/Parent.html#method-i-each_index] +to iterate over all child indexes: + + xml_string = '<root><a/><b/><c/></root>' + d = REXML::Document.new(xml_string) + d.root.children # => [<a/>, <b/>, <c/>] + d.root.each_index {|child| p child } + +Output: + + 0 + 1 + 2 + +=== Clones + +==== Task: Clone Deeply + +Use method {Parent#deep_clone}[../../../../REXML/Parent.html#method-i-deep_clone] +to clone deeply; that is, to clone every nested node that is a Parent object: + + xml_string = <<-EOT + <?xml version="1.0" encoding="UTF-8"?> + <bookstore> + <book category="cooking"> + <title lang="en">Everyday Italian + Giada De Laurentiis + 2005 + 30.00 + + + Harry Potter + J K. Rowling + 2005 + 29.99 + + + Learning XML + Erik T. Ray + 2003 + 39.95 + + + EOT + d = REXML::Document.new(xml_string) + root = d.root + shallow = root.clone + deep = root.deep_clone + shallow.to_s.size # => 12 + deep.to_s.size # => 590 diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/child_toc.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/child_toc.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/child_toc.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/child_toc.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,12 @@ +Tasks on this page: + +- {Relationships}[#label-Relationships] + - {Task: Set the Parent}[#label-Task-3A+Set+the+Parent] + - {Task: Insert Previous Sibling}[#label-Task-3A+Insert+Previous+Sibling] + - {Task: Insert Next Sibling}[#label-Task-3A+Insert+Next+Sibling] +- {Removal or Replacement}[#label-Removal+or+Replacement] + - {Task: Remove Child from Parent}[#label-Task-3A+Remove+Child+from+Parent] + - {Task: Replace Child}[#label-Task-3A+Replace+Child] +- {Document}[#label-Document] + - {Task: Get the Document}[#label-Task-3A+Get+the+Document] + diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/document_toc.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/document_toc.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/document_toc.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/document_toc.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,30 @@ +Tasks on this page: + +- {New Document}[#label-New+Document] + - {Task: Create an Empty Document}[#label-Task-3A+Create+an+Empty+Document] + - {Task: Parse a String into a New Document}[#label-Task-3A+Parse+a+String+into+a+New+Document] + - {Task: Parse an IO Stream into a New Document}[#label-Task-3A+Parse+an+IO+Stream+into+a+New+Document] + - {Task: Create a Document from an Existing Document}[#label-Task-3A+Create+a+Document+from+an+Existing+Document] + - {Task: Clone a Document}[#label-Task-3A+Clone+a+Document] +- {Document Type}[#label-Document+Type] + - {Task: Get the Document Type}[#label-Task-3A+Get+the+Document+Type] + - {Task: Set the Document Type}[#label-Task-3A+Set+the+Document+Type] +- {XML Declaration}[#label-XML+Declaration] + - {Task: Get the XML Declaration}[#label-Task-3A+Get+the+XML+Declaration] + - {Task: Set the XML Declaration}[#label-Task-3A+Set+the+XML+Declaration] +- {Children}[#label-Children] + - {Task: Add an Element Child}[#label-Task-3A+Add+an+Element+Child] + - {Task: Add a Non-Element Child}[#label-Task-3A+Add+a+Non-Element+Child] +- {Writing}[#label-Writing] + - {Task: Write to $stdout}[#label-Task-3A+Write+to+-24stdout] + - {Task: Write to IO Stream}[#label-Task-3A+Write+to+IO+Stream] + - {Task: Write with No Indentation}[#label-Task-3A+Write+with+No+Indentation] + - {Task: Write with Specified Indentation}[#label-Task-3A+Write+with+Specified+Indentation] +- {Querying}[#label-Querying] + - {Task: Get the Document}[#label-Task-3A+Get+the+Document] + - {Task: Get the Encoding}[#label-Task-3A+Get+the+Encoding] + - {Task: Get the Node Type}[#label-Task-3A+Get+the+Node+Type] + - {Task: Get the Root Element}[#label-Task-3A+Get+the+Root+Element] + - {Task: Determine Whether Stand-Alone}[#label-Task-3A+Determine+Whether+Stand-Alone] + - {Task: Get the Version}[#label-Task-3A+Get+the+Version] + diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/element_toc.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/element_toc.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/element_toc.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/element_toc.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,55 @@ +Tasks on this page: + +- {New Element}[#label-New+Element] + - {Task: Create a Default Element}[#label-Task-3A+Create+a+Default+Element] + - {Task: Create a Named Element}[#label-Task-3A+Create+a+Named+Element] + - {Task: Create an Element with Name and Parent}[#label-Task-3A+Create+an+Element+with+Name+and+Parent] + - {Task: Create an Element with Name, Parent, and Context}[#label-Task-3A+Create+an+Element+with+Name-2C+Parent-2C+and+Context] + - {Task: Create a Shallow Clone}[#label-Task-3A+Create+a+Shallow+Clone] +- {Attributes}[#label-Attributes] + - {Task: Create and Add an Attribute}[#label-Task-3A+Create+and+Add+an+Attribute] + - {Task: Add an Existing Attribute}[#label-Task-3A+Add+an+Existing+Attribute] + - {Task: Add Multiple Attributes from a Hash}[#label-Task-3A+Add+Multiple+Attributes+from+a+Hash] + - {Task: Add Multiple Attributes from an Array}[#label-Task-3A+Add+Multiple+Attributes+from+an+Array] + - {Task: Retrieve the Value for an Attribute Name}[#label-Task-3A+Retrieve+the+Value+for+an+Attribute+Name] + - {Task: Retrieve the Attribute Value for a Name and Namespace}[#label-Task-3A+Retrieve+the+Attribute+Value+for+a+Name+and+Namespace] + - {Task: Delete an Attribute}[#label-Task-3A+Delete+an+Attribute] + - {Task: Determine Whether the Element Has Attributes}[#label-Task-3A+Determine+Whether+the+Element+Has+Attributes] +- {Children}[#label-Children] + - {Task: Create and Add an Element}[#label-Task-3A+Create+and+Add+an+Element] + - {Task: Add an Existing Element}[#label-Task-3A+Add+an+Existing+Element] + - {Task: Create and Add an Element with Attributes}[#label-Task-3A+Create+and+Add+an+Element+with+Attributes] + - {Task: Add an Existing Element with Added Attributes}[#label-Task-3A+Add+an+Existing+Element+with+Added+Attributes] + - {Task: Delete a Specified Element}[#label-Task-3A+Delete+a+Specified+Element] + - {Task: Delete an Element by Index}[#label-Task-3A+Delete+an+Element+by+Index] + - {Task: Delete an Element by XPath}[#label-Task-3A+Delete+an+Element+by+XPath] + - {Task: Determine Whether Element Children}[#label-Task-3A+Determine+Whether+Element+Children] + - {Task: Get Element Descendants by XPath}[#label-Task-3A+Get+Element+Descendants+by+XPath] + - {Task: Get Next Element Sibling}[#label-Task-3A+Get+Next+Element+Sibling] + - {Task: Get Previous Element Sibling}[#label-Task-3A+Get+Previous+Element+Sibling] + - {Task: Add a Text Node}[#label-Task-3A+Add+a+Text+Node] + - {Task: Replace the First Text Node}[#label-Task-3A+Replace+the+First+Text+Node] + - {Task: Remove the First Text Node}[#label-Task-3A+Remove+the+First+Text+Node] + - {Task: Retrieve the First Text Node}[#label-Task-3A+Retrieve+the+First+Text+Node] + - {Task: Retrieve a Specific Text Node}[#label-Task-3A+Retrieve+a+Specific+Text+Node] + - {Task: Determine Whether the Element has Text Nodes}[#label-Task-3A+Determine+Whether+the+Element+has+Text+Nodes] + - {Task: Get the Child at a Given Index}[#label-Task-3A+Get+the+Child+at+a+Given+Index] + - {Task: Get All CDATA Children}[#label-Task-3A+Get+All+CDATA+Children] + - {Task: Get All Comment Children}[#label-Task-3A+Get+All+Comment+Children] + - {Task: Get All Processing Instruction Children}[#label-Task-3A+Get+All+Processing+Instruction+Children] + - {Task: Get All Text Children}[#label-Task-3A+Get+All+Text+Children] +- {Namespaces}[#label-Namespaces] + - {Task: Add a Namespace}[#label-Task-3A+Add+a+Namespace] + - {Task: Delete the Default Namespace}[#label-Task-3A+Delete+the+Default+Namespace] + - {Task: Delete a Specific Namespace}[#label-Task-3A+Delete+a+Specific+Namespace] + - {Task: Get a Namespace URI}[#label-Task-3A+Get+a+Namespace+URI] + - {Task: Retrieve Namespaces}[#label-Task-3A+Retrieve+Namespaces] + - {Task: Retrieve Namespace Prefixes}[#label-Task-3A+Retrieve+Namespace+Prefixes] +- {Iteration}[#label-Iteration] + - {Task: Iterate Over Elements}[#label-Task-3A+Iterate+Over+Elements] + - {Task: Iterate Over Elements Having a Specified Attribute}[#label-Task-3A+Iterate+Over+Elements+Having+a+Specified+Attribute] + - {Task: Iterate Over Elements Having a Specified Attribute and Value}[#label-Task-3A+Iterate+Over+Elements+Having+a+Specified+Attribute+and+Value] + - {Task: Iterate Over Elements Having Specified Text}[#label-Task-3A+Iterate+Over+Elements+Having+Specified+Text] +- {Context}[#label-Context] +- {Other Getters}[#label-Other+Getters] + diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/master_toc.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/master_toc.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/master_toc.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/master_toc.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,135 @@ +== Tasks + +=== {Child}[../../tasks/rdoc/child_rdoc.html] +- {Relationships}[../../tasks/rdoc/child_rdoc.html#label-Relationships] + - {Task: Set the Parent}[../../tasks/rdoc/child_rdoc.html#label-Task-3A+Set+the+Parent] + - {Task: Insert Previous Sibling}[../../tasks/rdoc/child_rdoc.html#label-Task-3A+Insert+Previous+Sibling] + - {Task: Insert Next Sibling}[../../tasks/rdoc/child_rdoc.html#label-Task-3A+Insert+Next+Sibling] +- {Removal or Replacement}[../../tasks/rdoc/child_rdoc.html#label-Removal+or+Replacement] + - {Task: Remove Child from Parent}[../../tasks/rdoc/child_rdoc.html#label-Task-3A+Remove+Child+from+Parent] + - {Task: Replace Child}[../../tasks/rdoc/child_rdoc.html#label-Task-3A+Replace+Child] +- {Document}[../../tasks/rdoc/child_rdoc.html#label-Document] + - {Task: Get the Document}[../../tasks/rdoc/child_rdoc.html#label-Task-3A+Get+the+Document] + +=== {Document}[../../tasks/rdoc/document_rdoc.html] +- {New Document}[../../tasks/rdoc/document_rdoc.html#label-New+Document] + - {Task: Create an Empty Document}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Create+an+Empty+Document] + - {Task: Parse a String into a New Document}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Parse+a+String+into+a+New+Document] + - {Task: Parse an IO Stream into a New Document}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Parse+an+IO+Stream+into+a+New+Document] + - {Task: Create a Document from an Existing Document}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Create+a+Document+from+an+Existing+Document] + - {Task: Clone a Document}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Clone+a+Document] +- {Document Type}[../../tasks/rdoc/document_rdoc.html#label-Document+Type] + - {Task: Get the Document Type}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+Document+Type] + - {Task: Set the Document Type}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Set+the+Document+Type] +- {XML Declaration}[../../tasks/rdoc/document_rdoc.html#label-XML+Declaration] + - {Task: Get the XML Declaration}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+XML+Declaration] + - {Task: Set the XML Declaration}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Set+the+XML+Declaration] +- {Children}[../../tasks/rdoc/document_rdoc.html#label-Children] + - {Task: Add an Element Child}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Add+an+Element+Child] + - {Task: Add a Non-Element Child}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Add+a+Non-Element+Child] +- {Writing}[../../tasks/rdoc/document_rdoc.html#label-Writing] + - {Task: Write to $stdout}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Write+to+-24stdout] + - {Task: Write to IO Stream}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Write+to+IO+Stream] + - {Task: Write with No Indentation}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Write+with+No+Indentation] + - {Task: Write with Specified Indentation}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Write+with+Specified+Indentation] +- {Querying}[../../tasks/rdoc/document_rdoc.html#label-Querying] + - {Task: Get the Document}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+Document] + - {Task: Get the Encoding}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+Encoding] + - {Task: Get the Node Type}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+Node+Type] + - {Task: Get the Root Element}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+Root+Element] + - {Task: Determine Whether Stand-Alone}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Determine+Whether+Stand-Alone] + - {Task: Get the Version}[../../tasks/rdoc/document_rdoc.html#label-Task-3A+Get+the+Version] + +=== {Element}[../../tasks/rdoc/element_rdoc.html] +- {New Element}[../../tasks/rdoc/element_rdoc.html#label-New+Element] + - {Task: Create a Default Element}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+a+Default+Element] + - {Task: Create a Named Element}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+a+Named+Element] + - {Task: Create an Element with Name and Parent}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+an+Element+with+Name+and+Parent] + - {Task: Create an Element with Name, Parent, and Context}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+an+Element+with+Name-2C+Parent-2C+and+Context] + - {Task: Create a Shallow Clone}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+a+Shallow+Clone] +- {Attributes}[../../tasks/rdoc/element_rdoc.html#label-Attributes] + - {Task: Create and Add an Attribute}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+and+Add+an+Attribute] + - {Task: Add an Existing Attribute}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+an+Existing+Attribute] + - {Task: Add Multiple Attributes from a Hash}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+Multiple+Attributes+from+a+Hash] + - {Task: Add Multiple Attributes from an Array}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+Multiple+Attributes+from+an+Array] + - {Task: Retrieve the Value for an Attribute Name}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Retrieve+the+Value+for+an+Attribute+Name] + - {Task: Retrieve the Attribute Value for a Name and Namespace}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Retrieve+the+Attribute+Value+for+a+Name+and+Namespace] + - {Task: Delete an Attribute}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Delete+an+Attribute] + - {Task: Determine Whether the Element Has Attributes}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Determine+Whether+the+Element+Has+Attributes] +- {Children}[../../tasks/rdoc/element_rdoc.html#label-Children] + - {Task: Create and Add an Element}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+and+Add+an+Element] + - {Task: Add an Existing Element}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+an+Existing+Element] + - {Task: Create and Add an Element with Attributes}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Create+and+Add+an+Element+with+Attributes] + - {Task: Add an Existing Element with Added Attributes}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+an+Existing+Element+with+Added+Attributes] + - {Task: Delete a Specified Element}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Delete+a+Specified+Element] + - {Task: Delete an Element by Index}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Delete+an+Element+by+Index] + - {Task: Delete an Element by XPath}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Delete+an+Element+by+XPath] + - {Task: Determine Whether Element Children}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Determine+Whether+Element+Children] + - {Task: Get Element Descendants by XPath}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+Element+Descendants+by+XPath] + - {Task: Get Next Element Sibling}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+Next+Element+Sibling] + - {Task: Get Previous Element Sibling}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+Previous+Element+Sibling] + - {Task: Add a Text Node}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+a+Text+Node] + - {Task: Replace the First Text Node}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Replace+the+First+Text+Node] + - {Task: Remove the First Text Node}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Remove+the+First+Text+Node] + - {Task: Retrieve the First Text Node}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Retrieve+the+First+Text+Node] + - {Task: Retrieve a Specific Text Node}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Retrieve+a+Specific+Text+Node] + - {Task: Determine Whether the Element has Text Nodes}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Determine+Whether+the+Element+has+Text+Nodes] + - {Task: Get the Child at a Given Index}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+the+Child+at+a+Given+Index] + - {Task: Get All CDATA Children}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+All+CDATA+Children] + - {Task: Get All Comment Children}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+All+Comment+Children] + - {Task: Get All Processing Instruction Children}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+All+Processing+Instruction+Children] + - {Task: Get All Text Children}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+All+Text+Children] +- {Namespaces}[../../tasks/rdoc/element_rdoc.html#label-Namespaces] + - {Task: Add a Namespace}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Add+a+Namespace] + - {Task: Delete the Default Namespace}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Delete+the+Default+Namespace] + - {Task: Delete a Specific Namespace}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Delete+a+Specific+Namespace] + - {Task: Get a Namespace URI}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Get+a+Namespace+URI] + - {Task: Retrieve Namespaces}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Retrieve+Namespaces] + - {Task: Retrieve Namespace Prefixes}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Retrieve+Namespace+Prefixes] +- {Iteration}[../../tasks/rdoc/element_rdoc.html#label-Iteration] + - {Task: Iterate Over Elements}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Iterate+Over+Elements] + - {Task: Iterate Over Elements Having a Specified Attribute}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Iterate+Over+Elements+Having+a+Specified+Attribute] + - {Task: Iterate Over Elements Having a Specified Attribute and Value}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Iterate+Over+Elements+Having+a+Specified+Attribute+and+Value] + - {Task: Iterate Over Elements Having Specified Text}[../../tasks/rdoc/element_rdoc.html#label-Task-3A+Iterate+Over+Elements+Having+Specified+Text] +- {Context}[../../tasks/rdoc/element_rdoc.html#label-Context] +- {Other Getters}[../../tasks/rdoc/element_rdoc.html#label-Other+Getters] + +=== {Node}[../../tasks/rdoc/node_rdoc.html] +- {Siblings}[../../tasks/rdoc/node_rdoc.html#label-Siblings] + - {Task: Find Previous Sibling}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Find+Previous+Sibling] + - {Task: Find Next Sibling}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Find+Next+Sibling] +- {Position}[../../tasks/rdoc/node_rdoc.html#label-Position] + - {Task: Find Own Index Among Siblings}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Find+Own+Index+Among+Siblings] +- {Recursive Traversal}[../../tasks/rdoc/node_rdoc.html#label-Recursive+Traversal] + - {Task: Traverse Each Recursively}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Traverse+Each+Recursively] +- {Recursive Search}[../../tasks/rdoc/node_rdoc.html#label-Recursive+Search] + - {Task: Traverse Each Recursively}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Traverse+Each+Recursively] +- {Representation}[../../tasks/rdoc/node_rdoc.html#label-Representation] + - {Task: Represent a String}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Represent+a+String] +- {Parent?}[../../tasks/rdoc/node_rdoc.html#label-Parent-3F] + - {Task: Determine Whether the Node is a Parent}[../../tasks/rdoc/node_rdoc.html#label-Task-3A+Determine+Whether+the+Node+is+a+Parent] + +=== {Parent}[../../tasks/rdoc/parent_rdoc.html] +- {Queries}[../../tasks/rdoc/parent_rdoc.html#label-Queries] + - {Task: Get the Count of Children}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Get+the+Count+of+Children] + - {Task: Get the Child at a Given Index}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Get+the+Child+at+a+Given+Index] + - {Task: Get the Index of a Given Child}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Get+the+Index+of+a+Given+Child] + - {Task: Get the Children}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Get+the+Children] + - {Task: Determine Whether the Node is a Parent}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Determine+Whether+the+Node+is+a+Parent] +- {Additions}[../../tasks/rdoc/parent_rdoc.html#label-Additions] + - {Task: Add a Child at the Beginning}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Add+a+Child+at+the+Beginning] + - {Task: Add a Child at the End}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Add+a+Child+at+the+End] + - {Task: Replace a Child with Another Child}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Replace+a+Child+with+Another+Child] + - {Task: Replace Multiple Children with Another Child}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Replace+Multiple+Children+with+Another+Child] + - {Task: Insert Child Before a Given Child}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Insert+Child+Before+a+Given+Child] + - {Task: Insert Child After a Given Child}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Insert+Child+After+a+Given+Child] +- {Deletions}[../../tasks/rdoc/parent_rdoc.html#label-Deletions] + - {Task: Remove a Given Child}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Remove+a+Given+Child] + - {Task: Remove the Child at a Specified Offset}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Remove+the+Child+at+a+Specified+Offset] + - {Task: Remove Children That Meet Specified Criteria}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Remove+Children+That+Meet+Specified+Criteria] +- {Iterations}[../../tasks/rdoc/parent_rdoc.html#label-Iterations] + - {Task: Iterate Over Children}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Iterate+Over+Children] + - {Task: Iterate Over Child Indexes}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Iterate+Over+Child+Indexes] +- {Clones}[../../tasks/rdoc/parent_rdoc.html#label-Clones] + - {Task: Clone Deeply}[../../tasks/rdoc/parent_rdoc.html#label-Task-3A+Clone+Deeply] + diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/node_toc.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/node_toc.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/node_toc.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/node_toc.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,16 @@ +Tasks on this page: + +- {Siblings}[#label-Siblings] + - {Task: Find Previous Sibling}[#label-Task-3A+Find+Previous+Sibling] + - {Task: Find Next Sibling}[#label-Task-3A+Find+Next+Sibling] +- {Position}[#label-Position] + - {Task: Find Own Index Among Siblings}[#label-Task-3A+Find+Own+Index+Among+Siblings] +- {Recursive Traversal}[#label-Recursive+Traversal] + - {Task: Traverse Each Recursively}[#label-Task-3A+Traverse+Each+Recursively] +- {Recursive Search}[#label-Recursive+Search] + - {Task: Traverse Each Recursively}[#label-Task-3A+Traverse+Each+Recursively] +- {Representation}[#label-Representation] + - {Task: Represent a String}[#label-Task-3A+Represent+a+String] +- {Parent?}[#label-Parent-3F] + - {Task: Determine Whether the Node is a Parent}[#label-Task-3A+Determine+Whether+the+Node+is+a+Parent] + diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/parent_toc.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/parent_toc.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/parent_toc.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tasks/tocs/parent_toc.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,25 @@ +Tasks on this page: + +- {Queries}[#label-Queries] + - {Task: Get the Count of Children}[#label-Task-3A+Get+the+Count+of+Children] + - {Task: Get the Child at a Given Index}[#label-Task-3A+Get+the+Child+at+a+Given+Index] + - {Task: Get the Index of a Given Child}[#label-Task-3A+Get+the+Index+of+a+Given+Child] + - {Task: Get the Children}[#label-Task-3A+Get+the+Children] + - {Task: Determine Whether the Node is a Parent}[#label-Task-3A+Determine+Whether+the+Node+is+a+Parent] +- {Additions}[#label-Additions] + - {Task: Add a Child at the Beginning}[#label-Task-3A+Add+a+Child+at+the+Beginning] + - {Task: Add a Child at the End}[#label-Task-3A+Add+a+Child+at+the+End] + - {Task: Replace a Child with Another Child}[#label-Task-3A+Replace+a+Child+with+Another+Child] + - {Task: Replace Multiple Children with Another Child}[#label-Task-3A+Replace+Multiple+Children+with+Another+Child] + - {Task: Insert Child Before a Given Child}[#label-Task-3A+Insert+Child+Before+a+Given+Child] + - {Task: Insert Child After a Given Child}[#label-Task-3A+Insert+Child+After+a+Given+Child] +- {Deletions}[#label-Deletions] + - {Task: Remove a Given Child}[#label-Task-3A+Remove+a+Given+Child] + - {Task: Remove the Child at a Specified Offset}[#label-Task-3A+Remove+the+Child+at+a+Specified+Offset] + - {Task: Remove Children That Meet Specified Criteria}[#label-Task-3A+Remove+Children+That+Meet+Specified+Criteria] +- {Iterations}[#label-Iterations] + - {Task: Iterate Over Children}[#label-Task-3A+Iterate+Over+Children] + - {Task: Iterate Over Child Indexes}[#label-Task-3A+Iterate+Over+Child+Indexes] +- {Clones}[#label-Clones] + - {Task: Clone Deeply}[#label-Task-3A+Clone+Deeply] + diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tutorial.rdoc ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tutorial.rdoc --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/doc/rexml/tutorial.rdoc 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/doc/rexml/tutorial.rdoc 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,1358 @@ += \REXML Tutorial + +== Why \REXML? + +- Ruby's \REXML library is part of the Ruby distribution, + so using it requires no gem installations. +- \REXML is fully maintained. +- \REXML is mature, having been in use for long years. + +== To Include, or Not to Include? + +REXML is a module. +To use it, you must require it: + + require 'rexml' # => true + +If you do not also include it, you must fully qualify references to REXML: + + REXML::Document # => REXML::Document + +If you also include the module, you may optionally omit REXML::: + + include REXML + Document # => REXML::Document + REXML::Document # => REXML::Document + +== Preliminaries + +All examples here assume that the following code has been executed: + + require 'rexml' + include REXML + +The source XML for many examples here is from file +{books.xml}[https://www.w3schools.com/xml/books.xml] at w3schools.com. +You may find it convenient to open that page in a new tab +(Ctrl-click in some browsers). + +Note that your browser may display the XML with modified whitespace +and without the XML declaration, which in this case is: + + + +For convenience, we capture the XML into a string variable: + + require 'open-uri' + source_string = URI.open('https://www.w3schools.com/xml/books.xml').read + +And into a file: + + File.write('source_file.xml', source_string) + +Throughout these examples, variable +doc+ will hold only the document +derived from these sources: + + doc = Document.new(source_string) + +== Parsing \XML \Source + +=== Parsing a Document + +Use method REXML::Document::new to parse XML source. + +The source may be a string: + + doc = Document.new(source_string) + +Or an \IO stream: + + doc = File.open('source_file.xml', 'r') do |io| + Document.new(io) + end + +Method URI.open returns a StringIO object, +so the source can be from a web page: + + require 'open-uri' + io = URI.open("https://www.w3schools.com/xml/books.xml") + io.class # => StringIO + doc = Document.new(io) + +For any of these sources, the returned object is an REXML::Document: + + doc # => ... + doc.class # => REXML::Document + +Note: 'UNDEFINED' is the "name" displayed for a document, +even though doc.name returns an empty string "". + +A parsed document may produce \REXML objects of many classes, +but the two that are likely to be of greatest interest are +REXML::Document and REXML::Element. +These two classes are covered in great detail in this tutorial. + +=== Context (Parsing Options) + +The context for parsing a document is a hash that influences +the way the XML is read and stored. + +The context entries are: + +- +:respect_whitespace+: controls treatment of whitespace. +- +:compress_whitespace+: determines whether whitespace is compressed. +- +:ignore_whitespace_nodes+: determines whether whitespace-only nodes are to be ignored. +- +:raw+: controls treatment of special characters and entities. + +See {Element Context}[../context_rdoc.html]. + +== Exploring the Document + +An REXML::Document object represents an XML document. + +The object inherits from its ancestor classes: + +- REXML::Child (includes module REXML::Node) + - REXML::Parent (includes module {Enumerable}[rdoc-ref:Enumerable]). + - REXML::Element (includes module REXML::Namespace). + - REXML::Document + +This section covers only those properties and methods that are unique to a document +(that is, not inherited or included). + +=== Document Properties + +A document has several properties (other than its children); + +- Document type. +- Node type. +- Name. +- Document. +- XPath + +[Document Type] + + A document may have a document type: + + my_xml = '' + my_doc = Document.new(my_xml) + doc_type = my_doc.doctype + doc_type.class # => REXML::DocType + doc_type.to_s # => "" + +[Node Type] + + A document also has a node type (always +:document+): + + doc.node_type # => :document + +[Name] + + A document has a name (always an empty string): + + doc.name # => "" + +[Document] + + \Method REXML::Document#document returns +self+: + + doc.document == doc # => true + + An object of a different class (\REXML::Element or \REXML::Child) + may have a document, which is the document to which the object belongs; + if so, that document will be an \REXML::Document object. + + doc.root.document.class # => REXML::Document + +[XPath] + + \method REXML::Element#xpath returns the string xpath to the element, + relative to its most distant ancestor: + + doc.root.class # => REXML::Element + doc.root.xpath # => "/bookstore" + doc.root.texts.first # => "\n\n" + doc.root.texts.first.xpath # => "/bookstore/text()" + + If there is no ancestor, returns the expanded name of the element: + + Element.new('foo').xpath # => "foo" + +=== Document Children + +A document may have children of these types: + +- XML declaration. +- Root element. +- Text. +- Processing instructions. +- Comments. +- CDATA. + +[XML Declaration] + + A document may an XML declaration, which is stored as an REXML::XMLDecl object: + + doc.xml_decl # => + doc.xml_decl.class # => REXML::XMLDecl + + Document.new('').xml_decl # => + + my_xml = '"' + my_doc = Document.new(my_xml) + xml_decl = my_doc.xml_decl + xml_decl.to_s # => "" + + The version, encoding, and stand-alone values may be retrieved separately: + + my_doc.version # => "1.0" + my_doc.encoding # => "UTF-8" + my_doc.stand_alone? # => "yes" + +[Root Element] + + A document may have a single element child, called the _root_ _element_, + which is stored as an REXML::Element object; + it may be retrieved with method +root+: + + doc.root # => ... + doc.root.class # => REXML::Element + + Document.new('').root # => nil + +[Text] + + A document may have text passages, each of which is stored + as an REXML::Text object: + + doc.texts.each {|t| p [t.class, t] } + + Output: + + [REXML::Text, "\n"] + +[Processing Instructions] + + A document may have processing instructions, which are stored + as REXML::Instruction objects: + + + + Output: + + [REXML::Instruction, ] + [REXML::Instruction, ] + +[Comments] + + A document may have comments, which are stored + as REXML::Comment objects: + + my_xml = <<-EOT + + + EOT + my_doc = Document.new(my_xml) + my_doc.comments.each {|c| p [c.class, c] } + + Output: + + [REXML::Comment, # ... , @string="foo">] + [REXML::Comment, # ... , @string="bar">] + +[CDATA] + + A document may have CDATA entries, which are stored + as REXML::CData objects: + + my_xml = <<-EOT + + + EOT + my_doc = Document.new(my_xml) + my_doc.cdatas.each {|cd| p [cd.class, cd] } + + Output: + + [REXML::CData, "foo"] + [REXML::CData, "bar"] + +The payload of a document is a tree of nodes, descending from the root element: + + doc.root.children.each do |child| + p [child, child.class] + end + +Output: + + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + +== Exploring an Element + +An REXML::Element object represents an XML element. + +The object inherits from its ancestor classes: + +- REXML::Child (includes module REXML::Node) + - REXML::Parent (includes module {Enumerable}[rdoc-ref:Enumerable]). + - REXML::Element (includes module REXML::Namespace). + +This section covers methods: + +- Defined in REXML::Element itself. +- Inherited from REXML::Parent and REXML::Child. +- Included from REXML::Node. + +=== Inside the Element + +[Brief String Representation] + + Use method REXML::Element#inspect to retrieve a brief string representation. + + doc.root.inspect # => " ... " + + The ellipsis (...) indicates that the element has children. + When there are no children, the ellipsis is omitted: + + Element.new('foo').inspect # => "" + + If the element has attributes, those are also included: + + doc.root.elements.first.inspect # => " ... " + +[Extended String Representation] + + Use inherited method REXML::Child.bytes to retrieve an extended + string representation. + + doc.root.bytes # => "\n\n\n Everyday Italian\n Giada De Laurentiis\n 2005\n 30.00\n\n\n\n Harry Potter\n J K. Rowling\n 2005\n 29.99\n\n\n\n XQuery Kick Start\n James McGovern\n Per Bothner\n Kurt Cagle\n James Linn\n Vaidyanathan Nagarajan\n 2003\n 49.99\n\n\n\n Learning XML\n Erik T. Ray\n 2003\n 39.95\n\n\n" + +[Node Type] + + Use method REXML::Element#node_type to retrieve the node type (always +:element+): + + doc.root.node_type # => :element + +[Raw Mode] + + Use method REXML::Element#raw to retrieve whether (+true+ or +nil+) + raw mode is set. + + doc.root.raw # => nil + +[Context] + + Use method REXML::Element#context to retrieve the context hash + (see {Element Context}[../context_rdoc.html]): + + doc.root.context # => {} + +=== Relationships + +An element may have: + +- Ancestors. +- Siblings. +- Children. + +==== Ancestors + +[Containing Document] + + Use method REXML::Element#document to retrieve the containing document, if any: + + ele = doc.root.elements.first # => ... + ele.document # => ... + ele = Element.new('foo') # => + ele.document # => nil + +[Root Element] + + Use method REXML::Element#root to retrieve the root element: + + ele = doc.root.elements.first # => ... + ele.root # => ... + ele = Element.new('foo') # => + ele.root # => + +[Root Node] + + Use method REXML::Element#root_node to retrieve the most distant ancestor, + which is the containing document, if any, otherwise the root element: + + ele = doc.root.elements.first # => ... + ele.root_node # => ... + ele = Element.new('foo') # => + ele.root_node # => + +[Parent] + + Use inherited method REXML::Child#parent to retrieve the parent + + ele = doc.root # => ... + ele.parent # => ... + ele = doc.root.elements.first # => ... + ele.parent # => ... + + Use included method REXML::Node#index_in_parent to retrieve the index + of the element among all of its parents children (not just the element children). + Note that while the index for doc.root.elements[n] is 1-based, + the returned index is 0-based. + + doc.root.children # => + # ["\n\n", + # ... , + # "\n\n", + # ... , + # "\n\n", + # ... , + # "\n\n", + # ... , + # "\n\n"] + ele = doc.root.elements[1] # => ... + ele.index_in_parent # => 2 + ele = doc.root.elements[2] # => ... + ele.index_in_parent# => 4 + +==== Siblings + +[Next Element] + + Use method REXML::Element#next_element to retrieve the first following + sibling that is itself an element (+nil+ if there is none): + + ele = doc.root.elements[1] + while ele do + p [ele.class, ele] + ele = ele.next_element + end + p ele + + Output: + + [REXML::Element, ... ] + [REXML::Element, ... ] + [REXML::Element, ... ] + [REXML::Element, ... ] + +[Previous Element] + + Use method REXML::Element#previous_element to retrieve the first preceding + sibling that is itself an element (+nil+ if there is none): + + ele = doc.root.elements[4] + while ele do + p [ele.class, ele] + ele = ele.previous_element + end + p ele + + Output: + + [REXML::Element, ... ] + [REXML::Element, ... ] + [REXML::Element, ... ] + [REXML::Element, ... ] + +[Next Node] + + Use included method REXML::Node.next_sibling_node + (or its alias next_sibling) to retrieve the first following node + regardless of its class: + + node = doc.root.children[0] + while node do + p [node.class, node] + node = node.next_sibling + end + p node + + Output: + + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + +[Previous Node] + + Use included method REXML::Node.previous_sibling_node + (or its alias previous_sibling) to retrieve the first preceding node + regardless of its class: + + node = doc.root.children[-1] + while node do + p [node.class, node] + node = node.previous_sibling + end + p node + + Output: + + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + +==== Children + +[Child Count] + + Use inherited method REXML::Parent.size to retrieve the count + of nodes (of all types) in the element: + + doc.root.size # => 9 + +[Child Nodes] + + Use inherited method REXML::Parent.children to retrieve an array + of the child nodes (of all types): + + doc.root.children # => + # ["\n\n", + # ... , + # "\n\n", + # ... , + # "\n\n", + # ... , + # "\n\n", + # ... , + # "\n\n"] + +[Child at Index] + + Use method REXML::Element#[] to retrieve the child at a given numerical index, + or +nil+ if there is no such child: + + doc.root[0] # => "\n\n" + doc.root[1] # => ... + doc.root[7] # => ... + doc.root[8] # => "\n\n" + + doc.root[-1] # => "\n\n" + doc.root[-2] # => ... + + doc.root[50] # => nil + +[Index of Child] + + Use method REXML::Parent#index to retrieve the zero-based child index + of the given object, or #size - 1 if there is no such child: + + ele = doc.root # => ... + ele.index(ele[0]) # => 0 + ele.index(ele[1]) # => 1 + ele.index(ele[7]) # => 7 + ele.index(ele[8]) # => 8 + + ele.index(ele[-1]) # => 8 + ele.index(ele[-2]) # => 7 + + ele.index(ele[50]) # => 8 + +[Element Children] + + Use method REXML::Element#has_elements? to retrieve whether the element + has element children: + + doc.root.has_elements? # => true + REXML::Element.new('foo').has_elements? # => false + + Use method REXML::Element#elements to retrieve the REXML::Elements object + containing the element children: + + eles = doc.root.elements + eles # => # ... > + eles.size # => 4 + eles.each {|e| p [e.class], e } + + Output: + + [ ... , + ... , + ... , + ... + ] + +Note that while in this example, all the element children of the root element are +elements of the same name, 'book', that is not true of all documents; +a root element (or any other element) may have any mixture of child elements. + +[CDATA Children] + + Use method REXML::Element#cdatas to retrieve a frozen array of CDATA children: + + my_xml = <<-EOT + + + + + EOT + my_doc = REXML::Document.new(my_xml) + cdatas my_doc.root.cdatas + cdatas.frozen? # => true + cdatas.map {|cd| cd.class } # => [REXML::CData, REXML::CData] + +[Comment Children] + + Use method REXML::Element#comments to retrieve a frozen array of comment children: + + my_xml = <<-EOT + + + + + EOT + my_doc = REXML::Document.new(my_xml) + comments = my_doc.root.comments + comments.frozen? # => true + comments.map {|c| c.class } # => [REXML::Comment, REXML::Comment] + comments.map {|c| c.to_s } # => ["foo", "bar"] + +[Processing Instruction Children] + + Use method REXML::Element#instructions to retrieve a frozen array + of processing instruction children: + + my_xml = <<-EOT + + + + + EOT + my_doc = REXML::Document.new(my_xml) + instrs = my_doc.root.instructions + instrs.frozen? # => true + instrs.map {|i| i.class } # => [REXML::Instruction, REXML::Instruction] + instrs.map {|i| i.to_s } # => ["", ""] + +[Text Children] + + Use method REXML::Element#has_text? to retrieve whether the element + has text children: + + doc.root.has_text? # => true + REXML::Element.new('foo').has_text? # => false + + Use method REXML::Element#texts to retrieve a frozen array of text children: + + my_xml = 'textmore' + my_doc = REXML::Document.new(my_xml) + texts = my_doc.root.texts + texts.frozen? # => true + texts.map {|t| t.class } # => [REXML::Text, REXML::Text] + texts.map {|t| t.to_s } # => ["text", "more"] + +[Parenthood] + + Use inherited method REXML::Parent.parent? to retrieve whether the element is a parent; + always returns +true+; only REXML::Child#parent returns +false+. + + doc.root.parent? # => true + +=== Element Attributes + +Use method REXML::Element#has_attributes? to return whether the element +has attributes: + + ele = doc.root # => ... + ele.has_attributes? # => false + ele = ele.elements.first # => ... + ele.has_attributes? # => true + +Use method REXML::Element#attributes to return the hash +containing the attributes for the element. +Each hash key is a string attribute name; +each hash value is an REXML::Attribute object. + + ele = doc.root # => ... + attrs = ele.attributes # => {} + + ele = ele.elements.first # => ... + attrs = ele.attributes # => {"category"=>category='cooking'} + attrs.size # => 1 + attr_name = attrs.keys.first # => "category" + attr_name.class # => String + attr_value = attrs.values.first # => category='cooking' + attr_value.class # => REXML::Attribute + +Use method REXML::Element#[] to retrieve the string value for a given attribute, +which may be given as either a string or a symbol: + + ele = doc.root.elements.first # => ... + attr_value = ele['category'] # => "cooking" + attr_value.class # => String + ele['nosuch'] # => nil + +Use method REXML::Element#attribute to retrieve the value of a named attribute: + + my_xml = "" + my_doc = REXML::Document.new(my_xml) + my_doc.root.attribute("x") # => x='x' + my_doc.root.attribute("x", "a") # => a:x='a:x' + +== Whitespace + +Use method REXML::Element#ignore_whitespace_nodes to determine whether +whitespace nodes were ignored when the XML was parsed; +returns +true+ if so, +nil+ otherwise. + +Use method REXML::Element#whitespace to determine whether whitespace +is respected for the element; returns +true+ if so, +false+ otherwise. + +== Namespaces + +Use method REXML::Element#namespace to retrieve the string namespace URI +for the element, which may derive from one of its ancestors: + + xml_string = <<-EOT + + + + + + + EOT + d = Document.new(xml_string) + b = d.elements['//b'] + b.namespace # => "1" + b.namespace('y') # => "2" + b.namespace('nosuch') # => nil + +Use method REXML::Element#namespaces to retrieve a hash of all defined namespaces +in the element and its ancestors: + + xml_string = <<-EOT + + + + + + + EOT + d = Document.new(xml_string) + d.elements['//a'].namespaces # => {"x"=>"1", "y"=>"2"} + d.elements['//b'].namespaces # => {"x"=>"1", "y"=>"2"} + d.elements['//c'].namespaces # => {"x"=>"1", "y"=>"2", "z"=>"3"} + +Use method REXML::Element#prefixes to retrieve an array of the string prefixes (names) +of all defined namespaces in the element and its ancestors: + + xml_string = <<-EOT + + + + + + + EOT + d = Document.new(xml_string, {compress_whitespace: :all}) + d.elements['//a'].prefixes # => ["x", "y"] + d.elements['//b'].prefixes # => ["x", "y"] + d.elements['//c'].prefixes # => ["x", "y", "z"] + +== Traversing + +You can use certain methods to traverse children of the element. +Each child that meets given criteria is yielded to the given block. + +[Traverse All Children] + + Use inherited method REXML::Parent#each (or its alias #each_child) to traverse + all children of the element: + + doc.root.each {|child| p [child.class, child] } + + Output: + + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + [REXML::Element, ... ] + [REXML::Text, "\n\n"] + +[Traverse Element Children] + + Use method REXML::Element#each_element to traverse only the element children + of the element: + + doc.root.each_element {|e| p [e.class, e] } + + Output: + + [REXML::Element, ... ] + [REXML::Element, ... ] + [REXML::Element, ... ] + [REXML::Element, ... ] + +[Traverse Element Children with Attribute] + + Use method REXML::Element#each_element_with_attribute with the single argument + +attr_name+ to traverse each element child that has the given attribute: + + my_doc = Document.new '' + my_doc.root.each_element_with_attribute('id') {|e| p [e.class, e] } + + Output: + + [REXML::Element, ] + [REXML::Element, ] + [REXML::Element, ] + + Use the same method with a second argument +value+ to traverse + each element child element that has the given attribute and value: + + my_doc.root.each_element_with_attribute('id', '1') {|e| p [e.class, e] } + + Output: + + [REXML::Element, ] + [REXML::Element, ] + + Use the same method with a third argument +max+ to traverse + no more than the given number of element children: + + my_doc.root.each_element_with_attribute('id', '1', 1) {|e| p [e.class, e] } + + Output: + + [REXML::Element, ] + + Use the same method with a fourth argument +xpath+ to traverse + only those element children that match the given xpath: + + my_doc.root.each_element_with_attribute('id', '1', 2, '//d') {|e| p [e.class, e] } + + Output: + + [REXML::Element, ] + +[Traverse Element Children with Text] + + Use method REXML::Element#each_element_with_text with no arguments + to traverse those element children that have text: + + my_doc = Document.new 'bbd' + my_doc.root.each_element_with_text {|e| p [e.class, e] } + + Output: + + [REXML::Element, ... ] + [REXML::Element, ... ] + [REXML::Element, ... ] + + Use the same method with the single argument +text+ to traverse + those element children that have exactly that text: + + my_doc.root.each_element_with_text('b') {|e| p [e.class, e] } + + Output: + + [REXML::Element, ... ] + [REXML::Element, ... ] + + Use the same method with additional second argument +max+ to traverse + no more than the given number of element children: + + my_doc.root.each_element_with_text('b', 1) {|e| p [e.class, e] } + + Output: + + [REXML::Element, ... ] + + Use the same method with additional third argument +xpath+ to traverse + only those element children that also match the given xpath: + + my_doc.root.each_element_with_text('b', 2, '//c') {|e| p [e.class, e] } + + Output: + + [REXML::Element, ... ] + +[Traverse Element Children's Indexes] + + Use inherited method REXML::Parent#each_index to traverse all children's indexes + (not just those of element children): + + doc.root.each_index {|i| print i } + + Output: + + 012345678 + +[Traverse Children Recursively] + + Use included method REXML::Node#each_recursive to traverse all children recursively: + + doc.root.each_recursive {|child| p [child.class, child] } + + Output: + + [REXML::Element, ... ] + [REXML::Element, ... </>] + [REXML::Element, <author> ... </>] + [REXML::Element, <year> ... </>] + [REXML::Element, <price> ... </>] + [REXML::Element, <book category='children'> ... </>] + [REXML::Element, <title lang='en'> ... </>] + [REXML::Element, <author> ... </>] + [REXML::Element, <year> ... </>] + [REXML::Element, <price> ... </>] + [REXML::Element, <book category='web'> ... </>] + [REXML::Element, <title lang='en'> ... </>] + [REXML::Element, <author> ... </>] + [REXML::Element, <author> ... </>] + [REXML::Element, <author> ... </>] + [REXML::Element, <author> ... </>] + [REXML::Element, <author> ... </>] + [REXML::Element, <year> ... </>] + [REXML::Element, <price> ... </>] + [REXML::Element, <book category='web' cover='paperback'> ... </>] + [REXML::Element, <title lang='en'> ... </>] + [REXML::Element, <author> ... </>] + [REXML::Element, <year> ... </>] + [REXML::Element, <price> ... </>] + +== Searching + +You can use certain methods to search among the descendants of an element. + +Use method REXML::Element#get_elements to retrieve all element children of the element +that match the given +xpath+: + + xml_string = <<-EOT + <root> + <a level='1'> + <a level='2'/> + </a> + </root> + EOT + d = Document.new(xml_string) + d.root.get_elements('//a') # => [<a level='1'> ... </>, <a level='2'/>] + +Use method REXML::Element#get_text with no argument to retrieve the first text node +in the first child: + + my_doc = Document.new "<p>some text <b>this is bold!</b> more text</p>" + text_node = my_doc.root.get_text + text_node.class # => REXML::Text + text_node.to_s # => "some text " + +Use the same method with argument +xpath+ to retrieve the first text node +in the first child that matches the xpath: + + my_doc.root.get_text(1) # => "this is bold!" + +Use method REXML::Element#text with no argument to retrieve the text +from the first text node in the first child: + + my_doc = Document.new "<p>some text <b>this is bold!</b> more text</p>" + text_node = my_doc.root.text + text_node.class # => String + text_node # => "some text " + +Use the same method with argument +xpath+ to retrieve the text from the first text node +in the first child that matches the xpath: + + my_doc.root.text(1) # => "this is bold!" + +Use included method REXML::Node#find_first_recursive +to retrieve the first descendant element +for which the given block returns a truthy value, or +nil+ if none: + + doc.root.find_first_recursive do |ele| + ele.name == 'price' + end # => <price> ... </> + doc.root.find_first_recursive do |ele| + ele.name == 'nosuch' + end # => nil + +== Editing + +=== Editing a Document + +[Creating a Document] + + Create a new document with method REXML::Document::new: + + doc = Document.new(source_string) + empty_doc = REXML::Document.new + +[Adding to the Document] + + Add an XML declaration with method REXML::Document#add + and an argument of type REXML::XMLDecl: + + my_doc = Document.new + my_doc.xml_decl.to_s # => "" + my_doc.add(XMLDecl.new('2.0')) + my_doc.xml_decl.to_s # => "<?xml version='2.0'?>" + + Add a document type with method REXML::Document#add + and an argument of type REXML::DocType: + + my_doc = Document.new + my_doc.doctype.to_s # => "" + my_doc.add(DocType.new('foo')) + my_doc.doctype.to_s # => "<!DOCTYPE foo>" + + Add a node of any other REXML type with method REXML::Document#add and an argument + that is not of type REXML::XMLDecl or REXML::DocType: + + my_doc = Document.new + my_doc.add(Element.new('foo')) + my_doc.to_s # => "<foo/>" + + Add an existing element as the root element with method REXML::Document#add_element: + + ele = Element.new('foo') + my_doc = Document.new + my_doc.add_element(ele) + my_doc.root # => <foo/> + + Create and add an element as the root element with method REXML::Document#add_element: + + my_doc = Document.new + my_doc.add_element('foo') + my_doc.root # => <foo/> + +=== Editing an Element + +==== Creating an Element + +Create a new element with method REXML::Element::new: + + ele = Element.new('foo') # => <foo/> + +==== Setting Element Properties + +Set the context for an element with method REXML::Element#context= +(see {Element Context}[../context_rdoc.html]): + + ele.context # => nil + ele.context = {ignore_whitespace_nodes: :all} + ele.context # => {:ignore_whitespace_nodes=>:all} + +Set the parent for an element with inherited method REXML::Child#parent= + + ele.parent # => nil + ele.parent = Element.new('bar') + ele.parent # => <bar/> + +Set the text for an element with method REXML::Element#text=: + + ele.text # => nil + ele.text = 'bar' + ele.text # => "bar" + +==== Adding to an Element + +Add a node as the last child with inherited method REXML::Parent#add (or its alias #push): + + ele = Element.new('foo') # => <foo/> + ele.push(Text.new('bar')) + ele.push(Element.new('baz')) + ele.children # => ["bar", <baz/>] + +Add a node as the first child with inherited method REXML::Parent#unshift: + + ele = Element.new('foo') # => <foo/> + ele.unshift(Element.new('bar')) + ele.unshift(Text.new('baz')) + ele.children # => ["bar", <baz/>] + +Add an element as the last child with method REXML::Element#add_element: + + ele = Element.new('foo') # => <foo/> + ele.add_element('bar') + ele.add_element(Element.new('baz')) + ele.children # => [<bar/>, <baz/>] + +Add a text node as the last child with method REXML::Element#add_text: + + ele = Element.new('foo') # => <foo/> + ele.add_text('bar') + ele.add_text(Text.new('baz')) + ele.children # => ["bar", "baz"] + +Insert a node before a given node with method REXML::Parent#insert_before: + + ele = Element.new('foo') # => <foo/> + ele.add_text('bar') + ele.add_text(Text.new('baz')) + ele.children # => ["bar", "baz"] + target = ele[1] # => "baz" + ele.insert_before(target, Text.new('bat')) + ele.children # => ["bar", "bat", "baz"] + +Insert a node after a given node with method REXML::Parent#insert_after: + + ele = Element.new('foo') # => <foo/> + ele.add_text('bar') + ele.add_text(Text.new('baz')) + ele.children # => ["bar", "baz"] + target = ele[0] # => "bar" + ele.insert_after(target, Text.new('bat')) + ele.children # => ["bar", "bat", "baz"] + +Add an attribute with method REXML::Element#add_attribute: + + ele = Element.new('foo') # => <foo/> + ele.add_attribute('bar', 'baz') + ele.add_attribute(Attribute.new('bat', 'bam')) + ele.attributes # => {"bar"=>bar='baz', "bat"=>bat='bam'} + +Add multiple attributes with method REXML::Element#add_attributes: + + ele = Element.new('foo') # => <foo/> + ele.add_attributes({'bar' => 'baz', 'bat' => 'bam'}) + ele.add_attributes([['ban', 'bap'], ['bah', 'bad']]) + ele.attributes # => {"bar"=>bar='baz', "bat"=>bat='bam', "ban"=>ban='bap', "bah"=>bah='bad'} + +Add a namespace with method REXML::Element#add_namespace: + + ele = Element.new('foo') # => <foo/> + ele.add_namespace('bar') + ele.add_namespace('baz', 'bat') + ele.namespaces # => {"xmlns"=>"bar", "baz"=>"bat"} + +==== Deleting from an Element + +Delete a specific child object with inherited method REXML::Parent#delete: + + ele = Element.new('foo') # => <foo/> + ele.add_element('bar') + ele.add_text('baz') + ele.children # => [<bar/>, "baz"] + target = ele[1] # => "baz" + ele.delete(target) # => "baz" + ele.children # => [<bar/>] + target = ele[0] # => <baz/> + ele.delete(target) # => <baz/> + ele.children # => [] + +Delete a child at a specific index with inherited method REXML::Parent#delete_at: + + ele = Element.new('foo') # => <foo/> + ele.add_element('bar') + ele.add_text('baz') + ele.children # => [<bar/>, "baz"] + ele.delete_at(1) + ele.children # => [<bar/>] + ele.delete_at(0) + ele.children # => [] + +Delete all children meeting a specified criterion with inherited method +REXML::Parent#delete_if: + + ele = Element.new('foo') # => <foo/> + ele.add_element('bar') + ele.add_text('baz') + ele.add_element('bat') + ele.add_text('bam') + ele.children # => [<bar/>, "baz", <bat/>, "bam"] + ele.delete_if {|child| child.instance_of?(Text) } + ele.children # => [<bar/>, <bat/>] + +Delete an element at a specific 1-based index with method REXML::Element#delete_element: + + ele = Element.new('foo') # => <foo/> + ele.add_element('bar') + ele.add_text('baz') + ele.add_element('bat') + ele.add_text('bam') + ele.children # => [<bar/>, "baz", <bat/>, "bam"] + ele.delete_element(2) # => <bat/> + ele.children # => [<bar/>, "baz", "bam"] + ele.delete_element(1) # => <bar/> + ele.children # => ["baz", "bam"] + +Delete a specific element with the same method: + + ele = Element.new('foo') # => <foo/> + ele.add_element('bar') + ele.add_text('baz') + ele.add_element('bat') + ele.add_text('bam') + ele.children # => [<bar/>, "baz", <bat/>, "bam"] + target = ele.elements[2] # => <bat/> + ele.delete_element(target) # => <bat/> + ele.children # => [<bar/>, "baz", "bam"] + +Delete an element matching an xpath using the same method: + + ele = Element.new('foo') # => <foo/> + ele.add_element('bar') + ele.add_text('baz') + ele.add_element('bat') + ele.add_text('bam') + ele.children # => [<bar/>, "baz", <bat/>, "bam"] + ele.delete_element('./bat') # => <bat/> + ele.children # => [<bar/>, "baz", "bam"] + ele.delete_element('./bar') # => <bar/> + ele.children # => ["baz", "bam"] + +Delete an attribute by name with method REXML::Element#delete_attribute: + + ele = Element.new('foo') # => <foo/> + ele.add_attributes({'bar' => 'baz', 'bam' => 'bat'}) + ele.attributes # => {"bar"=>bar='baz', "bam"=>bam='bat'} + ele.delete_attribute('bam') + ele.attributes # => {"bar"=>bar='baz'} + +Delete a namespace with method REXML::Element#delete_namespace: + + ele = Element.new('foo') # => <foo/> + ele.add_namespace('bar') + ele.add_namespace('baz', 'bat') + ele.namespaces # => {"xmlns"=>"bar", "baz"=>"bat"} + ele.delete_namespace('xmlns') + ele.namespaces # => {} # => {"baz"=>"bat"} + ele.delete_namespace('baz') + ele.namespaces # => {} # => {} + +Remove an element from its parent with inherited method REXML::Child#remove: + + ele = Element.new('foo') # => <foo/> + parent = Element.new('bar') # => <bar/> + parent.add_element(ele) # => <foo/> + parent.children.size # => 1 + ele.remove # => <foo/> + parent.children.size # => 0 + +==== Replacing Nodes + +Replace the node at a given 0-based index with inherited method REXML::Parent#[]=: + + ele = Element.new('foo') # => <foo/> + ele.add_element('bar') + ele.add_text('baz') + ele.add_element('bat') + ele.add_text('bam') + ele.children # => [<bar/>, "baz", <bat/>, "bam"] + ele[2] = Text.new('bad') # => "bad" + ele.children # => [<bar/>, "baz", "bad", "bam"] + +Replace a given node with another node with inherited method REXML::Parent#replace_child: + + ele = Element.new('foo') # => <foo/> + ele.add_element('bar') + ele.add_text('baz') + ele.add_element('bat') + ele.add_text('bam') + ele.children # => [<bar/>, "baz", <bat/>, "bam"] + target = ele[2] # => <bat/> + ele.replace_child(target, Text.new('bah')) + ele.children # => [<bar/>, "baz", "bah", "bam"] + +Replace +self+ with a given node with inherited method REXML::Child#replace_with: + + ele = Element.new('foo') # => <foo/> + ele.add_element('bar') + ele.add_text('baz') + ele.add_element('bat') + ele.add_text('bam') + ele.children # => [<bar/>, "baz", <bat/>, "bam"] + target = ele[2] # => <bat/> + target.replace_with(Text.new('bah')) + ele.children # => [<bar/>, "baz", "bah", "bam"] + +=== Cloning + +Create a shallow clone of an element with method REXML::Element#clone. +The clone contains the name and attributes, but not the parent or children: + + ele = Element.new('foo') + ele.add_attributes({'bar' => 0, 'baz' => 1}) + ele.clone # => <foo bar='0' baz='1'/> + +Create a shallow clone of a document with method REXML::Document#clone. +The XML declaration is copied; the document type and root element are not cloned: + + my_xml = '<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE foo><root/>' + my_doc = Document.new(my_xml) + clone_doc = my_doc.clone + + my_doc.xml_decl # => <?xml ... ?> + clone_doc.xml_decl # => <?xml ... ?> + + my_doc.doctype.to_s # => "<?xml version='1.0' encoding='UTF-8'?>" + clone_doc.doctype.to_s # => "" + + my_doc.root # => <root/> + clone_doc.root # => nil + +Create a deep clone of an element with inherited method REXML::Parent#deep_clone. +All nodes and attributes are copied: + + doc.to_s.size # => 825 + clone = doc.deep_clone + clone.to_s.size # => 825 + +== Writing the Document + +Write a document to an \IO stream (defaults to <tt>$stdout</tt>) +with method REXML::Document#write: + + doc.write + +Output: + + <?xml version='1.0' encoding='UTF-8'?> + <bookstore> + + <book category='cooking'> + <title lang='en'>Everyday Italian + Giada De Laurentiis + 2005 + 30.00 + + + + Harry Potter + J K. Rowling + 2005 + 29.99 + + + + XQuery Kick Start + James McGovern + Per Bothner + Kurt Cagle + James Linn + Vaidyanathan Nagarajan + 2003 + 49.99 + + + + Learning XML + Erik T. Ray + 2003 + 39.95 + + + diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/attlistdecl.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/attlistdecl.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/attlistdecl.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/attlistdecl.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,63 @@ +# frozen_string_literal: false +#vim:ts=2 sw=2 noexpandtab: +require_relative 'child' +require_relative 'source' + +module REXML + # This class needs: + # * Documentation + # * Work! Not all types of attlists are intelligently parsed, so we just + # spew back out what we get in. This works, but it would be better if + # we formatted the output ourselves. + # + # AttlistDecls provide *just* enough support to allow namespace + # declarations. If you need some sort of generalized support, or have an + # interesting idea about how to map the hideous, terrible design of DTD + # AttlistDecls onto an intuitive Ruby interface, let me know. I'm desperate + # for anything to make DTDs more palateable. + class AttlistDecl < Child + include Enumerable + + # What is this? Got me. + attr_reader :element_name + + # Create an AttlistDecl, pulling the information from a Source. Notice + # that this isn't very convenient; to create an AttlistDecl, you basically + # have to format it yourself, and then have the initializer parse it. + # Sorry, but for the foreseeable future, DTD support in REXML is pretty + # weak on convenience. Have I mentioned how much I hate DTDs? + def initialize(source) + super() + if (source.kind_of? Array) + @element_name, @pairs, @contents = *source + end + end + + # Access the attlist attribute/value pairs. + # value = attlist_decl[ attribute_name ] + def [](key) + @pairs[key] + end + + # Whether an attlist declaration includes the given attribute definition + # if attlist_decl.include? "xmlns:foobar" + def include?(key) + @pairs.keys.include? key + end + + # Iterate over the key/value pairs: + # attlist_decl.each { |attribute_name, attribute_value| ... } + def each(&block) + @pairs.each(&block) + end + + # Write out exactly what we got in. + def write out, indent=-1 + out << @contents + end + + def node_type + :attlistdecl + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/attribute.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/attribute.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/attribute.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/attribute.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,210 @@ +# frozen_string_literal: true +require_relative "namespace" +require_relative 'text' + +module REXML + # Defines an Element Attribute; IE, a attribute=value pair, as in: + # . Attributes can be in their own + # namespaces. General users of REXML will not interact with the + # Attribute class much. + class Attribute + include Node + include Namespace + + # The element to which this attribute belongs + attr_reader :element + PATTERN = /\s*(#{NAME_STR})\s*=\s*(["'])(.*?)\2/um + + NEEDS_A_SECOND_CHECK = /(<|&((#{Entity::NAME});|(#0*((?:\d+)|(?:x[a-fA-F0-9]+)));)?)/um + + # Constructor. + # FIXME: The parser doesn't catch illegal characters in attributes + # + # first:: + # Either: an Attribute, which this new attribute will become a + # clone of; or a String, which is the name of this attribute + # second:: + # If +first+ is an Attribute, then this may be an Element, or nil. + # If nil, then the Element parent of this attribute is the parent + # of the +first+ Attribute. If the first argument is a String, + # then this must also be a String, and is the content of the attribute. + # If this is the content, it must be fully normalized (contain no + # illegal characters). + # parent:: + # Ignored unless +first+ is a String; otherwise, may be the Element + # parent of this attribute, or nil. + # + # + # Attribute.new( attribute_to_clone ) + # Attribute.new( attribute_to_clone, parent_element ) + # Attribute.new( "attr", "attr_value" ) + # Attribute.new( "attr", "attr_value", parent_element ) + def initialize( first, second=nil, parent=nil ) + @normalized = @unnormalized = @element = nil + if first.kind_of? Attribute + self.name = first.expanded_name + @unnormalized = first.value + if second.kind_of? Element + @element = second + else + @element = first.element + end + elsif first.kind_of? String + @element = parent + self.name = first + @normalized = second.to_s + else + raise "illegal argument #{first.class.name} to Attribute constructor" + end + end + + # Returns the namespace of the attribute. + # + # e = Element.new( "elns:myelement" ) + # e.add_attribute( "nsa:a", "aval" ) + # e.add_attribute( "b", "bval" ) + # e.attributes.get_attribute( "a" ).prefix # -> "nsa" + # e.attributes.get_attribute( "b" ).prefix # -> "" + # a = Attribute.new( "x", "y" ) + # a.prefix # -> "" + def prefix + super + end + + # Returns the namespace URL, if defined, or nil otherwise + # + # e = Element.new("el") + # e.add_namespace("ns", "http://url") + # e.add_attribute("ns:a", "b") + # e.add_attribute("nsx:a", "c") + # e.attribute("ns:a").namespace # => "http://url" + # e.attribute("nsx:a").namespace # => nil + # + # This method always returns "" for no namespace attribute. Because + # the default namespace doesn't apply to attribute names. + # + # From https://www.w3.org/TR/xml-names/#uniqAttrs + # + # > the default namespace does not apply to attribute names + # + # e = REXML::Element.new("el") + # e.add_namespace("", "http://example.com/") + # e.namespace # => "http://example.com/" + # e.add_attribute("a", "b") + # e.attribute("a").namespace # => "" + def namespace arg=nil + arg = prefix if arg.nil? + if arg == "" + "" + else + @element.namespace(arg) + end + end + + # Returns true if other is an Attribute and has the same name and value, + # false otherwise. + def ==( other ) + other.kind_of?(Attribute) and other.name==name and other.value==value + end + + # Creates (and returns) a hash from both the name and value + def hash + name.hash + value.hash + end + + # Returns this attribute out as XML source, expanding the name + # + # a = Attribute.new( "x", "y" ) + # a.to_string # -> "x='y'" + # b = Attribute.new( "ns:x", "y" ) + # b.to_string # -> "ns:x='y'" + def to_string + value = to_s + if @element and @element.context and @element.context[:attribute_quote] == :quote + value = value.gsub('"', '"') if value.include?('"') + %Q^#@expanded_name="#{value}"^ + else + value = value.gsub("'", ''') if value.include?("'") + "#@expanded_name='#{value}'" + end + end + + def doctype + @element&.document&.doctype + end + + # Returns the attribute value, with entities replaced + def to_s + return @normalized if @normalized + + @normalized = Text::normalize( @unnormalized, doctype ) + @normalized + end + + # Returns the UNNORMALIZED value of this attribute. That is, entities + # have been expanded to their values + def value + return @unnormalized if @unnormalized + + @unnormalized = Text::unnormalize(@normalized, doctype, + entity_expansion_text_limit: @element&.document&.entity_expansion_text_limit) + end + + # The normalized value of this attribute. That is, the attribute with + # entities intact. + def normalized=(new_normalized) + @normalized = new_normalized + @unnormalized = nil + end + + # Returns a copy of this attribute + def clone + Attribute.new self + end + + # Sets the element of which this object is an attribute. Normally, this + # is not directly called. + # + # Returns this attribute + def element=( element ) + @element = element + + if @normalized + Text.check( @normalized, NEEDS_A_SECOND_CHECK ) + end + + self + end + + # Removes this Attribute from the tree, and returns true if successful + # + # This method is usually not called directly. + def remove + @element.attributes.delete self.name unless @element.nil? + end + + # Writes this attribute (EG, puts 'key="value"' to the output) + def write( output, indent=-1 ) + output << to_string + end + + def node_type + :attribute + end + + def inspect + rv = +"" + write( rv ) + rv + end + + def xpath + @element.xpath + "/@#{self.expanded_name}" + end + + def document + @element&.document + end + end +end +#vim:ts=2 sw=2 noexpandtab: diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/cdata.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/cdata.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/cdata.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/cdata.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,68 @@ +# frozen_string_literal: false +require_relative "text" + +module REXML + class CData < Text + START = '' + ILLEGAL = /(\]\]>)/ + + # Constructor. CData is data between + # + # _Examples_ + # CData.new( source ) + # CData.new( "Here is some CDATA" ) + # CData.new( "Some unprocessed data", respect_whitespace_TF, parent_element ) + def initialize( first, whitespace=true, parent=nil ) + super( first, whitespace, parent, false, true, ILLEGAL ) + end + + # Make a copy of this object + # + # _Examples_ + # c = CData.new( "Some text" ) + # d = c.clone + # d.to_s # -> "Some text" + def clone + CData.new self + end + + # Returns the content of this CData object + # + # _Examples_ + # c = CData.new( "Some text" ) + # c.to_s # -> "Some text" + def to_s + @string + end + + def value + @string + end + + # == DEPRECATED + # See the rexml/formatters package + # + # Generates XML output of this object + # + # output:: + # Where to write the string. Defaults to $stdout + # indent:: + # The amount to indent this node by + # transitive:: + # Ignored + # ie_hack:: + # Ignored + # + # _Examples_ + # c = CData.new( " Some text " ) + # c.write( $stdout ) #-> + def write( output=$stdout, indent=-1, transitive=false, ie_hack=false ) + Kernel.warn( "#{self.class.name}#write is deprecated", uplevel: 1) + indent( output, indent ) + output << START + output << @string + output << STOP + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/child.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/child.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/child.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/child.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,96 @@ +# frozen_string_literal: false +require_relative "node" + +module REXML + ## + # A Child object is something contained by a parent, and this class + # contains methods to support that. Most user code will not use this + # class directly. + class Child + include Node + attr_reader :parent # The Parent of this object + + # Constructor. Any inheritors of this class should call super to make + # sure this method is called. + # parent:: + # if supplied, the parent of this child will be set to the + # supplied value, and self will be added to the parent + def initialize( parent = nil ) + @parent = nil + # Declare @parent, but don't define it. The next line sets the + # parent. + parent.add( self ) if parent + end + + # Replaces this object with another object. Basically, calls + # Parent.replace_child + # + # Returns:: self + def replace_with( child ) + @parent.replace_child( self, child ) + self + end + + # Removes this child from the parent. + # + # Returns:: self + def remove + unless @parent.nil? + @parent.delete self + end + self + end + + # Sets the parent of this child to the supplied argument. + # + # other:: + # Must be a Parent object. If this object is the same object as the + # existing parent of this child, no action is taken. Otherwise, this + # child is removed from the current parent (if one exists), and is added + # to the new parent. + # Returns:: The parent added + def parent=( other ) + return @parent if @parent == other + @parent.delete self if defined? @parent and @parent + @parent = other + end + + alias :next_sibling :next_sibling_node + alias :previous_sibling :previous_sibling_node + + # Sets the next sibling of this child. This can be used to insert a child + # after some other child. + # a = Element.new("a") + # b = a.add_element("b") + # c = Element.new("c") + # b.next_sibling = c + # # => + def next_sibling=( other ) + parent.insert_after self, other + end + + # Sets the previous sibling of this child. This can be used to insert a + # child before some other child. + # a = Element.new("a") + # b = a.add_element("b") + # c = Element.new("c") + # b.previous_sibling = c + # # => + def previous_sibling=(other) + parent.insert_before self, other + end + + # Returns:: the document this child belongs to, or nil if this child + # belongs to no document + def document + parent&.document + end + + # This doesn't yet handle encodings + def bytes + document&.encoding + + to_s + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/comment.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/comment.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/comment.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/comment.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,80 @@ +# frozen_string_literal: false +require_relative "child" + +module REXML + ## + # Represents an XML comment; that is, text between \ + class Comment < Child + include Comparable + START = "" + + # The content text + + attr_accessor :string + + ## + # Constructor. The first argument can be one of three types: + # @param first If String, the contents of this comment are set to the + # argument. If Comment, the argument is duplicated. If + # Source, the argument is scanned for a comment. + # @param second If the first argument is a Source, this argument + # should be nil, not supplied, or a Parent to be set as the parent + # of this object + def initialize( first, second = nil ) + super(second) + if first.kind_of? String + @string = first + elsif first.kind_of? Comment + @string = first.string + end + end + + def clone + Comment.new self + end + + # == DEPRECATED + # See REXML::Formatters + # + # output:: + # Where to write the string + # indent:: + # An integer. If -1, no indenting will be used; otherwise, the + # indentation will be this number of spaces, and children will be + # indented an additional amount. + # transitive:: + # Ignored by this class. The contents of comments are never modified. + # ie_hack:: + # Needed for conformity to the child API, but not used by this class. + def write( output, indent=-1, transitive=false, ie_hack=false ) + Kernel.warn("#{self.class.name}#write is deprecated. See REXML::Formatters", uplevel: 1) + indent( output, indent ) + output << START + output << @string + output << STOP + end + + alias :to_s :string + + ## + # Compares this Comment to another; the contents of the comment are used + # in the comparison. + def <=>(other) + other.to_s <=> @string + end + + ## + # Compares this Comment to another; the contents of the comment are used + # in the comparison. + def ==( other ) + other.kind_of? Comment and + (other <=> self) == 0 + end + + def node_type + :comment + end + end +end +#vim:ts=2 sw=2 noexpandtab: diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/doctype.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/doctype.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/doctype.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/doctype.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,306 @@ +# frozen_string_literal: false +require_relative "parent" +require_relative "parseexception" +require_relative "namespace" +require_relative 'entity' +require_relative 'attlistdecl' +require_relative 'xmltokens' + +module REXML + class ReferenceWriter + def initialize(id_type, + public_id_literal, + system_literal, + context=nil) + @id_type = id_type + @public_id_literal = public_id_literal + @system_literal = system_literal + if context and context[:prologue_quote] == :apostrophe + @default_quote = "'" + else + @default_quote = "\"" + end + end + + def write(output) + output << " #{@id_type}" + if @public_id_literal + if @public_id_literal.include?("'") + quote = "\"" + else + quote = @default_quote + end + output << " #{quote}#{@public_id_literal}#{quote}" + end + if @system_literal + if @system_literal.include?("'") + quote = "\"" + elsif @system_literal.include?("\"") + quote = "'" + else + quote = @default_quote + end + output << " #{quote}#{@system_literal}#{quote}" + end + end + end + + # Represents an XML DOCTYPE declaration; that is, the contents of . DOCTYPES can be used to declare the DTD of a document, as well as + # being used to declare entities used in the document. + class DocType < Parent + include XMLTokens + START = "" + SYSTEM = "SYSTEM" + PUBLIC = "PUBLIC" + DEFAULT_ENTITIES = { + 'gt'=>EntityConst::GT, + 'lt'=>EntityConst::LT, + 'quot'=>EntityConst::QUOT, + "apos"=>EntityConst::APOS + } + + # name is the name of the doctype + # external_id is the referenced DTD, if given + attr_reader :name, :external_id, :entities, :namespaces + + # Constructor + # + # dt = DocType.new( 'foo', '-//I/Hate/External/IDs' ) + # # + # dt = DocType.new( doctype_to_clone ) + # # Incomplete. Shallow clone of doctype + # + # +Note+ that the constructor: + # + # Doctype.new( Source.new( "" ) ) + # + # is _deprecated_. Do not use it. It will probably disappear. + def initialize( first, parent=nil ) + @entities = DEFAULT_ENTITIES + @long_name = @uri = nil + if first.kind_of? String + super() + @name = first + @external_id = parent + elsif first.kind_of? DocType + super( parent ) + @name = first.name + @external_id = first.external_id + @long_name = first.instance_variable_get(:@long_name) + @uri = first.instance_variable_get(:@uri) + elsif first.kind_of? Array + super( parent ) + @name = first[0] + @external_id = first[1] + @long_name = first[2] + @uri = first[3] + elsif first.kind_of? Source + super( parent ) + parser = Parsers::BaseParser.new( first ) + event = parser.pull + if event[0] == :start_doctype + @name, @external_id, @long_name, @uri, = event[1..-1] + end + else + super() + end + end + + def node_type + :doctype + end + + def attributes_of element + rv = [] + each do |child| + child.each do |key,val| + rv << Attribute.new(key,val) + end if child.kind_of? AttlistDecl and child.element_name == element + end + rv + end + + def attribute_of element, attribute + att_decl = find do |child| + child.kind_of? AttlistDecl and + child.element_name == element and + child.include? attribute + end + return nil unless att_decl + att_decl[attribute] + end + + def clone + DocType.new self + end + + # output:: + # Where to write the string + # indent:: + # An integer. If -1, no indentation will be used; otherwise, the + # indentation will be this number of spaces, and children will be + # indented an additional amount. + # transitive:: + # Ignored + # ie_hack:: + # Ignored + def write( output, indent=0, transitive=false, ie_hack=false ) + f = REXML::Formatters::Default.new + indent( output, indent ) + output << START + output << ' ' + output << @name + if @external_id + reference_writer = ReferenceWriter.new(@external_id, + @long_name, + @uri, + context) + reference_writer.write(output) + end + unless @children.empty? + output << ' [' + @children.each { |child| + output << "\n" + f.write( child, output ) + } + output << "\n]" + end + output << STOP + end + + def context + @parent&.context + end + + def entity( name ) + @entities[name]&.unnormalized + end + + def add child + super(child) + @entities = DEFAULT_ENTITIES.clone if @entities == DEFAULT_ENTITIES + @entities[ child.name ] = child if child.kind_of? Entity + end + + # This method retrieves the public identifier identifying the document's + # DTD. + # + # Method contributed by Henrik Martensson + def public + case @external_id + when "SYSTEM" + nil + when "PUBLIC" + @long_name + end + end + + # This method retrieves the system identifier identifying the document's DTD + # + # Method contributed by Henrik Martensson + def system + case @external_id + when "SYSTEM" + @long_name + when "PUBLIC" + @uri.kind_of?(String) ? @uri : nil + end + end + + # This method returns a list of notations that have been declared in the + # _internal_ DTD subset. Notations in the external DTD subset are not + # listed. + # + # Method contributed by Henrik Martensson + def notations + children().select {|node| node.kind_of?(REXML::NotationDecl)} + end + + # Retrieves a named notation. Only notations declared in the internal + # DTD subset can be retrieved. + # + # Method contributed by Henrik Martensson + def notation(name) + notations.find { |notation_decl| + notation_decl.name == name + } + end + end + + # We don't really handle any of these since we're not a validating + # parser, so we can be pretty dumb about them. All we need to be able + # to do is spew them back out on a write() + + # This is an abstract class. You never use this directly; it serves as a + # parent class for the specific declarations. + class Declaration < Child + def initialize src + super() + @string = src + end + + def to_s + @string+'>' + end + + # == DEPRECATED + # See REXML::Formatters + # + def write( output, indent ) + output << to_s + end + end + + public + class ElementDecl < Declaration + def initialize( src ) + super + end + end + + class ExternalEntity < Child + def initialize( src ) + super() + @entity = src + end + def to_s + @entity + end + def write( output, indent ) + output << @entity + end + end + + class NotationDecl < Child + attr_accessor :public, :system + def initialize name, middle, pub, sys + super(nil) + @name = name + @middle = middle + @public = pub + @system = sys + end + + def to_s + context = parent&.context + notation = "" + notation + end + + def write( output, indent=-1 ) + output << to_s + end + + # This method retrieves the name of the notation. + # + # Method contributed by Henrik Martensson + def name + @name + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/document.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/document.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/document.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/document.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,471 @@ +# frozen_string_literal: false +require_relative "security" +require_relative "element" +require_relative "xmldecl" +require_relative "source" +require_relative "comment" +require_relative "doctype" +require_relative "instruction" +require_relative "rexml" +require_relative "parseexception" +require_relative "output" +require_relative "parsers/baseparser" +require_relative "parsers/streamparser" +require_relative "parsers/treeparser" + +module REXML + # Represents an XML document. + # + # A document may have: + # + # - A single child that may be accessed via method #root. + # - An XML declaration. + # - A document type. + # - Processing instructions. + # + # == In a Hurry? + # + # If you're somewhat familiar with XML + # and have a particular task in mind, + # you may want to see the + # {tasks pages}[../doc/rexml/tasks/tocs/master_toc_rdoc.html], + # and in particular, the + # {tasks page for documents}[../doc/rexml/tasks/tocs/document_toc_rdoc.html]. + # + class Document < Element + # A convenient default XML declaration. Use: + # + # mydoc << XMLDecl.default + # + DECLARATION = XMLDecl.default + + # :call-seq: + # new(string = nil, context = {}) -> new_document + # new(io_stream = nil, context = {}) -> new_document + # new(document = nil, context = {}) -> new_document + # + # Returns a new \REXML::Document object. + # + # When no arguments are given, + # returns an empty document: + # + # d = REXML::Document.new + # d.to_s # => "" + # + # When argument +string+ is given, it must be a string + # containing a valid XML document: + # + # xml_string = 'FooBar' + # d = REXML::Document.new(xml_string) + # d.to_s # => "FooBar" + # + # When argument +io_stream+ is given, it must be an \IO object + # that is opened for reading, and when read must return a valid XML document: + # + # File.write('t.xml', xml_string) + # d = File.open('t.xml', 'r') do |io| + # REXML::Document.new(io) + # end + # d.to_s # => "FooBar" + # + # When argument +document+ is given, it must be an existing + # document object, whose context and attributes (but not children) + # are cloned into the new document: + # + # d = REXML::Document.new(xml_string) + # d.children # => [ ... ] + # d.context = {raw: :all, compress_whitespace: :all} + # d.add_attributes({'bar' => 0, 'baz' => 1}) + # d1 = REXML::Document.new(d) + # d1.children # => [] + # d1.context # => {:raw=>:all, :compress_whitespace=>:all} + # d1.attributes # => {"bar"=>bar='0', "baz"=>baz='1'} + # + # When argument +context+ is given, it must be a hash + # containing context entries for the document; + # see {Element Context}[../doc/rexml/context_rdoc.html]: + # + # context = {raw: :all, compress_whitespace: :all} + # d = REXML::Document.new(xml_string, context) + # d.context # => {:raw=>:all, :compress_whitespace=>:all} + # + def initialize( source = nil, context = {} ) + @entity_expansion_count = 0 + @entity_expansion_limit = Security.entity_expansion_limit + @entity_expansion_text_limit = Security.entity_expansion_text_limit + super() + @context = context + # `source = ""` is an invalid usage because no root element XML is an invalid XML. + # But we accept `""` for backward compatibility. + return if source.nil? or source == "" + if source.kind_of? Document + @context = source.context + super source + else + build( source ) + end + end + + # :call-seq: + # node_type -> :document + # + # Returns the symbol +:document+. + # + def node_type + :document + end + + # :call-seq: + # clone -> new_document + # + # Returns the new document resulting from executing + # Document.new(self). See Document.new. + # + def clone + Document.new self + end + + # :call-seq: + # expanded_name -> empty_string + # + # Returns an empty string. + # + def expanded_name + '' + #d = doc_type + #d ? d.name : "UNDEFINED" + end + alias :name :expanded_name + + # :call-seq: + # add(xml_decl) -> self + # add(doc_type) -> self + # add(object) -> self + # + # Adds an object to the document; returns +self+. + # + # When argument +xml_decl+ is given, + # it must be an REXML::XMLDecl object, + # which becomes the XML declaration for the document, + # replacing the previous XML declaration if any: + # + # d = REXML::Document.new + # d.xml_decl.to_s # => "" + # d.add(REXML::XMLDecl.new('2.0')) + # d.xml_decl.to_s # => "" + # + # When argument +doc_type+ is given, + # it must be an REXML::DocType object, + # which becomes the document type for the document, + # replacing the previous document type, if any: + # + # d = REXML::Document.new + # d.doctype.to_s # => "" + # d.add(REXML::DocType.new('foo')) + # d.doctype.to_s # => "" + # + # When argument +object+ (not an REXML::XMLDecl or REXML::DocType object) + # is given it is added as the last child: + # + # d = REXML::Document.new + # d.add(REXML::Element.new('foo')) + # d.to_s # => "" + # + def add( child ) + if child.kind_of? XMLDecl + if @children[0].kind_of? XMLDecl + @children[0] = child + else + @children.unshift child + end + child.parent = self + elsif child.kind_of? DocType + # Find first Element or DocType node and insert the decl right + # before it. If there is no such node, just insert the child at the + # end. If there is a child and it is an DocType, then replace it. + insert_before_index = @children.find_index { |x| + x.kind_of?(Element) || x.kind_of?(DocType) + } + if insert_before_index # Not null = not end of list + if @children[ insert_before_index ].kind_of? DocType + @children[ insert_before_index ] = child + else + @children[ insert_before_index-1, 0 ] = child + end + else # Insert at end of list + @children << child + end + child.parent = self + else + rv = super + raise "attempted adding second root element to document" if @elements.size > 1 + rv + end + end + alias :<< :add + + # :call-seq: + # add_element(name_or_element = nil, attributes = nil) -> new_element + # + # Adds an element to the document by calling REXML::Element.add_element: + # + # REXML::Element.add_element(name_or_element, attributes) + def add_element(arg=nil, arg2=nil) + rv = super + raise "attempted adding second root element to document" if @elements.size > 1 + rv + end + + # :call-seq: + # root -> root_element or nil + # + # Returns the root element of the document, if it exists, otherwise +nil+: + # + # d = REXML::Document.new('') + # d.root # => + # d = REXML::Document.new('') + # d.root # => nil + # + def root + elements[1] + #self + #@children.find { |item| item.kind_of? Element } + end + + # :call-seq: + # doctype -> doc_type or nil + # + # Returns the DocType object for the document, if it exists, otherwise +nil+: + # + # d = REXML::Document.new('') + # d.doctype.class # => REXML::DocType + # d = REXML::Document.new('') + # d.doctype.class # => nil + # + def doctype + @children.find { |item| item.kind_of? DocType } + end + + # :call-seq: + # xml_decl -> xml_decl + # + # Returns the XMLDecl object for the document, if it exists, + # otherwise the default XMLDecl object: + # + # d = REXML::Document.new('') + # d.xml_decl.class # => REXML::XMLDecl + # d.xml_decl.to_s # => "" + # d = REXML::Document.new('') + # d.xml_decl.class # => REXML::XMLDecl + # d.xml_decl.to_s # => "" + # + def xml_decl + rv = @children[0] + return rv if rv.kind_of? XMLDecl + @children.unshift(XMLDecl.default)[0] + end + + # :call-seq: + # version -> version_string + # + # Returns the XMLDecl version of this document as a string, + # if it has been set, otherwise the default version: + # + # d = REXML::Document.new('') + # d.version # => "2.0" + # d = REXML::Document.new('') + # d.version # => "1.0" + # + def version + xml_decl().version + end + + # :call-seq: + # encoding -> encoding_string + # + # Returns the XMLDecl encoding of the document, + # if it has been set, otherwise the default encoding: + # + # d = REXML::Document.new('') + # d.encoding # => "UTF-16" + # d = REXML::Document.new('') + # d.encoding # => "UTF-8" + # + def encoding + xml_decl().encoding + end + + # :call-seq: + # stand_alone? + # + # Returns the XMLDecl standalone value of the document as a string, + # if it has been set, otherwise the default standalone value: + # + # d = REXML::Document.new('') + # d.stand_alone? # => "yes" + # d = REXML::Document.new('') + # d.stand_alone? # => nil + # + def stand_alone? + xml_decl().stand_alone? + end + + # :call-seq: + # doc.write(output=$stdout, indent=-1, transitive=false, ie_hack=false, encoding=nil) + # doc.write(options={:output => $stdout, :indent => -1, :transitive => false, :ie_hack => false, :encoding => nil}) + # + # Write the XML tree out, optionally with indent. This writes out the + # entire XML document, including XML declarations, doctype declarations, + # and processing instructions (if any are given). + # + # A controversial point is whether Document should always write the XML + # declaration () whether or not one is given by the + # user (or source document). REXML does not write one if one was not + # specified, because it adds unnecessary bandwidth to applications such + # as XML-RPC. + # + # Accept Nth argument style and options Hash style as argument. + # The recommended style is options Hash style for one or more + # arguments case. + # + # _Examples_ + # Document.new("").write + # + # output = "" + # Document.new("").write(output) + # + # output = "" + # Document.new("").write(:output => output, :indent => 2) + # + # See also the classes in the rexml/formatters package for the proper way + # to change the default formatting of XML output. + # + # _Examples_ + # + # output = "" + # tr = Transitive.new + # tr.write(Document.new(""), output) + # + # output:: + # output an object which supports '<< string'; this is where the + # document will be written. + # indent:: + # An integer. If -1, no indenting will be used; otherwise, the + # indentation will be twice this number of spaces, and children will be + # indented an additional amount. For a value of 3, every item will be + # indented 3 more levels, or 6 more spaces (2 * 3). Defaults to -1 + # transitive:: + # If transitive is true and indent is >= 0, then the output will be + # pretty-printed in such a way that the added whitespace does not affect + # the absolute *value* of the document -- that is, it leaves the value + # and number of Text nodes in the document unchanged. + # ie_hack:: + # This hack inserts a space before the /> on empty tags to address + # a limitation of Internet Explorer. Defaults to false + # encoding:: + # Encoding name as String. Change output encoding to specified encoding + # instead of encoding in XML declaration. + # Defaults to nil. It means encoding in XML declaration is used. + def write(*arguments) + if arguments.size == 1 and arguments[0].class == Hash + options = arguments[0] + + output = options[:output] + indent = options[:indent] + transitive = options[:transitive] + ie_hack = options[:ie_hack] + encoding = options[:encoding] + else + output, indent, transitive, ie_hack, encoding, = *arguments + end + + output ||= $stdout + indent ||= -1 + transitive = false if transitive.nil? + ie_hack = false if ie_hack.nil? + encoding ||= xml_decl.encoding + + if encoding != 'UTF-8' && !output.kind_of?(Output) + output = Output.new( output, encoding ) + end + formatter = if indent > -1 + if transitive + require_relative "formatters/transitive" + REXML::Formatters::Transitive.new( indent, ie_hack ) + else + REXML::Formatters::Pretty.new( indent, ie_hack ) + end + else + REXML::Formatters::Default.new( ie_hack ) + end + formatter.write( self, output ) + end + + + def Document::parse_stream( source, listener ) + Parsers::StreamParser.new( source, listener ).parse + end + + # Set the entity expansion limit. By default the limit is set to 10000. + # + # Deprecated. Use REXML::Security.entity_expansion_limit= instead. + def Document::entity_expansion_limit=( val ) + Security.entity_expansion_limit = val + end + + # Get the entity expansion limit. By default the limit is set to 10000. + # + # Deprecated. Use REXML::Security.entity_expansion_limit= instead. + def Document::entity_expansion_limit + Security.entity_expansion_limit + end + + # Set the entity expansion limit. By default the limit is set to 10240. + # + # Deprecated. Use REXML::Security.entity_expansion_text_limit= instead. + def Document::entity_expansion_text_limit=( val ) + Security.entity_expansion_text_limit = val + end + + # Get the entity expansion limit. By default the limit is set to 10240. + # + # Deprecated. Use REXML::Security.entity_expansion_text_limit instead. + def Document::entity_expansion_text_limit + Security.entity_expansion_text_limit + end + + attr_reader :entity_expansion_count + attr_writer :entity_expansion_limit + attr_accessor :entity_expansion_text_limit + + def record_entity_expansion + @entity_expansion_count += 1 + if @entity_expansion_count > @entity_expansion_limit + raise "number of entity expansions exceeded, processing aborted." + end + end + + def document + self + end + + private + + attr_accessor :namespaces_cache + + # New document level cache is created and available in this block. + # This API is thread unsafe. Users can't change this document in this block. + def enable_cache + @namespaces_cache = {} + begin + yield + ensure + @namespaces_cache = nil + end + end + + def build( source ) + Parsers::TreeParser.new( source, self ).parse + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/attlistdecl.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/attlistdecl.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/attlistdecl.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/attlistdecl.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,11 @@ +# frozen_string_literal: false +require_relative "../child" +module REXML + module DTD + class AttlistDecl < Child + START = ")/um + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/dtd.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/dtd.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/dtd.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/dtd.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,47 @@ +# frozen_string_literal: false +require_relative "elementdecl" +require_relative "entitydecl" +require_relative "../comment" +require_relative "notationdecl" +require_relative "attlistdecl" +require_relative "../parent" + +module REXML + module DTD + class Parser + def Parser.parse( input ) + case input + when String + parse_helper input + when File + parse_helper input.read + end + end + + # Takes a String and parses it out + def Parser.parse_helper( input ) + contents = Parent.new + while input.size > 0 + case input + when ElementDecl.PATTERN_RE + match = $& + contents << ElementDecl.new( match ) + when AttlistDecl.PATTERN_RE + matchdata = $~ + contents << AttlistDecl.new( matchdata ) + when EntityDecl.PATTERN_RE + matchdata = $~ + contents << EntityDecl.new( matchdata ) + when Comment.PATTERN_RE + matchdata = $~ + contents << Comment.new( matchdata ) + when NotationDecl.PATTERN_RE + matchdata = $~ + contents << NotationDecl.new( matchdata ) + end + end + contents + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/elementdecl.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/elementdecl.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/elementdecl.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/elementdecl.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,18 @@ +# frozen_string_literal: false +require_relative "../child" +module REXML + module DTD + class ElementDecl < Child + START = "/um + PATTERN_RE = /^\s*#{START}\s+((?:[:\w][-\.\w]*:)?[-!\*\.\w]*)(.*?)>/ + #\s*((((["']).*?\5)|[^\/'">]*)*?)(\/)?>/um, true) + + def initialize match + @name = match[1] + @rest = match[2] + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/entitydecl.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/entitydecl.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/entitydecl.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/entitydecl.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,57 @@ +# frozen_string_literal: false +require_relative "../child" +module REXML + module DTD + class EntityDecl < Child + START = "/um + SYSTEM = /^\s*#{START}\s+(?:%\s+)?(\w+)\s+SYSTEM\s+((["']).*?\3)(?:\s+NDATA\s+\w+)?\s*>/um + PLAIN = /^\s*#{START}\s+(\w+)\s+((["']).*?\3)\s*>/um + PERCENT = /^\s*#{START}\s+%\s+(\w+)\s+((["']).*?\3)\s*>/um + # + # + def initialize src + super() + md = nil + if src.match( PUBLIC ) + md = src.match( PUBLIC, true ) + @middle = "PUBLIC" + @content = "#{md[2]} #{md[4]}" + elsif src.match( SYSTEM ) + md = src.match( SYSTEM, true ) + @middle = "SYSTEM" + @content = md[2] + elsif src.match( PLAIN ) + md = src.match( PLAIN, true ) + @middle = "" + @content = md[2] + elsif src.match( PERCENT ) + md = src.match( PERCENT, true ) + @middle = "" + @content = md[2] + end + raise ParseException.new("failed Entity match", src) if md.nil? + @name = md[1] + end + + def to_s + rv = " 0 + rv << @content + rv + end + + def write( output, indent ) + indent( output, indent ) + output << to_s + end + + def EntityDecl.parse_source source, listener + md = source.match( PATTERN_RE, true ) + thing = md[0].squeeze(" \t\n\r") + listener.send inspect.downcase, thing + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/notationdecl.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/notationdecl.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/notationdecl.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/dtd/notationdecl.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,40 @@ +# frozen_string_literal: false +require_relative "../child" +module REXML + module DTD + class NotationDecl < Child + START = "/um + SYSTEM = /^\s*#{START}\s+(\w[\w-]*)\s+(SYSTEM)\s+((["']).*?\4)\s*>/um + def initialize src + super() + if src.match( PUBLIC ) + md = src.match( PUBLIC, true ) + elsif src.match( SYSTEM ) + md = src.match( SYSTEM, true ) + else + raise ParseException.new( "error parsing notation: no matching pattern", src ) + end + @name = md[1] + @middle = md[2] + @rest = md[3] + end + + def to_s + "" + end + + def write( output, indent ) + indent( output, indent ) + output << to_s + end + + def NotationDecl.parse_source source, listener + md = source.match( PATTERN_RE, true ) + thing = md[0].squeeze(" \t\n\r") + listener.send inspect.downcase, thing + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/element.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/element.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/element.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/element.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,2578 @@ +# frozen_string_literal: false +require_relative "parent" +require_relative "namespace" +require_relative "attribute" +require_relative "cdata" +require_relative "xpath" +require_relative "parseexception" + +module REXML + # An \REXML::Element object represents an XML element. + # + # An element: + # + # - Has a name (string). + # - May have a parent (another element). + # - Has zero or more children + # (other elements, text, CDATA, processing instructions, and comments). + # - Has zero or more siblings + # (other elements, text, CDATA, processing instructions, and comments). + # - Has zero or more named attributes. + # + # == In a Hurry? + # + # If you're somewhat familiar with XML + # and have a particular task in mind, + # you may want to see the + # {tasks pages}[../doc/rexml/tasks/tocs/master_toc_rdoc.html], + # and in particular, the + # {tasks page for elements}[../doc/rexml/tasks/tocs/element_toc_rdoc.html]. + # + # === Name + # + # An element has a name, which is initially set when the element is created: + # + # e = REXML::Element.new('foo') + # e.name # => "foo" + # + # The name may be changed: + # + # e.name = 'bar' + # e.name # => "bar" + # + # + # === \Parent + # + # An element may have a parent. + # + # Its parent may be assigned explicitly when the element is created: + # + # e0 = REXML::Element.new('foo') + # e1 = REXML::Element.new('bar', e0) + # e1.parent # => ... + # + # Note: the representation of an element always shows the element's name. + # If the element has children, the representation indicates that + # by including an ellipsis (...). + # + # The parent may be assigned explicitly at any time: + # + # e2 = REXML::Element.new('baz') + # e1.parent = e2 + # e1.parent # => + # + # When an element is added as a child, its parent is set automatically: + # + # e1.add_element(e0) + # e0.parent # => ... + # + # For an element that has no parent, method +parent+ returns +nil+. + # + # === Children + # + # An element has zero or more children. + # The children are an ordered collection + # of all objects whose parent is the element itself. + # + # The children may include any combination of elements, text, comments, + # processing instructions, and CDATA. + # (This example keeps things clean by controlling whitespace + # via a +context+ setting.) + # + # xml_string = <<-EOT + # + # + # text 0 + # + # + # + # + # text 1 + # + # + # + # + # EOT + # context = {ignore_whitespace_nodes: :all, compress_whitespace: :all} + # d = REXML::Document.new(xml_string, context) + # root = d.root + # root.children.size # => 10 + # root.each {|child| p "#{child.class}: #{child}" } + # + # Output: + # + # "REXML::Element: " + # "REXML::Text: \n text 0\n " + # "REXML::Comment: comment 0" + # "REXML::Instruction: " + # "REXML::CData: cdata 0" + # "REXML::Element: " + # "REXML::Text: \n text 1\n " + # "REXML::Comment: comment 1" + # "REXML::Instruction: " + # "REXML::CData: cdata 1" + # + # A child may be added using inherited methods + # Parent#insert_before or Parent#insert_after: + # + # xml_string = '' + # d = REXML::Document.new(xml_string) + # root = d.root + # c = d.root[1] # => + # root.insert_before(c, REXML::Element.new('b')) + # root.to_a # => [, , , ] + # + # A child may be replaced using Parent#replace_child: + # + # root.replace_child(c, REXML::Element.new('x')) + # root.to_a # => [, , , ] + # + # A child may be removed using Parent#delete: + # + # x = root[2] # => + # root.delete(x) + # root.to_a # => [, , ] + # + # === Siblings + # + # An element has zero or more siblings, + # which are the other children of the element's parent. + # + # In the example above, element +ele_1+ is between a CDATA sibling + # and a text sibling: + # + # ele_1 = root[5] # => + # ele_1.previous_sibling # => "cdata 0" + # ele_1.next_sibling # => "\n text 1\n " + # + # === \Attributes + # + # An element has zero or more named attributes. + # + # A new element has no attributes: + # + # e = REXML::Element.new('foo') + # e.attributes # => {} + # + # Attributes may be added: + # + # e.add_attribute('bar', 'baz') + # e.add_attribute('bat', 'bam') + # e.attributes.size # => 2 + # e['bar'] # => "baz" + # e['bat'] # => "bam" + # + # An existing attribute may be modified: + # + # e.add_attribute('bar', 'bad') + # e.attributes.size # => 2 + # e['bar'] # => "bad" + # + # An existing attribute may be deleted: + # + # e.delete_attribute('bar') + # e.attributes.size # => 1 + # e['bar'] # => nil + # + # == What's Here + # + # To begin with, what's elsewhere? + # + # \Class \REXML::Element inherits from its ancestor classes: + # + # - REXML::Child + # - REXML::Parent + # + # \REXML::Element itself and its ancestors also include modules: + # + # - {Enumerable}[https://docs.ruby-lang.org/en/master/Enumerable.html] + # - REXML::Namespace + # - REXML::Node + # - REXML::XMLTokens + # + # === Methods for Creating an \Element + # + # ::new:: Returns a new empty element. + # #clone:: Returns a clone of another element. + # + # === Methods for Attributes + # + # {[attribute_name]}[#method-i-5B-5D]:: Returns an attribute value. + # #add_attribute:: Adds a new attribute. + # #add_attributes:: Adds multiple new attributes. + # #attribute:: Returns the attribute value for a given name and optional namespace. + # #delete_attribute:: Removes an attribute. + # + # === Methods for Children + # + # {[index]}[#method-i-5B-5D]:: Returns the child at the given offset. + # #add_element:: Adds an element as the last child. + # #delete_element:: Deletes a child element. + # #each_element:: Calls the given block with each child element. + # #each_element_with_attribute:: Calls the given block with each child element + # that meets given criteria, + # which can include the attribute name. + # #each_element_with_text:: Calls the given block with each child element + # that meets given criteria, + # which can include text. + # #get_elements:: Returns an array of element children that match a given xpath. + # + # === Methods for \Text Children + # + # #add_text:: Adds a text node to the element. + # #get_text:: Returns a text node that meets specified criteria. + # #text:: Returns the text string from the first node that meets specified criteria. + # #texts:: Returns an array of the text children of the element. + # #text=:: Adds, removes, or replaces the first text child of the element + # + # === Methods for Other Children + # + # #cdatas:: Returns an array of the cdata children of the element. + # #comments:: Returns an array of the comment children of the element. + # #instructions:: Returns an array of the instruction children of the element. + # + # === Methods for Namespaces + # + # #add_namespace:: Adds a namespace to the element. + # #delete_namespace:: Removes a namespace from the element. + # #namespace:: Returns the string namespace URI for the element. + # #namespaces:: Returns a hash of all defined namespaces in the element. + # #prefixes:: Returns an array of the string prefixes (names) + # of all defined namespaces in the element + # + # === Methods for Querying + # + # #document:: Returns the document, if any, that the element belongs to. + # #root:: Returns the most distant element (not document) ancestor of the element. + # #root_node:: Returns the most distant ancestor of the element. + # #xpath:: Returns the string xpath to the element + # relative to the most distant parent + # #has_attributes?:: Returns whether the element has attributes. + # #has_elements?:: Returns whether the element has elements. + # #has_text?:: Returns whether the element has text. + # #next_element:: Returns the next sibling that is an element. + # #previous_element:: Returns the previous sibling that is an element. + # #raw:: Returns whether raw mode is set for the element. + # #whitespace:: Returns whether whitespace is respected for the element. + # #ignore_whitespace_nodes:: Returns whether whitespace nodes + # are to be ignored for the element. + # #node_type:: Returns symbol :element. + # + # === One More Method + # + # #inspect:: Returns a string representation of the element. + # + # === Accessors + # + # #elements:: Returns the REXML::Elements object for the element. + # #attributes:: Returns the REXML::Attributes object for the element. + # #context:: Returns or sets the context hash for the element. + # + class Element < Parent + include Namespace + + UNDEFINED = "UNDEFINED"; # The default name + + # Mechanisms for accessing attributes and child elements of this + # element. + attr_reader :attributes, :elements + # The context holds information about the processing environment, such as + # whitespace handling. + attr_accessor :context + + # :call-seq: + # Element.new(name = 'UNDEFINED', parent = nil, context = nil) -> new_element + # Element.new(element, parent = nil, context = nil) -> new_element + # + # Returns a new \REXML::Element object. + # + # When no arguments are given, + # returns an element with name 'UNDEFINED': + # + # e = REXML::Element.new # => + # e.class # => REXML::Element + # e.name # => "UNDEFINED" + # + # When only argument +name+ is given, + # returns an element of the given name: + # + # REXML::Element.new('foo') # => + # + # When only argument +element+ is given, it must be an \REXML::Element object; + # returns a shallow copy of the given element: + # + # e0 = REXML::Element.new('foo') + # e1 = REXML::Element.new(e0) # => + # + # When argument +parent+ is also given, it must be an REXML::Parent object: + # + # e = REXML::Element.new('foo', REXML::Parent.new) + # e.parent # => #]> + # + # When argument +context+ is also given, it must be a hash + # representing the context for the element; + # see {Element Context}[../doc/rexml/context_rdoc.html]: + # + # e = REXML::Element.new('foo', nil, {raw: :all}) + # e.context # => {:raw=>:all} + # + def initialize( arg = UNDEFINED, parent=nil, context=nil ) + super(parent) + + @elements = Elements.new(self) + @attributes = Attributes.new(self) + @context = context + + if arg.kind_of? String + self.name = arg + elsif arg.kind_of? Element + self.name = arg.expanded_name + arg.attributes.each_attribute{ |attribute| + @attributes << Attribute.new( attribute ) + } + @context = arg.context + end + end + + # :call-seq: + # inspect -> string + # + # Returns a string representation of the element. + # + # For an element with no attributes and no children, shows the element name: + # + # REXML::Element.new.inspect # => "" + # + # Shows attributes, if any: + # + # e = REXML::Element.new('foo') + # e.add_attributes({'bar' => 0, 'baz' => 1}) + # e.inspect # => "" + # + # Shows an ellipsis (...), if there are child elements: + # + # e.add_element(REXML::Element.new('bar')) + # e.add_element(REXML::Element.new('baz')) + # e.inspect # => " ... " + # + def inspect + rv = "<#@expanded_name" + + @attributes.each_attribute do |attr| + rv << " " + attr.write( rv, 0 ) + end + + if children.size > 0 + rv << "> ... " + else + rv << "/>" + end + end + + # :call-seq: + # clone -> new_element + # + # Returns a shallow copy of the element, containing the name and attributes, + # but not the parent or children: + # + # e = REXML::Element.new('foo') + # e.add_attributes({'bar' => 0, 'baz' => 1}) + # e.clone # => + # + def clone + self.class.new self + end + + # :call-seq: + # root_node -> document or element + # + # Returns the most distant ancestor of +self+. + # + # When the element is part of a document, + # returns the root node of the document. + # Note that the root node is different from the document element; + # in this example +a+ is document element and the root node is its parent: + # + # d = REXML::Document.new('') + # top_element = d.first # => ... + # child = top_element.first # => ... + # d.root_node == d # => true + # top_element.root_node == d # => true + # child.root_node == d # => true + # + # When the element is not part of a document, but does have ancestor elements, + # returns the most distant ancestor element: + # + # e0 = REXML::Element.new('foo') + # e1 = REXML::Element.new('bar') + # e1.parent = e0 + # e2 = REXML::Element.new('baz') + # e2.parent = e1 + # e2.root_node == e0 # => true + # + # When the element has no ancestor elements, + # returns +self+: + # + # e = REXML::Element.new('foo') + # e.root_node == e # => true + # + # Related: #root, #document. + # + def root_node + parent.nil? ? self : parent.root_node + end + + # :call-seq: + # root -> element + # + # Returns the most distant _element_ (not document) ancestor of the element: + # + # d = REXML::Document.new('') + # top_element = d.first + # child = top_element.first + # top_element.root == top_element # => true + # child.root == top_element # => true + # + # For a document, returns the topmost element: + # + # d.root == top_element # => true + # + # Related: #root_node, #document. + # + def root + target = self + while target + return target.elements[1] if target.kind_of? Document + parent = target.parent + return target if parent.kind_of? Document or parent.nil? + target = parent + end + nil + end + + # :call-seq: + # document -> document or nil + # + # If the element is part of a document, returns that document: + # + # d = REXML::Document.new('') + # top_element = d.first + # child = top_element.first + # top_element.document == d # => true + # child.document == d # => true + # + # If the element is not part of a document, returns +nil+: + # + # REXML::Element.new.document # => nil + # + # For a document, returns +self+: + # + # d.document == d # => true + # + # Related: #root, #root_node. + # + def document + root&.parent + end + + # :call-seq: + # whitespace + # + # Returns +true+ if whitespace is respected for this element, + # +false+ otherwise. + # + # See {Element Context}[../doc/rexml/context_rdoc.html]. + # + # The evaluation is tested against the element's +expanded_name+, + # and so is namespace-sensitive. + def whitespace + @whitespace = nil + if @context + if @context[:respect_whitespace] + @whitespace = (@context[:respect_whitespace] == :all or + @context[:respect_whitespace].include? expanded_name) + end + @whitespace = false if (@context[:compress_whitespace] and + (@context[:compress_whitespace] == :all or + @context[:compress_whitespace].include? expanded_name) + ) + end + @whitespace = true unless @whitespace == false + @whitespace + end + + # :call-seq: + # ignore_whitespace_nodes + # + # Returns +true+ if whitespace nodes are ignored for the element. + # + # See {Element Context}[../doc/rexml/context_rdoc.html]. + # + def ignore_whitespace_nodes + @ignore_whitespace_nodes = false + if @context + if @context[:ignore_whitespace_nodes] + @ignore_whitespace_nodes = + (@context[:ignore_whitespace_nodes] == :all or + @context[:ignore_whitespace_nodes].include? expanded_name) + end + end + end + + # :call-seq: + # raw + # + # Returns +true+ if raw mode is set for the element. + # + # See {Element Context}[../doc/rexml/context_rdoc.html]. + # + # The evaluation is tested against +expanded_name+, and so is namespace + # sensitive. + def raw + @raw = (@context and @context[:raw] and + (@context[:raw] == :all or + @context[:raw].include? expanded_name)) + @raw + end + + #once :whitespace, :raw, :ignore_whitespace_nodes + + ################################################# + # Namespaces # + ################################################# + + # :call-seq: + # prefixes -> array_of_namespace_prefixes + # + # Returns an array of the string prefixes (names) of all defined namespaces + # in the element and its ancestors: + # + # xml_string = <<-EOT + # + # + # + # + # + # + # EOT + # d = REXML::Document.new(xml_string, {compress_whitespace: :all}) + # d.elements['//a'].prefixes # => ["x", "y"] + # d.elements['//b'].prefixes # => ["x", "y"] + # d.elements['//c'].prefixes # => ["x", "y", "z"] + # + def prefixes + prefixes = [] + prefixes = parent.prefixes if parent + prefixes |= attributes.prefixes + prefixes + end + + # :call-seq: + # namespaces -> array_of_namespace_names + # + # Returns a hash of all defined namespaces + # in the element and its ancestors: + # + # xml_string = <<-EOT + # + # + # + # + # + # + # EOT + # d = REXML::Document.new(xml_string) + # d.elements['//a'].namespaces # => {"x"=>"1", "y"=>"2"} + # d.elements['//b'].namespaces # => {"x"=>"1", "y"=>"2"} + # d.elements['//c'].namespaces # => {"x"=>"1", "y"=>"2", "z"=>"3"} + # + def namespaces + namespaces_cache = document&.__send__(:namespaces_cache) + if namespaces_cache + namespaces_cache[self] ||= calculate_namespaces + else + calculate_namespaces + end + end + + # :call-seq: + # namespace(prefix = nil) -> string_uri or nil + # + # Returns the string namespace URI for the element, + # possibly deriving from one of its ancestors. + # + # xml_string = <<-EOT + # + # + # + # + # + # + # EOT + # d = REXML::Document.new(xml_string) + # b = d.elements['//b'] + # b.namespace # => "1" + # b.namespace('y') # => "2" + # b.namespace('nosuch') # => nil + # + def namespace(prefix=nil) + if prefix.nil? + prefix = prefix() + end + prefix = (prefix == '') ? 'xmlns' : prefix.delete_prefix("xmlns:") + ns = namespaces[prefix] + + ns = '' if ns.nil? and prefix == 'xmlns' + ns + end + + # :call-seq: + # add_namespace(prefix, uri = nil) -> self + # + # Adds a namespace to the element; returns +self+. + # + # With the single argument +prefix+, + # adds a namespace using the given +prefix+ and the namespace URI: + # + # e = REXML::Element.new('foo') + # e.add_namespace('bar') + # e.namespaces # => {"xmlns"=>"bar"} + # + # With both arguments +prefix+ and +uri+ given, + # adds a namespace using both arguments: + # + # e.add_namespace('baz', 'bat') + # e.namespaces # => {"xmlns"=>"bar", "baz"=>"bat"} + # + def add_namespace( prefix, uri=nil ) + unless uri + @attributes["xmlns"] = prefix + else + prefix = "xmlns:#{prefix}" unless prefix =~ /^xmlns:/ + @attributes[ prefix ] = uri + end + self + end + + # :call-seq: + # delete_namespace(namespace = 'xmlns') -> self + # + # Removes a namespace from the element. + # + # With no argument, removes the default namespace: + # + # d = REXML::Document.new "" + # d.to_s # => "" + # d.root.delete_namespace # => + # d.to_s # => "" + # + # With argument +namespace+, removes the specified namespace: + # + # d.root.delete_namespace('foo') + # d.to_s # => "" + # + # Does nothing if no such namespace is found: + # + # d.root.delete_namespace('nosuch') + # d.to_s # => "" + # + def delete_namespace namespace="xmlns" + namespace = "xmlns:#{namespace}" unless namespace == 'xmlns' + attribute = attributes.get_attribute(namespace) + attribute.remove unless attribute.nil? + self + end + + ################################################# + # Elements # + ################################################# + + # :call-seq: + # add_element(name, attributes = nil) -> new_element + # add_element(element, attributes = nil) -> element + # + # Adds a child element, optionally setting attributes + # on the added element; returns the added element. + # + # With string argument +name+, creates a new element with that name + # and adds the new element as a child: + # + # e0 = REXML::Element.new('foo') + # e0.add_element('bar') + # e0[0] # => + # + # + # With argument +name+ and hash argument +attributes+, + # sets attributes on the new element: + # + # e0.add_element('baz', {'bat' => '0', 'bam' => '1'}) + # e0[1] # => + # + # With element argument +element+, adds that element as a child: + # + # e0 = REXML::Element.new('foo') + # e1 = REXML::Element.new('bar') + # e0.add_element(e1) + # e0[0] # => + # + # With argument +element+ and hash argument +attributes+, + # sets attributes on the added element: + # + # e0.add_element(e1, {'bat' => '0', 'bam' => '1'}) + # e0[1] # => + # + def add_element element, attrs=nil + raise "First argument must be either an element name, or an Element object" if element.nil? + el = @elements.add(element) + attrs.each do |key, value| + el.attributes[key]=value + end if attrs.kind_of? Hash + el + end + + # :call-seq: + # delete_element(index) -> removed_element or nil + # delete_element(element) -> removed_element or nil + # delete_element(xpath) -> removed_element or nil + # + # Deletes a child element. + # + # When 1-based integer argument +index+ is given, + # removes and returns the child element at that offset if it exists; + # indexing does not include text nodes; + # returns +nil+ if the element does not exist: + # + # d = REXML::Document.new 'text' + # a = d.root # => ... + # a.delete_element(1) # => + # a.delete_element(1) # => + # a.delete_element(1) # => nil + # + # When element argument +element+ is given, + # removes and returns that child element if it exists, + # otherwise returns +nil+: + # + # d = REXML::Document.new 'text' + # a = d.root # => ... + # c = a[2] # => + # a.delete_element(c) # => + # a.delete_element(c) # => nil + # + # When xpath argument +xpath+ is given, + # removes and returns the element at xpath if it exists, + # otherwise returns +nil+: + # + # d = REXML::Document.new 'text' + # a = d.root # => ... + # a.delete_element('//c') # => + # a.delete_element('//c') # => nil + # + def delete_element element + @elements.delete element + end + + # :call-seq: + # has_elements? + # + # Returns +true+ if the element has one or more element children, + # +false+ otherwise: + # + # d = REXML::Document.new 'text' + # a = d.root # => ... + # a.has_elements? # => true + # b = a[0] # => + # b.has_elements? # => false + # + def has_elements? + !@elements.empty? + end + + # :call-seq: + # each_element_with_attribute(attr_name, value = nil, max = 0, xpath = nil) {|e| ... } + # + # Calls the given block with each child element that meets given criteria. + # + # When only string argument +attr_name+ is given, + # calls the block with each child element that has that attribute: + # + # d = REXML::Document.new '' + # a = d.root + # a.each_element_with_attribute('id') {|e| p e } + # + # Output: + # + # + # + # + # + # With argument +attr_name+ and string argument +value+ given, + # calls the block with each child element that has that attribute + # with that value: + # + # a.each_element_with_attribute('id', '1') {|e| p e } + # + # Output: + # + # + # + # + # With arguments +attr_name+, +value+, and integer argument +max+ given, + # calls the block with at most +max+ child elements: + # + # a.each_element_with_attribute('id', '1', 1) {|e| p e } + # + # Output: + # + # + # + # With all arguments given, including +xpath+, + # calls the block with only those child elements + # that meet the first three criteria, + # and also match the given +xpath+: + # + # a.each_element_with_attribute('id', '1', 2, '//d') {|e| p e } + # + # Output: + # + # + # + def each_element_with_attribute( key, value=nil, max=0, name=nil, &block ) # :yields: Element + each_with_something( proc {|child| + if value.nil? + child.attributes[key] != nil + else + child.attributes[key]==value + end + }, max, name, &block ) + end + + # :call-seq: + # each_element_with_text(text = nil, max = 0, xpath = nil) {|e| ... } + # + # Calls the given block with each child element that meets given criteria. + # + # With no arguments, calls the block with each child element that has text: + # + # d = REXML::Document.new 'bbd' + # a = d.root + # a.each_element_with_text {|e| p e } + # + # Output: + # + # ... + # ... + # ... + # + # With the single string argument +text+, + # calls the block with each element that has exactly that text: + # + # a.each_element_with_text('b') {|e| p e } + # + # Output: + # + # ... + # ... + # + # With argument +text+ and integer argument +max+, + # calls the block with at most +max+ elements: + # + # a.each_element_with_text('b', 1) {|e| p e } + # + # Output: + # + # ... + # + # With all arguments given, including +xpath+, + # calls the block with only those child elements + # that meet the first two criteria, + # and also match the given +xpath+: + # + # a.each_element_with_text('b', 2, '//c') {|e| p e } + # + # Output: + # + # ... + # + def each_element_with_text( text=nil, max=0, name=nil, &block ) # :yields: Element + each_with_something( proc {|child| + if text.nil? + child.has_text? + else + child.text == text + end + }, max, name, &block ) + end + + # :call-seq: + # each_element {|e| ... } + # + # Calls the given block with each child element: + # + # d = REXML::Document.new 'bbd' + # a = d.root + # a.each_element {|e| p e } + # + # Output: + # + # ... + # ... + # ... + # + # + def each_element( xpath=nil, &block ) # :yields: Element + @elements.each( xpath, &block ) + end + + # :call-seq: + # get_elements(xpath) + # + # Returns an array of the elements that match the given +xpath+: + # + # xml_string = <<-EOT + # + # + # + # + # + # EOT + # d = REXML::Document.new(xml_string) + # d.root.get_elements('//a') # => [ ... , ] + # + def get_elements( xpath ) + @elements.to_a( xpath ) + end + + # :call-seq: + # next_element + # + # Returns the next sibling that is an element if it exists, + # +niL+ otherwise: + # + # d = REXML::Document.new 'text' + # d.root.elements['b'].next_element #-> + # d.root.elements['c'].next_element #-> nil + # + def next_element + element = next_sibling + element = element.next_sibling until element.nil? or element.kind_of? Element + element + end + + # :call-seq: + # previous_element + # + # Returns the previous sibling that is an element if it exists, + # +niL+ otherwise: + # + # d = REXML::Document.new 'text' + # d.root.elements['c'].previous_element #-> + # d.root.elements['b'].previous_element #-> nil + # + def previous_element + element = previous_sibling + element = element.previous_sibling until element.nil? or element.kind_of? Element + element + end + + + ################################################# + # Text # + ################################################# + + # :call-seq: + # has_text? -> true or false + # + # Returns +true+ if the element has one or more text noded, + # +false+ otherwise: + # + # d = REXML::Document.new 'text' + # a = d.root + # a.has_text? # => true + # b = a[0] + # b.has_text? # => false + # + def has_text? + not text().nil? + end + + # :call-seq: + # text(xpath = nil) -> text_string or nil + # + # Returns the text string from the first text node child + # in a specified element, if it exists, +nil+ otherwise. + # + # With no argument, returns the text from the first text node in +self+: + # + # d = REXML::Document.new "

some text this is bold! more text

" + # d.root.text.class # => String + # d.root.text # => "some text " + # + # With argument +xpath+, returns text from the first text node + # in the element that matches +xpath+: + # + # d.root.text(1) # => "this is bold!" + # + # Note that an element may have multiple text nodes, + # possibly separated by other non-text children, as above. + # Even so, the returned value is the string text from the first such node. + # + # Note also that the text note is retrieved by method get_text, + # and so is always normalized text. + # + def text( path = nil ) + rv = get_text(path) + rv&.value + end + + # :call-seq: + # get_text(xpath = nil) -> text_node or nil + # + # Returns the first text node child in a specified element, if it exists, + # +nil+ otherwise. + # + # With no argument, returns the first text node from +self+: + # + # d = REXML::Document.new "

some text this is bold! more text

" + # d.root.get_text.class # => REXML::Text + # d.root.get_text # => "some text " + # + # With argument +xpath+, returns the first text node from the element + # that matches +xpath+: + # + # d.root.get_text(1) # => "this is bold!" + # + def get_text path = nil + rv = nil + if path + element = @elements[ path ] + rv = element.get_text unless element.nil? + else + rv = @children.find { |node| node.kind_of? Text } + end + rv + end + + # :call-seq: + # text = string -> string + # text = nil -> nil + # + # Adds, replaces, or removes the first text node child in the element. + # + # With string argument +string+, + # creates a new \REXML::Text node containing that string, + # honoring the current settings for whitespace and row, + # then places the node as the first text child in the element; + # returns +string+. + # + # If the element has no text child, the text node is added: + # + # d = REXML::Document.new '' + # d.root.text = 'foo' #-> 'foo' + # + # If the element has a text child, it is replaced: + # + # d.root.text = 'bar' #-> 'bar' + # + # With argument +nil+, removes the first text child: + # + # d.root.text = nil #-> '' + # + def text=( text ) + if text.kind_of? String + text = Text.new( text, whitespace(), nil, raw() ) + elsif !text.nil? and !text.kind_of? Text + text = Text.new( text.to_s, whitespace(), nil, raw() ) + end + old_text = get_text + if text.nil? + old_text.remove unless old_text.nil? + else + if old_text.nil? + self << text + else + old_text.replace_with( text ) + end + end + self + end + + # :call-seq: + # add_text(string) -> nil + # add_text(text_node) -> self + # + # Adds text to the element. + # + # When string argument +string+ is given, returns +nil+. + # + # If the element has no child text node, + # creates a \REXML::Text object using the string, + # honoring the current settings for whitespace and raw, + # then adds that node to the element: + # + # d = REXML::Document.new('') + # a = d.root + # a.add_text('foo') + # a.to_a # => [, "foo"] + # + # If the element has child text nodes, + # appends the string to the _last_ text node: + # + # d = REXML::Document.new('foobar') + # a = d.root + # a.add_text('baz') + # a.to_a # => ["foo", , "barbaz"] + # a.add_text('baz') + # a.to_a # => ["foo", , "barbazbaz"] + # + # When text node argument +text_node+ is given, + # appends the node as the last text node in the element; + # returns +self+: + # + # d = REXML::Document.new('foobar') + # a = d.root + # a.add_text(REXML::Text.new('baz')) + # a.to_a # => ["foo", , "bar", "baz"] + # a.add_text(REXML::Text.new('baz')) + # a.to_a # => ["foo", , "bar", "baz", "baz"] + # + def add_text( text ) + if text.kind_of? String + if @children[-1].kind_of? Text + @children[-1] << text + return + end + text = Text.new( text, whitespace(), nil, raw() ) + end + self << text unless text.nil? + self + end + + # :call-seq: + # node_type -> :element + # + # Returns symbol :element: + # + # d = REXML::Document.new('') + # a = d.root # => + # a.node_type # => :element + # + def node_type + :element + end + + # :call-seq: + # xpath -> string_xpath + # + # Returns the string xpath to the element + # relative to the most distant parent: + # + # d = REXML::Document.new('') + # a = d.root # => ... + # b = a[0] # => ... + # c = b[0] # => + # d.xpath # => "" + # a.xpath # => "/a" + # b.xpath # => "/a/b" + # c.xpath # => "/a/b/c" + # + # If there is no parent, returns the expanded name of the element: + # + # e = REXML::Element.new('foo') + # e.xpath # => "foo" + # + def xpath + path_elements = [] + cur = self + path_elements << __to_xpath_helper( self ) + while cur.parent + cur = cur.parent + path_elements << __to_xpath_helper( cur ) + end + path_elements.reverse.join( "/" ) + end + + ################################################# + # Attributes # + ################################################# + + # :call-seq: + # [index] -> object + # [attr_name] -> attr_value + # [attr_sym] -> attr_value + # + # With integer argument +index+ given, + # returns the child at offset +index+, or +nil+ if none: + # + # d = REXML::Document.new '>textmore
' + # root = d.root + # (0..root.size).each do |index| + # node = root[index] + # p "#{index}: #{node} (#{node.class})" + # end + # + # Output: + # + # "0: (REXML::Element)" + # "1: text (REXML::Text)" + # "2: (REXML::Element)" + # "3: more (REXML::Text)" + # "4: (REXML::Element)" + # "5: (NilClass)" + # + # With string argument +attr_name+ given, + # returns the string value for the given attribute name if it exists, + # otherwise +nil+: + # + # d = REXML::Document.new('') + # root = d.root + # root['attr'] # => "value" + # root['nosuch'] # => nil + # + # With symbol argument +attr_sym+ given, + # returns [attr_sym.to_s]: + # + # root[:attr] # => "value" + # root[:nosuch] # => nil + # + def [](name_or_index) + case name_or_index + when String + attributes[name_or_index] + when Symbol + attributes[name_or_index.to_s] + else + super + end + end + + + # :call-seq: + # attribute(name, namespace = nil) + # + # Returns the string value for the given attribute name. + # + # With only argument +name+ given, + # returns the value of the named attribute if it exists, otherwise +nil+: + # + # xml_string = <<-EOT + # + # + # + # + #
+ # EOT + # d = REXML::Document.new(xml_string) + # root = d.root + # a = root[1] # => + # a.attribute('attr') # => attr='value' + # a.attribute('nope') # => nil + # + # With arguments +name+ and +namespace+ given, + # returns the value of the named attribute if it exists, otherwise +nil+: + # + # xml_string = "" + # document = REXML::Document.new(xml_string) + # document.root.attribute("x") # => x='x' + # document.root.attribute("x", "a") # => a:x='a:x' + # + def attribute( name, namespace=nil ) + prefix = namespaces.key(namespace) if namespace + prefix = nil if prefix == 'xmlns' + + ret_val = + attributes.get_attribute( prefix ? "#{prefix}:#{name}" : name ) + + return ret_val unless ret_val.nil? + return nil if prefix.nil? + + # now check that prefix'es namespace is not the same as the + # default namespace + return nil unless ( namespaces[ prefix ] == namespaces[ 'xmlns' ] ) + + attributes.get_attribute( name ) + end + + # :call-seq: + # has_attributes? -> true or false + # + # Returns +true+ if the element has attributes, +false+ otherwise: + # + # d = REXML::Document.new('') + # a, b = *d.root + # a.has_attributes? # => true + # b.has_attributes? # => false + # + def has_attributes? + !@attributes.empty? + end + + # :call-seq: + # add_attribute(name, value) -> value + # add_attribute(attribute) -> attribute + # + # Adds an attribute to this element, overwriting any existing attribute + # by the same name. + # + # With string argument +name+ and object +value+ are given, + # adds the attribute created with that name and value: + # + # e = REXML::Element.new + # e.add_attribute('attr', 'value') # => "value" + # e['attr'] # => "value" + # e.add_attribute('attr', 'VALUE') # => "VALUE" + # e['attr'] # => "VALUE" + # + # With only attribute object +attribute+ given, + # adds the given attribute: + # + # a = REXML::Attribute.new('attr', 'value') + # e.add_attribute(a) # => attr='value' + # e['attr'] # => "value" + # a = REXML::Attribute.new('attr', 'VALUE') + # e.add_attribute(a) # => attr='VALUE' + # e['attr'] # => "VALUE" + # + def add_attribute( key, value=nil ) + if key.kind_of? Attribute + @attributes << key + else + @attributes[key] = value + end + end + + # :call-seq: + # add_attributes(hash) -> hash + # add_attributes(array) + # + # Adds zero or more attributes to the element; + # returns the argument. + # + # If hash argument +hash+ is given, + # each key must be a string; + # adds each attribute created with the key/value pair: + # + # e = REXML::Element.new + # h = {'foo' => 'bar', 'baz' => 'bat'} + # e.add_attributes(h) + # + # If argument +array+ is given, + # each array member must be a 2-element array [name, value]; + # each name must be a string: + # + # e = REXML::Element.new + # a = [['foo' => 'bar'], ['baz' => 'bat']] + # e.add_attributes(a) + # + def add_attributes hash + if hash.kind_of? Hash + hash.each_pair {|key, value| @attributes[key] = value } + elsif hash.kind_of? Array + hash.each { |value| @attributes[ value[0] ] = value[1] } + end + end + + # :call-seq: + # delete_attribute(name) -> removed_attribute or nil + # + # Removes a named attribute if it exists; + # returns the removed attribute if found, otherwise +nil+: + # + # e = REXML::Element.new('foo') + # e.add_attribute('bar', 'baz') + # e.delete_attribute('bar') # => + # e.delete_attribute('bar') # => nil + # + def delete_attribute(key) + attr = @attributes.get_attribute(key) + attr.remove unless attr.nil? + end + + ################################################# + # Other Utilities # + ################################################# + + # :call-seq: + # cdatas -> array_of_cdata_children + # + # Returns a frozen array of the REXML::CData children of the element: + # + # xml_string = <<-EOT + # + # + # + # + # EOT + # d = REXML::Document.new(xml_string) + # cds = d.root.cdatas # => ["foo", "bar"] + # cds.frozen? # => true + # cds.map {|cd| cd.class } # => [REXML::CData, REXML::CData] + # + def cdatas + find_all { |child| child.kind_of? CData }.freeze + end + + # :call-seq: + # comments -> array_of_comment_children + # + # Returns a frozen array of the REXML::Comment children of the element: + # + # xml_string = <<-EOT + # + # + # + # + # EOT + # d = REXML::Document.new(xml_string) + # cs = d.root.comments + # cs.frozen? # => true + # cs.map {|c| c.class } # => [REXML::Comment, REXML::Comment] + # cs.map {|c| c.to_s } # => ["foo", "bar"] + # + def comments + find_all { |child| child.kind_of? Comment }.freeze + end + + # :call-seq: + # instructions -> array_of_instruction_children + # + # Returns a frozen array of the REXML::Instruction children of the element: + # + # xml_string = <<-EOT + # + # + # + # + # EOT + # d = REXML::Document.new(xml_string) + # is = d.root.instructions + # is.frozen? # => true + # is.map {|i| i.class } # => [REXML::Instruction, REXML::Instruction] + # is.map {|i| i.to_s } # => ["", ""] + # + def instructions + find_all { |child| child.kind_of? Instruction }.freeze + end + + # :call-seq: + # texts -> array_of_text_children + # + # Returns a frozen array of the REXML::Text children of the element: + # + # xml_string = 'textmore' + # d = REXML::Document.new(xml_string) + # ts = d.root.texts + # ts.frozen? # => true + # ts.map {|t| t.class } # => [REXML::Text, REXML::Text] + # ts.map {|t| t.to_s } # => ["text", "more"] + # + def texts + find_all { |child| child.kind_of? Text }.freeze + end + + # == DEPRECATED + # See REXML::Formatters + # + # Writes out this element, and recursively, all children. + # output:: + # output an object which supports '<< string'; this is where the + # document will be written. + # indent:: + # An integer. If -1, no indenting will be used; otherwise, the + # indentation will be this number of spaces, and children will be + # indented an additional amount. Defaults to -1 + # transitive:: + # If transitive is true and indent is >= 0, then the output will be + # pretty-printed in such a way that the added whitespace does not affect + # the parse tree of the document + # ie_hack:: + # This hack inserts a space before the /> on empty tags to address + # a limitation of Internet Explorer. Defaults to false + # + # out = '' + # doc.write( out ) #-> doc is written to the string 'out' + # doc.write( $stdout ) #-> doc written to the console + def write(output=$stdout, indent=-1, transitive=false, ie_hack=false) + Kernel.warn("#{self.class.name}#write is deprecated. See REXML::Formatters", uplevel: 1) + formatter = if indent > -1 + if transitive + require_relative "formatters/transitive" + REXML::Formatters::Transitive.new( indent, ie_hack ) + else + REXML::Formatters::Pretty.new( indent, ie_hack ) + end + else + REXML::Formatters::Default.new( ie_hack ) + end + formatter.write( self, output ) + end + + private + def calculate_namespaces + if parent + parent.namespaces.merge(attributes.namespaces) + else + attributes.namespaces + end + end + + def __to_xpath_helper node + rv = node.expanded_name.clone + if node.parent + results = node.parent.find_all {|n| + n.kind_of?(REXML::Element) and n.expanded_name == node.expanded_name + } + if results.length > 1 + idx = results.index( node ) + rv << "[#{idx+1}]" + end + end + rv + end + + # A private helper method + def each_with_something( test, max=0, name=nil ) + num = 0 + @elements.each( name ){ |child| + yield child if test.call(child) and num += 1 + return if max>0 and num == max + } + end + end + + ######################################################################## + # ELEMENTS # + ######################################################################## + + # A class which provides filtering of children for Elements, and + # XPath search support. You are expected to only encounter this class as + # the element.elements object. Therefore, you are + # _not_ expected to instantiate this yourself. + # + # xml_string = <<-EOT + # + # + # + # Everyday Italian + # Giada De Laurentiis + # 2005 + # 30.00 + # + # + # Harry Potter + # J K. Rowling + # 2005 + # 29.99 + # + # + # XQuery Kick Start + # James McGovern + # Per Bothner + # Kurt Cagle + # James Linn + # Vaidyanathan Nagarajan + # 2003 + # 49.99 + # + # + # Learning XML + # Erik T. Ray + # 2003 + # 39.95 + # + # + # EOT + # d = REXML::Document.new(xml_string) + # elements = d.root.elements + # elements # => # ... > + # + class Elements + include Enumerable + # :call-seq: + # new(parent) -> new_elements_object + # + # Returns a new \Elements object with the given +parent+. + # Does _not_ assign parent.elements = self: + # + # d = REXML::Document.new(xml_string) + # eles = REXML::Elements.new(d.root) + # eles # => # ... > + # eles == d.root.elements # => false + # + def initialize parent + @element = parent + end + + # :call-seq: + # parent + # + # Returns the parent element cited in creating the \Elements object. + # This element is also the default starting point for searching + # in the \Elements object. + # + # d = REXML::Document.new(xml_string) + # elements = REXML::Elements.new(d.root) + # elements.parent == d.root # => true + # + def parent + @element + end + + # :call-seq: + # elements[index] -> element or nil + # elements[xpath] -> element or nil + # elements[n, name] -> element or nil + # + # Returns the first \Element object selected by the arguments, + # if any found, or +nil+ if none found. + # + # Notes: + # - The +index+ is 1-based, not 0-based, so that: + # - The first element has index 1 + # - The _nth_ element has index +n+. + # - The selection ignores non-\Element nodes. + # + # When the single argument +index+ is given, + # returns the element given by the index, if any; otherwise, +nil+: + # + # d = REXML::Document.new(xml_string) + # eles = d.root.elements + # eles # => # ... > + # eles[1] # => ... + # eles.size # => 4 + # eles[4] # => ... + # eles[5] # => nil + # + # The node at this index is not an \Element, and so is not returned: + # + # eles = d.root.first.first # => ... </> + # eles.to_a # => ["Everyday Italian"] + # eles[1] # => nil + # + # When the single argument +xpath+ is given, + # returns the first element found via that +xpath+, if any; otherwise, +nil+: + # + # eles = d.root.elements # => #<REXML::Elements @element=<bookstore> ... </>> + # eles['/bookstore'] # => <bookstore> ... </> + # eles['//book'] # => <book category='cooking'> ... </> + # eles['//book [@category="children"]'] # => <book category='children'> ... </> + # eles['/nosuch'] # => nil + # eles['//nosuch'] # => nil + # eles['//book [@category="nosuch"]'] # => nil + # eles['.'] # => <bookstore> ... </> + # eles['..'].class # => REXML::Document + # + # With arguments +n+ and +name+ given, + # returns the _nth_ found element that has the given +name+, + # or +nil+ if there is no such _nth_ element: + # + # eles = d.root.elements # => #<REXML::Elements @element=<bookstore> ... </>> + # eles[1, 'book'] # => <book category='cooking'> ... </> + # eles[4, 'book'] # => <book category='web' cover='paperback'> ... </> + # eles[5, 'book'] # => nil + # + def []( index, name=nil) + if index.kind_of? Integer + raise "index (#{index}) must be >= 1" if index < 1 + name = literalize(name) if name + num = 0 + @element.find { |child| + child.kind_of? Element and + (name.nil? ? true : child.has_name?( name )) and + (num += 1) == index + } + else + XPath::first( @element, index ) + end + end + + # :call-seq: + # elements[] = index, replacement_element -> replacement_element or nil + # + # Replaces or adds an element. + # + # When <tt>eles[index]</tt> exists, replaces it with +replacement_element+ + # and returns +replacement_element+: + # + # d = REXML::Document.new(xml_string) + # eles = d.root.elements # => #<REXML::Elements @element=<bookstore> ... </>> + # eles[1] # => <book category='cooking'> ... </> + # eles[1] = REXML::Element.new('foo') + # eles[1] # => <foo/> + # + # Does nothing (or raises an exception) + # if +replacement_element+ is not an \Element: + # eles[2] # => <book category='web' cover='paperback'> ... </> + # eles[2] = REXML::Text.new('bar') + # eles[2] # => <book category='web' cover='paperback'> ... </> + # + # When <tt>eles[index]</tt> does not exist, + # adds +replacement_element+ to the element and returns + # + # d = REXML::Document.new(xml_string) + # eles = d.root.elements # => #<REXML::Elements @element=<bookstore> ... </>> + # eles.size # => 4 + # eles[50] = REXML::Element.new('foo') # => <foo/> + # eles.size # => 5 + # eles[5] # => <foo/> + # + # Does nothing (or raises an exception) + # if +replacement_element+ is not an \Element: + # + # eles[50] = REXML::Text.new('bar') # => "bar" + # eles.size # => 5 + # + def []=( index, element ) + previous = self[index] + if previous.nil? + @element.add element + else + previous.replace_with element + end + previous + end + + # :call-seq: + # empty? -> true or false + # + # Returns +true+ if there are no children, +false+ otherwise. + # + # d = REXML::Document.new('') + # d.elements.empty? # => true + # d = REXML::Document.new(xml_string) + # d.elements.empty? # => false + # + def empty? + @element.find{ |child| child.kind_of? Element}.nil? + end + + # :call-seq: + # index(element) + # + # Returns the 1-based index of the given +element+, if found; + # otherwise, returns -1: + # + # d = REXML::Document.new(xml_string) + # elements = d.root.elements + # ele_1, ele_2, ele_3, ele_4 = *elements + # elements.index(ele_4) # => 4 + # elements.delete(ele_3) + # elements.index(ele_4) # => 3 + # elements.index(ele_3) # => -1 + # + def index element + rv = 0 + found = @element.find do |child| + child.kind_of? Element and + (rv += 1) and + child == element + end + return rv if found == element + -1 + end + + # :call-seq: + # delete(index) -> removed_element or nil + # delete(element) -> removed_element or nil + # delete(xpath) -> removed_element or nil + # + # Removes an element; returns the removed element, or +nil+ if none removed. + # + # With integer argument +index+ given, + # removes the child element at that offset: + # + # d = REXML::Document.new(xml_string) + # elements = d.root.elements + # elements.size # => 4 + # elements[2] # => <book category='children'> ... </> + # elements.delete(2) # => <book category='children'> ... </> + # elements.size # => 3 + # elements[2] # => <book category='web'> ... </> + # elements.delete(50) # => nil + # + # With element argument +element+ given, + # removes that child element: + # + # d = REXML::Document.new(xml_string) + # elements = d.root.elements + # ele_1, ele_2, ele_3, ele_4 = *elements + # elements.size # => 4 + # elements[2] # => <book category='children'> ... </> + # elements.delete(ele_2) # => <book category='children'> ... </> + # elements.size # => 3 + # elements[2] # => <book category='web'> ... </> + # elements.delete(ele_2) # => nil + # + # With string argument +xpath+ given, + # removes the first element found via that xpath: + # + # d = REXML::Document.new(xml_string) + # elements = d.root.elements + # elements.delete('//book') # => <book category='cooking'> ... </> + # elements.delete('//book [@category="children"]') # => <book category='children'> ... </> + # elements.delete('//nosuch') # => nil + # + def delete element + if element.kind_of? Element + @element.delete element + else + el = self[element] + el.remove if el + end + end + + # :call-seq: + # delete_all(xpath) + # + # Removes all elements found via the given +xpath+; + # returns the array of removed elements, if any, else +nil+. + # + # d = REXML::Document.new(xml_string) + # elements = d.root.elements + # elements.size # => 4 + # deleted_elements = elements.delete_all('//book [@category="web"]') + # deleted_elements.size # => 2 + # elements.size # => 2 + # deleted_elements = elements.delete_all('//book') + # deleted_elements.size # => 2 + # elements.size # => 0 + # elements.delete_all('//book') # => [] + # + def delete_all( xpath ) + rv = [] + XPath::each( @element, xpath) {|element| + rv << element if element.kind_of? Element + } + rv.each do |element| + @element.delete element + element.remove + end + rv + end + + # :call-seq: + # add -> new_element + # add(name) -> new_element + # add(element) -> element + # + # Adds an element; returns the element added. + # + # With no argument, creates and adds a new element. + # The new element has: + # + # - No name. + # - \Parent from the \Elements object. + # - Context from the that parent. + # + # Example: + # + # d = REXML::Document.new(xml_string) + # elements = d.root.elements + # parent = elements.parent # => <bookstore> ... </> + # parent.context = {raw: :all} + # elements.size # => 4 + # new_element = elements.add # => </> + # elements.size # => 5 + # new_element.name # => nil + # new_element.parent # => <bookstore> ... </> + # new_element.context # => {:raw=>:all} + # + # With string argument +name+, creates and adds a new element. + # The new element has: + # + # - Name +name+. + # - \Parent from the \Elements object. + # - Context from the that parent. + # + # Example: + # + # d = REXML::Document.new(xml_string) + # elements = d.root.elements + # parent = elements.parent # => <bookstore> ... </> + # parent.context = {raw: :all} + # elements.size # => 4 + # new_element = elements.add('foo') # => <foo/> + # elements.size # => 5 + # new_element.name # => "foo" + # new_element.parent # => <bookstore> ... </> + # new_element.context # => {:raw=>:all} + # + # With argument +element+, + # creates and adds a clone of the given +element+. + # The new element has name, parent, and context from the given +element+. + # + # d = REXML::Document.new(xml_string) + # elements = d.root.elements + # elements.size # => 4 + # e0 = REXML::Element.new('foo') + # e1 = REXML::Element.new('bar', e0, {raw: :all}) + # element = elements.add(e1) # => <bar/> + # elements.size # => 5 + # element.name # => "bar" + # element.parent # => <bookstore> ... </> + # element.context # => {:raw=>:all} + # + def add element=nil + if element.nil? + Element.new("", self, @element.context) + elsif not element.kind_of?(Element) + Element.new(element, self, @element.context) + else + @element << element + element.context = @element.context + element + end + end + + alias :<< :add + + # :call-seq: + # each(xpath = nil) {|element| ... } -> self + # + # Iterates over the elements. + # + # With no argument, calls the block with each element: + # + # d = REXML::Document.new(xml_string) + # elements = d.root.elements + # elements.each {|element| p element } + # + # Output: + # + # <book category='cooking'> ... </> + # <book category='children'> ... </> + # <book category='web'> ... </> + # <book category='web' cover='paperback'> ... </> + # + # With argument +xpath+, calls the block with each element + # that matches the given +xpath+: + # + # elements.each('//book [@category="web"]') {|element| p element } + # + # Output: + # + # <book category='web'> ... </> + # <book category='web' cover='paperback'> ... </> + # + def each( xpath=nil ) + XPath::each( @element, xpath ) {|e| yield e if e.kind_of? Element } + end + + # :call-seq: + # collect(xpath = nil) {|element| ... } -> array + # + # Iterates over the elements; returns the array of block return values. + # + # With no argument, iterates over all elements: + # + # d = REXML::Document.new(xml_string) + # elements = d.root.elements + # elements.collect {|element| element.size } # => [9, 9, 17, 9] + # + # With argument +xpath+, iterates over elements that match + # the given +xpath+: + # + # xpath = '//book [@category="web"]' + # elements.collect(xpath) {|element| element.size } # => [17, 9] + # + def collect( xpath=nil ) + collection = [] + XPath::each( @element, xpath ) {|e| + collection << yield(e) if e.kind_of?(Element) + } + collection + end + + # :call-seq: + # inject(xpath = nil, initial = nil) -> object + # + # Calls the block with elements; returns the last block return value. + # + # With no argument, iterates over the elements, calling the block + # <tt>elements.size - 1</tt> times. + # + # - The first call passes the first and second elements. + # - The second call passes the first block return value and the third element. + # - The third call passes the second block return value and the fourth element. + # - And so on. + # + # In this example, the block returns the passed element, + # which is then the object argument to the next call: + # + # d = REXML::Document.new(xml_string) + # elements = d.root.elements + # elements.inject do |object, element| + # p [elements.index(object), elements.index(element)] + # element + # end + # + # Output: + # + # [1, 2] + # [2, 3] + # [3, 4] + # + # With the single argument +xpath+, calls the block only with + # elements matching that xpath: + # + # elements.inject('//book [@category="web"]') do |object, element| + # p [elements.index(object), elements.index(element)] + # element + # end + # + # Output: + # + # [3, 4] + # + # With argument +xpath+ given as +nil+ + # and argument +initial+ also given, + # calls the block once for each element. + # + # - The first call passes the +initial+ and the first element. + # - The second call passes the first block return value and the second element. + # - The third call passes the second block return value and the third element. + # - And so on. + # + # In this example, the first object index is <tt>-1</tt> + # + # elements.inject(nil, 'Initial') do |object, element| + # p [elements.index(object), elements.index(element)] + # element + # end + # + # Output: + # + # [-1, 1] + # [1, 2] + # [2, 3] + # [3, 4] + # + # In this form the passed object can be used as an accumulator: + # + # elements.inject(nil, 0) do |total, element| + # total += element.size + # end # => 44 + # + # With both arguments +xpath+ and +initial+ are given, + # calls the block only with elements matching that xpath: + # + # elements.inject('//book [@category="web"]', 0) do |total, element| + # total += element.size + # end # => 26 + # + def inject( xpath=nil, initial=nil ) + first = true + XPath::each( @element, xpath ) {|e| + if (e.kind_of? Element) + if (first and initial == nil) + initial = e + first = false + else + initial = yield( initial, e ) if e.kind_of? Element + end + end + } + initial + end + + # :call-seq: + # size -> integer + # + # Returns the count of \Element children: + # + # d = REXML::Document.new '<a>sean<b/>elliott<b/>russell<b/></a>' + # d.root.elements.size # => 3 # Three elements. + # d.root.size # => 6 # Three elements plus three text nodes.. + # + def size + count = 0 + @element.each {|child| count+=1 if child.kind_of? Element } + count + end + + # :call-seq: + # to_a(xpath = nil) -> array_of_elements + # + # Returns an array of element children (not including non-element children). + # + # With no argument, returns an array of all element children: + # + # d = REXML::Document.new '<a>sean<b/>elliott<c/></a>' + # elements = d.root.elements + # elements.to_a # => [<b/>, <c/>] # Omits non-element children. + # children = d.root.children + # children # => ["sean", <b/>, "elliott", <c/>] # Includes non-element children. + # + # With argument +xpath+, returns an array of element children + # that match the xpath: + # + # elements.to_a('//c') # => [<c/>] + # + def to_a( xpath=nil ) + rv = XPath.match( @element, xpath ) + return rv.find_all{|e| e.kind_of? Element} if xpath + rv + end + + private + # Private helper class. Removes quotes from quoted strings + def literalize name + name = name[1..-2] if name[0] == ?' or name[0] == ?" #' + name + end + end + + ######################################################################## + # ATTRIBUTES # + ######################################################################## + + # A class that defines the set of Attributes of an Element and provides + # operations for accessing elements in that set. + class Attributes < Hash + + # :call-seq: + # new(element) + # + # Creates and returns a new \REXML::Attributes object. + # The element given by argument +element+ is stored, + # but its own attributes are not modified: + # + # ele = REXML::Element.new('foo') + # attrs = REXML::Attributes.new(ele) + # attrs.object_id == ele.attributes.object_id # => false + # + # Other instance methods in class \REXML::Attributes may refer to: + # + # - +element.document+. + # - +element.prefix+. + # - +element.expanded_name+. + # + def initialize element + @element = element + end + + # :call-seq: + # [name] -> attribute_value or nil + # + # Returns the value for the attribute given by +name+, + # if it exists; otherwise +nil+. + # The value returned is the unnormalized attribute value, + # with entities expanded: + # + # xml_string = <<-EOT + # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> + # <ele foo:att='1' bar:att='2' att='<'/> + # </root> + # EOT + # d = REXML::Document.new(xml_string) + # ele = d.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> + # ele.attributes['att'] # => "<" + # ele.attributes['bar:att'] # => "2" + # ele.attributes['nosuch'] # => nil + # + # Related: get_attribute (returns an \Attribute object). + # + def [](name) + attr = get_attribute(name) + attr&.value + end + + # :call-seq: + # to_a -> array_of_attribute_objects + # + # Returns an array of \REXML::Attribute objects representing + # the attributes: + # + # xml_string = <<-EOT + # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> + # <ele foo:att='1' bar:att='2' att='<'/> + # </root> + # EOT + # d = REXML::Document.new(xml_string) + # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> + # attrs = ele.attributes.to_a # => [foo:att='1', bar:att='2', att='<'] + # attrs.first.class # => REXML::Attribute + # + def to_a + enum_for(:each_attribute).to_a + end + + # :call-seq: + # length + # + # Returns the count of attributes: + # + # xml_string = <<-EOT + # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> + # <ele foo:att='1' bar:att='2' att='<'/> + # </root> + # EOT + # d = REXML::Document.new(xml_string) + # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> + # ele.attributes.length # => 3 + # + def length + c = 0 + each_attribute { c+=1 } + c + end + alias :size :length + + # :call-seq: + # each_attribute {|attr| ... } + # + # Calls the given block with each \REXML::Attribute object: + # + # xml_string = <<-EOT + # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> + # <ele foo:att='1' bar:att='2' att='<'/> + # </root> + # EOT + # d = REXML::Document.new(xml_string) + # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> + # ele.attributes.each_attribute do |attr| + # p [attr.class, attr] + # end + # + # Output: + # + # [REXML::Attribute, foo:att='1'] + # [REXML::Attribute, bar:att='2'] + # [REXML::Attribute, att='<'] + # + def each_attribute # :yields: attribute + return to_enum(__method__) unless block_given? + each_value do |val| + if val.kind_of? Attribute + yield val + else + val.each_value { |atr| yield atr } + end + end + end + + # :call-seq: + # each {|expanded_name, value| ... } + # + # Calls the given block with each expanded-name/value pair: + # + # xml_string = <<-EOT + # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> + # <ele foo:att='1' bar:att='2' att='<'/> + # </root> + # EOT + # d = REXML::Document.new(xml_string) + # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> + # ele.attributes.each do |expanded_name, value| + # p [expanded_name, value] + # end + # + # Output: + # + # ["foo:att", "1"] + # ["bar:att", "2"] + # ["att", "<"] + # + def each + return to_enum(__method__) unless block_given? + each_attribute do |attr| + yield [attr.expanded_name, attr.value] + end + end + + # :call-seq: + # get_attribute(name) -> attribute_object or nil + # + # Returns the \REXML::Attribute object for the given +name+: + # + # xml_string = <<-EOT + # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> + # <ele foo:att='1' bar:att='2' att='<'/> + # </root> + # EOT + # d = REXML::Document.new(xml_string) + # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> + # attrs = ele.attributes + # attrs.get_attribute('foo:att') # => foo:att='1' + # attrs.get_attribute('foo:att').class # => REXML::Attribute + # attrs.get_attribute('bar:att') # => bar:att='2' + # attrs.get_attribute('att') # => att='<' + # attrs.get_attribute('nosuch') # => nil + # + def get_attribute( name ) + attr = fetch( name, nil ) + if attr.nil? + return nil if name.nil? + # Look for prefix + name =~ Namespace::NAMESPLIT + prefix, n = $1, $2 + if prefix + attr = fetch( n, nil ) + # check prefix + if attr == nil + elsif attr.kind_of? Attribute + return attr if prefix == attr.prefix + else + attr = attr[ prefix ] + return attr + end + end + doctype = @element.document&.doctype + if doctype + expn = @element.expanded_name + expn = doctype.name if expn.size == 0 + attr_val = doctype.attribute_of(expn, name) + return Attribute.new( name, attr_val ) if attr_val + end + return nil + end + if attr.kind_of? Hash + attr = attr[ @element.prefix ] + end + attr + end + + # :call-seq: + # [name] = value -> value + # + # When +value+ is non-+nil+, + # assigns that to the attribute for the given +name+, + # overwriting the previous value if it exists: + # + # xml_string = <<-EOT + # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> + # <ele foo:att='1' bar:att='2' att='<'/> + # </root> + # EOT + # d = REXML::Document.new(xml_string) + # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> + # attrs = ele.attributes + # attrs['foo:att'] = '2' # => "2" + # attrs['baz:att'] = '3' # => "3" + # + # When +value+ is +nil+, deletes the attribute if it exists: + # + # attrs['baz:att'] = nil + # attrs.include?('baz:att') # => false + # + def []=( name, value ) + if value.nil? # Delete the named attribute + attr = get_attribute(name) + delete attr + return + end + + unless value.kind_of? Attribute + doctype = @element.document&.doctype + if doctype + value = Text::normalize( value, doctype ) + else + value = Text::normalize( value, nil ) + end + value = Attribute.new(name, value) + end + value.element = @element + old_attr = fetch(value.name, nil) + if old_attr.nil? + store(value.name, value) + elsif old_attr.kind_of? Hash + old_attr[value.prefix] = value + elsif old_attr.prefix != value.prefix + store value.name, {old_attr.prefix => old_attr, + value.prefix => value} + else + store value.name, value + end + @element + end + + # :call-seq: + # prefixes -> array_of_prefix_strings + # + # Returns an array of prefix strings in the attributes. + # The array does not include the default + # namespace declaration, if one exists. + # + # xml_string = '<a xmlns="foo" xmlns:x="bar" xmlns:y="twee" z="glorp"/>' + # d = REXML::Document.new(xml_string) + # d.root.attributes.prefixes # => ["x", "y"] + # + def prefixes + ns = [] + each_attribute do |attribute| + ns << attribute.name if attribute.prefix == 'xmlns' + end + doctype = @element.document&.doctype + if doctype + expn = @element.expanded_name + expn = doctype.name if expn.size == 0 + doctype.attributes_of(expn).each { + |attribute| + ns << attribute.name if attribute.prefix == 'xmlns' + } + end + ns + end + + # :call-seq: + # namespaces + # + # Returns a hash of name/value pairs for the namespaces: + # + # xml_string = '<a xmlns="foo" xmlns:x="bar" xmlns:y="twee" z="glorp"/>' + # d = REXML::Document.new(xml_string) + # d.root.attributes.namespaces # => {"xmlns"=>"foo", "x"=>"bar", "y"=>"twee"} + # + def namespaces + namespaces = {} + each_attribute do |attribute| + namespaces[attribute.name] = attribute.value if attribute.prefix == 'xmlns' or attribute.name == 'xmlns' + end + doctype = @element.document&.doctype + if doctype + expn = @element.expanded_name + expn = doctype.name if expn.size == 0 + doctype.attributes_of(expn).each { + |attribute| + namespaces[attribute.name] = attribute.value if attribute.prefix == 'xmlns' or attribute.name == 'xmlns' + } + end + namespaces + end + + # :call-seq: + # delete(name) -> element + # delete(attribute) -> element + # + # Removes a specified attribute if it exists; + # returns the attributes' element. + # + # When string argument +name+ is given, + # removes the attribute of that name if it exists: + # + # xml_string = <<-EOT + # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> + # <ele foo:att='1' bar:att='2' att='<'/> + # </root> + # EOT + # d = REXML::Document.new(xml_string) + # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> + # attrs = ele.attributes + # attrs.delete('foo:att') # => <ele bar:att='2' att='<'/> + # attrs.delete('foo:att') # => <ele bar:att='2' att='<'/> + # + # When attribute argument +attribute+ is given, + # removes that attribute if it exists: + # + # attr = REXML::Attribute.new('bar:att', '2') + # attrs.delete(attr) # => <ele att='<'/> # => <ele att='<'/> + # attrs.delete(attr) # => <ele att='<'/> # => <ele/> + # + def delete( attribute ) + name = nil + prefix = nil + if attribute.kind_of? Attribute + name = attribute.name + prefix = attribute.prefix + else + attribute =~ Namespace::NAMESPLIT + prefix, name = $1, $2 + prefix = '' unless prefix + end + old = fetch(name, nil) + if old.kind_of? Hash # the supplied attribute is one of many + old.delete(prefix) + if old.size == 1 + repl = nil + old.each_value{|v| repl = v} + store name, repl + end + elsif old # the supplied attribute is a top-level one + super(name) + end + @element + end + + # :call-seq: + # add(attribute) -> attribute + # + # Adds attribute +attribute+, replacing the previous + # attribute of the same name if it exists; + # returns +attribute+: + # + # xml_string = <<-EOT + # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> + # <ele foo:att='1' bar:att='2' att='<'/> + # </root> + # EOT + # d = REXML::Document.new(xml_string) + # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> + # attrs = ele.attributes + # attrs # => {"att"=>{"foo"=>foo:att='1', "bar"=>bar:att='2', ""=>att='<'}} + # attrs.add(REXML::Attribute.new('foo:att', '2')) # => foo:att='2' + # attrs.add(REXML::Attribute.new('baz', '3')) # => baz='3' + # attrs.include?('baz') # => true + # + def add( attribute ) + self[attribute.name] = attribute + end + + alias :<< :add + + # :call-seq: + # delete_all(name) -> array_of_removed_attributes + # + # Removes all attributes matching the given +name+; + # returns an array of the removed attributes: + # + # xml_string = <<-EOT + # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> + # <ele foo:att='1' bar:att='2' att='<'/> + # </root> + # EOT + # d = REXML::Document.new(xml_string) + # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> + # attrs = ele.attributes + # attrs.delete_all('att') # => [att='<'] + # + def delete_all( name ) + rv = [] + each_attribute { |attribute| + rv << attribute if attribute.expanded_name == name + } + rv.each{ |attr| attr.remove } + rv + end + + # :call-seq: + # get_attribute_ns(namespace, name) + # + # Returns the \REXML::Attribute object among the attributes + # that matches the given +namespace+ and +name+: + # + # xml_string = <<-EOT + # <root xmlns:foo="http://foo" xmlns:bar="http://bar"> + # <ele foo:att='1' bar:att='2' att='<'/> + # </root> + # EOT + # d = REXML::Document.new(xml_string) + # ele = d.root.elements['//ele'] # => <a foo:att='1' bar:att='2' att='<'/> + # attrs = ele.attributes + # attrs.get_attribute_ns('http://foo', 'att') # => foo:att='1' + # attrs.get_attribute_ns('http://foo', 'nosuch') # => nil + # + def get_attribute_ns(namespace, name) + result = nil + each_attribute() { |attribute| + if name == attribute.name && + namespace == attribute.namespace() && + ( !namespace.empty? || !attribute.fully_expanded_name.index(':') ) + # foo will match xmlns:foo, but only if foo isn't also an attribute + result = attribute if !result or !namespace.empty? or + !attribute.fully_expanded_name.index(':') + end + } + result + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/encoding.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/encoding.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/encoding.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/encoding.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,48 @@ +# coding: US-ASCII +# frozen_string_literal: false +module REXML + module Encoding + # ID ---> Encoding name + attr_reader :encoding + def encoding=(encoding) + encoding = encoding.name if encoding.is_a?(::Encoding) + if encoding.is_a?(String) + original_encoding = encoding + encoding = find_encoding(encoding) + unless encoding + raise ArgumentError, "Bad encoding name #{original_encoding}" + end + end + encoding = encoding.upcase if encoding + return false if defined?(@encoding) and encoding == @encoding + @encoding = encoding || "UTF-8" + true + end + + def encode(string) + string.encode(@encoding) + end + + def decode(string) + string.encode(::Encoding::UTF_8, @encoding) + end + + private + def find_encoding(name) + case name + when /\Ashift-jis\z/i + return "SHIFT_JIS" + when /\ACP-(\d+)\z/ + name = "CP#{$1}" + when /\AUTF-8\z/i + return name + end + begin + ::Encoding::Converter.search_convpath(name, 'UTF-8') + rescue ::Encoding::ConverterNotFoundError + return nil + end + name + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/entity.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/entity.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/entity.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/entity.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,142 @@ +# frozen_string_literal: false +require_relative 'child' +require_relative 'source' +require_relative 'xmltokens' + +module REXML + class Entity < Child + include XMLTokens + PUBIDCHAR = "\x20\x0D\x0Aa-zA-Z0-9\\-()+,./:=?;!*@$_%#" + SYSTEMLITERAL = %Q{((?:"[^"]*")|(?:'[^']*'))} + PUBIDLITERAL = %Q{("[#{PUBIDCHAR}']*"|'[#{PUBIDCHAR}]*')} + EXTERNALID = "(?:(?:(SYSTEM)\\s+#{SYSTEMLITERAL})|(?:(PUBLIC)\\s+#{PUBIDLITERAL}\\s+#{SYSTEMLITERAL}))" + NDATADECL = "\\s+NDATA\\s+#{NAME}" + PEREFERENCE = "%#{NAME};" + PEREFERENCE_RE = /#{PEREFERENCE}/um + ENTITYVALUE = %Q{((?:"(?:[^%&"]|#{PEREFERENCE}|#{REFERENCE})*")|(?:'([^%&']|#{PEREFERENCE}|#{REFERENCE})*'))} + PEDEF = "(?:#{ENTITYVALUE}|#{EXTERNALID})" + ENTITYDEF = "(?:#{ENTITYVALUE}|(?:#{EXTERNALID}(#{NDATADECL})?))" + PEDECL = "<!ENTITY\\s+(%)\\s+#{NAME}\\s+#{PEDEF}\\s*>" + GEDECL = "<!ENTITY\\s+#{NAME}\\s+#{ENTITYDEF}\\s*>" + ENTITYDECL = /\s*(?:#{GEDECL})|(?:#{PEDECL})/um + + attr_reader :name, :external, :ref, :ndata, :pubid, :value + + # Create a new entity. Simple entities can be constructed by passing a + # name, value to the constructor; this creates a generic, plain entity + # reference. For anything more complicated, you have to pass a Source to + # the constructor with the entity definition, or use the accessor methods. + # +WARNING+: There is no validation of entity state except when the entity + # is read from a stream. If you start poking around with the accessors, + # you can easily create a non-conformant Entity. + # + # e = Entity.new( 'amp', '&' ) + def initialize stream, value=nil, parent=nil, reference=false + super(parent) + @ndata = @pubid = @value = @external = nil + if stream.kind_of? Array + @name = stream[1] + if stream[-1] == '%' + @reference = true + stream.pop + else + @reference = false + end + if stream[2] =~ /SYSTEM|PUBLIC/ + @external = stream[2] + if @external == 'SYSTEM' + @ref = stream[3] + @ndata = stream[4] if stream.size == 5 + else + @pubid = stream[3] + @ref = stream[4] + end + else + @value = stream[2] + end + else + @reference = reference + @external = nil + @name = stream + @value = value + end + end + + # Evaluates whether the given string matches an entity definition, + # returning true if so, and false otherwise. + def Entity::matches? string + (ENTITYDECL =~ string) == 0 + end + + # Evaluates to the unnormalized value of this entity; that is, replacing + # &ent; entities. + def unnormalized + document&.record_entity_expansion + + return nil if @value.nil? + + @unnormalized = Text::unnormalize(@value, parent, + entity_expansion_text_limit: document&.entity_expansion_text_limit) + end + + #once :unnormalized + + # Returns the value of this entity unprocessed -- raw. This is the + # normalized value; that is, with all %ent; and &ent; entities intact + def normalized + @value + end + + # Write out a fully formed, correct entity definition (assuming the Entity + # object itself is valid.) + # + # out:: + # An object implementing <TT><<</TT> to which the entity will be + # output + # indent:: + # *DEPRECATED* and ignored + def write out, indent=-1 + out << '<!ENTITY ' + out << '% ' if @reference + out << @name + out << ' ' + if @external + out << @external << ' ' + if @pubid + q = @pubid.include?('"')?"'":'"' + out << q << @pubid << q << ' ' + end + q = @ref.include?('"')?"'":'"' + out << q << @ref << q + out << ' NDATA ' << @ndata if @ndata + else + q = @value.include?('"')?"'":'"' + out << q << @value << q + end + out << '>' + end + + # Returns this entity as a string. See write(). + def to_s + rv = '' + write rv + rv + end + end + + # This is a set of entity constants -- the ones defined in the XML + # specification. These are +gt+, +lt+, +amp+, +quot+ and +apos+. + # CAUTION: these entities does not have parent and document + module EntityConst + # +>+ + GT = Entity.new( 'gt', '>' ) + # +<+ + LT = Entity.new( 'lt', '<' ) + # +&+ + AMP = Entity.new( 'amp', '&' ) + # +"+ + QUOT = Entity.new( 'quot', '"' ) + # +'+ + APOS = Entity.new( 'apos', "'" ) + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/formatters/default.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/formatters/default.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/formatters/default.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/formatters/default.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,116 @@ +# frozen_string_literal: false + +module REXML + module Formatters + class Default + # Prints out the XML document with no formatting -- except if ie_hack is + # set. + # + # ie_hack:: + # If set to true, then inserts whitespace before the close of an empty + # tag, so that IE's bad XML parser doesn't choke. + def initialize( ie_hack=false ) + @ie_hack = ie_hack + end + + # Writes the node to some output. + # + # node:: + # The node to write + # output:: + # A class implementing <TT><<</TT>. Pass in an Output object to + # change the output encoding. + def write( node, output ) + case node + + when Document + if node.xml_decl.encoding != 'UTF-8' && !output.kind_of?(Output) + output = Output.new( output, node.xml_decl.encoding ) + end + write_document( node, output ) + + when Element + write_element( node, output ) + + when Declaration, ElementDecl, NotationDecl, ExternalEntity, Entity, + Attribute, AttlistDecl + node.write( output,-1 ) + + when Instruction + write_instruction( node, output ) + + when DocType, XMLDecl + node.write( output ) + + when Comment + write_comment( node, output ) + + when CData + write_cdata( node, output ) + + when Text + write_text( node, output ) + + else + raise Exception.new("XML FORMATTING ERROR") + + end + end + + protected + def write_document( node, output ) + node.children.each { |child| write( child, output ) } + end + + def write_element( node, output ) + output << "<#{node.expanded_name}" + + node.attributes.to_a.map { |a| + Hash === a ? a.values : a + }.flatten.sort_by {|attr| attr.name}.each do |attr| + output << " " + attr.write( output ) + end unless node.attributes.empty? + + if node.children.empty? + output << " " if @ie_hack + output << "/" + else + output << ">" + node.children.each { |child| + write( child, output ) + } + output << "</#{node.expanded_name}" + end + output << ">" + end + + def write_text( node, output ) + output << node.to_s() + end + + def write_comment( node, output ) + output << Comment::START + output << node.to_s + output << Comment::STOP + end + + def write_cdata( node, output ) + output << CData::START + output << node.to_s + output << CData::STOP + end + + def write_instruction( node, output ) + output << Instruction::START + output << node.target + content = node.content + if content + output << ' ' + output << content + end + output << Instruction::STOP + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/formatters/pretty.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/formatters/pretty.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/formatters/pretty.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/formatters/pretty.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,142 @@ +# frozen_string_literal: true +require_relative 'default' + +module REXML + module Formatters + # Pretty-prints an XML document. This destroys whitespace in text nodes + # and will insert carriage returns and indentations. + # + # TODO: Add an option to print attributes on new lines + class Pretty < Default + + # If compact is set to true, then the formatter will attempt to use as + # little space as possible + attr_accessor :compact + # The width of a page. Used for formatting text + attr_accessor :width + + # Create a new pretty printer. + # + # output:: + # An object implementing '<<(String)', to which the output will be written. + # indentation:: + # An integer greater than 0. The indentation of each level will be + # this number of spaces. If this is < 1, the behavior of this object + # is undefined. Defaults to 2. + # ie_hack:: + # If true, the printer will insert whitespace before closing empty + # tags, thereby allowing Internet Explorer's XML parser to + # function. Defaults to false. + def initialize( indentation=2, ie_hack=false ) + @indentation = indentation + @level = 0 + @ie_hack = ie_hack + @width = 80 + @compact = false + end + + protected + def write_element(node, output) + output << ' '*@level + output << "<#{node.expanded_name}" + + node.attributes.each_attribute do |attr| + output << " " + attr.write( output ) + end unless node.attributes.empty? + + if node.children.empty? + if @ie_hack + output << " " + end + output << "/" + else + output << ">" + # If compact and all children are text, and if the formatted output + # is less than the specified width, then try to print everything on + # one line + skip = false + if compact + if node.children.inject(true) {|s,c| s & c.kind_of?(Text)} + string = +"" + old_level = @level + @level = 0 + node.children.each { |child| write( child, string ) } + @level = old_level + if string.length < @width + output << string + skip = true + end + end + end + unless skip + output << "\n" + @level += @indentation + node.children.each { |child| + next if child.kind_of?(Text) and child.to_s.strip.length == 0 + write( child, output ) + output << "\n" + } + @level -= @indentation + output << ' '*@level + end + output << "</#{node.expanded_name}" + end + output << ">" + end + + def write_text( node, output ) + s = node.to_s() + s.gsub!(/\s/,' ') + s.squeeze!(" ") + s = wrap(s, @width - @level) + s = indent_text(s, @level, " ", true) + output << (' '*@level + s) + end + + def write_comment( node, output) + output << ' ' * @level + super + end + + def write_cdata( node, output) + output << ' ' * @level + super + end + + def write_document( node, output ) + # Ok, this is a bit odd. All XML documents have an XML declaration, + # but it may not write itself if the user didn't specifically add it, + # either through the API or in the input document. If it doesn't write + # itself, then we don't need a carriage return... which makes this + # logic more complex. + node.children.each { |child| + next if child.instance_of?(Text) + unless child == node.children[0] or child.instance_of?(Text) or + (child == node.children[1] and !node.children[0].writethis) + output << "\n" + end + write( child, output ) + } + end + + private + def indent_text(string, level=1, style="\t", indentfirstline=true) + return string if level < 0 + string.gsub(/\n/, "\n#{style*level}") + end + + def wrap(string, width) + parts = [] + while string.length > width and place = string.rindex(' ', width) + parts << string[0...place] + string = string[place+1..-1] + end + parts << string + parts.join("\n") + end + + end + end +end + diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/formatters/transitive.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/formatters/transitive.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/formatters/transitive.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/formatters/transitive.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,58 @@ +# frozen_string_literal: false +require_relative 'pretty' + +module REXML + module Formatters + # The Transitive formatter writes an XML document that parses to an + # identical document as the source document. This means that no extra + # whitespace nodes are inserted, and whitespace within text nodes is + # preserved. Within these constraints, the document is pretty-printed, + # with whitespace inserted into the metadata to introduce formatting. + # + # Note that this is only useful if the original XML is not already + # formatted. Since this formatter does not alter whitespace nodes, the + # results of formatting already formatted XML will be odd. + class Transitive < Default + def initialize( indentation=2, ie_hack=false ) + @indentation = indentation + @level = 0 + @ie_hack = ie_hack + end + + protected + def write_element( node, output ) + output << "<#{node.expanded_name}" + + node.attributes.each_attribute do |attr| + output << " " + attr.write( output ) + end unless node.attributes.empty? + + output << "\n" + output << ' '*@level + if node.children.empty? + output << " " if @ie_hack + output << "/" + else + output << ">" + # If compact and all children are text, and if the formatted output + # is less than the specified width, then try to print everything on + # one line + @level += @indentation + node.children.each { |child| + write( child, output ) + } + @level -= @indentation + output << "</#{node.expanded_name}" + output << "\n" + output << ' '*@level + end + output << ">" + end + + def write_text( node, output ) + output << node.to_s() + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/functions.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/functions.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/functions.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/functions.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,446 @@ +# frozen_string_literal: false +module REXML + # If you add a method, keep in mind two things: + # (1) the first argument will always be a list of nodes from which to + # filter. In the case of context methods (such as position), the function + # should return an array with a value for each child in the array. + # (2) all method calls from XML will have "-" replaced with "_". + # Therefore, in XML, "local-name()" is identical (and actually becomes) + # "local_name()" + module Functions + @@available_functions = {} + @@context = nil + @@namespace_context = {} + @@variables = {} + + INTERNAL_METHODS = [ + :namespace_context, + :namespace_context=, + :variables, + :variables=, + :context=, + :get_namespace, + :send, + ] + class << self + def singleton_method_added(name) + unless INTERNAL_METHODS.include?(name) + @@available_functions[name] = true + end + end + end + + def Functions::namespace_context=(x) ; @@namespace_context=x ; end + def Functions::variables=(x) ; @@variables=x ; end + def Functions::namespace_context ; @@namespace_context ; end + def Functions::variables ; @@variables ; end + + def Functions::context=(value); @@context = value; end + + def Functions::text( ) + if @@context[:node].node_type == :element + @@context[:node].find_all{|n| n.node_type == :text}.collect{|n| n.value} + elsif @@context[:node].node_type == :text + @@context[:node].value + else + false + end + end + + # Returns the last node of the given list of nodes. + def Functions::last( ) + @@context[:size] + end + + def Functions::position( ) + @@context[:index] + end + + # Returns the size of the given list of nodes. + def Functions::count( node_set ) + node_set.size + end + + # Since REXML is non-validating, this method is not implemented as it + # requires a DTD + def Functions::id( object ) + end + + def Functions::local_name(node_set=nil) + get_namespace(node_set) do |node| + return node.local_name + end + "" + end + + def Functions::namespace_uri( node_set=nil ) + get_namespace( node_set ) {|node| node.namespace} + end + + def Functions::name( node_set=nil ) + get_namespace( node_set ) do |node| + node.expanded_name + end + end + + # Helper method. + def Functions::get_namespace( node_set = nil ) + if node_set == nil + yield @@context[:node] if @@context[:node].respond_to?(:namespace) + else + if node_set.respond_to? :each + result = [] + node_set.each do |node| + result << yield(node) if node.respond_to?(:namespace) + end + result + elsif node_set.respond_to? :namespace + yield node_set + end + end + end + + # A node-set is converted to a string by returning the string-value of the + # node in the node-set that is first in document order. If the node-set is + # empty, an empty string is returned. + # + # A number is converted to a string as follows + # + # NaN is converted to the string NaN + # + # positive zero is converted to the string 0 + # + # negative zero is converted to the string 0 + # + # positive infinity is converted to the string Infinity + # + # negative infinity is converted to the string -Infinity + # + # if the number is an integer, the number is represented in decimal form + # as a Number with no decimal point and no leading zeros, preceded by a + # minus sign (-) if the number is negative + # + # otherwise, the number is represented in decimal form as a Number + # including a decimal point with at least one digit before the decimal + # point and at least one digit after the decimal point, preceded by a + # minus sign (-) if the number is negative; there must be no leading zeros + # before the decimal point apart possibly from the one required digit + # immediately before the decimal point; beyond the one required digit + # after the decimal point there must be as many, but only as many, more + # digits as are needed to uniquely distinguish the number from all other + # IEEE 754 numeric values. + # + # The boolean false value is converted to the string false. The boolean + # true value is converted to the string true. + # + # An object of a type other than the four basic types is converted to a + # string in a way that is dependent on that type. + def Functions::string( object=@@context[:node] ) + if object.respond_to?(:node_type) + case object.node_type + when :attribute + object.value + when :element + string_value(object) + when :document + string_value(object.root) + when :processing_instruction + object.content + else + object.to_s + end + else + case object + when Array + string(object[0]) + when Float + if object.nan? + "NaN" + else + integer = object.to_i + if object == integer + "%d" % integer + else + object.to_s + end + end + else + object.to_s + end + end + end + + # A node-set is converted to a string by + # returning the concatenation of the string-value + # of each of the children of the node in the + # node-set that is first in document order. + # If the node-set is empty, an empty string is returned. + def Functions::string_value( o ) + rv = "" + o.children.each { |e| + if e.node_type == :text + rv << e.to_s + elsif e.node_type == :element + rv << string_value( e ) + end + } + rv + end + + def Functions::concat( *objects ) + concatenated = "" + objects.each do |object| + concatenated << string(object) + end + concatenated + end + + # Fixed by Mike Stok + def Functions::starts_with( string, test ) + string(string).index(string(test)) == 0 + end + + # Fixed by Mike Stok + def Functions::contains( string, test ) + string(string).include?(string(test)) + end + + # Kouhei fixed this + def Functions::substring_before( string, test ) + ruby_string = string(string) + ruby_index = ruby_string.index(string(test)) + if ruby_index.nil? + "" + else + ruby_string[ 0...ruby_index ] + end + end + + # Kouhei fixed this too + def Functions::substring_after( string, test ) + ruby_string = string(string) + return $1 if ruby_string =~ /#{test}(.*)/ + "" + end + + # Take equal portions of Mike Stok and Sean Russell; mix + # vigorously, and pour into a tall, chilled glass. Serves 10,000. + def Functions::substring( string, start, length=nil ) + ruby_string = string(string) + ruby_length = if length.nil? + ruby_string.length.to_f + else + number(length) + end + ruby_start = number(start) + + # Handle the special cases + return '' if ( + ruby_length.nan? or + ruby_start.nan? or + ruby_start.infinite? + ) + + infinite_length = ruby_length.infinite? == 1 + ruby_length = ruby_string.length if infinite_length + + # Now, get the bounds. The XPath bounds are 1..length; the ruby bounds + # are 0..length. Therefore, we have to offset the bounds by one. + ruby_start = round(ruby_start) - 1 + ruby_length = round(ruby_length) + + if ruby_start < 0 + ruby_length += ruby_start unless infinite_length + ruby_start = 0 + end + return '' if ruby_length <= 0 + ruby_string[ruby_start,ruby_length] + end + + # UNTESTED + def Functions::string_length( string ) + string(string).length + end + + def Functions::normalize_space( string=nil ) + string = string(@@context[:node]) if string.nil? + if string.kind_of? Array + string.collect{|x| x.to_s.strip.gsub(/\s+/um, ' ') if x} + else + string.to_s.strip.gsub(/\s+/um, ' ') + end + end + + # This is entirely Mike Stok's beast + def Functions::translate( string, tr1, tr2 ) + from = string(tr1) + to = string(tr2) + + # the map is our translation table. + # + # if a character occurs more than once in the + # from string then we ignore the second & + # subsequent mappings + # + # if a character maps to nil then we delete it + # in the output. This happens if the from + # string is longer than the to string + # + # there's nothing about - or ^ being special in + # http://www.w3.org/TR/xpath#function-translate + # so we don't build ranges or negated classes + + map = Hash.new + 0.upto(from.length - 1) { |pos| + from_char = from[pos] + unless map.has_key? from_char + map[from_char] = + if pos < to.length + to[pos] + else + nil + end + end + } + + if ''.respond_to? :chars + string(string).chars.collect { |c| + if map.has_key? c then map[c] else c end + }.compact.join + else + string(string).unpack('U*').collect { |c| + if map.has_key? c then map[c] else c end + }.compact.pack('U*') + end + end + + def Functions::boolean(object=@@context[:node]) + case object + when true, false + object + when Float + return false if object.zero? + return false if object.nan? + true + when Numeric + not object.zero? + when String + not object.empty? + when Array + not object.empty? + else + object ? true : false + end + end + + # UNTESTED + def Functions::not( object ) + not boolean( object ) + end + + # UNTESTED + def Functions::true( ) + true + end + + # UNTESTED + def Functions::false( ) + false + end + + # UNTESTED + def Functions::lang( language ) + lang = false + node = @@context[:node] + attr = nil + until node.nil? + if node.node_type == :element + attr = node.attributes["xml:lang"] + unless attr.nil? + lang = compare_language(string(language), attr) + break + else + end + end + node = node.parent + end + lang + end + + def Functions::compare_language lang1, lang2 + lang2.downcase.index(lang1.downcase) == 0 + end + + # a string that consists of optional whitespace followed by an optional + # minus sign followed by a Number followed by whitespace is converted to + # the IEEE 754 number that is nearest (according to the IEEE 754 + # round-to-nearest rule) to the mathematical value represented by the + # string; any other string is converted to NaN + # + # boolean true is converted to 1; boolean false is converted to 0 + # + # a node-set is first converted to a string as if by a call to the string + # function and then converted in the same way as a string argument + # + # an object of a type other than the four basic types is converted to a + # number in a way that is dependent on that type + def Functions::number(object=@@context[:node]) + case object + when true + Float(1) + when false + Float(0) + when Array + number(string(object)) + when Numeric + object.to_f + else + str = string(object) + case str.strip + when /\A\s*(-?(?:\d+(?:\.\d*)?|\.\d+))\s*\z/ + $1.to_f + else + Float::NAN + end + end + end + + def Functions::sum( nodes ) + nodes = [nodes] unless nodes.kind_of? Array + nodes.inject(0) { |r,n| r + number(string(n)) } + end + + def Functions::floor( number ) + number(number).floor + end + + def Functions::ceiling( number ) + number(number).ceil + end + + def Functions::round( number ) + number = number(number) + begin + neg = number.negative? + number = number.abs.round + neg ? -number : number + rescue FloatDomainError + number + end + end + + def Functions::processing_instruction( node ) + node.node_type == :processing_instruction + end + + def Functions::send(name, *args) + if @@available_functions[name.to_sym] + super + else + # TODO: Maybe, this is not XPath spec behavior. + # This behavior must be reconsidered. + XPath.match(@@context[:node], name.to_s) + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/instruction.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/instruction.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/instruction.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/instruction.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,79 @@ +# frozen_string_literal: false + +require_relative "child" +require_relative "source" + +module REXML + # Represents an XML Instruction; IE, <? ... ?> + # TODO: Add parent arg (3rd arg) to constructor + class Instruction < Child + START = "<?" + STOP = "?>" + + # target is the "name" of the Instruction; IE, the "tag" in <?tag ...?> + # content is everything else. + attr_accessor :target, :content + + # Constructs a new Instruction + # @param target can be one of a number of things. If String, then + # the target of this instruction is set to this. If an Instruction, + # then the Instruction is shallowly cloned (target and content are + # copied). + # @param content Must be either a String, or a Parent. Can only + # be a Parent if the target argument is a Source. Otherwise, this + # String is set as the content of this instruction. + def initialize(target, content=nil) + case target + when String + super() + @target = target + @content = content + when Instruction + super(content) + @target = target.target + @content = target.content + else + message = + "processing instruction target must be String or REXML::Instruction: " + message << "<#{target.inspect}>" + raise ArgumentError, message + end + @content.strip! if @content + end + + def clone + Instruction.new self + end + + # == DEPRECATED + # See the rexml/formatters package + # + def write writer, indent=-1, transitive=false, ie_hack=false + Kernel.warn( "#{self.class.name}#write is deprecated", uplevel: 1) + indent(writer, indent) + writer << START + writer << @target + if @content + writer << ' ' + writer << @content + end + writer << STOP + end + + # @return true if other is an Instruction, and the content and target + # of the other matches the target and content of this object. + def ==( other ) + other.kind_of? Instruction and + other.target == @target and + other.content == @content + end + + def node_type + :processing_instruction + end + + def inspect + "<?p-i #{target} ...?>" + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/light/node.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/light/node.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/light/node.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/light/node.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,188 @@ +# frozen_string_literal: false +require_relative '../xmltokens' + +module REXML + module Light + # Represents a tagged XML element. Elements are characterized by + # having children, attributes, and names, and can themselves be + # children. + class Node + NAMESPLIT = /^(?:(#{XMLTokens::NCNAME_STR}):)?(#{XMLTokens::NCNAME_STR})/u + PARENTS = [ :element, :document, :doctype ] + # Create a new element. + def initialize node=nil + @node = node + if node.kind_of? String + node = [ :text, node ] + elsif node.nil? + node = [ :document, nil, nil ] + elsif node[0] == :start_element + node[0] = :element + elsif node[0] == :start_doctype + node[0] = :doctype + elsif node[0] == :start_document + node[0] = :document + end + end + + def size + if PARENTS.include? @node[0] + @node[-1].size + else + 0 + end + end + + def each + size.times { |x| yield( at(x+4) ) } + end + + def name + at(2) + end + + def name=( name_str, ns=nil ) + pfx = '' + pfx = "#{prefix(ns)}:" if ns + _old_put(2, "#{pfx}#{name_str}") + end + + def parent=( node ) + _old_put(1,node) + end + + def local_name + namesplit + @name + end + + def local_name=( name_str ) + _old_put( 1, "#@prefix:#{name_str}" ) + end + + def prefix( namespace=nil ) + prefix_of( self, namespace ) + end + + def namespace( prefix=prefix() ) + namespace_of( self, prefix ) + end + + def namespace=( namespace ) + @prefix = prefix( namespace ) + pfx = '' + pfx = "#@prefix:" if @prefix.size > 0 + _old_put(1, "#{pfx}#@name") + end + + def []( reference, ns=nil ) + if reference.kind_of? String + pfx = '' + pfx = "#{prefix(ns)}:" if ns + at(3)["#{pfx}#{reference}"] + elsif reference.kind_of? Range + _old_get( Range.new(4+reference.begin, reference.end, reference.exclude_end?) ) + else + _old_get( 4+reference ) + end + end + + def =~( path ) + XPath.match( self, path ) + end + + # Doesn't handle namespaces yet + def []=( reference, ns, value=nil ) + if reference.kind_of? String + value = ns unless value + at( 3 )[reference] = value + elsif reference.kind_of? Range + _old_put( Range.new(3+reference.begin, reference.end, reference.exclude_end?), ns ) + else + if value + _old_put( 4+reference, ns, value ) + else + _old_put( 4+reference, ns ) + end + end + end + + # Append a child to this element, optionally under a provided namespace. + # The namespace argument is ignored if the element argument is an Element + # object. Otherwise, the element argument is a string, the namespace (if + # provided) is the namespace the element is created in. + def << element + if node_type() == :text + at(-1) << element + else + newnode = Node.new( element ) + newnode.parent = self + self.push( newnode ) + end + at(-1) + end + + def node_type + _old_get(0) + end + + def text=( foo ) + replace = at(4).kind_of?(String)? 1 : 0 + self._old_put(4,replace, normalizefoo) + end + + def root + context = self + context = context.at(1) while context.at(1) + end + + def has_name?( name, namespace = '' ) + at(3) == name and namespace() == namespace + end + + def children + self + end + + def parent + at(1) + end + + def to_s + + end + + private + + def namesplit + return if @name.defined? + at(2) =~ NAMESPLIT + @prefix = '' || $1 + @name = $2 + end + + def namespace_of( node, prefix=nil ) + if not prefix + name = at(2) + name =~ NAMESPLIT + prefix = $1 + end + to_find = 'xmlns' + to_find = "xmlns:#{prefix}" if not prefix.nil? + ns = at(3)[ to_find ] + ns ? ns : namespace_of( @node[0], prefix ) + end + + def prefix_of( node, namespace=nil ) + if not namespace + name = node.name + name =~ NAMESPLIT + $1 + else + ns = at(3).find { |k,v| v == namespace } + ns ? ns : prefix_of( node.parent, namespace ) + end + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/namespace.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/namespace.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/namespace.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/namespace.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,63 @@ +# frozen_string_literal: true + +require_relative 'xmltokens' + +module REXML + # Adds named attributes to an object. + module Namespace + # The name of the object, valid if set + attr_reader :name, :expanded_name + # The expanded name of the object, valid if name is set + attr_accessor :prefix + include XMLTokens + NAME_WITHOUT_NAMESPACE = /\A#{NCNAME_STR}\z/ + NAMESPLIT = /^(?:(#{NCNAME_STR}):)?(#{NCNAME_STR})/u + + # Sets the name and the expanded name + def name=( name ) + @expanded_name = name + if name.match?(NAME_WITHOUT_NAMESPACE) + @prefix = "" + @namespace = "" + @name = name + elsif name =~ NAMESPLIT + if $1 + @prefix = $1 + else + @prefix = "" + @namespace = "" + end + @name = $2 + elsif name == "" + @prefix = nil + @namespace = nil + @name = nil + else + message = "name must be \#{PREFIX}:\#{LOCAL_NAME} or \#{LOCAL_NAME}: " + message += "<#{name.inspect}>" + raise ArgumentError, message + end + end + + # Compares names optionally WITH namespaces + def has_name?( other, ns=nil ) + if ns + namespace() == ns and name() == other + elsif other.include? ":" + fully_expanded_name == other + else + name == other + end + end + + alias :local_name :name + + # Fully expand the name, even if the prefix wasn't specified in the + # source file. + def fully_expanded_name + ns = prefix + return "#{ns}:#@name" if ns.size > 0 + @name + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/node.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/node.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/node.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/node.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,80 @@ +# frozen_string_literal: false +require_relative "parseexception" +require_relative "formatters/pretty" +require_relative "formatters/default" + +module REXML + # Represents a node in the tree. Nodes are never encountered except as + # superclasses of other objects. Nodes have siblings. + module Node + # @return the next sibling (nil if unset) + def next_sibling_node + return nil if @parent.nil? + @parent[ @parent.index(self) + 1 ] + end + + # @return the previous sibling (nil if unset) + def previous_sibling_node + return nil if @parent.nil? + ind = @parent.index(self) + return nil if ind == 0 + @parent[ ind - 1 ] + end + + # indent:: + # *DEPRECATED* This parameter is now ignored. See the formatters in the + # REXML::Formatters package for changing the output style. + def to_s indent=nil + unless indent.nil? + Kernel.warn( "#{self.class.name}#to_s(indent) parameter is deprecated", uplevel: 1) + f = REXML::Formatters::Pretty.new( indent ) + f.write( self, rv = "" ) + else + f = REXML::Formatters::Default.new + f.write( self, rv = "" ) + end + return rv + end + + def indent to, ind + if @parent and @parent.context and not @parent.context[:indentstyle].nil? then + indentstyle = @parent.context[:indentstyle] + else + indentstyle = ' ' + end + to << indentstyle*ind unless ind<1 + end + + def parent? + false; + end + + + # Visit all subnodes of +self+ recursively + def each_recursive(&block) # :yields: node + stack = [] + each { |child| stack.unshift child if child.node_type == :element } + until stack.empty? + child = stack.pop + yield child + n = stack.size + child.each { |grandchild| stack.insert n, grandchild if grandchild.node_type == :element } + end + end + + # Find (and return) first subnode (recursively) for which the block + # evaluates to true. Returns +nil+ if none was found. + def find_first_recursive(&block) # :yields: node + each_recursive {|node| + return node if block.call(node) + } + nil + end + + # Returns the position that +self+ holds in its parent's array, indexed + # from 1. + def index_in_parent + parent.index(self)+1 + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/output.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/output.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/output.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/output.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,30 @@ +# frozen_string_literal: false +require_relative 'encoding' + +module REXML + class Output + include Encoding + + attr_reader :encoding + + def initialize real_IO, encd="iso-8859-1" + @output = real_IO + self.encoding = encd + + @to_utf = encoding != 'UTF-8' + + if encoding == "UTF-16" + @output << "\ufeff".encode("UTF-16BE") + self.encoding = "UTF-16BE" + end + end + + def <<( content ) + @output << (@to_utf ? self.encode(content) : content) + end + + def to_s + "Output[#{encoding}]" + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parent.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parent.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parent.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parent.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,166 @@ +# frozen_string_literal: false +require_relative "child" + +module REXML + # A parent has children, and has methods for accessing them. The Parent + # class is never encountered except as the superclass for some other + # object. + class Parent < Child + include Enumerable + + # Constructor + # @param parent if supplied, will be set as the parent of this object + def initialize parent=nil + super(parent) + @children = [] + end + + def add( object ) + object.parent = self + @children << object + object + end + + alias :push :add + alias :<< :push + + def unshift( object ) + object.parent = self + @children.unshift object + end + + def delete( object ) + found = false + @children.delete_if {|c| c.equal?(object) and found = true } + object.parent = nil if found + found ? object : nil + end + + def each(&block) + @children.each(&block) + end + + def delete_if( &block ) + @children.delete_if(&block) + end + + def delete_at( index ) + @children.delete_at index + end + + def each_index( &block ) + @children.each_index(&block) + end + + # Fetches a child at a given index + # @param index the Integer index of the child to fetch + def []( index ) + @children[index] + end + + alias :each_child :each + + + + # Set an index entry. See Array.[]= + # @param index the index of the element to set + # @param opt either the object to set, or an Integer length + # @param child if opt is an Integer, this is the child to set + # @return the parent (self) + def []=( *args ) + args[-1].parent = self + @children[*args[0..-2]] = args[-1] + end + + # Inserts an child before another child + # @param child1 this is either an xpath or an Element. If an Element, + # child2 will be inserted before child1 in the child list of the parent. + # If an xpath, child2 will be inserted before the first child to match + # the xpath. + # @param child2 the child to insert + # @return the parent (self) + def insert_before( child1, child2 ) + if child1.kind_of? String + child1 = XPath.first( self, child1 ) + child1.parent.insert_before child1, child2 + else + ind = index(child1) + child2.parent.delete(child2) if child2.parent + @children[ind,0] = child2 + child2.parent = self + end + self + end + + # Inserts an child after another child + # @param child1 this is either an xpath or an Element. If an Element, + # child2 will be inserted after child1 in the child list of the parent. + # If an xpath, child2 will be inserted after the first child to match + # the xpath. + # @param child2 the child to insert + # @return the parent (self) + def insert_after( child1, child2 ) + if child1.kind_of? String + child1 = XPath.first( self, child1 ) + child1.parent.insert_after child1, child2 + else + ind = index(child1)+1 + child2.parent.delete(child2) if child2.parent + @children[ind,0] = child2 + child2.parent = self + end + self + end + + def to_a + @children.dup + end + + # Fetches the index of a given child + # @param child the child to get the index of + # @return the index of the child, or nil if the object is not a child + # of this parent. + def index( child ) + count = -1 + @children.find { |i| count += 1 ; i.hash == child.hash } + count + end + + # @return the number of children of this parent + def size + @children.size + end + + alias :length :size + + # Replaces one child with another, making sure the nodelist is correct + # @param to_replace the child to replace (must be a Child) + # @param replacement the child to insert into the nodelist (must be a + # Child) + def replace_child( to_replace, replacement ) + @children.map! {|c| c.equal?( to_replace ) ? replacement : c } + to_replace.parent = nil + replacement.parent = self + end + + # Deeply clones this object. This creates a complete duplicate of this + # Parent, including all descendants. + def deep_clone + cl = clone() + each do |child| + if child.kind_of? Parent + cl << child.deep_clone + else + cl << child.clone + end + end + cl + end + + alias :children :to_a + + def parent? + true + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parseexception.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parseexception.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parseexception.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parseexception.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,53 @@ +# frozen_string_literal: false +module REXML + class ParseException < RuntimeError + attr_accessor :source, :parser, :continued_exception + + def initialize( message, source=nil, parser=nil, exception=nil ) + super(message) + @source = source + @parser = parser + @continued_exception = exception + end + + def to_s + # Quote the original exception, if there was one + if @continued_exception + err = @continued_exception.inspect + err << "\n" + err << @continued_exception.backtrace.join("\n") + err << "\n...\n" + else + err = "" + end + + # Get the stack trace and error message + err << super + + # Add contextual information + if @source + err << "\nLine: #{line}\n" + err << "Position: #{position}\n" + err << "Last 80 unconsumed characters:\n" + err.force_encoding("ASCII-8BIT") + err << @source.buffer[0..80].force_encoding("ASCII-8BIT").gsub(/\n/, ' ') + end + + err + end + + def position + @source.current_line[0] if @source and defined? @source.current_line and + @source.current_line + end + + def line + @source.current_line[2] if @source and defined? @source.current_line and + @source.current_line + end + + def context + @source.current_line + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/baseparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/baseparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/baseparser.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/baseparser.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,949 @@ +# frozen_string_literal: true +require_relative '../parseexception' +require_relative '../undefinednamespaceexception' +require_relative '../security' +require_relative '../source' +require 'set' +require "strscan" + +module REXML + module Parsers + unless [].respond_to?(:tally) + module EnumerableTally + refine Enumerable do + def tally + counts = {} + each do |item| + counts[item] ||= 0 + counts[item] += 1 + end + counts + end + end + end + using EnumerableTally + end + + if StringScanner::Version < "3.0.8" + module StringScannerCaptures + refine StringScanner do + def captures + values_at(*(1...size)) + end + end + end + using StringScannerCaptures + end + + # = Using the Pull Parser + # <em>This API is experimental, and subject to change.</em> + # parser = PullParser.new( "<a>text<b att='val'/>txet</a>" ) + # while parser.has_next? + # res = parser.next + # puts res[1]['att'] if res.start_tag? and res[0] == 'b' + # end + # See the PullEvent class for information on the content of the results. + # The data is identical to the arguments passed for the various events to + # the StreamListener API. + # + # Notice that: + # parser = PullParser.new( "<a>BAD DOCUMENT" ) + # while parser.has_next? + # res = parser.next + # raise res[1] if res.error? + # end + # + # Nat Price gave me some good ideas for the API. + class BaseParser + LETTER = '[:alpha:]' + DIGIT = '[:digit:]' + + COMBININGCHAR = '' # TODO + EXTENDER = '' # TODO + + NCNAME_STR= "[#{LETTER}_][-[:alnum:]._#{COMBININGCHAR}#{EXTENDER}]*" + QNAME_STR= "(?:(#{NCNAME_STR}):)?(#{NCNAME_STR})" + QNAME = /(#{QNAME_STR})/ + + # Just for backward compatibility. For example, kramdown uses this. + # It's not used in REXML. + UNAME_STR= "(?:#{NCNAME_STR}:)?#{NCNAME_STR}" + + NAMECHAR = '[\-\w\.:]' + NAME = "([\\w:]#{NAMECHAR}*)" + NMTOKEN = "(?:#{NAMECHAR})+" + NMTOKENS = "#{NMTOKEN}(\\s+#{NMTOKEN})*" + REFERENCE = "&(?:#{NAME};|#\\d+;|#x[0-9a-fA-F]+;)" + REFERENCE_RE = /#{REFERENCE}/ + + DOCTYPE_START = /\A\s*<!DOCTYPE\s/um + DOCTYPE_END = /\A\s*\]\s*>/um + ATTRIBUTE_PATTERN = /\s*(#{QNAME_STR})\s*=\s*(["'])(.*?)\4/um + COMMENT_START = /\A<!--/u + COMMENT_PATTERN = /<!--(.*?)-->/um + CDATA_START = /\A<!\[CDATA\[/u + CDATA_END = /\A\s*\]\s*>/um + CDATA_PATTERN = /<!\[CDATA\[(.*?)\]\]>/um + XMLDECL_START = /\A<\?xml\s/u; + XMLDECL_PATTERN = /<\?xml\s+(.*?)\?>/um + INSTRUCTION_START = /\A<\?/u + INSTRUCTION_PATTERN = /<\?#{NAME}(\s+.*?)?\?>/um + TAG_MATCH = /\A<((?>#{QNAME_STR}))/um + CLOSE_MATCH = /\A\s*<\/(#{QNAME_STR})\s*>/um + + VERSION = /\bversion\s*=\s*["'](.*?)['"]/um + ENCODING = /\bencoding\s*=\s*["'](.*?)['"]/um + STANDALONE = /\bstandalone\s*=\s*["'](.*?)['"]/um + + ENTITY_START = /\A\s*<!ENTITY/ + ELEMENTDECL_START = /\A\s*<!ELEMENT/um + ELEMENTDECL_PATTERN = /\A\s*(<!ELEMENT.*?)>/um + SYSTEMENTITY = /\A\s*(%.*?;)\s*$/um + ENUMERATION = "\\(\\s*#{NMTOKEN}(?:\\s*\\|\\s*#{NMTOKEN})*\\s*\\)" + NOTATIONTYPE = "NOTATION\\s+\\(\\s*#{NAME}(?:\\s*\\|\\s*#{NAME})*\\s*\\)" + ENUMERATEDTYPE = "(?:(?:#{NOTATIONTYPE})|(?:#{ENUMERATION}))" + ATTTYPE = "(CDATA|ID|IDREF|IDREFS|ENTITY|ENTITIES|NMTOKEN|NMTOKENS|#{ENUMERATEDTYPE})" + ATTVALUE = "(?:\"((?:[^<&\"]|#{REFERENCE})*)\")|(?:'((?:[^<&']|#{REFERENCE})*)')" + DEFAULTDECL = "(#REQUIRED|#IMPLIED|(?:(#FIXED\\s+)?#{ATTVALUE}))" + ATTDEF = "\\s+#{NAME}\\s+#{ATTTYPE}\\s+#{DEFAULTDECL}" + ATTDEF_RE = /#{ATTDEF}/ + ATTLISTDECL_START = /\A\s*<!ATTLIST/um + ATTLISTDECL_PATTERN = /\A\s*<!ATTLIST\s+#{NAME}(?:#{ATTDEF})*\s*>/um + + TEXT_PATTERN = /\A([^<]*)/um + + # Entity constants + PUBIDCHAR = "\x20\x0D\x0Aa-zA-Z0-9\\-()+,./:=?;!*@$_%#" + SYSTEMLITERAL = %Q{((?:"[^"]*")|(?:'[^']*'))} + PUBIDLITERAL = %Q{("[#{PUBIDCHAR}']*"|'[#{PUBIDCHAR}]*')} + EXTERNALID = "(?:(?:(SYSTEM)\\s+#{SYSTEMLITERAL})|(?:(PUBLIC)\\s+#{PUBIDLITERAL}\\s+#{SYSTEMLITERAL}))" + NDATADECL = "\\s+NDATA\\s+#{NAME}" + PEREFERENCE = "%#{NAME};" + ENTITYVALUE = %Q{((?:"(?:[^%&"]|#{PEREFERENCE}|#{REFERENCE})*")|(?:'([^%&']|#{PEREFERENCE}|#{REFERENCE})*'))} + PEDEF = "(?:#{ENTITYVALUE}|#{EXTERNALID})" + ENTITYDEF = "(?:#{ENTITYVALUE}|(?:#{EXTERNALID}(#{NDATADECL})?))" + PEDECL = "<!ENTITY\\s+(%)\\s+#{NAME}\\s+#{PEDEF}\\s*>" + GEDECL = "<!ENTITY\\s+#{NAME}\\s+#{ENTITYDEF}\\s*>" + ENTITYDECL = /\s*(?:#{GEDECL})|\s*(?:#{PEDECL})/um + + NOTATIONDECL_START = /\A\s*<!NOTATION/um + EXTERNAL_ID_PUBLIC = /\A\s*PUBLIC\s+#{PUBIDLITERAL}\s+#{SYSTEMLITERAL}\s*/um + EXTERNAL_ID_SYSTEM = /\A\s*SYSTEM\s+#{SYSTEMLITERAL}\s*/um + PUBLIC_ID = /\A\s*PUBLIC\s+#{PUBIDLITERAL}\s*/um + + EREFERENCE = /&(?!#{NAME};)/ + + DEFAULT_ENTITIES = { + 'gt' => [/>/, '>', '>', />/], + 'lt' => [/</, '<', '<', /</], + 'quot' => [/"/, '"', '"', /"/], + "apos" => [/'/, "'", "'", /'/] + } + + module Private + PEREFERENCE_PATTERN = /#{PEREFERENCE}/um + TAG_PATTERN = /((?>#{QNAME_STR}))\s*/um + CLOSE_PATTERN = /(#{QNAME_STR})\s*>/um + EQUAL_PATTERN = /\s*=\s*/um + ATTLISTDECL_END = /\s+#{NAME}(?:#{ATTDEF})*\s*>/um + NAME_PATTERN = /#{NAME}/um + GEDECL_PATTERN = "\\s+#{NAME}\\s+#{ENTITYDEF}\\s*>" + PEDECL_PATTERN = "\\s+(%)\\s+#{NAME}\\s+#{PEDEF}\\s*>" + ENTITYDECL_PATTERN = /(?:#{GEDECL_PATTERN})|(?:#{PEDECL_PATTERN})/um + CARRIAGE_RETURN_NEWLINE_PATTERN = /\r\n?/ + CHARACTER_REFERENCES = /&#((?:\d+)|(?:x[a-fA-F0-9]+));/ + DEFAULT_ENTITIES_PATTERNS = {} + default_entities = ['gt', 'lt', 'quot', 'apos', 'amp'] + default_entities.each do |term| + DEFAULT_ENTITIES_PATTERNS[term] = /&#{term};/ + end + XML_PREFIXED_NAMESPACE = "http://www.w3.org/XML/1998/namespace" + end + private_constant :Private + + def initialize( source ) + self.stream = source + @listeners = [] + @prefixes = Set.new + @entity_expansion_count = 0 + @entity_expansion_limit = Security.entity_expansion_limit + @entity_expansion_text_limit = Security.entity_expansion_text_limit + @source.ensure_buffer + @version = nil + end + + def add_listener( listener ) + @listeners << listener + end + + attr_reader :source + attr_reader :entity_expansion_count + attr_writer :entity_expansion_limit + attr_writer :entity_expansion_text_limit + + def stream=( source ) + @source = SourceFactory.create_from( source ) + reset + end + + def reset + @closed = nil + @have_root = false + @document_status = nil + @tags = [] + @stack = [] + @entities = [] + @namespaces = {"xml" => Private::XML_PREFIXED_NAMESPACE} + @namespaces_restore_stack = [] + end + + def position + if @source.respond_to? :position + @source.position + else + # FIXME + 0 + end + end + + # Returns true if there are no more events + def empty? + (@source.empty? and @stack.empty?) + end + + # Returns true if there are more events. Synonymous with !empty? + def has_next? + !(@source.empty? and @stack.empty?) + end + + # Push an event back on the head of the stream. This method + # has (theoretically) infinite depth. + def unshift token + @stack.unshift(token) + end + + # Peek at the +depth+ event in the stack. The first element on the stack + # is at depth 0. If +depth+ is -1, will parse to the end of the input + # stream and return the last event, which is always :end_document. + # Be aware that this causes the stream to be parsed up to the +depth+ + # event, so you can effectively pre-parse the entire document (pull the + # entire thing into memory) using this method. + def peek depth=0 + raise %Q[Illegal argument "#{depth}"] if depth < -1 + temp = [] + if depth == -1 + temp.push(pull()) until empty? + else + while @stack.size+temp.size < depth+1 + temp.push(pull()) + end + end + @stack += temp if temp.size > 0 + @stack[depth] + end + + # Returns the next event. This is a +PullEvent+ object. + def pull + @source.drop_parsed_content + + pull_event.tap do |event| + @listeners.each do |listener| + listener.receive event + end + end + end + + def pull_event + if @closed + x, @closed = @closed, nil + return [ :end_element, x ] + end + if empty? + if @document_status == :in_doctype + raise ParseException.new("Malformed DOCTYPE: unclosed", @source) + end + unless @tags.empty? + path = "/" + @tags.join("/") + raise ParseException.new("Missing end tag for '#{path}'", @source) + end + + unless @document_status == :in_element + raise ParseException.new("Malformed XML: No root element", @source) + end + + return [ :end_document ] + end + return @stack.shift if @stack.size > 0 + #STDERR.puts @source.encoding + #STDERR.puts "BUFFER = #{@source.buffer.inspect}" + + @source.ensure_buffer + if @document_status == nil + start_position = @source.position + if @source.match?("<?", true) + return process_instruction + elsif @source.match?("<!", true) + if @source.match?("--", true) + return [ :comment, process_comment ] + elsif @source.match?("DOCTYPE", true) + base_error_message = "Malformed DOCTYPE" + unless @source.skip_spaces + if @source.match?(">") + message = "#{base_error_message}: name is missing" + else + message = "#{base_error_message}: invalid name" + end + @source.position = start_position + raise REXML::ParseException.new(message, @source) + end + name = parse_name(base_error_message) + @source.skip_spaces + if @source.match?("[", true) + id = [nil, nil, nil] + @document_status = :in_doctype + elsif @source.match?(">", true) + id = [nil, nil, nil] + @document_status = :after_doctype + @source.ensure_buffer + else + id = parse_id(base_error_message, + accept_external_id: true, + accept_public_id: false) + if id[0] == "SYSTEM" + # For backward compatibility + id[1], id[2] = id[2], nil + end + @source.skip_spaces + if @source.match?("[", true) + @document_status = :in_doctype + elsif @source.match?(">", true) + @document_status = :after_doctype + @source.ensure_buffer + else + message = "#{base_error_message}: garbage after external ID" + raise REXML::ParseException.new(message, @source) + end + end + args = [:start_doctype, name, *id] + if @document_status == :after_doctype + @source.skip_spaces + @stack << [ :end_doctype ] + end + return args + else + message = "Invalid XML" + raise REXML::ParseException.new(message, @source) + end + end + end + if @document_status == :in_doctype + @source.skip_spaces + start_position = @source.position + if @source.match?("<!", true) + if @source.match?("ELEMENT", true) + md = @source.match(/(.*?)>/um, true) + raise REXML::ParseException.new( "Bad ELEMENT declaration!", @source ) if md.nil? + return [ :elementdecl, "<!ELEMENT" + md[1] ] + elsif @source.match?("ENTITY", true) + match_data = @source.match(Private::ENTITYDECL_PATTERN, true) + unless match_data + raise REXML::ParseException.new("Malformed entity declaration", @source) + end + match = [:entitydecl, *match_data.captures.compact] + ref = false + if match[1] == '%' + ref = true + match.delete_at 1 + end + # Now we have to sort out what kind of entity reference this is + if match[2] == 'SYSTEM' + # External reference + match[3] = match[3][1..-2] # PUBID + match.delete_at(4) if match.size > 4 # Chop out NDATA decl + # match is [ :entity, name, SYSTEM, pubid(, ndata)? ] + elsif match[2] == 'PUBLIC' + # External reference + match[3] = match[3][1..-2] # PUBID + match[4] = match[4][1..-2] # HREF + match.delete_at(5) if match.size > 5 # Chop out NDATA decl + # match is [ :entity, name, PUBLIC, pubid, href(, ndata)? ] + elsif Private::PEREFERENCE_PATTERN.match?(match[2]) + raise REXML::ParseException.new("Parameter entity references forbidden in internal subset: #{match[2]}", @source) + else + match[2] = match[2][1..-2] + match.pop if match.size == 4 + # match is [ :entity, name, value ] + end + match << '%' if ref + return match + elsif @source.match?("ATTLIST", true) + md = @source.match(Private::ATTLISTDECL_END, true) + raise REXML::ParseException.new( "Bad ATTLIST declaration!", @source ) if md.nil? + element = md[1] + contents = "<!ATTLIST" + md[0] + + pairs = {} + values = md[0].strip.scan( ATTDEF_RE ) + values.each do |attdef| + unless attdef[3] == "#IMPLIED" + attdef.compact! + val = attdef[3] + val = attdef[4] if val == "#FIXED " + pairs[attdef[0]] = val + if attdef[0] =~ /^xmlns:(.*)/ + @namespaces[$1] = val + end + end + end + return [ :attlistdecl, element, pairs, contents ] + elsif @source.match?("NOTATION", true) + base_error_message = "Malformed notation declaration" + unless @source.skip_spaces + if @source.match?(">") + message = "#{base_error_message}: name is missing" + else + message = "#{base_error_message}: invalid name" + end + @source.position = start_position + raise REXML::ParseException.new(message, @source) + end + name = parse_name(base_error_message) + id = parse_id(base_error_message, + accept_external_id: true, + accept_public_id: true) + @source.skip_spaces + unless @source.match?(">", true) + message = "#{base_error_message}: garbage before end >" + raise REXML::ParseException.new(message, @source) + end + return [:notationdecl, name, *id] + elsif @source.match?("--", true) + return [ :comment, process_comment ] + else + raise REXML::ParseException.new("Malformed node: Started with '<!' but not a comment nor ELEMENT,ENTITY,ATTLIST,NOTATION", @source) + end + elsif match = @source.match(/(%.*?;)\s*/um, true) + return [ :externalentity, match[1] ] + elsif @source.match?(/\]\s*>/um, true) + @document_status = :after_doctype + return [ :end_doctype ] + else + raise ParseException.new("Malformed DOCTYPE: invalid declaration", @source) + end + end + if @document_status == :after_doctype + @source.skip_spaces + end + begin + start_position = @source.position + if @source.match?("<", true) + # :text's read_until may remain only "<" in buffer. In the + # case, buffer is empty here. So we need to fill buffer + # here explicitly. + @source.ensure_buffer + if @source.match?("/", true) + @namespaces_restore_stack.pop + last_tag = @tags.pop + md = @source.match(Private::CLOSE_PATTERN, true) + if md and !last_tag + message = "Unexpected top-level end tag (got '#{md[1]}')" + raise REXML::ParseException.new(message, @source) + end + if md.nil? or last_tag != md[1] + message = "Missing end tag for '#{last_tag}'" + message += " (got '#{md[1]}')" if md + @source.position = start_position if md.nil? + raise REXML::ParseException.new(message, @source) + end + return [ :end_element, last_tag ] + elsif @source.match?("!", true) + #STDERR.puts "SOURCE BUFFER = #{source.buffer}, #{source.buffer.size}" + if @source.match?("--", true) + return [ :comment, process_comment ] + elsif @source.match?("[CDATA[", true) + text = @source.read_until("]]>") + if text.chomp!("]]>") + return [ :cdata, text ] + else + raise REXML::ParseException.new("Malformed CDATA: Missing end ']]>'", @source) + end + else + raise REXML::ParseException.new("Malformed node: Started with '<!' but not a comment nor CDATA", @source) + end + elsif @source.match?("?", true) + return process_instruction + else + # Get the next tag + md = @source.match(Private::TAG_PATTERN, true) + unless md + @source.position = start_position + raise REXML::ParseException.new("malformed XML: missing tag start", @source) + end + tag = md[1] + @document_status = :in_element + @prefixes.clear + @prefixes << md[2] if md[2] + push_namespaces_restore + attributes, closed = parse_attributes(@prefixes) + # Verify that all of the prefixes have been defined + for prefix in @prefixes + unless @namespaces.key?(prefix) + raise UndefinedNamespaceException.new(prefix,@source,self) + end + end + + if closed + @closed = tag + pop_namespaces_restore + else + if @tags.empty? and @have_root + raise ParseException.new("Malformed XML: Extra tag at the end of the document (got '<#{tag}')", @source) + end + @tags.push( tag ) + end + @have_root = true + return [ :start_element, tag, attributes ] + end + else + text = @source.read_until("<") + if text.chomp!("<") + @source.position -= "<".bytesize + end + if @tags.empty? + unless /\A\s*\z/.match?(text) + if @have_root + raise ParseException.new("Malformed XML: Extra content at the end of the document (got '#{text}')", @source) + else + raise ParseException.new("Malformed XML: Content at the start of the document (got '#{text}')", @source) + end + end + return pull_event if @have_root + end + return [ :text, text ] + end + rescue REXML::UndefinedNamespaceException + raise + rescue REXML::ParseException + raise + rescue => error + raise REXML::ParseException.new( "Exception parsing", + @source, self, (error ? error : $!) ) + end + # NOTE: The end of the method never runs, because it is unreachable. + # All branches of code above have explicit unconditional return or raise statements. + end + private :pull_event + + def entity( reference, entities ) + return unless entities + + value = entities[ reference ] + return if value.nil? + + record_entity_expansion + unnormalize( value, entities ) + end + + # Escapes all possible entities + def normalize( input, entities=nil, entity_filter=nil ) + copy = input.clone + # Doing it like this rather than in a loop improves the speed + copy.gsub!( EREFERENCE, '&' ) + entities.each do |key, value| + copy.gsub!( value, "&#{key};" ) unless entity_filter and + entity_filter.include?(entity) + end if entities + copy.gsub!( EREFERENCE, '&' ) + DEFAULT_ENTITIES.each do |key, value| + copy.gsub!( value[3], value[1] ) + end + copy + end + + # Unescapes all possible entities + def unnormalize( string, entities=nil, filter=nil ) + if string.include?("\r") + rv = string.gsub( Private::CARRIAGE_RETURN_NEWLINE_PATTERN, "\n" ) + else + rv = string.dup + end + matches = rv.scan( REFERENCE_RE ) + return rv if matches.size == 0 + rv.gsub!( Private::CHARACTER_REFERENCES ) { + m=$1 + if m.start_with?("x") + code_point = Integer(m[1..-1], 16) + else + code_point = Integer(m, 10) + end + [code_point].pack('U*') + } + matches.collect!{|x|x[0]}.compact! + if filter + matches.reject! do |entity_reference| + filter.include?(entity_reference) + end + end + if matches.size > 0 + matches.tally.each do |entity_reference, n| + entity_expansion_count_before = @entity_expansion_count + entity_value = entity( entity_reference, entities ) + if entity_value + if n > 1 + entity_expansion_count_delta = + @entity_expansion_count - entity_expansion_count_before + record_entity_expansion(entity_expansion_count_delta * (n - 1)) + end + re = Private::DEFAULT_ENTITIES_PATTERNS[entity_reference] || /&#{entity_reference};/ + rv.gsub!( re, entity_value ) + if rv.bytesize > @entity_expansion_text_limit + raise "entity expansion has grown too large" + end + else + er = DEFAULT_ENTITIES[entity_reference] + rv.gsub!( er[0], er[2] ) if er + end + end + rv.gsub!( Private::DEFAULT_ENTITIES_PATTERNS['amp'], '&' ) + end + rv + end + + private + def add_namespace(prefix, uri) + @namespaces_restore_stack.last[prefix] = @namespaces[prefix] + if uri.nil? + @namespaces.delete(prefix) + else + @namespaces[prefix] = uri + end + end + + def push_namespaces_restore + namespaces_restore = {} + @namespaces_restore_stack.push(namespaces_restore) + namespaces_restore + end + + def pop_namespaces_restore + namespaces_restore = @namespaces_restore_stack.pop + namespaces_restore.each do |prefix, uri| + if uri.nil? + @namespaces.delete(prefix) + else + @namespaces[prefix] = uri + end + end + end + + def record_entity_expansion(delta=1) + @entity_expansion_count += delta + if @entity_expansion_count > @entity_expansion_limit + raise "number of entity expansions exceeded, processing aborted." + end + end + + def need_source_encoding_update?(xml_declaration_encoding) + return false if xml_declaration_encoding.nil? + return false if /\AUTF-16\z/i =~ xml_declaration_encoding + true + end + + def normalize_xml_declaration_encoding(xml_declaration_encoding) + /\AUTF-16(?:BE|LE)\z/i.match?(xml_declaration_encoding) ? "UTF-16" : nil + end + + def parse_name(base_error_message) + md = @source.match(Private::NAME_PATTERN, true) + unless md + if @source.match?(/\S/um) + message = "#{base_error_message}: invalid name" + else + message = "#{base_error_message}: name is missing" + end + raise REXML::ParseException.new(message, @source) + end + md[0] + end + + def parse_id(base_error_message, + accept_external_id:, + accept_public_id:) + if accept_external_id and (md = @source.match(EXTERNAL_ID_PUBLIC, true)) + pubid = system = nil + pubid_literal = md[1] + pubid = pubid_literal[1..-2] if pubid_literal # Remove quote + system_literal = md[2] + system = system_literal[1..-2] if system_literal # Remove quote + ["PUBLIC", pubid, system] + elsif accept_public_id and (md = @source.match(PUBLIC_ID, true)) + pubid = system = nil + pubid_literal = md[1] + pubid = pubid_literal[1..-2] if pubid_literal # Remove quote + ["PUBLIC", pubid, nil] + elsif accept_external_id and (md = @source.match(EXTERNAL_ID_SYSTEM, true)) + system = nil + system_literal = md[1] + system = system_literal[1..-2] if system_literal # Remove quote + ["SYSTEM", nil, system] + else + details = parse_id_invalid_details(accept_external_id: accept_external_id, + accept_public_id: accept_public_id) + message = "#{base_error_message}: #{details}" + raise REXML::ParseException.new(message, @source) + end + end + + def parse_id_invalid_details(accept_external_id:, + accept_public_id:) + public = /\A\s*PUBLIC/um + system = /\A\s*SYSTEM/um + if (accept_external_id or accept_public_id) and @source.match?(/#{public}/um) + if @source.match?(/#{public}(?:\s+[^'"]|\s*[\[>])/um) + return "public ID literal is missing" + end + unless @source.match?(/#{public}\s+#{PUBIDLITERAL}/um) + return "invalid public ID literal" + end + if accept_public_id + if @source.match?(/#{public}\s+#{PUBIDLITERAL}\s+[^'"]/um) + return "system ID literal is missing" + end + unless @source.match?(/#{public}\s+#{PUBIDLITERAL}\s+#{SYSTEMLITERAL}/um) + return "invalid system literal" + end + "garbage after system literal" + else + "garbage after public ID literal" + end + elsif accept_external_id and @source.match?(/#{system}/um) + if @source.match?(/#{system}(?:\s+[^'"]|\s*[\[>])/um) + return "system literal is missing" + end + unless @source.match?(/#{system}\s+#{SYSTEMLITERAL}/um) + return "invalid system literal" + end + "garbage after system literal" + else + unless @source.match?(/\A\s*(?:PUBLIC|SYSTEM)\s/um) + return "invalid ID type" + end + "ID type is missing" + end + end + + def process_comment + text = @source.read_until("-->") + unless text.chomp!("-->") + raise REXML::ParseException.new("Unclosed comment: Missing end '-->'", @source) + end + + if text.include? "--" or text.end_with?("-") + raise REXML::ParseException.new("Malformed comment", @source) + end + text + end + + def process_instruction + name = parse_name("Malformed XML: Invalid processing instruction node") + if name == "xml" + xml_declaration + else # PITarget + if @source.skip_spaces # e.g. <?name content?> + start_position = @source.position + content = @source.read_until("?>") + unless content.chomp!("?>") + @source.position = start_position + raise ParseException.new("Malformed XML: Unclosed processing instruction: <#{name}>", @source) + end + else # e.g. <?name?> + content = nil + unless @source.match?("?>", true) + raise ParseException.new("Malformed XML: Unclosed processing instruction: <#{name}>", @source) + end + end + [:processing_instruction, name, content] + end + end + + def xml_declaration + unless @version.nil? + raise ParseException.new("Malformed XML: XML declaration is duplicated", @source) + end + if @document_status + raise ParseException.new("Malformed XML: XML declaration is not at the start", @source) + end + unless @source.skip_spaces + raise ParseException.new("Malformed XML: XML declaration misses spaces before version", @source) + end + unless @source.match?("version", true) + raise ParseException.new("Malformed XML: XML declaration misses version", @source) + end + @version = parse_attribute_value_with_equal("xml") + unless @source.skip_spaces + unless @source.match?("?>", true) + raise ParseException.new("Malformed XML: Unclosed XML declaration", @source) + end + encoding = normalize_xml_declaration_encoding(@source.encoding) + return [ :xmldecl, @version, encoding, nil ] # e.g. <?xml version="1.0"?> + end + + if @source.match?("encoding", true) + encoding = parse_attribute_value_with_equal("xml") + unless @source.skip_spaces + unless @source.match?("?>", true) + raise ParseException.new("Malformed XML: Unclosed XML declaration", @source) + end + if need_source_encoding_update?(encoding) + @source.encoding = encoding + end + encoding ||= normalize_xml_declaration_encoding(@source.encoding) + return [ :xmldecl, @version, encoding, nil ] # e.g. <?xml version="1.1" encoding="UTF-8"?> + end + end + + if @source.match?("standalone", true) + standalone = parse_attribute_value_with_equal("xml") + case standalone + when "yes", "no" + else + raise ParseException.new("Malformed XML: XML declaration standalone is not yes or no : <#{standalone}>", @source) + end + end + @source.skip_spaces + unless @source.match?("?>", true) + raise ParseException.new("Malformed XML: Unclosed XML declaration", @source) + end + + if need_source_encoding_update?(encoding) + @source.encoding = encoding + end + encoding ||= normalize_xml_declaration_encoding(@source.encoding) + + # e.g. <?xml version="1.0" ?> + # <?xml version="1.1" encoding="UTF-8" ?> + # <?xml version="1.1" standalone="yes"?> + # <?xml version="1.1" encoding="UTF-8" standalone="yes" ?> + [ :xmldecl, @version, encoding, standalone ] + end + + if StringScanner::Version < "3.1.1" + def scan_quote + @source.match(/(['"])/, true)&.[](1) + end + else + def scan_quote + case @source.peek_byte + when 34 # '"'.ord + @source.scan_byte + '"' + when 39 # "'".ord + @source.scan_byte + "'" + else + nil + end + end + end + + def parse_attribute_value_with_equal(name) + unless @source.match?(Private::EQUAL_PATTERN, true) + message = "Missing attribute equal: <#{name}>" + raise REXML::ParseException.new(message, @source) + end + unless quote = scan_quote + message = "Missing attribute value start quote: <#{name}>" + raise REXML::ParseException.new(message, @source) + end + start_position = @source.position + value = @source.read_until(quote) + unless value.chomp!(quote) + @source.position = start_position + message = "Missing attribute value end quote: <#{name}>: <#{quote}>" + raise REXML::ParseException.new(message, @source) + end + value + end + + def parse_attributes(prefixes) + attributes = {} + expanded_names = {} + closed = false + while true + if @source.match?(">", true) + return attributes, closed + elsif @source.match?("/>", true) + closed = true + return attributes, closed + elsif match = @source.match(QNAME, true) + name = match[1] + prefix = match[2] + local_part = match[3] + value = parse_attribute_value_with_equal(name) + @source.skip_spaces + if prefix == "xmlns" + if local_part == "xml" + if value != Private::XML_PREFIXED_NAMESPACE + msg = "The 'xml' prefix must not be bound to any other namespace "+ + "(http://www.w3.org/TR/REC-xml-names/#ns-decl)" + raise REXML::ParseException.new( msg, @source, self ) + end + elsif local_part == "xmlns" + msg = "The 'xmlns' prefix must not be declared "+ + "(http://www.w3.org/TR/REC-xml-names/#ns-decl)" + raise REXML::ParseException.new( msg, @source, self) + end + add_namespace(local_part, value) + elsif prefix + prefixes << prefix unless prefix == "xml" + end + + if attributes[name] + msg = "Duplicate attribute #{name.inspect}" + raise REXML::ParseException.new(msg, @source, self) + end + + unless prefix == "xmlns" + uri = @namespaces[prefix] + expanded_name = [uri, local_part] + existing_prefix = expanded_names[expanded_name] + if existing_prefix + message = "Namespace conflict in adding attribute " + + "\"#{local_part}\": " + + "Prefix \"#{existing_prefix}\" = \"#{uri}\" and " + + "prefix \"#{prefix}\" = \"#{uri}\"" + raise REXML::ParseException.new(message, @source, self) + end + expanded_names[expanded_name] = prefix + end + + attributes[name] = value + else + message = "Invalid attribute name: <#{@source.buffer.split(%r{[/>\s]}).first}>" + raise REXML::ParseException.new(message, @source) + end + end + end + end + end +end + +=begin + case event[0] + when :start_element + when :text + when :end_element + when :processing_instruction + when :cdata + when :comment + when :xmldecl + when :start_doctype + when :end_doctype + when :externalentity + when :elementdecl + when :entity + when :attlistdecl + when :notationdecl + when :end_doctype + end +=end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/lightparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/lightparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/lightparser.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/lightparser.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,59 @@ +# frozen_string_literal: false +require_relative 'streamparser' +require_relative 'baseparser' +require_relative '../light/node' + +module REXML + module Parsers + class LightParser + def initialize stream + @stream = stream + @parser = REXML::Parsers::BaseParser.new( stream ) + end + + def add_listener( listener ) + @parser.add_listener( listener ) + end + + def rewind + @stream.rewind + @parser.stream = @stream + end + + def parse + root = context = [ :document ] + while true + event = @parser.pull + case event[0] + when :end_document + break + when :start_element, :start_doctype + new_node = event + context << new_node + new_node[1,0] = [context] + context = new_node + when :end_element, :end_doctype + context = context[1] + else + new_node = event + context << new_node + new_node[1,0] = [context] + end + end + root + end + end + + # An element is an array. The array contains: + # 0 The parent element + # 1 The tag name + # 2 A hash of attributes + # 3..-1 The child elements + # An element is an array of size > 3 + # Text is a String + # PIs are [ :processing_instruction, target, data ] + # Comments are [ :comment, data ] + # DocTypes are DocType structs + # The root is an array with XMLDecls, Text, DocType, Array, Text + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/pullparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/pullparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/pullparser.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/pullparser.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,213 @@ +# frozen_string_literal: false +require 'forwardable' + +require_relative '../parseexception' +require_relative 'baseparser' +require_relative '../xmltokens' + +module REXML + module Parsers + # = Using the Pull Parser + # <em>This API is experimental, and subject to change.</em> + # parser = PullParser.new( "<a>text<b att='val'/>txet</a>" ) + # while parser.has_next? + # res = parser.next + # puts res[1]['att'] if res.start_tag? and res[0] == 'b' + # end + # See the PullEvent class for information on the content of the results. + # The data is identical to the arguments passed for the various events to + # the StreamListener API. + # + # Notice that: + # parser = PullParser.new( "<a>BAD DOCUMENT" ) + # while parser.has_next? + # res = parser.next + # raise res[1] if res.error? + # end + # + # Nat Price gave me some good ideas for the API. + class PullParser + include XMLTokens + extend Forwardable + + def_delegators( :@parser, :has_next? ) + def_delegators( :@parser, :entity ) + def_delegators( :@parser, :empty? ) + def_delegators( :@parser, :source ) + + def initialize stream + @entities = {} + @listeners = nil + @parser = BaseParser.new( stream ) + @my_stack = [] + end + + def add_listener( listener ) + @listeners = [] unless @listeners + @listeners << listener + end + + def entity_expansion_count + @parser.entity_expansion_count + end + + def entity_expansion_limit=( limit ) + @parser.entity_expansion_limit = limit + end + + def entity_expansion_text_limit=( limit ) + @parser.entity_expansion_text_limit = limit + end + + def each + while has_next? + yield self.pull + end + end + + def peek depth=0 + if @my_stack.length <= depth + (depth - @my_stack.length + 1).times { + e = PullEvent.new(@parser.pull) + @my_stack.push(e) + } + end + @my_stack[depth] + end + + def pull + return @my_stack.shift if @my_stack.length > 0 + + event = @parser.pull + case event[0] + when :entitydecl + @entities[ event[1] ] = + event[2] unless event[2] =~ /PUBLIC|SYSTEM/ + when :text + unnormalized = @parser.unnormalize( event[1], @entities ) + event << unnormalized + end + PullEvent.new( event ) + end + + def unshift token + @my_stack.unshift token + end + + def reset + @parser.reset + end + end + + # A parsing event. The contents of the event are accessed as an +Array?, + # and the type is given either by the ...? methods, or by accessing the + # +type+ accessor. The contents of this object vary from event to event, + # but are identical to the arguments passed to +StreamListener+s for each + # event. + class PullEvent + # The type of this event. Will be one of :tag_start, :tag_end, :text, + # :processing_instruction, :comment, :doctype, :attlistdecl, :entitydecl, + # :notationdecl, :entity, :cdata, :xmldecl, or :error. + def initialize(arg) + @contents = arg + end + + def []( start, endd=nil) + if start.kind_of? Range + @contents.slice( start.begin+1 .. start.end ) + elsif start.kind_of? Numeric + if endd.nil? + @contents.slice( start+1 ) + else + @contents.slice( start+1, endd ) + end + else + raise "Illegal argument #{start.inspect} (#{start.class})" + end + end + + def event_type + @contents[0] + end + + # Content: [ String tag_name, Hash attributes ] + def start_element? + @contents[0] == :start_element + end + + # Content: [ String tag_name ] + def end_element? + @contents[0] == :end_element + end + + # Content: [ String raw_text, String unnormalized_text ] + def text? + @contents[0] == :text + end + + # Content: [ String text ] + def instruction? + @contents[0] == :processing_instruction + end + + # Content: [ String text ] + def comment? + @contents[0] == :comment + end + + # Content: [ String name, String pub_sys, String long_name, String uri ] + def doctype? + @contents[0] == :start_doctype + end + + # Content: [ String text ] + def attlistdecl? + @contents[0] == :attlistdecl + end + + # Content: [ String text ] + def elementdecl? + @contents[0] == :elementdecl + end + + # Due to the wonders of DTDs, an entity declaration can be just about + # anything. There's no way to normalize it; you'll have to interpret the + # content yourself. However, the following is true: + # + # * If the entity declaration is an internal entity: + # [ String name, String value ] + # Content: [ String text ] + def entitydecl? + @contents[0] == :entitydecl + end + + # Content: [ String text ] + def notationdecl? + @contents[0] == :notationdecl + end + + # Content: [ String text ] + def entity? + @contents[0] == :entity + end + + # Content: [ String text ] + def cdata? + @contents[0] == :cdata + end + + # Content: [ String version, String encoding, String standalone ] + def xmldecl? + @contents[0] == :xmldecl + end + + def error? + @contents[0] == :error + end + + def inspect + @contents[0].to_s + ": " + @contents[1..-1].inspect + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/sax2parser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/sax2parser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/sax2parser.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/sax2parser.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,270 @@ +# frozen_string_literal: false +require_relative 'baseparser' +require_relative '../parseexception' +require_relative '../namespace' +require_relative '../text' + +module REXML + module Parsers + # SAX2Parser + class SAX2Parser + def initialize source + @parser = BaseParser.new(source) + @listeners = [] + @procs = [] + @namespace_stack = [] + @has_listeners = false + @tag_stack = [] + @entities = {} + end + + def source + @parser.source + end + + def entity_expansion_count + @parser.entity_expansion_count + end + + def entity_expansion_limit=( limit ) + @parser.entity_expansion_limit = limit + end + + def entity_expansion_text_limit=( limit ) + @parser.entity_expansion_text_limit = limit + end + + def add_listener( listener ) + @parser.add_listener( listener ) + end + + # Listen arguments: + # + # Symbol, Array, Block + # Listen to Symbol events on Array elements + # Symbol, Block + # Listen to Symbol events + # Array, Listener + # Listen to all events on Array elements + # Array, Block + # Listen to :start_element events on Array elements + # Listener + # Listen to All events + # + # Symbol can be one of: :start_element, :end_element, + # :start_prefix_mapping, :end_prefix_mapping, :characters, + # :processing_instruction, :doctype, :attlistdecl, :elementdecl, + # :entitydecl, :notationdecl, :cdata, :xmldecl, :comment + # + # There is an additional symbol that can be listened for: :progress. + # This will be called for every event generated, passing in the current + # stream position. + # + # Array contains regular expressions or strings which will be matched + # against fully qualified element names. + # + # Listener must implement the methods in SAX2Listener + # + # Block will be passed the same arguments as a SAX2Listener method would + # be, where the method name is the same as the matched Symbol. + # See the SAX2Listener for more information. + def listen( *args, &blok ) + if args[0].kind_of? Symbol + if args.size == 2 + args[1].each { |match| @procs << [args[0], match, blok] } + else + add( [args[0], nil, blok] ) + end + elsif args[0].kind_of? Array + if args.size == 2 + args[0].each { |match| add( [nil, match, args[1]] ) } + else + args[0].each { |match| add( [ :start_element, match, blok ] ) } + end + else + add([nil, nil, args[0]]) + end + end + + def deafen( listener=nil, &blok ) + if listener + @listeners.delete_if {|item| item[-1] == listener } + @has_listeners = false if @listeners.size == 0 + else + @procs.delete_if {|item| item[-1] == blok } + end + end + + def parse + @procs.each { |sym,match,block| block.call if sym == :start_document } + @listeners.each { |sym,match,block| + block.start_document if sym == :start_document or sym.nil? + } + context = [] + while true + event = @parser.pull + case event[0] + when :end_document + handle( :end_document ) + break + when :start_doctype + handle( :doctype, *event[1..-1]) + when :end_doctype + context = context[1] + when :start_element + @tag_stack.push(event[1]) + # find the observers for namespaces + procs = get_procs( :start_prefix_mapping, event[1] ) + listeners = get_listeners( :start_prefix_mapping, event[1] ) + if procs or listeners + # break out the namespace declarations + # The attributes live in event[2] + event[2].each {|n, v| event[2][n] = @parser.normalize(v)} + nsdecl = event[2].find_all { |n, value| n =~ /^xmlns(:|$)/ } + nsdecl.collect! { |n, value| [ n[6..-1], value ] } + @namespace_stack.push({}) + nsdecl.each do |n,v| + @namespace_stack[-1][n] = v + # notify observers of namespaces + procs.each { |ob| ob.call( n, v ) } if procs + listeners.each { |ob| ob.start_prefix_mapping(n, v) } if listeners + end + end + event[1] =~ Namespace::NAMESPLIT + prefix = $1 + local = $2 + uri = get_namespace(prefix) + # find the observers for start_element + procs = get_procs( :start_element, event[1] ) + listeners = get_listeners( :start_element, event[1] ) + # notify observers + procs.each { |ob| ob.call( uri, local, event[1], event[2] ) } if procs + listeners.each { |ob| + ob.start_element( uri, local, event[1], event[2] ) + } if listeners + when :end_element + @tag_stack.pop + event[1] =~ Namespace::NAMESPLIT + prefix = $1 + local = $2 + uri = get_namespace(prefix) + # find the observers for start_element + procs = get_procs( :end_element, event[1] ) + listeners = get_listeners( :end_element, event[1] ) + # notify observers + procs.each { |ob| ob.call( uri, local, event[1] ) } if procs + listeners.each { |ob| + ob.end_element( uri, local, event[1] ) + } if listeners + + namespace_mapping = @namespace_stack.pop + # find the observers for namespaces + procs = get_procs( :end_prefix_mapping, event[1] ) + listeners = get_listeners( :end_prefix_mapping, event[1] ) + if procs or listeners + namespace_mapping.each do |ns_prefix, ns_uri| + # notify observers of namespaces + procs.each { |ob| ob.call( ns_prefix ) } if procs + listeners.each { |ob| ob.end_prefix_mapping(ns_prefix) } if listeners + end + end + when :text + unnormalized = @parser.unnormalize( event[1], @entities ) + handle( :characters, unnormalized ) + when :entitydecl + handle_entitydecl( event ) + when :processing_instruction, :comment, :attlistdecl, + :elementdecl, :cdata, :notationdecl, :xmldecl + handle( *event ) + end + handle( :progress, @parser.position ) + end + end + + private + def handle( symbol, *arguments ) + tag = @tag_stack[-1] + procs = get_procs( symbol, tag ) + listeners = get_listeners( symbol, tag ) + # notify observers + procs.each { |ob| ob.call( *arguments ) } if procs + listeners.each { |l| + l.send( symbol.to_s, *arguments ) + } if listeners + end + + def handle_entitydecl( event ) + @entities[ event[1] ] = event[2] if event.size == 3 + parameter_reference_p = false + case event[2] + when "SYSTEM" + if event.size == 5 + if event.last == "%" + parameter_reference_p = true + else + event[4, 0] = "NDATA" + end + end + when "PUBLIC" + if event.size == 6 + if event.last == "%" + parameter_reference_p = true + else + event[5, 0] = "NDATA" + end + end + else + parameter_reference_p = (event.size == 4) + end + event[1, 0] = event.pop if parameter_reference_p + handle( event[0], event[1..-1] ) + end + + # The following methods are duplicates, but it is faster than using + # a helper + def get_procs( symbol, name ) + return nil if @procs.size == 0 + @procs.find_all do |sym, match, block| + ( + (sym.nil? or symbol == sym) and + ((name.nil? and match.nil?) or match.nil? or ( + (name == match) or + (match.kind_of? Regexp and name =~ match) + ) + ) + ) + end.collect{|x| x[-1]} + end + def get_listeners( symbol, name ) + return nil if @listeners.size == 0 + @listeners.find_all do |sym, match, block| + ( + (sym.nil? or symbol == sym) and + ((name.nil? and match.nil?) or match.nil? or ( + (name == match) or + (match.kind_of? Regexp and name =~ match) + ) + ) + ) + end.collect{|x| x[-1]} + end + + def add( pair ) + if pair[-1].respond_to? :call + @procs << pair unless @procs.include? pair + else + @listeners << pair unless @listeners.include? pair + @has_listeners = true + end + end + + def get_namespace( prefix ) + return nil if @namespace_stack.empty? + + uris = (@namespace_stack.find_all { |ns| not ns[prefix].nil? }) || + (@namespace_stack.find { |ns| not ns[nil].nil? }) + uris[-1][prefix] unless uris.nil? or 0 == uris.size + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/streamparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/streamparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/streamparser.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/streamparser.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,67 @@ +# frozen_string_literal: false +require_relative "baseparser" + +module REXML + module Parsers + class StreamParser + def initialize source, listener + @listener = listener + @parser = BaseParser.new( source ) + @entities = {} + end + + def add_listener( listener ) + @parser.add_listener( listener ) + end + + def entity_expansion_count + @parser.entity_expansion_count + end + + def entity_expansion_limit=( limit ) + @parser.entity_expansion_limit = limit + end + + def entity_expansion_text_limit=( limit ) + @parser.entity_expansion_text_limit = limit + end + + def parse + # entity string + while true + event = @parser.pull + case event[0] + when :end_document + return + when :start_element + attrs = event[2].each do |n, v| + event[2][n] = @parser.unnormalize( v ) + end + @listener.tag_start( event[1], attrs ) + when :end_element + @listener.tag_end( event[1] ) + when :text + unnormalized = @parser.unnormalize( event[1], @entities ) + @listener.text( unnormalized ) + when :processing_instruction + @listener.instruction( *event[1,2] ) + when :start_doctype + @listener.doctype( *event[1..-1] ) + when :end_doctype + # FIXME: remove this condition for milestone:3.2 + @listener.doctype_end if @listener.respond_to? :doctype_end + when :comment, :attlistdecl, :cdata, :xmldecl, :elementdecl + @listener.send( event[0].to_s, *event[1..-1] ) + when :entitydecl, :notationdecl + @entities[ event[1] ] = event[2] if event.size == 3 + @listener.send( event[0].to_s, event[1..-1] ) + when :externalentity + entity_reference = event[1] + content = entity_reference.gsub(/\A%|;\z/, "") + @listener.entity(content) + end + end + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/treeparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/treeparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/treeparser.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/treeparser.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,89 @@ +# frozen_string_literal: false +require_relative '../validation/validationexception' +require_relative '../undefinednamespaceexception' + +module REXML + module Parsers + class TreeParser + def initialize( source, build_context = Document.new ) + @build_context = build_context + @parser = Parsers::BaseParser.new( source ) + end + + def add_listener( listener ) + @parser.add_listener( listener ) + end + + def parse + entities = nil + begin + while true + event = @parser.pull + #STDERR.puts "TREEPARSER GOT #{event.inspect}" + case event[0] + when :end_document + return + when :start_element + el = @build_context = @build_context.add_element( event[1] ) + event[2].each do |key, value| + el.attributes[key]=Attribute.new(key,value,self) + end + when :end_element + @build_context = @build_context.parent + when :text + if @build_context[-1].instance_of? Text + @build_context[-1] << event[1] + else + @build_context.add( + Text.new(event[1], @build_context.whitespace, nil, true) + ) unless ( + @build_context.ignore_whitespace_nodes and + event[1].strip.size==0 + ) + end + when :comment + c = Comment.new( event[1] ) + @build_context.add( c ) + when :cdata + c = CData.new( event[1] ) + @build_context.add( c ) + when :processing_instruction + @build_context.add( Instruction.new( event[1], event[2] ) ) + when :end_doctype + entities.each { |k,v| entities[k] = @build_context.entities[k].value } + @build_context = @build_context.parent + when :start_doctype + doctype = DocType.new( event[1..-1], @build_context ) + @build_context = doctype + entities = {} + when :attlistdecl + n = AttlistDecl.new( event[1..-1] ) + @build_context.add( n ) + when :externalentity + n = ExternalEntity.new( event[1] ) + @build_context.add( n ) + when :elementdecl + n = ElementDecl.new( event[1] ) + @build_context.add(n) + when :entitydecl + entities[ event[1] ] = event[2] unless event[2] =~ /PUBLIC|SYSTEM/ + @build_context.add(Entity.new(event)) + when :notationdecl + n = NotationDecl.new( *event[1..-1] ) + @build_context.add( n ) + when :xmldecl + x = XMLDecl.new( event[1], event[2], event[3] ) + @build_context.add( x ) + end + end + rescue REXML::Validation::ValidationException + raise + rescue REXML::ParseException + raise + rescue + raise ParseException.new( $!.message, @parser.source, @parser, $! ) + end + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/ultralightparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/ultralightparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/ultralightparser.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/ultralightparser.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,57 @@ +# frozen_string_literal: false +require_relative 'streamparser' +require_relative 'baseparser' + +module REXML + module Parsers + class UltraLightParser + def initialize stream + @stream = stream + @parser = REXML::Parsers::BaseParser.new( stream ) + end + + def add_listener( listener ) + @parser.add_listener( listener ) + end + + def rewind + @stream.rewind + @parser.stream = @stream + end + + def parse + root = context = [] + while true + event = @parser.pull + case event[0] + when :end_document + break + when :end_doctype + context = context[1] + when :start_element, :start_doctype + context << event + event[1,0] = [context] + context = event + when :end_element + context = context[1] + else + context << event + end + end + root + end + end + + # An element is an array. The array contains: + # 0 The parent element + # 1 The tag name + # 2 A hash of attributes + # 3..-1 The child elements + # An element is an array of size > 3 + # Text is a String + # PIs are [ :processing_instruction, target, data ] + # Comments are [ :comment, data ] + # DocTypes are DocType structs + # The root is an array with XMLDecls, Text, DocType, Array, Text + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/xpathparser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/xpathparser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/xpathparser.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/parsers/xpathparser.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,739 @@ +# frozen_string_literal: false + +require_relative '../namespace' +require_relative '../xmltokens' + +module REXML + module Parsers + # You don't want to use this class. Really. Use XPath, which is a wrapper + # for this class. Believe me. You don't want to poke around in here. + # There is strange, dark magic at work in this code. Beware. Go back! Go + # back while you still can! + class XPathParser + include XMLTokens + LITERAL = /^'([^']*)'|^"([^"]*)"/u + + def namespaces=( namespaces ) + Functions::namespace_context = namespaces + @namespaces = namespaces + end + + def parse path + path = path.dup + path.gsub!(/([\(\[])\s+/, '\1') # Strip ignorable spaces + path.gsub!( /\s+([\]\)])/, '\1') + parsed = [] + rest = OrExpr(path, parsed) + if rest + unless rest.strip.empty? + raise ParseException.new("Garbage component exists at the end: " + + "<#{rest}>: <#{path}>") + end + end + parsed + end + + def predicate path + parsed = [] + Predicate( "[#{path}]", parsed ) + parsed + end + + def abbreviate(path_or_parsed) + if path_or_parsed.kind_of?(String) + parsed = parse(path_or_parsed) + else + parsed = path_or_parsed + end + components = [] + component = nil + while parsed.size > 0 + op = parsed.shift + case op + when :node + component << "node()" + when :attribute + component = "@" + components << component + when :child + component = "" + components << component + when :descendant_or_self + next_op = parsed[0] + if next_op == :node + parsed.shift + component = "" + components << component + else + component = "descendant-or-self::" + components << component + end + when :self + next_op = parsed[0] + if next_op == :node + parsed.shift + components << "." + else + component = "self::" + components << component + end + when :parent + next_op = parsed[0] + if next_op == :node + parsed.shift + components << ".." + else + component = "parent::" + components << component + end + when :any + component << "*" + when :text + component << "text()" + when :following, :following_sibling, + :ancestor, :ancestor_or_self, :descendant, + :namespace, :preceding, :preceding_sibling + component = op.to_s.tr("_", "-") << "::" + components << component + when :qname + prefix = parsed.shift + name = parsed.shift + component << prefix+":" if prefix.size > 0 + component << name + when :predicate + component << '[' + component << predicate_to_path(parsed.shift) {|x| abbreviate(x)} + component << ']' + when :document + components << "" + when :function + component << parsed.shift + component << "( " + component << predicate_to_path(parsed.shift[0]) {|x| abbreviate(x)} + component << " )" + when :literal + component << quote_literal(parsed.shift) + else + component << "UNKNOWN(" + component << op.inspect + component << ")" + end + end + case components + when [""] + "/" + when ["", ""] + "//" + else + components.join("/") + end + end + + def expand(path_or_parsed) + if path_or_parsed.kind_of?(String) + parsed = parse(path_or_parsed) + else + parsed = path_or_parsed + end + path = "" + document = false + while parsed.size > 0 + op = parsed.shift + case op + when :node + path << "node()" + when :attribute, :child, :following, :following_sibling, + :ancestor, :ancestor_or_self, :descendant, :descendant_or_self, + :namespace, :preceding, :preceding_sibling, :self, :parent + path << "/" unless path.size == 0 + path << op.to_s.tr("_", "-") + path << "::" + when :any + path << "*" + when :qname + prefix = parsed.shift + name = parsed.shift + path << prefix+":" if prefix.size > 0 + path << name + when :predicate + path << '[' + path << predicate_to_path( parsed.shift ) { |x| expand(x) } + path << ']' + when :document + document = true + else + path << "UNKNOWN(" + path << op.inspect + path << ")" + end + end + path = "/"+path if document + path + end + + def predicate_to_path(parsed, &block) + path = "" + case parsed[0] + when :and, :or, :mult, :plus, :minus, :neq, :eq, :lt, :gt, :lteq, :gteq, :div, :mod, :union + op = parsed.shift + case op + when :eq + op = "=" + when :lt + op = "<" + when :gt + op = ">" + when :lteq + op = "<=" + when :gteq + op = ">=" + when :neq + op = "!=" + when :union + op = "|" + end + left = predicate_to_path( parsed.shift, &block ) + right = predicate_to_path( parsed.shift, &block ) + path << left + path << " " + path << op.to_s + path << " " + path << right + when :function + parsed.shift + name = parsed.shift + path << name + path << "(" + parsed.shift.each_with_index do |argument, i| + path << ", " if i > 0 + path << predicate_to_path(argument, &block) + end + path << ")" + when :literal + parsed.shift + path << quote_literal(parsed.shift) + else + path << yield( parsed ) + end + path.squeeze(" ") + end + # For backward compatibility + alias_method :preciate_to_string, :predicate_to_path + + private + def quote_literal( literal ) + case literal + when String + # XPath 1.0 does not support escape characters. + # Assumes literal does not contain both single and double quotes. + if literal.include?("'") + "\"#{literal}\"" + else + "'#{literal}'" + end + else + literal.inspect + end + end + + #LocationPath + # | RelativeLocationPath + # | '/' RelativeLocationPath? + # | '//' RelativeLocationPath + def LocationPath path, parsed + path = path.lstrip + if path[0] == ?/ + parsed << :document + if path[1] == ?/ + parsed << :descendant_or_self + parsed << :node + path = path[2..-1] + else + path = path[1..-1] + end + end + RelativeLocationPath( path, parsed ) if path.size > 0 + end + + #RelativeLocationPath + # | Step + # | (AXIS_NAME '::' | '@' | '') AxisSpecifier + # NodeTest + # Predicate + # | '.' | '..' AbbreviatedStep + # | RelativeLocationPath '/' Step + # | RelativeLocationPath '//' Step + AXIS = /^(ancestor|ancestor-or-self|attribute|child|descendant|descendant-or-self|following|following-sibling|namespace|parent|preceding|preceding-sibling|self)::/ + def RelativeLocationPath path, parsed + loop do + original_path = path + path = path.lstrip + + return original_path if path.empty? + + # (axis or @ or <child::>) nodetest predicate > + # OR > / Step + # (. or ..) > + if path[0] == ?. + if path[1] == ?. + parsed << :parent + parsed << :node + path = path[2..-1] + else + parsed << :self + parsed << :node + path = path[1..-1] + end + else + path_before_axis_specifier = path + parsed_not_abberviated = [] + if path[0] == ?@ + parsed_not_abberviated << :attribute + path = path[1..-1] + # Goto Nodetest + elsif path =~ AXIS + parsed_not_abberviated << $1.tr('-','_').intern + path = $' + # Goto Nodetest + else + parsed_not_abberviated << :child + end + + path_before_node_test = path + path = NodeTest(path, parsed_not_abberviated) + if path == path_before_node_test + return path_before_axis_specifier + end + path = Predicate(path, parsed_not_abberviated) + + parsed.concat(parsed_not_abberviated) + end + + original_path = path + path = path.lstrip + return original_path if path.empty? + + return original_path if path[0] != ?/ + + if path[1] == ?/ + parsed << :descendant_or_self + parsed << :node + path = path[2..-1] + else + path = path[1..-1] + end + end + end + + # Returns a 1-1 map of the nodeset + # The contents of the resulting array are either: + # true/false, if a positive match + # String, if a name match + #NodeTest + # | ('*' | NCNAME ':' '*' | QNAME) NameTest + # | '*' ':' NCNAME NameTest since XPath 2.0 + # | NODE_TYPE '(' ')' NodeType + # | PI '(' LITERAL ')' PI + # | '[' expr ']' Predicate + PREFIX_WILDCARD = /^\*:(#{NCNAME_STR})/u + LOCAL_NAME_WILDCARD = /^(#{NCNAME_STR}):\*/u + QNAME = Namespace::NAMESPLIT + NODE_TYPE = /^(comment|text|node)\(\s*\)/m + PI = /^processing-instruction\(/ + def NodeTest path, parsed + original_path = path + path = path.lstrip + case path + when PREFIX_WILDCARD + prefix = nil + name = $1 + path = $' + parsed << :qname + parsed << prefix + parsed << name + when /^\*/ + path = $' + parsed << :any + when NODE_TYPE + type = $1 + path = $' + parsed << type.tr('-', '_').intern + when PI + path = $' + literal = nil + if path =~ /^\s*\)/ + path = $' + else + path =~ LITERAL + literal = $1 + path = $' + raise ParseException.new("Missing ')' after processing instruction") if path[0] != ?) + path = path[1..-1] + end + parsed << :processing_instruction + parsed << (literal || '') + when LOCAL_NAME_WILDCARD + prefix = $1 + path = $' + parsed << :namespace + parsed << prefix + when QNAME + prefix = $1 + name = $2 + path = $' + prefix = "" unless prefix + parsed << :qname + parsed << prefix + parsed << name + else + path = original_path + end + path + end + + # Filters the supplied nodeset on the predicate(s) + def Predicate path, parsed + original_path = path + path = path.lstrip + return original_path unless path[0] == ?[ + predicates = [] + while path[0] == ?[ + path, expr = get_group(path) + predicates << expr[1..-2] if expr + end + predicates.each{ |pred| + preds = [] + parsed << :predicate + parsed << preds + OrExpr(pred, preds) + } + path + end + + # The following return arrays of true/false, a 1-1 mapping of the + # supplied nodeset, except for axe(), which returns a filtered + # nodeset + + #| OrExpr S 'or' S AndExpr + #| AndExpr + def OrExpr path, parsed + n = [] + rest = AndExpr( path, n ) + if rest != path + while rest =~ /^\s*( or )/ + n = [ :or, n, [] ] + rest = AndExpr( $', n[-1] ) + end + end + if parsed.size == 0 and n.size != 0 + parsed.replace(n) + elsif n.size > 0 + parsed << n + end + rest + end + + #| AndExpr S 'and' S EqualityExpr + #| EqualityExpr + def AndExpr path, parsed + n = [] + rest = EqualityExpr( path, n ) + if rest != path + while rest =~ /^\s*( and )/ + n = [ :and, n, [] ] + rest = EqualityExpr( $', n[-1] ) + end + end + if parsed.size == 0 and n.size != 0 + parsed.replace(n) + elsif n.size > 0 + parsed << n + end + rest + end + + #| EqualityExpr ('=' | '!=') RelationalExpr + #| RelationalExpr + def EqualityExpr path, parsed + n = [] + rest = RelationalExpr( path, n ) + if rest != path + while rest =~ /^\s*(!?=)\s*/ + if $1[0] == ?! + n = [ :neq, n, [] ] + else + n = [ :eq, n, [] ] + end + rest = RelationalExpr( $', n[-1] ) + end + end + if parsed.size == 0 and n.size != 0 + parsed.replace(n) + elsif n.size > 0 + parsed << n + end + rest + end + + #| RelationalExpr ('<' | '>' | '<=' | '>=') AdditiveExpr + #| AdditiveExpr + def RelationalExpr path, parsed + n = [] + rest = AdditiveExpr( path, n ) + if rest != path + while rest =~ /^\s*([<>]=?)\s*/ + if $1[0] == ?< + sym = "lt" + else + sym = "gt" + end + sym << "eq" if $1[-1] == ?= + n = [ sym.intern, n, [] ] + rest = AdditiveExpr( $', n[-1] ) + end + end + if parsed.size == 0 and n.size != 0 + parsed.replace(n) + elsif n.size > 0 + parsed << n + end + rest + end + + #| AdditiveExpr ('+' | '-') MultiplicativeExpr + #| MultiplicativeExpr + def AdditiveExpr path, parsed + n = [] + rest = MultiplicativeExpr( path, n ) + if rest != path + while rest =~ /^\s*(\+|-)\s*/ + if $1[0] == ?+ + n = [ :plus, n, [] ] + else + n = [ :minus, n, [] ] + end + rest = MultiplicativeExpr( $', n[-1] ) + end + end + if parsed.size == 0 and n.size != 0 + parsed.replace(n) + elsif n.size > 0 + parsed << n + end + rest + end + + #| MultiplicativeExpr ('*' | S ('div' | 'mod') S) UnaryExpr + #| UnaryExpr + def MultiplicativeExpr path, parsed + n = [] + rest = UnaryExpr( path, n ) + if rest != path + while rest =~ /^\s*(\*| div | mod )\s*/ + if $1[0] == ?* + n = [ :mult, n, [] ] + elsif $1.include?( "div" ) + n = [ :div, n, [] ] + else + n = [ :mod, n, [] ] + end + rest = UnaryExpr( $', n[-1] ) + end + end + if parsed.size == 0 and n.size != 0 + parsed.replace(n) + elsif n.size > 0 + parsed << n + end + rest + end + + #| '-' UnaryExpr + #| UnionExpr + def UnaryExpr path, parsed + path =~ /^(\-*)/ + path = $' + if $1 and (($1.size % 2) != 0) + mult = -1 + else + mult = 1 + end + parsed << :neg if mult < 0 + + n = [] + path = UnionExpr( path, n ) + parsed.concat( n ) + path + end + + #| UnionExpr '|' PathExpr + #| PathExpr + def UnionExpr path, parsed + n = [] + rest = PathExpr( path, n ) + if rest != path + while rest =~ /^\s*(\|)\s*/ + n = [ :union, n, [] ] + rest = PathExpr( $', n[-1] ) + end + end + if parsed.size == 0 and n.size != 0 + parsed.replace( n ) + elsif n.size > 0 + parsed << n + end + rest + end + + #| LocationPath + #| FilterExpr ('/' | '//') RelativeLocationPath + def PathExpr path, parsed + path = path.lstrip + n = [] + rest = FilterExpr( path, n ) + if rest != path + if rest and rest[0] == ?/ + rest = RelativeLocationPath(rest, n) + parsed.concat(n) + return rest + end + end + rest = LocationPath(rest, n) if rest =~ /\A[\/\.\@\[\w*]/ + parsed.concat(n) + rest + end + + #| FilterExpr Predicate + #| PrimaryExpr + def FilterExpr path, parsed + n = [] + path_before_primary_expr = path + path = PrimaryExpr(path, n) + return path_before_primary_expr if path == path_before_primary_expr + path = Predicate(path, n) + parsed.concat(n) + path + end + + #| VARIABLE_REFERENCE + #| '(' expr ')' + #| LITERAL + #| NUMBER + #| FunctionCall + VARIABLE_REFERENCE = /^\$(#{NAME_STR})/u + NUMBER = /^(\d*\.?\d+)/ + NT = /^comment|text|processing-instruction|node$/ + def PrimaryExpr path, parsed + case path + when VARIABLE_REFERENCE + varname = $1 + path = $' + parsed << :variable + parsed << varname + #arry << @variables[ varname ] + when /^(\w[-\w]*)(?:\()/ + fname = $1 + tmp = $' + return path if fname =~ NT + path = tmp + parsed << :function + parsed << fname + path = FunctionCall(path, parsed) + when NUMBER + varname = $1.nil? ? $2 : $1 + path = $' + parsed << :literal + parsed << (varname.include?('.') ? varname.to_f : varname.to_i) + when LITERAL + varname = $1.nil? ? $2 : $1 + path = $' + parsed << :literal + parsed << varname + when /^\(/ #/ + path, contents = get_group(path) + contents = contents[1..-2] + n = [] + OrExpr( contents, n ) + parsed.concat(n) + end + path + end + + #| FUNCTION_NAME '(' ( expr ( ',' expr )* )? ')' + def FunctionCall rest, parsed + path, arguments = parse_args(rest) + argset = [] + for argument in arguments + args = [] + OrExpr( argument, args ) + argset << args + end + parsed << argset + path + end + + # get_group( '[foo]bar' ) -> ['bar', '[foo]'] + def get_group string + ind = 0 + depth = 0 + st = string[0,1] + en = (st == "(" ? ")" : "]") + begin + case string[ind,1] + when st + depth += 1 + when en + depth -= 1 + end + ind += 1 + end while depth > 0 and ind < string.length + return nil unless depth==0 + [string[ind..-1], string[0..ind-1]] + end + + def parse_args( string ) + arguments = [] + ind = 0 + inquot = false + inapos = false + depth = 1 + begin + case string[ind] + when ?" + inquot = !inquot unless inapos + when ?' + inapos = !inapos unless inquot + else + unless inquot or inapos + case string[ind] + when ?( + depth += 1 + if depth == 1 + string = string[1..-1] + ind -= 1 + end + when ?) + depth -= 1 + if depth == 0 + s = string[0,ind].strip + arguments << s unless s == "" + string = string[ind+1..-1] + end + when ?, + if depth == 1 + s = string[0,ind].strip + arguments << s unless s == "" + string = string[ind+1..-1] + ind = -1 + end + end + end + end + ind += 1 + end while depth > 0 and ind < string.length + return nil unless depth==0 + [string,arguments] + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/quickpath.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/quickpath.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/quickpath.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/quickpath.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,267 @@ +# frozen_string_literal: false +require_relative 'functions' +require_relative 'xmltokens' + +module REXML + class QuickPath + include Functions + include XMLTokens + + # A base Hash object to be used when initializing a + # default empty namespaces set. + EMPTY_HASH = {} + + def QuickPath::first element, path, namespaces=EMPTY_HASH + match(element, path, namespaces)[0] + end + + def QuickPath::each element, path, namespaces=EMPTY_HASH, &block + path = "*" unless path + match(element, path, namespaces).each( &block ) + end + + def QuickPath::match element, path, namespaces=EMPTY_HASH + raise "nil is not a valid xpath" unless path + results = nil + Functions::namespace_context = namespaces + case path + when /^\/([^\/]|$)/u + # match on root + path = path[1..-1] + return [element.root.parent] if path == '' + results = filter([element.root], path) + when /^[-\w]*::/u + results = filter([element], path) + when /^\*/u + results = filter(element.to_a, path) + when /^[\[!\w:]/u + # match on child + children = element.to_a + results = filter(children, path) + else + results = filter([element], path) + end + results + end + + # Given an array of nodes it filters the array based on the path. The + # result is that when this method returns, the array will contain elements + # which match the path + def QuickPath::filter elements, path + return elements if path.nil? or path == '' or elements.size == 0 + case path + when /^\/\//u # Descendant + axe( elements, "descendant-or-self", $' ) + when /^\/?\b(\w[-\w]*)\b::/u # Axe + axe( elements, $1, $' ) + when /^\/(?=\b([:!\w][-\.\w]*:)?[-!\*\.\w]*\b([^:(]|$)|\*)/u # Child + rest = $' + results = [] + elements.each do |element| + results |= filter( element.to_a, rest ) + end + results + when /^\/?(\w[-\w]*)\(/u # / Function + function( elements, $1, $' ) + when Namespace::NAMESPLIT # Element name + name = $2 + ns = $1 + rest = $' + elements.delete_if do |element| + !(element.kind_of? Element and + (element.expanded_name == name or + (element.name == name and + element.namespace == Functions.namespace_context[ns]))) + end + filter( elements, rest ) + when /^\/\[/u + matches = [] + elements.each do |element| + matches |= predicate( element.to_a, path[1..-1] ) if element.kind_of? Element + end + matches + when /^\[/u # Predicate + predicate( elements, path ) + when /^\/?\.\.\./u # Ancestor + axe( elements, "ancestor", $' ) + when /^\/?\.\./u # Parent + filter( elements.collect{|e|e.parent}, $' ) + when /^\/?\./u # Self + filter( elements, $' ) + when /^\*/u # Any + results = [] + elements.each do |element| + results |= filter( [element], $' ) if element.kind_of? Element + #if element.kind_of? Element + # children = element.to_a + # children.delete_if { |child| !child.kind_of?(Element) } + # results |= filter( children, $' ) + #end + end + results + else + [] + end + end + + def QuickPath::axe( elements, axe_name, rest ) + matches = [] + matches = filter( elements.dup, rest ) if axe_name =~ /-or-self$/u + case axe_name + when /^descendant/u + elements.each do |element| + matches |= filter( element.to_a, "descendant-or-self::#{rest}" ) if element.kind_of? Element + end + when /^ancestor/u + elements.each do |element| + while element.parent + matches << element.parent + element = element.parent + end + end + matches = filter( matches, rest ) + when "self" + matches = filter( elements, rest ) + when "child" + elements.each do |element| + matches |= filter( element.to_a, rest ) if element.kind_of? Element + end + when "attribute" + elements.each do |element| + matches << element.attributes[ rest ] if element.kind_of? Element + end + when "parent" + matches = filter(elements.collect{|element| element.parent}.uniq, rest) + when "following-sibling" + matches = filter(elements.collect{|element| element.next_sibling}.uniq, + rest) + when "previous-sibling" + matches = filter(elements.collect{|element| + element.previous_sibling}.uniq, rest ) + end + matches.uniq + end + + OPERAND_ = '((?=(?:(?!and|or).)*[^\s<>=])[^\s<>=]+)' + # A predicate filters a node-set with respect to an axis to produce a + # new node-set. For each node in the node-set to be filtered, the + # PredicateExpr is evaluated with that node as the context node, with + # the number of nodes in the node-set as the context size, and with the + # proximity position of the node in the node-set with respect to the + # axis as the context position; if PredicateExpr evaluates to true for + # that node, the node is included in the new node-set; otherwise, it is + # not included. + # + # A PredicateExpr is evaluated by evaluating the Expr and converting + # the result to a boolean. If the result is a number, the result will + # be converted to true if the number is equal to the context position + # and will be converted to false otherwise; if the result is not a + # number, then the result will be converted as if by a call to the + # boolean function. Thus a location path para[3] is equivalent to + # para[position()=3]. + def QuickPath::predicate( elements, path ) + ind = 1 + bcount = 1 + while bcount > 0 + bcount += 1 if path[ind] == ?[ + bcount -= 1 if path[ind] == ?] + ind += 1 + end + ind -= 1 + predicate = path[1..ind-1] + rest = path[ind+1..-1] + + # have to change 'a [=<>] b [=<>] c' into 'a [=<>] b and b [=<>] c' + # + predicate.gsub!( + /#{OPERAND_}\s*([<>=])\s*#{OPERAND_}\s*([<>=])\s*#{OPERAND_}/u, + '\1 \2 \3 and \3 \4 \5' ) + # Let's do some Ruby trickery to avoid some work: + predicate.gsub!( /&/u, "&&" ) + predicate.gsub!( /=/u, "==" ) + predicate.gsub!( /@(\w[-\w.]*)/u, 'attribute("\1")' ) + predicate.gsub!( /\bmod\b/u, "%" ) + predicate.gsub!( /\b(\w[-\w.]*\()/u ) { + fname = $1 + fname.gsub( /-/u, "_" ) + } + + Functions.pair = [ 0, elements.size ] + results = [] + elements.each do |element| + Functions.pair[0] += 1 + Functions.node = element + res = eval( predicate ) + case res + when true + results << element + when Integer + results << element if Functions.pair[0] == res + when String + results << element + end + end + filter( results, rest ) + end + + def QuickPath::attribute( name ) + Functions.node.attributes[name] if Functions.node.kind_of? Element + end + + def QuickPath::name() + Functions.node.name if Functions.node.kind_of? Element + end + + def QuickPath::method_missing( id, *args ) + begin + Functions.send( id.id2name, *args ) + rescue Exception + raise "METHOD: #{id.id2name}(#{args.join ', '})\n#{$!.message}" + end + end + + def QuickPath::function( elements, fname, rest ) + args = parse_args( elements, rest ) + Functions.pair = [0, elements.size] + results = [] + elements.each do |element| + Functions.pair[0] += 1 + Functions.node = element + res = Functions.send( fname, *args ) + case res + when true + results << element + when Integer + results << element if Functions.pair[0] == res + end + end + results + end + + def QuickPath::parse_args( element, string ) + # /.*?(?:\)|,)/ + arguments = [] + buffer = "" + while string and string != "" + c = string[0] + string.sub!(/^./u, "") + case c + when ?, + # if depth = 1, then we start a new argument + arguments << evaluate( buffer ) + #arguments << evaluate( string[0..count] ) + when ?( + # start a new method call + function( element, buffer, string ) + buffer = "" + when ?) + # close the method call and return arguments + return arguments + else + buffer << c + end + end + "" + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/rexml.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/rexml.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/rexml.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/rexml.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,39 @@ +# -*- coding: utf-8 -*- +# frozen_string_literal: false +# +# \Module \REXML provides classes and methods for parsing, +# editing, and generating XML. +# +# == Implementation +# +# \REXML: +# - Is pure Ruby. +# - Provides tree, stream, SAX2, pull, and lightweight APIs. +# - Conforms to {XML version 1.0}[https://www.w3.org/TR/REC-xml/]. +# - Fully implements {XPath version 1.0}[http://www.w3c.org/tr/xpath]. +# - Is {non-validating}[https://www.w3.org/TR/xml/]. +# - Passes 100% of the non-validating {Oasis tests}[http://www.oasis-open.org/committees/xml-conformance/xml-test-suite.shtml]. +# +# == In a Hurry? +# +# If you're somewhat familiar with XML +# and have a particular task in mind, +# you may want to see {the tasks pages}[doc/rexml/tasks/tocs/master_toc_rdoc.html]. +# +# == API +# +# Among the most important classes for using \REXML are: +# - REXML::Document. +# - REXML::Element. +# +# There's also an {REXML tutorial}[doc/rexml/tutorial_rdoc.html]. +# +module REXML + COPYRIGHT = "Copyright © 2001-2008 Sean Russell <ser@germane-software.com>" + DATE = "2008/019" + VERSION = "3.4.4" + REVISION = "" + + Copyright = COPYRIGHT + Version = VERSION +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/sax2listener.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/sax2listener.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/sax2listener.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/sax2listener.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,98 @@ +# frozen_string_literal: false +module REXML + # A template for stream parser listeners. + # Note that the declarations (attlistdecl, elementdecl, etc) are trivially + # processed; REXML doesn't yet handle doctype entity declarations, so you + # have to parse them out yourself. + # === Missing methods from SAX2 + # ignorable_whitespace + # === Methods extending SAX2 + # +WARNING+ + # These methods are certainly going to change, until DTDs are fully + # supported. Be aware of this. + # start_document + # end_document + # doctype + # elementdecl + # attlistdecl + # entitydecl + # notationdecl + # cdata + # xmldecl + # comment + module SAX2Listener + def start_document + end + def end_document + end + def start_prefix_mapping prefix, uri + end + def end_prefix_mapping prefix + end + def start_element uri, localname, qname, attributes + end + def end_element uri, localname, qname + end + def characters text + end + def processing_instruction target, data + end + # Handles a doctype declaration. Any attributes of the doctype which are + # not supplied will be nil. # EG, <!DOCTYPE me PUBLIC "foo" "bar"> + # @p name the name of the doctype; EG, "me" + # @p pub_sys "PUBLIC", "SYSTEM", or nil. EG, "PUBLIC" + # @p long_name the supplied long name, or nil. EG, "foo" + # @p uri the uri of the doctype, or nil. EG, "bar" + def doctype name, pub_sys, long_name, uri + end + # If a doctype includes an ATTLIST declaration, it will cause this + # method to be called. The content is the declaration itself, unparsed. + # EG, <!ATTLIST el attr CDATA #REQUIRED> will come to this method as "el + # attr CDATA #REQUIRED". This is the same for all of the .*decl + # methods. + def attlistdecl(element, pairs, contents) + end + # <!ELEMENT ...> + def elementdecl content + end + # <!ENTITY ...> + # The argument passed to this method is an array of the entity + # declaration. It can be in a number of formats, but in general it + # returns (example, result): + # <!ENTITY % YN '"Yes"'> + # ["%", "YN", "\"Yes\""] + # <!ENTITY % YN 'Yes'> + # ["%", "YN", "Yes"] + # <!ENTITY WhatHeSaid "He said %YN;"> + # ["WhatHeSaid", "He said %YN;"] + # <!ENTITY open-hatch SYSTEM "http://www.textuality.com/boilerplate/OpenHatch.xml"> + # ["open-hatch", "SYSTEM", "http://www.textuality.com/boilerplate/OpenHatch.xml"] + # <!ENTITY open-hatch PUBLIC "-//Textuality//TEXT Standard open-hatch boilerplate//EN" "http://www.textuality.com/boilerplate/OpenHatch.xml"> + # ["open-hatch", "PUBLIC", "-//Textuality//TEXT Standard open-hatch boilerplate//EN", "http://www.textuality.com/boilerplate/OpenHatch.xml"] + # <!ENTITY hatch-pic SYSTEM "../grafix/OpenHatch.gif" NDATA gif> + # ["hatch-pic", "SYSTEM", "../grafix/OpenHatch.gif", "NDATA", "gif"] + def entitydecl declaration + end + # <!NOTATION ...> + def notationdecl name, public_or_system, public_id, system_id + end + # Called when <![CDATA[ ... ]]> is encountered in a document. + # @p content "..." + def cdata content + end + # Called when an XML PI is encountered in the document. + # EG: <?xml version="1.0" encoding="utf"?> + # @p version the version attribute value. EG, "1.0" + # @p encoding the encoding attribute value, or nil. EG, "utf" + # @p standalone the standalone attribute value, or nil. EG, nil + # @p spaced the declaration is followed by a line break + def xmldecl version, encoding, standalone + end + # Called when a comment is encountered. + # @p comment The content of the comment + def comment comment + end + def progress position + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/security.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/security.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/security.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/security.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,28 @@ +# frozen_string_literal: false +module REXML + module Security + @@entity_expansion_limit = 10_000 + + # Set the entity expansion limit. By default the limit is set to 10000. + def self.entity_expansion_limit=( val ) + @@entity_expansion_limit = val + end + + # Get the entity expansion limit. By default the limit is set to 10000. + def self.entity_expansion_limit + @@entity_expansion_limit + end + + @@entity_expansion_text_limit = 10_240 + + # Set the entity expansion limit. By default the limit is set to 10240. + def self.entity_expansion_text_limit=( val ) + @@entity_expansion_text_limit = val + end + + # Get the entity expansion limit. By default the limit is set to 10240. + def self.entity_expansion_text_limit + @@entity_expansion_text_limit + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/source.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/source.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/source.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/source.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,388 @@ +# coding: US-ASCII +# frozen_string_literal: false + +require "stringio" +require "strscan" + +require_relative 'encoding' + +module REXML + if StringScanner::Version < "1.0.0" + module StringScannerCheckScanString + refine StringScanner do + def check(pattern) + pattern = /#{Regexp.escape(pattern)}/ if pattern.is_a?(String) + super(pattern) + end + + def scan(pattern) + pattern = /#{Regexp.escape(pattern)}/ if pattern.is_a?(String) + super(pattern) + end + + def match?(pattern) + pattern = /#{Regexp.escape(pattern)}/ if pattern.is_a?(String) + super(pattern) + end + + def skip(pattern) + pattern = /#{Regexp.escape(pattern)}/ if pattern.is_a?(String) + super(pattern) + end + end + end + using StringScannerCheckScanString + end + + # Generates Source-s. USE THIS CLASS. + class SourceFactory + # Generates a Source object + # @param arg Either a String, or an IO + # @return a Source, or nil if a bad argument was given + def SourceFactory::create_from(arg) + if arg.respond_to? :read and + arg.respond_to? :readline and + arg.respond_to? :nil? and + arg.respond_to? :eof? + IOSource.new(arg) + elsif arg.respond_to? :to_str + IOSource.new(StringIO.new(arg)) + elsif arg.kind_of? Source + arg + else + raise "#{arg.class} is not a valid input stream. It must walk \n"+ + "like either a String, an IO, or a Source." + end + end + end + + # A Source can be searched for patterns, and wraps buffers and other + # objects and provides consumption of text + class Source + include Encoding + # The line number of the last consumed text + attr_reader :line + attr_reader :encoding + + module Private + SPACES_PATTERN = /\s+/um + SCANNER_RESET_SIZE = 100000 + PRE_DEFINED_TERM_PATTERNS = {} + pre_defined_terms = ["'", '"', "<", "]]>", "?>"] + if StringScanner::Version < "3.1.1" + pre_defined_terms.each do |term| + PRE_DEFINED_TERM_PATTERNS[term] = /#{Regexp.escape(term)}/ + end + else + pre_defined_terms.each do |term| + PRE_DEFINED_TERM_PATTERNS[term] = term + end + end + end + private_constant :Private + + # Constructor + # @param arg must be a String, and should be a valid XML document + # @param encoding if non-null, sets the encoding of the source to this + # value, overriding all encoding detection + def initialize(arg, encoding=nil) + @orig = arg + @scanner = StringScanner.new(@orig) + if encoding + self.encoding = encoding + else + detect_encoding + end + @line = 0 + @encoded_terms = {} + end + + # The current buffer (what we're going to read next) + def buffer + @scanner.rest + end + + def drop_parsed_content + if @scanner.pos > Private::SCANNER_RESET_SIZE + @scanner.string = @scanner.rest + end + end + + def buffer_encoding=(encoding) + @scanner.string.force_encoding(encoding) + end + + # Inherited from Encoding + # Overridden to support optimized en/decoding + def encoding=(enc) + return unless super + encoding_updated + end + + def read(term = nil) + end + + def read_until(term) + pattern = Private::PRE_DEFINED_TERM_PATTERNS[term] || /#{Regexp.escape(term)}/ + data = @scanner.scan_until(pattern) + unless data + data = @scanner.rest + @scanner.pos = @scanner.string.bytesize + end + data + end + + def ensure_buffer + end + + def match(pattern, cons=false) + if cons + @scanner.scan(pattern).nil? ? nil : @scanner + else + @scanner.check(pattern).nil? ? nil : @scanner + end + end + + def match?(pattern, cons=false) + if cons + !@scanner.skip(pattern).nil? + else + !@scanner.match?(pattern).nil? + end + end + + def skip_spaces + @scanner.skip(Private::SPACES_PATTERN) ? true : false + end + + def position + @scanner.pos + end + + def position=(pos) + @scanner.pos = pos + end + + def peek_byte + @scanner.peek_byte + end + + def scan_byte + @scanner.scan_byte + end + + # @return true if the Source is exhausted + def empty? + @scanner.eos? + end + + # @return the current line in the source + def current_line + lines = @orig.split + res = lines.grep @scanner.rest[0..30] + res = res[-1] if res.kind_of? Array + lines.index( res ) if res + end + + private + + def detect_encoding + scanner_encoding = @scanner.rest.encoding + detected_encoding = "UTF-8" + begin + @scanner.string.force_encoding("ASCII-8BIT") + if @scanner.scan(/\xfe\xff/n) + detected_encoding = "UTF-16BE" + elsif @scanner.scan(/\xff\xfe/n) + detected_encoding = "UTF-16LE" + elsif @scanner.scan(/\xef\xbb\xbf/n) + detected_encoding = "UTF-8" + end + ensure + @scanner.string.force_encoding(scanner_encoding) + end + self.encoding = detected_encoding + end + + def encoding_updated + if @encoding != 'UTF-8' + @scanner.string = decode(@scanner.rest) + @to_utf = true + else + @to_utf = false + @scanner.string.force_encoding(::Encoding::UTF_8) + end + end + end + + # A Source that wraps an IO. See the Source class for method + # documentation + class IOSource < Source + #attr_reader :block_size + + # block_size has been deprecated + def initialize(arg, block_size=500, encoding=nil) + @er_source = @source = arg + @to_utf = false + @pending_buffer = nil + + if encoding + super("", encoding) + else + super(@source.read(3) || "") + end + + if !@to_utf and + @orig.respond_to?(:force_encoding) and + @source.respond_to?(:external_encoding) and + @source.external_encoding != ::Encoding::UTF_8 + @force_utf8 = true + else + @force_utf8 = false + end + end + + def read(term = nil, min_bytes = 1) + term = encode(term) if term + begin + str = readline(term) + @scanner << str + read_bytes = str.bytesize + begin + while read_bytes < min_bytes + str = readline(term) + @scanner << str + read_bytes += str.bytesize + end + rescue IOError + end + true + rescue Exception, NameError + @source = nil + false + end + end + + def read_until(term) + pattern = Private::PRE_DEFINED_TERM_PATTERNS[term] || /#{Regexp.escape(term)}/ + term = @encoded_terms[term] ||= encode(term) + until str = @scanner.scan_until(pattern) + break if @source.nil? + break if @source.eof? + @scanner << readline(term) + end + if str + read if @scanner.eos? and @source and !@source.eof? + str + else + rest = @scanner.rest + @scanner.pos = @scanner.string.bytesize + rest + end + end + + def ensure_buffer + read if @scanner.eos? && @source + end + + def match( pattern, cons=false ) + # To avoid performance issue, we need to increase bytes to read per scan + min_bytes = 1 + while true + if cons + md = @scanner.scan(pattern) + else + md = @scanner.check(pattern) + end + break if md + return nil if pattern.is_a?(String) + return nil if @source.nil? + return nil unless read(nil, min_bytes) + min_bytes *= 2 + end + + md.nil? ? nil : @scanner + end + + def match?( pattern, cons=false ) + # To avoid performance issue, we need to increase bytes to read per scan + min_bytes = 1 + while true + if cons + n_matched_bytes = @scanner.skip(pattern) + else + n_matched_bytes = @scanner.match?(pattern) + end + return true if n_matched_bytes + return false if pattern.is_a?(String) + return false if @source.nil? + return false unless read(nil, min_bytes) + min_bytes *= 2 + end + end + + def empty? + super and ( @source.nil? || @source.eof? ) + end + + # @return the current line in the source + def current_line + begin + pos = @er_source.pos # The byte position in the source + lineno = @er_source.lineno # The XML < position in the source + @er_source.rewind + line = 0 # The \r\n position in the source + begin + while @er_source.pos < pos + @er_source.readline + line += 1 + end + rescue + end + @er_source.seek(pos) + rescue IOError, SystemCallError + pos = -1 + line = -1 + end + [pos, lineno, line] + end + + private + def readline(term = nil) + if @pending_buffer + begin + str = @source.readline(term || @line_break) + rescue IOError + end + if str.nil? + str = @pending_buffer + else + str = @pending_buffer + str + end + @pending_buffer = nil + else + str = @source.readline(term || @line_break) + end + return nil if str.nil? + + if @to_utf + decode(str) + else + str.force_encoding(::Encoding::UTF_8) if @force_utf8 + str + end + end + + def encoding_updated + case @encoding + when "UTF-16BE", "UTF-16LE" + @source.binmode + @source.set_encoding(@encoding, @encoding) + end + @line_break = encode(">") + @pending_buffer, @scanner.string = @scanner.rest, "" + @pending_buffer.force_encoding(@encoding) + super + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/streamlistener.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/streamlistener.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/streamlistener.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/streamlistener.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,93 @@ +# frozen_string_literal: false +module REXML + # A template for stream parser listeners. + # Note that the declarations (attlistdecl, elementdecl, etc) are trivially + # processed; REXML doesn't yet handle doctype entity declarations, so you + # have to parse them out yourself. + module StreamListener + # Called when a tag is encountered. + # @p name the tag name + # @p attrs an array of arrays of attribute/value pairs, suitable for + # use with assoc or rassoc. IE, <tag attr1="value1" attr2="value2"> + # will result in + # tag_start( "tag", # [["attr1","value1"],["attr2","value2"]]) + def tag_start name, attrs + end + # Called when the end tag is reached. In the case of <tag/>, tag_end + # will be called immediately after tag_start + # @p the name of the tag + def tag_end name + end + # Called when text is encountered in the document + # @p text the text content. + def text text + end + # Called when an instruction is encountered. EG: <?xsl sheet='foo'?> + # @p name the instruction name; in the example, "xsl" + # @p instruction the rest of the instruction. In the example, + # "sheet='foo'" + def instruction name, instruction + end + # Called when a comment is encountered. + # @p comment The content of the comment + def comment comment + end + # Handles a doctype declaration. Any attributes of the doctype which are + # not supplied will be nil. # EG, <!DOCTYPE me PUBLIC "foo" "bar"> + # @p name the name of the doctype; EG, "me" + # @p pub_sys "PUBLIC", "SYSTEM", or nil. EG, "PUBLIC" + # @p long_name the supplied long name, or nil. EG, "foo" + # @p uri the uri of the doctype, or nil. EG, "bar" + def doctype name, pub_sys, long_name, uri + end + # Called when the doctype is done + def doctype_end + end + # If a doctype includes an ATTLIST declaration, it will cause this + # method to be called. The content is the declaration itself, unparsed. + # EG, <!ATTLIST el attr CDATA #REQUIRED> will come to this method as "el + # attr CDATA #REQUIRED". This is the same for all of the .*decl + # methods. + def attlistdecl element_name, attributes, raw_content + end + # <!ELEMENT ...> + def elementdecl content + end + # <!ENTITY ...> + # The argument passed to this method is an array of the entity + # declaration. It can be in a number of formats, but in general it + # returns (example, result): + # <!ENTITY % YN '"Yes"'> + # ["YN", "\"Yes\"", "%"] + # <!ENTITY % YN 'Yes'> + # ["YN", "Yes", "%"] + # <!ENTITY WhatHeSaid "He said %YN;"> + # ["WhatHeSaid", "He said %YN;"] + # <!ENTITY open-hatch SYSTEM "http://www.textuality.com/boilerplate/OpenHatch.xml"> + # ["open-hatch", "SYSTEM", "http://www.textuality.com/boilerplate/OpenHatch.xml"] + # <!ENTITY open-hatch PUBLIC "-//Textuality//TEXT Standard open-hatch boilerplate//EN" "http://www.textuality.com/boilerplate/OpenHatch.xml"> + # ["open-hatch", "PUBLIC", "-//Textuality//TEXT Standard open-hatch boilerplate//EN", "http://www.textuality.com/boilerplate/OpenHatch.xml"] + # <!ENTITY hatch-pic SYSTEM "../grafix/OpenHatch.gif" NDATA gif> + # ["hatch-pic", "SYSTEM", "../grafix/OpenHatch.gif", "gif"] + def entitydecl content + end + # <!NOTATION ...> + def notationdecl content + end + # Called when %foo; is encountered in a doctype declaration. + # @p content "foo" + def entity content + end + # Called when <![CDATA[ ... ]]> is encountered in a document. + # @p content "..." + def cdata content + end + # Called when an XML PI is encountered in the document. + # EG: <?xml version="1.0" encoding="utf"?> + # @p version the version attribute value. EG, "1.0" + # @p encoding the encoding attribute value, or nil. EG, "utf" + # @p standalone the standalone attribute value, or nil. EG, nil + def xmldecl version, encoding, standalone + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/text.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/text.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/text.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/text.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,420 @@ +# frozen_string_literal: true +require_relative 'security' +require_relative 'entity' +require_relative 'doctype' +require_relative 'child' +require_relative 'doctype' +require_relative 'parseexception' + +module REXML + # Represents text nodes in an XML document + class Text < Child + include Comparable + # The order in which the substitutions occur + SPECIALS = [ /&(?!#?[\w-]+;)/u, /</u, />/u, /"/u, /'/u, /\r/u ] + SUBSTITUTES = ['&', '<', '>', '"', ''', ' '] + # Characters which are substituted in written strings + SLAICEPS = [ '<', '>', '"', "'", '&' ] + SETUTITSBUS = [ /</u, />/u, /"/u, /'/u, /&/u ] + + # If +raw+ is true, then REXML leaves the value alone + attr_accessor :raw + + NEEDS_A_SECOND_CHECK = /(<|&((#{Entity::NAME});|(#0*((?:\d+)|(?:x[a-fA-F0-9]+)));)?)/um + NUMERICENTITY = /�*((?:\d+)|(?:x[a-fA-F0-9]+));/ + VALID_CHAR = [ + 0x9, 0xA, 0xD, + (0x20..0xD7FF), + (0xE000..0xFFFD), + (0x10000..0x10FFFF) + ] + + VALID_XML_CHARS = Regexp.new('^['+ + VALID_CHAR.map { |item| + case item + when Integer + [item].pack('U').force_encoding('utf-8') + when Range + [item.first, '-'.ord, item.last].pack('UUU').force_encoding('utf-8') + end + }.join + + ']*$') + + # Constructor + # +arg+ if a String, the content is set to the String. If a Text, + # the object is shallowly cloned. + # + # +respect_whitespace+ (boolean, false) if true, whitespace is + # respected + # + # +parent+ (nil) if this is a Parent object, the parent + # will be set to this. + # + # +raw+ (nil) This argument can be given three values. + # If true, then the value of used to construct this object is expected to + # contain no unescaped XML markup, and REXML will not change the text. If + # this value is false, the string may contain any characters, and REXML will + # escape any and all defined entities whose values are contained in the + # text. If this value is nil (the default), then the raw value of the + # parent will be used as the raw value for this node. If there is no raw + # value for the parent, and no value is supplied, the default is false. + # Use this field if you have entities defined for some text, and you don't + # want REXML to escape that text in output. + # Text.new( "<&", false, nil, false ) #-> "<&" + # Text.new( "<&", false, nil, false ) #-> "&lt;&amp;" + # Text.new( "<&", false, nil, true ) #-> Parse exception + # Text.new( "<&", false, nil, true ) #-> "<&" + # # Assume that the entity "s" is defined to be "sean" + # # and that the entity "r" is defined to be "russell" + # Text.new( "sean russell" ) #-> "&s; &r;" + # Text.new( "sean russell", false, nil, true ) #-> "sean russell" + # + # +entity_filter+ (nil) This can be an array of entities to match in the + # supplied text. This argument is only useful if +raw+ is set to false. + # Text.new( "sean russell", false, nil, false, ["s"] ) #-> "&s; russell" + # Text.new( "sean russell", false, nil, true, ["s"] ) #-> "sean russell" + # In the last example, the +entity_filter+ argument is ignored. + # + # +illegal+ INTERNAL USE ONLY + def initialize(arg, respect_whitespace=false, parent=nil, raw=nil, + entity_filter=nil, illegal=NEEDS_A_SECOND_CHECK ) + + @raw = false + @parent = nil + @entity_filter = nil + + if parent + super( parent ) + @raw = parent.raw + end + + if arg.kind_of? String + @string = arg.dup + elsif arg.kind_of? Text + @string = arg.instance_variable_get(:@string).dup + @raw = arg.raw + @entity_filter = arg.instance_variable_get(:@entity_filter) + else + raise "Illegal argument of type #{arg.type} for Text constructor (#{arg})" + end + + @string.squeeze!(" \n\t") unless respect_whitespace + @string.gsub!(/\r\n?/, "\n") + @raw = raw unless raw.nil? + @entity_filter = entity_filter if entity_filter + clear_cache + + Text.check(@string, illegal) if @raw + end + + def parent= parent + super(parent) + Text.check(@string, NEEDS_A_SECOND_CHECK) if @raw and @parent + end + + # check for illegal characters + def Text.check string, pattern, doctype = nil + + # illegal anywhere + if !string.match?(VALID_XML_CHARS) + string.chars.each do |c| + case c.ord + when *VALID_CHAR + else + raise "Illegal character #{c.inspect} in raw string #{string.inspect}" + end + end + end + + pos = 0 + while (index = string.index(/<|&/, pos)) + if string[index] == "<" + raise "Illegal character \"#{string[index]}\" in raw string #{string.inspect}" + end + + unless (end_index = string.index(/[^\s];/, index + 1)) + raise "Illegal character \"#{string[index]}\" in raw string #{string.inspect}" + end + + value = string[(index + 1)..end_index] + if /\s/.match?(value) + raise "Illegal character \"#{string[index]}\" in raw string #{string.inspect}" + end + + if value[0] == "#" + character_reference = value[1..-1] + + unless (/\A(\d+|x[0-9a-fA-F]+)\z/.match?(character_reference)) + if character_reference[0] == "x" || character_reference[-1] == "x" + raise "Illegal character \"#{string[index]}\" in raw string #{string.inspect}" + else + raise "Illegal character #{string.inspect} in raw string #{string.inspect}" + end + end + + case (character_reference[0] == "x" ? character_reference[1..-1].to_i(16) : character_reference[0..-1].to_i) + when *VALID_CHAR + else + raise "Illegal character #{string.inspect} in raw string #{string.inspect}" + end + elsif !(/\A#{Entity::NAME}\z/um.match?(value)) + raise "Illegal character \"#{string[index]}\" in raw string #{string.inspect}" + end + + pos = end_index + 1 + end + + string + end + + def node_type + :text + end + + def empty? + @string.size==0 + end + + + def clone + Text.new(self, true) + end + + + # Appends text to this text node. The text is appended in the +raw+ mode + # of this text node. + # + # +returns+ the text itself to enable method chain like + # 'text << "XXX" << "YYY"'. + def <<( to_append ) + @string << to_append.gsub( /\r\n?/, "\n" ) + clear_cache + self + end + + + # +other+ a String or a Text + # +returns+ the result of (to_s <=> arg.to_s) + def <=>( other ) + to_s() <=> other.to_s + end + + def doctype + @parent&.document&.doctype + end + + REFERENCE = /#{Entity::REFERENCE}/ + # Returns the string value of this text node. This string is always + # escaped, meaning that it is a valid XML text node string, and all + # entities that can be escaped, have been inserted. This method respects + # the entity filter set in the constructor. + # + # # Assume that the entity "s" is defined to be "sean", and that the + # # entity "r" is defined to be "russell" + # t = Text.new( "< & sean russell", false, nil, false, ['s'] ) + # t.to_s #-> "< & &s; russell" + # t = Text.new( "< & &s; russell", false, nil, false ) + # t.to_s #-> "< & &s; russell" + # u = Text.new( "sean russell", false, nil, true ) + # u.to_s #-> "sean russell" + def to_s + return @string if @raw + @normalized ||= Text::normalize( @string, doctype, @entity_filter ) + end + + def inspect + @string.inspect + end + + # Returns the string value of this text. This is the text without + # entities, as it might be used programmatically, or printed to the + # console. This ignores the 'raw' attribute setting, and any + # entity_filter. + # + # # Assume that the entity "s" is defined to be "sean", and that the + # # entity "r" is defined to be "russell" + # t = Text.new( "< & sean russell", false, nil, false, ['s'] ) + # t.value #-> "< & sean russell" + # t = Text.new( "< & &s; russell", false, nil, false ) + # t.value #-> "< & sean russell" + # u = Text.new( "sean russell", false, nil, true ) + # u.value #-> "sean russell" + def value + @unnormalized ||= Text::unnormalize(@string, doctype, + entity_expansion_text_limit: document&.entity_expansion_text_limit) + end + + # Sets the contents of this text node. This expects the text to be + # unnormalized. It returns self. + # + # e = Element.new( "a" ) + # e.add_text( "foo" ) # <a>foo</a> + # e[0].value = "bar" # <a>bar</a> + # e[0].value = "<a>" # <a><a></a> + def value=( val ) + @string = val.gsub( /\r\n?/, "\n" ) + clear_cache + @raw = false + end + + def wrap(string, width, addnewline=false) + # Recursively wrap string at width. + return string if string.length <= width + place = string.rindex(' ', width) # Position in string with last ' ' before cutoff + if addnewline + "\n" + string[0,place] + "\n" + wrap(string[place+1..-1], width) + else + string[0,place] + "\n" + wrap(string[place+1..-1], width) + end + end + + def indent_text(string, level=1, style="\t", indentfirstline=true) + Kernel.warn("#{self.class.name}#indent_text is deprecated. See REXML::Formatters", uplevel: 1) + return string if level < 0 + + new_string = +'' + string.each_line { |line| + indent_string = style * level + new_line = (indent_string + line).sub(/[\s]+$/,'') + new_string << new_line + } + new_string.strip! unless indentfirstline + new_string + end + + # == DEPRECATED + # See REXML::Formatters + # + def write( writer, indent=-1, transitive=false, ie_hack=false ) + Kernel.warn("#{self.class.name}#write is deprecated. See REXML::Formatters", uplevel: 1) + formatter = if indent > -1 + REXML::Formatters::Pretty.new( indent ) + else + REXML::Formatters::Default.new + end + formatter.write( self, writer ) + end + + # FIXME + # This probably won't work properly + def xpath + @parent.xpath + "/text()" + end + + # Writes out text, substituting special characters beforehand. + # +out+ A String, IO, or any other object supporting <<( String ) + # +input+ the text to substitute and the write out + # + # z=utf8.unpack("U*") + # ascOut="" + # z.each{|r| + # if r < 0x100 + # ascOut.concat(r.chr) + # else + # ascOut.concat(sprintf("&#x%x;", r)) + # end + # } + # puts ascOut + def write_with_substitution out, input + copy = input.clone + # Doing it like this rather than in a loop improves the speed + copy.gsub!( SPECIALS[0], SUBSTITUTES[0] ) + copy.gsub!( SPECIALS[1], SUBSTITUTES[1] ) + copy.gsub!( SPECIALS[2], SUBSTITUTES[2] ) + copy.gsub!( SPECIALS[3], SUBSTITUTES[3] ) + copy.gsub!( SPECIALS[4], SUBSTITUTES[4] ) + copy.gsub!( SPECIALS[5], SUBSTITUTES[5] ) + out << copy + end + + private + def clear_cache + @normalized = nil + @unnormalized = nil + end + + # Reads text, substituting entities + def Text::read_with_substitution( input, illegal=nil ) + copy = input.clone + + if copy =~ illegal + raise ParseException.new( "malformed text: Illegal character #$& in \"#{copy}\"" ) + end if illegal + + copy.gsub!( /\r\n?/, "\n" ) + if copy.include? ?& + copy.gsub!( SETUTITSBUS[0], SLAICEPS[0] ) + copy.gsub!( SETUTITSBUS[1], SLAICEPS[1] ) + copy.gsub!( SETUTITSBUS[2], SLAICEPS[2] ) + copy.gsub!( SETUTITSBUS[3], SLAICEPS[3] ) + copy.gsub!( SETUTITSBUS[4], SLAICEPS[4] ) + copy.gsub!( /�*((?:\d+)|(?:x[a-f0-9]+));/ ) { + m=$1 + #m='0' if m=='' + m = "0#{m}" if m[0] == ?x + [Integer(m)].pack('U*') + } + end + copy + end + + EREFERENCE = /&(?!#{Entity::NAME};)/ + # Escapes all possible entities + def Text::normalize( input, doctype=nil, entity_filter=nil ) + copy = input.to_s + # Doing it like this rather than in a loop improves the speed + #copy = copy.gsub( EREFERENCE, '&' ) + copy = copy.gsub( "&", "&" ) if copy.include?("&") + if doctype + # Replace all ampersands that aren't part of an entity + doctype.entities.each_value do |entity| + copy = copy.gsub( entity.value, + "&#{entity.name};" ) if entity.value and + not( entity_filter and entity_filter.include?(entity.name) ) + end + else + # Replace all ampersands that aren't part of an entity + DocType::DEFAULT_ENTITIES.each_value do |entity| + if copy.include?(entity.value) + copy = copy.gsub(entity.value, "&#{entity.name};" ) + end + end + end + copy + end + + # Unescapes all possible entities + def Text::unnormalize( string, doctype=nil, filter=nil, illegal=nil, entity_expansion_text_limit: nil ) + entity_expansion_text_limit ||= Security.entity_expansion_text_limit + sum = 0 + string.gsub( /\r\n?/, "\n" ).gsub( REFERENCE ) { + s = Text.expand($&, doctype, filter) + if sum + s.bytesize > entity_expansion_text_limit + raise "entity expansion has grown too large" + else + sum += s.bytesize + end + s + } + end + + def Text.expand(ref, doctype, filter) + if ref[1] == ?# + if ref[2] == ?x + [ref[3...-1].to_i(16)].pack('U*') + else + [ref[2...-1].to_i].pack('U*') + end + elsif ref == '&' + '&' + elsif filter and filter.include?( ref[1...-1] ) + ref + elsif doctype + doctype.entity( ref[1...-1] ) or ref + else + entity_value = DocType::DEFAULT_ENTITIES[ ref[1...-1] ] + entity_value ? entity_value.value : ref + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/undefinednamespaceexception.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/undefinednamespaceexception.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/undefinednamespaceexception.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/undefinednamespaceexception.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,9 @@ +# frozen_string_literal: false +require_relative 'parseexception' +module REXML + class UndefinedNamespaceException < ParseException + def initialize( prefix, source, parser ) + super( "Undefined prefix #{prefix} found" ) + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/validation/relaxng.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/validation/relaxng.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/validation/relaxng.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/validation/relaxng.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,540 @@ +# frozen_string_literal: false +require_relative "validation" +require_relative "../parsers/baseparser" + +module REXML + module Validation + # Implemented: + # * empty + # * element + # * attribute + # * text + # * optional + # * choice + # * oneOrMore + # * zeroOrMore + # * group + # * value + # * interleave + # * mixed + # * ref + # * grammar + # * start + # * define + # + # Not implemented: + # * data + # * param + # * include + # * externalRef + # * notAllowed + # * anyName + # * nsName + # * except + # * name + class RelaxNG + include Validator + + INFINITY = 1.0 / 0.0 + EMPTY = Event.new( nil ) + TEXT = [:start_element, "text"] + attr_accessor :current + attr_accessor :count + attr_reader :references + + # FIXME: Namespaces + def initialize source + parser = REXML::Parsers::BaseParser.new( source ) + + @count = 0 + @references = {} + @root = @current = Sequence.new(self) + @root.previous = true + states = [ @current ] + begin + event = parser.pull + case event[0] + when :start_element + case event[1] + when "empty" + when "element", "attribute", "text", "value" + states[-1] << event + when "optional" + states << Optional.new( self ) + states[-2] << states[-1] + when "choice" + states << Choice.new( self ) + states[-2] << states[-1] + when "oneOrMore" + states << OneOrMore.new( self ) + states[-2] << states[-1] + when "zeroOrMore" + states << ZeroOrMore.new( self ) + states[-2] << states[-1] + when "group" + states << Sequence.new( self ) + states[-2] << states[-1] + when "interleave" + states << Interleave.new( self ) + states[-2] << states[-1] + when "mixed" + states << Interleave.new( self ) + states[-2] << states[-1] + states[-1] << TEXT + when "define" + states << [ event[2]["name"] ] + when "ref" + states[-1] << Ref.new( event[2]["name"] ) + when "anyName" + states << AnyName.new( self ) + states[-2] << states[-1] + when "nsName" + when "except" + when "name" + when "data" + when "param" + when "include" + when "grammar" + when "start" + when "externalRef" + when "notAllowed" + end + when :end_element + case event[1] + when "element", "attribute" + states[-1] << event + when "zeroOrMore", "oneOrMore", "choice", "optional", + "interleave", "group", "mixed" + states.pop + when "define" + ref = states.pop + @references[ ref.shift ] = ref + #when "empty" + end + when :end_document + states[-1] << event + when :text + states[-1] << event + end + end while event[0] != :end_document + end + + def receive event + validate( event ) + end + end + + class State + def initialize( context ) + @previous = [] + @events = [] + @current = 0 + @count = context.count += 1 + @references = context.references + @value = false + end + + def reset + return if @current == 0 + @current = 0 + @events.each {|s| s.reset if s.kind_of? State } + end + + def previous=( previous ) + @previous << previous + end + + def next( event ) + #print "In next with #{event.inspect}. " + #p @previous + return @previous.pop.next( event ) if @events[@current].nil? + expand_ref_in( @events, @current ) if @events[@current].class == Ref + if ( @events[@current].kind_of? State ) + @current += 1 + @events[@current-1].previous = self + return @events[@current-1].next( event ) + end + if ( @events[@current].matches?(event) ) + @current += 1 + if @events[@current].nil? + @previous.pop + elsif @events[@current].kind_of? State + @current += 1 + @events[@current-1].previous = self + @events[@current-1] + else + self + end + else + nil + end + end + + def to_s + # Abbreviated: + self.class.name =~ /(?:::)(\w)\w+$/ + # Full: + #self.class.name =~ /(?:::)(\w+)$/ + "#$1.#@count" + end + + def inspect + "< #{to_s} #{@events.collect{|e| + pre = e == @events[@current] ? '#' : '' + pre + e.inspect unless self == e + }.join(', ')} >" + end + + def expected + [@events[@current]] + end + + def <<( event ) + add_event_to_arry( @events, event ) + end + + + protected + def expand_ref_in( arry, ind ) + new_events = [] + @references[ arry[ind].to_s ].each{ |evt| + add_event_to_arry(new_events,evt) + } + arry[ind,1] = new_events + end + + def add_event_to_arry( arry, evt ) + evt = generate_event( evt ) + if evt.kind_of? String + arry[-1].event_arg = evt if arry[-1].kind_of? Event and @value + @value = false + else + arry << evt + end + end + + def generate_event( event ) + return event if event.kind_of? State or event.class == Ref + evt = nil + arg = nil + case event[0] + when :start_element + case event[1] + when "element" + evt = :start_element + arg = event[2]["name"] + when "attribute" + evt = :start_attribute + arg = event[2]["name"] + when "text" + evt = :text + when "value" + evt = :text + @value = true + end + when :text + return event[1] + when :end_document + return Event.new( event[0] ) + else # then :end_element + case event[1] + when "element" + evt = :end_element + when "attribute" + evt = :end_attribute + end + end + Event.new( evt, arg ) + end + end + + + class Sequence < State + def matches?(event) + @events[@current].matches?( event ) + end + end + + + class Optional < State + def next( event ) + if @current == 0 + rv = super + return rv if rv + @prior = @previous.pop + @prior.next( event ) + else + super + end + end + + def matches?(event) + @events[@current].matches?(event) || + (@current == 0 and @previous[-1].matches?(event)) + end + + def expected + return [ @prior.expected, @events[0] ].flatten if @current == 0 + [@events[@current]] + end + end + + + class ZeroOrMore < Optional + def next( event ) + expand_ref_in( @events, @current ) if @events[@current].class == Ref + if ( @events[@current].matches?(event) ) + @current += 1 + if @events[@current].nil? + @current = 0 + self + elsif @events[@current].kind_of? State + @current += 1 + @events[@current-1].previous = self + @events[@current-1] + else + self + end + else + @prior = @previous.pop + return @prior.next( event ) if @current == 0 + nil + end + end + + def expected + return [ @prior.expected, @events[0] ].flatten if @current == 0 + [@events[@current]] + end + end + + + class OneOrMore < State + def initialize context + super + @ord = 0 + end + + def reset + super + @ord = 0 + end + + def next( event ) + expand_ref_in( @events, @current ) if @events[@current].class == Ref + if ( @events[@current].matches?(event) ) + @current += 1 + @ord += 1 + if @events[@current].nil? + @current = 0 + self + elsif @events[@current].kind_of? State + @current += 1 + @events[@current-1].previous = self + @events[@current-1] + else + self + end + else + return @previous.pop.next( event ) if @current == 0 and @ord > 0 + nil + end + end + + def matches?( event ) + @events[@current].matches?(event) || + (@current == 0 and @ord > 0 and @previous[-1].matches?(event)) + end + + def expected + if @current == 0 and @ord > 0 + [@previous[-1].expected, @events[0]].flatten + else + [@events[@current]] + end + end + end + + + class Choice < State + def initialize context + super + @choices = [] + end + + def reset + super + @events = [] + @choices.each { |c| c.each { |s| s.reset if s.kind_of? State } } + end + + def <<( event ) + add_event_to_arry( @choices, event ) + end + + def next( event ) + # Make the choice if we haven't + if @events.size == 0 + c = 0 ; max = @choices.size + while c < max + if @choices[c][0].class == Ref + expand_ref_in( @choices[c], 0 ) + @choices += @choices[c] + @choices.delete( @choices[c] ) + max -= 1 + else + c += 1 + end + end + @events = @choices.find { |evt| evt[0].matches? event } + # Remove the references + # Find the events + end + unless @events + @events = [] + return nil + end + super + end + + def matches?( event ) + return @events[@current].matches?( event ) if @events.size > 0 + !@choices.find{|evt| evt[0].matches?(event)}.nil? + end + + def expected + return [@events[@current]] if @events.size > 0 + @choices.collect do |x| + if x[0].kind_of? State + x[0].expected + else + x[0] + end + end.flatten + end + + def inspect + "< #{to_s} #{@choices.collect{|e| e.collect{|f|f.to_s}.join(', ')}.join(' or ')} >" + end + + protected + def add_event_to_arry( arry, evt ) + if evt.kind_of? State or evt.class == Ref + arry << [evt] + elsif evt[0] == :text + if arry[-1] and + arry[-1][-1].kind_of?( Event ) and + arry[-1][-1].event_type == :text and @value + + arry[-1][-1].event_arg = evt[1] + @value = false + end + else + arry << [] if evt[0] == :start_element + arry[-1] << generate_event( evt ) + end + end + end + + + class Interleave < Choice + def initialize context + super + @choice = 0 + end + + def reset + @choice = 0 + end + + def next_current( event ) + # Expand references + c = 0 ; max = @choices.size + while c < max + if @choices[c][0].class == Ref + expand_ref_in( @choices[c], 0 ) + @choices += @choices[c] + @choices.delete( @choices[c] ) + max -= 1 + else + c += 1 + end + end + @events = @choices[@choice..-1].find { |evt| evt[0].matches? event } + @current = 0 + if @events + # reorder the choices + old = @choices[@choice] + idx = @choices.index( @events ) + @choices[@choice] = @events + @choices[idx] = old + @choice += 1 + end + + @events = [] unless @events + end + + + def next( event ) + # Find the next series + next_current(event) unless @events[@current] + return nil unless @events[@current] + + expand_ref_in( @events, @current ) if @events[@current].class == Ref + if ( @events[@current].kind_of? State ) + @current += 1 + @events[@current-1].previous = self + return @events[@current-1].next( event ) + end + return @previous.pop.next( event ) if @events[@current].nil? + if ( @events[@current].matches?(event) ) + @current += 1 + if @events[@current].nil? + return self unless @choices[@choice].nil? + @previous.pop + elsif @events[@current].kind_of? State + @current += 1 + @events[@current-1].previous = self + @events[@current-1] + else + self + end + else + nil + end + end + + def matches?( event ) + return @events[@current].matches?( event ) if @events[@current] + !@choices[@choice..-1].find{|evt| evt[0].matches?(event)}.nil? + end + + def expected + return [@events[@current]] if @events[@current] + @choices[@choice..-1].collect do |x| + if x[0].kind_of? State + x[0].expected + else + x[0] + end + end.flatten + end + + def inspect + "< #{to_s} #{@choices.collect{|e| e.collect{|f|f.to_s}.join(', ')}.join(' and ')} >" + end + end + + class Ref + def initialize value + @value = value + end + def to_s + @value + end + def inspect + "{#{to_s}}" + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/validation/validation.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/validation/validation.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/validation/validation.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/validation/validation.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,144 @@ +# frozen_string_literal: false +require_relative 'validationexception' + +module REXML + module Validation + module Validator + NILEVENT = [ nil ] + def reset + @current = @root + @root.reset + @root.previous = true + @attr_stack = [] + self + end + def dump + puts @root.inspect + end + def validate( event ) + @attr_stack = [] unless defined? @attr_stack + match = @current.next(event) + raise ValidationException.new( "Validation error. Expected: "+ + @current.expected.join( " or " )+" from #{@current.inspect} "+ + " but got #{Event.new( event[0], event[1] ).inspect}" ) unless match + @current = match + + # Check for attributes + case event[0] + when :start_element + @attr_stack << event[2] + begin + sattr = [:start_attribute, nil] + eattr = [:end_attribute] + text = [:text, nil] + k, = event[2].find { |key,value| + sattr[1] = key + m = @current.next( sattr ) + if m + # If the state has text children... + if m.matches?( eattr ) + @current = m + else + text[1] = value + m = m.next( text ) + text[1] = nil + return false unless m + @current = m if m + end + m = @current.next( eattr ) + if m + @current = m + true + else + false + end + else + false + end + } + event[2].delete(k) if k + end while k + when :end_element + attrs = @attr_stack.pop + raise ValidationException.new( "Validation error. Illegal "+ + " attributes: #{attrs.inspect}") if attrs.length > 0 + end + end + end + + class Event + def initialize(event_type, event_arg=nil ) + @event_type = event_type + @event_arg = event_arg + end + + attr_reader :event_type + attr_accessor :event_arg + + def done? + @done + end + + def single? + (@event_type != :start_element and @event_type != :start_attribute) + end + + def matches?( event ) + return false unless event[0] == @event_type + case event[0] + when nil + true + when :start_element + event[1] == @event_arg + when :end_element + true + when :start_attribute + event[1] == @event_arg + when :end_attribute + true + when :end_document + true + when :text + @event_arg.nil? || @event_arg == event[1] +=begin + when :processing_instruction + false + when :xmldecl + false + when :start_doctype + false + when :end_doctype + false + when :externalentity + false + when :elementdecl + false + when :entity + false + when :attlistdecl + false + when :notationdecl + false + when :end_doctype + false +=end + else + false + end + end + + def ==( other ) + return false unless other.kind_of? Event + @event_type == other.event_type and @event_arg == other.event_arg + end + + def to_s + inspect + end + + def inspect + "#{@event_type.inspect}( #@event_arg )" + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/validation/validationexception.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/validation/validationexception.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/validation/validationexception.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/validation/validationexception.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,10 @@ +# frozen_string_literal: false +module REXML + module Validation + class ValidationException < RuntimeError + def initialize msg + super + end + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/xmldecl.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/xmldecl.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/xmldecl.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/xmldecl.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,130 @@ +# frozen_string_literal: false + +require_relative 'encoding' +require_relative 'source' + +module REXML + # NEEDS DOCUMENTATION + class XMLDecl < Child + include Encoding + + DEFAULT_VERSION = "1.0" + DEFAULT_ENCODING = "UTF-8" + DEFAULT_STANDALONE = "no" + START = "<?xml" + STOP = "?>" + + attr_accessor :version, :standalone + attr_reader :writeencoding, :writethis + + def initialize(version=DEFAULT_VERSION, encoding=nil, standalone=nil) + @writethis = true + @writeencoding = !encoding.nil? + if version.kind_of? XMLDecl + super() + @version = version.version + self.encoding = version.encoding + @writeencoding = version.writeencoding + @standalone = version.standalone + @writethis = version.writethis + else + super() + @version = version + self.encoding = encoding + @standalone = standalone + end + @version = DEFAULT_VERSION if @version.nil? + end + + def clone + XMLDecl.new(self) + end + + # indent:: + # Ignored. There must be no whitespace before an XML declaration + # transitive:: + # Ignored + # ie_hack:: + # Ignored + def write(writer, indent=-1, transitive=false, ie_hack=false) + return nil unless @writethis or writer.kind_of? Output + writer << START + writer << " #{content encoding}" + writer << STOP + end + + def ==( other ) + other.kind_of?(XMLDecl) and + other.version == @version and + other.encoding == self.encoding and + other.standalone == @standalone + end + + def xmldecl version, encoding, standalone + @version = version + self.encoding = encoding + @standalone = standalone + end + + def node_type + :xmldecl + end + + alias :stand_alone? :standalone + alias :old_enc= :encoding= + + def encoding=( enc ) + if enc.nil? + self.old_enc = "UTF-8" + @writeencoding = false + else + self.old_enc = enc + @writeencoding = true + end + self.dowrite + end + + # Only use this if you do not want the XML declaration to be written; + # this object is ignored by the XML writer. Otherwise, instantiate your + # own XMLDecl and add it to the document. + # + # Note that XML 1.1 documents *must* include an XML declaration + def XMLDecl.default + rv = XMLDecl.new( "1.0" ) + rv.nowrite + rv + end + + def nowrite + @writethis = false + end + + def dowrite + @writethis = true + end + + def inspect + "#{START} ... #{STOP}" + end + + private + def content(enc) + context = nil + context = parent.context if parent + if context and context[:prologue_quote] == :quote + quote = "\"" + else + quote = "'" + end + + rv = "version=#{quote}#{@version}#{quote}" + if @writeencoding or enc !~ /\Autf-8\z/i + rv << " encoding=#{quote}#{enc}#{quote}" + end + if @standalone + rv << " standalone=#{quote}#{@standalone}#{quote}" + end + rv + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/xmltokens.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/xmltokens.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/xmltokens.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/xmltokens.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,85 @@ +# frozen_string_literal: false +module REXML + # Defines a number of tokens used for parsing XML. Not for general + # consumption. + module XMLTokens + # From http://www.w3.org/TR/REC-xml/#sec-common-syn + # + # [4] NameStartChar ::= + # ":" | + # [A-Z] | + # "_" | + # [a-z] | + # [#xC0-#xD6] | + # [#xD8-#xF6] | + # [#xF8-#x2FF] | + # [#x370-#x37D] | + # [#x37F-#x1FFF] | + # [#x200C-#x200D] | + # [#x2070-#x218F] | + # [#x2C00-#x2FEF] | + # [#x3001-#xD7FF] | + # [#xF900-#xFDCF] | + # [#xFDF0-#xFFFD] | + # [#x10000-#xEFFFF] + name_start_chars = [ + ":", + "A-Z", + "_", + "a-z", + "\\u00C0-\\u00D6", + "\\u00D8-\\u00F6", + "\\u00F8-\\u02FF", + "\\u0370-\\u037D", + "\\u037F-\\u1FFF", + "\\u200C-\\u200D", + "\\u2070-\\u218F", + "\\u2C00-\\u2FEF", + "\\u3001-\\uD7FF", + "\\uF900-\\uFDCF", + "\\uFDF0-\\uFFFD", + "\\u{10000}-\\u{EFFFF}", + ] + # From http://www.w3.org/TR/REC-xml/#sec-common-syn + # + # [4a] NameChar ::= + # NameStartChar | + # "-" | + # "." | + # [0-9] | + # #xB7 | + # [#x0300-#x036F] | + # [#x203F-#x2040] + name_chars = name_start_chars + [ + "\\-", + "\\.", + "0-9", + "\\u00B7", + "\\u0300-\\u036F", + "\\u203F-\\u2040", + ] + NAME_START_CHAR = "[#{name_start_chars.join('')}]" + NAME_CHAR = "[#{name_chars.join('')}]" + NAMECHAR = NAME_CHAR # deprecated. Use NAME_CHAR instead. + + # From http://www.w3.org/TR/xml-names11/#NT-NCName + # + # [6] NCNameStartChar ::= NameStartChar - ':' + ncname_start_chars = name_start_chars - [":"] + # From http://www.w3.org/TR/xml-names11/#NT-NCName + # + # [5] NCNameChar ::= NameChar - ':' + ncname_chars = name_chars - [":"] + NCNAME_STR = "[#{ncname_start_chars.join('')}][#{ncname_chars.join('')}]*" + NAME_STR = "(?:#{NCNAME_STR}:)?#{NCNAME_STR}" + + NAME = "(#{NAME_START_CHAR}#{NAME_CHAR}*)" + NMTOKEN = "(?:#{NAME_CHAR})+" + NMTOKENS = "#{NMTOKEN}(\\s+#{NMTOKEN})*" + REFERENCE = "(?:&#{NAME};|&#\\d+;|&#x[0-9a-fA-F]+;)" + + #REFERENCE = "(?:#{ENTITYREF}|#{CHARREF})" + #ENTITYREF = "&#{NAME};" + #CHARREF = "&#\\d+;|&#x[0-9a-fA-F]+;" + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/xpath.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/xpath.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/xpath.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/xpath.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,70 @@ +# frozen_string_literal: false +require_relative 'functions' +require_relative 'xpath_parser' + +module REXML + # Wrapper class. Use this class to access the XPath functions. + class XPath + include Functions + # A base Hash object, supposing to be used when initializing a + # default empty namespaces set, but is currently unused. + # TODO: either set the namespaces=EMPTY_HASH, or deprecate this. + EMPTY_HASH = {} + + # Finds and returns the first node that matches the supplied xpath. + # element:: + # The context element + # path:: + # The xpath to search for. If not supplied or nil, returns the first + # node matching '*'. + # namespaces:: + # If supplied, a Hash which defines a namespace mapping. + # variables:: + # If supplied, a Hash which maps $variables in the query + # to values. This can be used to avoid XPath injection attacks + # or to automatically handle escaping string values. + # + # XPath.first( node ) + # XPath.first( doc, "//b"} ) + # XPath.first( node, "a/x:b", { "x"=>"http://doofus" } ) + # XPath.first( node, '/book/publisher/text()=$publisher', {}, {"publisher"=>"O'Reilly"}) + def XPath::first(element, path=nil, namespaces=nil, variables={}, options={}) + raise "The namespaces argument, if supplied, must be a hash object." unless namespaces.nil? or namespaces.kind_of?(Hash) + raise "The variables argument, if supplied, must be a hash object." unless variables.kind_of?(Hash) + match(element, path, namespaces, variables, options).flatten[0] + end + + # Iterates over nodes that match the given path, calling the supplied + # block with the match. + # element:: + # The context element + # path:: + # The xpath to search for. If not supplied or nil, defaults to '*' + # namespaces:: + # If supplied, a Hash which defines a namespace mapping + # variables:: + # If supplied, a Hash which maps $variables in the query + # to values. This can be used to avoid XPath injection attacks + # or to automatically handle escaping string values. + # + # XPath.each( node ) { |el| ... } + # XPath.each( node, '/*[@attr='v']' ) { |el| ... } + # XPath.each( node, 'ancestor::x' ) { |el| ... } + # XPath.each( node, '/book/publisher/text()=$publisher', {}, {"publisher"=>"O'Reilly"}) \ + # {|el| ... } + def XPath::each(element, path=nil, namespaces=nil, variables={}, options={}, &block) + raise "The namespaces argument, if supplied, must be a hash object." unless namespaces.nil? or namespaces.kind_of?(Hash) + raise "The variables argument, if supplied, must be a hash object." unless variables.kind_of?(Hash) + match(element, path, namespaces, variables, options).each( &block ) + end + + # Returns an array of nodes matching a given XPath. + def XPath::match(element, path=nil, namespaces=nil, variables={}, options={}) + parser = XPathParser.new(**options) + parser.namespaces = namespaces + parser.variables = variables + path = "*" unless path + parser.parse(path,element) + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/xpath_parser.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/xpath_parser.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml/xpath_parser.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml/xpath_parser.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,980 @@ +# frozen_string_literal: false + +require "pp" + +require_relative 'namespace' +require_relative 'xmltokens' +require_relative 'attribute' +require_relative 'parsers/xpathparser' + +module REXML + module DClonable + refine Object do + # provides a unified +clone+ operation, for REXML::XPathParser + # to use across multiple Object types + def dclone + clone + end + end + refine Symbol do + # provides a unified +clone+ operation, for REXML::XPathParser + # to use across multiple Object types + def dclone ; self ; end + end + refine Integer do + # provides a unified +clone+ operation, for REXML::XPathParser + # to use across multiple Object types + def dclone ; self ; end + end + refine Float do + # provides a unified +clone+ operation, for REXML::XPathParser + # to use across multiple Object types + def dclone ; self ; end + end + refine Array do + # provides a unified +clone+ operation, for REXML::XPathParser + # to use across multiple Object+ types + def dclone + klone = self.clone + klone.clear + self.each{|v| klone << v.dclone} + klone + end + end + end +end + +using REXML::DClonable + +module REXML + # You don't want to use this class. Really. Use XPath, which is a wrapper + # for this class. Believe me. You don't want to poke around in here. + # There is strange, dark magic at work in this code. Beware. Go back! Go + # back while you still can! + class XPathParser + include XMLTokens + LITERAL = /^'([^']*)'|^"([^"]*)"/u + + DEBUG = (ENV["REXML_XPATH_PARSER_DEBUG"] == "true") + + def initialize(strict: false) + @debug = DEBUG + @parser = REXML::Parsers::XPathParser.new + @namespaces = nil + @variables = {} + @nest = 0 + @strict = strict + end + + def namespaces=( namespaces={} ) + Functions::namespace_context = namespaces + @namespaces = namespaces + end + + def variables=( vars={} ) + Functions::variables = vars + @variables = vars + end + + def parse path, node + path_stack = @parser.parse( path ) + if node.is_a?(Array) + Kernel.warn("REXML::XPath.each, REXML::XPath.first, REXML::XPath.match dropped support for nodeset...", uplevel: 1) + return [] if node.empty? + node = node.first + end + + document = node.document + if document + document.__send__(:enable_cache) do + match( path_stack, node ) + end + else + match( path_stack, node ) + end + end + + def get_first path, node + path_stack = @parser.parse( path ) + first( path_stack, node ) + end + + def predicate path, node + path_stack = @parser.parse( path ) + match( path_stack, node ) + end + + def []=( variable_name, value ) + @variables[ variable_name ] = value + end + + + # Performs a depth-first (document order) XPath search, and returns the + # first match. This is the fastest, lightest way to return a single result. + # + # FIXME: This method is incomplete! + def first( path_stack, node ) + return nil if path.size == 0 + + case path[0] + when :document + # do nothing + first( path[1..-1], node ) + when :child + for c in node.children + r = first( path[1..-1], c ) + return r if r + end + when :qname + name = path[2] + if node.name == name + return node if path.size == 3 + first( path[3..-1], node ) + else + nil + end + when :descendant_or_self + r = first( path[1..-1], node ) + return r if r + for c in node.children + r = first( path, c ) + return r if r + end + when :node + first( path[1..-1], node ) + when :any + first( path[1..-1], node ) + else + nil + end + end + + + def match(path_stack, node) + nodeset = [XPathNode.new(node, position: 1)] + result = expr(path_stack, nodeset) + case result + when Array # nodeset + unnode(result).uniq + else + [result] + end + end + + private + def strict? + @strict + end + + # Returns a String namespace for a node, given a prefix + # The rules are: + # + # 1. Use the supplied namespace mapping first. + # 2. If no mapping was supplied, use the context node to look up the namespace + def get_namespace( node, prefix ) + if @namespaces + @namespaces[prefix] || '' + else + return node.namespace( prefix ) if node.node_type == :element + '' + end + end + + + # Expr takes a stack of path elements and a set of nodes (either a Parent + # or an Array and returns an Array of matching nodes + def expr( path_stack, nodeset, context=nil ) + enter(:expr, path_stack, nodeset) if @debug + return nodeset if path_stack.length == 0 || nodeset.length == 0 + while path_stack.length > 0 + trace(:while, path_stack, nodeset) if @debug + if nodeset.length == 0 + path_stack.clear + return [] + end + op = path_stack.shift + case op + when :document + first_raw_node = nodeset.first.raw_node + nodeset = [XPathNode.new(first_raw_node.root_node, position: 1)] + when :self + nodeset = step(path_stack) do + [nodeset] + end + when :child + nodeset = step(path_stack) do + child(nodeset) + end + when :literal + trace(:literal, path_stack, nodeset) if @debug + return path_stack.shift + when :attribute + nodeset = step(path_stack, any_type: :attribute) do + nodesets = [] + nodeset.each do |node| + raw_node = node.raw_node + next unless raw_node.node_type == :element + attributes = raw_node.attributes + next if attributes.empty? + nodesets << attributes.each_attribute.collect.with_index do |attribute, i| + XPathNode.new(attribute, position: i + 1) + end + end + nodesets + end + when :namespace + pre_defined_namespaces = { + "xml" => "http://www.w3.org/XML/1998/namespace", + } + nodeset = step(path_stack, any_type: :namespace) do + nodesets = [] + nodeset.each do |node| + raw_node = node.raw_node + case raw_node.node_type + when :element + if @namespaces + nodesets << pre_defined_namespaces.merge(@namespaces) + else + nodesets << pre_defined_namespaces.merge(raw_node.namespaces) + end + when :attribute + if @namespaces + nodesets << pre_defined_namespaces.merge(@namespaces) + else + nodesets << pre_defined_namespaces.merge(raw_node.element.namespaces) + end + end + end + nodesets + end + when :parent + nodeset = step(path_stack) do + nodesets = [] + nodeset.each do |node| + raw_node = node.raw_node + if raw_node.node_type == :attribute + parent = raw_node.element + else + parent = raw_node.parent + end + nodesets << [XPathNode.new(parent, position: 1)] if parent + end + nodesets + end + when :ancestor + nodeset = step(path_stack) do + nodesets = [] + # new_nodes = {} + nodeset.each do |node| + raw_node = node.raw_node + new_nodeset = [] + while raw_node.parent + raw_node = raw_node.parent + # next if new_nodes.key?(node) + new_nodeset << XPathNode.new(raw_node, + position: new_nodeset.size + 1) + # new_nodes[node] = true + end + nodesets << new_nodeset unless new_nodeset.empty? + end + nodesets + end + when :ancestor_or_self + nodeset = step(path_stack) do + nodesets = [] + # new_nodes = {} + nodeset.each do |node| + raw_node = node.raw_node + next unless raw_node.node_type == :element + new_nodeset = [XPathNode.new(raw_node, position: 1)] + # new_nodes[node] = true + while raw_node.parent + raw_node = raw_node.parent + # next if new_nodes.key?(node) + new_nodeset << XPathNode.new(raw_node, + position: new_nodeset.size + 1) + # new_nodes[node] = true + end + nodesets << new_nodeset unless new_nodeset.empty? + end + nodesets + end + when :descendant_or_self + nodeset = step(path_stack) do + descendant(nodeset, true) + end + when :descendant + nodeset = step(path_stack) do + descendant(nodeset, false) + end + when :following_sibling + nodeset = step(path_stack) do + nodesets = [] + nodeset.each do |node| + raw_node = node.raw_node + next unless raw_node.respond_to?(:parent) + next if raw_node.parent.nil? + all_siblings = raw_node.parent.children + current_index = all_siblings.index(raw_node) + following_siblings = all_siblings[(current_index + 1)..-1] + next if following_siblings.empty? + nodesets << following_siblings.collect.with_index do |sibling, i| + XPathNode.new(sibling, position: i + 1) + end + end + nodesets + end + when :preceding_sibling + nodeset = step(path_stack, order: :reverse) do + nodesets = [] + nodeset.each do |node| + raw_node = node.raw_node + next unless raw_node.respond_to?(:parent) + next if raw_node.parent.nil? + all_siblings = raw_node.parent.children + current_index = all_siblings.index(raw_node) + preceding_siblings = all_siblings[0, current_index].reverse + next if preceding_siblings.empty? + nodesets << preceding_siblings.collect.with_index do |sibling, i| + XPathNode.new(sibling, position: i + 1) + end + end + nodesets + end + when :preceding + nodeset = step(path_stack, order: :reverse) do + unnode(nodeset) do |node| + preceding(node) + end + end + when :following + nodeset = step(path_stack) do + unnode(nodeset) do |node| + following(node) + end + end + when :variable + var_name = path_stack.shift + return [@variables[var_name]] + + when :eq, :neq, :lt, :lteq, :gt, :gteq + left = expr( path_stack.shift, nodeset.dup, context ) + right = expr( path_stack.shift, nodeset.dup, context ) + res = equality_relational_compare( left, op, right ) + trace(op, left, right, res) if @debug + return res + + when :or + left = expr(path_stack.shift, nodeset.dup, context) + return true if Functions.boolean(left) + right = expr(path_stack.shift, nodeset.dup, context) + return Functions.boolean(right) + + when :and + left = expr(path_stack.shift, nodeset.dup, context) + return false unless Functions.boolean(left) + right = expr(path_stack.shift, nodeset.dup, context) + return Functions.boolean(right) + + when :div, :mod, :mult, :plus, :minus + left = expr(path_stack.shift, nodeset, context) + right = expr(path_stack.shift, nodeset, context) + left = unnode(left) if left.is_a?(Array) + right = unnode(right) if right.is_a?(Array) + left = Functions::number(left) + right = Functions::number(right) + case op + when :div + return left / right + when :mod + return left % right + when :mult + return left * right + when :plus + return left + right + when :minus + return left - right + else + raise "[BUG] Unexpected operator: <#{op.inspect}>" + end + when :union + left = expr( path_stack.shift, nodeset, context ) + right = expr( path_stack.shift, nodeset, context ) + left = unnode(left) if left.is_a?(Array) + right = unnode(right) if right.is_a?(Array) + return (left | right) + when :neg + res = expr( path_stack, nodeset, context ) + res = unnode(res) if res.is_a?(Array) + return -Functions.number(res) + when :not + when :function + func_name = path_stack.shift.tr('-','_') + arguments = path_stack.shift + + if nodeset.size != 1 + message = "[BUG] Node set size must be 1 for function call: " + message += "<#{func_name}>: <#{nodeset.inspect}>: " + message += "<#{arguments.inspect}>" + raise message + end + + node = nodeset.first + if context + target_context = context + else + target_context = {:size => nodeset.size} + if node.is_a?(XPathNode) + target_context[:node] = node.raw_node + target_context[:index] = node.position + else + target_context[:node] = node + target_context[:index] = 1 + end + end + args = arguments.dclone.collect do |arg| + result = expr(arg, nodeset, target_context) + result = unnode(result) if result.is_a?(Array) + result + end + Functions.context = target_context + return Functions.send(func_name, *args) + + else + raise "[BUG] Unexpected path: <#{op.inspect}>: <#{path_stack.inspect}>" + end + end # while + return nodeset + ensure + leave(:expr, path_stack, nodeset) if @debug + end + + def step(path_stack, any_type: :element, order: :forward) + nodesets = yield + begin + enter(:step, path_stack, nodesets) if @debug + nodesets = node_test(path_stack, nodesets, any_type: any_type) + while path_stack[0] == :predicate + path_stack.shift # :predicate + predicate_expression = path_stack.shift.dclone + nodesets = evaluate_predicate(predicate_expression, nodesets) + end + if nodesets.size == 1 + ordered_nodeset = nodesets[0] + else + raw_nodes = [] + nodesets.each do |nodeset| + nodeset.each do |node| + if node.respond_to?(:raw_node) + raw_nodes << node.raw_node + else + raw_nodes << node + end + end + end + ordered_nodeset = sort(raw_nodes, order) + end + new_nodeset = [] + ordered_nodeset.each do |node| + # TODO: Remove duplicated + new_nodeset << XPathNode.new(node, position: new_nodeset.size + 1) + end + new_nodeset + ensure + leave(:step, path_stack, new_nodeset) if @debug + end + end + + def node_test(path_stack, nodesets, any_type: :element) + enter(:node_test, path_stack, nodesets) if @debug + operator = path_stack.shift + case operator + when :qname + prefix = path_stack.shift + name = path_stack.shift + new_nodesets = nodesets.collect do |nodeset| + filter_nodeset(nodeset) do |node| + raw_node = node.raw_node + case raw_node.node_type + when :element + if prefix.nil? + raw_node.name == name + elsif prefix.empty? + if strict? + raw_node.name == name and raw_node.namespace == "" + else + raw_node.name == name and raw_node.namespace == get_namespace(raw_node, prefix) + end + else + raw_node.name == name and raw_node.namespace == get_namespace(raw_node, prefix) + end + when :attribute + if prefix.nil? + raw_node.name == name + elsif prefix.empty? + raw_node.name == name and raw_node.namespace == "" + else + raw_node.name == name and raw_node.namespace == get_namespace(raw_node.element, prefix) + end + else + false + end + end + end + when :namespace + prefix = path_stack.shift + new_nodesets = nodesets.collect do |nodeset| + filter_nodeset(nodeset) do |node| + raw_node = node.raw_node + case raw_node.node_type + when :element + namespaces = @namespaces || raw_node.namespaces + raw_node.namespace == namespaces[prefix] + when :attribute + namespaces = @namespaces || raw_node.element.namespaces + raw_node.namespace == namespaces[prefix] + else + false + end + end + end + when :any + new_nodesets = nodesets.collect do |nodeset| + filter_nodeset(nodeset) do |node| + raw_node = node.raw_node + raw_node.node_type == any_type + end + end + when :comment + new_nodesets = nodesets.collect do |nodeset| + filter_nodeset(nodeset) do |node| + raw_node = node.raw_node + raw_node.node_type == :comment + end + end + when :text + new_nodesets = nodesets.collect do |nodeset| + filter_nodeset(nodeset) do |node| + raw_node = node.raw_node + raw_node.node_type == :text + end + end + when :processing_instruction + target = path_stack.shift + new_nodesets = nodesets.collect do |nodeset| + filter_nodeset(nodeset) do |node| + raw_node = node.raw_node + (raw_node.node_type == :processing_instruction) and + (target.empty? or (raw_node.target == target)) + end + end + when :node + new_nodesets = nodesets.collect do |nodeset| + filter_nodeset(nodeset) do |node| + true + end + end + else + message = "[BUG] Unexpected node test: " + + "<#{operator.inspect}>: <#{path_stack.inspect}>" + raise message + end + new_nodesets + ensure + leave(:node_test, path_stack, new_nodesets) if @debug + end + + def filter_nodeset(nodeset) + new_nodeset = [] + nodeset.each do |node| + next unless yield(node) + new_nodeset << XPathNode.new(node, position: new_nodeset.size + 1) + end + new_nodeset + end + + def evaluate_predicate(expression, nodesets) + enter(:predicate, expression, nodesets) if @debug + new_nodeset_count = 0 + new_nodesets = nodesets.collect do |nodeset| + new_nodeset = [] + subcontext = { :size => nodeset.size } + nodeset.each_with_index do |node, index| + if node.is_a?(XPathNode) + subcontext[:node] = node.raw_node + subcontext[:index] = node.position + else + subcontext[:node] = node + subcontext[:index] = index + 1 + end + result = expr(expression.dclone, [node], subcontext) + trace(:predicate_evaluate, expression, node, subcontext, result) if @debug + result = result[0] if result.kind_of? Array and result.length == 1 + if result.kind_of? Numeric + if result == node.position + new_nodeset_count += 1 + new_nodeset << XPathNode.new(node, position: new_nodeset_count) + end + elsif result.instance_of? Array + if result.size > 0 and result.inject(false) {|k,s| s or k} + if result.size > 0 + new_nodeset_count += 1 + new_nodeset << XPathNode.new(node, position: new_nodeset_count) + end + end + else + if result + new_nodeset_count += 1 + new_nodeset << XPathNode.new(node, position: new_nodeset_count) + end + end + end + new_nodeset + end + new_nodesets + ensure + leave(:predicate, new_nodesets) if @debug + end + + def trace(*args) + indent = " " * @nest + PP.pp(args, "").each_line do |line| + puts("#{indent}#{line}") + end + end + + def enter(tag, *args) + trace(:enter, tag, *args) + @nest += 1 + end + + def leave(tag, *args) + @nest -= 1 + trace(:leave, tag, *args) + end + + # Reorders an array of nodes so that they are in document order + # It tries to do this efficiently. + # + # FIXME: I need to get rid of this, but the issue is that most of the XPath + # interpreter functions as a filter, which means that we lose context going + # in and out of function calls. If I knew what the index of the nodes was, + # I wouldn't have to do this. Maybe add a document IDX for each node? + # Problems with mutable documents. Or, rewrite everything. + def sort(array_of_nodes, order) + new_arry = [] + array_of_nodes.each { |node| + node_idx = [] + np = node.node_type == :attribute ? node.element : node + while np.parent and np.parent.node_type == :element + node_idx << np.parent.index( np ) + np = np.parent + end + new_arry << [ node_idx.reverse, node ] + } + ordered = new_arry.sort_by do |index, node| + if order == :forward + index + else + index.map(&:-@) + end + end + ordered.collect do |_index, node| + node + end + end + + def descendant(nodeset, include_self) + nodesets = [] + nodeset.each do |node| + new_nodeset = [] + new_nodes = {} + descendant_recursive(node.raw_node, new_nodeset, new_nodes, include_self) + nodesets << new_nodeset unless new_nodeset.empty? + end + nodesets + end + + def descendant_recursive(raw_node, new_nodeset, new_nodes, include_self) + if include_self + return if new_nodes.key?(raw_node) + new_nodeset << XPathNode.new(raw_node, position: new_nodeset.size + 1) + new_nodes[raw_node] = true + end + + node_type = raw_node.node_type + if node_type == :element or node_type == :document + raw_node.children.each do |child| + descendant_recursive(child, new_nodeset, new_nodes, true) + end + end + end + + # Builds a nodeset of all of the preceding nodes of the supplied node, + # in reverse document order + # preceding:: includes every element in the document that precedes this node, + # except for ancestors + def preceding(node) + ancestors = [] + parent = node.parent + while parent + ancestors << parent + parent = parent.parent + end + + precedings = [] + preceding_node = preceding_node_of(node) + while preceding_node + if ancestors.include?(preceding_node) + ancestors.delete(preceding_node) + else + precedings << XPathNode.new(preceding_node, + position: precedings.size + 1) + end + preceding_node = preceding_node_of(preceding_node) + end + precedings + end + + def preceding_node_of( node ) + psn = node.previous_sibling_node + if psn.nil? + if node.parent.nil? or node.parent.class == Document + return nil + end + return node.parent + #psn = preceding_node_of( node.parent ) + end + while psn and psn.kind_of? Element and psn.children.size > 0 + psn = psn.children[-1] + end + psn + end + + def following(node) + followings = [] + following_node = next_sibling_node(node) + while following_node + followings << XPathNode.new(following_node, + position: followings.size + 1) + following_node = following_node_of(following_node) + end + followings + end + + def following_node_of( node ) + return node.children[0] if node.kind_of?(Element) and node.children.size > 0 + + next_sibling_node(node) + end + + def next_sibling_node(node) + psn = node.next_sibling_node + while psn.nil? + return nil if node.parent.nil? or node.parent.class == Document + node = node.parent + psn = node.next_sibling_node + end + psn + end + + def child(nodeset) + nodesets = [] + nodeset.each do |node| + raw_node = node.raw_node + node_type = raw_node.node_type + # trace(:child, node_type, node) + case node_type + when :element + nodesets << raw_node.children.collect.with_index do |child_node, i| + XPathNode.new(child_node, position: i + 1) + end + when :document + new_nodeset = [] + raw_node.children.each do |child| + case child + when XMLDecl, Text + # Ignore + else + new_nodeset << XPathNode.new(child, position: new_nodeset.size + 1) + end + end + nodesets << new_nodeset unless new_nodeset.empty? + end + end + nodesets + end + + def norm b + case b + when true, false + b + when 'true', 'false' + Functions::boolean( b ) + when /^\d+(\.\d+)?$/, Numeric + Functions::number( b ) + else + Functions::string( b ) + end + end + + def equality_relational_compare(set1, op, set2) + set1 = unnode(set1) if set1.is_a?(Array) + set2 = unnode(set2) if set2.is_a?(Array) + + if set1.kind_of? Array and set2.kind_of? Array + # If both objects to be compared are node-sets, then the + # comparison will be true if and only if there is a node in the + # first node-set and a node in the second node-set such that the + # result of performing the comparison on the string-values of + # the two nodes is true. + set1.product(set2).any? do |node1, node2| + node_string1 = Functions.string(node1) + node_string2 = Functions.string(node2) + compare(node_string1, op, node_string2) + end + elsif set1.kind_of? Array or set2.kind_of? Array + # If one is nodeset and other is number, compare number to each item + # in nodeset s.t. number op number(string(item)) + # If one is nodeset and other is string, compare string to each item + # in nodeset s.t. string op string(item) + # If one is nodeset and other is boolean, compare boolean to each item + # in nodeset s.t. boolean op boolean(item) + if set1.kind_of? Array + a = set1 + b = set2 + else + a = set2 + b = set1 + end + + case b + when true, false + each_unnode(a).any? do |unnoded| + compare(Functions.boolean(unnoded), op, b) + end + when Numeric + each_unnode(a).any? do |unnoded| + compare(Functions.number(unnoded), op, b) + end + when /\A\d+(\.\d+)?\z/ + b = Functions.number(b) + each_unnode(a).any? do |unnoded| + compare(Functions.number(unnoded), op, b) + end + else + b = Functions::string(b) + each_unnode(a).any? do |unnoded| + compare(Functions::string(unnoded), op, b) + end + end + else + # If neither is nodeset, + # If op is = or != + # If either boolean, convert to boolean + # If either number, convert to number + # Else, convert to string + # Else + # Convert both to numbers and compare + compare(set1, op, set2) + end + end + + def value_type(value) + case value + when true, false + :boolean + when Numeric + :number + when String + :string + else + raise "[BUG] Unexpected value type: <#{value.inspect}>" + end + end + + def normalize_compare_values(a, operator, b) + a_type = value_type(a) + b_type = value_type(b) + case operator + when :eq, :neq + if a_type == :boolean or b_type == :boolean + a = Functions.boolean(a) unless a_type == :boolean + b = Functions.boolean(b) unless b_type == :boolean + elsif a_type == :number or b_type == :number + a = Functions.number(a) unless a_type == :number + b = Functions.number(b) unless b_type == :number + else + a = Functions.string(a) unless a_type == :string + b = Functions.string(b) unless b_type == :string + end + when :lt, :lteq, :gt, :gteq + a = Functions.number(a) unless a_type == :number + b = Functions.number(b) unless b_type == :number + else + message = "[BUG] Unexpected compare operator: " + + "<#{operator.inspect}>: <#{a.inspect}>: <#{b.inspect}>" + raise message + end + [a, b] + end + + def compare(a, operator, b) + a, b = normalize_compare_values(a, operator, b) + case operator + when :eq + a == b + when :neq + a != b + when :lt + a < b + when :lteq + a <= b + when :gt + a > b + when :gteq + a >= b + else + message = "[BUG] Unexpected compare operator: " + + "<#{operator.inspect}>: <#{a.inspect}>: <#{b.inspect}>" + raise message + end + end + + def each_unnode(nodeset) + return to_enum(__method__, nodeset) unless block_given? + nodeset.each do |node| + if node.is_a?(XPathNode) + unnoded = node.raw_node + else + unnoded = node + end + yield(unnoded) + end + end + + def unnode(nodeset) + each_unnode(nodeset).collect do |unnoded| + unnoded = yield(unnoded) if block_given? + unnoded + end + end + end + + # @private + class XPathNode + attr_reader :raw_node, :context + def initialize(node, context=nil) + if node.is_a?(XPathNode) + @raw_node = node.raw_node + else + @raw_node = node + end + @context = context || {} + end + + def position + @context[:position] + end + end +end diff -Nru ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml.rb ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml.rb --- ruby3.3-3.3.8/.bundle/gems/rexml-3.4.4/lib/rexml.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/gems/rexml-3.4.4/lib/rexml.rb 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,3 @@ +# frozen_string_literal: true + +require_relative "rexml/document" diff -Nru ruby3.3-3.3.8/.bundle/specifications/net-imap-0.4.19.gemspec ruby3.3-3.3.13/.bundle/specifications/net-imap-0.4.19.gemspec --- ruby3.3-3.3.8/.bundle/specifications/net-imap-0.4.19.gemspec 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/specifications/net-imap-0.4.19.gemspec 1970-01-01 00:00:00.000000000 +0000 @@ -1,26 +0,0 @@ -# -*- encoding: utf-8 -*- -# stub: net-imap 0.4.19 ruby lib - -Gem::Specification.new do |s| - s.name = "net-imap".freeze - s.version = "0.4.19" - - s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version= - s.metadata = { "changelog_uri" => "https://github.com/ruby/net-imap/releases", "homepage_uri" => "https://github.com/ruby/net-imap", "source_code_uri" => "https://github.com/ruby/net-imap" } if s.respond_to? :metadata= - s.require_paths = ["lib".freeze] - s.authors = ["Shugo Maeda".freeze, "nicholas a. evans".freeze] - s.bindir = "exe".freeze - s.date = "2025-02-07" - s.description = "Ruby client api for Internet Message Access Protocol".freeze - s.email = ["shugo@ruby-lang.org".freeze, "nick@rubinick.dev".freeze] - s.files = ["BSDL".freeze, "COPYING".freeze, "Gemfile".freeze, "LICENSE.txt".freeze, "README.md".freeze, "Rakefile".freeze, "docs/styles.css".freeze, "lib/net/imap.rb".freeze, "lib/net/imap/authenticators.rb".freeze, "lib/net/imap/command_data.rb".freeze, "lib/net/imap/config.rb".freeze, "lib/net/imap/config/attr_accessors.rb".freeze, "lib/net/imap/config/attr_inheritance.rb".freeze, "lib/net/imap/config/attr_type_coercion.rb".freeze, "lib/net/imap/data_encoding.rb".freeze, "lib/net/imap/deprecated_client_options.rb".freeze, "lib/net/imap/errors.rb".freeze, "lib/net/imap/fetch_data.rb".freeze, "lib/net/imap/flags.rb".freeze, "lib/net/imap/response_data.rb".freeze, "lib/net/imap/response_parser.rb".freeze, "lib/net/imap/response_parser/parser_utils.rb".freeze, "lib/net/imap/sasl.rb".freeze, "lib/net/imap/sasl/anonymous_authenticator.rb".freeze, "lib/net/imap/sasl/authentication_exchange.rb".freeze, "lib/net/imap/sasl/authenticators.rb".freeze, "lib/net/imap/sasl/client_adapter.rb".freeze, "lib/net/imap/sasl/cram_md5_authenticator.rb".freeze, "lib/net/imap/sasl/digest_md5_authenticator.rb".freeze, "lib/net/imap/sasl/external_authenticator.rb".freeze, "lib/net/imap/sasl/gs2_header.rb".freeze, "lib/net/imap/sasl/login_authenticator.rb".freeze, "lib/net/imap/sasl/oauthbearer_authenticator.rb".freeze, "lib/net/imap/sasl/plain_authenticator.rb".freeze, "lib/net/imap/sasl/protocol_adapters.rb".freeze, "lib/net/imap/sasl/scram_algorithm.rb".freeze, "lib/net/imap/sasl/scram_authenticator.rb".freeze, "lib/net/imap/sasl/stringprep.rb".freeze, "lib/net/imap/sasl/xoauth2_authenticator.rb".freeze, "lib/net/imap/sasl_adapter.rb".freeze, "lib/net/imap/search_result.rb".freeze, "lib/net/imap/sequence_set.rb".freeze, "lib/net/imap/stringprep.rb".freeze, "lib/net/imap/stringprep/nameprep.rb".freeze, "lib/net/imap/stringprep/saslprep.rb".freeze, "lib/net/imap/stringprep/saslprep_tables.rb".freeze, "lib/net/imap/stringprep/tables.rb".freeze, "lib/net/imap/stringprep/trace.rb".freeze, "lib/net/imap/uidplus_data.rb".freeze, "net-imap.gemspec".freeze, "rakelib/benchmarks.rake".freeze, "rakelib/rdoc.rake".freeze, "rakelib/rfcs.rake".freeze, "rakelib/saslprep.rake".freeze, "rakelib/string_prep_tables_generator.rb".freeze, "sample/net-imap.rb".freeze] - s.homepage = "https://github.com/ruby/net-imap".freeze - s.licenses = ["Ruby".freeze, "BSD-2-Clause".freeze] - s.required_ruby_version = Gem::Requirement.new(">= 2.7.3".freeze) - s.rubygems_version = "3.4.20".freeze - s.summary = "Ruby client api for Internet Message Access Protocol".freeze - - s.specification_version = 4 - - s.add_runtime_dependency(%q<date>.freeze, [">= 0"]) -end diff -Nru ruby3.3-3.3.8/.bundle/specifications/net-imap-0.4.25.gemspec ruby3.3-3.3.13/.bundle/specifications/net-imap-0.4.25.gemspec --- ruby3.3-3.3.8/.bundle/specifications/net-imap-0.4.25.gemspec 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/specifications/net-imap-0.4.25.gemspec 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,26 @@ +# -*- encoding: utf-8 -*- +# stub: net-imap 0.4.25 ruby lib + +Gem::Specification.new do |s| + s.name = "net-imap".freeze + s.version = "0.4.25" + + s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version= + s.metadata = { "changelog_uri" => "https://github.com/ruby/net-imap/releases", "homepage_uri" => "https://github.com/ruby/net-imap", "source_code_uri" => "https://github.com/ruby/net-imap" } if s.respond_to? :metadata= + s.require_paths = ["lib".freeze] + s.authors = ["Shugo Maeda".freeze, "nicholas a. evans".freeze] + s.bindir = "exe".freeze + s.date = "1980-01-02" + s.description = "Ruby client api for Internet Message Access Protocol".freeze + s.email = ["shugo@ruby-lang.org".freeze, "nick@rubinick.dev".freeze] + s.files = ["BSDL".freeze, "COPYING".freeze, "Gemfile".freeze, "LICENSE.txt".freeze, "README.md".freeze, "Rakefile".freeze, "docs/styles.css".freeze, "lib/net/imap.rb".freeze, "lib/net/imap/authenticators.rb".freeze, "lib/net/imap/command_data.rb".freeze, "lib/net/imap/config.rb".freeze, "lib/net/imap/config/attr_accessors.rb".freeze, "lib/net/imap/config/attr_inheritance.rb".freeze, "lib/net/imap/config/attr_type_coercion.rb".freeze, "lib/net/imap/data_encoding.rb".freeze, "lib/net/imap/deprecated_client_options.rb".freeze, "lib/net/imap/errors.rb".freeze, "lib/net/imap/fetch_data.rb".freeze, "lib/net/imap/flags.rb".freeze, "lib/net/imap/response_data.rb".freeze, "lib/net/imap/response_parser.rb".freeze, "lib/net/imap/response_parser/parser_utils.rb".freeze, "lib/net/imap/response_reader.rb".freeze, "lib/net/imap/sasl.rb".freeze, "lib/net/imap/sasl/anonymous_authenticator.rb".freeze, "lib/net/imap/sasl/authentication_exchange.rb".freeze, "lib/net/imap/sasl/authenticators.rb".freeze, "lib/net/imap/sasl/client_adapter.rb".freeze, "lib/net/imap/sasl/cram_md5_authenticator.rb".freeze, "lib/net/imap/sasl/digest_md5_authenticator.rb".freeze, "lib/net/imap/sasl/external_authenticator.rb".freeze, "lib/net/imap/sasl/gs2_header.rb".freeze, "lib/net/imap/sasl/login_authenticator.rb".freeze, "lib/net/imap/sasl/oauthbearer_authenticator.rb".freeze, "lib/net/imap/sasl/plain_authenticator.rb".freeze, "lib/net/imap/sasl/protocol_adapters.rb".freeze, "lib/net/imap/sasl/scram_algorithm.rb".freeze, "lib/net/imap/sasl/scram_authenticator.rb".freeze, "lib/net/imap/sasl/stringprep.rb".freeze, "lib/net/imap/sasl/xoauth2_authenticator.rb".freeze, "lib/net/imap/sasl_adapter.rb".freeze, "lib/net/imap/search_result.rb".freeze, "lib/net/imap/sequence_set.rb".freeze, "lib/net/imap/stringprep.rb".freeze, "lib/net/imap/stringprep/nameprep.rb".freeze, "lib/net/imap/stringprep/saslprep.rb".freeze, "lib/net/imap/stringprep/saslprep_tables.rb".freeze, "lib/net/imap/stringprep/tables.rb".freeze, "lib/net/imap/stringprep/trace.rb".freeze, "lib/net/imap/uidplus_data.rb".freeze, "net-imap.gemspec".freeze, "rakelib/benchmarks.rake".freeze, "rakelib/rdoc.rake".freeze, "rakelib/rfcs.rake".freeze, "rakelib/saslprep.rake".freeze, "rakelib/string_prep_tables_generator.rb".freeze, "sample/net-imap.rb".freeze] + s.homepage = "https://github.com/ruby/net-imap".freeze + s.licenses = ["Ruby".freeze, "BSD-2-Clause".freeze] + s.required_ruby_version = Gem::Requirement.new(">= 2.7.3".freeze) + s.rubygems_version = "3.4.20".freeze + s.summary = "Ruby client api for Internet Message Access Protocol".freeze + + s.specification_version = 4 + + s.add_runtime_dependency(%q<date>.freeze, [">= 0"]) +end diff -Nru ruby3.3-3.3.8/.bundle/specifications/rexml-3.3.9.gemspec ruby3.3-3.3.13/.bundle/specifications/rexml-3.3.9.gemspec --- ruby3.3-3.3.8/.bundle/specifications/rexml-3.3.9.gemspec 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/specifications/rexml-3.3.9.gemspec 1970-01-01 00:00:00.000000000 +0000 @@ -1,23 +0,0 @@ -# -*- encoding: utf-8 -*- -# stub: rexml 3.3.9 ruby lib - -Gem::Specification.new do |s| - s.name = "rexml".freeze - s.version = "3.3.9" - - s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version= - s.metadata = { "changelog_uri" => "https://github.com/ruby/rexml/releases/tag/v3.3.9" } if s.respond_to? :metadata= - s.require_paths = ["lib".freeze] - s.authors = ["Kouhei Sutou".freeze] - s.date = "2024-10-24" - s.description = "An XML toolkit for Ruby".freeze - s.email = ["kou@cozmixng.org".freeze] - s.extra_rdoc_files = ["LICENSE.txt".freeze, "NEWS.md".freeze, "README.md".freeze, "doc/rexml/context.rdoc".freeze, "doc/rexml/tasks/rdoc/child.rdoc".freeze, "doc/rexml/tasks/rdoc/document.rdoc".freeze, "doc/rexml/tasks/rdoc/element.rdoc".freeze, "doc/rexml/tasks/rdoc/node.rdoc".freeze, "doc/rexml/tasks/rdoc/parent.rdoc".freeze, "doc/rexml/tasks/tocs/child_toc.rdoc".freeze, "doc/rexml/tasks/tocs/document_toc.rdoc".freeze, "doc/rexml/tasks/tocs/element_toc.rdoc".freeze, "doc/rexml/tasks/tocs/master_toc.rdoc".freeze, "doc/rexml/tasks/tocs/node_toc.rdoc".freeze, "doc/rexml/tasks/tocs/parent_toc.rdoc".freeze, "doc/rexml/tutorial.rdoc".freeze] - s.files = ["LICENSE.txt".freeze, "NEWS.md".freeze, "README.md".freeze, "doc/rexml/context.rdoc".freeze, "doc/rexml/tasks/rdoc/child.rdoc".freeze, "doc/rexml/tasks/rdoc/document.rdoc".freeze, "doc/rexml/tasks/rdoc/element.rdoc".freeze, "doc/rexml/tasks/rdoc/node.rdoc".freeze, "doc/rexml/tasks/rdoc/parent.rdoc".freeze, "doc/rexml/tasks/tocs/child_toc.rdoc".freeze, "doc/rexml/tasks/tocs/document_toc.rdoc".freeze, "doc/rexml/tasks/tocs/element_toc.rdoc".freeze, "doc/rexml/tasks/tocs/master_toc.rdoc".freeze, "doc/rexml/tasks/tocs/node_toc.rdoc".freeze, "doc/rexml/tasks/tocs/parent_toc.rdoc".freeze, "doc/rexml/tutorial.rdoc".freeze, "lib/rexml.rb".freeze, "lib/rexml/attlistdecl.rb".freeze, "lib/rexml/attribute.rb".freeze, "lib/rexml/cdata.rb".freeze, "lib/rexml/child.rb".freeze, "lib/rexml/comment.rb".freeze, "lib/rexml/doctype.rb".freeze, "lib/rexml/document.rb".freeze, "lib/rexml/dtd/attlistdecl.rb".freeze, "lib/rexml/dtd/dtd.rb".freeze, "lib/rexml/dtd/elementdecl.rb".freeze, "lib/rexml/dtd/entitydecl.rb".freeze, "lib/rexml/dtd/notationdecl.rb".freeze, "lib/rexml/element.rb".freeze, "lib/rexml/encoding.rb".freeze, "lib/rexml/entity.rb".freeze, "lib/rexml/formatters/default.rb".freeze, "lib/rexml/formatters/pretty.rb".freeze, "lib/rexml/formatters/transitive.rb".freeze, "lib/rexml/functions.rb".freeze, "lib/rexml/instruction.rb".freeze, "lib/rexml/light/node.rb".freeze, "lib/rexml/namespace.rb".freeze, "lib/rexml/node.rb".freeze, "lib/rexml/output.rb".freeze, "lib/rexml/parent.rb".freeze, "lib/rexml/parseexception.rb".freeze, "lib/rexml/parsers/baseparser.rb".freeze, "lib/rexml/parsers/lightparser.rb".freeze, "lib/rexml/parsers/pullparser.rb".freeze, "lib/rexml/parsers/sax2parser.rb".freeze, "lib/rexml/parsers/streamparser.rb".freeze, "lib/rexml/parsers/treeparser.rb".freeze, "lib/rexml/parsers/ultralightparser.rb".freeze, "lib/rexml/parsers/xpathparser.rb".freeze, "lib/rexml/quickpath.rb".freeze, "lib/rexml/rexml.rb".freeze, "lib/rexml/sax2listener.rb".freeze, "lib/rexml/security.rb".freeze, "lib/rexml/source.rb".freeze, "lib/rexml/streamlistener.rb".freeze, "lib/rexml/text.rb".freeze, "lib/rexml/undefinednamespaceexception.rb".freeze, "lib/rexml/validation/relaxng.rb".freeze, "lib/rexml/validation/validation.rb".freeze, "lib/rexml/validation/validationexception.rb".freeze, "lib/rexml/xmldecl.rb".freeze, "lib/rexml/xmltokens.rb".freeze, "lib/rexml/xpath.rb".freeze, "lib/rexml/xpath_parser.rb".freeze] - s.homepage = "https://github.com/ruby/rexml".freeze - s.licenses = ["BSD-2-Clause".freeze] - s.rdoc_options = ["--main".freeze, "README.md".freeze] - s.required_ruby_version = Gem::Requirement.new(">= 2.5.0".freeze) - s.rubygems_version = "3.4.20".freeze - s.summary = "An XML toolkit for Ruby".freeze -end diff -Nru ruby3.3-3.3.8/.bundle/specifications/rexml-3.4.4.gemspec ruby3.3-3.3.13/.bundle/specifications/rexml-3.4.4.gemspec --- ruby3.3-3.3.8/.bundle/specifications/rexml-3.4.4.gemspec 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/.bundle/specifications/rexml-3.4.4.gemspec 2026-10-23 03:17:43.000000000 +0000 @@ -0,0 +1,23 @@ +# -*- encoding: utf-8 -*- +# stub: rexml 3.4.4 ruby lib + +Gem::Specification.new do |s| + s.name = "rexml".freeze + s.version = "3.4.4" + + s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version= + s.metadata = { "changelog_uri" => "https://github.com/ruby/rexml/releases/tag/v3.4.4" } if s.respond_to? :metadata= + s.require_paths = ["lib".freeze] + s.authors = ["Kouhei Sutou".freeze] + s.date = "1980-01-02" + s.description = "An XML toolkit for Ruby".freeze + s.email = ["kou@cozmixng.org".freeze] + s.extra_rdoc_files = ["LICENSE.txt".freeze, "NEWS.md".freeze, "README.md".freeze, "doc/rexml/context.rdoc".freeze, "doc/rexml/tasks/rdoc/child.rdoc".freeze, "doc/rexml/tasks/rdoc/document.rdoc".freeze, "doc/rexml/tasks/rdoc/element.rdoc".freeze, "doc/rexml/tasks/rdoc/node.rdoc".freeze, "doc/rexml/tasks/rdoc/parent.rdoc".freeze, "doc/rexml/tasks/tocs/child_toc.rdoc".freeze, "doc/rexml/tasks/tocs/document_toc.rdoc".freeze, "doc/rexml/tasks/tocs/element_toc.rdoc".freeze, "doc/rexml/tasks/tocs/master_toc.rdoc".freeze, "doc/rexml/tasks/tocs/node_toc.rdoc".freeze, "doc/rexml/tasks/tocs/parent_toc.rdoc".freeze, "doc/rexml/tutorial.rdoc".freeze] + s.files = ["LICENSE.txt".freeze, "NEWS.md".freeze, "README.md".freeze, "doc/rexml/context.rdoc".freeze, "doc/rexml/tasks/rdoc/child.rdoc".freeze, "doc/rexml/tasks/rdoc/document.rdoc".freeze, "doc/rexml/tasks/rdoc/element.rdoc".freeze, "doc/rexml/tasks/rdoc/node.rdoc".freeze, "doc/rexml/tasks/rdoc/parent.rdoc".freeze, "doc/rexml/tasks/tocs/child_toc.rdoc".freeze, "doc/rexml/tasks/tocs/document_toc.rdoc".freeze, "doc/rexml/tasks/tocs/element_toc.rdoc".freeze, "doc/rexml/tasks/tocs/master_toc.rdoc".freeze, "doc/rexml/tasks/tocs/node_toc.rdoc".freeze, "doc/rexml/tasks/tocs/parent_toc.rdoc".freeze, "doc/rexml/tutorial.rdoc".freeze, "lib/rexml.rb".freeze, "lib/rexml/attlistdecl.rb".freeze, "lib/rexml/attribute.rb".freeze, "lib/rexml/cdata.rb".freeze, "lib/rexml/child.rb".freeze, "lib/rexml/comment.rb".freeze, "lib/rexml/doctype.rb".freeze, "lib/rexml/document.rb".freeze, "lib/rexml/dtd/attlistdecl.rb".freeze, "lib/rexml/dtd/dtd.rb".freeze, "lib/rexml/dtd/elementdecl.rb".freeze, "lib/rexml/dtd/entitydecl.rb".freeze, "lib/rexml/dtd/notationdecl.rb".freeze, "lib/rexml/element.rb".freeze, "lib/rexml/encoding.rb".freeze, "lib/rexml/entity.rb".freeze, "lib/rexml/formatters/default.rb".freeze, "lib/rexml/formatters/pretty.rb".freeze, "lib/rexml/formatters/transitive.rb".freeze, "lib/rexml/functions.rb".freeze, "lib/rexml/instruction.rb".freeze, "lib/rexml/light/node.rb".freeze, "lib/rexml/namespace.rb".freeze, "lib/rexml/node.rb".freeze, "lib/rexml/output.rb".freeze, "lib/rexml/parent.rb".freeze, "lib/rexml/parseexception.rb".freeze, "lib/rexml/parsers/baseparser.rb".freeze, "lib/rexml/parsers/lightparser.rb".freeze, "lib/rexml/parsers/pullparser.rb".freeze, "lib/rexml/parsers/sax2parser.rb".freeze, "lib/rexml/parsers/streamparser.rb".freeze, "lib/rexml/parsers/treeparser.rb".freeze, "lib/rexml/parsers/ultralightparser.rb".freeze, "lib/rexml/parsers/xpathparser.rb".freeze, "lib/rexml/quickpath.rb".freeze, "lib/rexml/rexml.rb".freeze, "lib/rexml/sax2listener.rb".freeze, "lib/rexml/security.rb".freeze, "lib/rexml/source.rb".freeze, "lib/rexml/streamlistener.rb".freeze, "lib/rexml/text.rb".freeze, "lib/rexml/undefinednamespaceexception.rb".freeze, "lib/rexml/validation/relaxng.rb".freeze, "lib/rexml/validation/validation.rb".freeze, "lib/rexml/validation/validationexception.rb".freeze, "lib/rexml/xmldecl.rb".freeze, "lib/rexml/xmltokens.rb".freeze, "lib/rexml/xpath.rb".freeze, "lib/rexml/xpath_parser.rb".freeze] + s.homepage = "https://github.com/ruby/rexml".freeze + s.licenses = ["BSD-2-Clause".freeze] + s.rdoc_options = ["--main".freeze, "README.md".freeze] + s.required_ruby_version = Gem::Requirement.new(">= 2.5.0".freeze) + s.rubygems_version = "3.4.20".freeze + s.summary = "An XML toolkit for Ruby".freeze +end diff -Nru ruby3.3-3.3.8/ChangeLog ruby3.3-3.3.13/ChangeLog --- ruby3.3-3.3.8/ChangeLog 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ChangeLog 1970-01-01 00:00:00.000000000 +0000 @@ -1,83367 +0,0 @@ --*- coding: utf-8 -*- - -commit b200bad6cd40d08e9f33b93e1a85c270b337867c - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-04-09 18:23:04 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-04-09 18:23:04 +0900 - - bump teeny - -commit 4ca521e91342165ed35cb12c9868f10e2a6aa07c - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-04-09 17:27:37 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-04-09 17:27:37 +0900 - - merge revision(s) 06919949a60b42a8f30e8bd0cb075e17b05eebcd, 51bc992822f9108ad64de32d300e1cefd0e2da59, 42daa6c2a2b49b4e45f40736e25c7d182860f24a: [Backport #21141] - - [Bug #21141] [DOC] Clarify what time is in UTC - - [Bug #21141] [DOC] Refine description of `Time#utc?` - - [Bug #21141] [DOC] Fix indentation - -commit a67e9e41846cdadad9bb2d9e9d10223c52253898 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-04-07 21:19:10 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-04-07 21:19:10 +0900 - - merge revision(s) 3a7b9ca93b91dcc086b9ac8b9957e59268f9493b: [Backport #21217] - - Fix `Integer.sqrt` to never exceed actual value - - `Integer.sqrt` uses `sqrt(3)` from libm for small values. - This method must return a value less than or equal to the actual integer - square root, but libm's sqrt does not always guarantee that. - - This change corrects that by decrementing the result if necessary. - - Fixes [Bug #21217] - -commit 5640fea8aada2380145375a7f9eac2b979fe1258 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-04-06 13:42:21 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-04-06 13:42:21 +0900 - - Update prism test snapshots. - - This is follow-up for 7c315e23983a35d29108d9ba8c914d6320254d43. - -commit 7c315e23983a35d29108d9ba8c914d6320254d43 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-04-06 11:24:36 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-04-06 11:31:57 +0900 - - merge revision(s) 117d6e145a0270ab8fc9134403519ef13b9ebb24: [Backport #21027] - - [ruby/prism] Fix `not` receiver - - `not foo` should be `!foo` - `not()` should be `!nil` - - Fixes [Bug #21027] - - https://github.com/ruby/prism/commit/871ed4b462 - -commit a1679f0d83845a35116d4e40bba4783346c8d7dc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2025-04-03 19:30:24 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2025-04-04 07:38:52 +0900 - - Use EnvUtil.apply_timeout_scale - -commit f2ee22f32d3b4919b9a5b62a81b544019383ef3a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2025-04-03 19:07:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2025-04-04 07:38:52 +0900 - - Extend open_timeout for test failure on s390x - - https://rubyci.s3.amazonaws.com/s390x/ruby-master/log/20250403T060004Z.fail.html.gz - -commit 7065e60318c970655eb561829a2071c310b67e2d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2025-04-03 14:18:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2025-04-03 19:41:48 +0900 - - Use IPv4 for test server because TestNetHTTPS is failing with s390x - - https://rubyci.s3.amazonaws.com/s390x/ruby-3.2/log/20250403T005659Z.fail.html.gz - -commit c48219e2d738faa388e61361c0549f7addbfacfe - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2025-04-03 13:04:31 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2025-04-03 14:10:39 +0900 - - f7059af50a31 is also required at ractor_core.h - -commit 31c295ef28fc678d8416f1f35726ac43d470d1d3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2025-04-03 09:40:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2025-04-03 12:54:11 +0900 - - Enforce to use CMake 3 because CMake 4 is not compatible to build libyaml via vcpkg - -commit 3d8a66568e8106b367665d716e0d3c8c8208aa07 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-04-02 21:16:22 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-04-02 21:16:47 +0900 - - merge revision(s) d78ff6a767ca813ac5fa178dd7611f20a993c191: [Backport #20984] - - [Bug #20984] Fix test with locale encoding - -commit ca0238353dd594c1012b7263b83e0c7eeb882cf4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2025-04-01 15:20:17 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2025-04-02 10:35:49 +0900 - - [rubygems/rubygems] Bump up minimum required version for cmake 4 - - https://github.com/rubygems/rubygems/commit/3e77caeddf - -commit 51dee044c1cb079a463118c5113ae9fdf96e463e - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-30 12:11:59 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-30 12:11:59 +0900 - - merge revision(s) 5f77f9bea61fb4cc8447a76e191fdfb28f076862: [Backport #21195] - - Fix handling of `error`/`errno` in `io_internal_wait`. (#12961) - - [Bug #21195] - -commit aac5c546cd35ff0aeab120e3724fbb1296892ae3 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-29 16:49:59 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-29 16:49:59 +0900 - - merge revision(s) f69ad0e810e1fdc18dc12f77bbecfa49999ef3bf: [Backport #21094] - - [Bug #21094] Update nested module names when setting temporary name - -commit 770060f7662698ca74bc28428919a688b8fe06d2 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-29 15:25:02 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-29 15:32:49 +0900 - - merge revision(s) 1acfb29015dbc38fd345d8786aa78aad59f7dcd1: [Backport #21186] - - [Bug #21186] multibyte char literal should be a single letter word - -commit d2eda78e4091a99c1a387d43967af5794d8eac70 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-29 15:21:40 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-29 15:21:40 +0900 - - merge revision(s) 9459bedd84d479bb1d7d3d40bada1cecb4701c37: [Backport #19841] - - [Bug #19841] Refine error on marshaling recursive USERDEF - -commit c1319d7e406ddf3f0da487296f1c4c50d90496ad - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2025-03-21 02:19:58 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2025-03-24 13:24:18 +0900 - - [rubygems/rubygems] Support git 2.49 - - One error message that we parse is now slightly different. - - https://github.com/rubygems/rubygems/commit/758528791d - -commit f85e5e01bafeca387e833b9d79cab43a8b22aa3d - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-16 20:10:00 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-16 20:35:27 +0900 - - merge revision(s) f423f6e10c0c226dfed98e7cb7a5d489191dfa35: [Backport #21131] - - Ensure IO.copy_stream buffer is an independent string - - Otherwise, changes to the buffer by the destination write method - could result in data changing for supposedly independent strings. - - Fixes [Bug #21131] - -commit 2b2ab1a67c236eb0c47e63e8adcf877b0d20a38c - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-16 18:52:56 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-16 18:52:56 +0900 - - merge revision(s) 08b3a45bc97c835b4677bf76dbce68fd51d81897: [Backport #21180] - - Push a real iseq in rb_vm_push_frame_fname() - - Previously, vm_make_env_each() (used during proc - creation and for the debug inspector C API) picked up the - non-GC-allocated iseq that rb_vm_push_frame_fname() creates, - which led to a SEGV when the GC tried to mark the non GC object. - - Put a real iseq imemo instead. Speed should be about the same since - the old code also did a imemo allocation and a malloc allocation. - - Real iseq allows ironing out the special-casing of dummy frames in - rb_execution_context_mark() and rb_execution_context_update(). A check - is added to RubyVM::ISeq#eval, though, to stop attempts to run dummy - iseqs. - - [Bug #21180] - - Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org> - -commit d213eb7f453fa0bd6c476826c450d9726c3c8b15 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-16 18:46:04 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-16 18:46:29 +0900 - - merge revision(s) 3f07bc76ff6a11232d9f18e5eaa31835c195e8f0, 34098b669c0cbc024cd08e686891f1dfe0a10aaf: [Backport #21144] - - [Bug #21144] Win32: Use Windows time zone ID if TZ is not set - - If the TZ environment variable is not set, the time zone names - retrieved from the system are localized for UI display and may vary - across editions and language packs for the same time zone. - Use the time zone IDs that are invariant across environments instead. - - [Bug #21144] Win32: Convert the time zone name to the current locale - - The Windows time zone IDs provided by Microsoft as of 24H1 are ASCII - only all, but the API itself is not impossible to set non-ASCII key - name. Prefer the current locale encoding for now until we move to - UTF-8 including environment variables and command line arguments. - -commit 726bff43b462d2a1b0bc93299cf031202f7fe7a1 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-16 18:02:45 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-16 18:02:45 +0900 - - merge revision(s) c224ca4feaff20cab03d76439bcbfb35d4e2f6b1: [Backport #21172] - - Fix a race condition with interned strings sweeping. - - [Bug #21172] - - This fixes a rare CI failure. - - The timeline of the race condition is: - - - A `"foo" oid=1` string is interned. - - `"foo" oid=1` is no longer referenced and will be swept in the future. - - Another `"foo" oid=2` string is interned. - - `register_fstring` finds `"foo" oid=1`, but since it is about to be swept, - removes it from `fstring_table` and insert `"foo" oid=2` instead. - - `"foo" oid=1` is swept, since it has the `RSTRING_FSTR` flag, - a `st_delete` is issued in `fstring_table` which removes `"foo" oid=2`. - - I don't know how to reproduce this bug consistently in a single test - case. - -commit 1d3c19871d7a0d05a0f0a80e78cfad843b7ef324 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-16 15:39:32 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-16 15:39:32 +0900 - - merge revision(s) 931ac960b6d11937364b6c4e847fdd575ee67980: [Backport #21159] - - [Bug #21159] module names should not be modifiable - -commit da86a9959b4c5bbdefb6fd1000a0251a151ffbc1 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-16 15:25:20 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-16 15:25:20 +0900 - - merge revision(s) 2b6fc9ea7212543a1be26768403f59c7a759b5ea: [Backport #21092] - - [Bug #21092] Fallback variables after execonf has done - - When reading from a dummy makefile, the global variables initialized - in `init_mkmf` may not be overridden. - -commit ac3f355fb33f4ce41df864f2084028610b7b38d1 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-16 13:10:13 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-16 13:10:13 +0900 - - Silently ignore keyword args for attr-asign method to cease segmentation fault. - -commit e860cb2267cd17aef9a5e8e977d03410c213d6a2 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-08 18:21:16 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-08 18:21:16 +0900 - - merge revision(s) 91a10c07579f282a94e4b5830feaeca87f9a7dd3: [Backport #21112] - - Fix a typo in WeakKeyMap argument error - - [Bug #21112] - -commit fff5baf200572762a60c624bc7bea866992c2f30 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-08 18:19:14 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-08 18:19:14 +0900 - - merge revision(s) 46b544c54955348ef1ea9692b837b061f59f91cd, d3abee739f4feb91bb9aaae33877d70c8c576db0: [Backport #21095] - - Prefer `uname -n` over `hostname`. (#12647) - - Add fallback for `hostname` if `uname` isn't available. (#12655) - -commit 54dd27d89d2e6814114f1aff18836a987d5a4ab1 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-08 17:26:28 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-08 17:26:28 +0900 - - merge revision(s) d4a1a2780c39bc648496ac92fc6e6ce2eb38ab47: [Backport #21032] - - rb_feature_p: skip `get_expanded_load_path` for absolute paths - - Ref: https://github.com/fxn/zeitwerk/pull/308 - - ```ruby - require 'benchmark' - - $LOAD_PATH << 'relative-path' - - autoload :FOO, '/tmp/foo.rb' - - puts Benchmark.realtime { - 500_000.times do - Object.autoload?(:FOO) - end - } - ``` - - The above script takes 2.5 seconds on `master`, and only - 50ms on this branch. - - When we're looking for a feature with an absolute path, we don't - need to call the expensive `get_expanded_load_path`. - -commit 8274b8193e0a047d1edfff603dd2436276f906c4 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-08 17:23:15 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-08 17:23:15 +0900 - - merge revision(s) f7059af50a31a4d27a04ace0beadb60616f3f971: [Backport #21046] - - Use no-inline version `rb_current_ec` on Arm64 - - The TLS across .so issue seems related to Arm64, but not Darwin. - -commit 56ba9041d9e338359b32ba0bfb3d816d57dc9d39 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2025-03-08 17:03:20 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-08 17:03:20 +0900 - - merge revision(s) ae6bd3b49ba252985b92416c24102ede3c0aac9b, 966458199d870b88b42898d4a063b487c1ef6b00, 966458199d870b88b42898d4a063b487c1ef6b00: [Backport #20951] - - [DOC] Tweak "Timezone Objects" - - - Make method descriptions plain pragraphs in each method. - - Make "Argument" and "Returns" note-lists. - - [Bug #20951] [DOC] About UTC offset calculation after `utc_to_local` - - [Bug #20951] [DOC] About UTC offset calculation after `utc_to_local` - -commit ef523984f0c16ec3ec1ea3b5b74ed24e6b03d561 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2025-03-06 07:21:48 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-08 16:43:58 +0900 - - Replace tombstone when converting AR to ST hash - - [Bug #21170] - - st_table reserves -1 as a special hash value to indicate that an entry - has been deleted. So that that's a valid value to be returned from the - hash function, do_hash replaces -1 with 0 so that it is not mistaken for - the sentinel. - - Previously, when upgrading an AR table to an ST table, - rb_st_add_direct_with_hash was used which did not perform the same - conversion, this could lead to a hash in a broken state where one if its - entries which was supposed to exist being marked as a tombstone. - - The hash could then become further corrupted when the ST table required - resizing as the falsely tombstoned entry would be skipped but it would - be counted in num entries, leading to an uninitialized entry at index - 15. - - In most cases this will be really rare, unless using a very poorly - implemented custom hash function. - - This also adds two debug assertions, one that st_add_direct_with_hash - does not receive the reserved hash value, and a second in - rebuild_table_with, which ensures that after we rebuild/compact a table - it contains the expected number of elements. - - Co-authored-by: Alan Wu <alanwu@ruby-lang.org> - -commit ecb9f7ef372c70c3e4fa81a5002533814a94aa86 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2025-02-26 18:14:54 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-08 16:27:22 +0900 - - Merge cgi-0.4.2 - -commit e58827163002e816e49ed18007f4fa3481102b08 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2025-02-26 18:14:16 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2025-03-08 16:27:22 +0900 - - Merge uri-0.13.2 - -commit 188ff4d4356b1a369e2204e5c45e1d168ffdf631 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2024-11-05 18:04:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-03-06 09:09:35 +0900 - - Name dependency checks job - - And run on the latest ubuntu. - -commit 9472548aa1b8b82515602e543ec03872d0b139cb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-08-22 09:47:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-03-06 09:09:35 +0900 - - automerge needs windows results - -commit c462deb48262eeb4dc08255d9b859eb73759eb95 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-03-06 08:34:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-03-06 08:36:55 +0900 - - Update actions/cache for ruby_3_3 - -commit 2e7f65acbd52e9da57e7b2c44597106ca70aebd8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2025-02-28 15:54:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2025-02-28 16:43:01 +0900 - - Skip VS2022 17.13.x build - - see https://github.com/ruby/ruby/pull/12830 - -commit 5eb08338ca318c3ea2e367f3b00f0d1fb36270e2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-02-14 10:35:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-02-14 10:35:44 +0900 - - Drop k0kubun from CODEOWNERS - - The maintainers have been shifted to newer versions. - https://bugs.ruby-lang.org/issues/21136 - -commit f8b9e2c06f04ea3720d94b5268b6c62e30ad3b26 - Author: nicholas a. evans <nick@rubinick.dev> - AuthorDate: 2025-02-12 02:21:31 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2025-02-12 02:21:31 +0900 - - Bump net-imap to 0.4.19 for Ruby 3.3 (CVE-2025-25186) (#12732) - - This update addresses CVE-2025-25186 (GHSA-7fc5-f82f-cx69). - -commit 5b226fdb8df4a954476d8ee1b855539adaf82091 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2025-02-07 11:02:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-02-11 01:29:08 +0900 - - Support `git ls-files ...`.split style for file list of gemspec - -commit 84b60a03cd908c1b2efdfee65d71ffc03418ea21 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2025-02-05 14:49:50 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-02-11 01:29:08 +0900 - - Bump up net-smtp-0.5.1 - -commit da75893dbe4e6fbde84037a4e1730a95c685cdd9 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2025-02-05 14:58:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2025-02-06 09:49:44 +0900 - - Bump up actions/upload-artifact-4.4.1 - -commit be31f993d7fa0219d85f7b3c694d454da4ecc10b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 16:22:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 16:22:35 +0900 - - v3.3.7 - -commit b6affbca88f5e0a70bda784d5195be5f0408b5ba - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 14:25:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 14:25:34 +0900 - - Skip an unstable test due to a Ractor assertion - -commit e9f479d8712f7ecd3802d4438cd44161088d9713 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 14:16:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 14:16:37 +0900 - - YJIT: Filter & calls from specialized C method codegen - - Evident with the crash reported in [Bug #20997], the C replacement - codegen functions aren't authored to handle block arguments (nor - should they because the extra code from the complexity defeats - optimization). Filter sites with VM_CALL_ARGS_BLOCKARG. - - Co-Authored-By: Alan Wu <alanwu@ruby-lang.org> - -commit 02bcfb42be7ca97fa40c6efa2f03ddff66c9257c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 14:13:29 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 14:13:29 +0900 - - merge revision(s) 04ec07794657cd2444ecb001a522b9df2db1b90a: [Backport #21038] - - Preserve `errno` in `rb_fiber_scheduler_unblock`. (#12576) - - [Bug #21038] - - Co-authored-by: Julian Scheid <julians37@gmail.com> - -commit 7b9caf19ba480d168ef4c5e93690735240975c91 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 11:00:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 11:00:02 +0900 - - merge revision(s) b176d4f52e4af67654814dab3e9c5f4bf9170e54: [Backport #21008] - - [Bug #21008] Normalize before sum to float - - After switching to `Float`-mode when summing `Numeric` objects, - normalization for `Float` is still needed. - -commit 12a0807965624a0be37dc79371a69b5d787cc8d1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:59:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:59:12 +0900 - - merge revision(s) 8034e9c3d001ca3dff124ab42972684eac8af2ae: [Backport #20995] - - [Bug #20995] Protect `IO.popen` block from exiting by exception - -commit 0d6459249d13e247cd0eae28f59ef51b862bce80 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:58:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:58:17 +0900 - - merge revision(s) 19c39e4cfaa467e69b9848c9c5496d7f50d39c7f: [Backport #20984] - - [Bug #20984] ENV.inspect should be encoding aware - -commit 3a986b47cba80bdc081638d5f759a26c1beb8fad - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:56:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:56:25 +0900 - - merge revision(s) e0d600ec190c64aff76cfcbd6009cffb927da166: [Backport #21012] - - Avoid opt_aset_with optimization inside multiple assignment - - Previously, since the opt_aset_with optimization was introduced, - use of the opt_aset_with optimization inside multiple assignment - would result in a segfault or incorrect instructions. - - Fixes [Bug #21012] - - Co-authored-by: Nobuyoshi Nakada <nobu.nakada@gmail.com> - -commit 299455be9966c0a31dabe00014a4b8fae5093a7d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:54:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:54:19 +0900 - - merge revision(s) 92dd9734a967c20e628c8f77c5ce700058dcd58c: [Backport #20950] - - Fix use-after-free in ep in Proc#dup for ifunc procs - - [Bug #20950] - - ifunc proc has the ep allocated in the cfunc_proc_t which is the data of - the TypedData object. If an ifunc proc is duplicated, the ep points to - the ep of the source object. If the source object is freed, then the ep - of the duplicated object now points to a freed memory region. If we try - to use the ep we could crash. - - For example, the following script crashes: - - p = { a: 1 }.to_proc - 100.times do - p = p.dup - GC.start - p.call - rescue ArgumentError - end - - This commit changes ifunc proc to also duplicate the ep when it is duplicated. - -commit 00147cbab567b05b8a4137875bbda341ef704760 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:53:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:53:38 +0900 - - merge revision(s) e90b447655dd39ad1eb645cdaae450efd605db00: [Backport #20924] - - [Bug #20924] Fix reading with delimiter in wide character encodings - -commit 1b1c6e67588ef417847d36f4f4017bd18157a1d2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:52:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:52:11 +0900 - - merge revision(s) f65a6c090c229de1665af49f2e51fc1d6397ab72: [Backport #20921] - - Fix use-after-free in constant cache - - [Bug #20921] - - When we create a cache entry for a constant, the following sequence of - events could happen: - - - vm_track_constant_cache is called to insert a constant cache. - - In vm_track_constant_cache, we first look up the ST table for the ID - of the constant. Assume the ST table exists because another iseq also - holds a cache entry for this ID. - - We then insert into this ST table with the iseq_inline_constant_cache. - - However, while inserting into this ST table, it allocates memory, which - could trigger a GC. Assume that it does trigger a GC. - - The GC frees the one and only other iseq that holds a cache entry for - this ID. - - In remove_from_constant_cache, it will appear that the ST table is now - empty because there are no more iseq with cache entries for this ID, so - we free the ST table. - - We complete GC and continue our st_insert. However, this ST table has - been freed so we now have a use-after-free. - - This issue is very hard to reproduce, because it requires that the GC runs - at a very specific time. However, we can make it show up by applying this - patch which runs GC right before the st_insert to mimic the st_insert - triggering a GC: - - diff --git a/vm_insnhelper.c b/vm_insnhelper.c - index 3cb23f06f0..a93998136a 100644 - --- a/vm_insnhelper.c - +++ b/vm_insnhelper.c - @@ -6338,6 +6338,10 @@ vm_track_constant_cache(ID id, void *ic) - rb_id_table_insert(const_cache, id, (VALUE)ics); - } - - + if (id == rb_intern("MyConstant")) rb_gc(); - + - st_insert(ics, (st_data_t) ic, (st_data_t) Qtrue); - } - - And if we run this script: - - Object.const_set("MyConstant", "Hello!") - - my_proc = eval("-> { MyConstant }") - my_proc.call - - my_proc = eval("-> { MyConstant }") - my_proc.call - - We can see that ASAN outputs a use-after-free error: - - ==36540==ERROR: AddressSanitizer: heap-use-after-free on address 0x606000049528 at pc 0x000102f3ceac bp 0x00016d607a70 sp 0x00016d607a68 - READ of size 8 at 0x606000049528 thread T0 - #0 0x102f3cea8 in do_hash st.c:321 - #1 0x102f3ddd0 in rb_st_insert st.c:1132 - #2 0x103140700 in vm_track_constant_cache vm_insnhelper.c:6345 - #3 0x1030b91d8 in vm_ic_track_const_chain vm_insnhelper.c:6356 - #4 0x1030b8cf8 in rb_vm_opt_getconstant_path vm_insnhelper.c:6424 - #5 0x1030bc1e0 in vm_exec_core insns.def:263 - #6 0x1030b55fc in rb_vm_exec vm.c:2585 - #7 0x1030fe0ac in rb_iseq_eval_main vm.c:2851 - #8 0x102a82588 in rb_ec_exec_node eval.c:281 - #9 0x102a81fe0 in ruby_run_node eval.c:319 - #10 0x1027f3db4 in rb_main main.c:43 - #11 0x1027f3bd4 in main main.c:68 - #12 0x183900270 (<unknown module>) - - 0x606000049528 is located 8 bytes inside of 56-byte region [0x606000049520,0x606000049558) - freed by thread T0 here: - #0 0x104174d40 in free+0x98 (libclang_rt.asan_osx_dynamic.dylib:arm64e+0x54d40) - #1 0x102ada89c in rb_gc_impl_free default.c:8183 - #2 0x102ada7dc in ruby_sized_xfree gc.c:4507 - #3 0x102ac4d34 in ruby_xfree gc.c:4518 - #4 0x102f3cb34 in rb_st_free_table st.c:663 - #5 0x102bd52d8 in remove_from_constant_cache iseq.c:119 - #6 0x102bbe2cc in iseq_clear_ic_references iseq.c:153 - #7 0x102bbd2a0 in rb_iseq_free iseq.c:166 - #8 0x102b32ed0 in rb_imemo_free imemo.c:564 - #9 0x102ac4b44 in rb_gc_obj_free gc.c:1407 - #10 0x102af4290 in gc_sweep_plane default.c:3546 - #11 0x102af3bdc in gc_sweep_page default.c:3634 - #12 0x102aeb140 in gc_sweep_step default.c:3906 - #13 0x102aeadf0 in gc_sweep_rest default.c:3978 - #14 0x102ae4714 in gc_sweep default.c:4155 - #15 0x102af8474 in gc_start default.c:6484 - #16 0x102afbe30 in garbage_collect default.c:6363 - #17 0x102ad37f0 in rb_gc_impl_start default.c:6816 - #18 0x102ad3634 in rb_gc gc.c:3624 - #19 0x1031406ec in vm_track_constant_cache vm_insnhelper.c:6342 - #20 0x1030b91d8 in vm_ic_track_const_chain vm_insnhelper.c:6356 - #21 0x1030b8cf8 in rb_vm_opt_getconstant_path vm_insnhelper.c:6424 - #22 0x1030bc1e0 in vm_exec_core insns.def:263 - #23 0x1030b55fc in rb_vm_exec vm.c:2585 - #24 0x1030fe0ac in rb_iseq_eval_main vm.c:2851 - #25 0x102a82588 in rb_ec_exec_node eval.c:281 - #26 0x102a81fe0 in ruby_run_node eval.c:319 - #27 0x1027f3db4 in rb_main main.c:43 - #28 0x1027f3bd4 in main main.c:68 - #29 0x183900270 (<unknown module>) - - previously allocated by thread T0 here: - #0 0x104174c04 in malloc+0x94 (libclang_rt.asan_osx_dynamic.dylib:arm64e+0x54c04) - #1 0x102ada0ec in rb_gc_impl_malloc default.c:8198 - #2 0x102acee44 in ruby_xmalloc gc.c:4438 - #3 0x102f3c85c in rb_st_init_table_with_size st.c:571 - #4 0x102f3c900 in rb_st_init_table st.c:600 - #5 0x102f3c920 in rb_st_init_numtable st.c:608 - #6 0x103140698 in vm_track_constant_cache vm_insnhelper.c:6337 - #7 0x1030b91d8 in vm_ic_track_const_chain vm_insnhelper.c:6356 - #8 0x1030b8cf8 in rb_vm_opt_getconstant_path vm_insnhelper.c:6424 - #9 0x1030bc1e0 in vm_exec_core insns.def:263 - #10 0x1030b55fc in rb_vm_exec vm.c:2585 - #11 0x1030fe0ac in rb_iseq_eval_main vm.c:2851 - #12 0x102a82588 in rb_ec_exec_node eval.c:281 - #13 0x102a81fe0 in ruby_run_node eval.c:319 - #14 0x1027f3db4 in rb_main main.c:43 - #15 0x1027f3bd4 in main main.c:68 - #16 0x183900270 (<unknown module>) - - This commit fixes this bug by adding a inserting_constant_cache_id field - to the VM, which stores the ID that is currently being inserted and, in - remove_from_constant_cache, we don't free the ST table for ID equal to - this one. - - Co-Authored-By: Alan Wu <alanwu@ruby-lang.org> - -commit 745fe4cf7e0c297879b46045a4838b3e5e2dfeb9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:51:27 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:51:27 +0900 - - merge revision(s) 660b995365f719fa59ed6f2809bb1527e6470d14: [Backport #20915] - - [Bug #20915] Fix SEGV with `TracePoint#parameters` and aliased C method - - The following snippet results with a SEGV: - - ```ruby - C = Class.new do - alias_method :new_to_s, :to_s - end - - TracePoint.new(:c_call, &:parameters).enable { C.new.new_to_s } - ``` - - at MRI 3.3.6 and ruby 3.4.0dev - - The root cause of the issue lies in the `rb_tracearg_parameters` function - within the `RUBY_EVENT_C_RETURN` branch. Specifically, when the invoked - method is an alias for a C function, - `rb_method_entry_without_refinements(..., trace_arg->called_id, ...)` - may return NULL. In that case we can fallback to `trace_arg->id`. - -commit 1e48631e0f318a3b73cd39bdbda4619017383aac - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:50:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:50:24 +0900 - - merge revision(s) 02b70256b5171d4b85ea7eeab836d3d7cfb3dbfc, 6b4f8945d600168bf530d21395da8293fbd5e8ba: [Backport #20909] - - Check negative integer underflow - - Many of Oniguruma functions need valid encoding strings - -commit 8506fdfb4aca5262940b9c49827c2a839f6bb1fe - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:48:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:48:57 +0900 - - merge revision(s) 3b7892b6e4d1a1a5d6019987f9b46ed443dd104f: [Backport #20871] - - Fix a bug in rb_include_module that stops nested inclusion into module subclasses - - This bug was present since the code was originally added by me - in 3556a834a2847e52162d1d3302d4c64390df1694. - - Fixes [Bug #20871] - -commit f19831a15d680fd995ceaecad1157282be7182dc - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:47:41 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:47:41 +0900 - - merge revision(s) a8c2d5e7bee5fad0965baeb58d312ddc5932ec26: [Backport #20907] - - Ensure fiber scheduler re-acquires mutex when interrupted from sleep. (#12158) - - [Bug #20907] - -commit 1ec258ab7002210670171f3f2f0c4b39657e24a4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:42:54 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:42:54 +0900 - - merge revision(s) d71be7274bd2623bb521be72c245c08fc38d6ae4: [Backport #20873] - - [Bug #20873] Consider `-FIXNUM_MIN` overflow - - `-FIXNUM_MIN` is usually greater than `FIXNUM_MAX` on platforms using - two's complement representation. - -commit 42f043c1893b320b9d2a38ec3b1065dee71ce863 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:40:39 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:40:39 +0900 - - merge revision(s) 56ecc243e230e8e99761ec0ffc5116601f094bb0: [Backport #20868] - - [Bug #20868] Fix Method#hash to not change after compaction - - The hash value of a Method must remain constant after a compaction, otherwise - it may not work as the key in a hash table. - - For example: - - def a; end - - # Need this method here because otherwise the iseq may be on the C stack - # which would get pinned and not move during compaction - def get_hash - method(:a).hash - end - - puts get_hash # => 2993401401091578131 - - GC.verify_compaction_references(expand_heap: true, toward: :empty) - - puts get_hash # => -2162775864511574135 - -commit 233014639793cb6c8650a9b17d37bc09c662d430 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2025-01-15 10:38:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2025-01-15 10:38:34 +0900 - - merge revision(s) 773d140f65c1c8b726e107915bc003c186f38677: [Backport #20787] - - [Bug #20787] Check the separator in `IO#readline` as well as 3.2 - -commit 732ee20a02bcfd92a473a7841f374ee9b8a7bbb0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-12-03 10:28:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-12-03 11:08:37 +0900 - - Bump up actions/checkout-4.2.2 - -commit 7ff601aea00265f12a4cef1fd6c6321d6215d844 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-12-03 10:01:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-12-03 11:08:37 +0900 - - Lock json-schema-5.1.0 for using pure ruby version - -commit c53d12ee708662ac4b231178b08bd8a75f21ffeb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-11-19 16:39:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-11-20 10:18:27 +0900 - - Revert "Skip tests that suddenly started failing for MinGW" - - This reverts commit f72eb702f29574b85889d3ea6447efa29c8a8789. - -commit da008169578b389039845c4f1008b03da249964f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2024-11-17 22:49:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-11-20 10:18:27 +0900 - - Win32: Expose wchar main routine only - - Warned if both of `main` and `wmain` are exposed: - ``` - LINK : warning LNK4067: ambiguous entry point; selected 'mainCRTStartup' - ``` - -commit 7e2789415b1189072b79a1144f0aa871216e6fd0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2024-11-10 21:31:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-11-20 10:18:27 +0900 - - Make `MUNICODE_FLAG` simply expanded - - It is not expected that `target_os` will change going forward. - -commit b4afc2b25fbe2c4112b273a5aab51f8371a4feb6 - Author: Daisuke Fujimura (fd0) <booleanlabel@gmail.com> - AuthorDate: 2024-11-06 21:28:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-11-20 10:18:27 +0900 - - `EXE_LDFLAGS` uses the same `MUNICODE_FLAG` - -commit b7475e2ac326701776f34d4f2cfeddb7a5dca428 - Author: Daisuke Fujimura (fd0) <booleanlabel@gmail.com> - AuthorDate: 2024-11-06 10:01:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-11-20 10:18:27 +0900 - - `-municode` is available for MinGW-w64 targets only - -commit b3a1fc146c9793c31ec59bb75f30c368dcc94aa7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2024-11-04 09:39:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-11-20 10:18:27 +0900 - - Use wide character startup - - Mingw crt-git 12.0.0.r369.g0d4221712-1 now prohibits "command line - contains characters that are not supported in the active code page". - https://sourceforge.net/p/mingw-w64/mingw-w64/ci/0d42217123d3aec0341b79f6d959c76e09648a1e/ - - Already Ruby builds `argv` in `rb_w32_sysinit`, instead of mswin- or - mingw-made `argv`. Just bypass the conversion in mingw crt. - -commit 792826d5f4b77adf571d20b8752f5d93a1848092 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2024-11-17 19:56:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-11-20 10:18:27 +0900 - - Make `rb_ec_set_vm_stack` conformant to the C++11 requirement - - Https://learn.microsoft.com/en-us/cpp/build/reference/zc-inline-remove-unreferenced-comdat?view=msvc-140 - > If `/Zc:inline` is specified, the compiler enforces the C++11 - > requirement that all functions declared inline must have a definition - > available in the same translation unit if they're used. - -commit d44061b91986a225dd4a9d0337853a45de9eef48 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2024-11-17 19:29:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-11-20 10:18:27 +0900 - - Win32: Remove unreferenced COMDAT from object files - - Windows 11 SDK Version 10.0.26100.0 introduced a new internal inline - function in ucrt/corecrt_math.h. Even it appears in object files and - will be included in the DEF file, it will be removed from the DLL and - result in a linker error. - -commit 5232e3ce3cdd69f9afaf5d34370f6ef3c84e4930 - Author: MSP-Greg <Greg.mpls@gmail.com> - AuthorDate: 2024-06-21 09:33:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-11-20 10:18:27 +0900 - - [ruby/net-http] test_https.rb - fix test_session_reuse_but_expire - - https://github.com/ruby/net-http/commit/5544243c41 - -commit c78721f718d1004182b36a6610d32b1a158808be - Author: Job Snijders <job@sobornost.net> - AuthorDate: 2024-03-25 21:20:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-11-20 10:18:27 +0900 - - [ruby/openssl] Only CSR version 1 (encoded as 0) is allowed by PKIX standards - - RFC 2986, section 4.1 only defines version 1 for CSRs. This version - is encoded as a 0. Starting with OpenSSL 3.3, setting the CSR version - to anything but 1 fails. - - Do not attempt to generate a CSR with invalid version (which now fails) - and invalidate the CSR in test_sign_and_verify_rsa_sha1 by changing its - subject rather than using an invalid version. - - This commit fixes the following error. - - ``` - 2) Error: test_version(OpenSSL::TestX509Request): OpenSSL::X509::RequestError: - X509_REQ_set_version: passed invalid argument - /home/runner/work/openssl/openssl/test/openssl/test_x509req.rb:18:in `version=' - /home/runner/work/openssl/openssl/test/openssl/test_x509req.rb:18:in `issue_csr' - /home/runner/work/openssl/openssl/test/openssl/test_x509req.rb:43:in - `test_version' - 40: req = OpenSSL::X509::Request.new(req.to_der) - 41: assert_equal(0, req.version) - 42: - => 43: req = issue_csr(1, @dn, @rsa1024, OpenSSL::Digest.new('SHA256')) - 44: assert_equal(1, req.version) - 45: req = OpenSSL::X509::Request.new(req.to_der) - 46: assert_equal(1, req.version) - ``` - - https://github.com/ruby/openssl/commit/c06fdeb091 - -commit 068fb26c0862e10f892e89ad7b6bb31e548fde0c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-11-19 15:42:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-11-20 10:18:27 +0900 - - Lock sinatra-4.0 - -commit a97621ef3c7e026651d93460bbf04d3008c5676b - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2024-11-16 07:05:28 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-11-16 07:05:28 +0900 - - wasm: align fiber stack pointer to 16 bytes (#12101) - - wasm: align fiber stack pointer to 16 bytes - - In WebAssembly C ABI, the linear stack pointer must be always aligned - to 16 bytes like other archs. - The misaligned stack pointer causes some weird memory corruption since - compiler assumes the aligned stack pointer. - -commit a24570a62a584478a7dde5dd716b5c88fe86e9e5 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2024-11-13 04:20:36 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-11-13 04:20:36 +0900 - - ObjectSpace.dump: handle Module#set_temporary_name (#12068) - - ObjectSpace.dump: handle Module#set_temporary_name - - [Bug #20892] - - Until the introduction of that method, it was impossible for a - Module name not to be valid JSON, hence it wasn't going through - the slower escaping function. - - This assumption no longer hold. - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - -commit f4258aaed02ee7be761f2499b0b6243a8f37b7cb - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2024-11-13 02:04:21 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-11-13 02:04:21 +0900 - - [Bug #20886] Avoid double-free in regex timeout after stack_double (#12063) - - Fix regex timeout double-free after stack_double - - As of 10574857ce167869524b97ee862b610928f6272f, it's possible to crash - on a double free due to `stk_alloc` AKA `msa->stack_p` being freed - twice, once at the end of match_at and a second time in `FREE_MATCH_ARG` - in the parent caller. - - Fixes [Bug #20886] - -commit a51a6bf6926241704593b9439e91c06ee6f3ee61 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2024-11-09 18:00:13 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-11-09 18:00:13 +0900 - - [Bug #20883] Fix coderange for sprintf on binary strings (#12040) - - Fix update_coderange for binary strings - - Although a binary (aka ASCII-8BIT) string will never have a broken - coderange, it still has to differentiate between "valid" and "7bit". - - On Ruby 3.4/trunk this problem is masked because we now clear the - coderange more agressively in rb_str_resize, and we happened to always - be strinking this string, but we should not assume that. - - On Ruby 3.3 this created strings where `ascii_only?` was true in cases - it shouldn't be as well as other problems. - - Fixes [Bug #20883] - - Co-authored-by: Daniel Colson <danieljamescolson@gmail.com> - Co-authored-by: Matthew Draper <matthew@trebex.net> - -commit 75015d4c1f6965b5e85e96fb309f1f2129f933c0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-11-05 09:49:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-11-05 09:49:11 +0900 - - v3.3.6 - -commit f72eb702f29574b85889d3ea6447efa29c8a8789 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-11-05 09:00:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-11-05 09:00:11 +0900 - - Skip tests that suddenly started failing for MinGW - - These test failures first appeared on irrelevant changes. It probably - came from changes in GitHub Actions instead of CRuby's. - - Until we figure out how to fix these tests, let's skip them to make the - CI usable. - -commit 7237ded95f3ad624edc122b14d0276daf554a96c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-11-05 07:52:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-11-05 07:52:43 +0900 - - macos-12 is deprecated and fails on Mondays - - https://github.com/actions/runner-images/issues/10721 - -commit 6db39f4677ff50aacfe54bd9dda052c09e1c6ab0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-11-05 07:43:39 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-11-05 07:43:39 +0900 - - merge revision(s) 29c480dd6fca993590c82078ba797e2c4e876ac7: [Backport #20853] - - [Bug #20853] Fix Proc#hash to not change after compaction - - The hash value of a Proc must remain constant after a compaction, otherwise - it may not work as the key in a hash table. - -commit edeb0319f7a95dfe3f9b895bcf32371dd8514726 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-11-05 07:42:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-11-05 07:42:47 +0900 - - merge revision(s) 6118e8a47394409b53164b60e79fadf348b97db3: [Backport #20716] - - Fix method caching bug when including/prepend module A that prepends module B - - Fix by always adding the generated iclass to the subclasses list, - otherwise the method cache for the iclass is not cleared when - the method in the module is overwritten. - - Fixes [Bug #20716] - -commit 5ce0ba0d415deb99527c409cc5f1df16ce02ef3e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-11-05 07:39:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-11-05 07:39:22 +0900 - - merge revision(s) 35e124832e29b65c84d4e0e4e434616859f9bdf5: [Backport #20755] - - [Bug #20755] Frozen string should not be writable via IO::Buffer - -commit 12ea98e8c8af0ed6778aad26e7ec5f95e2c239e5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-11-05 07:38:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-11-05 07:38:18 +0900 - - merge revision(s) 637067440f74043c6d79fc649ab8acf1afea25a5: [Backport #20752] - - [Bug #20752] Slice of readonly `IO::Buffer` also should be readonly - -commit 34a0f41d0aaff190f1647a6fa0e905690d0eff98 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-11-05 07:37:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-11-05 07:37:14 +0900 - - merge revision(s) c1862cbb89a6bf42dcd07d92fe4f4bfeebca5775: [Backport #20719] - - [Bug #20719] `Float` argument must be ASCII compatible - -commit 2b713dcb89c620daa55d672d2933ffde333ca5de - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-11-05 07:36:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-11-05 07:36:36 +0900 - - merge revision(s) d33e3d47b84a73b38644f2a3d41881ce9be6ef18: [Backport #20704] - - [Bug #20704] Win32: Fix chdir to non-ASCII path - - On Windows, `chdir` in compilers' runtime libraries uses the active - code page, but command line arguments in ruby are always UTF-8, since - commit:33ea2646b98adb49ae2e1781753bf22d33729ac0. - -commit e7c939aea1034a463226635e11117ade42cba4e4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-11-05 07:29:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-11-05 07:29:25 +0900 - - merge revision(s) 76ea5cde2a0f4834a5228104249b6b3346ddfc94: [Backport #20777] - - Refactor RUBY_DESCRIPTION assertions in test_rubyoptions - -commit 7446f7cdd103b129b8b750f577efd29e069176c0 - Author: Jonathan Calvert <athemeus@athemeus.com> - AuthorDate: 2024-09-07 12:19:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-11-05 07:26:25 +0900 - - merge revision(s) 0d16c36d0ab2afa2ec79b72b229e69c141ebdaba: [Backport #13831] - - [win32/registry] Fallback to UTF-8 for unknown codepages - - There are some codepages like cp708 for which no ruby encoding exists: - - $ ruby -e "Encoding.find('cp708')" - Traceback (most recent call last): - 1: from -e:1:in `<main>' - -e:1:in `find': unknown encoding name - cp708 (ArgumentError) - - win32/registry uses ENCODING to transcode error messages and expand environment - variables from UTF-16LE, so using UTF-8 seems like the best choice and is better - than a hard failure. - - This should resolve [Bug #13831] - -commit 6b3a0b4ffd12cd7f80be224efa8744534fcf2b93 - Author: Alex Myers <myers3162002@gmail.com> - AuthorDate: 2024-11-02 00:42:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-11-02 00:42:18 +0900 - - Bump REXML to 3.3.9 for Ruby 3.3 (#11972) - -commit c4b6ce36758fbc8d851b8b6563d0cf64cf2417db - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-10-18 11:12:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-10-22 00:41:50 +0900 - - Merge syntax-suggest-2.0.1 - -commit 494fcc507b3bc218beb6638d33476b647d55969e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-10-17 16:12:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-10-18 00:55:01 +0900 - - Merge RubyGems-3.5.22 and Bundler-2.5.22 - -commit d03e4228aaeb1bdd3432119e683aa259b028c5b2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-10-17 16:11:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-10-18 00:55:01 +0900 - - Merge RubyGems-3.5.21 and Bundler-2.5.21 - -commit af7656869ee714a7124c1c655bc905e456770bd2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2024-09-09 17:25:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-10-01 01:16:44 +0900 - - Run just bignum related tests when gmp enabled - -commit 4608ef8d7b0e22d690b73dabc032e9dd43e9a446 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-09-30 12:03:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-10-01 01:16:44 +0900 - - -l option of 7z is unknown switch with the `ubuntu-latest`. - - https://github.com/ruby/actions/actions/runs/11095032727/job/30823174026#step:3:349 - -commit 77fb1bf434d7be9cf5d892404b04b20c18fa6f06 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-09-25 16:54:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-26 02:56:17 +0900 - - Merge RubyGems-3.5.20 and Bundler-2.5.20 - -commit 3894841182c32de231b3998502bf1a9dba7cdb4f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-09-25 16:54:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-26 02:56:17 +0900 - - Merge RubyGems-3.5.19 and Bundler-2.5.19 - -commit ef3c4a7aa7c0a79a00f4daa50e0be1184d9fe536 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-09-25 16:53:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-26 02:56:17 +0900 - - Merge RubyGems-3.5.18 and Bundler-2.5.18 - -commit 95f72a4a32396cae7475b39d7739fb534242b625 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-09-25 16:53:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-26 02:56:17 +0900 - - Merge RubyGems-3.5.17 and Bundler-2.5.17 - -commit d8966416d010719ef8f1689137da31aa75e71198 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2024-09-25 02:50:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-09-25 02:50:33 +0900 - - Use `PRIuSIZE` instead of `%zu` for `size_t` (#9359) - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - -commit ec04de7512d512a2bcc623a72a4f17f43a01a5bf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-09-24 00:47:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-24 01:25:10 +0900 - - Bump debug.gem to 1.9.2 - -commit 5b6009870dff883a8e71a05e60f175cea1d00d55 - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2024-09-13 16:40:30 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-24 01:25:10 +0900 - - Ensure fiber scheduler is woken up when close interrupts read - - If one thread is reading and another closes that socket, the close - blocks waiting for the read to abort cleanly. This ensures that Ruby is - totally done with the file descriptor _BEFORE_ we tell the OS to close - and potentially re-use it. - - When the read is correctly terminated, the close should be unblocked. - That currently works if closing is happening on a thread, but if it's - happening on a fiber with a fiber scheduler, it does NOT work. - - This patch ensures that if the close happened in a fiber scheduled - thread, that the scheduler is notified that the fiber is unblocked. - - [Bug #20723] - -commit 4e59e7d35fbd6ff87f63cd0aa5d6a2f923323fee - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-09-17 09:28:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-09-17 09:28:08 +0900 - - [Bug #20737] Do not warn default gems to be promoted in Ruby 3.5 (#11613) - -commit 55ddfd58dd6e67e88cf9a3e55bf99550affe8b3f - Author: Jonathan Calvert <athemeus@athemeus.com> - AuthorDate: 2024-09-11 09:38:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-09-11 09:38:48 +0900 - - Fixes [Bug #20718] (#11576) - - Fixes [Bug #20718] - - Allow objects that are not of type `RTypedData` to use the default free function, as `RTYPEDDATA_EMBEDDED_P` can return a false positive when casting non-`RTypedData` objects - -commit 948ca04a76c0031d17798f79fe3bbc5fb8462e90 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-09-06 10:00:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-06 10:00:19 +0900 - - Allow failures for all Travis jobs - - Every job on Travis is unstable now. - -commit c3f7041ab19fbf0e937126dc1b7397b97f768b9a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-09-06 09:55:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-09-06 09:55:34 +0900 - - Merge reline-0.5.10 (#11558) - - * Merge reline-0.5.8 - - * Merge reline-0.5.9 - - * Merge reline-0.5.10 - -commit 4eb51dfc9e67683a1a03fdf302d5ddd95cad716a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-09-05 00:47:06 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-09-05 00:47:06 +0900 - - Merge JSON 2.7.2 for Ruby 3.3 (#11541) - - Merge JSON 2.7.2 - -commit ef084cc8f4958c1b6e4ead99136631bef6d8ddba - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-09-03 01:09:08 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-03 01:09:08 +0900 - - v3.3.5 - -commit d3ab7be8ca034ea58da7d6ebc77ad66e192cba18 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-09-02 19:28:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-02 19:28:11 +0900 - - merge revision(s) 657f4b99f61: [Backport #20667] - - Update bundled gems list as of 2024-08-02 - -commit c69d59e9b2d3d8621e50670087d4e53b73580c75 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-09-02 19:25:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-02 19:25:23 +0900 - - Sync tool/lib/core_assertions.rb from master - - It seems necessary to pass test-bundled-gems with REXML. - -commit cf9a6c2b63e6337a3f6ce76527446739e5aceb67 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-09-02 19:19:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-02 19:19:13 +0900 - - merge revision(s) a3562c2a0abf1c2bdd1d50377b4f929580782594: [Backport #20701] - - Remove incorrect setting of KW_SPLAT_MUT flag - - Fixes [Bug #20701] - - Co-authored-by: Pablo Herrero <pablodherrero@gmail.com> - -commit d83b5633b16f4ddcece4ff924f21c5a5851470cf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-09-02 19:10:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-02 19:10:19 +0900 - - merge revision(s) 992596fb7af18a7f472589a607d0eb3fbb03b49a: [Backport #20344] - - Fix next inside block argument stack underflow - - [Bug #20344] - Fix compile_next adding removable adjust label - -commit b210c86a0201f6a97c4da8266908260746f53ae0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-09-02 19:07:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-02 19:07:09 +0900 - - merge revision(s) 97449338d6cb42d9dd7c9ca61550616e7e6b6ef6: [Backport #20649] - - [Bug #20649] Allow `nil` as 2nd argument of `assign_error` - - Fallback to the last token element in that case, for the backward - compatibilities. - -commit 6a4e79533b4454392f3afdfa0c4d35b763b68466 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-09-02 18:56:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-02 18:56:18 +0900 - - merge revision(s) 1870505f478cc75993b296b7144a45137ace6937: [Backport #20651] - - Fix wrong unreachable chunk remove when jump destination label is unremovable - -commit e0e23e7d5eb4da42c490b1d3408bd6e5047e8f83 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-09-02 18:52:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-02 18:52:51 +0900 - - merge revision(s) 29500e30346: [Backport #20667] - - Update bundled gems list as of 2024-08-22 - -commit 7b954e7bc64e201af1dd65e264e5091310efd362 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-09-02 18:43:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-09-02 18:44:25 +0900 - - Allow failures in Travis ppc64le and s390x - - Those jobs are way too unstable and provide very little benefit. - - e.g. - https://app.travis-ci.com/github/ruby/ruby/jobs/624611955 - https://app.travis-ci.com/github/ruby/ruby/jobs/625551620 - -commit 937964f3467a6242bb4bf1431983e6847d529338 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-08-28 08:00:27 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-08-28 08:00:27 +0900 - - Merge URI-0.13.1 for Ruby 3.3 (#11466) - - Merge URI-0.13.1 - -commit ac8d50e52ebc2d2684914e56548a64a65830c16a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2024-08-24 07:48:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-08-24 07:48:08 +0900 - - [Backport 3.3] [Bug #20691] Fix use-after-free in WeakKeyMap#clear (#11443) - - Fix use-after-free in WeakKeyMap#clear - - [Bug #20691] - - If the WeakKeyMap has been marked but sweeping hasn't started yet and we - cann WeakKeyMap#clear, then there could be a use-after-free because we do - not call rb_gc_remove_weak to remove the key from the GC. - - For example, the following code triggers use-after-free errors in Valgrind: - - map = ObjectSpace::WeakKeyMap.new - - 1_000.times do - 1_000.times do - map[Object.new] = nil - end - - map.clear - end - - Output from Valgrind: - - ==61230== Invalid read of size 8 - ==61230== at 0x25CAF8: gc_update_weak_references (default.c:5593) - ==61230== by 0x25CAF8: gc_marks_finish (default.c:5641) - ==61230== by 0x26031C: gc_marks_continue (default.c:5987) - ==61230== by 0x26031C: gc_continue (default.c:2255) - ==61230== by 0x2605FC: newobj_cache_miss (default.c:2589) - ==61230== by 0x26111F: newobj_alloc (default.c:2622) - ==61230== by 0x26111F: rb_gc_impl_new_obj (default.c:2701) - ==61230== by 0x26111F: newobj_of (gc.c:890) - ==61230== by 0x26111F: rb_wb_protected_newobj_of (gc.c:917) - ==61230== by 0x2DE218: rb_class_allocate_instance (object.c:131) - ==61230== by 0x2E32A8: class_call_alloc_func (object.c:2141) - ==61230== by 0x2E32A8: rb_class_alloc (object.c:2113) - ==61230== by 0x2E32A8: rb_class_new_instance_pass_kw (object.c:2172) - ==61230== by 0x4296BC: vm_call_cfunc_with_frame_ (vm_insnhelper.c:3788) - ==61230== by 0x44A9CD: vm_sendish (vm_insnhelper.c:5955) - ==61230== by 0x44A9CD: vm_exec_core (insns.def:898) - ==61230== by 0x43A0E4: rb_vm_exec (vm.c:2564) - ==61230== by 0x2341B4: rb_ec_exec_node (eval.c:281) - ==61230== by 0x236258: ruby_run_node (eval.c:319) - ==61230== by 0x15D665: rb_main (main.c:43) - ==61230== by 0x15D665: main (main.c:62) - ==61230== Address 0x2159cb00 is 0 bytes inside a block of size 8 free'd - ==61230== at 0x4849B2C: free (vg_replace_malloc.c:989) - ==61230== by 0x248EF1: rb_gc_impl_free (default.c:8512) - ==61230== by 0x248EF1: rb_gc_impl_free (default.c:8493) - ==61230== by 0x248EF1: ruby_sized_xfree.constprop.0 (gc.c:4178) - ==61230== by 0x4627EC: wkmap_free_table_i (weakmap.c:652) - ==61230== by 0x3A54AF: apply_functor (st.c:1633) - ==61230== by 0x3A54AF: st_general_foreach (st.c:1543) - ==61230== by 0x3A54AF: rb_st_foreach (st.c:1640) - ==61230== by 0x46203C: wkmap_clear (weakmap.c:973) - ==61230== by 0x4296BC: vm_call_cfunc_with_frame_ (vm_insnhelper.c:3788) - ==61230== by 0x44A9CD: vm_sendish (vm_insnhelper.c:5955) - ==61230== by 0x44A9CD: vm_exec_core (insns.def:898) - ==61230== by 0x43A0E4: rb_vm_exec (vm.c:2564) - ==61230== by 0x2341B4: rb_ec_exec_node (eval.c:281) - ==61230== by 0x236258: ruby_run_node (eval.c:319) - ==61230== by 0x15D665: rb_main (main.c:43) - ==61230== by 0x15D665: main (main.c:62) - ==61230== Block was alloc'd at - ==61230== at 0x484680F: malloc (vg_replace_malloc.c:446) - ==61230== by 0x25C68E: rb_gc_impl_malloc (default.c:8527) - ==61230== by 0x4622E9: wkmap_aset_replace (weakmap.c:817) - ==61230== by 0x3A4D02: rb_st_update (st.c:1487) - ==61230== by 0x4623E4: wkmap_aset (weakmap.c:854) - ==61230== by 0x4296BC: vm_call_cfunc_with_frame_ (vm_insnhelper.c:3788) - ==61230== by 0x44A9CD: vm_sendish (vm_insnhelper.c:5955) - ==61230== by 0x44A9CD: vm_exec_core (insns.def:898) - ==61230== by 0x43A0E4: rb_vm_exec (vm.c:2564) - ==61230== by 0x2341B4: rb_ec_exec_node (eval.c:281) - ==61230== by 0x236258: ruby_run_node (eval.c:319) - ==61230== by 0x15D665: rb_main (main.c:43) - ==61230== by 0x15D665: main (main.c:62) - ==61230== - ==61230== Invalid write of size 8 - ==61230== at 0x25CB3B: gc_update_weak_references (default.c:5598) - ==61230== by 0x25CB3B: gc_marks_finish (default.c:5641) - ==61230== by 0x26031C: gc_marks_continue (default.c:5987) - ==61230== by 0x26031C: gc_continue (default.c:2255) - ==61230== by 0x2605FC: newobj_cache_miss (default.c:2589) - ==61230== by 0x26111F: newobj_alloc (default.c:2622) - ==61230== by 0x26111F: rb_gc_impl_new_obj (default.c:2701) - ==61230== by 0x26111F: newobj_of (gc.c:890) - ==61230== by 0x26111F: rb_wb_protected_newobj_of (gc.c:917) - ==61230== by 0x2DE218: rb_class_allocate_instance (object.c:131) - ==61230== by 0x2E32A8: class_call_alloc_func (object.c:2141) - ==61230== by 0x2E32A8: rb_class_alloc (object.c:2113) - ==61230== by 0x2E32A8: rb_class_new_instance_pass_kw (object.c:2172) - ==61230== by 0x4296BC: vm_call_cfunc_with_frame_ (vm_insnhelper.c:3788) - ==61230== by 0x44A9CD: vm_sendish (vm_insnhelper.c:5955) - ==61230== by 0x44A9CD: vm_exec_core (insns.def:898) - ==61230== by 0x43A0E4: rb_vm_exec (vm.c:2564) - ==61230== by 0x2341B4: rb_ec_exec_node (eval.c:281) - ==61230== by 0x236258: ruby_run_node (eval.c:319) - ==61230== by 0x15D665: rb_main (main.c:43) - ==61230== by 0x15D665: main (main.c:62) - ==61230== Address 0x2159cb00 is 0 bytes inside a block of size 8 free'd - ==61230== at 0x4849B2C: free (vg_replace_malloc.c:989) - ==61230== by 0x248EF1: rb_gc_impl_free (default.c:8512) - ==61230== by 0x248EF1: rb_gc_impl_free (default.c:8493) - ==61230== by 0x248EF1: ruby_sized_xfree.constprop.0 (gc.c:4178) - ==61230== by 0x4627EC: wkmap_free_table_i (weakmap.c:652) - ==61230== by 0x3A54AF: apply_functor (st.c:1633) - ==61230== by 0x3A54AF: st_general_foreach (st.c:1543) - ==61230== by 0x3A54AF: rb_st_foreach (st.c:1640) - ==61230== by 0x46203C: wkmap_clear (weakmap.c:973) - ==61230== by 0x4296BC: vm_call_cfunc_with_frame_ (vm_insnhelper.c:3788) - ==61230== by 0x44A9CD: vm_sendish (vm_insnhelper.c:5955) - ==61230== by 0x44A9CD: vm_exec_core (insns.def:898) - ==61230== by 0x43A0E4: rb_vm_exec (vm.c:2564) - ==61230== by 0x2341B4: rb_ec_exec_node (eval.c:281) - ==61230== by 0x236258: ruby_run_node (eval.c:319) - ==61230== by 0x15D665: rb_main (main.c:43) - ==61230== by 0x15D665: main (main.c:62) - ==61230== Block was alloc'd at - ==61230== at 0x484680F: malloc (vg_replace_malloc.c:446) - ==61230== by 0x25C68E: rb_gc_impl_malloc (default.c:8527) - ==61230== by 0x4622E9: wkmap_aset_replace (weakmap.c:817) - ==61230== by 0x3A4D02: rb_st_update (st.c:1487) - ==61230== by 0x4623E4: wkmap_aset (weakmap.c:854) - ==61230== by 0x4296BC: vm_call_cfunc_with_frame_ (vm_insnhelper.c:3788) - ==61230== by 0x44A9CD: vm_sendish (vm_insnhelper.c:5955) - ==61230== by 0x44A9CD: vm_exec_core (insns.def:898) - ==61230== by 0x43A0E4: rb_vm_exec (vm.c:2564) - ==61230== by 0x2341B4: rb_ec_exec_node (eval.c:281) - ==61230== by 0x236258: ruby_run_node (eval.c:319) - ==61230== by 0x15D665: rb_main (main.c:43) - ==61230== by 0x15D665: main (main.c:62) - - Co-authored-by: Jean Boussier <byroot@ruby-lang.org> - -commit 8657de70aa9d16066f9761710a5a74211046dc67 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2024-08-23 07:54:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-08-23 07:54:55 +0900 - - [Backport 3.3] [Bug #20688] Fix use-after-free for WeakMap and WeakKeyMap (#11439) - - * Add struct weakmap_entry for WeakMap entries - - * Refactor wmap_foreach to pass weakmap_entry - - * Use wmap_foreach for wmap_mark - - * Refactor wmap_compact to use wmap_foreach - - * Remove wmap_free_entry - - * Fix WeakMap use-after-free - - [Bug #20688] - - We cannot free the weakmap_entry before the ST_DELETE because it could - hash the key which would read the weakmap_entry and would cause a - use-after-free. Instead, we store the entry and free it on the next - iteration. - - For example, the following script triggers a use-after-free in Valgrind: - - weakmap = ObjectSpace::WeakMap.new - 10_000.times { weakmap[Object.new] = Object.new } - - ==25795== Invalid read of size 8 - ==25795== at 0x462297: wmap_cmp (weakmap.c:165) - ==25795== by 0x3A2B1C: find_table_bin_ind (st.c:930) - ==25795== by 0x3A5EAA: st_general_foreach (st.c:1599) - ==25795== by 0x3A5EAA: rb_st_foreach (st.c:1640) - ==25795== by 0x25C991: gc_mark_children (default.c:4870) - ==25795== by 0x25C991: gc_marks_wb_unprotected_objects_plane (default.c:5565) - ==25795== by 0x25C991: rgengc_rememberset_mark_plane (default.c:5557) - ==25795== by 0x25C991: rgengc_rememberset_mark (default.c:6233) - ==25795== by 0x25C991: gc_marks_start (default.c:6057) - ==25795== by 0x25C991: gc_marks (default.c:6077) - ==25795== by 0x25C991: gc_start (default.c:6723) - ==25795== by 0x260F96: heap_prepare (default.c:2282) - ==25795== by 0x260F96: heap_next_free_page (default.c:2489) - ==25795== by 0x260F96: newobj_cache_miss (default.c:2598) - ==25795== by 0x26197F: newobj_alloc (default.c:2622) - ==25795== by 0x26197F: rb_gc_impl_new_obj (default.c:2701) - ==25795== by 0x26197F: newobj_of (gc.c:890) - ==25795== by 0x26197F: rb_wb_protected_newobj_of (gc.c:917) - ==25795== by 0x2DEA88: rb_class_allocate_instance (object.c:131) - ==25795== by 0x2E3B18: class_call_alloc_func (object.c:2141) - ==25795== by 0x2E3B18: rb_class_alloc (object.c:2113) - ==25795== by 0x2E3B18: rb_class_new_instance_pass_kw (object.c:2172) - ==25795== by 0x429DDC: vm_call_cfunc_with_frame_ (vm_insnhelper.c:3786) - ==25795== by 0x44B08D: vm_sendish (vm_insnhelper.c:5953) - ==25795== by 0x44B08D: vm_exec_core (insns.def:898) - ==25795== by 0x43A7A4: rb_vm_exec (vm.c:2564) - ==25795== by 0x234914: rb_ec_exec_node (eval.c:281) - ==25795== Address 0x21603710 is 0 bytes inside a block of size 16 free'd - ==25795== at 0x4849B2C: free (vg_replace_malloc.c:989) - ==25795== by 0x249651: rb_gc_impl_free (default.c:8527) - ==25795== by 0x249651: rb_gc_impl_free (default.c:8508) - ==25795== by 0x249651: ruby_sized_xfree.constprop.0 (gc.c:4178) - ==25795== by 0x4626EC: ruby_sized_xfree_inlined (gc.h:277) - ==25795== by 0x4626EC: wmap_free_entry (weakmap.c:45) - ==25795== by 0x4626EC: wmap_mark_weak_table_i (weakmap.c:61) - ==25795== by 0x3A5CEF: apply_functor (st.c:1633) - ==25795== by 0x3A5CEF: st_general_foreach (st.c:1543) - ==25795== by 0x3A5CEF: rb_st_foreach (st.c:1640) - ==25795== by 0x25C991: gc_mark_children (default.c:4870) - ==25795== by 0x25C991: gc_marks_wb_unprotected_objects_plane (default.c:5565) - ==25795== by 0x25C991: rgengc_rememberset_mark_plane (default.c:5557) - ==25795== by 0x25C991: rgengc_rememberset_mark (default.c:6233) - ==25795== by 0x25C991: gc_marks_start (default.c:6057) - ==25795== by 0x25C991: gc_marks (default.c:6077) - ==25795== by 0x25C991: gc_start (default.c:6723) - ==25795== by 0x260F96: heap_prepare (default.c:2282) - ==25795== by 0x260F96: heap_next_free_page (default.c:2489) - ==25795== by 0x260F96: newobj_cache_miss (default.c:2598) - ==25795== by 0x26197F: newobj_alloc (default.c:2622) - ==25795== by 0x26197F: rb_gc_impl_new_obj (default.c:2701) - ==25795== by 0x26197F: newobj_of (gc.c:890) - ==25795== by 0x26197F: rb_wb_protected_newobj_of (gc.c:917) - ==25795== by 0x2DEA88: rb_class_allocate_instance (object.c:131) - ==25795== by 0x2E3B18: class_call_alloc_func (object.c:2141) - ==25795== by 0x2E3B18: rb_class_alloc (object.c:2113) - ==25795== by 0x2E3B18: rb_class_new_instance_pass_kw (object.c:2172) - ==25795== by 0x429DDC: vm_call_cfunc_with_frame_ (vm_insnhelper.c:3786) - ==25795== by 0x44B08D: vm_sendish (vm_insnhelper.c:5953) - ==25795== by 0x44B08D: vm_exec_core (insns.def:898) - ==25795== by 0x43A7A4: rb_vm_exec (vm.c:2564) - ==25795== Block was alloc'd at - ==25795== at 0x484680F: malloc (vg_replace_malloc.c:446) - ==25795== by 0x25CE9E: rb_gc_impl_malloc (default.c:8542) - ==25795== by 0x462A39: wmap_aset_replace (weakmap.c:423) - ==25795== by 0x3A5542: rb_st_update (st.c:1487) - ==25795== by 0x462B8E: wmap_aset (weakmap.c:452) - ==25795== by 0x429DDC: vm_call_cfunc_with_frame_ (vm_insnhelper.c:3786) - ==25795== by 0x44B08D: vm_sendish (vm_insnhelper.c:5953) - ==25795== by 0x44B08D: vm_exec_core (insns.def:898) - ==25795== by 0x43A7A4: rb_vm_exec (vm.c:2564) - ==25795== by 0x234914: rb_ec_exec_node (eval.c:281) - ==25795== by 0x2369B8: ruby_run_node (eval.c:319) - ==25795== by 0x15D675: rb_main (main.c:43) - ==25795== by 0x15D675: main (main.c:62) - - * Fix use-after-free for WeakKeyMap - - [Bug #20688] - - We cannot free the key before the ST_DELETE because it could hash the - key which would read the key and would cause a use-after-free. Instead, - we store the key and free it on the next iteration. - -commit 9ae91eb2aa8a82315026e72fb58d89bc23432335 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-08-22 01:40:11 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-08-22 01:40:11 +0900 - - Backport warning feature for bundled gems from master (#11420) - - * Make sure to always use the right `warn` - - * lib/bundled_gems.rb: more reliable caller detection - - The `2` skipped frames went out of sync and now it should be `3`. - - Rather than just update the offset, we can implement a way that - is adaptative as long as all require decorators are also called require. - - Also we should compute the corresponding `uplevel` otherwise the - warning will still point decorators. - - Co-authored-by: "Hiroshi SHIBATA" <hsbt@ruby-lang.org> - - * Warn ostruct for Ruby 3.5 - - * Warn pstore for Ruby 3.5 - - * Mark rdoc as bundled gems at Ruby 3.5 - - * Warn to use win32ole without Gemfile for Ruby 3.5 - - * EXACT list is mostly same as SINCE list on bundled gems. - - * Mark to warn fiddle as bundled gems for Ruby 3.5 - - * Mark to warn logger as bundled gems for Ruby 3.5 - - * We should use uplevel:2 in another case. - - Like the following scenario with bootsnap, that frames are same or smaller than frame_to_skip(=3). - - --- - "/Users/hsbt/.local/share/rbenv/versions/3.3-dev/lib/ruby/3.3.0/bundled_gems.rb:69:in `block (2 levels) in replace_require'" - "/Users/hsbt/.local/share/gem/gems/bootsnap-1.18.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'" - "test_warn_bootsnap.rb:11:in `<main>'" - --- - - * Delete unnecessary rubocop disable comment - - * Show correct script name with sub-feature case - - * Skip to show script name with using ruby -r option - - * Don't show script name when bundle exec and call ruby script directly. - - * Pick word fix from 34adc07372c10170b8ca36111d216cbd8e4699be - - --------- - - Co-authored-by: David Rodríguez <deivid.rodriguez@riseup.net> - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - Co-authored-by: Kentaro Takeyama <75117116+obregonia1@users.noreply.github.com> - -commit 66312ad913d67bfd3c2c83b174eabf537f5def84 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2024-08-15 02:19:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-08-15 02:19:53 +0900 - - Re-initialize vm->ractor.sched.lock after fork (#11372) - - [Bug #20633] Re-initialize vm->ractor.sched.lock after fork - - Previously under certain conditions it was possible to encounter a - deadlock in the forked child process if ractor.sched.lock was held. - - Co-authored-by: Nathan Froyd <froydnj@gmail.com> - -commit 4d11a0960d1b9c88c4e85bfeffb83c5f08f7099b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-08-08 16:41:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-08-08 18:00:50 +0900 - - Added bootstrap job for release workflow - -commit 65cca99b30c65d462aa67969e0f16f6e45db4705 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2024-08-07 02:34:39 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-08-07 02:34:39 +0900 - - parse.y: const_decl_path don't replace destination node by a literal (#11314) - - [Bug #20668] - - The `dest` node is assumed to be a `CDECL`, so overwriting it with - a `LIT` cause a crash on the next iteration. - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - -commit f85c7deacc25738bd83ba182370c283ba82b61d4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-07-31 01:05:54 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-07-31 01:05:54 +0900 - - Update RubyGems 3.5.16 and Bundler 2.5.16 for Ruby 3.3 (#11252) - - * Merge RubyGems-3.5.12 and Bundler-2.5.12 - - * Merge RubyGems-3.5.13 and Bundler-2.5.13 - - * Merge RubyGems-3.5.14 and Bundler-2.5.14 - - * Merge RubyGems-3.5.15 and Bundler-2.5.15 - - * Merge RubyGems-3.5.16 and Bundler-2.5.16 - -commit 0922afa95b3e390876cbea7f78d3d93d979f27d4 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2024-07-31 01:05:09 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-07-31 01:05:09 +0900 - - [Bug #20654] Fix floor and ceil when ndigits is large (#11277) - - * Fix floor when ndigits is large - - [Bug #20654] - - This commit fixes Integer#floor and Float#floor when the number is - negative and ndigits is large such that 10**ndigits is a bignum. - - Previously, it would return 0 in such cases. However, this would cause - unexpected behaviour such as: - - puts -1.floor(-5) # => -100000 - puts -1.floor(-10) # => -10000000000 - puts -1.floor(-20) # => 0 - - This commit changes the last result so that it will return - -100000000000000000000. - - * Fix ceil when ndigits is large - - [Bug #20654] - - This commit fixes Integer#ceil and Float#ceil when the number is - negative and ndigits is large such that 10**ndigits is a bignum. - - Previously, it would return 0 in such cases. However, this would cause - unexpected behaviour such as: - - puts 1.ceil(-5) # => 100000 - puts 1.ceil(-10) # => 10000000000 - puts 1.ceil(-20) # => 0 - - This commit changes the last result so that it will return - 100000000000000000000. - -commit ce565cd4b851977bf37a470bee54e441bb60486d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2024-07-30 09:45:26 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-07-30 09:45:26 +0900 - - [Bug #20653] Fix memory leak in String#start_with? when regexp times out (#11255) - - Fix memory leak in String#start_with? when regexp times out - - [Bug #20653] - - This commit refactors how Onigmo handles timeout. Instead of raising a - timeout error, onig_search will return a ONIGERR_TIMEOUT which the - caller can free memory, and then raise a timeout error. - - This fixes a memory leak in String#start_with when the regexp times out. - For example: - - regex = Regexp.new("^#{"(a*)" * 10_000}x$", timeout: 0.000001) - str = "a" * 1000000 + "x" - - 10.times do - 100.times do - str.start_with?(regex) - rescue - end - - puts `ps -o rss= -p #{$$}` - end - - Before: - - 33216 - 51936 - 71152 - 81728 - 97152 - 103248 - 120384 - 133392 - 133520 - 133616 - - After: - - 14912 - 15376 - 15824 - 15824 - 16128 - 16128 - 16144 - 16144 - 16160 - 16160 - -commit 6d744837abc3f7f71a1f10c7ca399201f6f05e43 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-27 12:37:21 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-07-29 11:55:48 +0900 - - [Bug #20088] Fix ARCH_FLAG for cross compiling - -commit 7571ad42f42939d172ec9a68dfe56aac724ee2ef - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2024-07-26 01:14:26 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-07-26 01:14:26 +0900 - - [Bug #20650] Fix memory leak in Regexp capture group when timeout (#11244) - - Fix memory leak in Regexp capture group when timeout - - [Bug #20650] - - The capture group allocates memory that is leaked when it times out. - - For example: - - re = Regexp.new("^#{"(a*)" * 10_000}x$", timeout: 0.000001) - str = "a" * 1000000 + "x" - - 10.times do - 100.times do - re =~ str - rescue Regexp::TimeoutError - end - - puts `ps -o rss= -p #{$$}` - end - - Before: - - 34688 - 56416 - 78288 - 100368 - 120784 - 140704 - 161904 - 183568 - 204320 - 224800 - - After: - - 16288 - 16288 - 16880 - 16896 - 16912 - 16928 - 16944 - 17184 - 17184 - 17200 - -commit 4667f8ec10269b0b5deca459f098abbdf3bae4ec - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2024-07-23 08:35:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-07-23 08:35:22 +0900 - - bundled_gems.rb: Add a fast path (#11221) - - bundled_gems.rb: Add a fast path - - [Bug #20641] `Gem::BUNDLED_GEMS.warning?` adds a lot of extra - work on top of `require`. When the call end up atually loading code - the overhead is somewhat marginal. - - However it's not uncommon for code to go some late `require` in some - paths, so it's expected that calling `require` with something already - required is somewhat fast, and `bundled_gems.rb` breaks this assumption. - - To avoid this, we can have a fast path that in most case allow to - short-circuit all the heavy computations. If we extract the feature - basename and it doesn't match any of the bundled gems we care about - we can return very early. - - With this change `require 'date'` is now only 1.33x slower on Ruby - 3.3.3, than it was on Ruby 3.2.2, whereas before this change it - was at least 100x slower. - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - -commit 425e468d25a70740cef3ed676e9b82f7902e077a - Author: Ivo Anjo <ivo.anjo@datadoghq.com> - AuthorDate: 2024-07-16 01:08:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-07-16 01:08:16 +0900 - - [Backport #20633] Fix the condition for `atomic_signal_fence` (#11166) - - [Bug #20633] Fix the condition for `atomic_signal_fence` - - `AC_CHECK_DECLS` defines `HAVE_DECL_SYMBOL` to 1 if declared, 0 - otherwise, not undefined. - - Co-authored-by: kimuraw (Wataru Kimura) <kimuraw@i.nifty.jp> - -commit 3427a1679a8ca30465c684ac28449f495bff8a22 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2024-07-10 00:55:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-07-10 00:55:04 +0900 - - retry on cancelling of `getaddrinfo` (#11131) - - When the registerred unblock function is called, it should retry - the cancelled blocking function if possible after checkints. - - For example, `SIGCHLD` can cancel this method, but it should not - raise any exception if there is no trap handlers. - - The following is repro-code: - - ```ruby - require 'socket' - PN = 10_000 - - 1000000.times{ - p _1 - PN.times{ - fork{ - sleep rand(0.3) - } - } - i = 0 - while i<PN - cpid = Process.wait -1, Process::WNOHANG - if cpid - # p [i, cpid] - i += 1 - end - - begin - TCPServer.new(nil, 0).close - rescue - p $! - exit! - end - end - } - ``` - -commit be1089c8ec5ba40e09b1553e36b3174bf4014d9d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-07-09 08:28:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-07-09 08:28:22 +0900 - - v3.3.4 - -commit 17e21d815583ef7d6be03f29e90a219602497626 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-07-09 08:08:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-07-09 08:08:42 +0900 - - merge revision(s) fc33559c: [Backport #20570] - - clear `kw_flag` if given hash is nil - - https://bugs.ruby-lang.org/issues/20570 is caused I missed to - clear the `kw_flag` even if `keyword_hash` is nil. - -commit df8a08fb6a1f173a9c25db15fbe390096f39c2ff - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-07-09 08:04:30 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-07-09 08:04:30 +0900 - - merge revision(s) 75aaeb35b82da26359b9418d2963384d0c55839c: [Backport #20239] - - [Bug #20239] Fix overflow at down-casting - -commit 9d583dd43a24354e8ae58c089cf091c1243e6e60 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-07-09 07:58:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-07-09 07:58:13 +0900 - - merge revision(s) fba8aff7, d8c6e91748871ab2287d7703347847fe18a292d2: [Backport #20592] - - [Bug #20592] Fix segfault when sending NULL to freeaddrinfo - - On alpine freeaddrinfo does not accept NULL pointer - - Fix dangling `else` - -commit 8a2e41d34b135046957e1195a5d4f4967a82a965 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-07-09 07:55:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-07-09 07:55:17 +0900 - - merge revision(s) 2dd46bb82ffc4dff01d7ea70922f0e407acafb4e: [Backport #20468] - - [Bug #20468] Fix safe navigation in `for` variable - -commit a40645e115e6cd6328bb302dfc78b16f6ad45938 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-07-09 07:42:06 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-07-09 07:42:06 +0900 - - merge revision(s) 01b13886: [Backport #20562] - - [Bug #20562] Categorize `RUBY_FREE_AT_EXIT` warning as experimental - -commit 9a8454ea5ca2bb4d6540d5c43b8e91e199ed1a8a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-07-09 07:40:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-07-09 07:40:28 +0900 - - Fix malformed JSON in macOS CI - -commit f811f79b3aa5d1fba3a9a631a802aa1d41fa5dc4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-07-06 00:13:11 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-07-06 00:13:11 +0900 - - Refine macOS CI (#11107) - - Update macos runners with latest environments. - - * Use macos-14 instead of macos-arm-oss - * Removed macos-11 and added macos-13 - -commit b2be36ef3349ebdab5423ea3337c03bcc3319b60 - Author: Ivo Anjo <ivo.anjo@datadoghq.com> - AuthorDate: 2024-07-04 01:56:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-07-04 01:56:00 +0900 - - [Backport #11036] Add explicit compiler fence when pushing frames to ensure safe profiling (#11090) - - **What does this PR do?** - - This PR tweaks the `vm_push_frame` function to add an explicit compiler - fence (`atomic_signal_fence`) to ensure profilers that use signals - to interrupt applications (stackprof, vernier, pf2, Datadog profiler) - can safely sample from the signal handler. - - This is a backport of #11036 to Ruby 3.3 . - - **Motivation:** - - The `vm_push_frame` was specifically tweaked in - https://github.com/ruby/ruby/pull/3296 to initialize the a frame - before updating the `cfp` pointer. - - But since there's nothing stopping the compiler from reordering - the initialization of a frame (`*cfp =`) with the update of the cfp - pointer (`ec->cfp = cfp`) we've been hesitant to rely on this on - the Datadog profiler. - - In practice, after some experimentation + talking to folks, this - reordering does not seem to happen. - - But since modern compilers have a way for us to exactly tell them - not to do the reordering (`atomic_signal_fence`), this seems even - better. - - I've actually extracted `vm_push_frame` into the "Compiler Explorer" - website, which you can use to see the assembly output of this function - across many compilers and architectures: https://godbolt.org/z/3oxd1446K - - On that link you can observe two things across many compilers: - 1. The compilers are not reordering the writes - 2. The barrier does not change the generated assembly output - (== has no cost in practice) - - **Additional Notes:** - - The checks added in `configure.ac` define two new macros: - * `HAVE_STDATOMIC_H` - * `HAVE_DECL_ATOMIC_SIGNAL_FENCE` - - Since Ruby generates an arch-specific `config.h` header with - these macros upon installation, this can be used by profilers - and other libraries to test if Ruby was compiled with the fence enabled. - - **How to test the change?** - - As I mentioned above, you can check https://godbolt.org/z/3oxd1446K - to confirm the compiled output of `vm_push_frame` does not change - in most compilers (at least all that I've checked on that site). - -commit 291cc913503475a204c93a53a2f470c8cc6bfca2 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2024-06-29 05:04:49 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-29 05:04:49 +0900 - - [Bug #20598] Fix corruption of internal encoding string (#11069) - - Fix corruption of internal encoding string - - [Bug #20598] - - Just like [Bug #20595], Encoding#name_list and Encoding#aliases can have - their strings corrupted when Encoding.default_internal is set to nil. - - Co-authored-by: Matthew Valentine-House <matt@eightbitraptor.com> - -commit 7a780a3ef766e0622ade4a5fbf2518f73c38282b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2024-06-27 23:46:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-27 23:46:53 +0900 - - [Bug #20595] Fix corruption of encoding name string (#11063) - - Fix corruption of encoding name string - - [Bug #20595] - - enc_set_default_encoding will free the C string if the encoding is nil, - but the C string can be used by the encoding name string. This will cause - the encoding name string to be corrupted. - - Consider the following code: - - Encoding.default_internal = Encoding::ASCII_8BIT - names = Encoding.default_internal.names - p names - Encoding.default_internal = nil - p names - - It outputs: - - ["ASCII-8BIT", "BINARY", "internal"] - ["ASCII-8BIT", "BINARY", "\x00\x00\x00\x00\x00\x00\x00\x00"] - - Co-authored-by: Matthew Valentine-House <matt@eightbitraptor.com> - -commit 01762837b7f98934e402c6888e15de32a673b0fd - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-06-21 02:57:19 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-21 02:57:19 +0900 - - [Bug #20581][3.3] Fix unintentional truncation for dependencies of bundled gems (#11006) - - * Try to load original gemspec from `.bundle/gems/foo-x.y.z/foo.gemspec`. - - `.bundle/specification/foo-x.y.z.gemspec` may be changed our toolchain - - * Try to find gemspec from `.bundle/specifications - - * Adjust indent - -commit 3160434c506fe2c7c9c69965dceb6e8fd7357c28 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-06-21 02:41:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-06-21 02:41:13 +0900 - - Add k0kubun to ruby_3_3 CODEOWNERS - -commit d1ffd5ecfa62a049b7c508f30b6912a890de1b32 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2024-06-21 02:39:20 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-21 02:39:20 +0900 - - String.new(capacity:) don't substract termlen (#11027) - - [Bug #20585] - - This was changed in 36a06efdd9f0604093dccbaf96d4e2cb17874dc8 because - `String.new(1024)` would end up allocating `1025` bytes, but the problem - with this change is that the caller may be trying to right size a String. - - So instead, we should just better document the behavior of `capacity:`. - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - -commit a3eb5e5c70eaee12964cdd807b8f19950003141f - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2024-06-14 02:02:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-14 02:02:32 +0900 - - Don't call `Warning.warn` unless the category is enabled (#10981) - - Don't call `Warning.warn` unless the category is enabled - - The warning category should be enabled if we want to call - `Warning.warn`. - - This commit speeds up the following benchmark: - - ```ruby - eval "def test; " + - 1000.times.map { "' '.chomp!" }.join(";") + "; end" - - def run_benchmark count - i = 0 - while i < count - start = Process.clock_gettime(Process::CLOCK_MONOTONIC) - yield - ms = Process.clock_gettime(Process::CLOCK_MONOTONIC) - start - puts "itr ##{i}: #{(ms * 1000).to_i}ms" - i += 1 - end - end - - run_benchmark(25) do - 250.times do - test - end - end - ``` - - On `master` this runs at about 92ms per iteration. With this patch, it - is 7ms per iteration. - - [Bug #20573] - -commit aa957546fa553abadd888ba18675c099df1178e0 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2024-06-14 02:02:02 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-14 02:02:02 +0900 - - Bump shlex from 1.1.0 to 1.3.0 in /yjit/bindgen (#10985) - - `yjit-bindgen` isn't run to build Ruby releases at all, but people might - be running security scanners on the source tarball. Upgrade this - dependency to calm the scanners. - - Backport of <https://github.com/ruby/ruby/pull/9652>. - See: <https://github.com/ruby/ruby/pull/10980> - -commit f1c7b6f435f1167a0514b39a5f72f55cec4d1426 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-06-12 08:54:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-06-12 08:54:24 +0900 - - v3.3.3 - -commit 97b1bf9ac11848c2783264d22bf7cdb7f32a21cf - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2024-06-12 08:43:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-12 08:43:32 +0900 - - [Bug #20270] Fix --parser=prism (#10970) - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - -commit d1869cfb852cf95b5a51025c016437ab46b12104 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-06-12 03:28:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-06-12 03:29:27 +0900 - - redmine-backporter.rb: Prepend commit: to shorter revs - - Some of the places in Redmine (e.g. Associated revisions) print - revisions using only 8 characters. Even when I copied a revision from - there, I want to prepend commit: in the message. - -commit 23f4b78ad8844ec81cb02fad25a6247a2d498582 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-06-12 03:17:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-06-12 03:17:32 +0900 - - merge revision(s) 27321290: [Backport #20521] - - [Bug #20521] ripper: Clean up strterm - -commit d3b139821294f56e6b31e28608c534d9f0920fc2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-06-12 03:11:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-06-12 03:11:23 +0900 - - merge revision(s) 1e08a9f0e9058186db18f29efc6458c00f10a856: [Backport #20499] - - [Bug #20499] Use Xcode owned tools for Xcode clang - - Xcode has its own version tools that may be incompatible with genuine - LLVM tools, use the tools in the same directory. - -commit 8951040aadca57fce633b0f714248de78a962c22 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2024-06-12 03:08:31 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-12 03:08:31 +0900 - - [3.3 backport] compile.c: use putspecialobject for RubyVM::FrozenCore (#10962) - - compile.c: use putspecialobject for RubyVM::FrozenCore - - [Bug #20569] - - `putobject RubyVM::FrozenCore`, is not serializable, we - have to use `putspecialobject VM_SPECIAL_OBJECT_VMCORE`. - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - -commit 4c50d23245689761e04db450ced9fe9fa76997d0 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2024-06-12 03:01:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-12 03:01:29 +0900 - - Raise SyntaxError on invalid encoding symbol (#10967) - - [Bug #20280] - - Backport of #10014. - -commit 40251ed0dfe99bb09c2fa542fce603ade25e3729 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2024-06-11 08:05:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-11 08:05:58 +0900 - - Fix inconsistent evaluation of keyword splat (#10959) - - [Bug #20180] - - Backports #9624. - -commit d0327a7224d8d778a75c7554b287369895dc17be - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2024-06-06 06:54:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-06 06:54:24 +0900 - - Don't add `+YJIT` to `RUBY_DESCRIPTION` until it's actually enabled (#10920) - - If you start Ruby with `--yjit-disable`, the `+YJIT` shouldn't be - added until `RubyVM::YJIT.enable` is actually called. Otherwise - it's confusing in crash reports etc. - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - -commit e0fe6f70170924397b957d6cfa84774592b1c809 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-06-05 16:28:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-06-05 16:29:17 +0900 - - merge revision(s) f8abd24b1f28998157da1230b231419ef7b81722: [Backport #20522] - - Improve YJIT performance warning regression test - - [Bug #20522] - -commit 06f470ce66be24f82d3720dd2bb08b18b16753ac - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-06-05 13:36:46 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-05 13:36:46 +0900 - - Merge RubyGems 3.5.11 and Bundler 2.5.11 for Ruby 3.3 (#10870) - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit 1ff55bb09dca302d42951059a73e6d237fd8c338 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-06-05 06:58:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-06-05 06:58:37 +0900 - - merge revision(s) 05553cf22d43dd78b8f30cc4591230b5c000c538: [Backport #20517] - - [Bug #20517] Make a multibyte character one token at meta escape - -commit 4f00d98b327e3aa23564aa765488d15bc60c9e79 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2024-06-05 05:21:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-05 05:21:58 +0900 - - [3.3 backport] Do not emit shape transition warnings when YJIT is compiling (#10911) - - Do not emit shape transition warnings when YJIT is compiling - - [Bug #20522] - - If `Warning.warn` is redefined in Ruby, emitting a warning would invoke - Ruby code, which can't safely be done when YJIT is compiling. - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - -commit b74f669e2fbe5c63409878e7a9f9d39c8554ff77 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2024-06-05 05:17:41 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-06-05 05:17:41 +0900 - - YJIT: Fix out of bounds access when splatting empty array (#10905) - - This is a backport of 6c8ae44a388e5c03b7db90376af3652007b574e8 with a - test tailored to crash the 3.3.x branch (from GH-10904). - - Previously, we read the last element array even when the array was - empty, doing an out-of-bounds access. This sometimes caused a SEGV. - - [Bug #20496] - -commit 1df1538be4a494bbc5ef6e3504312a0284948709 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-06-05 05:14:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-06-05 05:14:09 +0900 - - merge revision(s) f54369830f83a65fb54916d762883fbe6eeb7d0b, 338eb0065bd81ba8ae8b9402abc94804a24594cc, ac636f5709feb1d9d7a0c46a86be153be765cf21: [Backport #20516] - - Revert "Rollback to released version numbers of stringio and strscan" - - This reverts commit 6a79e53823e328281b9e9eee53cd141af28f8548. - - [ruby/strscan] StringScanner#captures: Return nil not "" for unmached capture (https://github.com/ruby/strscan/pull/72) - - fix https://github.com/ruby/strscan/issues/70 - If there is no substring matching the group (s[3]), the behavior is - different. - - If there is no substring matching the group, the corresponding element - (s[3]) should be nil. - - ``` - s = StringScanner.new('foobarbaz') #=> #<StringScanner 0/9 @ "fooba..."> - s.scan /(foo)(bar)(BAZ)?/ #=> "foobar" - s[0] #=> "foobar" - s[1] #=> "foo" - s[2] #=> "bar" - s[3] #=> nil - s.captures #=> ["foo", "bar", ""] - s.captures.compact #=> ["foo", "bar", ""] - ``` - - ``` - s = StringScanner.new('foobarbaz') #=> #<StringScanner 0/9 @ "fooba..."> - s.scan /(foo)(bar)(BAZ)?/ #=> "foobar" - s[0] #=> "foobar" - s[1] #=> "foo" - s[2] #=> "bar" - s[3] #=> nil - s.captures #=> ["foo", "bar", nil] - s.captures.compact #=> ["foo", "bar"] - ``` - - https://docs.ruby-lang.org/ja/latest/method/MatchData/i/captures.html - ``` - /(foo)(bar)(BAZ)?/ =~ "foobarbaz" #=> 0 - $~.to_a #=> ["foobar", "foo", "bar", nil] - $~.captures #=> ["foo", "bar", nil] - $~.captures.compact #=> ["foo", "bar"] - ``` - - * StringScanner#captures is not yet documented. - https://docs.ruby-lang.org/ja/latest/class/StringScanner.html - - https://github.com/ruby/strscan/commit/1fbfdd3c6f - - [ruby/strscan] Bump version - - https://github.com/ruby/strscan/commit/d6f97ec102 - -commit 0a0338b06fcc3690346d5a3bec60bbcee85ec7ce - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-06-05 03:43:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-06-05 03:43:25 +0900 - - merge revision(s) 9f708d48f6df37ee9600db9d51b57a156609a13b, 0301473fb523c71d8cdc4966971f31f502001185, 874e9fc34d728f8e2444d15aa6759befd217c464, 7f0e26b7f99bf76408569892ce20318501f74729: [Backport #20516] - - Clear runtime dependencies if default gems is specified. - - The current build system uses runtime dependencies from only - `.bundle` directory. We shouldn't install runtime dependencies - from rubygems.org when `make test-bundled-gems` is invoked. - - Fixed dependencies list format - - Don't need to remove ruby2_keywords dependency from drb - - Re-use strscan with ruby repo - -commit 12c806acc3923115f2c6590c885e43f2f24a17e3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-06-05 03:31:00 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-06-05 03:32:28 +0900 - - merger.rb: Put spaces in between revisions - - so that they are linked correctly on GitHub - -commit c9bec74b21f0e6cf05d9b200a1636bdb8069de8c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-06-01 09:13:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-06-01 09:13:33 +0900 - - merge revision(s) 70ad58cb62b195ba86a5ef07a565b22b02a040ea: [Backport #20516] - - Update bundled_gems - -commit ea196a3c9f181d368ed1d308201f44a88de69b42 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-31 06:53:54 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-31 06:53:54 +0900 - - merge revision(s) be7c91db44d6b8dba8fa11ff782965b4bfa0b3c8: [Backport #20515] - - Do not pollute toplevel namespace - -commit 8f5b1bb64b6cdc09574390e7efb8cb5550762b78 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-31 05:05:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-31 05:05:32 +0900 - - merge revision(s) fd549b229b0822198ddc847703194263a2186ed1: [Backport #20515] - - test_bignum: defined? returns String (#10880) - MIME-Version: 1.0 - Content-Type: text/plain; charset=UTF-8 - Content-Transfer-Encoding: 8bit - - didn't verify the test is working properly due to mistaken auto-merge… [Bug #20515] - - bug: https://bugs.ruby-lang.org/issues/20515 - follow-up: 22e4eeda6561693367fc7a00b92b90f46b09cabd - follow-up: https://github.com/ruby/ruby/pull/10875 - -commit 74ba1914dd120e0c9ea33d86eae7c5d3e5c730f1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-31 03:54:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-31 03:54:34 +0900 - - merge revision(s) 22e4eeda6561693367fc7a00b92b90f46b09cabd,1ab7c412d2e3880a7ad233c32e93961888f8145c: [Backport #20515] - - ci: Test whether GMP is working in compilers.yml (#10875) - - Avoid reoccurence of [Bug #20515] - - Requires https://github.com/ruby/ruby/pull/10876 since 18eaf0be905e3e251423b42d6f4e56b7cae1bc3b - - bug: https://bugs.ruby-lang.org/issues/20515 - - RUBY_CHECK_HEADER didn't define HAVE_{header-file} (#10876) - - --with-gmp is not working at all because HAVE_GMP_H - was missing since 18eaf0be90. [Bug #20515] - - bug: https://bugs.ruby-lang.org/issues/20515 - follow-up: https://bugs.ruby-lang.org/issues/20494 - follow-up: 18eaf0be905e3e251423b42d6f4e56b7cae1bc3b - follow-up: https://github.com/ruby/ruby/pull/10805 - -commit b13cf49036f0a454063cde25807785adc00f8995 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-31 03:13:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-31 03:13:15 +0900 - - merge revision(s) 055613fd868a8c94e43893f8c58a00cdd2a81f6d,127d7a35df10ee2bc99f44b888972b2c5361d84f,e2a9b87126d59e4766479a7aa12cf7a648f46506: [Backport #20447] - - Fix pointer incompatiblity - - Since the subsecond part is discarded, WIDEVAL to VALUE conversion is - needed. - - Some functions are not used when `THREAD_MODEL=none` - - `rb_thread_sched_destroy` is not used now at all - -commit e5a195edf62fe1bf7146a191da13fa1c4fecbd71 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 09:23:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 09:23:11 +0900 - - v3.3.2 - -commit a9b6a7bf7204cd1244da7e05fafea721cf3b2e4f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 09:11:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 09:11:36 +0900 - - merge revision(s) ce20367a0e2f1fcfabebf3b6bea732fc71fa79f7: [Backport #20500] - - Define `incflags` also on mswin - -commit a96233161a0e917b57c3c2cd9598d75d8b7721f5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 08:53:29 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 08:53:29 +0900 - - merge revision(s) 5fa6ba9568e87e43e08a4daeba1572254c589fb1: [Backport #20500] - - [Bug #20500] Search non-default directories for jemalloc - - Co-Authored-by: lish82 (Hiroki Katagiri) - -commit b2eb7f47b3e5f5a4681aa364ed960a0809460cdb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 08:50:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 08:50:13 +0900 - - merge revision(s) 1faeb44dfcf777ace28321e80d0ebf942161a0a7,7f87ad9fc4bc45faf8cd33602a025f27c094b2fd: [Backport #20431] - - Check if macros are defined before using - - Assume macros with the same prefix would be defined together. - - Refer autoconfigured endian macro (#10572) - - Remove the case `RB_IO_BUFFER_HOST_ENDIAN` is not defined. - -commit d65da20eb4ebf5fcbc7cd0333e1406e1dd3c373b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 08:48:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 08:48:51 +0900 - - merge revision(s) ef3803ed4028810f9088019f0db1a366370ab53a: [Backport #20502] - - Ignore the result of pthread_kill in ubf_wakeup_thread - - After an upgrade to Ruby 3.3.0, I experienced reproducible production crashes - of the form: - - [BUG] pthread_kill: No such process (ESRCH) - - This is the only pthread_kill call in Ruby. The result of pthread_kill was - previously ignored in Ruby 3.2 and below. Checking the result was added in - be1bbd5b7d40ad863ab35097765d3754726bbd54 (MaNy). - - I have not yet been able to create a minimal self-contained example, - but it should be safe to remove the checks. - -commit 0044b6aefc656874adb9266829f19870dcd3d75e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 08:34:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 08:35:18 +0900 - - merge revision(s) bc002971b6ad483dbf69b8a275c44412bb6ab954: [Backport #20094] - - [Bug #20094] Distinguish `begin` and parentheses - -commit b3f2ccea5efb060e99d289b2272ddfe413e4f051 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 08:18:29 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 08:18:29 +0900 - - merge revision(s) 18eaf0be905e3e251423b42d6f4e56b7cae1bc3b: [Backport #20494] - - [Bug #20494] Search non-default directories for GMP - - Co-Authored-by: lish82 (Hiroki Katagiri) - -commit cf643fabd5c564c1dfeb337b50b4aa76ebaa11c1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 07:52:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 07:52:15 +0900 - - merge revision(s) d292a9b98ce03c76dbe13138d20b9fbf613cc02d: [Backport #20453] - - [Bug #20453] segfault in Regexp timeout - - https://bugs.ruby-lang.org/issues/20228 started freeing `stk_base` to - avoid a memory leak. But `stk_base` is sometimes stack allocated (using - `xalloca`), so the free only works if the regex stack has grown enough - to hit `stack_double` (which uses `xmalloc` and `xrealloc`). - - To reproduce the problem on master and 3.3.1: - - ```ruby - Regexp.timeout = 0.001 - /^(a*)x$/ =~ "a" * 1000000 + "x"' - ``` - - Some details about this potential fix: - - `stk_base == stk_alloc` on - [init](https://github.com/ruby/ruby/blob/dde99215f2bc60c22a00fc941ff7f714f011e920/regexec.c#L1153), - so if `stk_base != stk_alloc` we can be sure we called - [`stack_double`](https://github.com/ruby/ruby/blob/dde99215f2bc60c22a00fc941ff7f714f011e920/regexec.c#L1210) - and it's safe to free. It's also safe to free if we've - [saved](https://github.com/ruby/ruby/blob/dde99215f2bc60c22a00fc941ff7f714f011e920/regexec.c#L1187-L1189) - the stack to `msa->stack_p`, since we do the `stk_base != stk_alloc` - check before saving. - - This matches the check we do inside - [`stack_double`](https://github.com/ruby/ruby/blob/dde99215f2bc60c22a00fc941ff7f714f011e920/regexec.c#L1221) - -commit 5c06e930748ef6bdb4ac4751ba16b7b604da3db0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 07:47:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 07:47:26 +0900 - - merge revision(s) 6ade36c06b7cef948099b8f5f483763498705d12: [Backport #20414] - - `Fiber#raise` recursively raises on nested resuming_fiber. (#10482) - - * Improve consistency of `Fiber.current.raise`. - -commit b44c02ad5a1c5c8c1c62b83eec96cf3a8a2107bc - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 07:44:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 07:44:55 +0900 - - merge revision(s) c479492a6701dcef3d3a96de8946ecf7beb079d4: [Backport #20427] - - Resize ary when `Array#sort!` block modifies embedded ary - - In cases where `rb_ary_sort_bang` is called with a block and - tmp is an embedded array, we need to account for the block - potentially impacting the capacity of ary. - - ex: - ``` - var_0 = (1..70).to_a - var_0.sort! do |var_0_block_129, var_1_block_129| - var_0.pop - var_1_block_129 <=> var_0_block_129 - end.shift(3) - ``` - - The above example can put the array into a corrupted state - resulting in a heap buffer overflow and possible segfault: - ``` - ERROR: AddressSanitizer: heap-buffer-overflow on address [...] - WRITE of size 560 at 0x60b0000034f0 thread T0 [...] - ``` - - This commit adds a conditional to determine when the capacity - of ary has been modified by the provided block. If this is - the case, ensure that the capacity of ary is adjusted to - handle at minimum the len of tmp. - -commit 5688bcb54a640b353bed4ff49032ea00f947e1aa - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 07:43:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 07:43:01 +0900 - - merge revision(s) 5d1702e01a36e11b183fe29ce10780a9b1a41cf0: [Backport #20413] - - Enumerator should use a non-blocking fiber, change `rb_fiber_new` to be non-blocking by default. (#10481) - -commit a24f19742bfa398a3b32c51df01133db7bcbc6e0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 07:40:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 07:40:49 +0900 - - merge revision(s) 58918788abd63901588e4aa1e39b5c057321c10a: [Backport #20342] - - [Bug #20342] Consider wrapped load in `main` methods - -commit 72a45ac7a3cc9bbecf641ac505f8ee791c9da48c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 07:11:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 07:11:56 +0900 - - merge revision(s) 3a04ea2d0379dd8c6623c2d5563e6b4e23986fae: [Backport #20305] - - [Bug #20305] Fix matching against an incomplete character - - When matching against an incomplete character, some `enclen` calls are - expected not to exceed the limit, and some are expected to return the - required length and then the results are checked if it exceeds. - -commit 6e46a363a8f29d93cf6992805ee67d029cea030f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 03:46:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 03:46:33 +0900 - - merge revision(s) a7ff264477105b5dc0ade6facad4176a1b73df0b: [Backport #20393] - - Don't clear pending interrupts in the parent process. (#10365) - -commit 541fc816fcb697307d666fed644ddd07ca5e942e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 03:35:46 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 03:35:46 +0900 - - [ruby/zlib] Bump up 3.1.1 - -commit 2ae6df6d03c6d9750be559641c4c9f3b39eac62d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 03:35:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 03:35:23 +0900 - - merge revision(s) 9f8f32bf9f3758ba67dd2afe7e07d9eccb68bbc7: [Backport #20289] - - [ruby/zlib] In Zlib::GzipReader#eof? check if we're actually at eof - - Only consider it eof if we read ahead and something fills the buf. - If not, we may only have empty blocks and the footer. - - Fixes https://github.com/ruby/zlib/pull/56 - - https://github.com/ruby/zlib/commit/437bea8003 - -commit 2f4fe76eff0a8c6ab7a1d2fb845453acfc3cb206 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-02-23 07:34:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 03:13:02 +0900 - - Skip under_gc_compact_stress on s390x (#10073) - -commit 548c7cb9f517dcb8029bd9698187c81819e08edd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 03:07:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 03:07:07 +0900 - - merge revision(s) 7e4b1f8e1935a10df3c41ee60ca0987d73281126: [Backport #20322] - - [Bug #20322] Fix rb_enc_interned_str_cstr null encoding - - The documentation for `rb_enc_interned_str_cstr` notes that `enc` can be - a null pointer, but this currently causes a segmentation fault when - trying to autoload the encoding. This commit fixes the issue by checking - for NULL before calling `rb_enc_autoload`. - -commit 8f1084db9b07cb74f99de70d6f8bb6076d27d8aa - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 03:00:27 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 03:00:27 +0900 - - merge revision(s) dc146babf47a84bbd1f176d766637d4a40327019,f23d5028059078a346efc977287b669d494a5a3f,a0f7de814ae5c299d6ce99bed5fb308a05d50ba0: [Backport #20296] - - [Bug #20296] Clear errinfo when `exception: false` - - [Bug #20296] Refine the test - - [Bug #20296] Fix the default assertion message - -commit 22c1e5f126db8e057bdb48d91aa5ae449e019226 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 02:57:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 02:57:43 +0900 - - Suppress -Wclobbered warnings - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit e5a1119f1b4fd93d60540cd4277e61851c3ebe45 - Author: Hiroya Fujinami <make.just.on@gmail.com> - AuthorDate: 2023-12-30 01:08:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 02:51:23 +0900 - - Reduce `if` for decreasing counter on OP_REPEAT_INC (#9393) - - This commit also reduces the warning `'stkp' may be used - uninitialized in this function`. - -commit bcf5cd3ba47e70c5c1c6328f61887bbac2f9d41b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2024-01-24 19:33:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 02:48:19 +0900 - - Initialize errno variables and fix maybe-uninitialized warnings - -commit bbb3075c46b838da3bac5e699837cf0cc90320d9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 02:33:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 02:39:10 +0900 - - Sort backport revisions by commit timestamps - -commit f12c947192aa47b355015384e5c82cbf674023f1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 02:19:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 02:19:49 +0900 - - merge revision(s) e04146129ec6898dd6a9739dad2983c6e9b68056: [Backport #20292] - - [Bug #20292] Truncate embedded string to new capacity - -commit a8b2317d16fa172edd3cd7e6fcb3bc694287d109 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 02:02:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 02:02:15 +0900 - - merge revision(s) 78d9fe69479d32214a52ad7291c3973f1b6b7f6f: [Backport #20286] - - Ensure that exiting thread invokes end-of-life behaviour. (#10039) - -commit 6aaf673e4d3fa1f8a90e6006aadefddcb87fe1de - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 01:59:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 01:59:52 +0900 - - Skip broken SSL provider tests for freebsd - -commit 6e9dbcbacc489a4cf992c2cd9987c8031fa19fb3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 01:56:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 01:56:55 +0900 - - Force-skip a LOAD_PATH spec for rhel_zlinux - -commit 3cab9b997945ba5d3d06b374d5e12e07293f8e73 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-30 12:14:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 01:40:45 +0900 - - Change test_warmup_frees_pages to check each size pool - - This should help in debugging the intermittent test failures on CI: - - TestProcess#test_warmup_frees_pages [test/ruby/test_process.rb:2779]: - <201> expected but was - <202>. - -commit 8c29a3776e9e9ba070425c5b6548ecbc8ee21366 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 01:38:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 01:38:46 +0900 - - Skip a flaky Ractor test - - https://github.com/ruby/ruby/actions/runs/9289798294/job/25564563437 - -commit 015d6bae8b5bfe44708c824419c8a72e5b7b4837 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-30 01:32:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-30 01:32:03 +0900 - - Skip a flaky test in RBS - -commit 9cb804a2bd6eb43b67a716ccef6db400e47f29cf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 09:46:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 09:46:47 +0900 - - merge revision(s) 04729fe68dceddab045be7324e26c2bb15aa62c7: [Backport #20288] - - Fix exception handling in `rb_fiber_scheduler_set`. (#10042) - -commit 0e96dd93c51337a01fa29b563c2d330c472b03b7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 09:45:21 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 09:46:44 +0900 - - merger.rb: Don't ask "conflicts resolved?" if not needed - -commit 4d34fb54b0e21af3802cddb669f34fe446ed5f3d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 09:17:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 09:17:04 +0900 - - redmine-backporter.rb: Prepend commit: to every revision - -commit 6383d0afac6aa02b3e72d08128cc1d8327f149fa - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 09:10:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 09:10:33 +0900 - - merge revision(s) 015b0e2e1d312e2be60551587389c8da5c585e6f,ac1e9e443a0d6a4d4c0801c26d1d8bd33d9eb431: [Backport #20195] - - YJIT: Fix unused warnings - - ``` - warning: unused import: `condition::Condition` - --> src/asm/arm64/arg/mod.rs:13:9 - | - 13 | pub use condition::Condition; - | ^^^^^^^^^^^^^^^^^^^^ - | - = note: `#[warn(unused_imports)]` on by default - - warning: unused import: `rb_yjit_fix_mul_fix as rb_fix_mul_fix` - --> src/cruby.rs:188:9 - | - 188 | pub use rb_yjit_fix_mul_fix as rb_fix_mul_fix; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - - warning: unused import: `rb_insn_len as raw_insn_len` - --> src/cruby.rs:142:9 - | - 142 | pub use rb_insn_len as raw_insn_len; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ - | - = note: `#[warn(unused_imports)]` on by default - ``` - - Make asm public so it stops warning about unused public stuff in there. - - YJIT: Fix ruby2_keywords splat+rest and drop bogus checks - - YJIT didn't guard for ruby2_keywords hash in case of splat calls that - land in methods with a rest parameter, creating incorrect results. - - The compile-time checks didn't correspond to any actual effects of - ruby2_keywords, so it was masking this bug and YJIT was needlessly - refusing to compile some code. About 16% of fallback reasons in - `lobsters` was due to the ISeq check. - - We already handle the tagging part with - exit_if_supplying_kw_and_has_no_kw() and should now have a dynamic guard - for all splat cases. - - Note for backporting: You also need 7f51959ff1. - - [Bug #20195] - -commit d7ad60373988487ae746129dfd7f65df1dd13b86 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 09:00:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 09:01:13 +0900 - - redmine-backporter.rb: Remove an unneeded space - - from #backport_command_string - - I don't want to leave unneeded spaces in the command history by - copy-pasting the entire line. - -commit 9c81bbbbb738a5747eab5455292536369977ee92 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 08:55:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 08:55:49 +0900 - - merge revision(s) 7f51959ff14fbe06bc1afd283d1af17b26161cf4: [Backport #20204] - - YJIT: Move guard up for a case of splat+rest - - Previously, YJIT put the guard for having enough items to extract from - splat array at a place where the side exit is invalid, so if the guard - fails, YJIT could raise something other than ArgumentError. Move the - guard up to a place before any stack manipulation. - - [Bug #20204] - -commit 912c7df0a51455b764fc3008a99365f79213e8e0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 08:52:27 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 08:52:29 +0900 - - Skip a failing spec for rhel_zlinux - - https://rubyci.s3.amazonaws.com/rhel_zlinux/ruby-3.3/log/20240528T214850Z.fail.html.gz - - ``` - 1) - Execution variable $: default $LOAD_PATH entries until sitelibdir included have @gem_prelude_index set FAILED - Expected ["/home/chkbuild/build/20240528T214850Z/mspec/lib/mspec/lib", - "/home/chkbuild/build/20240528T214850Z/mspec/lib", - "./ruby/tool/lib", - "/home/linux1/chkbuild/tmp/build/20240528T214850Z/lib/ruby/site_ruby/3.3.0", - "/home/linux1/chkbuild/tmp/build/20240528T214850Z/lib/ruby/site_ruby/3.3.0/s390x-linux", - "/home/linux1/chkbuild/tmp/build/20240528T214850Z/lib/ruby/site_ruby", - "/home/linux1/chkbuild/tmp/build/20240528T214850Z/lib/ruby/vendor_ruby/3.3.0", - "/home/linux1/chkbuild/tmp/build/20240528T214850Z/lib/ruby/vendor_ruby/3.3.0/s390x-linux", - "/home/linux1/chkbuild/tmp/build/20240528T214850Z/lib/ruby/vendor_ruby", - "/home/linux1/chkbuild/tmp/build/20240528T214850Z/lib/ruby/3.3.0", - "/home/linux1/chkbuild/tmp/build/20240528T214850Z/lib/ruby/3.3.0/s390x-linux"].include? "/home/chkbuild/build/20240528T214850Z/lib/ruby/site_ruby/3.3.0" - to be truthy but was false - /home/chkbuild/build/20240528T214850Z/rubyspec/language/predefined_spec.rb:885:in `block (2 levels) in <top (required)>' - /home/chkbuild/build/20240528T214850Z/rubyspec/language/predefined_spec.rb:846:in `<top (required)>' - ``` - - It does have /home/linux1/chkbuild/tmp/build/20240528T214850Z/lib/ruby/site_ruby/3.3.0, - so it seems actually fine. It seems to be failing due to its setup - issues. Skipping this until we figure out how to fix it. - -commit 9443606caf22b5b9f3285a6ab5ea86e3ac210e23 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2024-05-18 15:34:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 08:38:55 +0900 - - [rubygems/rubygems] Should rescue vendored net-http exception - - https://github.com/rubygems/rubygems/commit/7d2c4cf364 - -commit 239a8cc7d7c6cc60e5f32865ebfcd5e2f5c9c08d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 08:28:00 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 08:30:45 +0900 - - merger.rb: Auto-detect tickets when --ticket is not given - -commit 90fda2da5f0d5841b80d7f8dca4b38aaf2a80f51 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 07:42:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 07:54:54 +0900 - - merger.rb: Drop an obsoleted command from help - - It was needed only for SVN, and we dropped SVN support. - -commit 077558ee2b8dd3ed414b78384f21118f833eb259 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-05-29 07:54:39 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-05-29 07:54:39 +0900 - - [Bug #20511] Update reline-0.5.7 (#10848) - - * Update reline-0.5.7 - - * Update irb-1.13.1 - -commit 917f3e5d22b3364002eb1fdc2f94b35ff76f6a73 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 07:15:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 07:17:51 +0900 - - merge revision(s) f36a71e26995b69ff72bc132bbcf40ad89571414: [Backport #20307] - - [Bug #20307] Fix `Hash#update` to make frozen copy of string keys - -commit 7d3e71330fd38c402ae4a6ec14f43eb95cf50435 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2024-02-27 01:22:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 07:17:51 +0900 - - Extract `RHASH_STRING_KEY_P` - -commit 691aab8d3af36343c01f6d02cb6d3c0aea4a1f4f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2024-02-26 23:47:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 07:17:51 +0900 - - Extract `RHASH_IDENTHASH_P` - -commit 4024feba55ccf7525e4e1e0fdbca9eda5dac3b86 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2024-01-30 06:37:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 07:05:52 +0900 - - Fix RegExp warning causing flaky Ripper failure - - Sometimes this file get picked up and break Ripper tests: - - TestRipper::Generic#test_parse_files:test/ruby - assert_separately failed with error message - pid 63392 exit 0 - | test_regexp.rb:2025: warning: character class has duplicated range - - https://github.com/ruby/ruby/actions/runs/7699956651/job/20982702553#step:12:103 - -commit 93d7bf5c5c635567fa519affdfd54edeb9064834 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-05-29 06:52:47 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-05-29 06:52:47 +0900 - - merge revision(s) bbd249e351af7e4929b518a5de73a832b5617273: [Backport #20192] (#10249) - - * merge revision(s) bbd249e351af7e4929b518a5de73a832b5617273: [Backport #20192] - - YJIT: Properly reject keyword splat with `yield` - - We don't have support for keyword splat anywhere, but we tried to - compile these anyways in case of `invokeblock`. This led to bad things - happening such as passing the wrong value and passing a hash into - rb_yjit_array_len(), which raised in the middle of compilation. - - [Bug #20192] - - * Skip a new test for RJIT - -commit f18ba2c6c6a9b2a74a8c2d655ab42947edb1fc6a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 06:28:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 06:29:07 +0900 - - merger.rb: Use commit: prefix in more places - -commit b77b5c191513f5f281e72a51e6b2de29e2d2d7a6 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 06:21:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 06:22:45 +0900 - - merge revision(s) 5e0c17145131e073814c7e5b15227d0b4e73cabe: [Backport #20169] - - Make io_fwrite safe for compaction - - [Bug #20169] - - Embedded strings are not safe for system calls without the GVL because - compaction can cause pages to be locked causing the operation to fail - with EFAULT. This commit changes io_fwrite to use rb_str_tmp_frozen_no_embed_acquire, - which guarantees that the return string is not embedded. - -commit 62f450285bbe1f8fbbaf12540d6538985234f3d8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 06:05:50 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 06:10:26 +0900 - - merger.rb: Improve the help message - - It wasn't clear whether the backport command takes a commit hash or a - ticket number. - -commit 4c007195663796ca0650f2cadddbd38284996b8a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 05:58:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:58:23 +0900 - - Allow failing test-annocheck - - It causes flaky failures like this: - - ``` - + /usr/bin/docker build --rm -t ruby-fedora-annocheck-copy --build-arg=FILES=ruby -f ../src/tool/annocheck/Dockerfile-copy . - DEPRECATED: The legacy builder is deprecated and will be removed in a future release. - Install the buildx component to build images with BuildKit: - https://docs.docker.com/go/buildx/ - - Sending build context to Docker daemon 556.5MB - - Step 1/6 : FROM docker.io/fedora:latest - toomanyrequests: You have reached your pull rate limit. You may increase the limit by authenticating and upgrading: https://www.docker.com/increase-rate-limit - ``` - - It seems not that important to maintain the job for backports, so let's - allow failing it until we fix it in master branch. - -commit c564c4a0992d15c4b1a2c395061c9a95bc060767 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 05:53:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:53:43 +0900 - - Sync merger.rb from master - -commit 82ff749451aa54bc282cffc916736fd62fa65f4d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 05:39:30 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:39:30 +0900 - - Sync redmine-backporter.rb from master - -commit 46dbcd8e9b9c2b20be0af58ada427ff4a5f1794b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-05-29 05:39:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:39:05 +0900 - - Sync .gitignore from master - - to avoid committing unrelated files unexpectedly - -commit 8dda932bcded3607c189d169333bbad0860d7efd - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-03-26 11:10:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:30:26 +0900 - - Fix extension installer for out-of-place build - - https://github.com/ruby/ruby/pull/9673#issuecomment-2019028293 - -commit cf460840b825f2fd7521b0ae211353080d33ceef - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-03-25 15:16:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:30:26 +0900 - - Guard makefile target at cross-build - - http://rubyci.s3.amazonaws.com/crossruby/crossruby-master-aarch64/log/20240325T041917Z.fail.html.gz - -commit 716473e348eb74c5d437f570cd0d2a1efe30a8ae - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-03-25 17:12:31 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:30:26 +0900 - - Use load_gemspec instead of Gem::Specification.load. - - We need to purge `git ls-files` from gemspec in default gems. - -commit 1849046d1f51b3630d5c68e2e6ff0746860eac9d - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2024-03-21 01:18:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:30:26 +0900 - - Consider extensions in gems outside of ext/ - -commit e60ad0b6f5ba9ad2da83472049cd7dd6f830139e - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2024-03-21 01:17:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:30:26 +0900 - - Extract `root` helper - - It holds the root directory for each type of default gem (ext/ or lib/). - -commit 642cf3fc8a0f7c31875d4bbc3628f835ebfc48a5 - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2024-03-19 04:58:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:30:26 +0900 - - Consider `target_prefix` in extension Makefiles - -commit 57b56225acbf2d0c08c3c9271c531e389359f453 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2024-01-24 18:22:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:30:26 +0900 - - Consistently put requirable features in default gemspecs file list - -commit 7ff330419f6beba9828681421762d6b495656056 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2024-01-24 18:16:48 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:30:26 +0900 - - Fix gemspec file list for extension gems - - So that it also includes requirable features provided by extensions. - -commit a63114323b614429998e7f9d30d9b344d271f20a - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2024-03-21 01:10:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:30:26 +0900 - - Simplify FileCollector interface - -commit e43393ac0f0376bb831f310de285a4e72837c972 - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2024-03-21 00:43:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:30:26 +0900 - - Use `$ext_build_dir` consistently - - Instead of hardcoded "ext". - -commit 6edd65a080b156f1ce78fdcf57214c1644a049db - Author: Eugene Kenny <elkenny@gmail.com> - AuthorDate: 2024-04-24 20:10:48 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:29:22 +0900 - - [Bug #20450] Remove rubyarchdir from bootsnap paths - -commit 718a78cdf552fe08e4f90a29b062542ceeecfe60 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-04-08 16:20:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:29:22 +0900 - - Added test case for bundled gems warning with -r option. - - This is for 76914d474d93b7485973c3bca4fa43b59f5bd383 - -commit a121e698401b947655921a071ee2edf01992219d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-03-25 13:31:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:29:22 +0900 - - Bootsnap and Zeitwerk are working correctly now - -commit edebbade1b48613f59c7cc7fcc82ece601b54dce - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-03-25 13:22:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:29:22 +0900 - - Add newline each test script - -commit 178de0e95356e6be288b1b722fd3a02d1db10bd8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-03-25 12:45:30 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:29:22 +0900 - - Added test script for bundled_gems.rb with zeitwerk - -commit 7a3cc549465125d48bedd0a22660a379914340a8 - Author: Masataka Pocke Kuwabara <kuwabara@pocke.me> - AuthorDate: 2024-04-08 12:41:29 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:29:22 +0900 - - Fix error when default gem is loaded from `-r` option - - This patch fixes an error when a default gem that will be migrated to - a bundled gem is loaded from `-r` option. - - Problem - === - - `bundle exec ruby -rostruct -e ''` unexpectedly raises the following error: - - ```console - $ ruby -v - ruby 3.4.0dev (2024-04-08T02:39:00Z master 6f7e8e278f) [arm64-darwin21] - $ bundle init && bundle install - $ bundle exec ruby -rostruct -e '' - /Users/kuwabara.masataka/.rbenv/versions/trunk/lib/ruby/3.4.0+0/bundled_gems.rb:111:in 'Gem::BUNDLED_GEMS.warning?': undefined method 'find' for nil (NoMethodError) - - caller = caller_locations(3, 3).find {|c| c&.absolute_path} - ^^^^^ - from /Users/kuwabara.masataka/.rbenv/versions/trunk/lib/ruby/3.4.0+0/bundled_gems.rb:75:in 'block (2 levels) in Kernel#replace_require' - ``` - - Solution - === - - This patch uses a safe navigation operator to fix this problem. By this - change, the command will show the warning message correctly. - - ```console - $ bundle exec ruby -rostruct -e '' - warning: ostruct was loaded from the standard library, but will no longer be part of the default gems since Ruby 3.5.0. Add ostruct to your Gemfile or gemspec. - ``` - -commit 121cec845a0c3d3529ebfdebafb339dddbfdeb90 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-01-19 16:08:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:29:22 +0900 - - Ignore warnings on the bundled gems repo - -commit 0b3a2cf5d33688378a0d947f1623879838fb9c4c - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2024-03-25 16:45:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2024-05-29 05:29:22 +0900 - - lib/bundled_gems.rb: dynamically ignore Kernel.require decorators - - Followup: https://github.com/ruby/ruby/pull/10347 - - This avoid directly referencing bootsnap and zeitwerk, and also - handle other gems that may decorate `require`. - -commit b6c07acedb3ca56471754a082b3db20bb863c92e - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2024-05-29 05:17:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-05-29 05:17:24 +0900 - - Backport bug #20493 to Ruby 3.3 (#10798) - - Inline RB_VM_SAVE_MACHINE_CONTEXT into BLOCKING_REGION - - There's an exhaustive explanation of this in the linked redmine bug, but - the short version is as follows: - - blocking_region_begin can spill callee-saved registers to the stack for - its own use. That means they're not saved to ec->machine by the call to - setjmp, since by that point they're already on the stack and new, - different values are in the real registers. ec->machine's end-of-stack - pointer is also bumped to accomodate this, BUT, after - blocking_region_begin returns, that points past the end of the stack! - - As far as C is concerned, that's fine; the callee-saved registers are - restored when blocking_region_begin returns. But, if another thread - triggers GC, it is relying on finding references to Ruby objects by - walking the stack region pointed to by ec->machine. - - If the C code in exec; subsequently does things that use that stack - memory, then the value will be overwritten and the GC might prematurely - collect something it shouldn't. - - [Bug #20493] - -commit 1c991f3bf40c2e506a819732dd0c4afe5d3c5f46 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2024-03-12 22:39:05 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-04-30 14:02:50 +0900 - - [ruby/openssl] test_asn1.rb: Remove the assertions of the time string format without second. - - This commit fixes the following errors in the tests. - Because the OpenSSL project changed the code to make the time string format - without second invalid. So, we drop the assertions. - - ``` - 1) Error: test_generalizedtime(OpenSSL::TestASN1): OpenSSL::ASN1::ASN1Error: generalizedtime is too short - /home/runner/work/ruby-openssl/ruby-openssl/test/openssl/test_asn1.rb:698:in `decode' - /home/runner/work/ruby-openssl/ruby-openssl/test/openssl/test_asn1.rb:698:in `decode_test' - /home/runner/work/ruby-openssl/ruby-openssl/test/openssl/test_asn1.rb:433:in `test_generalizedtime' - 430: OpenSSL::ASN1::GeneralizedTime.new(Time.utc(9999, 9, 8, 23, 43, 39)) - 431: # LibreSSL 3.6.0 requires the seconds element - 432: return if libressl? - => 433: decode_test B(%w{ 18 0D }) + "201612081934Z".b, - 434: OpenSSL::ASN1::GeneralizedTime.new(Time.utc(2016, 12, 8, 19, 34, 0)) - 435: # not implemented - 436: # decode_test B(%w{ 18 13 }) + "https://github.com/ruby/openssl/commit/201612081934+0930".b, - - 2) Error: test_utctime(OpenSSL::TestASN1): OpenSSL::ASN1::ASN1Error: utctime is too short - /home/runner/work/ruby-openssl/ruby-openssl/test/openssl/test_asn1.rb:698:in `decode' - /home/runner/work/ruby-openssl/ruby-openssl/test/openssl/test_asn1.rb:698:in `decode_test' - /home/runner/work/ruby-openssl/ruby-openssl/test/openssl/test_asn1.rb:411:in `test_utctime' - 408: end - 409: # Seconds is omitted. LibreSSL 3.6.0 requires it - 410: return if libressl? - => 411: decode_test B(%w{ 17 0B }) + "1609082343Z".b, - 412: OpenSSL::ASN1::UTCTime.new(Time.utc(2016, 9, 8, 23, 43, 0)) - 413: # not implemented - 414: # decode_test B(%w{ 17 11 }) + "https://github.com/ruby/openssl/commit/500908234339+0930".b, - ``` - - https://github.com/ruby/openssl/commit/2e826d5715 - -commit 85863f4d4d6f798a3a2afc33be243e5604c222a6 - Author: Xi Ruoyao <xry111@xry111.site> - AuthorDate: 2024-04-24 14:42:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2024-04-30 14:02:50 +0900 - - [ruby/net-http] Skip test_session_reuse_but_expire with OpenSSL 3.3 - - OpenSSL 3.3.0 9 Apr 2024 is also broken. - - Signed-off-by: Xi Ruoyao <xry111@xry111.site> - - https://github.com/ruby/net-http/commit/ab525c956d - -commit c56cd86388092faec079981f779f140717020d58 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2024-04-23 19:20:14 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-04-23 19:20:14 +0900 - - v3.3.1 - -commit dde99215f2bc60c22a00fc941ff7f714f011e920 - Author: Isaac Peka <7493006+isaac-peka@users.noreply.github.com> - AuthorDate: 2023-08-24 20:14:33 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-04-22 16:42:03 +0900 - - Fix handling of reg->dmin in Regex matching - -commit c38fc1bb36597264840d96d7475b9891c61c5240 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-04-12 14:01:47 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-04-22 16:29:28 +0900 - - Fix Use-After-Free issue for Regexp - - Co-authored-by: Isaac Peka <7493006+isaac-peka@users.noreply.github.com> - -commit 7227b859a7bf7626ee73de8130796657b7c7f3b5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-04-16 11:22:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-04-16 11:22:22 +0900 - - Merge RubyGems 3.5.9 and Bundler 2.5.9 (Fixed CI at Ruby 3.3) (#10348) - - * Merge RubyGems-3.5.6 and Bundler-2.5.6 - - * Merge RubyGems-3.5.7 and Bundler-2.5.7 - - * Merge RubyGems-3.5.8 and Bundler-2.5.8 - - * Partly reverted about https://github.com/rubygems/rubygems/pull/7483 - - * Merge RubyGems-3.5.9 and Bundler-2.5.9 - -commit 2f654588d9e0cefff1c23529d2f2672029e1bd21 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-03-25 17:09:56 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-25 17:09:56 +0900 - - Backport https://github.com/ruby/ruby/pull/10347 (#10349) - - Fix incorrect warning target with Zeitwerk and support warning with Bootsnap. - -commit 6d6818883b8f613fe9b6c72ac7eb9b313bba097b - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-22 10:33:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-22 10:33:40 +0900 - - merge revision(s) b176315827d1082f43628013a7d89fda02724d33: [Backport #20324] (#10329) - - [Bug #20324] Uncomparable ranges are not overlapping - -commit a24802e8fd7e05077256605885c82ffd8221bc94 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-22 09:25:36 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-22 09:25:36 +0900 - - merge revision(s) c7ce2f537f96ab2cf2f5fc2982d6147866ff5340: [Backport #20304] (#10311) - - Fix memory leak in setting encodings - - There is a memory leak in Encoding.default_external= and - Encoding.default_internal= because the duplicated name is not freed - when overwriting. - - 10.times do - 1_000_000.times do - Encoding.default_internal = nil - end - - puts `ps -o rss= -p #{$$}` - end - - Before: - - 25664 - 41504 - 57360 - 73232 - 89168 - 105056 - 120944 - 136816 - 152720 - 168576 - - After: - - 9648 - 9648 - 9648 - 9680 - 9680 - 9680 - 9680 - 9680 - 9680 - 9680 - -commit eb7cb164cffc86b63d2e2528c73e160c33b7a2e5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-03-21 16:12:38 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-21 16:12:38 +0900 - - CVE-2024-27281 for Ruby 3.3 (#10316) - - Merge RDoc-6.6.3.1 - -commit f79b1d1ef1f7aa64d20f0eadbb3b0f8f7084deb3 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-21 14:31:36 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-21 14:31:36 +0900 - - merge revision(s) e626da82eae3d437b84d4f9ead0164d436b08e1a,f3af5ae7e6c1c096bbfe46d69de825a02b1696cf: [Backport #20311] (#10312) - - Don't pin named structs defined in Ruby - - [Bug #20311] - - `rb_define_class_under` assumes it's called from C and that the - reference might be held in a C global variable, so it adds the - class to the VM root. - - In the case of `Struct.new('Name')` it's wasteful and make - the struct immortal. - - Make Struct memory leak test faster - - [Bug #20311] - - It times out on some platform, so we can reduce iterations. - On my machine it completes in 250ms and RSS grows 8X. - -commit 57a0afe2090b8d05673d650b1e8bf9ae67449b1f - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-21 11:23:21 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-21 11:23:21 +0900 - - merge revision(s) 081ee3d35509110f383cb7dd8d1205def0cdd1e8,1c97abaabae6844c861705fd07f532292dcffa74: [Backport #19907] (#10315) - - Add memory leak test for eval kwargs - - De-dup identical callinfo objects - - Previously every call to vm_ci_new (when the CI was not packable) would - result in a different callinfo being returned this meant that every - kwarg callsite had its own CI. - - When calling, different CIs result in different CCs. These CIs and CCs - both end up persisted on the T_CLASS inside cc_tbl. So in an eval loop - this resulted in a memory leak of both types of object. This also likely - resulted in extra memory used, and extra time searching, in non-eval - cases. - - For simplicity in this commit I always allocate a CI object inside - rb_vm_ci_lookup, but ideally we would lazily allocate it only when - needed. I hope to do that as a follow up in the future. - -commit 821719a505bbc628ddd80b90ae892666006eada1 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-21 11:18:06 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-21 11:18:06 +0900 - - merge revision(s) d3279a0c11ca45ca85027e7eb74dc4aac52c478b: [Backport #20327] (#10313) - - [Bug #20327] Do not count subsecond to calculate UTC offset - - Assume that there will never be any time zones with UTC offsets that - are subseconds. Historically, UTC offset has only been used down to - the second. - -commit a63e979853783601a60228b45741f8b3776e5507 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-21 10:45:01 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-21 10:45:01 +0900 - - merge revision(s) d19d683a354530a27b4cbb049223f8dc70c75849,de1a586ecc2ee7f465f0c0a69291054136a3a819: [Backport #20250] (#10308) - - rb_obj_setup: do not copy RUBY_FL_SEEN_OBJ_ID - - [Bug #20250] - - We're seting up a new instance, so it never had an associated - object_id. - - proc.c: get rid of `CLONESETUP` - MIME-Version: 1.0 - Content-Type: text/plain; charset=UTF-8 - Content-Transfer-Encoding: 8bit - - [Bug #20253] - - All the way down to Ruby 1.9, `Proc`, `Method`, `UnboundMethod` - and `Binding` always had their own specific clone and dup routine. - - This caused various discrepancies with how other objects behave - on `dup` and `clone. [Bug #20250], [Bug #20253]. - - This commit get rid of `CLONESETUP` and use the the same codepath - as all other types, so ensure consistency. - - NB: It's still not accepting the `freeze` keyword argument on `clone`. - - Co-Authored-By: Étienne Barrié <etienne.barrie@gmail.com> - -commit a406c516685f1950269c4e43d13cc748f0bfbc06 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-21 10:28:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-21 10:28:51 +0900 - - merge revision(s) ae8990aef098410ecc2b5f48fea9d7d171a3c5f6: [Backport #20183] (#10310) - - Alias init functions - - The extension library has each initialization function named "Init_" + - basename. If multiple extensions have the same base name (such as - cgi/escape and erb/escape), the same function will be registered for - both names. - - To fix this conflict, rename the initialization functions under sub - directories using using parent names, when statically linking. - -commit 05787897f69087abdabee926971cdf364bd73730 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-21 09:10:44 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-21 09:10:44 +0900 - - merge revision(s) 18ee7c9a108bf3424814565377c8796e5e455cf7,4a6384ed9358e8fb8464f6e37efb5477182f01db: [Backport #20246] (#10309) - - Clear all refined CCs on reopening refinement mod - - In cfd7729ce7a31c8b6ec5dd0e99c67b2932de4732 we started using inline - caches for refinements. However, we weren't clearing inline caches when - defined on a reopened refinement module. - - Fixes [Bug #20246] - - Fix [Bug #20246]: Don't set next_head_exact if a capture is called (#9897) - -commit b2c2702f20abfd4bb5f38cad60170e2bbb3adff9 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-21 09:05:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-21 09:05:07 +0900 - - merge revision(s) 01fd262e62076277a41af72ea13f20deb1b462a2: [Backport #20245] (#10307) - - Fix crash when checking symbol encoding - - [Bug #20245] - - We sometimes pass in a fake string to sym_check_asciionly. This can crash - if sym_check_asciionly raises because it creates a CFP with the fake - string as the receiver which will crash if GC tries to mark the CFP. - - For example, the following script crashes: - - GC.stress = true - Object.const_defined?("\xC3") - -commit 00cb72157a60c20a9b9d9fe81fc974ea83d672b4 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-21 02:13:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-21 02:13:59 +0900 - - merge revision(s) 3e6e3ca2627b1aa71b17de902cc1b8188246a828: [Backport #20207] (#10299) - - Correctly handle consecutive lookarounds (#9738) - - Fix [Bug #20207] - Fix [Bug #20212] - - Handling consecutive lookarounds in init_cache_opcodes is buggy, so it - causes invalid memory access reported in [Bug #20207] and [Bug #20212]. - This fixes it by using recursive functions to detected lookarounds - nesting correctly. - -commit c626c201e4129bbea17583ecef73472c6f668c81 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-20 22:40:50 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-20 22:40:50 +0900 - - merge revision(s) 01bfd1a2bf013a9ed92a9722ac5228187e05e6a8,1c120efe02d079b0a1dea573cf0fd7978d9cc857,31378dc0969f4466b2122d730b7298dd7004acdf: [Backport #20228] (#10301) - - Fix memory leak in OnigRegion when match raises - - [Bug #20228] - - rb_reg_onig_match can raise a Regexp::TimeoutError, which would cause - the OnigRegion to leak. - - Fix memory leak in stk_base when Regexp timeout - - [Bug #20228] - - If rb_reg_check_timeout raises a Regexp::TimeoutError, then the stk_base - will leak. - - Add memory leak test for Regexp timeout - - [Bug #20228] - -commit ce372be903e5f3597f1dc83cb558f165850b3bee - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-20 22:40:46 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-20 22:40:46 +0900 - - merge revision(s) ade56737e2273847426214035c0ff2340b43799a: [Backport #20190] (#10300) - - Fix coderange of invalid_encoding_string.<<(ord) - - Appending valid encoding character can change coderange from invalid to valid. - Example: "\x95".force_encoding('sjis')<<0x5C will be a valid string "\x{955C}" - -commit 69cee6fee50f63cd52d59325dc3780a6fc4e5ae2 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-20 20:05:31 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-20 20:05:31 +0900 - - merge revision(s) 771a2f039b9a059a73e8f111d1d46590fa697f63: [Backport #20213] (#10297) - - Fix incorrect use of VM_CALL_KW_SPLAT_MUT in zsuper with keyword splat - - For zsuper calls with a keyword splat but no actual keywords, the - keyword splat is passed directly, so it cannot be mutable, because - if the callee accepts a keyword splat, changes to the keyword splat - by the callee would be reflected in the caller. - - While here, simplify the logic when the method supports - literal keywords. I don't think it is possible for - a method with has_kw param flags to not have keywords, so add an - assertion for that, and set VM_CALL_KW_SPLAT_MUT in a single place. - -commit 0793cbbfde261f4fc9bf7045594d62a21e391811 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-20 20:05:21 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-20 20:05:21 +0900 - - merge revision(s) ef276858d9295208add48e27208c69184dc50472: [Backport #20197] (#10296) - - Trigger postponed jobs on running_ec if that is available - - Currently, any postponed job triggered from a non-ruby thread gets sent - to the main thread, but if the main thread is sleeping it won't be - checking ints. Instead, we should try and interrupt running_ec if that's - possible, and only fall back to the main thread if it's not. - - [Bug #20197] - --- - ractor.c | 16 ++++++++++++++++ - 1 file changed, 16 insertions(+) - -commit 23bfe6218a690bbde5143e26bc6fb243347fb4b3 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-20 20:05:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-20 20:05:08 +0900 - - merge revision(s) b14674b236445fb70f484603e678722760f678f4: [Backport #20194] (#10295) - - Memory leak with TracePoint on bmethod - - [Bug #20194] - - When disabling the TracePoint on bmethod, the hooks list is not freed. - - For example: - - obj = Object.new - obj.define_singleton_method(:foo) {} - bmethod = obj.method(:foo) - tp = TracePoint.new(:return) {} - - 10.times do - 100_000.times do - tp.enable(target: bmethod) {} - end - - puts `ps -o rss= -p #{$$}` - end - - Before: - - 18208 - 22832 - 26528 - 29728 - 34000 - 37776 - 40864 - 44400 - 47680 - 51504 - - After: - - 16688 - 17168 - 17168 - 17248 - 17696 - 17760 - 17824 - 17824 - 17856 - 17920 - --- - test/ruby/test_settracefunc.rb | 13 +++++++++++++ - vm_trace.c | 1 + - 2 files changed, 14 insertions(+) - -commit 7ae8abc23961bf4fa143a7a2cc0bc38167d468ae - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-20 20:00:47 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-20 20:00:47 +0900 - - merge revision(s) bb59696614083660241ef272f222628cbfa95844: [Backport #20098] (#10298) - - Fix [Bug #20098]: set counter value for {n,m} repetition correctly (#9391) - -commit bd42c1725a3bba0f97831aa3dbaa6924f506a5f3 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2024-03-15 01:27:35 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-15 01:27:35 +0900 - - Backport #20096 to Ruby 3.3 (#9471) - - Fix memory overread in registry.rb - - The terminator is not actually getting filled in; we're simply passing - (two) bytes of empty memory as the NUL terminator. This can lead to - garbage characters getting written to registry values. - - Fix this by explicitly putting a WCHAR_NUL character into the string to - be sent to the registry API, like we do in the MULTI_SZ case. - - [Bug #20096] - -commit 606dd03e9b0d4cf65ef56e52fab063e3ed5ef797 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2024-03-15 01:27:05 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-15 01:27:05 +0900 - - [Bug #20208] Revert "Set AI_ADDRCONFIG when making getaddrinfo(3) calls for outgoi… (#9791) - - Revert "Set AI_ADDRCONFIG when making getaddrinfo(3) calls for outgoing conns" - - This reverts commit 673ed41c81cf5a6951bcb2c3dec82d7bd6ea7440. - -commit 53f0c5a4e8834f11af0f903d2c59754d9be2a7f2 - Author: Kerem Kat <keremkat@gmail.com> - AuthorDate: 2024-03-15 01:26:35 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-15 01:26:35 +0900 - - Backport #9498 to Ruby 3.3 (#9805) - - Handle mmap failures for redblack tree cache - - The redblack tree cache is totally optional, so if we can't allocate - room for the cache, then just pretend as if the cache is full if mmap - fails - - Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org> - -commit cdcabd8a44ee2f4a2b549a3460a5c77c2dffca36 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2024-03-15 01:26:02 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-15 01:26:02 +0900 - - Backport 3.3: YJIT memory leak fix with additional CI fixes (#9841) - - merge revision(s) 2cc7a56e,b0711b1,db5d9429: [Backport #20209] - - YJIT: Avoid leaks by skipping objects with a singleton class - - For receiver with a singleton class, there are multiple vectors YJIT can - end up retaining the object. There is a path in jit_guard_known_klass() - that bakes the receiver into the code, and the object could also be kept - alive indirectly through a path starting at the CME object baked into - the code. - - To avoid these leaks, avoid compiling calls on objects with a singleton - class. - - See: https://github.com/Shopify/ruby/issues/552 - - [Bug #20209] - --- - yjit/bindgen/src/main.rs | 1 + - yjit/src/codegen.rs | 17 +++++++++++++++++ - yjit/src/cruby_bindings.inc.rs | 1 + - yjit/src/stats.rs | 2 ++ - 4 files changed, 21 insertions(+) - - YJIT: Fix tailcall and JIT entry eating up FINISH frames (#9729) - - Suppose YJIT runs a rb_vm_opt_send_without_block() - fallback and the control frame stack looks like: - - ``` - will_tailcall_bar [FINISH] - caller_that_used_fallback - ``` - - will_tailcall_bar() runs in the interpreter and sets up a tailcall. - Right before JIT_EXEC() in the `send` instruction, the stack will look like: - - ``` - bar [FINISH] - caller_that_used_fallback - ``` - - Previously, JIT_EXEC() ran bar() in JIT code, which caused the `FINISH` - flag to return to the interpreter instead of to the JIT code running - caller_that_used_fallback(), causing code to run twice and probably - crash. Recent flaky failures on CI about "each stub expects a particular - iseq" are probably due to leaving methods twice in - `test_optimizations.rb`. - - Only run JIT code from the interpreter if a new frame is pushed. - --- - test/ruby/test_optimization.rb | 11 +++++++++++ - vm_exec.h | 3 ++- - 2 files changed, 13 insertions(+), 1 deletion(-) - - YJIT: No need to RESTORE_REG now that we reject tailcalls - - Thanks to Kokubun for noticing. - - Follow-up: b0711b1cf152afad0a480ee2f9bedd142a0d24ac - --- - vm_exec.h | 1 - - 1 file changed, 1 deletion(-) - -commit fafe5db7328eb3395ac4559992701b5f25ab49f4 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-14 23:18:15 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-14 23:18:15 +0900 - - merge revision(s) b3d612804946e841e47d14e09b6839224a79c1a4: [Backport #20150] (#10253) - - Fix memory leak in grapheme clusters - - [Bug #20150] - - String#grapheme_cluters and String#each_grapheme_cluster leaks memory - because if the string is not UTF-8, then the created regex will not - be freed. - - For example: - - str = "hello world".encode(Encoding::UTF_32LE) - - 10.times do - 1_000.times do - str.grapheme_clusters - end - - puts `ps -o rss= -p #{$$}` - end - - Before: - - 26000 - 42256 - 59008 - 75792 - 92528 - 109232 - 125936 - 142672 - 159392 - 176160 - - After: - - 9264 - 9504 - 9808 - 10000 - 10128 - 10224 - 10352 - 10544 - 10704 - 10896 - --- - string.c | 98 +++++++++++++++++++++++++++++++----------------- - test/ruby/test_string.rb | 11 ++++++ - 2 files changed, 75 insertions(+), 34 deletions(-) - -commit 2a84aaf4a8c8d6d6bbb09416711922532b0033fe - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-14 18:55:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-14 18:55:52 +0900 - - Fix test session reuse but expire (#9824) (#10250) - - merge revision(s) 596db9c1f486d6609a4e97d82c8c71b54609fb6f: [Backport #20090] - - [Feature #19370] Blocks without anonymous parameters should not - affect - - --- - parse.y | 4 ++-- - test/ruby/test_syntax.rb | 7 +++++++ - 2 files changed, 9 insertions(+), 2 deletions(-) - -commit a889304fed63c3206f27d614ab75219271fb4ca9 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-14 18:42:28 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-14 18:42:28 +0900 - - merge revision(s) 6c0e58a54e3fda604386d9c409e2a9998bbc9352: [Backport #20198] (#10252) - - Make sure the correct error is raised for EAI_SYSTEM resolver fail - - In case of EAI_SYSTEM, getaddrinfo is supposed to set more detail in - errno; however, because we call getaddrinfo on a thread now, and errno - is threadlocal, that information is being lost. Instead, we just raise - whatever errno happens to be on the calling thread (which can be - something very confusing, like `ECHILD`). - - Fix it by explicitly propagating errno back to the calling thread - through the getaddrinfo_arg structure. - - [Bug #20198] - --- - ext/socket/raddrinfo.c | 25 +++++++++++++++++++------ - 1 file changed, 19 insertions(+), 6 deletions(-) - -commit 72d04bb073e6897fb4228d5b0b31ad02cbb91036 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-26 15:05:20 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-03-14 18:38:42 +0900 - - Disable to run appveyor anymore - - [Feature #19982] - -commit 8c4b5ac53b42b5bbbb279d17128b64ae685e7274 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-25 22:12:19 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-03-14 18:38:42 +0900 - - Skip AppVeyor and GitHub if only other CI files are changed - -commit 577f9c7a8334bb33512f01e7db95f6fb15e280b2 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-03-14 16:53:14 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-03-14 16:53:14 +0900 - - Backport 37ed86fd3c798e298fad9db6e7df1f3f45e1e03b (#10248) - - merge revision(s) 37ed86fd3c798e298fad9db6e7df1f3f45e1e03b: [Backport #--ticket=20161] - - Fix memory leak in regexp grapheme clusters - - [Bug #20161] - - The cc->mbuf gets overwritten, so we need to free it to not leak memory. - - For example: - - str = "hello world".encode(Encoding::UTF_32LE) - - 10.times do - 1_000.times do - str.grapheme_clusters - end - - puts `ps -o rss= -p #{$$}` - end - - Before: - - 15536 - 15760 - 15920 - 16144 - 16304 - 16480 - 16640 - 16784 - 17008 - 17280 - - After: - - 15584 - 15584 - 15760 - 15824 - 15888 - 15888 - 15888 - 15888 - 16048 - 16112 - --- - regparse.c | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -commit ade02f3c8909a8bf630af2c88f00b7bd7ff02682 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2024-03-04 11:57:04 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-03-04 11:57:04 +0900 - - merge revision(s) 051a874325c177e040301878069c2b28f5d06ce6: [Backport #20096] - - Fix memory overread in registry.rb - - The terminator is not actually getting filled in; we're simply passing - (two) bytes of empty memory as the NUL terminator. This can lead to - garbage characters getting written to registry values. - - Fix this by explicitly putting a WCHAR_NUL character into the string to - be sent to the registry API, like we do in the MULTI_SZ case. - - [Bug #20096] - --- - ext/win32/lib/win32/registry.rb | 7 ++----- - 1 file changed, 2 insertions(+), 5 deletions(-) - -commit 3f0e3ede02f7d4b31c9073c9eb912f11aa4349cd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-02-05 23:51:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-05 23:51:16 +0900 - - YJIT: Fix exits on splatkw instruction (#9715) - - [[Bug #20214]](https://bugs.ruby-lang.org/issues/20214) - -commit ac526abcd6d82545b8dc3586efb55d75f45f7417 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-02-05 23:51:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-05 23:51:04 +0900 - - Merge RubyGems 3.5.5 and Bundler 2.5.5 (#9676) - - * Merge RubyGems-3.5.4 and Bundler-2.5.4 - - * Merge RubyGems-3.5.5 and Bundler-2.5.5 - - * Make tests play with upstream Ruby tests - - CI broke in https://github.com/ruby/ruby/pull/9604 because if any Ruby - tests run `require 'net/http'`, they will pollute the - `$LOADED_FEATURES` for the RubyGems tests. We can fix this by renaming - the test default gem from `net-http` to `my-http`. - - See https://github.com/rubygems/rubygems/pull/7379#issuecomment-1901241299 - for more details. - - --------- - - Co-authored-by: Stan Hu <stanhu@gmail.com> - -commit 7f97e3540ce448b501bcbee15afac5f94bb22dd9 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2024-02-05 23:50:20 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-05 23:50:20 +0900 - - [Backport 3.3] [Bug #20085] Use consistent default options for `-mbranch-protection` (#9385) - - [Bug #20085] Use consistent default options for `-mbranch-protection` - - We need to use the same options for both C compiler and assembler - when `-mbranch-protection` is guessed by configure. Otherwise, - `coroutine/arm64/Context.{h,S}` will use incompatible PAC strategies. - -commit 288d84d827da6cb8a56ed614a9839a06488986c0 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-02-05 17:41:56 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-05 17:41:56 +0900 - - merge revision(s) 2554c5d3b8738a248cedb2fea96dfab9fbe19417: [Backport #20231] (#9831) - - Don't wait in `io_binwrite_string` if not necessary. (#9792) - - --- - io.c | 8 +++----- - 1 file changed, 3 insertions(+), 5 deletions(-) - -commit d7dc57a545d75c01313a9020b162ebb648a3ea18 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-02-04 22:54:36 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-04 22:54:36 +0900 - - merge revision(s) c5cf4d4e129f64cb69aaf0a829aed068ef1943c4: [Backport#19542] (#9829) - - merge revision(s) c5cf4d4e129f64cb69aaf0a829aed068ef1943c4: [Backport #19542] - - Improve behavioural consistency of unallocated (zero length) - `IO::Buffer`. (#9532) - - This makes the behaviour of IO::Buffer.new(0) and IO::Buffer.new.slice(0, 0) consistent. - - Fixes https://bugs.ruby-lang.org/issues/19542 and https://bugs.ruby-lang.org/issues/18805. - --- - io_buffer.c | 14 ++++++-------- - test/ruby/test_io_buffer.rb | 35 +++++++++++++++++++++++++++++++++++ - 2 files changed, 41 insertions(+), 8 deletions(-) - -commit a065b68bd8d93505304f90bbb1855c864e17ad61 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2024-02-04 14:37:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-04 14:37:33 +0900 - - Backport #9415 to ruby_3_3 (#9424) - - YJIT: Let RubyVM::YJIT.enable respect --yjit-stats - -commit ba16b340981942eda82d6328800b8098c452c0ca - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2024-02-04 14:36:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-04 14:36:34 +0900 - - YJIT: reduce default exec mem size to 48MiB (#9692) - - * YJIT: reduce default exec mem size to 48MiB based - - Based on user feedback from @jhawthorn and others. - Better for small and memory-constrained deployments. - - NOTE: This commit should be included in the next Ruby 3.3.x point - release. @xrxr should we tag someone specific? - - * YJIT: Update yjit.md about mem size (#9687) - - --------- - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - -commit ce6863a0cf971e0c0328e3fc85b10b6de36ecbad - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-02-04 13:13:15 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-04 13:13:15 +0900 - - merge revision(s) 18573b8d054f655e3e8b24902985bf4028f88810: [Backport #20178] (#9822) - - Avoid reading unused lvars in Primitive.cexpr - - Previously on builds with optimizations disabled, this could result in - an out of bounds read. When we had all of: - * built with -O0 - * Leaf builtin - * Primitive.mandatory_only - * "no args builtin", called by vm_call_single_noarg_inline_builti - * The stack is escaped to the heap via binding or a proc - - This is because mk_builtin_loader generated reads for all locals - regardless of whether they were used and in the case we generated a - mandatory_only iseq that would include more variables than were actually - available. - - On optimized builds, the invalid accesses would be optimized away, and - this also was often unnoticed as the invalid access would just hit - another part of the stack unless it had been escaped to the heap. - - The fix here is imperfect, as this could have false positives, but since - Primitive.cexpr! is only available within the cruby codebase itself - that's probably fine as a proper fix would be much more challenging (the - only false positives we found were in rjit.rb). - - Fixes [Bug #20178] - - Co-authored-by: Adam Hess <HParker@github.com> - --- - bootstraptest/test_method.rb | 9 +++++++++ - tool/mk_builtin_loader.rb | 6 ++++++ - 2 files changed, 15 insertions(+) - -commit 53d4e9c4bbba077a569549a01a8263e5e8f59ee8 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-02-04 00:47:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-04 00:47:32 +0900 - - merge revision(s) 1bd98c820da46a05328d2d53b8f748f28e7ee8f7: [Backport #20172] (#9798) - - Remove setaffinity of pthread for getaddrinfo - - It looks like `sched_getcpu(3)` returns a strange number on some - (virtual?) environments. - - I decided to remove the setaffinity mechanism because the performance - does not appear to degrade on a quick benchmark even if removed. - - [Bug #20172] - --- - ext/socket/extconf.rb | 2 -- - ext/socket/raddrinfo.c | 48 ++++-------------------------------------------- - 2 files changed, 4 insertions(+), 46 deletions(-) - -commit 45064610725ddd81a5ea3775da35aa46985bc789 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-02-03 22:35:44 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-03 22:35:44 +0900 - - Fix test session reuse but expire (#9824) - - * Show OpenSSL version in the error message of assert_equal - - * OpenSSL 3.2.1 30 Jan 2024 is also broken - -commit 3fb51b93d25b0566b71249b1c7ccddf0dab91429 - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-02-01 16:19:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-01 16:19:48 +0900 - - merge revision(s) 82b57d7bfeefd717c10f7a5a3484aca6b3e708a3: [Backport… (#9795) - - merge revision(s) 82b57d7bfeefd717c10f7a5a3484aca6b3e708a3: [Backport #20162] - - Fix memory leak when duplicating too complex object - - [Bug #20162] - - Creating a ST table then calling st_replace leaks memory because the - st_replace overwrites the ST table without freeing any of the existing - memory. This commit changes it to use st_copy instead. - - For example: - - RubyVM::Shape.exhaust_shapes - - o = Object.new - o.instance_variable_set(:@a, 0) - - 10.times do - 100_000.times { o.dup } - - puts `ps -o rss= -p #{$$}` - end - - Before: - - 23264 - 33600 - 42672 - 52160 - 61600 - 71728 - 81056 - 90528 - 100560 - 109840 - - After: - - 14752 - 14816 - 15584 - 15584 - 15664 - 15664 - 15664 - 15664 - 15664 - 15664 - --- - object.c | 3 +-- - test/ruby/test_shapes.rb | 13 +++++++++++++ - 2 files changed, 14 insertions(+), 2 deletions(-) - -commit 7231fc5baa0a44ef6264c795071c5fbec8d1102d - Author: NARUSE, Yui <nurse@users.noreply.github.com> - AuthorDate: 2024-02-01 16:13:50 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-01 16:13:50 +0900 - - merge revision(s) 597955a,8b65d15: [Backport #20173] (#9794) - - Fix to work match cache with peek next optimization (#9459) - - --- - regexec.c | 3 ++- - test/ruby/test_regexp.rb | 9 +++++++++ - 2 files changed, 11 insertions(+), 1 deletion(-) - - Fix test case for `test_match_cache_with_peek_optimization` (#9466) - - --- - test/ruby/test_regexp.rb | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -commit 57d8d6e58a13c9de7bb84c1c76625789f435bca1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-02-01 13:34:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-01 13:34:32 +0900 - - Backport bundled_gems.rb for Ruby 3.3 (#9457) - - racc is extracted at Ruby 3.3, not 3.4 - -commit 920c17dc94239baae05b513046b27967f11a3569 - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2024-02-01 13:33:30 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-02-01 13:33:30 +0900 - - Backport #20157 to Ruby 3.3 (#9428) - - * Fix GC.measure_total_time regression - - Commit 93ac7405b80cc61930d73da04441fa09af1851e1 introduced a regression - where measurements would still be taken after setting - GC.measure_total_time = false. - - Fixes [Bug #20157] - - * Add test case for GC.measure_total_time - - --------- - - Co-authored-by: Rian McGuire <rian@rian.id.au> - -commit 2886564279dff87a6c293f6e80436eb2b309967e - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2024-02-01 10:39:54 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-02-01 10:39:54 +0900 - - merge revision(s) 6aacbd690ccde53f9b97c6673482cb11df3f2955: [Backport #20149] - - Free pthread_attr after setting up the thread - - [bug #20149] - --- - ext/socket/raddrinfo.c | 12 +++++++++++- - 1 file changed, 11 insertions(+), 1 deletion(-) - -commit aeffb5e21de6000a3dcfa0ca88c6ba3c3c42d8db - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2024-02-01 09:08:06 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-02-01 09:08:06 +0900 - - merge revision(s) 6c252912af4981f016a9abdb4c1689307a4f1d2f: [Backport #20145] - - Memory leak when duplicating identhash - - [Bug #20145] - - Before this commit, both copy_compare_by_id and hash_copy will create a - copy of the ST table, so the ST table created in copy_compare_by_id will - be leaked. - - h = { 1 => 2 }.compare_by_identity - - 10.times do - 1_000_000.times do - h.select { false } - end - - puts `ps -o rss= -p #{$$}` - end - - Before: - - 110736 - 204352 - 300272 - 395520 - 460704 - 476736 - 542000 - 604704 - 682624 - 770528 - - After: - - 15504 - 16048 - 16144 - 16256 - 16320 - 16320 - 16752 - 16752 - 16752 - 16752 - --- - hash.c | 10 +++++++++- - test/ruby/test_hash.rb | 10 ++++++++++ - 2 files changed, 19 insertions(+), 1 deletion(-) - -commit f585171a6b1d6c20b3c162fd59dc874510ed2a49 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2024-01-30 20:29:02 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-01-30 20:29:02 +0900 - - merge revision(s) e12d4c654e3cb7a4473014610bc3bae41aaf811e: [Backport #20104] - - Don't create T_MATCH object if /regexp/.match(string) doesn't match - - Fixes [Bug #20104] - --- - re.c | 9 ++++++--- - test/ruby/test_regexp.rb | 12 ++++++++++++ - tool/lib/envutil.rb | 8 ++++++++ - 3 files changed, 26 insertions(+), 3 deletions(-) - -commit f8f0d342e48a38caac6d32b438c145bb581a51e6 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2024-01-30 18:57:00 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-01-30 18:57:00 +0900 - - merge revision(s) 3d19409637de1462b6790d2a92344bf0a10d8c52: [Backport #20090] - - Use index for referring to symbols in `args` rule instead of named - references - - In `args: args ',' arg_splat`, `args` is not unique name. - Currently the associated rule is interpreted as - `$$ = rest_arg_append(p, $$, $3, &@$);`. - The action works as expected because `$$` is initialized with - `$1` before each action is executed. - However it's misleading then change to use index. - --- - parse.y | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -commit 9f18cbd7964f32f224e7d0efba79ee0476a442e0 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2024-01-30 18:00:47 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-01-30 18:00:47 +0900 - - Revert "merge revision(s) bc002971b6ad483dbf69b8a275c44412bb6ab954: [Backport #20094]" - - This reverts commit d4b780e84e9a6b858d0f6c6a44b22da0d2f5835e. - -commit d4b780e84e9a6b858d0f6c6a44b22da0d2f5835e - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2024-01-30 17:41:31 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-01-30 17:41:31 +0900 - - merge revision(s) bc002971b6ad483dbf69b8a275c44412bb6ab954: [Backport #20094] - - [Bug #20094] Distinguish `begin` and parentheses - - --- - compile.c | 1 + - parse.y | 36 +++++++++++++++++++++--------------- - test/ruby/test_whileuntil.rb | 18 ++++++++++++++++++ - 3 files changed, 40 insertions(+), 15 deletions(-) - -commit 5f3dfa1c273c6fb9eae65ceca633b46f7e30f686 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2024-01-30 10:31:15 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-01-30 10:31:15 +0900 - - merge revision(s) d8702ddbfbe8cc7fc601a9a4d19842ef9c2b76c1: [Backport #20083] - - Fix [Bug #20083]: correct a cache point size for atomic groups - (#9367) - - --- - regexec.c | 2 +- - test/ruby/test_regexp.rb | 8 ++++++++ - 2 files changed, 9 insertions(+), 1 deletion(-) - -commit 818b4ea9b16e3570b431b86da9a24a5743b29617 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2024-01-30 10:24:31 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2024-01-30 10:24:31 +0900 - - merge revision(s) e5a4f757bdf5dc3d8c329ddd268432f9ecc7bff6: [Backport #20086] - - Fix Window private file mapping unlink EACCES issue. (#9358) - - * Don't return early. - - * Add missing `mapping` assignment. - - * Make debug logs conditional. - --- - io_buffer.c | 18 ++++++++++++------ - test/ruby/test_io_buffer.rb | 32 ++++++++++++++------------------ - 2 files changed, 26 insertions(+), 24 deletions(-) - -commit 634d4e29ef43e2fd113b361c069ffa8984e82362 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2024-01-05 22:54:57 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2024-01-05 22:54:57 +0900 - - Update net-* gems for Ruby 3.3 (#9418) - - * Bump up net-ftp to 0.3.4 - - * Bump up net-smtp to 0.4.0.1 - - * Bump up net-imap to 0.4.9.1 - - * [ruby/net-http] Renew test certificates - - The private key is replaced with a public known test key published at - [RFC 9500]. - - Also lifetime has been extended to 10 years from 4 years. - - [RFC 9500]: https://www.rfc-editor.org/rfc/rfc9500.html - - https://github.com/ruby/net-http/commit/4ab6c4a500 - - * Bump up net-http to 0.4.1 - - --------- - - Co-authored-by: Sorah Fukumori <her@sorah.jp> - -commit 5124f9ac7513eb590c37717337c430cb93caa151 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2023-12-25 14:59:38 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2023-12-25 14:59:38 +0900 - - v3.3.0 - -commit a44a59dbaf1b5c930c9f476077b0be9b1653ad9c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-25 14:52:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-25 14:52:06 +0900 - - [DOC] Add NEWS for [Feature #19370] - -commit a9f096183170810ac6ce32b20d7810d11a51b5f5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-23 18:07:37 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-25 14:44:04 +0900 - - [Feature #19370] Prohibit nesting anonymous parameter forwarding - -commit b641b7e640b90292e8091348ca05def0a16904a8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-25 14:08:21 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-25 14:11:49 +0900 - - Move non-portable pragmas to rubyspec.h - - In the extension libraries in spec/ruby/optional/capi, do not care - about deprecated declarations. - -commit 863ded45a18773742cf3adab0f6deb4ba6b47c6e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-25 13:48:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-25 13:50:23 +0900 - - Typofix under bootstraptest, spec and yjit directories - -commit 2cdbeb29e6e06d3492e2d4a388558ab883b07150 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-25 11:13:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-25 13:01:55 +0900 - - Do not leave test file - - Run this test separately because something seems remained unreleased - on Windows. - -commit b4efa4b7005efee484e61fbc6af9c652fee36db2 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-25 11:26:37 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-25 12:13:49 +0900 - - Don't copy RUBY_FL_PROMOTED flag in rb_obj_setup - - RUBY_FL_PROMOTED is used by the garbage collector to track when an - object becomes promoted to the old generation. rb_obj_setup must not - copy that flag over because then it may become out-of-sync with the age - of the object. - - This fixes a bug in Method#clone where the cloned Method object may get - RUBY_FL_PROMOTED incorrectly set. - -commit 1b5f3dd6a1a5d054e3fd5af10b5dc2f49e1046fc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-25 12:04:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-25 12:04:28 +0900 - - Removed empty sections - -commit 27ead9907db12a6ff955cd86a15a62ff1f064392 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-25 11:32:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-25 11:32:42 +0900 - - Typofix under lib and test, tool directories - -commit 7002e776944ddfd362cea253d18d02bc250fe9f7 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-25 09:22:13 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-25 11:29:40 +0900 - - Fix Symbol#inspect for GC compaction - - The test fails when RGENGC_CHECK_MODE is turned on: - - 1) Failure: - TestSymbol#test_inspect_under_gc_compact_stress [test/ruby/test_symbol.rb:123]: - <":testing"> expected but was - <":\x00\x00\x00\x00\x00\x00\x00">. - -commit e233730846fd2634208c3c568c49b76bf3b29a0b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-25 11:22:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-25 11:22:12 +0900 - - Partly reverted c903cddf55af1505a0779e1a131f2fe47b838260 - - These are intentional words - -commit c903cddf55af1505a0779e1a131f2fe47b838260 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-25 11:17:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-25 11:17:51 +0900 - - Typofix under doc directory - -commit 70618a48f7f9f12943e963bf121b56af4153f394 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-25 06:23:10 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-25 10:37:59 +0900 - - Fix off-by-one error for declarative marking - - The for loops for marking and reference updating declaratively marked - TypedData objects did not mark/reference update the very last element. - - When RGENGC_CHECK_MODE is turned on, this caused the test in Enumerator - to fail with: - - tool/lib/test/unit/testcase.rb:173:in `rescue in run': failed to allocate memory (NoMemoryError) - -commit 260bf60e52ffdfa625be1153624b0d123fc305f8 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-12-25 10:20:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-25 10:20:53 +0900 - - Correctly release the underlying file mapping. (#9340) - - * Avoiding using `Tempfile` which was retaining the file preventing it from unlinking. - -commit 5af64ff7db3d636201db68b9ba995131a04a8f7b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-25 02:10:10 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-25 06:22:34 +0900 - - Fix Enumerator#with_index for GC compaction - - enumerator_block_call was not safe for compaction because the Array - backing the argv was not pinned, so it could get moved during compaction - which would make argv point to somewhere else. - - The test crashes when RGENGC_CHECK_MODE is turned on: - - TestEnumerator#test_with_index_under_gc_compact_stress - check_rvalue_consistency: 0x55db0b399450 is not a Ruby object. - test/ruby/test_enumerator.rb:133: [BUG] check_rvalue_consistency_force: there is 1 errors. - ruby 3.3.0dev (2023-12-23T23:00:27Z master 50bf437341) [x86_64-linux] - -- Control frame information ----------------------------------------------- - c:0034 p:---- s:0192 e:000187 CFUNC :with_index - c:0033 p:---- s:0185 e:000184 CFUNC :each - c:0032 p:---- s:0182 e:000181 CFUNC :to_a - c:0031 p:0055 s:0178 e:000175 BLOCK test/ruby/test_enumerator.rb:133 - c:0030 p:0024 s:0172 e:000171 METHOD tool/lib/envutil.rb:242 - c:0029 p:0024 s:0167 e:000166 METHOD tool/lib/envutil.rb:251 - c:0028 p:0005 s:0160 e:000159 METHOD test/ruby/test_enumerator.rb:131 - ... - -- C level backtrace information ------------------------------------------- - build/ruby(rb_print_backtrace+0x14) [0x55db0b1deb21] vm_dump.c:820 - build/ruby(rb_vm_bugreport) vm_dump.c:1151 - build/ruby(bug_report_end+0x0) [0x55db0b3a53a6] error.c:1042 - build/ruby(rb_bug_without_die) error.c:1042 - build/ruby(die+0x0) [0x55db0afc77c2] error.c:1050 - build/ruby(rb_bug) error.c:1052 - build/ruby(gc_move+0x0) [0x55db0afbada0] gc.c:1714 - build/ruby(check_rvalue_consistency+0xa) [0x55db0afef0c3] gc.c:1729 - build/ruby(is_markable_object) gc.c:4769 - build/ruby(gc_mark_stack_values) gc.c:6595 - build/ruby(rb_gc_mark_vm_stack_values) gc.c:6605 - build/ruby(rb_execution_context_mark+0x39) [0x55db0b1d8589] vm.c:3309 - build/ruby(thread_mark+0x15) [0x55db0b1a9805] vm.c:3381 - build/ruby(gc_mark_stacked_objects+0x6d) [0x55db0aff2c3d] gc.c:7564 - build/ruby(gc_mark_stacked_objects_all) gc.c:7602 - build/ruby(gc_marks_rest) gc.c:8797 - build/ruby(gc_marks+0xd) [0x55db0aff43d5] gc.c:8855 - build/ruby(gc_start) gc.c:9608 - build/ruby(rb_multi_ractor_p+0x0) [0x55db0aff5463] gc.c:9489 - build/ruby(rb_vm_lock_leave) vm_sync.h:92 - build/ruby(garbage_collect) gc.c:9491 - build/ruby(newobj_slowpath+0xcb) [0x55db0aff57ab] gc.c:2871 - build/ruby(newobj_slowpath_wb_protected) gc.c:2895 - build/ruby(newobj_of0+0x24) [0x55db0aff59e4] gc.c:2937 - build/ruby(newobj_of) gc.c:2947 - build/ruby(rb_wb_protected_newobj_of) gc.c:2962 - build/ruby(ary_alloc_embed+0x10) [0x55db0b2f3e40] array.c:668 - build/ruby(ary_new) array.c:709 - build/ruby(rb_ary_tmp_new_from_values) array.c:759 - build/ruby(rb_ary_new_from_values) array.c:771 - build/ruby(args_copy+0x18) [0x55db0b1bbb88] vm_args.c:158 - -commit 86ef38194bf2f5c854cab0adf29984594ee4a6ec - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-12-25 04:26:07 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-25 04:56:06 +0900 - - RDoc for complex.c - -commit f0efeddd41f96d3afae9af73a3dc594d86614f4b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-24 23:08:01 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-25 01:04:41 +0900 - - Fix Regexp#inspect for GC compaction - - rb_reg_desc was not safe for GC compaction because it took in the C - string and length but not the backing String object so it get moved - during compaction. This commit changes rb_reg_desc to use the string - from the Regexp object. - - The test fails when RGENGC_CHECK_MODE is turned on: - - TestRegexp#test_inspect_under_gc_compact_stress [test/ruby/test_regexp.rb:474]: - <"(?-mix:\\/)|"> expected but was - <"/\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00/">. - -commit 8ad8803bb4aed01dfe56e42dc7c131b6bf307655 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-12-25 00:26:20 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-25 01:00:30 +0900 - - RDoc for Complex - -commit 42442ed7891b1c721b4a306f21ce9548a69e7be3 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-24 10:24:15 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-24 23:03:55 +0900 - - Fix Regexp#match for GC compaction - - The test fails when RGENGC_CHECK_MODE is turned on: - - TestRegexp#test_match_under_gc_compact_stress: - NoMethodError: undefined method `match' for nil - test_regexp.rb:878:in `block in test_match_under_gc_compact_stress' - -commit 37753f163e461e157e6e224d9d3e5626427a50cc - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-12-24 22:03:36 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-24 22:03:36 +0900 - - IO::Buffer improvements and documentation. (#9329) - - * Restore experimental warnings. - - * Documentation and code structure improvements. - - * Improved validation of flags, clarified documentation of argument handling. - - * Remove inconsistent use of `Example:` and add example to `null?`. - - * Expose `IO::Buffer#private?` and add test. - -commit 61289d940597efb76bd7bcdd0501801733d9c9dd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-24 15:47:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-24 19:34:25 +0900 - - Initialize loop variable of `ccan_list_for_each` - - On platforms where `typeof` is unsupported, `ccan_container_off_var` - calculates the offset of member by pointer subtraction. Although this - will result in the compile-time invariant value regardless the pointer - value, the loop variable will be used before assignment and may cause - an using uninitialized variable warning. - -commit 86893b28f7ac7cc522d628577564d49a8f558d70 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-12-24 15:58:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-24 15:58:23 +0900 - - Update bundled gems list as of 2023-12-24 - -commit a87ae242bb460c7643d0f974b96489b5f73a2d45 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-24 14:33:14 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-24 15:13:33 +0900 - - Use noinline version of accessing current ec - - On universal.arm64e-darwin22 with clang 15.0.0 (I didn't check - details yet) accessing `ruby_current_ec` directly causes - assertion violation `VM_ASSERT(ec == rb_current_ec_noinline())` - on `rb_current_execution_context()`, maybe because TLS accessing - issue. - -commit 541371e286d2f139c49e7805f6f229618eb63144 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-24 14:20:35 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-24 14:53:46 +0900 - - accept `RB_WAITFD_IN | RB_WAITFD_OUT` for waiting events - - Assrsion was `events == RB_WAITFD_IN || events == RB_WAITFD_OUT` - but it should accept `RB_WAITFD_IN | RB_WAITFD_OUT`. - -commit 0fef890b4fbe64a319247fee9d2cb13f45b76844 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-24 13:59:34 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-24 13:59:34 +0900 - - [DOC] Fix markup in HTML - - Inside HTML is not markdown. - -commit 82015496b924744ae3999987ba679978beb153c7 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-24 10:30:03 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-24 10:57:27 +0900 - - MN: access `timer_th.waiting` with lock - - `timer_th.waiting` should be protected by `timer_th.waiting_lock` - -commit daefbf8fbfa1bd2109315bab7658f52460f7ed59 - Author: Daisuke Fujimura (fd0) <booleanlabel@gmail.com> - AuthorDate: 2023-12-17 00:02:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-24 08:06:03 +0900 - - Use native_thread_init_stack on cygwin - -commit 50bf4373411a8780270c7ba1cc983d5756a4fde1 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-24 06:22:14 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-24 08:00:27 +0900 - - Fix String#sub for GC compaction - - The test fails when RGENGC_CHECK_MODE is turned on: - - TestString#test_sub_gc_compact_stress = 9.42 s - 1) Failure: - TestString#test_sub_gc_compact_stress [test/ruby/test_string.rb:2089]: - <"aaa [amp] yyy"> expected but was - <"aaa [] yyy">. - -commit a2ebf9cc63f0805bc7dd9a92e66bf589a869447e - Author: JP Camara <jp@jpcamara.com> - AuthorDate: 2023-12-23 10:28:55 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-24 07:07:11 +0900 - - Replicate EEXIST epoll_ctl behavior in kqueue - - * In the epoll implementation, you get an EEXIST if you try to register the same event for the same fd more than once for a particular epoll instance - - * Otherwise kevent will just override the previous event registration, and if multiple threads listen on the same fd only the last one to register will ever finish, the others are stuck - - * This approach will lead to native threads getting created, similar to the epoll implementation. This is not ideal, but it fixes certain test cases for now, like test/socket/test_tcp.rb#test_accept_multithread - -commit fadda88903d9fe764ae53eca07aaf85f08e162a7 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-24 04:51:43 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-24 06:52:05 +0900 - - Fix Regexp#to_s for GC compaction - - The test fails when RGENGC_CHECK_MODE is turned on: - - TestRegexp#test_to_s_under_gc_compact_stress = 13.46 s - 1) Failure: - TestRegexp#test_to_s_under_gc_compact_stress [test/ruby/test_regexp.rb:81]: - <"(?-mix:abcd\u3042)"> expected but was - <"(?-mix:\u5C78\u3030\u5C78\u3030\u5C78\u3030\u5C78\u3030\u5C78\u3030)">. - -commit 688a1314e60b0e58d5325f50c02552e3018c5025 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-12-24 06:08:26 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-24 06:08:26 +0900 - - [DOC] Clean up doc for File#flock (#9332) - -commit 47f33c38481d79563271f042946d0f3165d8b638 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-23 23:51:30 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-23 23:51:30 +0900 - - Remove useless `#if 1` in array.c - -commit fd3dede7f4bad52d7ab383eeb9ee29f20b045cb7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-23 18:57:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-23 18:57:47 +0900 - - Fix for older set versions - - `Set::VERSION` was not defined in old set.rb bundled with ruby 3.2 or - earlier. - Also add comment for spec/mspec/tool/remove_old_guards.rb. - -commit dc7785e16ba54039d7341bba570ff551f146cf62 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-23 18:15:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-23 18:15:26 +0900 - - Set 1.1 now checks subclass-ness stricter - -commit f6e9899e8a84fc98d47d9c0faf59ff3f0684e1b4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-23 01:54:35 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-23 18:03:31 +0900 - - Make rbconfig.rb loadable from exe/ruby - - So that it can run without `--disable=gems` option. - -commit 8c03bdacd180cc40b9dac2e6ab52ceb96b34bb18 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-23 01:51:23 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-23 18:03:30 +0900 - - Control the precheck for test-all by `PRECHECK_TEST_ALL` - -commit 40bc7ede38f87bfdd768ed277631b240bd0632b4 - Author: Akinori MUSHA <knu@idaemons.org> - AuthorDate: 2023-12-23 16:51:41 +0900 - Commit: Akinori MUSHA <knu@idaemons.org> - CommitDate: 2023-12-23 16:51:41 +0900 - - Set 1.1.0 has been imported - -commit c66ff6facedc693622132a343425ff878a163262 - Author: Akinori MUSHA <knu@idaemons.org> - AuthorDate: 2023-12-23 16:43:37 +0900 - Commit: Akinori MUSHA <knu@idaemons.org> - CommitDate: 2023-12-23 16:50:33 +0900 - - [ruby/set] Bump version to 1.1.0 - - https://github.com/ruby/set/commit/d6cab5bcc8 - -commit 67882d7695552202c47a62bae12e8a774f9e64ea - Author: Akinori MUSHA <knu@idaemons.org> - AuthorDate: 2023-12-08 22:20:14 +0900 - Commit: Akinori MUSHA <knu@idaemons.org> - CommitDate: 2023-12-23 16:50:31 +0900 - - [ruby/set] Use the pattern argument instead of a block - - https://github.com/ruby/set/commit/c63047c2ce - -commit 6fc3171e8af966c680664791b05fa9d505c95d19 - Author: Akinori MUSHA <knu@idaemons.org> - AuthorDate: 2023-12-08 22:18:25 +0900 - Commit: Akinori MUSHA <knu@idaemons.org> - CommitDate: 2023-12-23 16:50:30 +0900 - - [ruby/set] The arity of initialize_clone is -1 in Ruby >= 3 - - https://github.com/ruby/set/commit/32a9689696 - -commit 271c74a473b4fa2cdd754865882ba9912b58541c - Author: Akinori MUSHA <knu@idaemons.org> - AuthorDate: 2023-12-08 22:09:22 +0900 - Commit: Akinori MUSHA <knu@idaemons.org> - CommitDate: 2023-12-23 16:50:29 +0900 - - [ruby/set] Drop support for Ruby 2 - - https://github.com/ruby/set/commit/64dad673d8 - -commit da02d08f2793c1c5d2ce084d6ceb6fa58ed641f2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-23 15:17:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-23 15:18:14 +0900 - - RJIT: Rewind $! after compilation - -commit ef065102653378956f579985d10d3d4816dc87cf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-23 14:47:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-23 14:48:26 +0900 - - RJIT: Prefer STDERR over $stderr - - When $stderr is redirected, you'll have no way to see why RJIT got - broken. This reference must always be the actual stderr. - -commit c25705c2670ab34a2d4c993436edcf7d77e5cd92 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-23 13:20:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-23 13:20:42 +0900 - - Get rid of obsoleted RJITFirst - - It was renamed from test_mjit, but we did not maintain it as test_rjit. - We test RJIT very differently. - -commit 9b289d58f78e80362984ffb2920e859beeaec2ce - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-12-23 12:31:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-23 12:31:18 +0900 - - [DOC] RDoc for Complex (#9307) - -commit f1b7424cbed00a27532a053949f524eaaf4be1ba - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-23 05:15:22 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-23 11:07:22 +0900 - - FREE_AT_EXIT: Don't free main stack post-fork - - When a forked process was started in a thread, this would result in a - double-free during the child process exit. - - RUBY_FREE_AT_EXIT=1 ./miniruby -e 'Thread.new { fork { } }.join; Process.waitpid' - - This is because the main thread in the forked process was not the - initial VM thread, and the new thread's stack was freed as part of - objectspace iteration. - - This change also allows rb_threadptr_root_fiber_release to run without - EC being available. - -commit 339978ef3869acb2ff877451381a80ee4b548bfb - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-23 05:15:07 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-23 11:07:22 +0900 - - Free default_rand_key after freeing Ractors - - Ractor's free iterates through its TLS keys so we need to keep this - memory available until after Ractors are freed. - - Minimal reproduction: - - RUBY_FREE_AT_EXIT=1 ./miniruby -e rand - -commit 697a096c9b0d8c153cb5d99affb6b5673b7c4210 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-16 18:34:03 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-23 11:07:22 +0900 - - Remove EC argument from clean_hooks_check - - This argument doesn't seem used anymore. Since we want to free these - objects during VM destruction when RUBY_FREE_AT_EXIT is set they must - work without an EC. - - This avoids a use-after-free running `RUBY_FREE_AT_EXIT=1 ./miniruby -e ''` - -commit 7d7a84e99fca816ec352c95965687db240fb56d3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-23 09:08:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-23 09:34:26 +0900 - - Merge RubyGems-3.5.3 and Bundler-2.5.3 - -commit fa5de8f68d51e4fbc91190061e3ce3817bd68964 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-23 07:46:56 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-23 08:10:41 +0900 - - MN: skip waiting on fiber schedulers - - If the Fiber is nonblocking mode, fiber scheduler needs to handle - IO events. - -commit beec3d07c907ec875e05fe2d22cea2263857b499 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-23 07:45:08 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-23 08:10:41 +0900 - - MN: skip waiting on `read_nonblock' - - if the IO for `IO#read_nonblock` is not ready, it needs - to return (or raise) immediately. - -commit 2fe9e08578689adec0be8a36d0ae49541551d357 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-23 07:44:36 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-23 08:10:41 +0900 - - MN: skip RUBY_DESCRIPTION spec on MN enabled - -commit a4b737213eb1d8f352f1f148c27e96a3f09f5d08 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-23 05:23:53 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-23 05:56:02 +0900 - - MN: ceil timeout milli seconds - - `hrrel / RB_HRTIME_PER_MSEC` floor the timeout value and it can - return wrong value by `Mutex#sleep` (return Integer even if - it should return nil (timeout'ed)). - - This patch ceil the value and the issue was solved. - -commit c974ee1abe5df5a4bb97264e608afbd134c77652 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-23 05:22:52 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-23 05:56:02 +0900 - - ensure to restart antoher thread - -commit bbfc262c994f84801abfb1302cf6142dfee50adf - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-23 03:57:53 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-23 05:56:02 +0900 - - MN: fix "raise on close" - - Introduce `thread_io_wait_events()` to make 1 function to call - `thread_sched_wait_events()`. - - In ``thread_io_wait_events()`, manipulate `waiting_fd` to raise - an exception when closing the IO correctly. - -commit 19d082dcfa393e8a5d0282b872ace587ca5cd49a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-23 04:20:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-23 04:24:04 +0900 - - RJIT: Distinguish Pointer with Array - - This is more convenient for accessing those fields. - -commit 40e3f782dd92749a1fa593ef905d1b75fdd61904 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-22 21:50:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-22 23:08:10 +0900 - - Extract `forwarding_arg_check` function - -commit 11c2aa035b0639a2b3550cd8e0b9ef72315f0c2d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-22 16:30:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-22 23:08:10 +0900 - - Extract `arg_splat` nonterminal symbol - -commit 426f2334dd4a926782ffac32ad9c6c01abf220b8 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-12-22 22:26:22 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-12-22 23:06:47 +0900 - - .travis.yml: Try another way to be notified. - - I <jaruga@ruby-lang.org> haven't received the notifications since August 2022. - So, try another way to be notified written on the document below. - - https://docs.travis-ci.com/user/notifications/#configuring-email-notifications - -commit e8639098ed78f8f8f7c263d8b6f2d68822945a78 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-10-29 14:57:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-22 16:15:33 +0900 - - [Bug #19977] Fix (nil..nil) === x not to raise TypeError - -commit f263e447460eb952738f0318ca4e8dee4f4139a5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-22 15:57:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-22 16:00:18 +0900 - - RJIT: Avoid retaining unrelated local variables in memory - -commit ef4797bb0338aa35dd74290dcfef83cbc288ad58 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-12-22 15:44:57 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-22 15:53:41 +0900 - - [DOC] Fix NEWS markup - -commit 17e351057ea39acbc19fa3f17ba668a3ba31421e - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-22 15:03:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-22 15:28:33 +0900 - - Add Regexp updates to NEWS.md - -commit e364436c5f89fc4ee51706634637893771175d02 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-12-22 09:32:32 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-12-22 15:15:05 +0900 - - [DOC] NEWS entries for Parser - -commit f3c82df944603a590771c83e1e58c51f83eb63cf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-22 14:59:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-22 14:59:33 +0900 - - RJIT: Minimize string allocations in InsnCompiler - -commit 2e0277b133b9040808f45d0ec9930a0fd7422c3b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-22 14:25:08 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-22 14:46:19 +0900 - - RJIT: Make --rjit-trace actually work - -commit 4c6f07eeca54df45cbdd1ab83eafc5a9343482d4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-22 14:10:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-22 14:10:19 +0900 - - RJIT: Update bindgen - -commit 64c52cd1c2df840a021dd952b42bddde09534b1b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-22 13:57:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-22 14:05:13 +0900 - - RJIT: Add --rjit-trace to allow TracePoint during JIT - -commit c18edc5b5d03b9abf355038a17956d69e0552228 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-22 09:01:16 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-22 13:43:01 +0900 - - Avoid underflow of rb_yjit_live_iseq_count - - This value is only incremented when rb_iseq_translate_threaded_code is - called, which doesn't happen for iseqs which result in a syntax error. - - This is easy to hit by running a debug build with RUBY_FREE_AT_EXIT=1, - but any build and options could underflow this value by running enough - evals. - -commit cae11dd8576d9ddb9bead2e5340677c5d05b03f5 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-22 12:15:44 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-22 12:45:31 +0900 - - debug.gem v1.9.1 - -commit fa0f7522c41bd2a71117b2428bc6fbb0bbcc9699 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-12-22 08:52:20 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-12-22 11:30:00 +0900 - - coroutine/arm64: Skip saving/restoring x30 twice and use `autiasp` - - We don't need to save/restore x30 twice, and we can just use `ret`, - which uses x30 as return address register instead of explicit `ret <reg>` - instruction. This also allows us to use `autiasp` instead of `autia1716` - and we can skip setting SP/LR to x16/x17. - - Also the size of register save area is shrunk by 16 bytes due to the - removal of extra x30 save/restore. - -commit 2d004decde80566c5b004c5b832e8a1ab007965f - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-12-21 15:21:37 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-12-22 11:30:00 +0900 - - coroutine/arm64/Context.S: Append PAC/BTI note section if needed - - Fixes https://bugs.ruby-lang.org/issues/20029 - -commit 35587150e21175b6a63cd02d406beff5c76f1149 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-12-21 15:19:25 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-12-22 11:30:00 +0900 - - coroutine/arm64/Context.S: Insert `bti c` as BTI landing pad - -commit d9e5564ccd0e460b7685b786d21cf386b229e2a9 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-12-21 14:42:39 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-12-22 11:30:00 +0900 - - coroutine/arm64: Sign return address if PAC enabled - -commit 9a3c49ee5d6dd3770c21ed8193e7efd64cd81a6e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-22 10:45:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-22 10:47:36 +0900 - - RJIT: Convert opt_case_dispatch keys with #to_value - - comptime_key is a Ruby object and the value is not valid in machine code. - - This PR also implements `CMP r/m64, imm32 (Mod 01: [reg]+disp8)` that is - now needed for running mail.gem benchmark. - -commit 009968a700209336eb592ccb83bddcf7b2c17984 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-22 10:12:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-22 10:12:40 +0900 - - RJIT: Avoid incrementing vm_insns_count - - during compilation - -commit 3c182776292ecd2a28fea4f7de87a89e64459f9c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-22 09:18:30 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-22 09:47:13 +0900 - - RJIT: Clean up unnecessary documentation - -commit 18a97affa349b5edbc4829063b752aab1911fa55 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-22 09:45:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-22 09:45:37 +0900 - - RJIT: Fix a wrong comparison in set_local_type - -commit 68bcca4c2bfa716b965554057b098cefcba00f66 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-22 08:45:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-22 08:48:37 +0900 - - RJIT: Fix unwanted shadowing in set_local_type - - local_idx should not be overwritten. - -commit ffa5f16273f46c97bfca56e4549b0b38b9322d63 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-21 06:54:32 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-22 08:23:19 +0900 - - Make rb_profile_frames return 0 for NULL ec - - When using M:N threads, EC is set to NULL in the shared native thread - when nothing is scheduled. This previously caused a segfault when we try - to examine the EC. - - Returning 0 instead means we may miss profiling information, but a - profiler relying on this isn't thread aware anyways, and observing that - "nothing" is running is probably correct. - - Fixes [Bug #20017] - - Co-authored-by: Dustin Brown <dbrown9@gmail.com> - -commit 78b27ce62a7d6f28c73d6fb4f97b0948859be8e0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-22 07:30:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-22 07:32:03 +0900 - - RJIT: Streamline RJIT enablement check - - in bootstrap tests so that `make btest-bruby` skips the right tests. - -commit c73959cff40ba0f1d71ea6e3fce19b5f287e8494 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-22 07:24:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-22 07:25:41 +0900 - - RJIT: Rename pause/resume to disable/enable - - like YJIT. They don't work in the same way yet, but it's nice to make - the naming consistent first so that we will not need to rename them - later. - -commit 82496f2b389278a569fa7680ee6faa55a97410d7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-22 07:01:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-22 07:24:04 +0900 - - Merge RubyGems-3.5.2 and Bundler-2.5.2 - -commit fc549b2b3a65a95a734ee8679293a30284f84622 - Author: Victor Shepelev <zverok.offline@gmail.com> - AuthorDate: 2023-12-22 06:12:36 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-22 06:12:36 +0900 - - [DOC] Improve NEWS.md rendering and add missing features (#9308) - - * Fix rendering of the file on docs.ruby-lang.org: - * More indentation for code; - * Properly qualified methods to link to docs; - * Add two minor yet notable changes: - * Time.new stricter parsing of strings; - * NoMethodError rendering logic change. - -commit e04197aba74e62aae163f0cdc7058861047045a2 - Author: Victor Shepelev <zverok.offline@gmail.com> - AuthorDate: 2023-12-22 05:27:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-22 05:27:18 +0900 - - [DOC] Fix NoMethodError example of rendering (#9309) - - Fix NoMethodError example of rendering - -commit 1f0304218cf00e05a4a126196676ba221ebf91f6 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-21 08:29:03 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-22 02:17:22 +0900 - - Use main_thread->ec from rb_vm_main_ractor_ec - - rb_vm_main_ractor_ec was introduced to allow rb_postponed_job_* to work - when fired on non-Ruby threads, which have no EC set, and that is its - only use. - - When RUBY_MN_THREADS=1 is set ractor->threads.running_ec is NULL when - the shared thread is sleeping. This instead grabs the EC directly from - the main thread which seems to always be set. - - Fixes [Bug #20016] - - Co-authored-by: Dustin Brown <dbrown9@gmail.com> - -commit 1710eb9367d7d11f059a17879e00ef7637265558 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-21 03:37:02 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-22 02:17:22 +0900 - - [DOC] Fix rb_postponed_job_register_once typo - - Co-authored-by: Dustin Brown <dbrown9@gmail.com> - -commit e191bf42d2077a025c21888573f8b81688e5ea28 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-19 10:55:59 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-22 00:39:03 +0900 - - Fix ary_make_partial_step for compaction - - ary could change embeddedness due to compaction, so we should only get - the pointer after allocations. - - The included test was crashing with: - - TestArray#test_slice_gc_compact_stress - ruby/lib/pp.rb:192: [BUG] Segmentation fault at 0x0000000000000038 - -commit fd4735130e5fdc0a11f970092d5900847a3ce4cf - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-12-21 20:20:41 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-12-21 21:02:25 +0900 - - Fix a typo in NEWS.md - -commit bcb4706dac321bef018a28c83721609a20143351 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-21 14:16:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-21 14:16:09 +0900 - - Added limitation of bundled gems warning feature with bootsnap - -commit d587852cf7f660308d1287e85767ada3559a3ff9 - Author: Soutaro Matsumoto <matsumoto@soutaro.com> - AuthorDate: 2023-12-21 10:26:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-21 10:26:08 +0900 - - Bundle RBS 3.4.0 (#9293) - - Bundle RBS 3.4.0 and TypeProf 0.21.9. - -commit c28177cd57c99865bbf18e73008ba6fb11f73a2e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-21 02:17:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-21 02:17:46 +0900 - - RJIT: Print an error message first - - Creating a backtrace can crash if RJIT is triggered by branch_stub_hit. - In that case, it's useful to at least print the error message. - -commit 31959f1f13c0dcbb517469b4cbf29a637a7c6ee4 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-12-20 19:04:53 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-20 19:11:02 +0900 - - [ruby/irb] Bump version to v1.11.0 - (https://github.com/ruby/irb/pull/818) - - https://github.com/ruby/irb/commit/7421359b92 - -commit 4ad1007fd2da863e3afc8bd83b38c512f9ca7fc4 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-12-19 08:26:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-20 19:11:02 +0900 - - [ruby/irb] [DOC] Change indexes.rdoc to indexes.md - (https://github.com/ruby/irb/pull/812) - - * Change indexes.rdoc to indexes.md - - * Change indexes.rdoc to indexes.md - - * Change indexes.rdoc to indexes.md - - https://github.com/ruby/irb/commit/b1cd53cbf7 - -commit 2793a30b69177e7c7bbf124ccfca7b4f4216ca84 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-12-18 23:36:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-20 19:11:01 +0900 - - [ruby/irb] Warn users about errors in loading RC files - (https://github.com/ruby/irb/pull/817) - - 1. Because `IRB.rc_file` always generates an rc file name, even if the - file doesn't exist, we should check the file exists before trying to - load it. - 2. If any type of errors occur while loading the rc file, we should - warn the user about it. - - https://github.com/ruby/irb/commit/37ffdc6b19 - -commit 7c2d8198625ca2e38835ad06ab47b4ea3afbc34b - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-12-20 17:05:44 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-12-20 17:28:45 +0900 - - Fix a grammar issue in the shape performance warning message - -commit 4927f251481df57a209284bb2ad2b237468e7792 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-20 15:48:49 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-20 17:00:55 +0900 - - skip `MAP_STACK` on FreeBSD - -commit 256f34ab6b221b630e5e4ec8d39e3808e82a3296 - Author: JP Camara <jp@jpcamara.com> - AuthorDate: 2023-12-16 12:39:45 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-20 16:23:38 +0900 - - Hand thread into `thread_sched_wait_events_timeval` - - * When we have the thread already, it saves a lookup - - * `event_wait`, not `kq` - - Clean up the `thread_sched_wait_events_timeval` calls - - * By handling the PTHREAD check inside the function, all the other code can become much simpler and just call the function directly without additional checks - -commit 8782e02138e6fe18b6c0dcc29bb877d6cdae57e5 - Author: JP Camara <jp@jpcamara.com> - AuthorDate: 2023-12-07 10:01:14 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-20 16:23:38 +0900 - - KQueue support for M:N threads - - * Allows macOS users to use M:N threads (and technically FreeBSD, though it has not been verified on FreeBSD) - - * Include sys/event.h header check for macros, and include sys/event.h when present - - * Rename epoll_fd to more generic kq_fd (Kernel event Queue) for use by both epoll and kqueue - - * MAP_STACK is not available on macOS so conditionall apply it to mmap flags - - * Set fd to close on exec - - * Log debug messages specific to kqueue and epoll on creation - - * close_invalidate raises an error for the kqueue fd on child process fork. It's unclear rn if that's a bug, or if it's kqueue specific behavior - - Use kq with rb_thread_wait_for_single_fd - - * Only platforms with `USE_POLL` (linux) had changes applied to take advantage of kernel event queues. It needed to be applied to the `select` so that kqueue could be properly applied - - * Clean up kqueue specific code and make sure only flags that were actually set are removed (or an error is raised) - - * Also handle kevent specific errnos, since most don't apply from epoll to kqueue - - * Use the more platform standard close-on-exec approach of `fcntl` and `FD_CLOEXEC`. The io-event gem uses `ioctl`, but fcntl seems to be the recommended choice. It is also what Go, Bun, and Libuv use - - * We're making changes in this file anyways - may as well fix a couple spelling mistakes while here - - Make sure FD_CLOEXEC carries over in dup - - * Otherwise the kqueue descriptor should have FD_CLOEXEC, but doesn't and fails in assert_close_on_exec - -commit 7ef90b3978dad057ad6360a94d2d64e8ca5e9c38 - Author: HParker <HParker@github.com> - AuthorDate: 2023-12-20 14:12:18 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-20 14:36:32 +0900 - - Correct free_on_exit env var to free_at_exit - -commit 7dca6b53a995a9782026f726c291344b5b8e0ab2 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-12-20 14:30:47 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-20 14:30:47 +0900 - - Add tool/missing-baseruby.bat, used when BASERUBY not available - - Previously, the embedded semicolon in BASERUBY if BASERUBY is - not available breaks tarball builds without BASERUBY when using - OpenBSD make, due to the inability to escape MFLAGS correctly. - This moves the same BASERUBY code into a separate file, avoiding - the MFLAGS quoting issue. - - BASERUBY must be passed to build-ext because it is required - by ripper since the introduction of lrama. - - Fixes [Bug #19683] - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit ae2c4d07204dd714a7a5be7697541447b023ea25 - Author: Mikhail Doronin <mikhail.doronin@thetrainline.com> - AuthorDate: 2023-12-19 05:13:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-20 13:46:39 +0900 - - Revert "[Bug #19831] Remove duplicate library options" - - This reverts commit 5bb946228550c7f171c27725860b153a675404f3. - - Fixes https://bugs.ruby-lang.org/issues/20072 - -commit 32ecda354f1556edbfdba4723716fa523acbc94d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-19 06:55:19 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-20 08:29:36 +0900 - - Support `GC.auto_compact = :empty` on debug builds - - This commit adds `GC.auto_compact = :empty` which will run - auto-compaction sorting pages by empty slots so the most amount of - objects will be moved. This will make it easier to write tests for - auto-compaction. - -commit 3d984366ca809fdcc9320e776705ecd96efa49a0 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-20 07:06:50 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-12-20 07:50:59 +0900 - - [PRISM] Correct the jump target for redo in FOR_NODE - -commit 371ff808400b079b373e87de9b3deeb6c16f6a23 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-19 06:32:25 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-12-20 07:50:59 +0900 - - [PRISM] Fix parameter numbering in For Node - -commit f0b86f8c6098edfe47c4735d061e50e017d7e94d - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-12-20 05:32:54 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-20 07:29:09 +0900 - - RDoc for Complex - -commit 054f56fd3e5bf84e5443896fd1f4e439c2773c60 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-20 03:45:41 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-20 07:04:32 +0900 - - moved object should not have a shape ID - - fix [Bug #19917] - -commit 7a0dfdea8c92d2393d624bc7961f36e082c43471 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-20 06:15:15 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-20 07:00:41 +0900 - - use `rb_thread_io_blocking_call()` more - - use `rb_thread_io_blocking_call()` instead of - `rb_thread_io_blocking_region()` more. - - See https://github.com/ruby/ruby/pull/9178#issuecomment-1858711533 - -commit ec51a3c8183d555b6ccaa37834fac855ded3af88 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-20 05:25:38 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-20 07:00:41 +0900 - - declare `rb_thread_io_blocking_call` - -commit 2fe5fc176b31ce132e05a91b2c96b4a935e46ceb - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-20 06:14:51 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-20 07:00:41 +0900 - - setup `waiting_fd` for `thread_sched_wait_events()` - - `thread_sched_wait_events()` suspend the thread until the target - fd is ready. Howver, other threads can close the target fd and - suspended thread should be awake. To support it, setup `waiting_fd` - before `thread_sched_wait_events()`. - - `rb_thread_io_wake_pending_closer()` should be called before - `RUBY_VM_CHECK_INTS_BLOCKING()` because it can return this function. - - This patch introduces additional overhead (setup/cleanup `waiting_fd`) - and maybe we can reduce the overhead. - -commit 28a6e4ea9d9379a654a8f7c4b37fa33aa3ccd0b7 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-20 04:38:57 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-12-20 06:09:36 +0900 - - Set m_tbl right after allocation - - We should set the m_tbl right after allocation before anything that can - trigger GC to avoid clone_p from becoming old and needing to fire write - barriers. - - Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org> - -commit 50d39219a9b5f19a536c02ec47b54b79efa015f5 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-20 05:21:28 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-20 05:21:28 +0900 - - Use RICLASS_OWNS_M_TBL_P - - It's more consistent with gc_mark_children. - -commit bd91c5127ff30f5a21547e73a493c06fbd6da7ae - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-20 04:47:27 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-20 04:47:27 +0900 - - YJIT: Add stats option to RubyVM::YJIT.enable (#9297) - -commit 084b44e79dd456c9ce09ac06c6faf538160ac6b0 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-12-20 00:19:00 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-20 04:30:33 +0900 - - RDoc for Complex - -commit df0bfde2b29b7e8dac333b2a775ab8bff1283a5c - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-12-19 08:16:31 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-12-20 01:53:52 +0900 - - We need to load builtins so that they work - - Before this commit no methods defined in Ruby were being loaded. For - example `class` or `tap` methods would not exist. - - [ruby-core:115793] [Bug #20073] - -commit 8e6f63df47089361f7988176bb22ed3c96ecf95a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-15 04:15:17 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-19 23:13:20 +0900 - - Implement IO::Buffer on VWA - -commit 1822acdf336d53a2c143b29583c3ca21a9a224f4 - Author: Doug Orleans <door@hey.com> - AuthorDate: 2023-12-16 09:37:40 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-19 22:11:11 +0900 - - [DOC] remove reference to pre-3.0 splat operator behavior - -commit f9a48548cf3ef54fc0a385ccd78c708737055ecc - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-19 17:32:19 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-19 17:59:49 +0900 - - restore the stack pointer on finalizer - - When error on finalizer, the exception will be ignored. - To restart the code, we need to restore the stack pointer. - - fix [Bug #20042] - -commit 96e4f42b3d13f37afce1a8c584a56f6d7e98ec23 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-19 17:06:21 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-19 17:06:21 +0900 - - RJIT: Correct the macro that defines rb_vm_insns_count - -commit 8d5af353b2ab6c774a473fdb010dcbe3d4e90f0e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-19 15:21:31 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-19 17:05:19 +0900 - - RJIT: Avoid retaining comments unless --rjit-dump-disasm - - This significantly reduces retained objects on RJIT. - -commit 8671cd59f78a2bf28d323b6d0c5314e090811a65 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-19 17:02:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-19 17:02:38 +0900 - - RJIT: Correct the type of rb_vm_insns_count - -commit edd6581eec59f0139cfff27bccf9e24c9152a6d3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-19 17:00:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-19 17:00:18 +0900 - - RJIT: Declare rb_vm_insns_count - -commit eb872d17524f299bdd023f005da38ffcddffa90a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-19 16:49:54 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-19 16:55:40 +0900 - - RJIT: Share rb_vm_insns_count for vm_insns_count - -commit dee45ac231afd02797640cb335d86550aa620cbe - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-19 12:59:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-19 13:48:51 +0900 - - [DOC] State MatchData#[] when multiple captures with the same name - -commit b5f33ba76f9657228746e079eafb8fa952a9ab8b - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-12-19 11:55:24 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-12-19 12:40:43 +0900 - - signal.c: Fix undefined `reset_sigmask` use on Emscripten - - 3c471149910d79745b50389c436f0ed2973e0d91 added a call to `reset_sigmask` - but the guard condition didn't match with the condition used to define - `reset_sigmask`. - -commit f907a7111c5fd26f54c0e020dd64d6325c3fd08b - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-12-19 11:40:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-19 11:40:58 +0900 - - [DOC] RDoc for Complex (#9260) - -commit 36b389c206b0d793da45bc73c8a036e1d5c7a72e - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-12-17 23:21:17 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-12-19 11:13:38 +0900 - - [wasm] dln.c: Guard `dladdr` use in symbol incompatibility check - - wasi-libc recently added a family of `dl*` functions[^1], but it still - doesn't have `dladdr` unlike other platforms. Guard the use of `dladdr` - with `HAVE_DLADDR` to avoid build failure with the head version of - wasi-libc. - The library name is used only for diagnostic purpose if it's not NULL, - so it's safe to skip it. - - [^1]: https://github.com/WebAssembly/wasi-libc/commit/b85d65528d6e17ae1874c6cc6a6a3ac02e83021a - -commit 5ea862f26e86be6fabcc938e22bc2d5c2bbc8341 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-19 10:56:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-19 11:07:47 +0900 - - [ruby/psych] Bump up 5.1.2 - - https://github.com/ruby/psych/commit/a9ab74d132 - -commit b3598f95fa997e667bb9e8003b0284ab2a4db081 - Author: Alexander Momchilov <alexandermomchilov@gmail.com> - AuthorDate: 2023-12-18 18:01:01 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-19 11:07:46 +0900 - - [ruby/psych] Use `assert_same` in tests where applicable - - https://github.com/ruby/psych/commit/0dc25a9d6a - -commit e6fa1d62faf6ba4b0f3277e2e92e6e60d4330cc8 - Author: Alexander Momchilov <alexandermomchilov@gmail.com> - AuthorDate: 2023-12-18 18:00:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-19 11:07:45 +0900 - - [ruby/psych] Use `compare_by_identity` instead of `object_id` - - Object IDs became more expensive in Ruby 2.7. Using `Hash#compare_by_identity` let's us get the same effect, without needing to force all these objects to have object_ids assigned to them. - - https://github.com/ruby/psych/commit/df69e4a12e - -commit 46085ef970ab50b5e1c7878345a39528823461ac - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-18 20:22:22 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-19 10:20:40 +0900 - - [DOC] No ducuments for internal library - -commit ce436ff3e3cbd6810d7cf83fedbd2b55995ca0b1 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-19 03:30:24 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-19 09:25:37 +0900 - - Fix flaky test test_stat_heap - - The test sometimes fails with: - - 1) Failure: - TestGc#test_stat_heap [/tmp/ruby/src/trunk-repeat50/test/ruby/test_gc.rb:169]: - Expected 33434403 to be <= 33434354. - -commit 3c471149910d79745b50389c436f0ed2973e0d91 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-19 06:37:52 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-12-19 08:19:53 +0900 - - Unmask signal before re-raising fatal signal - - On Linux, while the signal handler runs, that signal is masked, so in - the rb_bug_for_fatal_signal() code path we didn't get the default signal - action as intended. See signal(7). It worked fine on macOS, though. - - Before: - - $ ./miniruby -e 'Process.kill :SIGSEGV, Process.pid' - <snip> - Aborted (core dumped) - - After: - - $ ./miniruby -e 'Process.kill :SIGSEGV, Process.pid' - <snip> - Segmentation fault (core dumped) - - Follow-up for 1ac0afab4da "rb_bug_for_fatal_signal: exit with the right - signal". - -commit 11fa76b1b521072c200c78ea023960221ff426d6 - Author: Alexander Momchilov <alexandermomchilov@gmail.com> - AuthorDate: 2023-12-18 17:19:02 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-19 04:51:16 +0900 - - compare_by_identity: remove alloc for non-empty Hash - - If a Hash is non-empty, there's no point calling `ar_force_convert_table`. We'll be immediately discarding that new st table, and replacing it with the new `identtable` st table that we're stealing out of `tmp`. - -commit b5c6c0122f5b010cb5f43e7a236c4ba2b1d56a2a - Author: Alexander Momchilov <alexandermomchilov@gmail.com> - AuthorDate: 2023-12-18 17:17:44 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-19 04:51:16 +0900 - - compare_by_identity: remove alloc for empty Hash - - For non-empty Hashes, this function needs to rehash all the stored values (using the new `compare` and `hash` functions from `identhash`). It does so by writing into a newly allocated `tmp` Hash, and then transferring ownership of its st table into `self`. - - For empty Hashes, we can skip allocating this `tmp`, because there's nothing to re-hash. We can just modify our new st table's `type` in-place. - -commit 893fe30ef2b30525d932d6b1256f717cc60b3311 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-19 01:56:01 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-12-19 04:44:44 +0900 - - [PRISM] Fix crash when --parser=prism called with stdin - - [Bug #20071] - - Currently Ruby crashes when the --parser=prism flag is used either with - no input, or with input that is being redirected from stdin. So all of - the following will crash - - ruby --parser=prism - ruby --parser=prism < test_code.rb - cat test_code.rb | ruby --parser=prism - - This commit checks whether the input is assumed to be from stdin, and - then processes that as a file. - - This will fix the second and third case above, but will cause a slight - behavioural changes for the first case - Ruby will treat stdin as an - empty file in this case and exit, rather than waiting for data to be - piped into stdin. - -commit 4b125b70d8584c6ebf2971d588c5c8a106fffc05 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-19 04:36:54 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-19 04:36:55 +0900 - - [DOC] Copy Prism release notes to NEWS - -commit 71b7a24c244960a581ee881d48ed38f4188364be - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-19 04:11:50 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-19 04:11:50 +0900 - - [DOC] Clarify what is 3.2 - -commit 495a237ef35443361144ebc1bd81439c770e90e9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-19 03:50:06 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-19 03:50:14 +0900 - - [DOC] Note about yjit_alloc_size in NEWS - - It's a pretty useful feature in 3.3. - -commit 6c4b04de5cba36077f86b08d54c4c316f3df1d87 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-18 21:40:43 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-19 02:26:37 +0900 - - clear `sched->lock_onwer` at fork - - `sched->lock_owner` can be non-NULL at fork because the timer thread - can acquire the lock while forking. `lock_owner` information is for - debugging, so we only need to clear it at fork. - - I hope this patch fixes the following assertion failure: - ``` - thread_pthread.c:354:thread_sched_lock_:sched->lock_owner == NULL - ``` - -commit f35fec771047de15127c0e00d22b9eccd5487f51 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-13 00:19:56 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-19 00:37:21 +0900 - - Reset pinned_slots at the beginning of GC - - pinned_slots is not being reset every GC, which causes this assertion to - fail: - - ``` - Assertion Failed: gc.c:7076:gc_pin:GET_HEAP_PAGE(obj)->pinned_slots <= GET_HEAP_PAGE(obj)->total_slots - ``` - - This commit changes it to reset it at the beginning of every compaction - GC cycle. - -commit f6ad49b87c110b618632a4a258896e3f5673000b - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-12-18 21:16:20 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-12-18 21:42:02 +0900 - - Use #initialize instead of `initialize` in shape perf warning - - This is more consistent with other messages. - -commit b2fc1b054e9c1a04c20c696f6889b6143e9b8592 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-12-18 18:17:15 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-12-18 20:58:08 +0900 - - Update `BasicSocket#recv` documentation on return value - - Ref: https://github.com/ruby/ruby/pull/6407 - - [Bug #19012] - - `0` is now interpreted as closed connection an not an - empty packet, as these are very rare and pretty much - useless. - -commit 40fc9b070ca68e0bd1d57e4dd712172e2faeaa2b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-18 19:57:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-18 20:17:45 +0900 - - [DOC] No document for internal or debug methods - -commit baf1403fba01c36b44dbd7bc658fed748ee7bc1e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-18 19:52:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-18 20:17:45 +0900 - - [DOC] Show `PTY.getpty` as an alias of `PTY.spawn` - - `:nodoc:` directive does not work at method definition in C, and must - be at the implementation function. That is, there is no way to make - one method visible and another method sharing the implementation - invisible at the same time. - -commit 835f1461f7d34941c8163650eb94965533eba029 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-18 19:51:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-18 20:17:44 +0900 - - [DOC] Add document of IO::Buffer#hexdump - -commit e9b0b6015ea393af9771ca23f7493c388ef17858 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-18 19:46:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-18 20:17:44 +0900 - - [DOC] Add documents of constants for IO#wait event mask - -commit 494e6b54ab37355740f88500b75cb701339b7fd9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-18 19:43:52 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-18 20:17:44 +0900 - - [DOC] Add links from `File::Constants` in dir.c to `File` constants - - Due to the bug ruby/rdoc#1067, `rb_file_const` needs `Document-const` - directives. - -commit 9b00b2bfb290f90c572bd3d969dd1f3758ed6eea - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-18 19:42:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-18 20:17:44 +0900 - - [DOC] Add links from `File::Constants` to `File` constants - -commit a94f3f206e186b42f49475f003992f909ec1a314 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-18 14:43:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-18 20:17:44 +0900 - - [DOC] Added notes regarding `:nodoc:` in C code - -commit 9abaf00c070d00d880e05182bc1f0fba3eba8231 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-18 12:44:28 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-18 20:17:43 +0900 - - [DOC] documents of aliased methods - -commit ba1d1522d35a7dd2595603ead57cd0fa8b21ba8b - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-12-18 17:59:06 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-12-18 18:33:18 +0900 - - Make the SHAPE_TOO_COMPLEX performance warning more actionable - - As suggested by Mame, we should try to help users fix the issues - without having to lookup the meaning of the warning. - -commit e8064c6c2c317be78953b4d19226368580af0dca - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-18 14:16:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-18 14:17:19 +0900 - - Shorten the workflow name - - Looking at the name in the list, "Miscellaneous / Miscellaneous checks" - seems too verbose/repetitive. Let's make it "Misc / Miscellaneous checks". - -commit 83194aa27dcadb87a5669c05c8dc96149e8c11e2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-18 14:14:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-18 14:15:11 +0900 - - Make the check_misc job name more descriptive - - We're going to add check_misc as a required status check, and "checks" - was a bit too vague for matching the job name. - -commit d8978445ae6b9bc0827c55a3721de329ba441b78 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-18 13:45:09 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-18 13:45:09 +0900 - - Improve YJIT documentation for Ruby 3.3 (#9263) - -commit e14dddcaca6eb0a6e55c128ffdceb18681009c49 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-12-16 00:25:00 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-16 00:25:00 +0900 - - Tweak NEWS.md - - * Move `defined?(@var)` optimization into GC section - * Remove a trailing space. - -commit 0601bce6fc57cef5ae22a944b15b8e9fca1ef6ef - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-18 08:49:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-18 08:49:06 +0900 - - [DOC] Add Socket::ResolutionError documentation - -commit 71c4a9c38f67dd393d64b4f68110b742a59cf082 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-18 08:47:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-18 08:47:59 +0900 - - [DOC] Correct the location of Addrinfo document - - The document must be placed immediately before the class definition. - No other statements can be placed in between. - -commit e316128e3d3bdd245eb74344df5fa5c2a43eaaf7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-18 08:38:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-18 08:38:59 +0900 - - [DOC] Stop unintentional references to builtin or standard names - -commit 7bfa1c3dc911f5c36ac64d6b4f410e4f12a7d4ca - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-17 22:37:15 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-17 22:37:15 +0900 - - Revert "[DOC] Make undocumented socket constans nodoc" - - This reverts commit cbda94edd80b0f664eda927f9ce9405b2074633a, because - `:nodoc:` does not work for constants. - - In the case of `rb_define_const`, RDoc parses the preceeding comment - as in `"/* definition: comment */"` form. - -commit aab74eafdeca6173d82eccc97de628538ff0c6fd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-17 21:17:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-17 21:17:48 +0900 - - [DOC] Fix Travis-CI condition - - "Not document only" should be honored always. Also simplified repo - and branch conditions - -commit cbda94edd80b0f664eda927f9ce9405b2074633a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-17 20:17:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-17 20:17:45 +0900 - - [DOC] Make undocumented socket constans nodoc - -commit 557d929ba699f3f30fd17290d42f331f5551a794 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-17 20:17:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-17 20:17:05 +0900 - - [DOC] Utilize COMMENTS.default_proc to add fallback documents - -commit d7d10f3ee85ecd1a1d59a60b8c35d85602250d87 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-17 06:45:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-17 06:45:33 +0900 - - Adjust rubygems style - -commit 8db0de92a8454b449efb243f380f5d2b68c38d7c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-17 06:39:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-17 06:39:16 +0900 - - Restore tracked_files for ruby core repo - -commit ab7f54688b495b3218843e58992b713c3b28011f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-17 00:30:00 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-17 00:30:00 +0900 - - Stir the hash value more with encoding index - -commit 40113454b1362554dee83454df76e5892999247f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 20:40:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 21:02:45 +0900 - - Use regex instead of hard coded paths - -commit ab87cd0baa884797b608013de24ab645cd38999f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 19:00:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 21:02:45 +0900 - - We don't use tracked_files in before(:suite). It breaks with release package. - -commit ad2a38dce4ac2e28c825080f4724d0ffed805e16 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 16:55:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 17:36:47 +0900 - - Added simple test script - -commit 83bdf127b8ddbb64c941bb9c467c686140b1696b - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-12-16 15:52:20 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 17:34:45 +0900 - - Avoid warning when requiring bigdecimal/util when bigdecimal is in gemfile - -commit 6f6b36b7e47d29ff8bc33918265a8bb4148109e8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 16:39:31 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 16:44:34 +0900 - - Added test for sub-feature like bigdecimal/util - -commit b710f96b5aaeb6c153e4b1a7e1b46c4521214126 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-16 13:48:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-16 16:00:12 +0900 - - [Bug #20068] Encoding does not matter to empty strings - -commit dd49ee152ba4153f5c4cf44896975cf1e0ee739e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 15:41:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 15:41:43 +0900 - - Use minimum arguments for Bootsnap - -commit 582862754fbbcc521e3d660eba6bfb566abf1bc2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 14:50:20 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 14:51:34 +0900 - - [ruby/io-console] Bump up v0.7.1 - - https://github.com/ruby/io-console/commit/8ac766d870 - -commit 80d63fbea57ca5369901ee51fda1577a9ec605e0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 14:48:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 14:49:13 +0900 - - [ruby/readline] Bump up v0.0.4 - - https://github.com/ruby/readline/commit/7dbc5bd8d9 - -commit cb636fe7075a260e4d47327764924a3ad10b502a - Author: hogelog <konbu.komuro@gmail.com> - AuthorDate: 2023-12-07 01:05:53 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 14:49:12 +0900 - - [ruby/readline] Fix readline-ext gem loading in non Unix-like environments - - https://github.com/ruby/readline/commit/6e1e5d0eb8 - -commit 20fbdae5fe3d3fa98d4f2fb8c5c8895a238576e5 - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-11-29 02:00:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 14:47:04 +0900 - - [ruby/reline] Bump version to 0.4.1 - (https://github.com/ruby/reline/pull/612) - - https://github.com/ruby/reline/commit/8937279e0f - -commit 4fd3c85acdfa942d88d8e9e2ccd17b8030c2c3b2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 14:20:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 14:20:55 +0900 - - [ruby/ipaddr] Bump up v1.2.6 - - https://github.com/ruby/ipaddr/commit/247459faa5 - -commit 8936bb74c66e68f44d2a18564ea0b0d5e290cc6e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 14:02:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 14:06:47 +0900 - - [ruby/abbrev] Bump up v0.1.2 - - https://github.com/ruby/abbrev/commit/b362e8e3b9 - -commit 3b6828f9679ac2a8cd26d9e68fa042b9c4452d0a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 14:05:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 14:06:37 +0900 - - [ruby/syslog] Bump up v0.1.2 - - https://github.com/ruby/syslog/commit/f7b29e2199 - -commit 2b3fc0407a9b9527ae5bf8069943661a061ec0ba - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 13:09:34 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 13:10:38 +0900 - - [ruby/securerandom] Bump up v0.3.1 - - https://github.com/ruby/securerandom/commit/890d659970 - -commit 6a79e53823e328281b9e9eee53cd141af28f8548 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 13:00:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 13:00:59 +0900 - - Rollback to released version numbers of stringio and strscan - -commit 1a244730a9fada79fbfc1b2f478c2fd8fc108e4a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 12:46:34 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 12:48:49 +0900 - - [ruby/open3] Bump up v0.2.1 - - https://github.com/ruby/open3/commit/b890922205 - -commit 6c7c4ac407c4eb2f70cd599c78808c5cd10b9c13 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 12:39:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 12:42:30 +0900 - - [ruby/rdoc] Bump up v6.6.2 - - https://github.com/ruby/rdoc/commit/895f1affc0 - -commit d242e8416e99eaee4465e2681210ae8b7ecd6d34 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 12:05:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 12:08:51 +0900 - - Revert all of commits after Prism 0.19.0 release - - We should bundle released version of Prism for Ruby 3.3.0 - -commit 711e85674e7c98909f5a43b7852ddc763beaa744 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-16 11:13:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 11:13:35 +0900 - - Pin versions that are RubyGems 2.5.1 and Bundler 2.5.1 - -commit f4e9336d4347e1086eb00494f90650cf6fde3be0 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-12-15 18:40:34 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 11:13:20 +0900 - - Partly pick commit from https://github.com/rubygems/rubygems/pull/7285 - - Refactor vendoring to allow validating vendoring is reproducible - - Helps ensure that unsuspecting diffs to the vendored code arent accidentally introduced - -commit d5af5a48a59dffdd0b156d58167e31109d19c491 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-16 01:59:29 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 11:09:50 +0900 - - Fix Sinatra warning during specs - - Some specs now print the following warning: - - ``` - /path/to/bundler/tmp/1/gems/base/ruby/3.2.0/gems/sinatra-2.0.8.1/lib/sinatra/base.rb:902: warning: constant Tilt::Cache is deprecated - ``` - - Updating sinatra to latest & greatest fixes it. - - Update other deps too since at it. - -commit 7cd4282cc8b4e8b242f082d806549d87964c4f8c - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-14 21:32:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 11:07:52 +0900 - - [rubygems/rubygems] Fix Bundler daily CI - - A default Bundler copy with vendored net-http is causing a Bundler spec - to end up loading that copy instead of the copy of Bundler under test. - This is because of vcr, but we don't really need vcr in the command - that's failing, so I avoided loading it. - - https://github.com/rubygems/rubygems/commit/304ab6e1b9 - -commit 0ff34aa13e9340871d5aeb339b5d86c52c7c2ca6 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-15 00:50:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 11:07:05 +0900 - - [rubygems/rubygems] More improves to default gem home selection for installation - - https://github.com/rubygems/rubygems/commit/966daf7d42 - -commit 299eb8d1179ed7bea49c50b0fa003bf0724f6fb4 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-15 02:43:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 11:06:07 +0900 - - [rubygems/rubygems] Improve command suggestion when gems are missing - - Previous attempt to use a full path when the running version is - different than the one that would be activated by default are different - was not correct. - - This is because if this error happens in a `bundle exec` context, the - `Gem.loaded_specs` is cleared because we're in an exec'd process, so - will be always using a full path in these cases. - - This alternative approach should do what I was expecting. - - https://github.com/rubygems/rubygems/commit/e0bb8bf51b - -commit c8e9cd2b8b65e58e48d4ca14203c5a5d08a2d728 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-16 01:02:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-16 11:04:38 +0900 - - [rubygems/rubygems] Fix Ruby DSL no longer working as expected - - https://github.com/rubygems/rubygems/commit/f6258e5679 - - Co-authored-by: AndrewSwerlick <andrew.swerlick@gmail.com> - -commit b8074c2f043d99f6f30ab75ad21cc2c998f49dcf - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-16 01:32:10 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-16 06:23:06 +0900 - - [PRISM] Fix incorrect instructions for `default_proc=` - - This is kind of specific and was found via debugging ruby/prism#2061 but - does not actually fix that issue. - - The change here checks for `!popped` for the additional instructions - that are normally added for nodes with the `attribute_write` flag. - - I also removed the extra catch table by deleting the - `ISEQ_COMPILE_DATA(iseq)->catch_except_p = true;` line. I'm...not - entirely sure why it was added but it doesn't match the upstream - compiler - [code](https://github.com/ruby/ruby/blob/92b10f5be7453aceb5863e46ac775a4ddbf83b97/compile.c#L887-L892). - - The changes here unfortunately don't improve the test failures mentioned in - the linked issue so we still have other issues with instructions for - hashes. - - Instructions before: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(34,8)> - local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - [ 1] h@0 - 0000 putnil ( 32)[Li] - 0001 putobject true - 0003 getconstant :Hash - 0005 send <calldata!mid:new, argc:0, ARGS_SIMPLE>, nil - 0008 setlocal h@0, 0 - 0011 getlocal h@0, 0 ( 33)[Li] - 0014 putspecialobject 1 - 0016 send <calldata!mid:lambda, argc:0, FCALL>, block in <compiled> - 0019 send <calldata!mid:default_proc=, argc:1, ARGS_SIMPLE>, nil - 0022 pop - 0023 getlocal h@0, 0 ( 34)[Li] - 0026 putobject :nope - 0028 send <calldata!mid:[], argc:1, ARGS_SIMPLE>, nil - 0031 leave - - == disasm: #<ISeq:block in <compiled>@<compiled>:33 (33,19)-(33,32)> - local table (size: 2, argc: 2 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - [ 2] _@0<Arg> [ 1] _@1<Arg> - 0000 putobject true ( 33)[LiBc] - 0002 leave [Br] - true - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:31 (31,0)-(33,8)> - local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - [ 1] h@0 - 0000 putnil ( 31)[Li] - 0001 putobject true - 0003 getconstant :Hash - 0005 send <calldata!mid:new, argc:0, ARGS_SIMPLE>, nil - 0008 setlocal h@0, 0 - 0011 putnil ( 32)[Li] - 0012 getlocal h@0, 0 - 0015 putspecialobject 1 - 0017 send <calldata!mid:lambda, argc:0, FCALL>, block in <compiled> - 0020 setn 2 - 0022 send <calldata!mid:default_proc=, argc:1, ARGS_SIMPLE>, nil - 0025 pop - 0026 pop - 0027 getlocal h@0, 0 ( 33)[Li] - 0030 putobject :nope - 0032 send <calldata!mid:[], argc:1, ARGS_SIMPLE>, nil - 0035 leave ( 31) - - == disasm: #<ISeq:block in <compiled>@<compiled>:32 (32,17)-(32,32)> - == catch table - | catch type: redo st: 0000 ed: 0002 sp: 0000 cont: 0000 - | catch type: next st: 0000 ed: 0002 sp: 0000 cont: 0002 - |------------------------------------------------------------------------ - local table (size: 2, argc: 2 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - [ 2] _@0<Arg> [ 1] _@1<Arg> - 0000 putobject true ( 32)[LiBc] - 0002 leave [Br] - ``` - - Instructions after: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(34,8)> - local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - [ 1] h@0 - 0000 putnil ( 32)[Li] - 0001 putobject true - 0003 getconstant :Hash - 0005 send <calldata!mid:new, argc:0, ARGS_SIMPLE>, nil - 0008 setlocal h@0, 0 - 0011 getlocal h@0, 0 ( 33)[Li] - 0014 putspecialobject 1 - 0016 send <calldata!mid:lambda, argc:0, FCALL>, block in <compiled> - 0019 send <calldata!mid:default_proc=, argc:1, ARGS_SIMPLE>, nil - 0022 pop - 0023 getlocal h@0, 0 ( 34)[Li] - 0026 putobject :nope - 0028 send <calldata!mid:[], argc:1, ARGS_SIMPLE>, nil - 0031 leave - - == disasm: #<ISeq:block in <compiled>@<compiled>:33 (33,19)-(33,32)> - local table (size: 2, argc: 2 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - [ 2] _@0<Arg> [ 1] _@1<Arg> - 0000 putobject true ( 33)[LiBc] - 0002 leave [Br] - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:31 (31,0)-(33,8)> - local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - [ 1] h@0 - 0000 putnil ( 31)[Li] - 0001 putobject true - 0003 getconstant :Hash - 0005 send <calldata!mid:new, argc:0, ARGS_SIMPLE>, nil - 0008 setlocal h@0, 0 - 0011 getlocal h@0, 0 ( 32)[Li] - 0014 putspecialobject 1 - 0016 send <calldata!mid:lambda, argc:0, FCALL>, block in <compiled> - 0019 send <calldata!mid:default_proc=, argc:1, ARGS_SIMPLE>, nil - 0022 pop - 0023 getlocal h@0, 0 ( 33)[Li] - 0026 putobject :nope - 0028 send <calldata!mid:[], argc:1, ARGS_SIMPLE>, nil - 0031 leave ( 31) - - == disasm: #<ISeq:block in <compiled>@<compiled>:32 (32,17)-(32,32)> - local table (size: 2, argc: 2 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - [ 2] _@0<Arg> [ 1] _@1<Arg> - 0000 putobject true ( 32)[LiBc] - 0002 leave [Br] - ``` - -commit 161787f9beef96c9fa1057b6378fe7e048ac2ecd - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-16 05:07:49 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-16 06:15:10 +0900 - - [PRISM] Compile CallTargetNode - -commit 5b6a4d8c1253fd1ab77c0539d33276fe1856cf24 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-14 06:09:39 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-16 06:15:10 +0900 - - [PRISM] Compile IndexTargetNode - -commit b9542246c92109b9639ee9976ac16f54a8759cfc - Author: Gopal Patel <nixme@stillhope.com> - AuthorDate: 2023-12-16 04:32:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-16 06:14:58 +0900 - - [ruby/prism] Fix majority of RBS type mismatches - - https://github.com/ruby/prism/commit/62cc50e41b - -commit 2e8cfcac9129ed8680c4b916bc5b4c535ae6e8c8 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-16 03:44:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-16 05:55:13 +0900 - - [ruby/prism] String literal hash keys should be frozen - - String literal hash keys can't be mutated by the user so we should mark - them as frozen. We were seeing instructions for hashes with string - literal keys using two `putstring` instructions when it should be a - `putobject` and `putstring`. - - Code example: - - ```ruby - { "a" => "b" } - ``` - - Instructions before: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(2,14)> - 0000 putobject "a" ( 2)[Li] - 0002 putstring "b" - 0004 newhash 2 - 0006 leave - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(1,14)> - 0000 putstring "a" ( 1)[Li] - 0002 putstring "b" - 0004 newhash 2 - 0006 leave - ``` - - Instructions after: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(2,14)> - 0000 putobject "a" ( 2)[Li] - 0002 putstring "b" - 0004 newhash 2 - 0006 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(1,14)> - 0000 putobject "a" ( 1)[Li] - 0002 putstring "b" - 0004 newhash 2 - 0006 leave - ``` - - https://github.com/ruby/prism/commit/b14ae55385 - -commit 9c9e6d5b91f23c15357d88036382d68ae3c77d97 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-16 04:39:31 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-16 04:45:25 +0900 - - [DOC] NEWS entries for C APIs - -commit f933cde9390563160d8a12c901e7a408f523c457 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-16 03:30:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-16 04:36:24 +0900 - - [rubygems/rubygems] Let the guards have some space to breathe - - https://github.com/rubygems/rubygems/commit/73f1609715 - -commit d9b39093e2bac70f121e38f4354a6a58c1b245a3 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-15 05:42:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-16 04:36:24 +0900 - - [rubygems/rubygems] Use a mutex around Checksum::Store @store access - - Not wrapping to_lock since access to it is single threaded and - read-only at the time of writing the lockfile. - - https://github.com/rubygems/rubygems/commit/3b53aa1b12 - -commit 1cfe874ef83cdb7776ecf892c470af634532501c - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-15 05:41:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-16 04:36:24 +0900 - - [rubygems/rubygems] Remove test-only & unused methods from Checksum::Store - - https://github.com/rubygems/rubygems/commit/79636dec12 - -commit 0a31cb1a37f184daa7c2839abd6a827793fdd2f3 - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-12-16 03:03:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-16 03:45:36 +0900 - - [ruby/prism] Finish keyword hash node flag refactor by renaming flag - - https://github.com/ruby/prism/commit/7f812389f8 - -commit b418e5a5800513da7204c0ba7b3a95a2d9ee9a7e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-16 03:18:40 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-16 03:42:19 +0900 - - Update error message in test_rubyoptions - -commit a604fe42620735f7bd1145e01bdca5398231ffb0 - Author: Adam Hess <HParker@github.com> - AuthorDate: 2023-12-15 07:40:37 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-16 03:42:19 +0900 - - update message to clarify compiler, not parser - - Co-authored-by: Ufuk Kayserilioglu <ufuk@paralaus.com> - -commit 55326a915f25608be1d40ab32baa9fc57762615d - Author: HParker <HParker@github.com> - AuthorDate: 2023-12-08 08:47:36 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-16 03:42:19 +0900 - - Introduce --parser runtime flag - - Introduce runtime flag for specifying the parser, - - ``` - ruby --parser=prism - ``` - - also update the description: - - ``` - $ ruby --parser=prism --version - ruby 3.3.0dev (2023-12-08T04:47:14Z add-parser-runtime.. 0616384c9f) +PRISM [x86_64-darwin23] - ``` - - [Bug #20044] - -commit 655c02790ee5aca122d3593fadab5b41a42a1899 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-12-16 03:32:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-16 03:32:32 +0900 - - [DOC] RDoc for Complex (#9254) - -commit 92b10f5be7453aceb5863e46ac775a4ddbf83b97 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-16 01:07:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-16 02:11:51 +0900 - - [Bug #20062] Fixed numbered parameter syntax error - - At the method definition, the local scope that saves the context of - the numbered parameters needs to be pushed before saving. - -commit 1ac0afab4da1986d6eefd421ca3877afd47d2a77 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-12-16 01:08:34 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-12-16 01:48:43 +0900 - - rb_bug_for_fatal_signal: exit with the right signal - - `die()` calls `abort()` which always exit as it `SIGABRT` - was received. - - This isn't very friendly with systems that automatically - collect crashes as the `%s` parameter will be changed. - -commit c9a9b8036c71974ab938a8bb3d6f095d4a318a8e - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-15 18:25:12 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-16 01:00:01 +0900 - - remove `Ractor::Selector` from Ruby level - - `Ractor::Selector` is not approved by Matz so remove it from - Ruby-level. - - The implementation is used by `Ractor.select` so most of implementation - was remaind and calling `rb_init_ractor_selector()`, `Ractor::Selector` - will be defined. I will provide `ractor-selector` gem to try it. - -commit 9b4cb69a88163340cac7c0a350eaf18832edb28f - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-15 18:59:54 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-16 01:00:01 +0900 - - support `skip` in bootstraptest - -commit 5a66ea23d2c244bac5d87a08939419cd300cf4cc - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-12-14 11:10:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-16 00:32:56 +0900 - - [rubygems/rubygems] Use mkdir_p helper in bundler.rb - - Small refactor, no functional change - - https://github.com/rubygems/rubygems/commit/5edb7a1026 - -commit 474b4c42f4d1c36d94548548e03f6649f2119f67 - Author: HParker <HParker@github.com> - AuthorDate: 2023-12-15 05:03:00 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-16 00:31:15 +0900 - - free ractors with ractor_free - - Previously with RUBY_FREE_ON_EXIT, ractors where being xfree-ed which is incorrect since they are not xmalloced. - Instead we can free ractors with ractor free during shutdown. This change only effects main ractor freeing when RUBY_FREE_ON_EXIT is set. - - Co-authored-by: John Hawthorn <john@hawthorn.email> - -commit 049a9bd62f0907caa8d2eca6337cd2542a5c7726 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-14 02:49:37 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-16 00:27:44 +0900 - - [PRISM] Fix `compile_prism` when src is a file - - `compile_prism` can take a source and file (and other arguments) or a - file as the source. `compile` checks if the source is a file and if it - is converts it. `compile_prism` is now doing the same thing. - - On the Ruby side `compile` handles a file - [here](https://github.com/ruby/ruby/blob/master/iseq.c#L1159-L1162). - - Before: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(26,21)> - local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - [ 1] name@0 - 0000 putstring "Prism" ( 25)[Li] - 0002 setlocal name@0, 0 - 0005 putself ( 26)[Li] - 0006 putobject "hello, " - 0008 getlocal name@0, 0 - 0011 dup - 0012 objtostring <calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE> - 0014 anytostring - 0015 concatstrings 2 - 0017 send <calldata!mid:puts, argc:1, FCALL|ARGS_SIMPLE>, nil - 0020 leave - hello, Prism - - "********* PRISM *************" - ./test.rb:13:in `compile_prism': wrong argument type File (expected String) (TypeError) - from ./test.rb:13:in `<main>' - make: *** [run] Error 1 - ``` - - After: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(26,21)> - local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - [ 1] name@0 - 0000 putstring "Prism" ( 25)[Li] - 0002 setlocal name@0, 0 - 0005 putself ( 26)[Li] - 0006 putobject "hello, " - 0008 getlocal name@0, 0 - 0011 dup - 0012 objtostring <calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE> - 0014 anytostring - 0015 concatstrings 2 - 0017 send <calldata!mid:puts, argc:1, FCALL|ARGS_SIMPLE>, nil - 0020 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@test_code.rb:24 (24,0)-(25,21)> - local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - [ 1] name@0 - 0000 putstring "Prism" ( 24)[Li] - 0002 setlocal name@0, 0 - 0005 putself ( 25)[Li] - 0006 putobject "hello, " - 0008 getlocal name@0, 0 - 0011 dup - 0012 objtostring <calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE> - 0014 anytostring - 0015 concatstrings 2 - 0017 send <calldata!mid:puts, argc:1, FCALL|ARGS_SIMPLE>, nil - 0020 leave ( 24) - ``` - - Fixes ruby/prism#1609 - -commit 20f4f007644b841c71402a5ae64ee5373dc7b91a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-15 19:36:07 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-16 00:26:39 +0900 - - [ruby/rdoc] [DOC] nodoc for probably internal methods - - https://github.com/ruby/rdoc/commit/f7dd147a8c - -commit e15d690db147fb059a48f87bf639fdf0c006a22b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-15 19:35:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-16 00:26:37 +0900 - - [ruby/rdoc] [DOC] Add missing documents - - https://github.com/ruby/rdoc/commit/e4c90340d0 - -commit 578eb02b16218ce842a30bf794bf52a68e680a38 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-15 19:26:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-16 00:25:53 +0900 - - [ruby/rdoc] Require fileutils before using it - - https://github.com/ruby/rdoc/commit/edb2523018 - -commit b257181ccc9cf46cfcbe085083f3ebffcd8abf09 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-15 19:20:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-16 00:25:51 +0900 - - [ruby/rdoc] Remove unused method `RDoc::Encoding.remove_frozen_string_literal` - - https://github.com/ruby/rdoc/commit/7a8e9a97fa - -commit f38814564b1c8d9394ae4568fb0dfd2bbbfe3440 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-16 00:07:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-16 00:19:50 +0900 - - [ruby/prism] Fix eval parsing depth - - https://github.com/ruby/prism/commit/89bf7a4948 - -commit fe9b42f024eb3724b0853c914916ea7a97fd30a6 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-15 22:48:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-16 00:03:49 +0900 - - [ruby/prism] Invalid pinned locals in pattern matching - - https://github.com/ruby/prism/commit/3a67b37a56 - -commit 1cd4b59e8cf56850a87a56194e7096db63f40204 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-12-14 11:11:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-15 23:53:10 +0900 - - [rubygems/rubygems] Save array allocation for every dependency in Gemfile - - Only need to check for lack of git key when branch option is present - - https://github.com/rubygems/rubygems/commit/ebfca1b389 - -commit ca7f7c0f516512c7e5b19aa74e05939b27bb37e4 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-12-15 18:40:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-15 23:48:25 +0900 - - [rubygems/rubygems] Refactor vendoring to allow validating vendoring is reproducible - - Helps ensure that unsuspecting diffs to the vendored code arent accidentally introduced - - https://github.com/rubygems/rubygems/commit/7c425d49dd - -commit 10a0545b6e0a4ed5eee1edff725f7955b2f26914 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-12-15 23:39:12 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-15 23:39:12 +0900 - - [DOC] RDoc for Complex (#9243) - -commit 7cbc08b388cfc6d9bd2023c313165bff37ba2c11 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-15 21:49:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-15 22:37:38 +0900 - - Follow removed conflict files - - After editing a conflict, continue without removed files. - -commit 854ff25f4f4a0c1183b742bd5077985236348c57 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-15 22:26:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-15 22:26:40 +0900 - - [ruby/prism] Add TODO comment - - https://github.com/ruby/prism/commit/885d1d78cb - -commit 16830a47830d6e780b7ce649f0247bdddd32f51d - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-11 12:29:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-15 22:25:54 +0900 - - [ruby/prism] Add an error for `in` keyword in arguments - - Fix https://github.com/ruby/prism/pull/2026 - - https://github.com/ruby/prism/commit/c4b41cd477 - -commit 04f7be612625a51523c7ae546a8774aea1a8fa12 - Author: Satoshi Tagomori <tagomoris@gmail.com> - AuthorDate: 2023-12-15 15:57:51 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-15 21:36:27 +0900 - - loading/testing in different processes for multiple runs - -commit 7c72755da8577947f564aeb264a201f62b032996 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-15 06:59:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-15 20:52:38 +0900 - - [rubygems/rubygems] Fix `ruby setup.rb` leaving traces in source folder - - It's the `Gem::Installer` below what installs executables, and the code - being deleted here is now actually creating a `gems/` folder in the root - of the source repo when running `ruby setup.rb`. - - https://github.com/rubygems/rubygems/commit/0e69a8b0d6 - -commit 4d5bfa7c3b3f21ed32f32542d66922d0481004bb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-15 15:39:14 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-15 15:39:14 +0900 - - Ignore the spcial case of target_cpu - - On Windows, x86_64 is called as x64. - -commit 2c2c6bc3fac34b7dd7ecafd08c7f12fc47988799 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-15 15:19:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-15 15:19:16 +0900 - - Fix `ARCH_FLAG` when cross-compiling on macOS - -commit 1e5c4026d5c75e6867f6e97de0aeaea55e62d26b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-15 14:10:02 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-15 14:10:02 +0900 - - Fix `ARCH_FLAG` when `--with-arch` with single CPU - -commit cc9aeec23e260a42fea9bf27835331ff76d24c4a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-15 15:14:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-15 15:14:48 +0900 - - Explained about test_for_warn_bundled_gems - -commit c3ae4b6ae12546a1b5adb33f8789a7bddd4739f1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-15 15:06:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-15 15:06:53 +0900 - - Revert "[Bug #20060] Properly return matched gem name in case of EXACT" - - This reverts commit 75c40802cb06d83fc2c3d0eca6d904fa41307230. - - This change is now working correctly with warning cases. - -commit 8df46d54bf9722ed0ab84f24e5fa48fe2fecfdd5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-15 14:49:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-15 15:05:13 +0900 - - Added test case of dash gem like net-smtp - -commit 9a204fb82e36dc30fc86827234e99ca6f55d442c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-15 14:48:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-15 15:05:13 +0900 - - Added test case of bootsnap - -commit 25a133ba17a0025451befecd4008b18de2c1e190 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-15 14:40:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-15 15:05:13 +0900 - - Added test case of bundle exec - -commit 66b82a4430a38dbbee0b69896743b5eed4c5badd - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-15 14:37:39 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-15 15:05:13 +0900 - - Added test case of bundled gems dependencies - -commit 76c1ce4e379535ed92ebc2197563b36bfd8b2beb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-15 14:34:56 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-15 15:05:13 +0900 - - Added basic test case of bundled gems warning - -commit 8e37cd8a8bd2263c66243a35f25b5e741635c893 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-15 00:02:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-15 15:04:36 +0900 - - Fix gem detection for names with dash - -commit b562efdf6d23d056764b334764a030eb72ea91a9 - Author: Shugo Maeda <shugo@ruby-lang.org> - AuthorDate: 2023-12-15 12:57:03 +0900 - Commit: Shugo Maeda <shugo@ruby-lang.org> - CommitDate: 2023-12-15 12:57:03 +0900 - - Bump up bundled net-ftp gem version to 0.3.3 - -commit 406d4bb59905903cf7b9fa62c2d590e963edda5c - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-15 11:21:39 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-15 11:58:43 +0900 - - add a test - - proposed at https://bugs.ruby-lang.org/issues/20050#note-5 - -commit 7ba2506232d3fa6c4e82e3708c0ff746a1a8de5c - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-15 03:42:40 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-15 11:58:43 +0900 - - check modifcation while ar->st - - * delete `ar_try_convert` but use `ar_force_convert_table` - to make program simple. - * `ar_force_convert_table` checks hash modification while - calling `#hash` method with the following strategy: - - 1. copy keys (and vals) of ar_table - 2. calc hashes from keys - 3. check copied keys and hash's keys. if not matched, repeat from 1 - - fix [Bug #20050] - -commit 29e99c84ae8059cd308cf1c06be05f62c55cd68d - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-12-15 11:44:13 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-15 11:44:13 +0900 - - Remove unused variables in test_call_op_asgn_keywords_mutable - -commit b98bd10f255d0afe33ba3c4410dd2c05c61695fb - Author: Satoshi Tagomori <tagomoris@gmail.com> - AuthorDate: 2023-12-15 10:38:33 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-15 11:09:31 +0900 - - stop warnings from running the test case requiring .so twice - -commit cfd91121ad71655ef9cea48450a0027a00a46f8f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-15 10:24:06 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-15 10:24:08 +0900 - - Trigger auto-request-review only for master branch - -commit 68020516bab1b885942450c48a9708ea2f726f68 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-15 08:55:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-15 08:55:15 +0900 - - [DOC] Reverse-merge YJIT release notes to NEWS - -commit 5587bd4b37cc01227ce5546b3350033bb1ef9775 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-15 06:44:38 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-15 07:11:54 +0900 - - [PRISM] Implement safe navigation in CallNodes - - This commit implements safe navigation for CallNodes, - CallAndWriteNodes and CallOperatorWriteNodes - -commit 39c072d6f7846a99f64e52090a320576715325c5 - Author: Victor Shepelev <zverok.offline@gmail.com> - AuthorDate: 2023-12-15 06:33:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-15 06:33:33 +0900 - - [DOC] Enhance docs for WeakMap and WeakKeyMap (#9160) - - Enhance docs for WeakMap and WeakKeyMap - - * WeakKeyMap: more class-level explanations, more details - on #getkey, fix a slight bug in code of #delete example; - * WeekMap: a bit more detailed class- and method-level docs. - -commit 570d7b2c3e2ee39e07548dfe242b684ec794789d - Author: Victor Shepelev <zverok.offline@gmail.com> - AuthorDate: 2023-12-15 06:01:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-15 06:01:48 +0900 - - [DOC] Adjust some new features wording/examples. (#9183) - - * Reword Range#overlap? docs last paragraph. - - * Docs: add explanation about Queue#freeze - - * Docs: Add :rescue event docs for TracePoint - - * Docs: Enhance Module#set_temporary_name documentation - - * Docs: Slightly expand Process::Status deprecations - - * Fix MatchData#named_captures rendering glitch - - * Improve Dir.fchdir examples - - * Adjust Refinement#target docs - -commit d3deb1b8232a303dd40909e32f939bad3b24a8af - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-15 05:25:54 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-15 05:26:01 +0900 - - [prism] Fix build with no asserts - -commit 8bbe835cd872a3af411cb6a950e2751c02060f3f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-15 05:06:09 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-15 05:06:09 +0900 - - Bump prism to version 0.19.0 - -commit d07fdc5edee219bbbd6262f909d636a509793cca - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-12-15 03:15:30 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-15 04:08:37 +0900 - - [PRISM] Fix keyword hash handling in method calls - - * Start using the renamed `PM_KEYWORD_HASH_NODE_FLAGS_SYMBOL_KEYS` flag - to check if all keys of the keyword hash node are symbols. - * For arguments passed as a hash, start marking them as `KW_SPLAT_MUT` only if the number of entries in the hash is greater than 1 (which is what the old compiler used to do). - -commit 295d97ab4dc826a4c2b812d254a6607c87534ed7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-14 01:34:05 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-15 04:06:26 +0900 - - Pattern matching - -commit 019fff3a8656cadad93ba8d6db476428bd8d7a5e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-15 02:48:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-15 03:54:46 +0900 - - [ruby/prism] Fix parse result for nesting pattern matching - - https://github.com/ruby/prism/commit/ee6fc9ee87 - -commit 5a66832952fa1ee971406b797605f72cead6e9c4 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-15 02:20:24 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-15 03:48:38 +0900 - - [Prism] Fix cvar or assignment instructions - - The instructions for `PM_CLASS_VARIABLE_OR_WRITE_NODE` were incorrect as - they were missing a `putnil`, a `defined`, and a `branchunless`. - - I verified this is fixed via the instructions and running the following: - `RUBY_ISEQ_DUMP_DEBUG=prism make test/csv/interface/test_read_write.rb`. - - These new instructions can't go in the defined function because - `defined?(@@fop ||= 1)` should return "assignment" not "class variable". - - Instructions before: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(30,11)> - 0000 putnil ( 30)[Li] - 0001 defined class variable, :@@foo, true - 0005 branchunless 14 - 0007 getclassvariable :@@foo, <is:0> - 0010 dup - 0011 branchif 20 - 0013 pop - 0014 putobject 1 - 0016 dup - 0017 setclassvariable :@@foo, <is:0> - 0020 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:29 (29,0)-(29,11)> - 0000 getclassvariable :@@foo, <is:0> ( 29)[Li] - 0003 dup - 0004 branchif 13 - 0006 pop - 0007 putobject 1 - 0009 dup - 0010 setclassvariable :@@foo, <is:0> - 0013 leave - ``` - - Instructions after: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(30,11)> - 0000 putnil ( 30)[Li] - 0001 defined class variable, :@@foo, true - 0005 branchunless 14 - 0007 getclassvariable :@@foo, <is:0> - 0010 dup - 0011 branchif 20 - 0013 pop - 0014 putobject 1 - 0016 dup - 0017 setclassvariable :@@foo, <is:0> - 0020 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:29 (29,0)-(29,11)> - 0000 putnil ( 29)[Li] - 0001 defined class variable, :@@foo, true - 0005 branchunless 14 - 0007 getclassvariable :@@foo, <is:0> - 0010 dup - 0011 branchif 20 - 0013 pop - 0014 putobject 1 - 0016 dup - 0017 setclassvariable :@@foo, <is:0> - 0020 leave - ``` - - Fixes ruby/prism#2064 - -commit 7ac93e99a3db30ed41cbbe95df1d7be9a790b9cb - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-14 02:17:22 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-15 03:45:41 +0900 - - [PRISM] Account for multiple anonymous locals - - This commit adjusts the local table size to be consistent regardless - of the number of anonymous locals. - -commit 01f21d57297f1e6820a6a374ccf9c432c6178038 - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-12-14 07:14:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-15 03:05:54 +0900 - - [ruby/prism] Fix the implementation of the flag on keyword hash nodes - - The previous implementation was incorrect since it was just checking for all keys in assoc nodes to be static literals but the actual check is that all keys in assoc nodes must be symbol nodes. - - This commit fixes that implementation, and, also, aliases the flag to `PM_KEYWORD_HASH_NODE_FLAGS_SYMBOL_KEYS` so that ruby/ruby can start using the new flag name. - - I intend to later change the real flag name to `PM_KEYWORD_HASH_NODE_FLAGS_SYMBOL_KEYS` and remove the alias. - - https://github.com/ruby/prism/commit/f5099c79ce - -commit c5e3d6da9cc7199128218711b89df45c8bf7c6f1 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-14 04:09:27 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-15 02:22:38 +0900 - - Implement Write Barriers on IO::Buffer - - Benchmark: - - ``` - require "benchmark" - - puts(Benchmark.measure do - ary = 1_000_000.times.map { IO::Buffer.for("") } - - 10.times { GC.start(full_mark: false) } - end) - ``` - - Before: - - ``` - 14.330119 0.051497 14.381616 ( 14.445106) - ``` - - After: - - ``` - 7.481152 0.040166 7.521318 ( 7.535209) - ``` - -commit 157e6c8a512968dc9f82d7f81606eeb3266cf6bb - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-14 20:58:50 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-15 01:46:54 +0900 - - [PRISM] Check for static literal, excluding array, hash, range - -commit e71f0117137c30db1dd694aa2c91c82174fa05df - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-14 06:41:45 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-15 01:46:54 +0900 - - [PRISM] Fix bugs in compiling optional keyword parameters - - This PR fixes two bugs when compiling optional keyword parameters: - - It moves keyword parameter compilation to STEP 5 in the parameters - sequence, where the rest of compilation happens. This is important - because keyword parameter compilation relies on the value of - body->param.keyword->bits_start which gets set in an earlier step - - It compiles array and hash values for keyword parameters, which - it didn't previously - -commit 3658798dbb60fe55beaebc157ba43c8fe617c4a0 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-15 01:30:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-15 01:39:05 +0900 - - [ruby/prism] Make equality operators non-associative - - Fix https://github.com/ruby/prism/pull/2073 - - https://github.com/ruby/prism/commit/0f747d9240 - -commit 8e1c148fd90b2c32044ef310a0a312bca89c6fea - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-15 00:19:31 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-15 01:14:45 +0900 - - [PRISM] Use frozen flag on StringNode - -commit a18819e65fa2dd3135909df81534937dadafb6ab - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-12-13 09:48:26 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-15 01:13:43 +0900 - - Fix op asgn method calls passing mutable keyword splats - - When passing the keyword splat to [], it cannot be mutable, because - mutating the keyword splat inside [] would result in changes to the - keyword splat passed to []=. - -commit 247ce712fcf93d28ceb359b66dfcf8f76e2c731d - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-12-15 01:09:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-15 01:09:17 +0900 - - [DOC] RDoc for Complex (#9231) - -commit a79a1d30289b326c8b6c6deb00f1431c693a4b50 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-14 22:16:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-15 00:04:22 +0900 - - [rubygems/rubygems] Upgrade vendored libraries - - To match the versions that will be included in final ruby release. - - https://github.com/rubygems/rubygems/commit/84394919fb - -commit 912016f626fab3e79e3ef8d9da53d1b148c8b5bf - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-14 04:25:19 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-14 22:52:32 +0900 - - Call obj_free for T_DATA, T_FILE objects on exit - - Previously, T_DATA and T_FILE objects did not have their instance - variables freed on exit which would be reported as a memory leak with - RUBY_FREE_ON_EXIT. This commit changes it to use obj_free which also - frees the generic instance variables. - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - -commit e3631277c37861d5e99fbefd8bd3eeefc0120825 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-14 21:13:29 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 21:22:49 +0900 - - Removed duplicated LICENSE files - -commit 612616925b3d5247748b8df98a13a70f74f8b4c3 - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-12-09 00:38:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 21:22:49 +0900 - - [rubygems/rubygems] Allow "default_user_install" to be overridden. - - For Ruby re-distributors, automatic user-install might be the right - default. Therefore printing warning about installing into user directory - is not always desirable. Let the default_user_install method be - customizable. - - https://github.com/rubygems/rubygems/commit/2320dba544 - -commit 45b511433d652c46d5652ab295367f41341697af - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 22:42:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 21:22:48 +0900 - - [rubygems/rubygems] Improve install advice when some gems are not found - - This problem is quite specific to our dev environment, but I guess the - fix could be handy for other situations. - - After merging a change to treat default gems as regular gems, I get this - when trying to run `rubocop` on our repo: - - ``` - $ bin/rubocop --only Performance/RegexpMatch - Could not find json-2.6.3 in locally installed gems - Run `bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb` to install missing gems. - ``` - - However, when running the suggested command, nothing changes and I still - get the same error: - - ``` - $ bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb - Using ast 2.4.2 - Using bundler 2.4.10 - Using json 2.6.3 - Using parallel 1.23.0 - Using racc 1.7.1 - Using parser 3.2.2.3 - Using rainbow 3.1.1 - Using regexp_parser 2.8.1 - Using rexml 3.2.5 - Using rubocop-ast 1.29.0 - Using ruby-progressbar 1.13.0 - Using unicode-display_width 2.4.2 - Using rubocop 1.52.1 - Using rubocop-performance 1.14.2 - Bundle complete! 2 Gemfile dependencies, 14 gems now installed. - Use `bundle info [gemname]` to see where a bundled gem is installed. - - $ bin/rubocop --only Performance/RegexpMatch - Could not find json-2.6.3 in locally installed gems - Run `bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb` to install missing gems. - ``` - - The problem is that our `bin/rubocop` script uses the development - version of Bundler (which has the change causing the problem), but the - advice recommands the default version of Bundler, which does not yet - have the change. - - This commit changes the advice to recommend to use the same version of - Bundler that run into the problem in the first place. - - So in the above situation you now get: - - ``` - $ bin/rubocop --only Performance/RegexpMatch - Could not find json-2.6.3 in locally installed gems - Run `/Users/deivid/code/rubygems/rubygems/bundler/exe/bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb` to install missing gems. - ``` - - And running that fixes the problem: - - ``` - $ /Users/deivid//rubygems/rubygems/bundler/exe/bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb - Fetching gem metadata from https://rubygems.org/......... - Fetching json 2.6.3 - Installing json 2.6.3 with native extensions - Bundle complete! 2 Gemfile dependencies, 14 gems now installed. - Use `bundle info [gemname]` to see where a bundled gem is installed. - ``` - - https://github.com/rubygems/rubygems/commit/10a9588c6d - -commit d718654bb1b6b440b664fe6f35424360b13bab6e - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 05:32:17 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 21:22:48 +0900 - - [rubygems/rubygems] Remove extension building sync stuff no longer present in RubyGems - - https://github.com/rubygems/rubygems/commit/59a85388b9 - -commit 41095f4de058c1a9d571c3c7e745c748d6c07cbc - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 05:49:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 21:22:48 +0900 - - [rubygems/rubygems] RubyGems > 3.2.0.rc.1 is now always provided - - https://github.com/rubygems/rubygems/commit/929b521f3a - -commit 778438d423dac10d1a63f826cfc4dc18ca4c0b66 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 05:28:57 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 21:22:48 +0900 - - [rubygems/rubygems] Gem::Specification always has `default_stubs` now - - https://github.com/rubygems/rubygems/commit/30db1eb4a5 - -commit 5cf6f7f8859a0418bbbe2b608a88557d4f06e098 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 05:21:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 21:22:48 +0900 - - [rubygems/rubygems] Remove more methods now defined in all RubyGems versions - - https://github.com/rubygems/rubygems/commit/e015200ffa - -commit 7564038864bcf7c3cfb2f602e318e9beae17b2f7 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 05:17:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 21:22:48 +0900 - - [rubygems/rubygems] Remove check only necessary for ancient RubyGems - - https://github.com/rubygems/rubygems/commit/ffa2f03489 - -commit 04dd2a8aae84f58009d230304029cf4af9a6d296 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 05:15:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 21:22:48 +0900 - - [rubygems/rubygems] This patch should be no longer needed - - https://github.com/rubygems/rubygems/commit/1139e90931 - -commit b45c1523a89133daa31c483e97f7d28593bb7b01 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 05:06:20 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 21:22:48 +0900 - - [rubygems/rubygems] Gem::Specification.find_all_by_name is always defined now - - https://github.com/rubygems/rubygems/commit/1d61c7686b - -commit b300f5a0e1b75dfd27d58890521a1085d44284b3 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-14 05:23:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 21:22:48 +0900 - - [rubygems/rubygems] Revert "Improve default gem handling" - - This reverts commit https://github.com/rubygems/rubygems/commit/091b4fcf2b99. - - https://github.com/rubygems/rubygems/commit/dcade3235f - -commit a10c11a66bae7ec4bfb56d0ccfe74a0c6681fc77 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-13 23:40:34 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-14 21:01:19 +0900 - - [PRISM] Add anon KW args to the block local table - -commit e51f9e9f75cc1dde9234836fa92077d71b3c5141 - Author: Satoshi Tagomori <tagomoris@gmail.com> - AuthorDate: 2023-12-08 15:06:12 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-14 17:39:42 +0900 - - rb_ext_resolve_symbol: C API to resolve and return externed symbols [Feature #20005] - - This is a C API for extensions to resolve and get function symbols of other extensions. - Extensions can check the expected symbol is correctly loaded and accessible, and - use it if it is available. - Otherwise, extensions can raise their own error to guide users to setup their - environments correctly and what's missing. - -commit 8a37df8c8bc0311c4822ee989087d212af2bf73f - Author: Satoshi Tagomori <tagomoris@gmail.com> - AuthorDate: 2023-12-07 20:38:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-14 17:39:42 +0900 - - dln_symbol: make dln_sym accessible Ruby internally - - The symbol resolved by dln_symbol will eventually be passed to - extensions. The error handling of dln_sym is also separated into - dln_sym_func because the new call resolving symbols will not raise - LoadError. - -commit 1b1d5e757e81ec243062a8919ddc76d017c34a54 - Author: Shugo Maeda <shugo@ruby-lang.org> - AuthorDate: 2023-12-14 16:38:39 +0900 - Commit: Shugo Maeda <shugo@ruby-lang.org> - CommitDate: 2023-12-14 16:38:39 +0900 - - Bump up bundled net-ftp gem version to 0.3.2 - -commit 26145a27f6b960bd607cdd2f9680eba14f84ac1a - Author: Shugo Maeda <shugo@ruby-lang.org> - AuthorDate: 2023-12-14 15:51:12 +0900 - Commit: Shugo Maeda <shugo@ruby-lang.org> - CommitDate: 2023-12-14 15:51:12 +0900 - - Bump up bundled net-ftp gem version to 0.3.1 - -commit b7e89d4b175a88be333134066b595d1e34c33fd3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-14 11:35:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-14 11:43:32 +0900 - - [ruby/prism] Fix hash pattern rest - - https://github.com/ruby/prism/commit/43c4232cfc - -commit beefce1444adafac484bb69b625de2b30e7e80d2 - Author: Drew Stevenson <drew@soona.co> - AuthorDate: 2023-12-01 13:35:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-14 09:06:05 +0900 - - [rubygems/rubygems] Warn for duplicate meta data links - - Match order of METADATA_LINK_KEYS to order used by rubygems.org in Links model. - Add missing download_uri key. - - https://github.com/rubygems/rubygems/commit/d2922cd6e9 - -commit d7dad644658697a05949b66e736a34fb772771de - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-13 13:57:02 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-14 08:26:52 +0900 - - Unlock freelist before assigning - - Co-authored-by: Matthew Draper <matthew@trebex.net> - -commit c1f4bfd41fa7e1fa23ef6803349ac009debdf61f - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-14 06:46:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-14 07:50:45 +0900 - - [rubygems/rubygems] Revert "Merge pull request #7167 from nevinera/add-json-output-option-to-bundle-outdated" - - This reverts commit https://github.com/rubygems/rubygems/commit/a4ac5116b8ea, reversing - changes made to https://github.com/rubygems/rubygems/commit/8a6b180d0ae5. - - https://github.com/rubygems/rubygems/commit/a1efe4015d - -commit 5a0cbc934428b3babdce6f5d014c30afcb84e567 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-13 16:38:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 07:48:08 +0900 - - Detect bootsnap from all frames - -commit 8b0c62696203daba815fa4e6d1c08dc143b3cc04 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-12 16:04:49 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 07:48:08 +0900 - - Skip warning feature with Bootsnap - - Bootsnap modified full feature path to require. We can't handle it for - warning correctly. - -commit 75c40802cb06d83fc2c3d0eca6d904fa41307230 - Author: Akira Matsuda <ronnie@dio.jp> - AuthorDate: 2023-12-14 02:30:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-14 07:47:56 +0900 - - [Bug #20060] Properly return matched gem name in case of EXACT - - this follows up 4e6861d3376eb7857d2b0a947c97b6fec8e5bf37 - -commit baf2ec2ca8127cd610a3681a1e84ebcb404fe8f2 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-12-13 20:46:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-14 07:00:26 +0900 - - [rubygems/rubygems] Use match? when regexp match data is unused - - Improved performance / reduced allocations - - https://github.com/rubygems/rubygems/commit/b04726c9a7 - -commit b266890dab38d12ad52288d5edf60f885ae5b8ce - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-14 06:29:37 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-14 06:29:37 +0900 - - YJIT: Add --yjit-disable to help and reorder it (#9230) - -commit 7f4b271a61a11b0254304b78db72fd2c954a4370 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-14 04:15:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-14 05:28:37 +0900 - - [rubygems/rubygems] Store Checksum::Store indexed by spec.lock_name - - https://github.com/rubygems/rubygems/commit/34d6c6c72f - -commit 14c7895c21bee44934336a9a9ea94aefc5cc7879 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-14 04:50:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-14 04:50:35 +0900 - - Fix a typo in yjit.md - -commit 31c0ea20e5492925ac971991937e30524da5043d - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-12-13 08:47:07 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-14 04:15:09 +0900 - - [PRISM] Add a test with a non-static-literal hash key - -commit 6aa26af683616cf908f0251dbb8ffde380e0c314 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-12-13 22:01:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-14 04:02:24 +0900 - - [rubygems/rubygems] Add 3.4 as a supported ruby version - - Since ruby trunk will be 3.4 very soon - - https://github.com/rubygems/rubygems/commit/36dd9a35dc - -commit 110dbf62acc307ea2e3ce57ddaa89fc734a715c5 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-13 05:52:53 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-14 03:42:17 +0900 - - [Prism] Fix InterpolatedMatchLastLine Instructions - - I looked at this at RubyConf with Kevin, and we noticed that there was a - `putobject` empty string missing from the instructions. I just got back - around to implementing this and pushing a PR and while doing that - noticed that we also have a `getspecial` when we want a `getglobal`. - - This change adds the `putobject` instruction and replaces the - `getspecial` with a `getglobal`. If we look at the parsetree for the - following code: - - ```ruby - $pit = '.oo'; if /"#{$pit}"/mix; end - ``` - - We can see it has a `NODE_GVAR` and the [Ruby - compiler](https://github.com/ruby/ruby/blob/a4b43e92645e46ee5a8c9af42d3de57cd052e87c/compile.c#L10024-L10030) shows that should - use `getglobal. - - ``` - @ NODE_SCOPE (id: 14, line: 1, location: (1,0)-(22,36)) - +- nd_tbl: (empty) - +- nd_args: - | (null node) - +- nd_body: - @ NODE_BLOCK (id: 12, line: 22, location: (22,0)-(22,36)) - +- nd_head (1): - | @ NODE_GASGN (id: 0, line: 22, location: (22,0)-(22,12))* - | +- nd_vid: :$pit - | +- nd_value: - | @ NODE_STR (id: 1, line: 22, location: (22,7)-(22,12)) - | +- nd_lit: ".oo" - +- nd_head (2): - @ NODE_IF (id: 11, line: 22, location: (22,14)-(22,36))* - +- nd_cond: - | @ NODE_MATCH2 (id: 10, line: 22, location: (22,14)-(22,36)) - | +- nd_recv: - | | @ NODE_DREGX (id: 2, line: 22, location: (22,17)-(22,31)) - | | +- nd_lit: "\"" - | | +- nd_next->nd_head: - | | | @ NODE_EVSTR (id: 4, line: 22, location: (22,19)-(22,26)) - | | | +- nd_body: - | | | @ NODE_GVAR (id: 3, line: 22, location: (22,21)-(22,25)) - | | | +- nd_vid: :$pit - | | +- nd_next->nd_next: - | | @ NODE_LIST (id: 7, line: 22, location: (22,26)-(22,27)) - | | +- as.nd_alen: 1 - | | +- nd_head: - | | | @ NODE_STR (id: 6, line: 22, location: (22,26)-(22,27)) - | | | +- nd_lit: "\"" - | | +- nd_next: - | | (null node) - | +- nd_value: - | @ NODE_GVAR (id: 9, line: 22, location: (22,14)-(22,36)) - | +- nd_vid: :$_ - +- nd_body: - | @ NODE_BEGIN (id: 8, line: 22, location: (22,32)-(22,32)) - | +- nd_body: - | (null node) - +- nd_else: - (null node) - ``` - - I'm struggling with writing a failing test, but the before/after - instructions show that `getglobal` is correct here. I compared the - instructions for the other `InterpolatedMatchLastLine` node tests - and they also used `getglobal`. I've edited the existing - `InterpolatedLastMatchLineNode` test so that it will use that instruction when - copied out of the test. Without the quotes it thinks it's just a - `MatchLastLineNode`. - - Incorrect instructions: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(22,36)> - 0000 putstring ".oo" ( 22)[Li] - 0002 setglobal :$pit - 0004 putobject "\"" - 0006 getglobal :$pit - 0008 dup - 0009 objtostring <calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE> - 0011 anytostring - 0012 putobject "\"" - 0014 toregexp 7, 3 - 0017 getglobal :$_ - 0019 send <calldata!mid:=~, argc:1, ARGS_SIMPLE>, nil - 0022 branchunless 30 - 0024 jump 26 - 0026 putnil - 0027 jump 31 - 0029 pop - 0030 putnil - 0031 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:21 (21,0)-(21,36)> - 0000 putstring ".oo" ( 21)[Li] - 0002 setglobal :$pit - 0004 putobject "\"" - 0006 getglobal :$pit - 0008 dup - 0009 objtostring <calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE> - 0011 anytostring - 0012 putobject "\"" - 0014 toregexp 7, 3 - 0017 getspecial 0, 0 - 0020 send <calldata!mid:=~, argc:1, ARGS_SIMPLE>, nil - 0023 branchunless 31 - 0025 jump 27 - 0027 putnil - 0028 jump 32 - 0030 pop - 0031 putnil - 0032 leave - ``` - - Fixed instructions: - - ``` - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(22,36)> - 0000 putstring ".oo" ( 22)[Li] - 0002 setglobal :$pit - 0004 putobject "\"" - 0006 getglobal :$pit - 0008 dup - 0009 objtostring <calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE> - 0011 anytostring - 0012 putobject "\"" - 0014 toregexp 7, 3 - 0017 getglobal :$_ - 0019 send <calldata!mid:=~, argc:1, ARGS_SIMPLE>, nil - 0022 branchunless 30 - 0024 jump 26 - 0026 putnil - 0027 jump 31 - 0029 pop - 0030 putnil - 0031 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:21 (21,0)-(21,36)> - 0000 putstring ".oo" ( 21)[Li] - 0002 setglobal :$pit - 0004 putobject "\"" - 0006 getglobal :$pit - 0008 dup - 0009 objtostring <calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE> - 0011 anytostring - 0012 putobject "\"" - 0014 toregexp 7, 3 - 0017 getglobal :$_ - 0019 send <calldata!mid:=~, argc:1, ARGS_SIMPLE>, nil - 0022 branchunless 30 - 0024 jump 26 - 0026 putnil - 0027 jump 31 - 0029 pop - 0030 putnil - 0031 leave - ``` - -commit ea4a4c302cf1733ce6c84ffb641ab2c43846f7de - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-14 03:28:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-14 03:28:20 +0900 - - [PRISM] Fix a -Wformat-zero-length warning - - ../prism_compile.c: In function ‘pm_compile_node’: - ../prism_compile.c:2330:20: warning: zero-length gnu_printf format string [-Wformat-zero-length] - 2330 | rb_bug(""); - | ^~ - -commit 02528f647d4d217a574eb2518dbb925c937dded6 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-13 11:34:14 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-14 03:20:11 +0900 - - [PRISM] Use xcalloc for iseq id table - - We use xfree on the other end, so we need to use a form of xmalloc here. - - Co-authored-by: Matthew Draper <matthew@trebex.net> - -commit b55de590f3344dcedaafba8bcf2a249c9f0c4fc5 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-13 11:32:18 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-14 03:20:11 +0900 - - [PRISM] Fix st_table memory leak - - Co-authored-by: Matthew Draper <matthew@trebex.net> - -commit a3b48ac9ad8a5d4eb7ae6c3d4fe9d040361daa7a - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-14 02:11:49 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-12-14 02:43:09 +0900 - - Fix memory leak in Hash#compare_by_identity - - We didn't free the old ST before overwriting it which caused a leak. - Found with RUBY_FREE_ON_EXIT. - - Co-authored-by: Peter Zhu <peter@peterzhu.ca> - -commit cc86fa8416b571e2d833157b852dee31a0d2f731 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-14 02:38:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-14 02:40:54 +0900 - - Skip an unstable test on MinGW - - This test fails fairly frequently on MinGW: - https://github.com/ruby/ruby/actions/runs/7195712496/job/19598924253#step:11:168 - https://github.com/ruby/ruby/actions/runs/7191246799/job/19585627182#step:11:168 - - and we aren't actively working on stabilizing tests for MinGW. - -commit 0f1c7e3bcb2ee0cb38d228ba0d23f52ceef5623c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-14 02:36:06 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-14 02:36:06 +0900 - - RJIT: Just skip generating code for aarch64/arm64 (#9221) - -commit c83a648fc827ac1430bd1f08f5af19f7174e02aa - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-12-14 02:05:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-14 02:05:35 +0900 - - [ruby/irb] Remove unused lvar in mesure command test - (https://github.com/ruby/irb/pull/814) - - https://github.com/ruby/irb/commit/320178b120 - -commit a4b43e92645e46ee5a8c9af42d3de57cd052e87c - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 21:03:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-14 00:47:43 +0900 - - [rubygems/rubygems] Add missing resolv, timeout, and net-protocol licenses - - https://github.com/rubygems/rubygems/commit/00694651a3 - -commit f8ddcecbdf34b8d33ed4311b34d498d4ff380a3e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-13 00:45:59 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-14 00:39:06 +0900 - - [Bug #20061] Clear mark bits when rb_free_on_exit - - When compiling with cppflags=-DRGENGC_CHECK_MODE, the following crashes: - - ``` - $ RUBY_FREE_ON_EXIT=1 ./miniruby -e 0 - -e: [BUG] obj_free: RVALUE_MARKED(0x0000000103570020 [3LM ] T_CLASS (anon)) != FALSE - ``` - - This commit clears the mark bits when rb_free_on_exit is enabled. - -commit 0d53dba7ce900387397610c060cfa24758fc806a - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-12-13 09:58:20 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-14 00:05:21 +0900 - - Make String#chomp! raise ArgumentError for 2+ arguments if string is empty - - String#chomp! returned nil without checking the number of passed - arguments in this case. - -commit c42e4a38e9839fe3380566727304f3fd75a6506a - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-12-09 09:39:41 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-14 00:05:21 +0900 - - Fix tool/ln_sr.rb passing 2 arguments to String#chomp! - - I'm guessing String#sub! was desired here. - -commit 9eba7a08920102747eb9dceeedd8d7c080515aac - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-12 07:35:13 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-13 23:33:07 +0900 - - [PRISM] Break nodes should add an entry to the parent catch table - -commit cb8a9851ca4e78795900cde2fb1147ec3a1192d7 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-12 00:33:52 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-13 23:33:07 +0900 - - [PRISM] Remove errant NOP when redo_label is set - -commit 9267dbdd7ad1f41116a89c2ce044b776274afc44 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-12 00:27:46 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-13 23:33:07 +0900 - - [PRISM] Generate instruction for when redo_label is set - -commit f390c51b15c470590a416d0def51ea1cca1bd74b - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-12-13 08:37:50 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-13 22:16:11 +0900 - - [PRISM] Use `PM_KEYWORD_HASH_NODE_FLAGS_STATIC_KEYS` flag in compiler - -commit 798a89fae1d7da1c0dd4282e9e16ab8bbf993b55 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-13 05:56:03 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-13 22:11:45 +0900 - - [PRISM] If receiver on CallNode is SelfNode, use FCALL flags - -commit 1ad991c54d7d890527050a54899265da21a677c2 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-13 04:24:00 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-13 22:11:21 +0900 - - [PRISM] Fix attrset edge cases - - In some cases code may look like an attrset ID but should actually - return the value of the method, not the passed values. - - In ruby/prism#2051 a flag was added when we have a attribute write call. - I used this flag to add the proper instructions when we have a real - attrset instead of using `rb_is_attrset_id` which was kind of hacky - anyway. - - The value that should be returned in the newly added test is 42, not 2. - Previously the changes we had made returned 2. - - Related to ruby/prism#1715 - -commit 36ca99b343ee8847beb4b7e0be112f75af64109f - Author: Alex Koval <al3xander.koval@gmail.com> - AuthorDate: 2023-12-13 19:39:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 21:17:57 +0900 - - [ruby/prism] fix typo in docs - - https://github.com/ruby/prism/commit/d7fbc09345 - -commit 745ab3e4c748ebf3b22278d7ad33c7abcf1f6016 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-12-13 20:06:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 20:06:26 +0900 - - [ruby/irb] Warn and do nothing if block is passed to measure command - (https://github.com/ruby/irb/pull/813) - - https://github.com/ruby/irb/commit/e79a90a1e6 - -commit a7ad9f38367b729d49db78e7cbe13922d3ff70ee - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-13 16:18:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 17:30:48 +0900 - - We need only one line for detecting caller gem name - -commit e282d7b880c3ac394ad8d41bde858c4534fb3188 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-13 17:05:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-13 17:05:12 +0900 - - Avoid warning --jit when only YJIT is enabled - -commit 75f4a687ed54e3b1863ba1767c666a0bea809c8a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-13 16:28:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-13 16:28:22 +0900 - - Fix a typo for `RJIT_TARGET_OK` (#8222) - -commit 20a09387d163b6d4ec77d1859f1cac480991ce9e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-13 16:24:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-13 16:24:19 +0900 - - Skip a GC test for RJIT - - It randomly fails like this: - https://github.com/ruby/ruby/actions/runs/7191443542/job/19586164973 - -commit 5f5f8dbbb6a7861e9c591ad09149944a5adf5a71 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-13 15:04:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 15:11:21 +0900 - - [ruby/resolv] Bump up 0.3.0 - - https://github.com/ruby/resolv/commit/22153c2a45 - -commit 39023792dbded9250040224accda18c0db14c5bc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-13 14:55:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 14:58:25 +0900 - - [ruby/io-console] Bump up 0.7.0 - - https://github.com/ruby/io-console/commit/3e5586e632 - -commit 06edde22f462f736c16ae9038b015fcdbd100716 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-13 14:42:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 14:42:58 +0900 - - [ruby/io-nonblock] Bump up 0.3.0 - - https://github.com/ruby/io-nonblock/commit/501e2ffea3 - -commit 5cabe1e9cc6829d1918c65bf29c4ba8217cc466d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-13 14:05:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 14:10:54 +0900 - - [ruby/io-wait] Bump up 0.3.1 - - https://github.com/ruby/io-wait/commit/5ec3db36c8 - -commit 12c775c94249b57dadfda0c2de9568398ae6cfd6 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-13 13:58:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 14:01:16 +0900 - - [ruby/etc] Bump up 1.4.3 - - https://github.com/ruby/etc/commit/743c26086d - -commit ac939d9ca3164a748c656ea7f33c356d7b91b0f9 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-11 21:19:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 13:02:22 +0900 - - [rubygems/rubygems] Improve default gem handling - - If a gem is specified in the Gemfile (or resolved as a transitive - dependency), it's always resolved from remote/installed sources. Default - gems are only used as a fallback for gems not included in the bundle. - - I believe this leads to more consistent behavior and more portable apps, - since all gems will be installed to the configured bundle path, - regardless of whether they are default gems or not. - - https://github.com/rubygems/rubygems/commit/091b4fcf2b - -commit 1a7aa5560f1a9967e320f71b7e8e8ee748151168 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-11 21:05:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 13:02:22 +0900 - - [rubygems/rubygems] Refactor `bundle info` - - https://github.com/rubygems/rubygems/commit/0e919eaa87 - -commit 70428247c673987c6613396f55a8ab5651d27fe4 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-11 20:41:58 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 13:02:21 +0900 - - [rubygems/rubygems] Remove dead code - - https://github.com/rubygems/rubygems/commit/fad186df39 - -commit 6b3c9cebe94cdd0d5f97877642689baed8a35327 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-08 07:59:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:59:23 +0900 - - Normalize bundler bindir - - This makes bundler consistent with all other gems, and makes the default - installation of Bundler in the release package look like any other - bundler installation. - - Before (on preview3, for example), Bundler executable is installed at: - - lib/ruby/gems/3.3.0+0/gems/bundler-2.5.0.dev/libexec/bundle - - Now it's installed in the standard location: - - lib/ruby/gems/3.3.0+0/gems/bundler-2.5.0.dev/exe/bundle - -commit 866b6fcd69c85cd00118324942886d92a3bb2a0f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-13 11:51:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - RubyGems 3.5+ will use vendored net-http - -commit 5015481e537ab3dd34c184ed4ef20521c5b4f43d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-13 11:28:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - Removed duplicated LICENSE file - -commit befbcfd90c4fbbdc3cc3fa3a083ff6868a2bfb02 - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-12-12 22:47:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Explain the 3 states `options[:user_install]` can have. - - This was issue previously, so hopefully this comment tries to state this - explicitly for future readers. - - https://github.com/rubygems/rubygems/commit/8ccd830f85 - -commit 1fa5dd883e286a768a9dfa82ef3de562fcdabd01 - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-12-12 22:37:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Test if the user dir is used for auto user installation - - This is mainly to align this test case with the - `test_process_options_does_not_fallback_to_user_install_when_gem_home_ - not_writable_and_no_user_install`, where the `install_dir` is checked - already. - - https://github.com/rubygems/rubygems/commit/02b1884b61 - -commit 402fd96ddc401cf35bced8d394c44df98d6fc466 - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-12-12 22:38:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Make sure `--no-user-install` is respected for auto user installation - - The `options[:user_install]` might have three states: - * `true`: `--user-install` - * `false`: `--no-user-install` and - * `nil`: option was not specified - - However, this had not been respected previously and the `false` and `nil` - were treated the same. This could lead to auto user installation despite - `--no-user-install` being specified on the command line. - - Fixes https://github.com/rubygems/rubygems/pull/7237 - - https://github.com/rubygems/rubygems/commit/9281545474 - -commit 844759ccdbf9400796259888d613597585ad697a - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 01:13:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Add a spec to cover what vendoring timeout fixes - - https://github.com/rubygems/rubygems/commit/2662e45d75 - -commit 5323935f5799772cf5d18e4e5a2dcce914b4c6bd - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 01:13:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Remove no longer needed gem install during test - - https://github.com/rubygems/rubygems/commit/bdb78d8289 - -commit 20d99a2f5fde15a21f1232078389ea83cb71cb33 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-05 01:49:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Resolv needs vendoring too - - https://github.com/rubygems/rubygems/commit/cdfc6923e4 - -commit f188a41afee554e46ea2125f22e7d989afc52be0 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-05 01:34:01 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Use vendored timeout from RubyGems - - https://github.com/rubygems/rubygems/commit/cfc5018c54 - -commit a7c9163b5d87c0420e54cd75668bceb8f39a578a - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-01 04:22:32 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Vendor timeout in RubyGems too - - https://github.com/rubygems/rubygems/commit/e2e7440ede - -commit 90317472e87692fff1c864d129d60130dc3bab2c - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-01-30 05:28:29 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Use vendored net-http in Bundler - - https://github.com/rubygems/rubygems/commit/0d758e8926 - -commit ce924ce1fb029f19fd34a43f2012a485f4f62b53 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-01-30 05:24:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Vendor net-http and net-protocol in RubyGems - - https://github.com/rubygems/rubygems/commit/99d91c9ed2 - -commit 6cefad77042ee3277488f56e8046c53f5313a82f - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-11 05:48:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Avoid loading artifice when not necessary - - https://github.com/rubygems/rubygems/commit/ef97ad37bd - -commit 7d5d2eef78d57bfac75b68c08e4bf5ce3d633a01 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-11 03:39:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Load hax.rb before anything when `BUNDLER_IGNORE_DEFAULT_GEM` set - - https://github.com/rubygems/rubygems/commit/111bd11c36 - -commit 8d1a2036643faecf55b9c09d6b788d1cd3b1f064 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-01-30 05:28:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-13 12:16:55 +0900 - - [rubygems/rubygems] Require `rubygems/request` where it's used - - https://github.com/rubygems/rubygems/commit/73b9498658 - -commit 196c24620e95e1c0412732cf14f1ccb441cf224f - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-13 03:40:05 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-13 12:00:50 +0900 - - [PRISM] Correctly parse non-base 10 integers in Prism - - This commit passes an `end` to rb_int_parse_cstr which allows us - to correctly parse non-base 10 integers which are enclosed in - parenthesis. Prior to this commit, we were getting a putobject nil - when compiling `(0o0)` for example. - -commit a2994c300b9620b0b226c8373f15627eead65d43 - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-12-12 08:57:26 +0900 - Commit: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - CommitDate: 2023-12-13 11:35:05 +0900 - - Add changelog entry for [Feature #20057] - -commit a8d2d93aff8d50adc914dfc24c09cfe28643501b - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-12-11 13:22:42 +0900 - Commit: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - CommitDate: 2023-12-13 11:35:05 +0900 - - Add a test case for preregistering with different data - - We want to make sure that if preregister is called with different data, - that the postponed job table is updated. - -commit 15d14e2f396c10366902aefaca99ee73c10cd556 - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-12-11 13:09:05 +0900 - Commit: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - CommitDate: 2023-12-13 11:35:05 +0900 - - Simplify implementation of tracepoint tests - - With the latest version of the postponed job patchset merged, we don't - actually need to go through the contortions of keeping the data in a - global variable; we can just update `data` with multiple calls to - rb_postponed_job_preregister. - -commit 4eefab592ac068acfd06fb9422f75a7786fbb855 - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-12-11 13:00:43 +0900 - Commit: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - CommitDate: 2023-12-13 11:35:05 +0900 - - Refactor local variable names in postponed_job methods - - Just removes the unneeded `prereg_` prefix from a few local var names. - -commit 626daa73ec244fa5a159dff31199bd336ec4ac8c - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-12-11 12:52:47 +0900 - Commit: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - CommitDate: 2023-12-13 11:35:05 +0900 - - Small doc improvements for rb_postponed_job API - -commit e96f6126f27c097d8148da143bb18edbe4180a61 - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-12-13 08:54:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 09:21:42 +0900 - - [ruby/prism] Fix hash deopt based on contents - - The previous implementation of hash deopt was based on clearing the static literal flag on a hash node if the element that was being added was an array, hash or range node, or if the element was not a static literal in the first place. - - However, this is not correct. First of all, the elements added to a hash node will primarily be assoc nodes, but never array, hash or range nodes. Secondly, the static literal flag is set on assoc nodes, only if the value in an assoc node is a static literal, so the key is never checked. As a result, the static literal flag on a hash node would never be cleared if the key wasn't a static literal. - - This commit fixes this by clearing the static literal flag if: - 1. the element is not an assoc node, - 2. the element is an assoc node, but the key is not a static literal, or - 3. the element is an assoc node, the key is a static literal, but assoc node (and thus the value in assoc node) is not a static literal. - - https://github.com/ruby/prism/commit/7f67109b36 - -commit 2350c7946275cd570cc1d7cd892abc16ac68a92c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-12 03:23:26 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-13 08:47:58 +0900 - - Use xfree for IO::Buffer - - Since IO::Buffer is allocated using TypedData_Make_Struct, it must use - xfree to free the buffer otherwise it will cause more major GC to run. - - Example: - - ``` - 10.times do - 1_000_000.times { IO::Buffer.new(0) } - - puts "oldmalloc_increase_bytes: #{GC.stat(:oldmalloc_increase_bytes)}, major_gc_count: #{GC.stat(:major_gc_count)}" - end - ``` - - Before: - - ``` - oldmalloc_increase_bytes: 14904176, major_gc_count: 3 - oldmalloc_increase_bytes: 2399424, major_gc_count: 5 - oldmalloc_increase_bytes: 5204640, major_gc_count: 6 - oldmalloc_increase_bytes: 2199936, major_gc_count: 7 - oldmalloc_increase_bytes: 34199936, major_gc_count: 7 - oldmalloc_increase_bytes: 24223360, major_gc_count: 8 - oldmalloc_increase_bytes: 5967616, major_gc_count: 9 - oldmalloc_increase_bytes: 37967616, major_gc_count: 9 - oldmalloc_increase_bytes: 9689792, major_gc_count: 10 - oldmalloc_increase_bytes: 41689792, major_gc_count: 10 - ``` - - After: - - ``` - oldmalloc_increase_bytes: 117392, major_gc_count: 2 - oldmalloc_increase_bytes: 26128, major_gc_count: 2 - oldmalloc_increase_bytes: 71600, major_gc_count: 2 - oldmalloc_increase_bytes: 117072, major_gc_count: 2 - oldmalloc_increase_bytes: 17296, major_gc_count: 2 - oldmalloc_increase_bytes: 62768, major_gc_count: 2 - oldmalloc_increase_bytes: 108240, major_gc_count: 2 - oldmalloc_increase_bytes: 153712, major_gc_count: 2 - oldmalloc_increase_bytes: 53936, major_gc_count: 2 - oldmalloc_increase_bytes: 99408, major_gc_count: 2 - ``` - -commit 18a5b6b7e9c06cc3205ee0d2681a2adf6a52baaa - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-12-13 06:05:19 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-13 07:32:59 +0900 - - [DOC] RDoc for Complex - -commit 9f77eb1f5a1e52a32b249abaef990e50c31e2ecc - Author: Alan Wu <alanwu@ruby-lang.org> - AuthorDate: 2023-12-13 07:24:17 +0900 - Commit: Alan Wu <alanwu@ruby-lang.org> - CommitDate: 2023-12-13 07:24:17 +0900 - - Remove unused macros - -commit d4bbee7475269972cf56ebd3b5e4dc9905789663 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-13 07:10:14 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-13 07:10:14 +0900 - - YJIT: Fix off-by-one in Kernel#send type handling (#9212) - - Previously, if the method ID argument happens to be on one below the top - of the stack, we didn't overwrite the type of the stack slot, which - leaves an incorrect type for the stack slot. The included script tripped - asserts both with and without --yjit-verify-ctx. - -commit 6e491cae5da769c38bfc88bc28aa1af8ec1705df - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-13 06:01:09 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-13 06:01:09 +0900 - - Move --repeat-count=2 job to macos-arm-oss (#9208) - -commit a6526342f3fbd94abc44cc4e99eda0943a61271f - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-13 03:44:33 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-13 05:15:02 +0900 - - [PRISM] Fix segv with regex once flag - - When you have an interpolated regex with a `once` flag and local - variable is outside the block created by the `once` flag, Prism would - see a segv. This is because it was not taking the depth into account. - - To fix this, we need to add 1 to the `local_depth_offset` on the - `scope`. - - Fixes: ruby/prism#2047 - -commit 1572322e17caf2f0900f02099d21245b81554a28 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 04:49:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-13 04:49:25 +0900 - - Sync with upstream rubygems (#9206) - -commit 0366c424e59b65fed953aa2148eaf14cb90bb6d3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-13 04:45:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-13 04:45:48 +0900 - - Remove a duplicated job - - This was first added in b481b673d75, but 197e91f357 added - -DUNIVERSAL_PARSER to the Compilers workflow as well. - - Given the nature of this test and the fact that it also runs make - test-all besides make test, I think it's better to keep only the - Compilers one. - -commit fd7decbf04f58438c04fa09fb325b16fbbec40c4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-13 04:19:00 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-13 04:19:02 +0900 - - Allow syncing tool/bundler - -commit 43ede3f26cda8c2a4dfbce9a44b0b6aa06281cd7 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-13 01:23:50 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-13 03:46:36 +0900 - - [PRISM] Compile NextNode arguments - -commit d1cf793adce7f797a3cd03594c539729c0099ec8 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-12-13 03:46:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 03:46:07 +0900 - - [ruby/irb] Remove documents about deprecated/WIP features and some - slight adjustments - (https://github.com/ruby/irb/pull/811) - - https://github.com/ruby/irb/commit/6a9193e88b - -commit b9dfe04a73b9b4b9a3d3e96a3418a8d105e5c63a - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-13 01:08:40 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-13 03:45:21 +0900 - - [PRISM] Implementing forwarding of args for ForwardingSuperNode - - ForwardingSuperNodes need to actually forward any applicable - arguments. This commit implements that logic, by using the data - stored on the local iseq about the parameters to forward the - appropriate arguments. - -commit 68753e44083f7d4d171f66aa092b35ccb41a66f6 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-12 23:40:16 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-13 03:45:21 +0900 - - [PRISM] Allow rest parameter to be `*` - - Prior to this commit, if a rest parameters was `*`, we did not add - it to the locals table correctly. This commit fixes that. - -commit f61df27b4ca73a31401ebe0357a3b7de947128e8 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-13 03:43:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 03:43:59 +0900 - - [ruby/prism] Use new flag setters for attribute write - - https://github.com/ruby/prism/commit/1e07832778 - -commit 06e2fbb8260022de8532d2e940fc69e8ea413679 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-11-22 18:12:23 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-12-13 02:36:37 +0900 - - [Bug #19114] Fix for multiple calls of TracePoint#enable - -commit 1f22245ed5004ef097e192aec157b34409214a2a - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-12-12 07:30:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 02:35:53 +0900 - - [ruby/prism] Start using flag macros/methods exclusively - - https://github.com/ruby/prism/commit/5f05a6fe83 - -commit bdb38dd9f22accfddc8d0a5e211c74b6a06faf51 - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-12-12 07:28:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 02:35:52 +0900 - - [ruby/prism] Add methods for setting/unsetting and macros for testing a flags - - https://github.com/ruby/prism/commit/e5f37d1407 - -commit 67940b135cae091f0f13d2c531b2ef33660e82fc - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-13 00:43:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 02:16:19 +0900 - - [rubygems/rubygems] Bump rake version used by tests - - And make it easier to update next time. - - https://github.com/rubygems/rubygems/commit/1ea4bfa5d8 - -commit 278ce27ee4063dec5b8967563d58e32ea087a380 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-13 00:39:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 00:55:54 +0900 - - [ruby/prism] Flag for attribute write on calls - - https://github.com/ruby/prism/commit/465731969c - -commit 2f1d6da8c45590bf3461ed4bf051a4e1009eaf85 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-12-13 00:34:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-13 00:34:53 +0900 - - Fix op asgn calls with keywords - - Examples of such calls: - - ```ruby - obj[kw: 1] += fo - obj[**kw] &&= bar - ``` - - Before this patch, literal keywords would segfault in the compiler, - and keyword splat usage would result in TypeError. - - This handles all cases I can think of: - - * literal keywords - * keyword splats - * combined with positional arguments - * combined with regular splats - * both with and without blocks - * both popped and non-popped cases - - This also makes sure that to_hash is only called once on the keyword - splat argument, instead of twice, and make sure it is called before - calling to_proc on a passed block. - - Fixes [Bug #20051] - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit f671c5d1791d14a44902cfe672ae6b457d1592e9 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-12 09:40:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-13 00:26:01 +0900 - - [rubygems/rubygems] Make RubyDsl a little easier to read; avoid a Hash sometimes - - https://github.com/rubygems/rubygems/commit/2dca83722b - -commit f466afa1768f437d5ee79444f35d65bc6e5374e8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-09 22:29:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-12 23:57:27 +0900 - - [PRISM] Do not hide syntactically required parentheses within macros - - It makes code formatters confused when auto indenting. - -commit 185b7e92a37548255fcc8c5ab08b72abeadaf74e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-09 05:18:07 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-12 23:01:21 +0900 - - Make WeakKeyMap safe for compaction during allocation - - During allocation, the table may not have been allocated yet which would - crash in the st_foreach. - -commit 33cf8f640bab35c463186ef0856689c22559fbeb - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-09 05:17:51 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-12 23:01:21 +0900 - - Make WeakMap safe for compaction during allocation - - During allocation, the table may not have been allocated yet which would - crash in the st_foreach. - -commit d313c82f797852037012138284d4e49fdaf284c4 - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-12-12 05:28:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 22:05:09 +0900 - - [ruby/prism] Update tests and snapshots - - https://github.com/ruby/prism/commit/0663e2bcfa - -commit 43229d531ff77cd9f8414e75141fcf54fafb22c4 - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-12-12 05:26:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 22:05:09 +0900 - - [ruby/prism] Start `KeywordHashNode`s with `STATIC_KEYS` set, until hit an element that should clear it - - https://github.com/ruby/prism/commit/7c7c486507 - -commit 25b9a0cbc86da562e765e4fac27bb28311646971 - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-12-12 05:26:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 22:05:08 +0900 - - [ruby/prism] Add `STATIC_KEYS` flag for `KeywordHashNode` - - https://github.com/ruby/prism/commit/aa83de39c1 - -commit d1c25605f671c85b1088cb8021d815a89b629dbf - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-12 08:31:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 21:40:17 +0900 - - [rubygems/rubygems] Resolve `ruby file: ".ruby-version"` relative to Gemfile - - https://github.com/rubygems/rubygems/commit/0cbbaed8a5 - -commit 28a9a4275ce334ed50a582d8c781b40ce46a74ec - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-12-12 20:27:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 20:27:39 +0900 - - [ruby/irb] Remove trailing space - - This is required to fix ruby/ruby's CI - - https://github.com/ruby/irb/commit/3c77213209 - -commit 35990cb38c0c77ddcd0b1f914b4fea5c13e12f39 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-12-12 19:34:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 19:34:38 +0900 - - [ruby/irb] [DOC] RDoc for module IRB - (https://github.com/ruby/irb/pull/738) - - [DOC] RDoc for module IRB - - https://github.com/ruby/irb/commit/f3a0626298 - -commit 25711e7063060920d14e42a530da6f7198926629 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-12-09 10:30:39 +0900 - Commit: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - CommitDate: 2023-12-12 18:05:21 +0900 - - Partially revert "Set AI_ADDRCONFIG when making getaddrinfo(3) calls" - - This _partially_ reverts commit - d2ba8ea54a4089959afdeecdd963e3c4ff391748, but for UDP sockets only. - - With TCP sockets (and other things which use `rsock_init_inetsock`), the - order of operations is to call `getaddrinfo(3)` with AF_UNSPEC, look at - the returned addresses, pick one, and then call `socket(2)` with the - family for that address (i.e. AF_INET or AF_INET6). - - With UDP sockets, however, this is reversed; `UDPSocket.new` takes an - address family as an argument, and then calls `socket(2)` with that - family. A subsequent call to UDPSocket#connect will then call - `getaddrinfo(3)` with that family. - - The problem here is that... - - * If you are in a networking situation that _only_ has loopback addrs, - * And you want to look up a name like "localhost" (or NULL) - * And you pass AF_INET or AF_INET6 as the ai_family argument to - getaddrinfo(3), - * And you pass AI_ADDRCONFIG to the hints argument as well, - - then glibc on Linux will not return an address. This is because - AI_ADDRCONFIG is supposed to return addresses for families we actually - have an address for and could conceivably connect to, but also is - documented to explicitly ignore localhost in that situation. - - It honestly doesn't make a ton of sense to pass AI_ADDRCONFIG if you're - explicitly passing the address family anyway, because you're not looking - for "an address for this name we can connect to"; you're looking for "an - IPv(4|6) address for this name". And the original glibc bug that - d2ba8ea5 was supposed to work around was related to parallel issuance of - A and AAAA queries, which of course won't happen if an address family is - explicitly specified. - - So, we fix this by not passing AI_ADDRCONFIG for calls to - `rsock_addrinfo` that we also pass an explicit family to (i.e. for - UDPsocket). - - [Bug #20048] - -commit f64485af7eb8a1bbaabbf59434592b6e6a0299d0 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-12-12 15:58:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 15:58:23 +0900 - - Update bundled gems list as of 2023-12-12 - -commit e411bd5b3684bfa5c654290059e9207a9596aad7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-12 14:41:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 15:40:44 +0900 - - [ruby/securerandom] [DOC] Satisfy RDoc coverage - - https://github.com/ruby/securerandom/commit/ddf2672e47 - -commit dbd704ae6f0e0fdcefa2007ce1c06f7021c8e830 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-12 14:11:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 15:40:43 +0900 - - [ruby/securerandom] [DOC] Add documents of methods and constants - - https://github.com/ruby/securerandom/commit/9a99978135 - -commit cb93d10ae559b0cf0f0935ddc1cc50dda65c6df8 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-12-12 15:35:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 15:36:10 +0900 - - [ruby/securerandom] [DOC] Improve the document about reproducibility of uuid_v7 - - https://github.com/ruby/securerandom/pull/19/files#r1329476195 - - https://github.com/ruby/securerandom/commit/156cbb8448 - -commit f49af3c969eb7ba9937514a229b49e5b7d91f0f1 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-12-12 10:34:52 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-12 15:31:16 +0900 - - Make Dir#chdir never yield args, and return block return value - - If no block is given, return 0 instead of nil for consistency - with Dir.chdir and Dir.fchdir. - -commit 9f0065a077f00a077f507461846234c52509ce90 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-12 14:12:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-12 14:12:08 +0900 - - Initialize interrupt queue before signal handlers (#9196) - -commit 1e5c8afb151c0121e83657fb6061d0e3805d30f6 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-12 10:16:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 11:39:57 +0900 - - [rubygems/rubygems] Ensure that the lockfile mtime is not altered on frozen install - - https://github.com/rubygems/rubygems/commit/6847709ee0 - -commit 6b3abcf4622c6ae39ddfd5b21c2387f177f82e0d - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2023-12-11 16:01:04 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2023-12-12 11:22:40 +0900 - - fix regexp pattern of diff - -commit e223dde3295cc59415c289305fd8d706d46cd2e9 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-31 07:21:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 11:10:53 +0900 - - [rubygems/rubygems] Allow bundle pristine to run in parallel - - Also fix running when BUNDLE_NO_INSTALL happens to be set, same as with install/update commands - - https://github.com/rubygems/rubygems/commit/a555fd6ccd - -commit 305f66b859c0fd123c95db74700d8b2c13fe2fe2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-12 11:06:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-12 11:06:27 +0900 - - Save $VERBOSE properly - -commit 73b43fffa163e11ce9e7e8880631acb870ac1695 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-12-12 10:31:14 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-12 10:31:37 +0900 - - Prevent a warning: assigned but unused variable - status - -commit 207dcf07e1e1359ca87590c8c22867024f20ae03 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-12-12 10:30:12 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-12 10:31:37 +0900 - - Prevent a warning: method redefined - -commit cfb8494d5473b3695ac40aa6a9891284603bfc89 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-12-12 10:29:26 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-12 10:31:37 +0900 - - Prevent warning: possibly useless use of a literal in void context - -commit 0c287df3bc4c1a7aed3279e20590ecf628722b4d - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-12-12 10:28:19 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-12 10:31:37 +0900 - - Prevent a warning: setting Encoding.default_external - -commit 535eb4de1109f5b8a8bde063dacc4c6fabf2322c - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-12-12 10:26:06 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-12 10:31:37 +0900 - - Remove unused statement - - ... to disable a warning: assigned but unused variable - expected - -commit 6414f260fc64878dc32f6899f5cecfac9908d26d - Author: Franz Liedke <franz@develophp.org> - AuthorDate: 2023-12-04 17:15:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 10:08:20 +0900 - - [rubygems/rubygems] Refactor: Wrap filesystem access - - https://github.com/rubygems/rubygems/commit/119d4bdc09 - -commit 0653fb026cd2203158b7af1e8b9608911dce2860 - Author: Franz Liedke <franz@develophp.org> - AuthorDate: 2023-12-03 04:03:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 10:08:20 +0900 - - [rubygems/rubygems] Refactor: Move filesystem access into Definition class - - https://github.com/rubygems/rubygems/commit/2720da2659 - -commit 0ec88b54f34ee0b0197f963ad6a98a2390a91de7 - Author: Franz Liedke <franz@develophp.org> - AuthorDate: 2023-12-03 03:54:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 10:08:19 +0900 - - [rubygems/rubygems] bundle lock: Always touch the lockfile - - https://github.com/rubygems/rubygems/commit/fd2e71dfdb - -commit 8c2480c9edf7d20505a8c3491ec84a3fdd77bd2e - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-12 05:30:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-12 10:04:57 +0900 - - Unlock tilt since we no longer support Ruby 2.6 - -commit a848c070d28fd8c836e3bf06c4b73cf7d293a290 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-12 05:31:37 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-12 10:04:57 +0900 - - [rubygems/rubygems] Remove doc not adding much value - - https://github.com/rubygems/rubygems/commit/c241a88962 - -commit 0e05392dccaaf4f9a0ce66228fd64dbd96b62227 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-09 04:25:23 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-12 10:04:57 +0900 - - [rubygems/rubygems] Make tests compatible with paths that contain a + char - - https://github.com/rubygems/rubygems/commit/3355c80c90 - -commit 3b9ea6648fcc110769c27686ebdc51fbbf1798c8 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-09 02:44:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-12 10:04:57 +0900 - - [rubygems/rubygems] Use StringIO 3.1.0 in tests to work with ruby 3.3.0 - - https://github.com/rubygems/rubygems/commit/8a936d733d - -commit 0b24c71a5a30a7d38976f6d0c20e71d9399adb02 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-08 07:25:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-12 10:04:57 +0900 - - [rubygems/rubygems] Improve enabling bundled gems warnings - - https://github.com/rubygems/rubygems/commit/7be5b40ca9 - -commit a06bf001b29bba77e71ba270f73469d9c9b4b0f0 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-07 22:51:22 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-12 10:04:57 +0900 - - [rubygems/rubygems] Remove non-transparent requirement added to prerelease gems - - I think we can safely assume these days that all RubyGems and Bundler - versions that will ever bundle a new gem created in 2023 support - prereleases. - - So this non transparent requirement is not necessary. - - In my opinion, it should be the gem author to explicitly add this - constraint, not RubyGems. - - https://github.com/rubygems/rubygems/commit/b165e6d725 - -commit b37288c047681e02615b5b484fb265b394ddc612 - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-12-08 22:03:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-12 10:04:56 +0900 - - [rubygems/rubygems] Make the "auto-user-install" logic easier to follow - - https://github.com/rubygems/rubygems/commit/4b4d9c0106 - -commit c032dfb5cbd844a8474a1397e65b4e04203d0ddd - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-12 01:28:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-12 10:04:56 +0900 - - [rubygems/rubygems] Fix installing from source when same bundler version already a default gem - - https://github.com/rubygems/rubygems/commit/620119308e - -commit 23289ad45bcf67e218352503958e2d788fbb6c2c - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-12 01:22:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-12 10:04:56 +0900 - - [rubygems/rubygems] Extract some common strings to variables - - https://github.com/rubygems/rubygems/commit/48bc573310 - -commit a811ebf3d5113971b6dc62a8c56053bca1a1d49b - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-08 06:49:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-12 10:04:56 +0900 - - [rubygems/rubygems] Revert missing extensions patch - - https://github.com/rubygems/rubygems/commit/4016c6c024 - -commit 38348502b5429703e418cf4634e405ce77fd4bbc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-12 09:39:13 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-12 09:39:13 +0900 - - [DOC] Update description about shared library suffix - - Loading an extension library with ".dll" suffix on Windows was very - old behavior, and the suffix must be ".so" since 2004. See commits - removing DLEXT2 181a3a2af5df88d145b73a060d51fe437c8c4ad4 and - b76ad15ed0da636161de0243c547ee1e6fc95681. - - Instead, use macOS as an example, which uses ".bundle". - -commit 4eca329d29a98209df401aa97d55b9fb8684ba1b - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-12 08:55:24 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-12-12 09:21:08 +0900 - - Skip a YJIT test on RJIT - -commit 9cb0ad863c0781062388fe1bb2a5d279dc29e734 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-12 07:41:27 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-12-12 09:21:08 +0900 - - YJIT: Fix missing arity check for splat calls to methods with optionals - - Previously, for splat callsites that land in methods with optional - parameters, we didn't reject the case where the caller supplies too many - arguments. Accepting those calls previously caused YJIT to construct - corrupted control frames, which leads to crashes if the callee uses - certain stack walking methods such as Kernel#raise and String#gsub (for - setting up the frame-local `$~`). - - Example crash in a debug build: - - Assertion Failed: ../vm_core.h:1375:VM_ENV_FLAGS:FIXNUM_P(flags) - -commit 47553094740ee17f2490fcb29893cac653c0b5dd - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-12 07:37:39 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-12-12 09:21:08 +0900 - - YJIT: Rename helper function and correct counter name - - Counter::guard_send_iseq_has_rest_and_splat_not_equal was using - jump-if-lesser-than, so wasn't checking for equality. Rename function - because moving is destructive in Rust, which is confusing for this function - which doesn't modify the array. - -commit 9765ada69c34eb1c21855d145c2c6d752b8839b0 - Author: Kazuhiro NISHIYAMA <zn@mbf.nifty.com> - AuthorDate: 2023-12-12 08:47:18 +0900 - Commit: Kazuhiro NISHIYAMA <znz@users.noreply.github.com> - CommitDate: 2023-12-12 09:14:11 +0900 - - Fix NoMethodError on fail - - ``` - .../tool/lib/colorize.rb:56:in `resolve_color': undefined method `gsub' for an instance of Symbol (NoMethodError) - - color.gsub(/\b[a-z][\w ]+/) do |n| - ^^^^^ - from .../tool/lib/colorize.rb:47:in `decorate' - from .../tool/lib/test/unit.rb:1012:in `block in failed' - ``` - -commit 505715ddf17e004d184c0b71afb40a31e2e8c98e - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-19 10:51:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 08:14:58 +0900 - - [rubygems/rubygems] Fewer allocations in gem installation - - For now, on a small rails app I have hanging around: - - ``` - ==> memprof.after.txt <== - Total allocated: 872.51 MB (465330 objects) - Total retained: 40.48 kB (326 objects) - - ==> memprof.before.txt <== - Total allocated: 890.79 MB (1494026 objects) - Total retained: 40.40 kB (328 objects) - ``` - - Not a huge difference in memory usage, but it's a drastic improvement - in total number of allocations. - - Additionally, this will pay huge dividends once - https://github.com/ruby/zlib/pull/61 is merged, as it will allow us to - completely avoid allocations in the repeated calls to readpartial, - which currently accounts for most of the memory usage shown above. - - https://github.com/rubygems/rubygems/commit/f78d45d927 - -commit 4a94ce8569c9399bd286d943ff35f6f3a25ed1b6 - Author: hogelog <konbu.komuro@gmail.com> - AuthorDate: 2023-12-12 07:13:54 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-12 07:13:54 +0900 - - [DOC] Fix RDoc to match actual Kenrel.require behavior (#9180) - -commit 69d60cc67ba0d7cf9318ccafa9d4c625103e955d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-12 05:17:48 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-12 07:04:46 +0900 - - [PRISM] Properly compile MultiTargetNodes within parameters - - If there are MultiTargetNodes within parameters, we need to - iterate over them and compile them individually correctly, once - the locals are all in the correct spaces. We need to add one - getlocal for the hidden variable, and then can recurse into the - MultiTargetNodes themselves - -commit 5c8e1911ca19bc3d346db5ae6314cc8957e9339a - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-12 04:46:24 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-12 07:04:46 +0900 - - [PRISM] Fixed rest in MultiTargetNodes - -commit aaeccc2924d34e2c012df0cd482ca66a9d7297c4 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-12 04:17:02 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-12 07:04:46 +0900 - - [PRISM] Correctly implemented forwarding parameters in methods - -commit 85ad5be9ee7597f6a550d66c90dc4fdd5a15f923 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-07 00:05:14 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-12 07:04:46 +0900 - - [PRISM] Restructure parameters on ScopeNodes - - This commit completely restructures how we handle parameters. The - motivation for this commit was the fix compilation of MultiTargetNodes - within parameters, including nested MultiTargetNodes. A subsequent - commit will actually do the compilation for the MultiTargetNodes. - - This commit's main accomplishment is restructuring the locals table - and how we account for it on the ScopeNode, specifically with regards - to hidden variables. - - It has multiple steps, all commented within the code, to calculate - the locals table correctly and compile the parameters: - - Step 1: Caculate the table size for the locals - - Step 2: Populate iv index table and local table - - Step 3: Fill in parameter names of MultiTargetNodes on local table - - Step 4: Fill in method body locals on local table - - Step 5: Compile any locals - -commit e1d995a96cf99387ce1798904c3051ba11e43d18 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-12-12 05:38:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-12 05:38:16 +0900 - - [DOC] Complex doc (#9185) - -commit 687d29f93ce45bd6721fc06530015a147e4057f0 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-11 07:40:22 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-12 02:59:10 +0900 - - try modified tests. - - debug.gem 1.9.0 has a test issue so try modified one. - ref: https://github.com/ruby/debug/commit/d4feeae32b69b4f88c94fecfc7a283b475eec4de - -commit fb935350707ce14b2f678612dae4cae079fd163c - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-12 02:14:21 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-12 02:53:47 +0900 - - [PRISM] Define and use a pm_add_ensure_iseq - - Prior to this commit, we were using `add_ensure_iseq` which compiled - a node as if it was a CRuby node. This commit defines - `pm_add_ensure_iseq` which compiles the Prism node appropriately. - -commit 3f25c08fa598ba48da8bb504aabe93a4a4c2d486 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-12-12 02:52:47 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-12 02:52:47 +0900 - - YJIT: implement call fuzzer script (#9129) - - * YJIT: implement call fuzzer script - - Attempt to detect bugs in YJIT call implementation. - - * Add basic checks for rest, kwrest. Impprove formatting. - - * Refactor call fuzzer to make it more powerful and maintainable - - Compute checksum of arguments - - * Fix checksum computation. Add useless locals as sussged by Alan. - - * Add some useless if statements - - * Add arguments of different types - - * Pass object arguments as well. Force different shapes. - - * Compute fuzzing time/speed - - * Make use of block param - -commit 4095e7d2be0ef6426e0cb75a53472f6dc1e5a0af - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-11 23:30:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 01:34:55 +0900 - - [ruby/prism] Regexp terminator escapes - - https://github.com/ruby/prism/commit/42a48a2ba9 - -commit c65de63913487caf26a281cb5c3be112f87a23a1 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-11 23:12:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 01:34:41 +0900 - - [ruby/prism] Handle a non-interpolated dsym spanning a heredoc - - https://github.com/ruby/prism/commit/b23136ebfd - -commit 261e8f28a0ccc6119fe38189a55388520969d8ff - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-11 22:50:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 01:34:27 +0900 - - [ruby/prism] Correct escapes when ctrl+meta+escape - - https://github.com/ruby/prism/commit/ee68b17c01 - -commit e186cebe420367947b89a5221491429452d724d5 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-09 05:13:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 00:40:08 +0900 - - [rubygems/rubygems] Override initialize in bundle rubygems_ext for NameTuple - - https://github.com/rubygems/rubygems/commit/f63ce682d2 - -commit b673b5b4329d020b19907142f291c8ecd69e95e0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-08 23:57:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-12 00:32:31 +0900 - - [ruby/prism] Split up CallNode in target position - - In this commit we're splitting up the call nodes that were in target - positions (that is, for loop indices, rescue error captures, and - multi assign targets). - - Previously, we would simply leave the call nodes in place. This had - the benefit of keeping the AST relatively simple, but had the - downside of not being very explicit. If a static analysis tool wanted - to only look at call nodes, it could easily be confused because the - method would have 1 fewer argument than it would actually be called - with. - - This also brings some consistency to the AST. All of the nodes in - a target position are now *TargetNode nodes. These should all be - treated the same, and the call nodes can now be treated the same. - - Finally, there is benefit to memory. Because being in a target - position ensures we don't have some fields, we can strip down the - number of fields on these nodes. - - So this commit introduces two new nodes: CallTargetNode and - IndexTargetNode. For CallTargetNode we get to drop the opening_loc, - closing_loc, arguments, and block. Those can never be present. We - also get to mark their fields as non-null, so they will always be - seen as present. - - The IndexTargetNode keeps around most of its fields but gets to - drop both the name (because it will always be []=) and the - message_loc (which was always super confusing because it included - the arguments by virtue of being inside the []). - - Overall, this adds complexity to the AST at the expense of memory - savings and explicitness. I believe this tradeoff is worth it in - this case, especially because these are very much not common nodes - in the first place. - - https://github.com/ruby/prism/commit/3ef71cdb45 - -commit c69d1367a7994c70f956fc6486568823e8fa5812 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-09 06:17:07 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-11 23:47:59 +0900 - - [PRISM] Fix ElseNode within CaseNode - - The logic within the consequent for the CaseNodes in popped cases - was incorrect as it wouldn't emit consequent instructions for a - popped CaseNode. This commit fixes that. - -commit 0562c246ebdf071dfb85b2f7904574d38fee14f7 - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-12-07 08:36:00 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-11 23:47:33 +0900 - - Add handling of implicit hash arguments - - Arguments that are passed as a hash need special consideration since in certain case they are not treated as keyword arguments. For example, if a call is passing `"a" => 1` as an argument, this will be turned into an implicit hash argument and not a keyword argument. - - The existing compiler checks to see if all hash nodes can be treated as keyword arguments. If they can, then it will treat them as keyword arguments. If not, then it will treat them as implicit hash arguments. - - This commit implements the same logic inside the Prism compiler. - -commit 48cb70fee95dcdcf5f9eef2ef40c3adfecc214fa - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-11 12:44:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-11 22:36:37 +0900 - - [ruby/prism] Fix parsing unterminated empty string `"` - - Fix https://github.com/ruby/prism/pull/2034 - - https://github.com/ruby/prism/commit/8280e577fa - -commit a860e3605c53e708d3cb06e2080ff73b58de4b22 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-11 14:10:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-11 22:34:48 +0900 - - [ruby/prism] Fix to parse a (endless-)range with binary operators - - Fix https://github.com/ruby/prism/pull/2022 - Fix https://github.com/ruby/prism/pull/2030 - - https://github.com/ruby/prism/commit/b78d8b6525 - -commit 1ab91b12fa5f7e98bba2e59e2f40b57004d9acf1 - Author: Daisuke Aritomo <osyoyu@osyoyu.com> - AuthorDate: 2023-12-09 13:13:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-11 20:07:36 +0900 - - [rubygems/rubygems] Stream output from ext builds when --verbose - - Uses Open3.popen2e in place of Open3.capture2e in Gem::Ext::Builder. - This change aims to stream stdout/stderr of ext builds when in verbose - mode, instead of printing everything at once when the build completes. - - Nice for debugging gem builds that consumes longer times. - - https://github.com/rubygems/rubygems/commit/dcdcb5adda - -commit 655aacc43a2ae263c9b71429232853d16df028d5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-11 15:48:51 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-11 16:51:46 +0900 - - Use dedicated functions to check terminators - -commit 980255cb7bfc9ea1ed105ff641ec44b751deced6 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-12-11 15:58:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-11 15:58:43 +0900 - - Update bundled gems list as of 2023-12-10 - -commit e5e53ee173170d2ed354be45f20852359452b45a - Author: Hsing-Hui Hsu <hsing-hui.hsu@webflow.com> - AuthorDate: 2023-12-11 04:08:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-11 08:56:37 +0900 - - docs(compar.c): change class name in example - -commit 91b0d5fa38f8f48a62ac9d10b50f0d65856fc897 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-12-11 00:22:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-11 00:22:22 +0900 - - [DOC] RDoc for Complex (#9181) - -commit c4c39082af3520cd96aefc2219a7037865f3f710 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-12-10 01:47:14 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-10 15:39:06 +0900 - - add `flags` to `rb_postponed_job_preregister` - - for future extensions. - -commit f8effa209adb3ce050c100ffaffe6f3cc1508185 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-11-19 20:54:57 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-10 15:00:37 +0900 - - Change the semantics of rb_postponed_job_register - - Our current implementation of rb_postponed_job_register suffers from - some safety issues that can lead to interpreter crashes (see bug #1991). - Essentially, the issue is that jobs can be called with the wrong - arguments. - - We made two attempts to fix this whilst keeping the promised semantics, - but: - * The first one involved masking/unmasking when flushing jobs, which - was believed to be too expensive - * The second one involved a lock-free, multi-producer, single-consumer - ringbuffer, which was too complex - - The critical insight behind this third solution is that essentially the - only user of these APIs are a) internal, or b) profiling gems. - - For a), none of the usages actually require variable data; they will - work just fine with the preregistration interface. - - For b), generally profiling gems only call a single callback with a - single piece of data (which is actually usually just zero) for the life - of the program. The ringbuffer is complex because it needs to support - multi-word inserts of job & data (which can't be atomic); but nobody - actually even needs that functionality, really. - - So, this comit: - * Introduces a pre-registration API for jobs, with a GVL-requiring - rb_postponed_job_prereigster, which returns a handle which can be - used with an async-signal-safe rb_postponed_job_trigger. - * Deprecates rb_postponed_job_register (and re-implements it on top of - the preregister function for compatability) - * Moves all the internal usages of postponed job register - pre-registration - -commit aecbd66742f43ccfcac04ca4143fcc68ad834320 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-11-19 20:54:01 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-10 15:00:37 +0900 - - Add RUBY_ATOMIC_{PTR_,}FETCH macros for atomic loads - - This can already be emulated by doing an atomic fetch_add of zero, but - this is more explicit. - - [Bug #19994] - -commit 130268e264f59c037eda31205c6e2223cffafbbe - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-12-10 13:21:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-10 13:21:46 +0900 - - [ruby/irb] Simplify show_source's super calculation - (https://github.com/ruby/irb/pull/807) - - https://github.com/ruby/irb/commit/2cccc448de - -commit 04eb1b6f2630a07b3a4140e593a4973493a71b92 - Author: Alex Koval <al3xander.koval@gmail.com> - AuthorDate: 2023-12-09 21:58:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-10 12:06:36 +0900 - - [ruby/prism] fix: escape newline - - https://github.com/ruby/prism/commit/a28b427dcc - -commit f64357540eabad0f1bfaa6be60710d153325b064 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-12-08 05:16:09 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-10 06:15:47 +0900 - - Ensure super(**kw, &block) calls kw.to_hash before block.to_proc - - Similar as previous commit, but handles the super case with - explicit arguments. - -commit a950f230788d51e13d16596e37cb77e4cc6e2311 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-11-09 08:56:53 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-10 06:15:47 +0900 - - Ensure f(**kw, &block) calls kw.to_hash before block.to_proc - - Previously, block.to_proc was called first, by vm_caller_setup_arg_block. - kw.to_hash was called later inside CALLER_SETUP_ARG or setup_parameters_complex. - - This adds a splatkw instruction that is inserted before sends with - ARGS_BLOCKARG and KW_SPLAT and without KW_SPLAT_MUT. This is not needed in the - KW_SPLAT_MUT case, because then you know the value is a hash, and you don't - need to call to_hash on it. - - The splatkw instruction checks whether the second to top block is a hash, - and if not, replaces it with the value of calling to_hash on it (using - rb_to_hash_type). As it is always before a send with ARGS_BLOCKARG and - KW_SPLAT, second to top is the keyword splat, and top is the passed block. - -commit c0b6ea7c8b5dc6e48ecf6e14e1dbd135d079f0fc - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-12-09 08:55:12 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-10 05:49:51 +0900 - - Add a fudge factor to the GC compaction move up/down tests - - There seems to be another manifestation of bug #20021, where some of the - compaction tests are failing on i686 for unrelated PR's because of fake - "live" references to moved objects on the machine stack. - - We _could_ solve this by counting how many objects are pinned during - compaction, but doing that involves pushing down the mark & pin bitset - merge into gc_compact_plane and out of gc_compact_page, which I thought - was pretty ugly. - - Now that we've solved bug #20022 though, we're able to compact - arbitrarily many objects with GC.verify_compaction_references, so the - number of objects we're moving is now 50,000 instead of 500. Since - that's now much larger than the number of objects likely to be pinned, I - think it's safe enough to just add a fudge-factor to the tests. - - Any _other_ change in GC.verify_compaction_references that breaks - compaction is now highly likely to break the assertion by more than 10 - objects, since it's operating on so many more in the first place. - - [Bug #20021] - -commit 9e09e5aa3af03a42cf6ef59da2779b0a5d5a6505 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-10 04:33:36 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-10 05:01:29 +0900 - - Fix test of GVL instrumentation on Ractor sleeping - - It seems that the Ractor sleep GVL event arrives very slightly after the - value becomes available and other threads wake (which makes sense) so we - need a little additional time to ensure we end up in a consisteny state. - -commit b2ad4fec1a369e1cbd0c65d52062946a4fbfb84b - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-09 14:16:02 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-10 02:31:41 +0900 - - Add missing GVL hooks for M:N threads and ractors - -commit edb8fc24d4a51e58f283a6e7fd1b18b43739fa05 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-12-09 17:31:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-09 17:34:08 +0900 - - [ruby/error_highlight] Bump version - - https://github.com/ruby/error_highlight/commit/942a723d32 - -commit 07734b51c66756c4a7a512ebb4736763542d99f3 - Author: Victor Shepelev <zverok.offline@gmail.com> - AuthorDate: 2023-12-09 13:54:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-09 13:54:33 +0900 - - [DOC] Small fixes for documentation rendering - - Mostly just fixing RDoc's incorrect treatment of `+` - -commit 1cbe114d1cf57dc47b4bbc6780f424647dd906d9 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-09 05:00:48 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-12-09 05:45:40 +0900 - - [PRISM] Fix `PM_CALL_NODE` assignment - - This PR fixes ruby/prism#1963. Array and variable assignment was broken - for call nodes. The change checks if the `method_id` is related to - assignment and if is adds a `putnil`, `setn` and a `pop`. - - The incorrect instructions meant that in some cases (demonstrated in - tests) the wrong value would be returned. - - I verified that this fixes the test mentioned in the issue - (run: `RUBY_ISEQ_DUMP_DEBUG=prism make test/-ext-/st/test_numhash.rb`) - - Incorrect instructions: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(4,10)> - 0000 putnil ( 4)[Li] - 0001 putself - 0002 send <calldata!mid:tbl, argc:0, FCALL|VCALL|ARGS_SIMPLE>, nil - 0005 putself - 0006 send <calldata!mid:i, argc:0, FCALL|VCALL|ARGS_SIMPLE>, nil - 0009 putself - 0010 send <calldata!mid:j, argc:0, FCALL|VCALL|ARGS_SIMPLE>, nil - 0013 setn 3 - 0015 send <calldata!mid:[]=, argc:2, ARGS_SIMPLE>, nil - 0018 pop - 0019 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:3 (3,0)-(3,10)> - 0000 putself ( 3)[Li] - 0001 send <calldata!mid:tbl, argc:0, FCALL|VCALL|ARGS_SIMPLE>, nil - 0004 putself - 0005 send <calldata!mid:i, argc:0, FCALL|VCALL|ARGS_SIMPLE>, nil - 0008 putself - 0009 send <calldata!mid:j, argc:0, FCALL|VCALL|ARGS_SIMPLE>, nil - 0012 send <calldata!mid:[]=, argc:2, ARGS_SIMPLE>, nil - 0015 leave - ``` - - Fixed instructions: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(4,10)> - 0000 putnil ( 4)[Li] - 0001 putself - 0002 send <calldata!mid:tbl, argc:0, FCALL|VCALL|ARGS_SIMPLE>, nil - 0005 putself - 0006 send <calldata!mid:i, argc:0, FCALL|VCALL|ARGS_SIMPLE>, nil - 0009 putself - 0010 send <calldata!mid:j, argc:0, FCALL|VCALL|ARGS_SIMPLE>, nil - 0013 setn 3 - 0015 send <calldata!mid:[]=, argc:2, ARGS_SIMPLE>, nil - 0018 pop - 0019 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:3 (3,0)-(3,10)> - 0000 putnil ( 3)[Li] - 0001 putself - 0002 send <calldata!mid:tbl, argc:0, FCALL|VCALL|ARGS_SIMPLE>, nil - 0005 putself - 0006 send <calldata!mid:i, argc:0, FCALL|VCALL|ARGS_SIMPLE>, nil - 0009 putself - 0010 send <calldata!mid:j, argc:0, FCALL|VCALL|ARGS_SIMPLE>, nil - 0013 setn 3 - 0015 send <calldata!mid:[]=, argc:2, ARGS_SIMPLE>, nil - 0018 pop - 0019 leave - ``` - - Fixes ruby/prism#1963 - -commit 9e7ca2c3c9d2fbdcdf7f3b6c0b8c63b2dbb08ebe - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-12-09 05:02:14 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-09 05:13:11 +0900 - - RDoc for Complex - -commit 98e3552cfb80d4d3a8176d9969ea4956adee93d5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-09 00:10:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-09 03:59:52 +0900 - - [ruby/prism] Add necessary encoding flags for symbols and regex - - This doesn't actually fix the encodings for symbols and regex, - unfortunately. But I wanted to get this change in because it is - the last AST change we're going to make before 3.3 is released. - - So, if consumers want, they can start to check these flags to - determine the encoding, even though it will be wrong. Then once we - actually set them correctly, everything should work. - - https://github.com/ruby/prism/commit/9b35f7e891 - -commit a94a2eea34a7d6e1bd0e97b5a3bc73adcfcbcb31 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-05 22:52:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-09 02:01:23 +0900 - - [rubygems/rubygems] Upstream RubyGems changes from TruffleRuby - - https://github.com/rubygems/rubygems/commit/749a508968 - -commit f2c13ff9e8646ea1f05498707c8e972379456883 - Author: Schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-12-09 01:41:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-09 01:49:33 +0900 - - [ruby/syntax_suggest] v2.0.0 - - https://github.com/ruby/syntax_suggest/commit/53b2a1b03c - -commit a54eb9c6f9c12816f6befefd3828b78689076549 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-08 23:40:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-08 23:40:32 +0900 - - [ruby/prism] A couple of small dot enhancements - - https://github.com/ruby/prism/commit/5642a57f39 - -commit 0166040939fd9057a7fb724e290fbe6c9cc036c2 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-12-08 09:37:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-08 23:35:26 +0900 - - [ruby/prism] Hashes need to deoptimize based on their contents - - If a hash has children that are not "basic" types of objects, then we - can't consider the hash to be a static literal. - - Fixes: #2015 - - https://github.com/ruby/prism/commit/ca2523137d - -commit 892b5f10d52bacaf8c6b430d0e9a95dc0ea36834 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-08 23:26:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-08 23:34:34 +0900 - - [ruby/prism] More closely match CRuby error messages - - https://github.com/ruby/prism/commit/1ed07a0c6d - -commit 0204523fe7ccafba30a4d2465946095f2603c7eb - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-12-07 06:44:37 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-12-08 21:59:40 +0900 - - Improve Fiber#kill docs and simplify the NEWS entry to let the documentation explain - -commit 49cdf063d6275151075ffd94c3d013f6c19b31f7 - Author: Akinori MUSHA <knu@idaemons.org> - AuthorDate: 2023-12-08 21:36:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-08 21:37:30 +0900 - - [ruby/set] Bump version to 1.0.4 - - https://github.com/ruby/set/commit/efc8c8c9f5 - -commit cc9826503d989df877adbcd94d39a6ff78d0b785 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-08 20:25:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-08 20:25:04 +0900 - - Revert "Skip to warn like 'bigdecimal/util' feature." - - This reverts commit 8f6cf72e661e36410848c1451335fd28a32cecdf. - -commit f2c84c48842d47e7612c78d0627542b596945586 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-08 15:33:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-08 16:01:01 +0900 - - Pick commit from https://github.com/rubygems/rubygems/pull/7085 - - Co-authored-by: Samuel Giddins <segiddins@segiddins.me> - -commit dab30b4d71efa40220a340e1ef7936824b6cc6c6 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-08 15:32:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-08 16:01:01 +0900 - - Pick commit from https://github.com/rubygems/rubygems/pull/7227 - - Co-authored-by: David Rodríguez <deivid.rodriguez@riseup.net> - -commit 01a2a0abc6a7deac27d66819531d53ceb7855c6a - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-08 02:11:56 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-08 16:01:01 +0900 - - [rubygems/rubygems] Migrate documentation to be generated with nronn - - https://github.com/rubygems/rubygems/commit/55281f0eaa - -commit 1c3aa4b97709676f2a254d0047d061e6bdff0472 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-08 03:22:20 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-08 16:01:01 +0900 - - [rubygems/rubygems] Add extra blank line to `bundle outdated` docs - - If it's not there, when migrating to `nronn`, generated man page is - messed up. - - https://github.com/rubygems/rubygems/commit/7161347648 - -commit dc64a04a12e25cb98aa24ccbd8a57f6aa5a43d65 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-08 06:51:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-08 16:01:01 +0900 - - [rubygems/rubygems] Revert "Merge pull request #7148 from Paul-Bob/improvement/include_response_body_on_fetch_http_error" - - This reverts commit https://github.com/rubygems/rubygems/commit/e5a4fd9eb617, reversing - changes made to https://github.com/rubygems/rubygems/commit/c5a5363b0c98. - - https://github.com/rubygems/rubygems/commit/e21c45c4c3 - -commit 8f6cf72e661e36410848c1451335fd28a32cecdf - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-08 15:57:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-08 15:57:08 +0900 - - Skip to warn like 'bigdecimal/util' feature. - -commit 64e985333f4fa7e4ba06454ef50c41e56a22768d - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-08 05:35:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-08 15:55:15 +0900 - - Improve bundled gems warnings for subfeatures - - Before, when requiring "bigdecimal/math" in a Bundler context: - - > /Users/deivid/.asdf/installs/ruby/3.3.0-dev/lib/ruby/3.3.0+0/bigdecimal/math.rb:2: warning: bigdecimal was loaded from the standard library, but will no longer be part of the default gems since Ruby 3.4.0. Add bigdecimal to your Gemfile or gemspec. - - After: - - > foo.rb:1: warning: bigdecimal/math is found in bigdecimal, which will no longer be part of the default gems since Ruby 3.4.0. Add bigdecimal to your Gemfile or gemspec. - -commit a530dfef2be3934decd975100585e3978ef49173 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-08 05:30:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-08 15:55:15 +0900 - - Improve bundled gem warnings - - Before, when requiring "bigdecimal" in a Bundler context: - - > foo.rb:1: warning: bigdecimal which will no longer be part of the default gems since Ruby 3.4.0. Add bigdecimal to your Gemfile or gemspec. - - After: - - > foo.rb:1: warning: bigdecimal was loaded from the standard library, but will no longer be part of the default gems since Ruby 3.4.0. Add bigdecimal to your Gemfile or gemspec. - -commit d61af5c49a9cc65c7009b9d2036bf43a527e8036 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-08 05:29:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-08 15:55:15 +0900 - - The SINCE and WARNED hashes take gem names, not features - -commit 4817166e54ad98f9b3e9d06e9e8c7ccff992a957 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-10-21 09:56:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-08 15:09:51 +0900 - - [rubygems/rubygems] Extract generate_index command to rubygems-generate_index gem - - So generate_index can be implemented with dependencies, such as the compact index - - Took this approach from feedback in https://github.com/rubygems/rubygems/pull/6853 - - Running `gem generate_index` by default will use an installed rubygems-generate_index, or install and then use the command from the gem - - Apply suggestions from code review - - https://github.com/rubygems/rubygems/commit/fc1cb9bc9e - - Co-authored-by: Hiroshi SHIBATA <hsbt@ruby-lang.org> - -commit 0166d56f2bb062ddf56a0e7757849da68b66fe62 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-08 13:18:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-08 14:51:03 +0900 - - [rubygems/rubygems] Don't memoize in NameTuple lock_name - - The result of this is already memoized and no other NameTuple - methods memoize. - - https://github.com/rubygems/rubygems/commit/b7cce0c64a - -commit 352a885a0f1a4d4576c686301ee71ea887a345e5 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-11-17 02:29:11 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-12-08 13:16:19 +0900 - - Thread specific storage APIs - - This patch introduces thread specific storage APIs - for tools which use `rb_internal_thread_event_hook` APIs. - - * `rb_internal_thread_specific_key_create()` to create a tool specific - thread local storage key and allocate the storage if not available. - * `rb_internal_thread_specific_set()` sets a data to thread and tool - specific storage. - * `rb_internal_thread_specific_get()` gets a data in thread and tool - specific storage. - - Note that `rb_internal_thread_specific_get|set(thread_val, key)` - can be called without GVL and safe for async signal and safe for - multi-threading (native threads). So you can call it in any internal - thread event hooks. Further more you can call it from other native - threads. Of course `thread_val` should be living while accessing the - data from this function. - - Note that you should not forget to clean up the set data. - -commit 9b7a964318d04beb82680ff1d0c6eb571f4b8b5e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-07 20:04:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-08 12:53:47 +0900 - - [Bug #19877] Flip-flop needs to be direct condition - -commit 8bb90f4d771d287644a3cf21bdda26c637f091e2 - Author: Yuji Yaginuma <yuuji.yaginuma@gmail.com> - AuthorDate: 2023-12-08 11:10:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-08 12:25:43 +0900 - - [rubygems/rubygems] Use `Minitest::TestTask` in a template file for `minitest` - - `minitest` has introduced a rake task for running test on 5.16.0. - https://github.com/minitest/minitest/blob/master/History.rdoc#5160--2022-06-14- - - This has some tasks related to running tests and it's useful for - `minitest` user I think. - https://github.com/minitest/minitest#rake-tasks- - - This PR changed to use the task in a template file for `minitest` - - https://github.com/rubygems/rubygems/commit/7a86d13062 - -commit ac5fd58700b5576bfdd89ffe06dd4302b6721e5f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-08 07:53:05 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-08 07:53:05 +0900 - - YJIT: Fix on-stack ISEQ comparison for auto_compact (#9164) - -commit 2755cb1b2fbc4a5f08ca56345b5945bd452da74e - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-08 06:10:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-08 07:29:33 +0900 - - [rubygems/rubygems] Use modern hashes consistently - - https://github.com/rubygems/rubygems/commit/bb66253f2c - -commit 9d696aa20461d94c2d32e1e474bd036ade20c94d - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-12-06 07:07:50 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-12-08 07:07:09 +0900 - - Support method calls inside `defined?` - - This commit supports all kinds of method calls (including methods with - parameters) inside `defined?` calls. - -commit f76881c9af4256d984c0cd59bc1f6929134eded0 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-12-08 05:36:37 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-08 06:34:41 +0900 - - RDoc for Complex - -commit 6816e8efcff3be75f8020cd1b0ea57d3cd664bbc - Author: Adam Hess <adamhess1991@gmail.com> - AuthorDate: 2023-10-13 03:15:53 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-08 05:52:35 +0900 - - Free everything at shutdown - - when the RUBY_FREE_ON_EXIT environment variable is set, manually free memory at shutdown. - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - Co-authored-by: Peter Zhu <peter@peterzhu.ca> - -commit b361a800c22e0248bf126d77e96a7bd4f9c34d1b - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-08 05:03:06 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-08 05:29:35 +0900 - - Added comment - -commit a0c7bb4328c981be5f3f0e82e7ef75fc8bbd51b6 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-08 04:13:33 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-08 05:29:35 +0900 - - [PRISM] Account for multiple arguments when compiling ArgumentsNode - - BreakNode, ReturnNode and NextNode all compile the ArgumentsNode - directly, but we weren't accounting for multiple arguments. If there - is more than one argument, we need to also emit a newarray - instruction to put the arguments onto the stack - -commit 7738b31d390e70b26e913d86c133a70c8e65a645 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-12-01 08:30:30 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-08 04:27:55 +0900 - - Eliminate array allocation for f(1, *a, &arg), f(*a, **kw, &arg), and f(*a, kw: 1, &arg) - - These are similar to the f(1, *a, &lvar), f(*a, **kw, &lvar) and - f(*a, kw: 1, &lvar) optimizations, but they use getblockparamproxy - instruction instead of getlocal. - - This also fixes the else style to be more similar to the surrounding - code. - -commit f5a01b091673b81cf2e1efa149f84763bdadad98 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-11-29 03:58:22 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-08 04:27:55 +0900 - - Add benchmark for recent optimization to avoid implicit allocations - -commit 13cd963500106b366c8df9eec5c1b6815e93f07f - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-11-22 02:02:31 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-08 04:27:55 +0900 - - Prevent modification of splat array inside setup_parameters_complex - - For the following: - - ``` - def f(*a); a end - p f(*a, kw: 3) - ``` - - `setup_parameters_complex` pushes `{kw: 3}` onto `a`. This worked fine - back when `concatarray true` was used and `a` was already a copy. It - does not work correctly with the optimization to switch to - `concatarray false`. This duplicates the array on the callee side - in such a case. - - This affects cases when passing a regular splat and a keyword splat - (or literal keywords) in a method call, where the method does not - accept keywords. - - This allocation could probably be avoided, but doing so would - make `setup_parameters_complex` more complicated. - -commit aa808204bb3b84ad37e2c4722f9d00e07ab8f281 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-11-07 06:17:49 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-08 04:27:55 +0900 - - Eliminate array allocation for f(*a, kw: 1, &lvar) and f(*a, kw: 1, &@iv) - - Similar to the previous commit, but this handles the block pass - case. - -commit 5e33f2b0e4c262ed0c7e524b11d020438c41f532 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-11-07 06:03:02 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-08 04:27:55 +0900 - - Eliminate array allocation for f(*a, kw: 1) - - In cases where the compiler can detect the hash is static, it would - use duphash for the hash part. As the hash is static, there is no need - to allocate an array. - -commit 95615872e32156d9add8fd3afd136dd73fd6aa1a - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-11-07 05:39:57 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-08 04:27:55 +0900 - - Eliminate array allocation for f(*a, **lvar, &lvar) and f(*a, **@iv, &@iv) - - The compiler already eliminates the array allocation for - f(*a, &lvar) and f(*a, &@iv). If that is safe, then eliminating - it for f(*a, **lvar) and f(*a, **@iv) as the last commit did is - as safe, and eliminating it for f(*a, **lvar, &lvar) and - f(*a, **@iv, &@iv) is also as safe. - -commit 1731dd05a7f9fcdef1ea1c25f7a3e072679c3d3a - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-11-07 05:37:16 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-08 04:27:55 +0900 - - Eliminate array allocation for f(*a, **lvar) and f(*a, **@iv) - - The compiler already eliminates the array allocation for - f(*a, &lvar) and f(*a, &@iv), and eliminating the array allocation - for keyword splat is as safe as eliminating it for block passes. - -commit c70c1d2a9592bcea916500eb16ae58f6de4b9a3f - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-11-07 05:08:03 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-08 04:27:55 +0900 - - Eliminate array allocation for f(1, *a, &lvar) and f(1, *a, &@iv) - - Due to how the compiler works, while f(*a, &lvar) and f(*a, &@iv) - do not allocate an array, but f(1, *a, &lvar) and f(1, *a, &@iv) - do. It's probably possible to fix this in the compiler, but - seems easiest to fix this in the peephole optimizer. - - Eliminating this array allocation is as safe as the current - elimination of the array allocation for f(*a, &lvar) and - f(*a, &@iv). - -commit 40a2afd08fe1b921f1052b29031abfa1869e0557 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-11-04 08:56:58 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-08 04:27:55 +0900 - - Eliminate array allocation for f(1, *a) - - Due to how the compiler works, while f(*a) does not allocate an - array f(1, *a) does. This is possible to fix in the compiler, but - the change is much more complex. This attempts to fix the issue - in a simpler way using the peephole optimizer. - - Eliminating this array allocation is safe, since just as in the - f(*a) case, nothing else on the caller side can modify the array. - -commit 41b299d6391261c11025e88b54743bb903606fb3 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-08 00:00:39 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-08 04:12:20 +0900 - - [PRISM] Stop catch table entries being deleted by the optimiser - -commit 3081c83169c55ef7eead6222e49248e09232c22c - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-10-27 09:03:17 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-08 03:29:33 +0900 - - Support tracing of struct member accessor methods - - This follows the same approach used for attr_reader/attr_writer in - 2d98593bf54a37397c6e4886ccc7e3654c2eaf85, skipping the checking for - tracing after the first call using the call cache, and clearing the - call cache when tracing is turned on/off. - - Fixes [Bug #18886] - -commit 1721bb9dc6dcc3ecec05e9d6f72654099460ef50 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-08 02:41:06 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-08 02:42:56 +0900 - - Skip a flaky objspace test on Visual Studio - - This seems to happen only on VisualStudio: - https://github.com/ruby/ruby/actions/runs/7130917319/job/19418375386 - - It fails relatively frequently. Nobody seems actively working on it, so - let's skip it until somebody starts working on it. - -commit 3a88de3ca73052809f5c0bfb4ef8cd435b29ae5f - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-10-26 04:49:28 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-08 02:30:36 +0900 - - Support eval "return" at toplevel - - Since Ruby 2.4, `return` is supported at toplevel. This makes `eval "return"` - also supported at toplevel. - - This mostly uses the same tests as direct `return` at toplevel, with a couple - differences: - - `END {return if false}` is a SyntaxError, but `END {eval "return" if false}` - is not an error since the eval is never executed. `END {return}` is a - SyntaxError, but `END {eval "return"}` is a LocalJumpError. - - The following is a SyntaxError: - - ```ruby - class X - nil&defined?0--begin e=no_method_error(); return; 0;end - end - ``` - - However, the following is not, because the eval is never executed: - - ```ruby - class X - nil&defined?0--begin e=no_method_error(); eval "return"; 0;end - end - ``` - - Fixes [Bug #19779] - -commit 0c3593b6573b4186c980fb4ea7635bf95261c749 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-07 12:29:06 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-08 02:23:02 +0900 - - Use free with ruby_dtoa - - In ae0ceafb0c0d05cc80623b525070255e3abb34ef ruby_dtoa was switched to - use malloc instead of xmalloc, which means that consumers should be - using free instead of xfree. Otherwise we will artificially shrink - oldmalloc_increase_bytes. - -commit 5f81f58b2696db3c1c3fc44a2c83dbff85747100 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-07 12:17:40 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-08 02:22:21 +0900 - - Use xfree in hash_st_free - - st.c redefines malloc and free to be ruby_xmalloc and ruby_xfree, so - when this was copied into hash.c it ended up mismatching an xmalloc with - a regular free, which ended up inflating oldmalloc_increase_bytes when - hashes were freed by minor GC. - -commit ca204a20231f1ecabf5a7343aec49c3ea1bac90a - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-12-08 01:35:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-08 01:35:55 +0900 - - Fix keyword splat passing as regular argument - - Since Ruby 3.0, Ruby has passed a keyword splat as a regular - argument in the case of a call to a Ruby method where the - method does not accept keyword arguments, if the method - call does not contain an argument splat: - - ```ruby - def self.f(obj) obj end - def self.fs(*obj) obj[0] end - h = {a: 1} - f(**h).equal?(h) # Before: true; After: false - fs(**h).equal?(h) # Before: true; After: false - - a = [] - f(*a, **h).equal?(h) # Before and After: false - fs(*a, **h).equal?(h) # Before and After: false - ``` - - The fact that the behavior differs when passing an empty - argument splat makes it obvious that something is not - working the way it is intended. Ruby 2 always copied - the keyword splat hash, and that is the expected behavior - in Ruby 3. - - This bug is because of a missed check in setup_parameters_complex. - If the keyword splat passed is not mutable, then it points to - an existing object and not a new object, and therefore it must - be copied. - - Now, there are 3 specs for the broken behavior of directly - using the keyword splatted hash. Fix two specs and add a - new version guard. Do not keep the specs for the broken - behavior for earlier Ruby versions, in case this fix is - backported. For the ruby2_keywords spec, just remove the - related line, since that line is unrelated to what the - spec is testing. - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit 195dbf241f800556731c190b0e4368224afe2e11 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-07 11:00:37 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-12-08 01:16:12 +0900 - - Fix potential compaction issue in env_copy() - - `src_ep[VM_ENV_DATA_INDEX_ME_CREF]` was read out and held without - marking across the allocation in vm_env_new(). In case vm_env_new() ran - compaction, an invalid reference could have been written into - `copied_env`. - - It might've been hard to actually produce a crash with this issue due to - the pinning marking of the field in rb_execution_context_mark(). - -commit 050806f4252dce2698260d905f7c86c621c1ec63 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-07 10:35:40 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-12-08 01:16:12 +0900 - - Add missing write barrier to env_copy() - - Previously, the following crashed with - `vm_assert_env:imemo_type_p(obj, imemo_env)` due to missing a missing - WB: - - o = Object.new - def o.foo(n) - freeze - - GC.stress = 1 - - # inflate block nesting get an imemo_env for each level - n.tap do |i| - i.tap do |local| - return Ractor.make_shareable(-> do - local + i + n - end) - end - end - ensure - GC.stress = false - GC.verify_internal_consistency - end - - p o.foo(1)[] - - By the time the recursive env_copy() call returns, `copied_env` could - have aged or have turned greyed, so we need a WB for the - `ep[VM_ENV_DATA_INDEX_SPECVAL]` assignment which adds an edge. - - Fix: 674eb7df7f409099f33da77293d9658e09b470d6 - -commit 5809b75019dd3a253bb0e45c37bbf0cca0400911 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-12-08 01:09:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-08 01:09:15 +0900 - - [ruby/irb] Debugging command warning should not be specific to the - `debug` command - (https://github.com/ruby/irb/pull/806) - - https://github.com/ruby/irb/commit/b7b57311cc - -commit c05278e425a7b7cadf0bf299ecfbe0ae9525c75c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-08 00:39:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-08 01:00:41 +0900 - - [ruby/prism] Update ordering of integer base flags - - https://github.com/ruby/prism/commit/d711950d5f - -commit 0dc40bd2b740898fac4c6d4193ab6cd7ad52c05d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-07 06:38:59 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-08 00:49:06 +0900 - - Check need_major_gc during GC stress - - need_major_gc is set when a major GC is required. However, if - gc_stress_no_major is also set, then it will not actually run a major - GC. - - For example, the following script will sometimes crash: - - ``` - GC.stress = 1 - 50000.times.map { [] } - ``` - - With the following message: - - ``` - [BUG] cannot create a new page after major GC - ``` - -commit b8df6b9e01d8971235ea42fc9098ce392f791928 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-08 00:08:16 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-08 00:34:39 +0900 - - [PRISM] Don't pop arguments on a return node - - Since ReturnNodes don't get popped, their arguments shouldn't either - -commit cbc0e0bef08f9389f5bbe76de016795f01c3bc76 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-11-27 14:50:05 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-08 00:19:35 +0900 - - Fix GC.verify_compaction_references not moving every object - - The intention of GC.verify_compaction_references is, I believe, to force - every single movable object to be moved, so that it's possible to debug - native extensions which not correctly updating their references to - objects they mark as movable. - - To do this, it doubles the number of allocated pages for each size pool, - and sorts the heap pages so that the free ones are swept first; thus, - every object in an old page should be moved into a free slot in one of - the new pages. - - This worked fine until movement of objects _between_ size pools during - compaction was implemented. That causes some problems for - verify_compaction_references: - - * We were doubling the number of pages in each size pool, but actually - if some objects need to move into a _different_ pool, there's no - guarantee that they'll be enough room in that one. - * It's possible for the sweep & compact cursors to meet in one size pool - before all the objects that want to move into that size pool from - another are processed by the compaction. - - You can see these problems by changing some of the movement tests in - test_gc_compact.rb to try and move e.g. 50,000 objects instead of - 500; the test is not able to actually move all of the objects in a - single compaction run. - - To fix this, we do two things in verify_compaction_references: - - * Firstly, we add enough pages to every size pool to make them the same - size. This ensures that their compact cursors will all have space to - move during compaction (even if that means empty pages are - pointlessly compacted) - * Then, we examine every object and determine where it _wants_ to be - compacted into. We use this information to add additional pages to - each size pool to handle all objects which should live there. - - With these two changes, we can move arbitrary amounts of objects into - the correct size pool in a single call to verify_compaction_references. - - My _motivation_ for performing this work was to try and fix some test - stability issues in test_gc_compact.rb. I now no longer think that we - actually see this particular bug in rubyci.org, but I also think - verify_compaction_references should do what it says on the tin, so it's - worth keeping. - - [Bug #20022] - -commit 5d832d16d9878766dfe527934ef1ad64698b9bf8 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-11-27 14:49:18 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-08 00:19:35 +0900 - - Add objspace_each_pages to gc.c - - This works like objspace_each_obj, except instead of being called with - the start & end address of each page, it's called with the page - structure itself. - - [Bug #20022] - -commit 10bc0bd4ab9b886b77ba0cb4cdb2fa121a84c835 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-07 23:34:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 23:39:11 +0900 - - [ruby/prism] Remove warnings check from parse_success? method - - https://github.com/ruby/prism/commit/e30a241fb3 - -commit 8e86a4347e8943305d2667865154fba046eb862d - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-07 19:24:33 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-07 23:38:24 +0900 - - [PRISM] Ensure should set correct end_label - -commit c4b969535055ab0debf47abc26d00c1b06c686cc - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-07 07:20:38 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-07 23:38:24 +0900 - - [PRISM] Rescue should set correct end_label - - In order for a break inside the rescue to have the correct jump target - -commit 071df40495e31f6d3fd14ae8686b01edf9a689e3 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-12-07 17:26:15 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-12-07 21:07:38 +0900 - - Lrama v0.5.12 - -commit 30a1ccbc5c0c7c3736dbd3b020e5ca5fbf657cbc - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-12-07 19:50:55 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-07 19:50:55 +0900 - - NEWS: Move "interruptible name resolution" to "Stdlib updates" section - -commit d69af4788a923f9afab63104a7adb72a02d37745 - Author: Matheus Richard <matheusrichardt@gmail.com> - AuthorDate: 2023-12-07 19:49:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 19:50:00 +0900 - - [ruby/io-console] [DOC] Add documentation for IO#cursor - - ruby/io-console#50 - - https://github.com/ruby/io-console/commit/ee752ce771 - -commit bc6a0ede4a05d19dc999d05c84b46a0258ab0528 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-07 18:56:23 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-07 18:56:23 +0900 - - Bump up bundled net-ftp gem version to 0.3.0 - -commit abf192eb16ea845ac11743a32bd2f3e2d234488b - Author: Tanaka Akira <akr@fsij.org> - AuthorDate: 2023-12-07 18:28:47 +0900 - Commit: Tanaka Akira <akr@fsij.org> - CommitDate: 2023-12-07 18:28:47 +0900 - - always omit test_ai_addrconfig. - -commit d2ba8ea54a4089959afdeecdd963e3c4ff391748 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-12-07 17:55:15 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-07 17:55:15 +0900 - - Set AI_ADDRCONFIG when making getaddrinfo(3) calls for outgoing conns (#7295) - - When making an outgoing TCP or UDP connection, set AI_ADDRCONFIG in the - hints we send to getaddrinfo(3) (if supported). This will prompt the - resolver to _NOT_ issue A or AAAA queries if the system does not - actually have an IPv4 or IPv6 address (respectively). - - This makes outgoing connections marginally more efficient on - non-dual-stack systems, since we don't have to try connecting to an - address which can't possibly work. - - More importantly, however, this works around a race condition present - in some older versions of glibc on aarch64 where it could accidently - send the two outgoing DNS queries with the same DNS txnid, and get - confused when receiving the responses. This manifests as outgoing - connections sometimes taking 5 seconds (the DNS timeout before retry) to - be made. - - Fixes #19144 - -commit c6eb355e04b2f9ffe9e78fcec259c901b3905cc9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-07 17:02:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-07 17:03:03 +0900 - - Revert "Warn `it` only with -W:deprecated" - - This reverts commit 5458252bb0edcd498e6bd4bea57fd7500bacd54c. - - Revert "Fallback rb_warn_deprecated for UNIVERSAL_PARSER" - - This reverts commit 680be886f4d807073f24beed36648ef76219e4f7. - - matz actually preferred always warning `it`. - -commit 680be886f4d807073f24beed36648ef76219e4f7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-07 16:57:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-07 17:00:36 +0900 - - Fallback rb_warn_deprecated for UNIVERSAL_PARSER - -commit 5458252bb0edcd498e6bd4bea57fd7500bacd54c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-07 16:44:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-12-07 16:44:02 +0900 - - Warn `it` only with -W:deprecated - -commit a41d6c825c4b1ed5699fd7880edeb8d4adfa5197 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-07 16:21:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 16:22:20 +0900 - - [ruby/open-uri] Bump up 0.4.1 - - https://github.com/ruby/open-uri/commit/d72508a7f4 - -commit ae76c8a11e707176a53c84016256646308f36207 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-07 16:14:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-07 16:14:59 +0900 - - Warn `it` (#9152) - - https://bugs.ruby-lang.org/issues/18980 - -commit 41c00bc97ebf237fd04ce740d0dfd0681f4a28c7 - Author: Andrew Kane <andrew@ankane.org> - AuthorDate: 2023-11-10 08:24:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 16:00:54 +0900 - - [ruby/open-uri] Set default for max_redirects and add exception class - - https://github.com/ruby/open-uri/commit/dcdcb885cc - -commit d97479f9c966bd2c9d52c8be28aca9431760c610 - Author: Andrew Kane <andrew@ankane.org> - AuthorDate: 2023-01-14 13:27:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 16:00:53 +0900 - - [ruby/open-uri] Add :max_redirects option - - https://github.com/ruby/open-uri/commit/7fd5ea09a7 - -commit 7d32830b8ce14cc130d052a4aa67495a34ed55dc - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-12-01 10:20:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-07 13:56:23 +0900 - - [rubygems/rubygems] Make --build-root disable auto-user-install. - - https://github.com/rubygems/rubygems/commit/6a06b0763f - -commit 33bd95625756562f4865fbc6ad5c39e0cfbc26d6 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-01 20:53:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-07 13:56:22 +0900 - - [rubygems/rubygems] Better approach to falling back to user installation when GEM_HOME not writable - - https://github.com/rubygems/rubygems/commit/f67bced16b - -commit 0f3f907e17bba1b94c5e202cb57988af8c6c91fc - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-01 20:52:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-07 13:56:22 +0900 - - [rubygems/rubygems] Add some early assertions to make sure the test is progressing fine - - If an error happens during the install command, it will fail in an - strange way right now. - - https://github.com/rubygems/rubygems/commit/2b6e0c703a - -commit aabf2ce181053d37cbf1d6db55ff533055c96d83 - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-11-28 23:38:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-07 13:55:31 +0900 - - [rubygems/rubygems] Use globals variables for standard input/output - - Replace use of `STDIN`, `STDOUT` and `STDERR` constants by their - `$stdin`, `$stdout` and `$stderr` global variable equivalents. - - This enables easier testing via standard means, such as `assert_output` - for minitest or `expect { print 'foo' }.to output.to_stdout` for RSpec - test suites. - - https://github.com/rubygems/rubygems/commit/a0a6fc1b76 - -commit d89280e8bf6496aa83326b5f9c293724bd1cc1e9 - Author: Dustin Brown <dbrown9@gmail.com> - AuthorDate: 2023-12-07 12:25:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-07 12:25:29 +0900 - - Copy encoding flags when copying a regex [Bug #20039] - - * :bug: Fixes [Bug #20039](https://bugs.ruby-lang.org/issues/20039) - - When a Regexp is initialized with another Regexp, we simply copy the - properties from the original. However, the flags on the original were - not being copied correctly. This caused an issue when the original had - multibyte characters and was being compared with an ASCII string. - Without the forced encoding flag (`KCODE_FIXED`) transferred on to the - new Regexp, the comparison would fail. See the included test for an - example. - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit 1ace218690d76496c5a54c45691515f8f6410a49 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-12-07 12:11:19 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-07 12:11:19 +0900 - - Remove a note for `bundle exec ruby` not printing a warning - - The implementation limitation is fixed by https://github.com/rubygems/rubygems/pull/7224 - -commit 214f6d6598be8437284dede9eb9a041a3ebfb24e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-07 10:56:34 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-07 11:37:08 +0900 - - Move replace_require into bundled_gems.rb - -commit 4f213ea1baa590c463c3554a6ff418d10dc291e0 - Author: Soutaro Matsumoto <matsumoto@soutaro.com> - AuthorDate: 2023-12-07 10:37:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-07 10:37:00 +0900 - - Fix SEGV caused by `GC::Profiler.raw_data` (#9122) - -commit 5078aa825c943f757f53a12264ab5e5c4cf1542e - Author: hogelog <konbu.komuro@gmail.com> - AuthorDate: 2023-12-06 23:19:38 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-07 09:45:46 +0900 - - Add NEWS for Range#overlap? - -commit ce094e8556014b5c1f175ff7c1b881339ad84a41 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-12-07 07:05:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 07:15:16 +0900 - - [ruby/prism] Emit error for constant assignments in defs - - https://github.com/ruby/prism/commit/864b06f90e - -commit 9d9865d9bc2f563c2c600ec53cc71926441b973f - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-07 05:20:05 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-12-07 06:42:53 +0900 - - YJIT: Add some object validity assertions - - We've seen quite a few compaction bugs lately, and these assertions - should give clearer symptoms. We only call class_of() on - objects that the Ruby code can see. - -commit c5a4409f20e816d3777ebd2c23b894022342a975 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-07 05:52:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 06:34:48 +0900 - - [ruby/prism] Simplify unterminated string - - https://github.com/ruby/prism/commit/ef512ca914 - -commit c8b60c8ac2c8bbd077150792b5b207e983ab3634 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-07 05:22:18 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-12-07 06:12:08 +0900 - - [PRISM] Correct depth offset for block local vars - - Blocks should always look at their own local table first, even when - defined inside an ensure/rescue or something else that uses depth - offset. We can ignore the depth offset if we're doing local lookups - inside a block - -commit fe6ee5e92148755b75ffd00ab29611b59a416d5a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-07 05:32:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 05:50:02 +0900 - - [ruby/prism] Move flag position consistently to front - - https://github.com/ruby/prism/commit/6e69a81737 - -commit cbb941f58a236d95d9e95c3f6dbd4510c04351f0 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-02 13:00:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 05:48:11 +0900 - - [ruby/prism] Fix closing loc for string literals - - Fix https://github.com/ruby/prism/pull/1974 - - https://github.com/ruby/prism/commit/453d403593 - -commit a57186b9d1b0db3a88e5e9082347903b109f7d0e - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-12-06 18:39:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 05:38:22 +0900 - - [ruby/prism] Fix one potential memory leak and silence one false positive report. - - https://github.com/ruby/prism/commit/9608aa386e - -commit a439fc2f175f5c272886a7be57c6444015450401 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-07 05:19:43 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-07 05:19:43 +0900 - - YJIT: Avoid register allocation conflict with a higher stack_idx (#9143) - - YJIT: Avoid register allocation conflict - - with a higher stack_idx - -commit 9336bbb0b268cb655e6c07ad2a83b9a28cb98911 - Author: Eric Mueller <nevinera@gmail.com> - AuthorDate: 2023-12-02 13:23:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 05:05:25 +0900 - - [rubygems/rubygems] Bundler::Fetcher uses Bundler::CIDetector - - Additionally, the result is memoized, as it's used twice in a row. - - This change does result in a net behavioral diff, as the list of ENVs - being checked has been updated (now includes buildkite, taskcluster, - cirrus, dsari, and drops buildbox and snap) - - https://github.com/rubygems/rubygems/commit/3fb445a5a1 - -commit 6fd3b358ff1e1745036286be7007cd0d6ebdcdd7 - Author: Eric Mueller <nevinera@gmail.com> - AuthorDate: 2023-12-02 13:20:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 05:05:25 +0900 - - [rubygems/rubygems] Duplicate Gem::CIDetector into bundler - - Because bundler needs to support older versions of rubygems, we can't - actually rely on Gem::CIDetector (yet - in a year or so they might be - able to consolidate, if they don't change futher). So we're copying it - into the Bundler:: namespace, and enforcing that they stay completely in - sync with a test. No other tests are needed, since Gem::CIDetector is - already tested, and this is and will remain identical. - - https://github.com/rubygems/rubygems/commit/abc67f0da1 - -commit a6c912a80de27a5022528802305e1e97fe5b2678 - Author: Eric Mueller <nevinera@gmail.com> - AuthorDate: 2023-11-29 11:41:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 05:05:24 +0900 - - [rubygems/rubygems] Gem::UpdateSuggestion uses Gem::CIDetector - - https://github.com/rubygems/rubygems/commit/e5b0458342 - -commit b1b78c4f9ff0ff3a2570980b0012893eb03fc597 - Author: Eric Mueller <nevinera@gmail.com> - AuthorDate: 2023-11-29 11:13:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 05:05:23 +0900 - - [rubygems/rubygems] Introduce the Gem::CIDetector - - This is based on the list in Gem::UpdateSuggestion and Bundler::Fetcher; - these have similar purposes (determining whether/what CI we're executing - in), and can benefit from being combined and updated (they're both - slightly out of date). - - Noteable changes: - * We'll consider ourselves to be on a CI in more cases - if CI_NAME or - TASKCLUSTER_ROOT_URL are set specifically, since those represent two - cases that were either overlooked or are no longer covered by the - existing implementation. (Or possibly TaskCluster still does provide - RUN_ID, but failed to document it) - * We will notice/track a few additional services in ci_strings (cirrus, - dsari, taskcluster), stop tracking 'snap' (they went under in 2017), - and update buildbox to buildkite (they've been called that for 8 - years, and the BUILDBOX envs have been deprecated for 3). - * We'll also sort/uniq/downcase the values (all of which only matter - because of the special case of CI_NAME). - - https://github.com/rubygems/rubygems/commit/60652b942f - -commit 82072254a05c88648caac2bd51069681e37f91aa - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-07 04:26:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 04:26:35 +0900 - - [ruby/prism] Update documentation for encodings - - https://github.com/ruby/prism/commit/18e6df0d4f - -commit 153c09f24be77b8db986c2914c141b5bd8f51f67 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-07 02:54:16 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-07 04:23:38 +0900 - - [prism] Handle string and xstring encodings - -commit 82f18baa21d0df59c30d8a6e60bf3e0991de1114 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-05 02:51:22 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-07 04:23:38 +0900 - - [ruby/prism] Provide flags for changing encodings - - https://github.com/ruby/prism/commit/e838eaff6f - -commit 9620ca678929f28dd8dab8e278e438a430a85022 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-06 23:45:04 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-07 03:05:03 +0900 - - [PRISM] Extract a PM_NOP helper - -commit 0316e666c07d020fac267e0a76952cf0dae07190 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-06 01:31:12 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-07 02:25:49 +0900 - - [PRISM] Fix ReturnNodes - - This code is almost exactly the same (fixed variable names) as - what exists already in compile.c - -commit 12e3b07455fea0e99e6aaf1893a7883fb2b0197e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-06 21:37:57 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-07 01:34:07 +0900 - - Re-embed when removing Object instance variables - - Objects with the same shape must always have the same "embeddedness" - (either embedded or heap allocated) because YJIT assumes so. However, - using remove_instance_variable, it's possible that some objects are - embedded and some are heap allocated because it does not re-embed heap - allocated objects. - - This commit changes remove_instance_variable to re-embed Object - instance variables when it becomes small enough. - -commit f80262b14d01a977ce386a5a377e911a90ce328d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-07 01:05:43 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-07 01:31:43 +0900 - - [PRISM] Account for nil parent in Call{Operator,And,Or}PathWriteNodes - - Prior to this commit, we were not accounting for the case of a nil - parent in a CallXPathWriteNode, for example ::A ||= 1. This commit - checks if the parent exists, and if not, uses Object as the inferred - parent - -commit 64ab04da6ae15243e1615739f2529f37e532943d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-07 01:02:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-07 01:14:54 +0900 - - [ruby/bigdecimal] Clarify that JSON methods come from the JSON gem - - https://github.com/ruby/bigdecimal/commit/581725d4e5 - -commit 4a7151a8e4806917f1bdca2a5b5a3b82d7959d32 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-07 00:16:58 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-07 00:16:58 +0900 - - Deduplicate assertions in redblack_balance - - The bug in i686 was fixed in commit - 71babe5536bdb2238509752d8706194ee57ff485. - -commit dab5a4b61aa43bd67221e89df9de67de0e3a97f6 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-11-17 06:46:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 23:59:23 +0900 - - [ruby/bigdecimal] [DOC] Add section Methods for Working with JSON - - https://github.com/ruby/bigdecimal/commit/2edd8d0a23 - -commit 018dbf18d50b34a3ea564bfe0264a423de4b33bb - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-05 06:40:59 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-06 23:55:48 +0900 - - [ruby/prism] Add locals_body_index to DefNode, BlockNode, LambdaNode - - The locals_body_index gives the index in the locals array where - the locals from the body start. This allows compilers to easily - index past the parameters in the locals array. - - https://github.com/ruby/prism/commit/5d4627b890 - -commit da1519b223e1accfcef1c831f9fdc6421724ea7c - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-06 04:08:21 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-06 23:46:19 +0900 - - [PRISM] Implement `PM_MATCH_PREDICATE_NODE` for `defined?` - - Ruby code: - - ```ruby - defined? 1 in 1 - ``` - - Instructions: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,16)> - 0000 putobject "expression" - 0002 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,16)> - 0000 putobject "expression" - 0002 leave - ``` - -commit 45471084484d18a7496d2318729f6206294fa2fa - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-06 04:06:01 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-06 23:46:19 +0900 - - [PRISM] Implement `PM_KEYWORD_HASH_NODE` for `defined?` - - Ruby code: - - ```ruby - defined? [a: [:b, :c]] - ``` - - Instructions (without optimizations): - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,23)> - == catch table - | catch type: rescue st: 0001 ed: 0007 sp: 0000 cont: 0009 - | == disasm: #<ISeq:defined guard in <compiled>@<compiled>:0 (0,0)-(-1,-1)> - | local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - | [ 1] "$!"@0 - | 0000 putnil - | 0001 leave - |------------------------------------------------------------------------ - 0000 putnil - 0001 putobject true - 0003 branchunless 9 - 0005 putobject "expression" - 0007 swap - 0008 pop - 0009 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,23)> - == catch table - | catch type: rescue st: 0000 ed: 0009 sp: 0000 cont: 0009 - | == disasm: #<ISeq:defined guard in <compiled>@<compiled>:0 (0,0)-(-1,-1)> - | local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - | [ 1] "$!"@0 - | 0000 putnil - | 0001 leave - |------------------------------------------------------------------------ - 0000 putnil - 0001 putobject true - 0003 branchunless 9 - 0005 putobject "expression" - 0007 swap - 0008 pop - 0009 leave - ``` - - Instructions (with optimizations): - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,23)> - == catch table - | catch type: rescue st: 0001 ed: 0003 sp: 0000 cont: 0005 - | == disasm: #<ISeq:defined guard in <compiled>@<compiled>:0 (0,0)-(-1,-1)> - | local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - | [ 1] "$!"@0 - | 0000 putnil - | 0001 leave - |------------------------------------------------------------------------ - 0000 putnil - 0001 putobject "expression" - 0003 swap - 0004 pop - 0005 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,23)> - == catch table - | catch type: rescue st: 0000 ed: 0005 sp: 0000 cont: 0005 - | == disasm: #<ISeq:defined guard in <compiled>@<compiled>:0 (0,0)-(-1,-1)> - | local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1]) - | [ 1] "$!"@0 - | 0000 putnil - | 0001 leave - |------------------------------------------------------------------------ - 0000 putnil - 0001 putobject "expression" - 0003 swap - 0004 pop - 0005 leave - ``` - -commit 86497645229099f3a6d0f64b3bb85d215f04f5df - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-06 03:47:46 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-06 23:46:19 +0900 - - [PRISM] Implement `PM_SPLAT_NODE` for `defined?` - - In an array for `defined?` we need to check if there is a - `contains_splat` flag, if so bail early. - - Ruby code: - - ```ruby - defined?([[*1..2], 3, *4..5]) - ``` - - Instructions: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,29)> - 0000 putobject "expression" - 0002 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,29)> - 0000 putobject "expression" - 0002 leave - ``` - -commit 02961fdbab0da97b2aa506b3e77d846d7e883ddc - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-06 02:14:41 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-06 23:46:19 +0900 - - [PRISM] Implement `PM_SOURCE_LINE_NODE` for `defined?` - - Ruby code: - - ```ruby - defined?(__LINE__) - ``` - - Instructions: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,18)> - 0000 putobject "expression" - 0002 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,18)> - 0000 putobject "expression" - 0002 leave - ``` - -commit d474239537f0845c4b737869fabe7815274500b8 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-06 02:12:44 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-06 23:46:19 +0900 - - [PRISM] Implement `PM_SOURCE_FILE_NODE` for `defined?` - - Ruby code: - - ```ruby - defined?(__FILE__) - ``` - - Instructions: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,18)> - 0000 putobject "expression" - 0002 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,18)> - 0000 putobject "expression" - 0002 leave - ``` - -commit 41b117e50c97ab8117ff538d6cd8ff2ebed57c71 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-06 02:07:26 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-06 23:46:19 +0900 - - [PRISM] Implement `PM_SOURCE_ENCODING_NODE` for `defined? - - Ruby code: - - ```ruby - defined?(__ENCODING__) - ``` - - Instructions: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,22)> - 0000 putobject "expression" - 0002 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,22)> - 0000 putobject "expression" - 0002 leave - ``` - -commit b04255deff8da978a967447a478be44d9c66d74e - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-06 02:04:56 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-06 23:46:19 +0900 - - [PRISM] Implement `PM_IMAGINARY_NODE` for `defined?` - - Ruby Code: - - ``` - defined?(1i) - ``` - - Instructions: - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,12)> - 0000 putobject "expression" - 0002 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,12)> - 0000 putobject "expression" - 0002 leave - ``` - -commit d6ec1aa0a79235e75cbb92141590199a322e7bf1 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-01 23:37:10 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-06 21:02:04 +0900 - - [PRISM] Compile Rescue Modifier nodes - -commit 34543f7c75c28f8b650b5ef3c30eb2c5314c4db5 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-12-06 17:39:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 20:41:49 +0900 - - [ruby/prism] Update snapshot - - https://github.com/ruby/prism/commit/5f0ea09785 - -commit c23c5f1ea6c4892e9d8ec2d14bf44e7e198a45da - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-12-06 20:35:16 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-12-06 20:35:16 +0900 - - Add NEWS entry about Encoding#replicate - -commit ca8733daaf7be388fb492e7feddfd569856686a2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-06 19:56:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-06 19:56:38 +0900 - - [DOC] Fixed document position - - Method documentation must be placed immediately before each - implementation, without any other functions or preprocessor - directives. - -commit d411d8f5fe80b9c8f741ee03f91a670d5620917c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-06 18:03:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 19:10:44 +0900 - - [rubygems/rubygems] Try to load Gem::BUNDLED_GEMS on Bundler - - `bundle exec ruby foo.rb` ignore to load gem_prelude.rb. Because warnings feature - is not working with `bundle exec ruby`. - - https://github.com/rubygems/rubygems/commit/a0d4ed92a7 - -commit e03e872eea75ee63672c755dccc340a1f6042fce - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-06 18:09:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 18:35:44 +0900 - - [ruby/rdoc] Only word-ending colon separates new definition - - When followed by non-space characters, rather it looks like a URL or a - path name on Windows. - - https://github.com/ruby/rdoc/commit/72c6560773 - -commit 379f06797d563084ed28f397419f97b7d2e01d87 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-06 17:37:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 18:35:43 +0900 - - [ruby/rdoc] Needs more backslash to match escaping backslashs - - https://github.com/ruby/rdoc/commit/1904e9076d - -commit 8105ff9ac4b63b7ceae5bb9bafc5c935b24a3f57 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-06 17:27:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 18:35:43 +0900 - - [ruby/rdoc] Use single quotes to keep backslash literally - - https://github.com/ruby/rdoc/commit/4ac9be7f48 - -commit 1fd976db21191307fc1262631f5da20c8ce970fd - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-12-06 16:47:29 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-06 17:13:18 +0900 - - Refine the NEWS entry for bundler warning - -commit 7e05e9ff945c4e6d9fffebafc8037e28d747f0b7 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-12-06 15:48:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-06 15:48:55 +0900 - - Fix incorrect "nested_fake_name" documentation. (#9135) - -commit 888051802b7a0d38303c946f1349b2c0daf6239a - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-12-06 15:47:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-06 15:47:33 +0900 - - Add news for `Fiber#kill`. (#9134) - -commit 538ff351336ebbee6c0a7987bbbbf8d34cb67d6b - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-12-05 14:07:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 11:49:01 +0900 - - [rubygems/rubygems] test_bundled_ca.rb: Add Net::OpenTimeout as a offline case. - - It seems that when DNS connection is enabled, but the TCP connection is - disabled in a way, the `Net::HTTP.connect` raises `Net::OpenTimeout`. - And I want to skip the tests in this case. - - https://github.com/ruby/net-http/blob/042faf74e77d786ff60dff81555f6ec4f21e77a9/lib/net/http.rb#L1601-L1608 - - ``` - 1) Error: - TestBundledCA#test_accessing_new_index: - Net::OpenTimeout: execution expired - /builddir/build/BUILD/ruby-3.0.4/lib/net/http.rb:987:in `initialize' - /builddir/build/BUILD/ruby-3.0.4/lib/net/http.rb:987:in `open' - /builddir/build/BUILD/ruby-3.0.4/lib/net/http.rb:987:in `block in connect' - /builddir/build/BUILD/ruby-3.0.4/lib/timeout.rb:107:in `timeout' - /builddir/build/BUILD/ruby-3.0.4/lib/net/http.rb:985:in `connect' - /builddir/build/BUILD/ruby-3.0.4/lib/net/http.rb:970:in `do_start' - /builddir/build/BUILD/ruby-3.0.4/lib/net/http.rb:959:in `start' - /builddir/build/BUILD/ruby-3.0.4/lib/net/http.rb:1512:in `request' - /builddir/build/BUILD/ruby-3.0.4/lib/net/http.rb:1270:in `get' - /builddir/build/BUILD/ruby-3.0.4/test/rubygems/test_bundled_ca.rb:34:in `assert_https' - /builddir/build/BUILD/ruby-3.0.4/test/rubygems/test_bundled_ca.rb:58:in `test_accessing_new_index' - ... - ``` - - https://github.com/rubygems/rubygems/commit/5defe0a2f6 - -commit d9a1bb4b097899c21c9a11b042072224c4ff252b - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-06 06:29:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 11:45:37 +0900 - - [rubygems/rubygems] Use String#unpack1 available since ruby 3.0 - - https://github.com/rubygems/rubygems/commit/46258d6cb4 - -commit b8b319dd1a48b695df8982eacf8b1ee0004c7a8b - Author: HParker <HParker@github.com> - AuthorDate: 2023-12-06 09:57:29 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-12-06 10:21:12 +0900 - - Revert "allow enabling Prism via flag or env var" - - This reverts commit 9b76c7fc89460ed8e9be40e4037c1d68395c0f6d. - -commit 00467699a96902bc8dc68bf0ad237f9a02e093d5 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-12-06 09:42:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-06 09:42:45 +0900 - - Don't warn generally for `IO::Buffer`, only on specific code paths e.g. `map`. (#9131) - -commit 0346cbbc148a6eec2f3a5b840758b00b51b3d016 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-06 07:54:37 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-12-06 08:19:42 +0900 - - Fix parameter types for rb_ivar_foreach() callbacks - - For this public API, the callback is declared to take - `(ID, VALUE, st_data_t)`, but it so happens that using - `(st_data_t, st_data_t, st_data_t)` also - type checks, because the underlying type is identical. - Use it as declared and get rid of some casts. - -commit 56eccb350b8872b4eca051cc3e2732cefb717637 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-06 06:25:34 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-06 06:25:34 +0900 - - Fix alphabetical order of include in shape.c - -commit 5f0ea3f590f8983669fe478bc9eace6880353b84 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-02 07:20:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 06:09:53 +0900 - - [rubygems/rubygems] Converts Bundler lockfile checksum validation to opt-in only - - Looks for the CHECKSUMS section in the lockfile, activating the feature - only if the section exists. Without a CHECKSUMS section, Bundler will - continue as normal, validating checksums when gems are installed while - checksums from the compact index are present. - - https://github.com/rubygems/rubygems/commit/2353cc93a4 - -commit a33632e1ca7af1e3ba34cff05643aa067561a8cc - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-06 01:34:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 05:47:22 +0900 - - [ruby/prism] Fix defined with new line - - It's possible to write the following and have it be valid Ruby: - - ``` - defined?("foo" - ) - ``` - - But Prism wasn't taking the new line into account. This adds an - `accept1` for a `PM_TOKEN_NEWLINE` to account for this. I've also - updated the fixtures and snapshots to test this. - - https://github.com/ruby/prism/commit/b87f8eedc6 - -commit 82883dc8f2343913eb9df32fda6798b2f969dfee - Author: Schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-12-06 03:24:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 03:25:42 +0900 - - [ruby/syntax_suggest] Change assertion to not rely on exact text from prism - - The original ripper test was very stable as the output didn't change. Prism is under active development and changing their output shouldn't cause a failure to the ruby/ruby test suite like https://github.com/ruby/ruby/actions/runs/7104601478/job/19339940315. - - This commit moves from checking exact output to asserting that the string we get back is not empty. This should give the same level of confidence that some error message was caught, and is less brittle. - - https://github.com/ruby/syntax_suggest/commit/4b6abb763e - -commit a063969ec18c8f213d9c70471a29d0d31ec5850a - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-06 01:40:17 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-12-06 03:20:06 +0900 - - YJIT: Assert code pages are not partially in-bounds - - Helps understand page switching - -commit 695e5c179ed06761e47c700c6b31a26f48eee699 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-06 00:22:46 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-12-06 03:20:06 +0900 - - YJIT: Simplify code page switching logic, remove an assert - - We have received a report of `assert!( !cb.has_dropped_bytes())` in - set_page() failing. The only explanation for this seems to be memory - allocation failing in write_byte(). The if condition implies that - `current_write_pos < dst_pos < mem_size`, which rules out failing to - encode the relative jump. The has_capacity() assert above not tripping - implies that we were in a place in the page where write_byte() did - attempt to write the byte and potentially made a syscall in the process. - - Remove the assert, since memory allocation could fail. Also, return - failure if the destination is outside of the code region to detect that - out-of-memory situation quicker. - -commit c175e265dae7c7192f9cf4ecbbc1c29c0491ef16 - Author: Schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-12-05 08:34:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 02:51:29 +0900 - - [ruby/syntax_suggest] Remove duplicate error messages - - Before: - - ``` - Expected a newline or semicolon after the statement - Cannot parse the expression - Expected a newline or semicolon after the statement - Cannot parse the expression - - 1 describe "webmock tests" do - 22 it "body" do - 27 query = Cutlass::FunctionQuery.new( - > 28 port: port - > 29 body: body - 30 ).call - 34 end - 35 end - ``` - - After: - - ``` - Expected a newline or semicolon after the statement - Cannot parse the expression - - 1 describe "webmock tests" do - 22 it "body" do - 27 query = Cutlass::FunctionQuery.new( - > 28 port: port - > 29 body: body - 30 ).call - 34 end - 35 end - ``` - - https://github.com/ruby/syntax_suggest/commit/becf097e5e - -commit 6d39d6d2143f7b910f310de0ff92772839ac72a2 - Author: Schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-12-05 07:59:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 02:51:29 +0900 - - [ruby/syntax_suggest] Update docs, clean up PR - - Removes or updates mentions of Ripper - - https://github.com/ruby/syntax_suggest/commit/08aaa3f50a - -commit 62c96959114ea165f7434da9edc42d15e4aaebfa - Author: Schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-12-05 06:23:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 02:51:28 +0900 - - [ruby/syntax_suggest] Support lexing with Prism - - https://github.com/ruby/syntax_suggest/commit/7f4176a914 - -commit cce29750d797a85ac89540b9ad47816131652a2f - Author: Schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-12-02 03:14:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 02:51:27 +0900 - - [ruby/syntax_suggest] Initial support for the prism parser - - Prism will be the parser in Ruby 3.3. We need to support 3.0+ so we will have to "dual boot" both parsers. - - Todo: - - - LexAll to support Prism lex output - - Add tests that exercise both Ripper and prism codepaths on CI - - Handle https://github.com/ruby/prism/issues/1972 in `ripper_errors.rb` - - Update docs to not mention Ripper explicitly - - Consider different/cleaner APIs for separating out Ripper and Prism - - https://github.com/ruby/syntax_suggest/commit/a7d6991cc4 - -commit 9b76c7fc89460ed8e9be40e4037c1d68395c0f6d - Author: HParker <HParker@github.com> - AuthorDate: 2023-12-02 06:25:41 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-06 02:17:14 +0900 - - allow enabling Prism via flag or env var - - Enable Prism using either --prism - - ruby --prism test.rb - - or via env var - - RUBY_PRISM=1 ruby test.rb - -commit b29ed638833f2abc7ce99b5bbf5cd07b0021d7fe - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-12-06 01:34:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 01:34:19 +0900 - - [ruby/irb] Bump version to v1.10.1 - (https://github.com/ruby/irb/pull/801) - - https://github.com/ruby/irb/commit/a1e431bd83 - -commit f55746a93d48a3ee1fdfacba3716457fabea150a - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-12-06 01:32:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 01:32:13 +0900 - - [ruby/irb] Disable pager when TERM is not set too - (https://github.com/ruby/irb/pull/802) - - https://github.com/ruby/irb/commit/173980974b - -commit ef387e67307504f41baf45a5b06a10eb82933788 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-12-06 01:03:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 01:03:06 +0900 - - [ruby/irb] Pager should be disabled when TERM=dumb - (https://github.com/ruby/irb/pull/800) - - For apps/libs that test against IRB, it's recommended to set `TERM=dumb` - so they get minimum disruption from Reline's interactive-focus features. - - Therefore, we should follow the convention to disable pager when `TERM=dumb`. - - https://github.com/ruby/irb/commit/8a3002a39e - -commit 94bf9f80377d32e9dd5123bdf487b55b5e06a851 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-12-05 18:17:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 00:25:20 +0900 - - [ruby/prism] Remove unnecessary match - - https://github.com/ruby/prism/commit/694d3d7279 - -commit ff6706b08e445c2927351da307e0d53e48f9332e - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-02 12:11:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 00:16:42 +0900 - - [ruby/prism] Fix a typo - - https://github.com/ruby/prism/pull/1949#discussion_r1412568793 - - https://github.com/ruby/prism/commit/a00f21d10a - -commit 3260ed7e5eeb7313411a682d9734f48920be9691 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-01 02:28:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 00:16:42 +0900 - - [ruby/prism] Add test cases - - https://github.com/ruby/prism/commit/e91f8dbb99 - -commit 975b74a8eb042c642e626fa95af7c15d41121497 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-01 02:22:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 00:16:41 +0900 - - [ruby/prism] Fix argument order - - https://github.com/ruby/prism/pull/1949#discussion_r1410733341 - - https://github.com/ruby/prism/commit/27635da821 - - Co-Authored-By: Kevin Newton <kddnewton@gmail.com> - -commit 3d4a4b252917ef2a76c92333eaeb76448b56d7ba - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-30 18:25:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 00:16:41 +0900 - - [ruby/prism] Fix some corner cases - - https://github.com/ruby/prism/commit/d5453f168e - -commit dcd75fd49dd879f4931b1c5b1bd65990a92badb5 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-30 17:42:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-06 00:16:40 +0900 - - [ruby/prism] Fix to parse command-style method calls more correctly - - Fix https://github.com/ruby/prism/pull/1468 - Fix https://github.com/ruby/prism/pull/1575 - - To decide command-style method calls are allowed, this introduce a new - parameter `accepts_command_call` to `parse_expression` and some - functions. - - Although one think this can be solved by operator precedence, it is - hard or impossible, because the precedence of command-style calls is skewed - (e.g. `! bar 1 ` is accepted, but `foo = ! bar 1` is rejected.) - - One of the most complex examples is that: - (1) even though `foo = bar = baz 1` and `foo, bar = baz 1` is accepted, - (2) `foo, bar = baz = fuzz 1` is rejected. - To implement this behavior, this introduces a new binding power - `PM_BINDING_POWER_MULTI_ASSIGNMENT` and uses it for distinguish which single - assignments or multi assignments at their RHS. - - https://github.com/ruby/prism/commit/d4dd49ca81 - -commit 6b9622ebdfc5ef12ee379cd1f0818b0188e1e068 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-04 21:27:34 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-05 22:56:22 +0900 - - [PRISM] Implement Retry node. - -commit 674eb7df7f409099f33da77293d9658e09b470d6 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-05 04:02:56 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-05 22:42:25 +0900 - - Make env_copy compaction safe - - The original order of events is: - - 1. Allocate env_body. - 2. Fill env_body using elements in src_env, and it performs operations - that can trigger a GC. - 3. Create the copied_env using vm_env_new. - - However, if GC compaction runs during step 2, then copied_env would not - have yet been created and objects on env_body could move but it would - not be reference updated. - - This commit changes the the order to be (1), (3), (2). - -commit ed25f0bd5a4fb936eddde080b90446e7d55afb2d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-05 04:00:00 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-05 22:42:25 +0900 - - Make env_clone compaction safe - - The original order of events is: - - 1. Allocate new_body. - 2. Peform memcpy into new_body. - 3. Create new_env using new_body. - - However, if GC compaction runs during step 3, then new_env would not - have yet been created and objects on new_body could move but it would - not be reference updated. - - This commit changes the order of the last two events. - -commit bf0c8055ab29a9c2d8280028379c4a7cb033905e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-05 18:10:56 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-05 18:10:56 +0900 - - [DOC] Fix wording in descriptions of Time-like objects - - Co-authored-by: Burdette Lamar <BurdetteLamar@Yahoo.com> - -commit bf0f56e12432be8f2047a5330d4bc0bfff6243f5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-02 23:55:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-05 18:04:02 +0900 - - [DOC] Mention Time-like objects - -commit 113f5d7fd79f2b7dd72a2f748dee475ad793a743 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-05 13:22:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-05 17:48:19 +0900 - - [ruby/rdoc] Allow any single-word token upto 2 before C method implementation - - Previously only unknown word `intern` is allowed between a single-word - token before a C method. Now any single-word token, such as `inline` - which is used for `ArithmeticSequence` in enumerator.c, is allowed - instead. - - https://github.com/ruby/rdoc/commit/3a214c1dd1 - -commit c0baa3783f1f43072128cb90339a2d00e03dde1c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-05 13:22:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-05 17:48:18 +0900 - - [ruby/rdoc] Reduce matched substring allocations - - https://github.com/ruby/rdoc/commit/aaed688a97 - -commit d691b1a14167129cc415abda3792aa25fd5d6a96 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-05 16:36:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-05 16:37:08 +0900 - - [ruby/rdoc] Bump up 6.6.1 - - https://github.com/ruby/rdoc/commit/7cf353a696 - -commit f19de1289b4c20b12efe431d124f6988fbaf007f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-05 16:02:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-05 16:02:17 +0900 - - [ruby/tempfile] Bump up 0.2.1 - - https://github.com/ruby/tempfile/commit/1450bb4f1c - -commit 494e2e4bfb28349a19b4503e37ac11509de1d50e - Author: Akshay Birajdar <akshaybirajdar05@gmail.com> - AuthorDate: 2023-05-01 19:32:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-05 15:43:42 +0900 - - [ruby/tempfile] Alias #to_s to #inspect - - https://github.com/ruby/tempfile/commit/e515889412 - -commit e7cc79183879b6449d42050407b3e998428b4ef2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-05 15:35:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-05 15:38:55 +0900 - - [ruby/cgi] Bump up 0.4.1 - - https://github.com/ruby/cgi/commit/929e6264b5 - -commit 56ccad060d1c215280f12444f726d54d2ca6636d - Author: Toshimaru <me@toshimaru.net> - AuthorDate: 2023-11-28 09:44:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-05 15:21:52 +0900 - - [ruby/rdoc] Early return when `token_stream` is `nil` - - https://github.com/ruby/rdoc/commit/04f75d8516 - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit cda431f5388e8359532998c7fbf5fa615ce6d45e - Author: toshimaru <me@toshimaru.net> - AuthorDate: 2023-11-20 08:47:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-05 15:21:51 +0900 - - [ruby/rdoc] fix: fix `NoMethodError` when `token_stream` is nil - - The change in #1055 might be a breaking change. - So, just simply wrap `token_stream` with `Array` - - https://github.com/ruby/rdoc/commit/d8c19d7fa1 - - Co-authored-by: Jonathan Hefner <jonathan@hefner.pro> - -commit eecae51502215ae4dab9d99a1079636f3fcd99a5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-05 13:01:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 15:09:56 +0900 - - [flori/json] Bump up 2.7.1 - - https://github.com/flori/json/commit/a1af7a308c - -commit 16669cd6ad737a99782655084fabf444f7dc93eb - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-12-02 00:56:17 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 14:28:42 +0900 - - [rubygems/rubygems] Fix crash when duplicating a dev dependency in Gemfile & gemspec - - https://github.com/rubygems/rubygems/commit/e78c0a4a48 - -commit 7ab877761e0577b1cd29811173971305bfadcead - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-27 01:17:22 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 14:28:41 +0900 - - [rubygems/rubygems] Instead of checking writability, try to write - - Checking writability is prone to errors. For example: - - $ mkdir -p foo/bar - $ chmod -w foo - $ touch foo/bar/baz # succeeds even if foo is not writable - - https://github.com/rubygems/rubygems/commit/6056138b6a - -commit 4a71852f757d9c18c023f3f6e993cdf55f74411d - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-27 00:54:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 14:28:40 +0900 - - [rubygems/rubygems] Set specs as pending at the beginning - - And word them consistently with other specs. - - https://github.com/rubygems/rubygems/commit/eee7afefd3 - -commit a60718d107d161071f0732d64898e3922d1e3b89 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-27 00:39:05 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 14:28:40 +0900 - - [rubygems/rubygems] Simplify `--no-user-install` spec - - This spec is ignoring the local `.gem` file, so most stuff is not - needed. - - https://github.com/rubygems/rubygems/commit/d52526800f - -commit 57178a9720ebe5c86e2fbd7d41d9f58f049133c3 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-11-30 12:36:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 14:28:39 +0900 - - [rubygems/rubygems] Prefer String#split with block in Gem::YAMLSerializer#load - - String#split supports a block since Ruby 2.6, avoiding intermediate array. - - https://github.com/rubygems/rubygems/commit/69cdf9e9d4 - -commit 5f789350dceef80494e4e3e3e1ce95f886657845 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-11-30 12:24:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 14:28:39 +0900 - - [rubygems/rubygems] Prefer String#split with block in Bundler::CompactIndexClient::Cache#versions - - String#split supports a block since Ruby 2.6, avoiding intermediate array. - - https://github.com/rubygems/rubygems/commit/4e864a8f2e - -commit a3cd7b3e27506f0b60a05292db8a18de520c69a6 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-11-30 12:22:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 14:28:38 +0900 - - [rubygems/rubygems] Prefer String#split with block in Bundler::YAMLSerializer#load - - String#split supports a block since Ruby 2.6, avoiding intermediate array. - - https://github.com/rubygems/rubygems/commit/5b324969cd - -commit 440ea778f2b8422e07075e5c451ec0d3bad8f90d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-05 14:27:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 14:27:19 +0900 - - VERSION file of JSON is removed from upstream - -commit a399c1f26d34b2ba3a4787f2206c59faa2ea97da - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-05 11:23:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 12:04:35 +0900 - - Removed obsoleted version definition - -commit bf5368493b74d514328f0f1096f760fca1d0c56c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-05 11:23:24 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 12:04:11 +0900 - - [flori/json] Detect json version from version.rb - - https://github.com/flori/json/commit/3ef57b5b39 - -commit 84654bfbba8df0f9eb6876051f8fe62f9a423bdd - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-05 10:41:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 12:04:11 +0900 - - [flori/json] cosmetics - - https://github.com/flori/json/commit/39d6c854a4 - -commit abc3d124f79abae6ea9072fe6a3e70486c1fbe58 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-05 10:41:01 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 12:04:10 +0900 - - [flori/json] The modern Ruby uses utf-8 encodings by default - - https://github.com/flori/json/commit/11b31210ac - -commit c8faaf4c7edf67a19786cb9ba53805e5b813b918 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-12-05 09:59:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 12:04:09 +0900 - - [flori/json] [DOC] RDoc for additions - (https://github.com/flori/json/pull/557) - - * RDoc for additions - - * Update lib/json/add/time.rb - - Co-authored-by: Hiroshi SHIBATA <hsbt@ruby-lang.org> - - --------- - - https://github.com/flori/json/commit/3f2efd60f7 - - Co-authored-by: Hiroshi SHIBATA <hsbt@ruby-lang.org> - -commit 70740deea793274f6e38a7b7fc3688aa709fd1d8 - Author: tompng <tomoyapenguin@gmail.com> - AuthorDate: 2023-12-04 19:18:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 12:04:08 +0900 - - [flori/json] Fix JSON.dump overload combination - - https://github.com/flori/json/commit/41c2712a3b - -commit e6b35e8a6d70892037503d74cec2657b2b8bd116 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-02 02:53:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 12:04:08 +0900 - - [flori/json] Overload kwargs in JSON.dump - - https://github.com/flori/json/commit/936f280f9f - -commit a22ed8943859963c67533bb0edc13a27bfdac00c - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-12-01 19:46:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-05 12:04:07 +0900 - - [flori/json] JSON.dump: handle unenclosed hashes regression - - Fix: https://github.com/flori/json/issues/553 - - We can never add keyword arguments to `dump` otherwise - existing code using unenclosed hash will break. - - https://github.com/flori/json/commit/8e0076a3f2 - -commit 5a2d70ef73d4d17f5999f5087499a5eda1126567 - Author: Schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-12-05 07:19:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-05 07:29:44 +0900 - - [ruby/syntax_suggest] Bump minimum Ruby version & update standardrb - - https://github.com/ruby/syntax_suggest/commit/73753518e9 - -commit 13482ab1e61e0c337badd6308412621f807df9c1 - Author: Schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-12-05 07:17:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-05 07:18:40 +0900 - - [ruby/syntax_suggest] Update standardrb to Ruby 3.0 standards - - https://github.com/ruby/syntax_suggest/commit/2771dcabe0 - -commit 81a700853d1d3bdf7973c7d7175711e7e8c508c7 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-05 00:55:11 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-05 07:02:04 +0900 - - [PRISM] Fixed redo node - -commit 7d371ca25d8e8f6524894be4413484cc9b04cb72 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-05 05:40:43 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-05 06:45:18 +0900 - - [PRISM] Handle percent literals for `defined?` - - Tests all the possible percent literal with `defined?`. Implements the - missing `PM_X_STRING_NODE` for the `%x` literal. - - Code: - - ```ruby - defined?(%x[1,2,3]) - ``` - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,19)> - 0000 putobject "expression" - 0002 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,19)> - 0000 putobject "expression" - 0002 leave - ``` - -commit 09e8d37f5b60f1cd1076c354128309cdf74d0df7 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-05 05:22:10 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-05 06:45:18 +0900 - - [PRISM] Implement `PM_INTERPOLATED_REGULAR_EXPRESSION_NODE` - - Implements `PM_INTERPOLATED_REGULAR_EXPRESSION_NODE` for `defined?` - - Code: - - ```ruby - defined?(/#{1}/) - ``` - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,16)> - 0000 putobject "expression" - 0002 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,16)> - 0000 putobject "expression" - 0002 leave - ``` - -commit 33bc22efe5d372898f3a37004f324f7457e9a944 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-05 05:10:12 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-05 06:45:18 +0900 - - [PRISM] Implement `PM_INTERPOLATED_STRING_NODE` - - Implements `PM_INTERPOLATED_STRING_NODE` for `defined?` - - Code: - - ```ruby - defined?("#{expr}") - ``` - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,19)> - 0000 putobject "expression" - 0002 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,19)> - 0000 putobject "expression" - 0002 leave - ``` - -commit c23b2e5353f08a7131c77567f89d3aae707bdd25 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-05 05:01:51 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-05 06:45:18 +0900 - - [PRISM] Fix `PM_PARENTHESES_NODE` - - In #9101 I only accounted for an empty paren. This change implements the - `PM_PARENTHESES_NODE` for when it's `nil` and when it's an expression. - - Code: - - ```ruby - defined?(("a")) - ``` - - ``` - "********* Ruby *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,15)> - 0000 putobject "expression" - 0002 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,15)> - 0000 putobject "expression" - 0002 leave - ``` - -commit 569750f624dbb4e9d5836d4e9c46816224f4b681 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-05 01:45:42 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-12-05 05:03:22 +0900 - - [Prism] Implement backref and numbered reference for `defined?` - - This PR implements `PM_BACK_REFERENCE_READ_NODE` and - `PM_NUMBERED_REFERENCE_READ_NODE` for `defined?`. The following now - works: - - * `PM_NUMBERED_REFERENCE_READ_NODE` - - ``` - defined? $1 - defined? $2 - ``` - - Instructions: - - ``` - "********* RUBY *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,12)> - 0000 putnil - 0001 defined ref, :$1, "global-variable" - 0005 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,12)> - 0000 putnil - 0001 defined ref, :$1, "global-variable" - 0005 leave - ``` - - * `PM_BACK_REFERENCE_READ_NODE` - - ``` - defined? $' - defined? $` - defined? $& - ``` - - Instructions: - - ``` - "********* RUBY *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,12)> - 0000 putnil - 0001 defined ref, :$`, "global-variable" - 0005 leave - - "********* PRISM *************" - == disasm: #<ISeq:<compiled>@<compiled>:0 (0,0)-(0,12)> - 0000 putnil - 0001 defined ref, :$`, "global-variable" - 0005 leave - ``` - -commit e3ca50b02fc4e3381f62a60bce0164d2132cf4ed - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-05 01:36:35 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-05 04:03:00 +0900 - - [PRISM] Fix compilation for NextNode - - This code was almost enitrely the same as the existing compiler's - code for its NextNode. - -commit 71babe5536bdb2238509752d8706194ee57ff485 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-04 23:26:26 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-05 03:57:12 +0900 - - Use 32-bit integers for redblack_id_t - - On 32-bit systems, the shape cache size is 1048576 (value of - REDBLACK_CACHE_SIZE), but a 16-bit unsigned integer can only go up to - 65536. This means that the redblack_id_t can overflow and lead to a - corrupted red-black tree. - - The following script crashes on 32-bit systems: - - o = Object.new - 1_000_000.times do |i| - o.instance_variable_set(:"@i#{i}", i) - end - -commit d35aa58b2fac5ce0172c3a940a9b5f33af21bc56 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-05 02:15:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-05 02:15:19 +0900 - - [ruby/prism] Fix up docs for lex_compat - - https://github.com/ruby/prism/commit/9131e84060 - -commit ea9f89eeb68dd7cac0083c1cfc5300672b380d00 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-05 01:58:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-05 02:00:14 +0900 - - [ruby/prism] Ripper compat docs update - - https://github.com/ruby/prism/commit/5f70b32b02 - -commit b9f2c67106ac8277b0e83a5701a43d016d829131 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-05 00:03:45 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-05 00:27:26 +0900 - - [PRISM] Fix dependencies - -commit b5a62eb9abf7a69e6a7288eba880652d7cd075a4 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-05 00:13:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-05 00:13:40 +0900 - - YJIT: Mark and update stubs in invalidated blocks (#9104) - - Like in the example given in delayed_deallocation(), stubs can be hit - even if the block housing it is invalidated. Mark them so we don't - work with invalidate ISeqs when hitting these stubs. - -commit f40727f4aa32dd89cffc0474c7b8dac367e6b308 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-04 23:58:41 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-04 23:58:41 +0900 - - Make rb_obj_copy_ivs_to_hash_table_i static - -commit 1227b6d9129d7e978b6bb659c9cb320d47a2aac1 - Author: Lily Lyons <lily@nowaffles.com> - AuthorDate: 2023-12-02 06:00:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-04 23:33:44 +0900 - - [ruby/prism] Refactor pm_diagnostic_t and pm_comment_t to use pm_location_t - - https://github.com/ruby/prism/commit/115b6a2fc6 - -commit 2a65d8370702b3f2a5db21b65f21ccef6f0b503b - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-04 13:00:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-04 23:00:23 +0900 - - [ruby/prism] Check "void value expression" for array literals - - Fix https://github.com/ruby/prism/pull/1978 - - https://github.com/ruby/prism/commit/194c997d0a - -commit 85bc80a51be0ceedcc57e7b6b779e6f8f885859e - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-12-04 11:13:25 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-04 11:37:06 +0900 - - Revert "Add missing GVL hooks for M:N threads and ractors" - - This reverts commit ad54fbf281ca1935e79f4df1460b0106ba76761e. - -commit 9c5e1b71891dab66544de2fe3311c45ede014fdd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-04 10:39:17 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-04 10:39:17 +0900 - - Fix format specifiers for `size_t` - -commit 2e8a4470aef1c2061e781a915b485107df421e69 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-04 10:32:21 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-04 10:32:21 +0900 - - Remove `rb_libruby_selfpath` for MJIT - -commit 52eabf2e329485088672beefe4bc59c148ed20cc - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-12-04 02:06:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-04 02:06:41 +0900 - - [ruby/irb] Bump version to v1.10.0 - (https://github.com/ruby/irb/pull/798) - - https://github.com/ruby/irb/commit/4acc9b8d6c - -commit a2197466a273928f76e00e89b3a6f5fb23569fa6 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-12-03 23:05:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-03 23:05:16 +0900 - - [ruby/irb] Disable pager in eval_history test - (https://github.com/ruby/irb/pull/799) - - https://github.com/ruby/irb/commit/ee85e84935 - -commit d4b1f56f50903403cb75451215298ceb56f2302c - Author: jinroq <2787780+jinroq@users.noreply.github.com> - AuthorDate: 2023-12-03 06:17:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-03 06:17:53 +0900 - - [Fix] Support when nil is assigned to variable `name` (#9105) - - * Add `!name.nil?` to if condition - -commit ad54fbf281ca1935e79f4df1460b0106ba76761e - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-11-30 08:54:32 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-12-03 03:06:07 +0900 - - Add missing GVL hooks for M:N threads and ractors - - [Bug #20019] - - This fixes GVL instrumentation in three locations it was missing: - - Suspending when blocking on a Ractor - - Suspending when doing a coroutine transfer from an M:N thread - - Resuming after an M:N thread starts - - Co-authored-by: Matthew Draper <matthew@trebex.net> - -commit 715cf9b6902b0cc317fbc5cea0df153e14ff7277 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-12-03 02:46:57 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-03 02:46:57 +0900 - - [DOC] More on What's Here (#9099) - - * More on What's Here - - * More on What's Here - -commit d1691617d6d6a115db52e7861f584fe98039ed1b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-02 06:10:11 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-02 23:06:03 +0900 - - Pin instruction storage - - The operands in each instruction needs to be pinned because if - auto-compaction runs in iseq_set_sequence, then the objects could exist - on the generated_iseq buffer, which would not be reference updated which - can lead to T_MOVED (and subsequently T_NONE) objects on the iseq. - -commit 092a17e7bd97525904c2874228a7febcaea74bf7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-26 19:33:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-02 21:48:00 +0900 - - [DOC] Markup class name `Time` as code - -commit ae3e9f114c540e78f1166f67dfb3577966f21f7f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-26 19:29:17 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-02 21:46:52 +0900 - - [DOC] Include timezones document in timev.rb - - So that it can be referred as a part of the document of `Time`. - -commit c9c1670f7e7aaa17e69fd14d573f2f40ccd8a3da - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-02 21:24:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 21:40:12 +0900 - - [ruby/rdoc] Markup punctuations need to be separated with a space - - https://github.com/ruby/rdoc/commit/83f0149fc1 - -commit 4ee1f0fb5de08acd659ec18409fca433d1bf371a - Author: Gary Tou <gary@garytou.com> - AuthorDate: 2023-12-02 13:32:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 13:32:04 +0900 - - [ruby/irb] Implement `history` command - (https://github.com/ruby/irb/pull/761) - - * Implement `history` command - - Lists IRB input history with indices. Also aliased as `hist`. - - * Add tests for `history` command - - * Address feedback: `puts` with multiple arguments instead of `join`ing - - * Address feedback: Handle nil from splitting an empty input string - - * Refactor line truncation - - * Add `-g` grep option to `history` command - - * Add `history` command to README - - * Remove unused `*args` parameter - - * Allow spaces to be included in grep - - * Allow `/` to be included in grep regex - - * Handle `input` being an empty string - - * Exclude "#{index}: " from matching the grep regex - - * Add new line after joining - - https://github.com/ruby/irb/commit/3f9eacbfa9 - -commit 9f6c6f88c3b135a41efc3e76c4b3c012141ef8b1 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-12-01 18:02:56 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-12-02 08:58:32 +0900 - - Lrama v0.5.11 - -commit 818813c2bde674f85804891df380c271637c0c8e - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-02 04:52:38 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-12-02 07:56:25 +0900 - - Implement paren node for `defined?` - - Implements and adds a test for passing a parentheses node to `defined?`. - -commit 6ecc1ca9b1afc5e863f82db3bb23a1ef59469817 - Author: Ryan Davis <ryand-github@zenspider.com> - AuthorDate: 2023-12-02 07:51:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-02 07:51:08 +0900 - - [DOC] Update ARGF.readlines documentation to match/reference IO.readlines. - -commit 0aed37b973c66e9ff071a1f46944cb0c6151d2dc - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-01 00:51:51 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-02 07:13:56 +0900 - - Make expandarray compaction safe - - The expandarray instruction can allocate an array, which can trigger - a GC compaction. However, since it does not increment the sp until the - end of the instruction, the objects it places on the stack are not - marked or reference updated by the GC, which can cause the objects to - move which leaves broken or incorrect objects on the stack. - - This commit changes the instruction to be handles_sp so the sp is - incremented inside of the instruction right after the object is written - on the stack. - -commit 492c82cb417a92d1941f10b52e77ec0c4b2cc8a6 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-02 02:22:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 05:53:34 +0900 - - [ruby/prism] Prism.parse_success?(source) - - A lot of tools use Ripper/RubyVM::AbstractSyntaxTree to determine - if a source is valid. These tools both create an AST instead of - providing an API that will return a boolean only. - - This new API only creates the C structs, but doesn't bother - reifying them into Ruby/the serialization API. Instead it only - returns true/false, which is significantly more efficient. - - https://github.com/ruby/prism/commit/7014740118 - -commit b77551adee831302f22dc7d9fdccd597923511c4 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-02 05:21:01 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-02 05:21:01 +0900 - - Remove unneeded local variables - -commit 562d949e022cb3e7288256af8d0df3f4e17b66cb - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-12-02 03:59:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 05:10:58 +0900 - - [ruby/prism] Fix parsing heredoc ends - - https://github.com/ruby/prism/commit/aa8c702271 - -commit 39238888bc784eb5887d899dc09fad30997464ac - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-12-02 04:28:54 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-12-02 05:05:22 +0900 - - Implements missing literals for `defined?` - - This PR implements the following literals: - - - String - - Symbols - - Integers - - Floats - - Regexs - - Ranges - - Lambdas - - Hashes - - and tests for them. - -commit ee0eca191f3ca486b6056234add436a8c1488dba - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-01 04:48:26 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-02 05:04:31 +0900 - - Make String#undump compaction safe - -commit 80ea7fbad871b2222b16af1bd9f39e1f1828bbd4 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-01 04:47:09 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-02 05:04:31 +0900 - - Pin embedded shared strings - - Embedded shared strings cannot be moved because strings point into the - slot of the shared string. There may be code using the RSTRING_PTR on - the stack, which would pin the string but not pin the shared string, - causing it to move. - -commit 0ed55bf09713299201caec3ba9d9ef7ba6e8526f - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-11-28 07:06:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 04:50:03 +0900 - - [rubygems/rubygems] Reduce array allocations when loading definition - - The same array was being re-created in a loop (as well as the `generic_local_platform`), which is avoidable by hoisting it to a frozen array created once - - https://github.com/rubygems/rubygems/commit/009a3c6d0d - -commit a607d62d8c5786087916413c369dbde0c62db573 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-02 02:29:36 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-02 03:57:41 +0900 - - [Bug #20033] Dynamic regexp should not assign captures - -commit ec83bd7356d639fe34f6843c4f1805c63cfdfa49 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-02 02:06:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 03:46:52 +0900 - - [ruby/prism] Provide heredoc? queries - - https://github.com/ruby/prism/commit/e148e8fe6a - -commit 2a8d9c59ff151e8e2274e5f788745e070111b8ab - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-02 03:00:20 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-02 03:23:23 +0900 - - [PRISM] Account for RescueNodes with no statements - - We need a PUTNIL if a RescueNode has no statements. - -commit d6584a02011120c15b520fa08e5e5f0132b686de - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-01 02:57:49 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-02 03:07:59 +0900 - - [PRISM] Fix behavior of BlockParameters with only one parameter - - This commit sets the ambiguous param flag if there is only one - parameter on a block node. It also fixes a small bug with a trailing - comma on params. - -commit ef466ac931dcb37f98fc89eba526c2593e1cddb0 - Author: hogelog <konbu.komuro@gmail.com> - AuthorDate: 2023-12-02 03:03:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 03:04:03 +0900 - - [ruby/irb] Scrub past history input before split - (https://github.com/ruby/irb/pull/795) - - * Scrub past history input before split - - * Don't rewrite ENV["LANG"] - - https://github.com/ruby/irb/commit/0f344f66d9 - -commit 73440e1ef21e1dd7ca590e402d37b835b9b1f0bb - Author: Eric Mueller <nevinera@gmail.com> - AuthorDate: 2023-11-30 12:40:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 02:52:38 +0900 - - [rubygems/rubygems] Many major_deprecations supply :removed_message - - Generally the removed message is very similar, but often it needs to - specify that the feature has "been removed" instead of "will be - removed", or "been deprecated". And a few chunks of text needed more - substantial updates. And a number of them seemed to have been carefully - crafted to make sense in either context, so I left those alone. - - https://github.com/rubygems/rubygems/commit/8d42cf9104 - -commit 079dfa1812e0f23a74c86e271245504b069b4c17 - Author: Eric Mueller <nevinera@gmail.com> - AuthorDate: 2023-11-30 11:51:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 02:52:37 +0900 - - [rubygems/rubygems] major_deprecation accepts :removed_message - - If supplied, it uses that in place of the message for the case where the - deprecation version is already past. - - https://github.com/rubygems/rubygems/commit/1deb73663c - -commit e5e1f9813e23c427cf45a25181b2e6d3cf97411a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-01 22:58:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-02 02:41:39 +0900 - - [Bug #19838] Flush delayed token nonconsecutive with the next token - -commit add0ab07e8b5e8f271e7bffa21c650c38a46c7db - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-01 22:16:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-02 02:41:39 +0900 - - Extract `end_with_newline_p` - -commit 6e2b10d45653ed96529aafe981eae7e920110461 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-01 21:57:28 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-02 02:41:39 +0900 - - Prefer proper enum over bare int - -commit 9d209093429658664b476b7d0630463ec8748d2c - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-02 02:20:16 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-02 02:20:16 +0900 - - [PRISM] Clean up trailing comment - -commit d224618beac0ed53a2f177d396f0eb6640e1a772 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-12-01 06:18:14 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-12-02 02:14:54 +0900 - - [PRISM] Restructure parameters - - Prior to this commit, we weren't accounting for hidden variables - on the locals table, so we would have inconsistencies on the stack. - This commit fixes params, and introduces a hidden_variable_count - on the scope, both of which fix parameters. - -commit 5150ba0dbe98ca72f4ffb10de559b204b46eb56a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-02 00:51:41 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-02 02:03:09 +0900 - - [prism] Update to latest numbered parameters - -commit cdb74d74afb87a0d7048a53aaf12d32516033a3c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-01 10:47:08 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-02 02:03:09 +0900 - - [ruby/prism] Change numbered parameters - - Previously numbered parameters were a field on blocks and lambdas - that indicated the maximum number of numbered parameters in either - the block or lambda, respectively. However they also had a - parameters field that would always be nil in these cases. - - This changes it so that we introduce a NumberedParametersNode that - goes in place of parameters, which has a single uint8_t maximum - field on it. That field contains the maximum numbered parameter in - either the block or lambda. - - As a part of the PR, I'm introducing a new UInt8Field type that - can be used on nodes, which is just to make it a little more - explicit what the maximum values can be (the maximum is actually 9, - since it only goes up to _9). Plus we can do a couple of nice - things in serialization like just read a single byte. - - https://github.com/ruby/prism/commit/2d87303903 - -commit 90d9c20a0c0df5565d5f95d5e14c58331fa5922f - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-10 23:51:14 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-12-02 01:40:25 +0900 - - [PRISM] Compile RescueNode - -commit 8f3310dc7519682f382ed589c5c1ed5b41627451 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-02 00:23:07 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-02 00:23:07 +0900 - - Remove unused files in prism - -commit 64f33aea2b9afa85bb840e38b8130f738d56f1c3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-02 00:18:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 00:18:19 +0900 - - [ruby/prism] Update snapshots - - https://github.com/ruby/prism/commit/f4c80c67dc - -commit cbe57caa246f57440667a53b4526ddabcea82df9 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-12-01 12:53:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 00:17:20 +0900 - - [ruby/prism] Fix comments after HEREDOCs again. - - The problem was deeper than just looking back a single token. - You can push the heredoc_end token way back into the list. - We need to save the last location of a heredoc end to see if - it's the last token in the file. - - Fixes https://github.com/ruby/prism/pull/1954 - - https://github.com/ruby/prism/commit/91dfd4eecd - -commit ffeec108cfccda71ff63167d41f090aa39c2432c - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-01 23:55:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 00:15:28 +0900 - - [ruby/prism] Add missing context names to the switch in `debug_context` - - Now, `PM_DEBUG_LOGGING` can be available. - - https://github.com/ruby/prism/commit/569ffacb5f - -commit 417d7004062de3360d0ab104bc21c5e3b40eff86 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-01 23:35:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 00:15:01 +0900 - - [ruby/prism] Improve to handle unterminated strings - - Fix https://github.com/ruby/prism/pull/1946 - - This fixes to set an error position for unterminated strings to the - opening delimiters. Previously, the error position was set to the end - of the delimiter. - - The same fix applies to other string-like literals. - - Additionally, this fixes https://github.com/ruby/prism/pull/1946; that is, it adds the last part of the - string even though the string literal does not terminate. - - https://github.com/ruby/prism/commit/c1240baafd - -commit 0e599336a20d698d2d7f62ed6db234124260e2cd - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-12-01 23:50:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-02 00:13:45 +0900 - - [ruby/prism] Fix `not_provided` comment - - I don't know when it is changed, but the `not_provided` signature is - changed. - - https://github.com/ruby/prism/commit/0255cc307d - -commit 3b21932d14a354eaedb1fdbe068efdfdc758a6ac - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-01 22:34:21 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-12-02 00:04:13 +0900 - - [PRISM] Use depth_offset not transparent scopes for FOR - -commit ce5f5ca1d64f92e6d7a79dd73930a71d9d00513e - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-12-01 22:34:05 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-12-02 00:04:13 +0900 - - [PRISM] Remove transparent scope nodes - -commit 43ef0da0fb308c937dd0261d5204bd72e8b6867a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-01 23:56:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-01 23:56:32 +0900 - - Add assertions for shape cache grandchild nodes - -commit 64c4bbb86cf5c2a7710bef4d481c6a05f780c632 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-01 18:12:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-01 20:33:26 +0900 - - [ruby/prism] Add test/prism/snapshots/heredoc_with_comment.txt - - https://github.com/ruby/prism/commit/97b296a0f7 - -commit 7d142c08cb5b65e4ba110b116c41a8e5e3acc027 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-01 16:46:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-01 16:47:06 +0900 - - lib/helper only needs on flori/json repo - -commit 86045fca24be94db7a9cbf7a9126e43c212dcc55 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-01 15:51:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-01 16:47:06 +0900 - - Manually merged from flori/json - - > https://github.com/flori/json/pull/525 - > Rename escape_slash in script_safe and also escape E+2028 and E+2029 - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - - > https://github.com/flori/json/pull/454 - > Remove unnecessary initialization of create_id in JSON.parse() - - Co-authored-by: Watson <watson1978@gmail.com> - -commit 0dfeb172968cdaefca2ab828c94d3e5f44d91f8f - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-04-14 02:22:29 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-01 16:47:06 +0900 - - Rename escape_slash in script_safe and also escape E+2028 and E+2029 - - It is rather common to directly interpolate JSON string inside - <script> tags in HTML as to provide configuration or parameters to a - script. - - However this may lead to XSS vulnerabilities, to prevent that 3 - characters need to be escaped: - - - `/` (forward slash) - - `U+2028` (LINE SEPARATOR) - - `U+2029` (PARAGRAPH SEPARATOR) - - The forward slash need to be escaped to prevent closing the script - tag early, and the other two are valid JSON but invalid Javascript - and can be used to break JS parsing. - - Given that the intent of escaping forward slash is the same than escaping - U+2028 and U+2029, I chos to rename and repurpose the existing `escape_slash` - option. - -commit 698cb8406298ff289ba7abadf34abc3d09a07ef0 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-02-20 19:09:32 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-01 16:47:06 +0900 - - Use ruby_xfree to free buffers - - They are allocated with ruby_xmalloc, they should be freed with - ruby_xfree. - -commit 32f289d118b442a712af28c2af44384f5cb07db1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-12-01 14:58:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-01 16:47:06 +0900 - - [flori/json] Bump up 2.7.0 - - https://github.com/flori/json/commit/ca546128f2 - -commit 4b770527c2d4287456d03d645b595662f2501d67 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2022-09-20 09:56:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-01 16:47:06 +0900 - - [flori/json] Fix "unexpected token" offset for Infinity - - Previously in the JSON::Ext parser, when we encountered an "Infinity" - token (and weren't allowing NaN/Infinity) we would try to display the - "unexpected token" at the character before. - - https://github.com/flori/json/commit/42ac170712 - -commit 854e6559b6dcda9dcbd6687aef1a3ac0c0c90cac - Author: Lucas Kanashiro <lucas.kanashiro@canonical.com> - AuthorDate: 2022-11-11 05:21:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-01 16:47:06 +0900 - - [flori/json] tests/ractor_test.rb: make assert_separately available - - Require tests/lib/helper.rb to avoid: - - NoMethodError: undefined method `assert_separately' - - https://github.com/flori/json/commit/a81bcc0328 - -commit e36b9760fd0eb3bffbf1536106ce3cce02816c1f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-01 14:52:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-01 15:04:30 +0900 - - Dispatch invalid hex escape content too - -commit d503e1b95a40e45d7767e0175de60092de4ba54e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-12-01 13:04:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-12-01 15:04:30 +0900 - - [Bug #20030] dispatch invalid escaped character without ignoring it - -commit 52c2660163240a494b65eb9942c3978896ed807b - Author: Misaki Shioi <shioi.mm@gmail.com> - AuthorDate: 2023-12-01 10:23:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-01 12:20:03 +0900 - - Fixup with review comment - - https://github.com/ruby/ruby/pull/9088#discussion_r1411490445 - -commit 1bfd30a1e3fa2c1d2729667ed698b7c604c2a1bd - Author: Misaki Shioi <shioi.mm@gmail.com> - AuthorDate: 2023-12-01 09:31:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-12-01 12:20:03 +0900 - - Relax test conditions to velify Socket::ResolutionError#error_code - - The test for Socket::ResolutionError#error_code fails in the FreeBSD environment with this test condition. Because Socket::ResolutionError#error_code returns Socket::EAI_FAIL instead of Socket::EAI_FAMILY. - - https://rubyci.s3.amazonaws.com/freebsd12/ruby-master/log/20231130T103002Z.fail.html.gz - - This PR avoids the test failure by relaxing the condition. - - Also changed the domain for testing to `example.com`. - -commit e2bbbacc233b1b1c13298baff9eacfe1ef0052f4 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-01 10:59:00 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] Correctly pass around const pm_encoding_t * - - https://github.com/ruby/prism/commit/ce4c67fb3a - -commit b4a85e402f0f4d33a3dd3eb58b6312207549d415 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-01 05:42:47 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [PRISM] Fix up prism encoding targets - -commit 99a147ff4fbfda6f15d8b6bcfd61d5776a58be2b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-01 02:52:42 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] Document remaining encodings - - https://github.com/ruby/prism/commit/b9510aed40 - -commit 0c277f2b7659076f18487132aef2cf40d4c608e7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-01 02:50:49 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] Group encodings into a single array - - https://github.com/ruby/prism/commit/f4b7beadc9 - -commit 6b234c1acf1b89198b1a7ad5f3aeb71057b4becc - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-01 02:00:44 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] Do not expose encodings that do not need to be exposed - - https://github.com/ruby/prism/commit/c52c7f37ea - -commit ea409958b38424f296aacc5c2d8d7bf3bcd1d2db - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-01 01:40:13 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] Remove ability to decode other encodings - - https://github.com/ruby/prism/commit/98e218d989 - -commit 997083188b8f7c2b058544a805a0dec83ea5483d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-01 01:38:11 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] Remove public ASCII functions that can now be static - - https://github.com/ruby/prism/commit/9461384b0c - -commit abb1fe286804a35fc4cbcc431434f9e5b42c544f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-01 01:36:10 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [PRISM] Consolidate prism encoding files - -commit 19a321bff0b12516f6fff644c3642627a6fcebae - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-12-01 01:06:40 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] CESU encoding - - https://github.com/ruby/prism/commit/2d5b9c2b3c - -commit ca26e0e34bcf41b5ce60f15dc5db5bae8bb36305 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-30 23:21:48 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] EUC-TW encoding - - https://github.com/ruby/prism/commit/edfb54f039 - -commit dde0abb29ea119e5ae5ce7a01b9d007ce5403a37 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-30 22:02:26 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] Shorter function definitions in pm_big5.c - - https://github.com/ruby/prism/commit/7ddf651bab - -commit 32249c2cf141158b02f51a41e0dfb36b78c424f4 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-30 11:45:25 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] GB18030 encoding - - https://github.com/ruby/prism/commit/ca3ab7ec89 - -commit a9162a44c59d85a56930e78cf1801558984db4a7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-30 11:01:10 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] Emacs MULE encodings - - https://github.com/ruby/prism/commit/4c06b6c42e - -commit 10d3897e13f87569d6a682336141330371a902e3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-30 04:25:40 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [PRISM] Big5 encodings - -commit 700e172a501d96ed3efe627b6a91b7890b32d2f4 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-30 04:10:20 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] EUC-KR encodings - - https://github.com/ruby/prism/commit/ba5218385a - -commit ddaa0730588a2c2947f6e59e91ca88b37e97f42a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-30 03:54:49 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] Support other EUC-JP encodings - - https://github.com/ruby/prism/commit/d040337ce9 - -commit 7b5bb978fb8aefb77c731b0a48386fc139413b13 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-30 02:53:42 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [PRISM] Alias CP51932 to EUC-JP - -commit 9ba92327f2aed5b5d95ad1ce51fe695f14a3428e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-30 01:42:47 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [PRISM] Consolidate SJIS encodings - -commit 219c3c1c09417d99e9de295c15a9deb8d158ff86 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-30 01:18:38 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-12-01 11:37:56 +0900 - - [ruby/prism] Add other UTF8 encodings - - https://github.com/ruby/prism/commit/709fb6e09f - -commit ba1cdadfc8ad6f284efeefbcebef1ca85bae178c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-01 11:35:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-01 11:35:55 +0900 - - YJIT: Cancel on-stack jit_return on invalidation (#9086) - - * YJIT: Cancel on-stack jit_return on invalidation - - Co-authored-by: Alan Wu <alansi.xingwu@shopify.com> - - * Use RUBY_VM_CONTROL_FRAME_STACK_OVERFLOW_P - - --------- - - Co-authored-by: Alan Wu <alansi.xingwu@shopify.com> - -commit 5888a16a125e573c1749000b343d41db76289c15 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-12-01 08:54:32 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-12-01 09:19:43 +0900 - - YJIT: Use `stats[:live_page_count]`, renamed from :compiled_page_count - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - -commit 59f31a66180b8b118c93cdb3dad20e467b18f7fc - Author: Alan Wu <alanwu@ruby-lang.org> - AuthorDate: 2023-12-01 08:46:00 +0900 - Commit: Alan Wu <alanwu@ruby-lang.org> - CommitDate: 2023-12-01 08:46:00 +0900 - - NEWS: Adjust indentation for RDoc's markdown parser - - Indenting by 2 spaces wasn't yielding nested list up as intended. I guess - it's a quirk of RDoc's markdown parser: - - https://github.com/ruby/rdoc/blob/v6.6.0/lib/rdoc/markdown.kpeg#L1128-L1130 - - NonindentSpace = / {0,3}/ - Indent = /\t| / - IndentedLine = Indent Line - -commit c3cb27eede43ccdabfe1c367c56c27d654a80a2d - Author: Alan Wu <alanwu@ruby-lang.org> - AuthorDate: 2023-12-01 08:28:11 +0900 - Commit: Alan Wu <alanwu@ruby-lang.org> - CommitDate: 2023-12-01 08:28:11 +0900 - - NEWS update about calling Kernel#lambda with non-literal block - -commit 73e6d8a0d0a05bdf778502af639de32869dd41b3 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-12-01 07:14:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-01 07:14:53 +0900 - - YJIT: optimized codegen for `rb_ary_length()` (#9085) - - YJIT: optimized codegen for rb_ary_length() - -commit 4541e192d947f5ca6502a9594e4820ed5b177c86 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-01 06:48:51 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-01 06:48:51 +0900 - - Add assertions in redblack_balance - - These assertions check that binary search tree invariants are held for - the new tree. - -commit 0c7c654b4da008fe18ebc822b1d76ee656eded01 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-30 21:05:48 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-12-01 06:31:57 +0900 - - [Prism] Fix local variable access for POST_EXECUTION_NODE - -commit 57782d3d47bcb52af0006ac75e75f3b3609b1d31 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-30 20:05:26 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-12-01 06:31:57 +0900 - - Store depth offset inside the scope node. - - Instead of incrementing the depth using call by reference as we're - recursing up the stack we could instead store an offset for each known - scope where we know the depth is going to represented differently in the - Prism ast. - -commit a1647c460f253cbf2c988f5f8bcf43bf23f576be - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-12-01 00:13:20 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-12-01 05:41:08 +0900 - - Rename variables redblack_balance - - It's too difficult for me to keep track that y is the new node, x is the - new left node, z is the new right node, a is the new left left node, - b is the new left right node, c is the new right left node, and d is - the new right right node. This commit refactors the variable names to be - more descriptive. - -commit 7008d97b76649928cd5552eb0f44a496d468daf0 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-11-30 08:49:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-01 04:58:40 +0900 - - [rubygems/rubygems] Only show "Defaulting to user installation" message when it matters. - - https://github.com/rubygems/rubygems/commit/61b0947225 - -commit 060f14bf62ad3f426a6666901c45b82d4334fa26 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-12-01 02:53:01 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-01 03:40:40 +0900 - - Update documentation for [[:word:]] and \p{Word} in regexps - - Onigmo uses Decimal_Number and not Number for these. - - Fixes [Bug #19417] - -commit f75fef66221e55ce9e9e302cfd8ee22062527c6c - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-12-01 03:33:40 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-12-01 03:34:57 +0900 - - Mention {Queue,SizedQueue}#freeze change in NEWS - -commit 0d1917aead71dde00f08ebbc7c041e788663fc1b - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-30 23:55:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-01 02:42:24 +0900 - - [ruby/prism] Remove no-op assignment - - https://github.com/ruby/prism/commit/4b3079d9e8 - -commit 85092ecd6f5c4d12d0cb1d6dfa7040337a4f558b - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-30 08:10:13 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-12-01 01:59:32 +0900 - - Fix imemo_env corruption under auto compaction - - Previously, vm_make_env_each() did: - 1. ALLOC env_body - 2. Copy locals into env_body - 3. Allocate imemo_env - 4. Set up imemo_env with env_body - - If compaction runs during (3), locals copied to env_body could be - moved and the imemo_env could end up with invalid references. - - Move (2) down so it reads references after potential movement. - -commit d048bae96b4108104cd0e77aad44962a39a5796f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-12-01 01:23:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-12-01 01:23:25 +0900 - - YJIT: Bump ec->cfp after setting cfp->jit_return (#9072) - -commit f193f96d31ffcd02d91f135ba765d92c23b52c55 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-12-01 00:22:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-01 00:22:22 +0900 - - [ruby/irb] Page evaluation result's output - (https://github.com/ruby/irb/pull/784) - - * Page evaluation result's output - - This will make it easier to work with long output that exceeds the terminal's height. - - * Use consistent TERM in rendering tests - - This makes sure we get consistent result on all platforms. - - https://github.com/ruby/irb/commit/4fedce93d3 - -commit cc393b4f80be7eccdc84785f684dc7899b0510e4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-29 12:30:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-12-01 00:06:51 +0900 - - [ruby/rdoc] Get rid of `Kernel#open` - - https://github.com/ruby/rdoc/commit/dc56f6d0bd - -commit 3c5a3b73f1126f3e05e85a20f3991bb6c22b4be3 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-30 16:28:41 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-30 23:48:21 +0900 - - Highlight some GC improvements in NEWS - - 3.3. got some major GC changes that do translate in very meaningful - performance gains, we should surface that. - -commit 630c97acc74701724b3a1beb3f92aae192c69769 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-11-30 07:39:26 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-30 23:48:14 +0900 - - Add a rescue for `defined?(A::B::C)` - - It's possible for `defined?(A::B::C)` to raise an exception. `defined?` - must swallow the exception and return nil, so this commit adds a rescue - entry for `defined?` expressions on constant paths - -commit 2c64041ed5de8cb040fbc62e126055e553bcf5db - Author: sid-707 <95631365+sid-707@users.noreply.github.com> - AuthorDate: 2023-11-30 12:57:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-30 23:10:28 +0900 - - [ruby/prism] Fix typo in comment - - https://github.com/ruby/prism/commit/eb1a6ba263 - -commit aac8be803409a18f6c32b438d154432eeb6f49e8 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-11-30 13:02:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-30 23:10:04 +0900 - - [ruby/prism] Fix lex_compat for `<<HEREDOC # comment` at EOF - - Fixes https://github.com/ruby/prism/pull/1874 - - https://github.com/ruby/prism/commit/304dd78dd2 - -commit 1802d14ca8924bd67e0915c5ad9f1fad5dba0602 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-30 19:04:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-30 21:40:22 +0900 - - [Bug #19877] Assign captures for direct regexp literal only - -commit 0cdad3b92a7e117bc7e36779140f5c83b07ca7ce - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-26 19:09:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-30 21:39:28 +0900 - - Add `RUBY_REFERENCES` - - Instead of `RUBY_REFERENCES_START` and `RUBY_REFERENCES_END`, so that - auto-indent works well. - -commit 30f7b7a0535575a4995ea59086830ee19c79ea82 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-26 16:04:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-30 21:39:28 +0900 - - Prefix `REF_EDGE` and `REFS_LIST_PTR` with `RUBY_` - - Also move `struct` so that `typedef`-ed names can be used. - -commit 18f218d6a14f1a4744327d814554bfda04f1f119 - Author: OKURA Masafumi <masafumi.o1988@gmail.com> - AuthorDate: 2023-11-26 18:06:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-30 21:35:04 +0900 - - Add some test cases to Data test - - I noticed that `deconstruct` and `hash` don't have enough coverage. - The behavior of `hash` is documented so I copied it. - -commit 722cb9a56d091a10fd6ff9eddfcc7773f06a393e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-30 20:17:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-30 20:17:27 +0900 - - Skip test_resolurion_error_error_code with FreeBSD environment - - https://rubyci.s3.amazonaws.com/freebsd12/ruby-master/log/20231130T103002Z.fail.html.gz - -commit e1b65e5f918744a2f2615feaa4ae39e1fb485651 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-30 18:35:35 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-30 19:05:55 +0900 - - Add NEWS entry for the deprecation of subprocess creation/forking - - [Feature #19630] - -commit 5259edaff9911cacb3fd656b2744d5ec6bce655d - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-30 15:53:06 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-30 17:23:31 +0900 - - Add NEWS entry for WeakMap#delete and `RUBY_CRASH_REPORT` - - I wasn't too sure where to put `RUBY_CRASH_REPORT`, it's not exactly - a command line option but close enough. - -commit 30e477802094e1c47fb5946b79aeeebb3b3ebec5 - Author: flosacca <flosacca@gmail.com> - AuthorDate: 2023-11-23 02:49:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-30 17:19:28 +0900 - - [ruby/cgi] Fix unescapeHTML - - https://github.com/ruby/cgi/commit/67610e6ca8 - -commit 0daa0589a9b714201a9460fef1bcf5260bc3c6ae - Author: flosacca <flosacca@gmail.com> - AuthorDate: 2023-11-28 05:22:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-30 17:19:28 +0900 - - [ruby/cgi] Add failing test cases for CGI::Escape.unescapeHTML - - https://github.com/ruby/cgi/commit/92fdb3316b - -commit f2f91396576146f58ec299a6d8e5acf665493aa9 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-30 15:38:49 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-30 15:38:49 +0900 - - Move #19785 correct category in NEWS - -commit f2ad246071ed6a111d22cf763c5dd170d581c824 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-11-30 13:38:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-30 13:38:07 +0900 - - Update bundled gems list as of 2023-11-29 - -commit e6d4441618161397610088192c65b42f217d4e38 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-30 13:36:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-30 13:36:11 +0900 - - Fix the argument order - -commit 5baa2b96509118710cd1b425457f11ad574168ee - Author: Misaki Shioi <shioi.mm@gmail.com> - AuthorDate: 2023-11-29 21:08:37 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-30 13:27:19 +0900 - - Make test-bundled-gems success - -commit f98293171901678a4e64b01ba0d7ee5804236c13 - Author: Misaki Shioi <shioi.mm@gmail.com> - AuthorDate: 2023-11-23 18:54:37 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-30 13:27:19 +0900 - - Fix failing spec - -commit 5f62b1d00ce8ca56ad624963ebdf01c572e73efc - Author: Misaki Shioi <shioi.mm@gmail.com> - AuthorDate: 2023-11-23 16:52:18 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-30 13:27:19 +0900 - - Rename rsock_raise_socket_error to rsock_raise_resolution_error - - Again, rsock_raise_socket_error is called only when getaddrinfo and getaddrname fail - -commit 52f6de41961d511e82826d6266441d91a92dcd59 - Author: Misaki Shioi <shioi.mm@gmail.com> - AuthorDate: 2023-11-23 16:49:41 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-30 13:27:19 +0900 - - Replace SocketError with Socket::ResolutionError in rsock_raise_socket_error - - rsock_raise_socket_error is called only when getaddrinfo and getaddrname fail - -commit e9050270d7d8b1bc6be2c1352772b906031adc6e - Author: Misaki Shioi <shioi.mm@gmail.com> - AuthorDate: 2023-11-23 16:30:37 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-30 13:27:19 +0900 - - Add Socket::ResolutionError & Socket::ResolutionError#error_code - - Socket::ResolutionError#error_code returns Socket::EAI_XXX - -commit db7f3064a8fce5a59e4ed0565273d8d43e27d52c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-23 03:29:54 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-30 12:51:13 +0900 - - Implement proc_entry on VWA - -commit 40e67cb20e2da8eda655f3164e75fdc504042e95 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-23 01:11:08 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-30 12:51:13 +0900 - - Implement Write Barriers on proc_entry - -commit 705a3c69d7956b071d85bd785b8b61ffdf96c525 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-23 01:08:13 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-30 12:51:13 +0900 - - Add RUBY_TYPED_FREE_IMMEDIATELY flag to proc_entry - -commit 62e2e1da920d15e755f1826b3703ca81366526d8 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-11-28 06:57:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-30 12:41:15 +0900 - - [rubygems/rubygems] Allow auto-install to install missing git gems - - Currently, auto-install with git gems fails, when - it would succeed with a rubygems-source gem - - Fix the issue by doing the same fallback for git errors as we do for - missing gems, the git errors should only bubble up in these cases when - the gem is not installed, meaning we want to go through the install flow - (and any persistent errors will be raised through there) - - https://github.com/rubygems/rubygems/commit/e25a339f7a - -commit f2bb5394596c96ce5d7ff415694f3fc83715a96b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-30 12:20:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-30 12:21:25 +0900 - - Manually sync with https://github.com/ruby/open3/pull/22 and related PRs - -commit 7174c62f6b7a87b8d1fd12adc8569684ae4d8249 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-21 21:51:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-30 12:11:19 +0900 - - [prism] Remove escaping C source files - -commit 3d908a41ab67e2aeced7dc6b9773a017bb859253 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-29 03:50:05 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-30 09:21:40 +0900 - - Guard match from GC in String#gsub - - We need to guard match from GC because otherwise it could end up being - reclaimed or moved in compaction. - -commit 8d1138c1cf087f28510f4532c746e70c54d0f81e - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-11-30 08:09:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-30 08:09:55 +0900 - - YJIT: edit `yjit.md` and bring it up to date (#9068) - - Also make various minor edits to improve readability. - -commit 128837e4a28bda89c6a6766b3f243b5a47910d9c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-30 00:54:27 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-30 07:54:58 +0900 - - Support RUNRUBY_USE_RR for rr debugger - -commit aee275165b35c75f7ba889752273844616a9c8f5 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-30 00:52:04 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-30 07:54:58 +0900 - - debugger can never be nil - -commit 2927c280950924c0aaa6c1a5805b2978b177809e - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-11-28 07:01:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-30 06:28:46 +0900 - - [rubygems/rubygems] Avoid re-compiling static regexp in a loop - - Pathname::SEPARATOR_PAT is a constant and can safely be interpolated once, avoiding creating a new regexp object on every iteration - - https://github.com/rubygems/rubygems/commit/75d9c0f1e4 - -commit 8234763816eecd42da3b5e893cd236b64e6fc0fb - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-30 05:02:32 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-30 06:20:30 +0900 - - [PRISM] Compile empty array as newarray 0 - - Prior to this commit, we were compiling an empty array as a - duparray of [] which meant we were allocating a new value - unnecessarily. With this commit, we emit a newarray with size 0 - instead. - -commit 853fd44745241398d182d2af3ebdea10640ebf2e - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-30 04:58:26 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-30 06:19:14 +0900 - - [PRISM] Implement CallNodes with splat followed by args - -commit 2233204cc17521b960dad8b3758e6e0631a13672 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-30 05:50:46 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-30 06:14:28 +0900 - - [PRISM] Account for ImplicitRestNode - - Prism introduced a new ImplicitRestNode. This adds tests for the - ImplicitRestNode cases, and changes one assert which is no longer - accurate. - -commit 53841941f0e9bce92116c673e3d5426d94573103 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-30 04:12:31 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-30 06:00:00 +0900 - - [PRISM] Fix EnsureNode, pass depth to get locals - - This commit fixes a bug with locals in ensure nodes by setting - the local tables correctly. It also changes accessing locals to - look at local tables in parent scopes, and account for this - correctly on depths of get or setlocals. - -commit 6ebcf25de2859b5b6402b7e8b181066c32d0e0bf - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-30 00:05:19 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-30 02:30:12 +0900 - - GC guard catch_table_ary in iseq_set_exception_table - - The function iseq_set_exception_table allocates memory which can cause - a GC compaction to run. Since catch_table_ary is not on the stack, it - can be moved, which would make tptr incorrect. - -commit 14761edbf6ae6e6b8d5339ebceeee1754fb453a4 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-30 01:31:19 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-30 02:08:15 +0900 - - [prism] Add MacJapanese encodings to common.mk - -commit 9fc40d2b26fad25960eff6dd4d35d6592f6faaef - Author: Matt Boldt <me@mattboldt.com> - AuthorDate: 2023-11-29 00:19:25 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-30 02:08:15 +0900 - - [ruby/prism] Add MacJapanese encoding - - MacJapanese (also aliased as MacJapan) is a modified Shift_JIS - encoding, but is implemented identically in Ruby - - https://github.com/ruby/prism/commit/9e0a097699 - -commit 86d9a6dcb61b47bcacfe98200cb6d47da6bb1134 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-11-30 01:30:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-30 01:30:13 +0900 - - [ruby/irb] Use gem repl_type_completor, remove type_completion - implementation - (https://github.com/ruby/irb/pull/772) - - https://github.com/ruby/irb/commit/a4868a5373 - -commit b549722eefaf1d7b43b607d96778f82fecc92e43 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-30 00:31:23 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-30 01:15:50 +0900 - - [prism] Add pm_cp950 to make targets - -commit 9fada99cb24d9ddd7147b048776f8e0a9d7b967f - Author: Dhaval <anarock@MacBook-Pro.local> - AuthorDate: 2023-11-29 09:25:29 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-30 01:15:50 +0900 - - [ruby/prism] added CP950 encoding - - https://github.com/ruby/prism/commit/9c2d1cf4ba - -commit 57cb47bfe2df3fc4300b39875c40a7fe0879effb - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-30 00:30:00 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-30 00:30:00 +0900 - - Assert that the left and right nodes are correct - -commit b632732bcf901360560555fea3d9d88811252f0d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-29 23:42:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-30 00:24:41 +0900 - - [ruby/prism] Fixed comment on pm_parser_numbered_parameters_set - - https://github.com/ruby/prism/commit/ceae5727b8 - -commit 38e6442f8cf7bc70f8f1262d591011dc78b337d9 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-29 22:59:53 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-29 22:59:53 +0900 - - Add missing assertion in test_use_all_shapes_then_freeze - -commit 2af82e23165180f20ca2af374aedb7a45dedcc20 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-11-29 19:46:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-29 22:56:19 +0900 - - [ruby/prism] Convert start line to signed integers - - Ruby allows for 0 or negative line start, this is often used - with `eval` calls to get a correct offset when prefixing a snippet. - - e.g. - - ```ruby - caller = caller_locations(1, 1).first - class_eval <<~RUBY, caller.path, caller.line - 2 - # frozen_string_literal: true - def some_method - #{caller_provided_code_snippet} - end - RUBY - ``` - - https://github.com/ruby/prism/commit/0d14ed1452 - -commit 2653404840952d25bbdd7deaf599fbfb1f5287f0 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-11-29 17:56:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-29 22:56:18 +0900 - - [ruby/prism] Rename varint as varuint - - Line numbers may be negative, so we need to introduce signed varint, - so renaming unsigned ones first avoid confusion. - - https://github.com/ruby/prism/commit/90d862361e - -commit 8e93bf8e1fbac73b677c333b19a8b55ae9daddc3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-29 20:16:36 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-29 20:16:36 +0900 - - [Bug #17037] Improve accuracy of division near precision limits - - When dividing near the precision limit of `double`, use Bignum - division to get rid of rounding errors. - -commit 79eb75a8dd64848f23e9efc465f06326b5d4b680 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-29 14:40:21 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-29 14:40:21 +0900 - - [Bug #20025] Check if upper/lower before fallback to case-folding - -commit bd2b6b702cf43fb25562bdf8b1929d06ed3fcd98 - Author: Michael Go <michael.go@shopify.com> - AuthorDate: 2023-11-29 00:37:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-29 11:21:38 +0900 - - [rubygems/rubygems] update Magnus library in Rust extension gem template - - https://github.com/rubygems/rubygems/commit/46f09800da - -commit a908cef53f4c647c7fe7c9e808b501c3bb3cc70f - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-29 10:32:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-29 11:03:06 +0900 - - [ruby/prism] Reject class/module defs in method params/rescue/ensure/else - - Fix https://github.com/ruby/prism/pull/1936 - - https://github.com/ruby/prism/commit/232e77a003 - -commit fcabe2df39b892458cb1f67437852c4acbb245a6 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-29 10:41:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-29 10:41:40 +0900 - - Remove written-but-never-read `me->def.body.refined.owner` - - This also removes aliasing rule violations; the anonymous structs were - distinct types from `rb_method_refined_t`. - -commit bed014e374c6a4a7cec15a18e9dd702b674706d9 - Author: Tema Bolshakov <either.free@gmail.com> - AuthorDate: 2023-11-28 21:35:38 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-29 09:39:15 +0900 - - Do not call the implicit convercion spec on older ruby versions - -commit 9c900771daa5e44d3be0d3c1d1e53e76763cfabb - Author: Tema Bolshakov <either.free@gmail.com> - AuthorDate: 2023-11-28 20:35:14 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-29 09:39:15 +0900 - - Fix Array#rassoc spec - -commit e4a11a1283da07fd1d94535298c605caf299a834 - Author: Tema Bolshakov <either.free@gmail.com> - AuthorDate: 2023-11-13 05:12:16 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-29 09:39:15 +0900 - - Array#rassoc should try to convert to array implicitly. Fixes #20003 - -commit 10f44dfeff631e4298461493514229c0d744bebe - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-28 23:26:55 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-29 07:43:22 +0900 - - Fix Ractor sharing for too complex Objects - -commit 6eb5a9cf8f99b64d97d26b41011c03b846317d3e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-28 23:26:41 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-29 07:43:22 +0900 - - Fix Ractor sharing for too complex generic ivars - -commit 49383901772f874569bbdc992867bd02b4b597a8 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-29 05:49:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-29 07:33:50 +0900 - - [ruby/prism] Implicit rest nodes - - Fundamentally, `foo { |bar,| }` is different from `foo { |bar, *| }` - because of arity checks. This PR introduces a new node to handle - that, `ImplicitRestNode`, which goes in the `rest` slot of parameter - nodes instead of `RestParameterNode` instances. - - This is also used in a couple of other places, namely: - - * pattern matching: `foo in [bar,]` - * multi target: `for foo, in bar do end` - * multi write: `foo, = bar` - - Now the only splat nodes with a `NULL` value are when you're - forwarding, as in: `def foo(*) = bar(*)`. - - https://github.com/ruby/prism/commit/dba2a3b652 - -commit ea3e17e430b74b4e58535a707319025e008cc123 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-11-29 07:27:11 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-29 07:27:11 +0900 - - YJIT: fix bug in top cfunc logging in `--yjit-stats` (#9056) - - YJIT: correctly handle case where there are no cfunc calls - - Fix bug in top cfunc logging in `--yjit-stats` - -commit a9c07cbd2128ae8fcb11862265d5fa24feaf3d4f - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-29 06:12:19 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-29 07:01:34 +0900 - - [PRISM] Don't calculate params size based on locals - - Prior to this commit, we were conflating the size of the locals - list with the number of parameters. This commit distinguishes - the two, and fixes a related bug which would occur if we set a local - that was not a parameter - -commit 04cbcd37b1c18c4db4b9df8d80abb4efec11755c - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-29 05:42:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-29 06:08:46 +0900 - - [ruby/prism] Add numbered_parameters field to BlockNode and LambdaNode - - We are aware at parse time how many numbered parameters we have - on a BlockNode or LambdaNode, but prior to this commit, did not - store that information anywhere in its own right. - - The numbered parameters were stored as locals, but this does not - distinguish them from other locals that have been set, for example - in `a { b = 1; _1 }` there is nothing on the AST that distinguishes - b from _1. - - Consumers such as the compiler need to know information about how - many numbered parameters exist to set up their own tables around - parameters. Since we have this information at parse time, we should - compute it here, instead of deferring the work later on. - - https://github.com/ruby/prism/commit/bf4a1e124d - -commit 6310522a9a33c19e963e56a8f87388d802525937 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-11-29 05:04:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-29 05:04:33 +0900 - - YJIT: reduce default exec-mem-size to 64MiB (#9054) - -commit 982641939cf709d22dbc060df57cbed31acd3b97 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-28 19:03:13 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-29 04:06:55 +0900 - - Further fix the GVL instrumentation API - - Followup: https://github.com/ruby/ruby/pull/9029 - - [Bug #20019] - - Some events still weren't triggered from the right place. - - The test suite was also improved a bit more. - -commit 7bd172744f7e40b6f840f2b9d35e73f5020a3005 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-29 01:33:40 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-29 04:03:57 +0900 - - [PRISM] Implement more compilation of SplatNodes - - There was a bug with the rest argument in SplatNodes, this commit - fixes it, and adds more tests illustrating the behavior of - SplatNodes - -commit 2760f2377425e2b04cc6c25df179525b43176e50 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-28 05:55:15 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-29 04:02:53 +0900 - - [PRISM] Compile YieldNode with different arguments - -commit cb70994b0e91448f5904c3dda51c7b2f79b1d28e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-29 03:37:38 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-29 03:37:38 +0900 - - Assert node inserted into red-black tree exists - -commit cd4207869ff831c41db3ec873b175369ffca080a - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-28 09:19:41 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-29 03:03:04 +0900 - - Fix cache incoherency for ME resolved through VM_METHOD_TYPE_REFINED - - Previously, we didn't invalidate the method entry wrapped by - VM_METHOD_TYPE_REFINED method entries which could cause calls to - land in the wrong method like it did in the included test. - - Do the invalidation, and adjust rb_method_entry_clone() to accommodate - this new invalidation vector. - - Fix: cfd7729ce7a31c8b6ec5dd0e99c67b2932de4732 - See-also: e201b81f79828c30500947fe8c8ea3c515e3d112 - -commit 0704f40787d306b00db6bbdfee7e13ee172f600a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-29 02:35:11 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-29 02:35:11 +0900 - - Add in missing error - -commit 7b057211670c05134f107cfaf2740f8d1a6de09a - Author: Alan Wu <alanwu@ruby-lang.org> - AuthorDate: 2023-11-29 02:30:30 +0900 - Commit: Alan Wu <alanwu@ruby-lang.org> - CommitDate: 2023-11-29 02:30:30 +0900 - - [PRISM] Run test setting global constant separately - - This impacted other tests. Please mind the commons. - - /home/runner/work/ruby/ruby/src/test/ruby/test_compile_prism.rb:394: warning: already initialized constant Bar - /tmp/test_reline_config_60145/bazbarbob.rb:6: warning: previous definition of Bar was here - - 1) Failure: - TestModule#test_const_get_evaled [/home/runner/work/ruby/ruby/src/test/ruby/test_module.rb:1239]: - NameError expected but nothing was raised. - -commit 55f34d474592f4ff5332615c7e4baf6270e7090d - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-28 23:50:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-29 02:27:11 +0900 - - [ruby/prism] Fix tests - - https://github.com/ruby/prism/commit/1e6ecbaf04 - -commit c11dd3475306a951959a8599f31ca360342ce008 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-28 13:23:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-29 02:27:10 +0900 - - [ruby/prism] Reset `current_param_name` around closed scopes - - It is for supporting `def foo(bar = (def baz(bar) = bar; 1)) = 2` case. - - https://github.com/ruby/prism/commit/c789a833c5 - -commit f6fbb9fec5b411dae1b38b306a49399baa52aaec - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-28 13:21:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-29 02:27:10 +0900 - - [ruby/prism] Use `0` for the default valie of `current_param_name` - - https://github.com/ruby/prism/commit/896915de24 - -commit b5796d7b113a78b17e27f2ad23c209f4e2d2900b - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-24 01:29:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-29 02:27:09 +0900 - - [ruby/prism] Check circular references in default values of params - - Fix https://github.com/ruby/prism/pull/1637 - - https://github.com/ruby/prism/commit/0172d69cba - -commit fadd28c7ba6b55ec934f379cfc30a8111e340404 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-29 02:22:46 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-29 02:22:46 +0900 - - [ruby/irb] Change show_source tests into integration tests - - * Remove trailing spaces - - * Migrate show_source tests to integration tests - - Because show_source tests often need to define class and/or methods, - they can easily leak state to other tests. Changing them to integration - tests will ensure that they are run in a clean environment. - - * Fix NoMethodError caused by SourceFinder#method_target - - https://github.com/ruby/irb/commit/3c39f13397c72a8db24e50afdcb8942e6c4ea12f - -commit 476a231e7e2c2a370ea9f47c9b62e8d6d3d9442d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-29 00:41:14 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-29 00:41:14 +0900 - - YJIT: Assert no patch overlap on pos_marker (#9048) - -commit 891ce4614a7cab6eb76429a9972b5e8c2dc02a5d - Author: paulreece <96156234+paulreece@users.noreply.github.com> - AuthorDate: 2023-11-28 23:56:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-28 23:56:51 +0900 - - [ruby/irb] This enhancement allows a user to add the -s flag if they - want to access a methods origin definition. It allows for chaining - of multiple esses to further go up the classes as needed. - (https://github.com/ruby/irb/pull/770) - - https://github.com/ruby/irb/commit/eec1329d5a - -commit 5fc71feb6ca8b62d51f9b6421cb26c9f1228be17 - Author: Kasumi Hanazuki <kasumi@rollingapple.net> - AuthorDate: 2023-11-28 23:05:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-28 23:05:31 +0900 - - [ruby/irb] Rescue errors from main.to_s/inspect when formatting - prompt - (https://github.com/ruby/irb/pull/791) - - Currently, IRB just terminates if `main.to_s` raises while IRB - constructs the prompt string. This can easily happen if the user wants - to start an IRB session in the instance scope of an uninitialized - object, for example: - - ``` - class C - def initialize - binding.irb - @values = [] - end - - def to_s = @values.join(',') # raises if uninitialized - end - - C.new - ``` - - This patch makes IRB rescue from such an exception and displays the - class name of the exception instead of `main.to_s` to indicate some - error has occurred. - - We may display more detailed information about the exception, but this - patch chooses not to do so because 1) the prompt has limited space, - 2) users can evaluate `to_s` in IRB to examine the error if they want, - and 3) obtaining the details can also raise, which requires nested - exception handling and can be complicated. - - https://github.com/ruby/irb/commit/412ab26067 - -commit 9365b78d49bfee1a1b40d02c7f6ac8b3a9954b8d - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-26 17:54:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-28 22:25:59 +0900 - - [ruby/prism] Fix to parse `*` as forwarding in `foo[*]` case - - Fix https://github.com/ruby/prism/pull/1924 - - https://github.com/ruby/prism/commit/7cde900065 - -commit c798943a4a272f213d21295a837da06ed5fa9a51 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-28 04:17:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-28 22:25:48 +0900 - - [ruby/prism] Move DATA parsing into its own parse result field - - https://github.com/ruby/prism/commit/42b60b6e95 - -commit 458d079166ce7344c1d44b2403ff963b8c68d7d8 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-11-28 16:06:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-28 21:50:04 +0900 - - [DOC] Add a mention of [Feature #18551] to NEWS.md - -commit 62c816410ff5e1d54da3ff3819ec1c67489066ff - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-28 20:46:00 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-28 20:49:12 +0900 - - Retry pthread_create a few times - - According to https://bugs.openjdk.org/browse/JDK-8268605, pthread_create - may fail spuriously. This change implements a simple retry as a modest - measure, which is also used by JDK. - -commit 1a16b6ffc2d48b93c730cd6e57fac6a68fa05737 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2022-01-27 14:37:48 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-28 15:10:42 +0900 - - Make Range#reverse_each raise TypeError if endless - -commit 0164da68c170c7f1e36dd70965b67c8c63523391 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-28 05:05:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-28 11:53:44 +0900 - - [ruby/prism] Use un-capitalized error messages - - I don't prefer this style, but it appears that a plurality of syntax - error messages between with un-capitalized messages in CRuby, so - we'll go with that for consistency, for now. - - https://github.com/ruby/prism/commit/b02df68954 - -commit 32b5f5be7cd0140c5f919d81d6ebf826efd03bb8 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-28 06:57:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-28 11:53:31 +0900 - - [ruby/prism] Introduce char_is_identifier_utf8 - - https://github.com/ruby/prism/commit/5f43e57b0f - -commit def416899d2b72d2299ddfa97f1f94ae2594d67b - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-11-28 10:38:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-28 10:38:41 +0900 - - [ruby/stringio] Development of 3.1.1 started. - - https://github.com/ruby/stringio/commit/75da93d48f - -commit 7f50c705742dd92509ae9fc3003eb7561baa7e8a - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-11-28 07:49:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-28 07:49:53 +0900 - - YJIT: add top C function call counts to `--yjit-stats` (#9047) - - * YJIT: gather call counts for individual cfuncs - - Co-authored by Takashi Kokubun - -commit 94015e0dce38d238d428b60b46dcb9f3caef445f - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-28 04:45:47 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-28 06:49:52 +0900 - - Guard match from GC when scanning string - - We need to guard match from GC because otherwise it could end up being - reclaimed or moved in compaction. - -commit 1acea5010023deb0b4747e6c7309c4d69bdaf47d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-14 04:32:39 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-28 06:02:38 +0900 - - [PRISM] Small fixes to parameters ordering and methods - -commit e4dd8f6c9c49526f92b5b70c46a067e97e64616e - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-28 04:07:27 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-28 05:14:40 +0900 - - [PRISM] Renamed some variables, added comments - -commit ba26c6eae0c51dc07beb5b5c7c5651ef4589f351 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-28 02:48:51 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-28 05:14:40 +0900 - - [PRISM] Compile IndexOperatorWriteNode - -commit ec5eddf695e9bc3414c8628a6311ffb856fa7374 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-28 01:12:24 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-28 05:14:40 +0900 - - [PRISM] Compile IndexAndWriteNode - -commit 13b7cddc2b7fb224065677b9c0030898ebbeb21e - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-27 22:04:24 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-28 05:14:40 +0900 - - [PRISM] Compile IndexOrWriteNode - -commit 4d71f70fd1cd0e11d9698e52411cd55045044c34 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-28 04:05:25 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-28 04:05:25 +0900 - - Add assertions to check created red-black tree - -commit 872922b03d9be2a4d861c5eb8190be24498e3e9d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-28 04:04:56 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-28 04:04:56 +0900 - - Fix indentation in comment in shape.c - -commit 95064bb88db7ff0d71bf9c921b0b87fe1ae712d7 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-22 23:49:26 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-28 02:52:07 +0900 - - [PRISM] Fix compilation for SplatNodes within ArrayNodes - - SplatNodes within ArrayNodes (e.g. [*1..2, 3]) need to be special - cased in the compiler because they use a combination of concatarray - and newarray instructions to treat each sequence of splat or non-splat - elements as independent arrays which get concatenated. This commit - implements those cases. - -commit 6d447fa35f877edae96e4a7f98c9f5e70219314b - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-21 06:16:22 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-28 02:51:50 +0900 - - [PRISM] Don't pop several args related nodes - -commit 150ed44d87e2d5b00f38019a487e05a67a303482 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-28 01:30:47 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-28 02:40:26 +0900 - - Fix compaction during ary_make_partial - - The ary_make_shared call may allocate, which can trigger a GC - compaction. This can cause the array to be embedded because it has a - length of 0. - -commit 3af56e87ca79740521c81e1336cfb5523f55ee29 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-26 16:47:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-28 02:35:38 +0900 - - [ruby/prism] Check void expressions for constant paths - - Fix https://github.com/ruby/prism/pull/1920 - - https://github.com/ruby/prism/commit/ee8e03bac7 - -commit 8654859dbd062af5071343effe48062123f356f7 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-26 17:20:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-28 02:33:31 +0900 - - [ruby/prism] Fix and reuse pm_call_node_index_p - - Fix https://github.com/ruby/prism/pull/1925 - Fix https://github.com/ruby/prism/pull/1927 - - Previously pm_call_node_index_p does not check about a block argument - correctly and is not used in parse_write to check an index call node. - - This commit fixes these problems. - - https://github.com/ruby/prism/commit/92bab044ff - -commit bd4a992f38f59d15e325966a8e57f12559f331ad - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-28 02:30:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-28 02:30:54 +0900 - - [ruby/prism] Correct template.rb comment - - https://github.com/ruby/prism/commit/4d689fe1df - -commit cc05a60c16b69b6156396f9e6a009f94421fe1b4 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-11-28 02:17:52 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-11-28 02:17:52 +0900 - - Update to ruby/spec@c3206f6 - -commit acab060c17a21bd79f384e3e055aaa115c5dc235 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-11-28 02:17:51 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-11-28 02:17:51 +0900 - - Update to ruby/mspec@9f83eea - -commit 23a7714343b372234972ef0dacf774d07fe65ced - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-24 21:18:00 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-28 01:37:57 +0900 - - Refactor and fix the GVL instrumentation API - - This entirely changes how it is tested. Rather than to use counters - we now record the timeline of events with associated threads which - makes it much easier to assert that certains events are only preceded - by a specific event, and makes it much easier to debug unexpected - timelines. - - Co-Authored-By: Étienne Barrié <etienne.barrie@gmail.com> - Co-Authored-By: JP Camara <jp@jpcamara.com> - Co-Authored-By: John Hawthorn <john@hawthorn.email> - -commit e3875dd0f8f11d9dbdc25b400f387c406b799cb5 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-28 01:13:47 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-28 01:13:47 +0900 - - Don't incremental mark when GC stressful - - Incremental marking prevents the GC from fully executing, so it may fail - to catch certain bugs. - -commit 7973eb7c3f6531a41adb9de63d1b3c4d5d4b7d03 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-28 01:06:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-28 01:07:03 +0900 - - [ruby/rdoc] [DOC] Slightly decorate `em` and `strong` - - https://github.com/ruby/rdoc/commit/2161157205 - -commit 8427a8a655e2a04bfdc6a645ec967405d3617137 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-11-27 15:33:08 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-28 01:02:11 +0900 - - Fix flaky "Expected 499 to be >= 500" assertion in test_gc_compact.rb - - There have been some sproradically flaky tests related to GC compaction, - which fail with: - - 1) Failure: - TestGCCompact#test_moving_hashes_down_size_pools [/test/ruby/test_gc_compact.rb:442]: - Expected 499 to be >= 500. - - What's happening here, is that, _sometimes_, depending on very unlucky - combinations of machine things, one of the expected-to-be-moved hashes - might be found on the machine stack during GC, and thus pinned. - - One factor which seems to make this _more_ likely is that GCC 11 on - Ubuntu 22.04 seems to want to allocate 440 bytes of stack space for - `gc_start`, which is much more than it actually uses on the common code - path. The result is that there are some 50-odd VALUE-sized cells "live" - on the stack which may well contain valid heap pointers from previous - function calls, and will need to be pinned. - - This is, of course, totally normal and expected; Ruby's GC is - conservative and if there is the possibility that a VALUE might be live - on the machine stack, it can't be moved. However, it does make these - tests flaky. - - This commit "fixes" the tests by performing the work in a fiber; the - fiber goes out of scope and should be collected by the call to - verify_compaction_references, so there should be no references to the - to-be-moved objects floating around on the machine stack. - - Fixes [#20021] - -commit 196c4aeb766a66b3557ddab61086db58c7a08226 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-27 20:15:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-28 00:58:31 +0900 - - [ruby/rdoc] Place a space between certain character class letters only - - https://github.com/ruby/rdoc/commit/1f568e049d - -commit 7835ebce97a6e6132d2bc7bdbef115f3f47cc6c2 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-28 00:23:31 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-28 00:23:43 +0900 - - Set compaction after major GC has been determined - - do_full_mark can change in gc_start, so we want to set auto-compaction - only after do_full_mark has been properly set. - -commit ca4755b59a7bdaaffbaef05474c8d8ee187e8d7d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-28 00:13:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-28 00:13:05 +0900 - - [Bug #20023] Resurrect fake string feature name before raising - -commit 2e4a0a4d90205224703a958fc9e4de61f6436aae - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-23 00:54:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-27 22:29:35 +0900 - - Implement Write Barriers on Enumerator::Producer - -commit 2dadd17c780108d9f98989578149a091ff2c0f50 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-23 00:49:28 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-27 22:29:35 +0900 - - Implement Write Barriers on Enumerator::Generator - -commit d7165d88ec715f4c73b6fcbbbd6b185145359757 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-23 00:45:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-27 22:29:35 +0900 - - Implement Write Barriers on Enumerator::Yielder - -commit 1c3088117a6b22b6aa07fb8c9c28028851786c1b - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-11-24 21:14:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-27 21:21:24 +0900 - - [ruby/stringio] Do not compile the C extension on TruffleRuby - - * Before this it was compiled but not used, because TruffleRuby has - a stringio.rb in stdlib and .rb has precedence over .so. - In fact that extension never worked on TruffleRuby, - because rb_io_extract_modeenc() has never been defined on TruffleRuby. - * So this just skip compiling the extension since compilation of it now fails: - https://github.com/ruby/openssl/issues/699 - - https://github.com/ruby/stringio/commit/d791b63df6 - -commit a07d84b63c7785f6f1a0c5f6933c0b7fa87df1d8 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-11-27 19:34:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-27 19:34:40 +0900 - - [ruby/irb] Hide debugger hint after the input is submitted - (https://github.com/ruby/irb/pull/789) - - If `output_modifier_proc`'s `complete` arg is true, it means the input is - submitted. In that case, debugger hint doesn't provide value to users - and adds noise to the output. So we hide it in such case. - - https://github.com/ruby/irb/commit/f86d9dbe2f - -commit 71a8daecd9ad10ba8aa0d66131e326722f1d78ad - Author: Josef Šimánek <josef.simanek@gmail.com> - AuthorDate: 2023-06-27 09:36:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-27 15:04:40 +0900 - - Opaque Etags for compact index requests - - This changes the CompactIndexClient to store etags received from the - compact index in separate files rather than relying on the MD5 checksum - of the file as the etag. - - Smoothes the upgrade from md5 etags to opaque by generating them when no - etag file exists. This should reduce the initial impact of changing the - caching behavior by reducing cache misses when the MD5 etag is the same. - - Eventually, the MD5 behavior should be retired and the etag should be - considered completely opaque with no assumption that MD5 would match. - -commit 794c879d19689df8ced5537ecaacdbe5313f2a3f - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-24 07:13:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-27 15:04:40 +0900 - - [rubygems/rubygems] Don't remember `--jobs` flag - - https://github.com/rubygems/rubygems/commit/9ab1136036 - -commit 56ac1b0e1435a425eb7451e10c0606a009d9113a - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-24 07:04:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-27 15:04:40 +0900 - - [rubygems/rubygems] Fix advice in `bundle install --system` deprecation - - https://github.com/rubygems/rubygems/commit/59a66e3560 - -commit e00d7b61827303ed3c7759757e9d0a90b80415cb - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-24 06:46:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-27 15:04:40 +0900 - - [rubygems/rubygems] Keep a single copy of the remembered flag deprecation message - - https://github.com/rubygems/rubygems/commit/cb4e26eabc - -commit fe57be5a2ea80655e1ece52518e3fe72058a0ad9 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-24 07:01:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-27 15:04:40 +0900 - - [rubygems/rubygems] Avoid some unnecessary quotes in remember flag deprecation message - - https://github.com/rubygems/rubygems/commit/3fd627e486 - -commit bd4bd61650403121dc1fc29fab850d048d851a55 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-24 06:53:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-27 15:04:40 +0900 - - [rubygems/rubygems] Simplify remembered flags deprecation message - - Configuration is now local by default. - - https://github.com/rubygems/rubygems/commit/6bc7709aa8 - -commit 60803e192eebd1048f28ea5ba2a2f2c753424dad - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-24 06:06:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-27 15:04:40 +0900 - - [rubygems/rubygems] Remove no longer necessary workaround for old RubyGems - - https://github.com/rubygems/rubygems/commit/ed4eaefac0 - -commit 67ee91a3058e9d918add38ed02205e7383f00fad - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-11-26 16:07:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-27 10:35:08 +0900 - - [ruby/psych] Prefer each_char in Psych::Visitors::Visitor::ToRuby#deserialize - - Use safe navigation operator with each_char to remove empty strings and improve readability. - - https://github.com/ruby/psych/commit/5fe714b216 - -commit 52c7e43b8797de0d042d05ecf6fc4a883c5c372f - Author: Olle Jonsson <olle.jonsson@gmail.com> - AuthorDate: 2023-11-26 01:52:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-27 07:08:27 +0900 - - [rubygems/rubygems] Add missing --prefer-local to Synopsis in bundle-install.1.ronn - - https://github.com/rubygems/rubygems/commit/e956c5bbe4 - -commit 08308fe3e8fd51f4445be9408a418d9ac6960921 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-19 11:18:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-27 07:07:39 +0900 - - [rubygems/rubygems] Reduce allocations when installing gems with bundler - - ``` - ==> memprof.after.txt <== - Total allocated: 1.13 MB (2352 objects) - Total retained: 10.08 kB (78 objects) - - ==> memprof.before.txt <== - Total allocated: 46.27 MB (38439 objects) - Total retained: 9.94 kB (75 objects) - ``` - - Yes, we were allocating 45MB of arrays in `dependencies_installed?`, - it was accidentally cubic. - - https://github.com/rubygems/rubygems/commit/13ab874388 - -commit cc5d1bf026bcc5b4929a4f9d5e32d2fa5730348c - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-11-27 02:07:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-27 02:07:45 +0900 - - [ruby/irb] Display aliases in help message - (https://github.com/ruby/irb/pull/788) - - Similar to Pry, it displays user-defined aliases in the help message with - a dedicated section. With the current default aliases, it looks like: - - ``` - ...other sections... - - Aliases - $ Alias for `show_source` - @ Alias for `whereami` - ``` - - https://github.com/ruby/irb/commit/2a0eacc891 - -commit 688faa93f03142b632b8eb0de0946f4e86845ebc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-26 21:49:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-26 21:49:18 +0900 - - [DOC] Fix markup in declarative marking API document - - - RDoc is not markdown, use `+` and `_` for code and variables - respectively, instead of backquotes. - - - Remove useless backslashes. - -commit 9cd086ba4b559153864ab924723a665a4ddfb5d8 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-11-26 20:07:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-26 20:07:50 +0900 - - [ruby/irb] Support disabling pager - (https://github.com/ruby/irb/pull/783) - - With either `IRB.conf[:USE_PAGER] = false` or `--no-pager` commnad line flag. - - I decided use `--no-pager` instead of `--use-pager` because it matches with - Pry and git's command line flags. - - https://github.com/ruby/irb/commit/df1c3b9042 - -commit 0bced53a8a11055d33160aa3f023b4b957e9e497 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-26 19:37:56 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-26 19:37:56 +0900 - - [DOC] Remove extra `+` which is not a part of keyword argument name - -commit 087a919ea4a6e151aa65209ebbebc9a907079172 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-26 19:18:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-26 19:18:57 +0900 - - [DOC] Fix markup - - RDoc is not markdown. - -commit e81c380c0fb3611d5507bfa169b0437a8712ea7c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-26 16:04:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-26 16:04:23 +0900 - - Constify `RUBY_REFERENCES_START` tables - -commit 7fe7b7bc5a7a3d79280c9dbf2a2383d386386b0f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-26 00:28:36 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-26 11:42:02 +0900 - - Fix portability of bignum in ISeq Binary Format - - - Unless `sizeof(BDIGIT) == 4`, (8-byte integer not available), the - size to be loaded was wrong. - - Since `BDIGIT`s are dumped as raw binary, the loaded byte order was - inverted unless little-endian. - -commit 003f06bde40008159e871411cae5a928121490ba - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-26 10:03:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-26 10:07:21 +0900 - - [ruby/resolv] Close leaked FD - - https://github.com/ruby/resolv/commit/49aefa3bba - -commit 87c3deacf431dd1ee4538ba15db54f884fa8a918 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2019-08-27 12:30:59 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-11-26 04:40:08 +0900 - - [ruby/resolv] Support a :use_ipv6 option to Resolv#initialize - - When set, supports returning IPv6 results even if there is no - public IPv6 address for the system. - - Implements Ruby Feature #14922 - - https://github.com/ruby/resolv/commit/09d141de38 - -commit 1b7376423d3bf79ba37856eae8f45d59ecc9c170 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-26 01:18:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-26 01:18:48 +0900 - - Omit test_session_reuse_but_expire if OpenSSL 3.2.0 - -commit b93a1bb40bf868ba8d664539ba4a44740e641772 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-25 04:31:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-25 23:32:36 +0900 - - Verify correctness of shape cache - - This commit adds assertions to verify that the shape cache is correct - compared to the shape tree. - -commit 564ef66e26454079188f024eb28e48a4ef1b2085 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-25 04:31:36 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-25 23:32:36 +0900 - - Verify that duplicate shape is not created - - This adds an assertion that the instance variable does not already exist - in the shape tree when creating a new shape. - -commit f6b292b5ca8b397b00cc4e82d8ae7ede8b09f25f - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-11-25 19:15:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-25 19:16:02 +0900 - - [ruby/irb] Fix exception(backtrace=nil) prints nothing - (https://github.com/ruby/irb/pull/782) - - https://github.com/ruby/irb/commit/fa9ecf9a5b - -commit 68a03613d8f7ec173addbfbb3989045d8f639ec5 - Author: hogelog <konbu.komuro@gmail.com> - AuthorDate: 2023-11-25 19:14:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-25 19:14:07 +0900 - - [ruby/irb] Fix flaky test case - test_autocomplete_with_multiple_doc_namespaces - (https://github.com/ruby/irb/pull/786) - - https://github.com/ruby/irb/commit/85c6ddeb7d - -commit 543dd74049f18db2f8dd9ac05b25f8dbff2edc14 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-11-07 22:36:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-25 19:12:28 +0900 - - Fix test_pkey_dh.rb in FIPS. - - We use dh2048_ffdhe2048.pem file (DH 2048 bits) instead of dh1024.pem file in - both non-FIPS and FIPS cases. Because the following command fails to generate - the pem file with 1024 bits. And the OpenSSL FIPS 140-2 security policy - document explains the DH public keys are allowed from 2048 bits.[1] - - ``` - $ OPENSSL_CONF=/home/jaruga/.local/openssl-3.3.0-dev-fips-debug-1aa08644ec/ssl/openssl_fips.cnf \ - /home/jaruga/.local/openssl-3.3.0-dev-fips-debug-1aa08644ec/bin/openssl \ - dhparam -out dh1024.pem 1024 - Generating DH parameters, 1024 bit long safe prime - dhparam: Generating DH key parameters failed - ``` - - The dh2048_ffdhe2048.pem file was created by the following command with the - OpenSSL FIPS configuration file. The logic to generate the DH pem file is - different between non-FIPS and FIPS cases. In FIPS, it seems that the command - always returns the text defined as ffdhe2048 in the FFDHE groups in RFC 7919 - unlike non-FIPS.[2] - - As the generated pem file is a normal and valid PKCS#3-style group parameter, we - use the file for the non-FIPS case too. - - ``` - $ OPENSSL_CONF=/home/jaruga/.local/openssl-3.3.0-dev-fips-debug-1aa08644ec/ssl/openssl_fips.cnf \ - /home/jaruga/.local/openssl-3.3.0-dev-fips-debug-1aa08644ec/bin/openssl \ - dhparam -out dh2048_ffdhe2048.pem 2048 - ``` - - Note that the hard-coded PEM-encoded string in the `test_DHparams` is - intentional to avoid modifying the content unintentionally. - - * [1] https://www.openssl.org/source/ - OpenSSL 3.0.8 FIPS 140-2 security - policy document page 25, Table 10 – Public Keys - DH Public - - DH (2048/3072/4096/6144/8192) public key agreement key - * [2] RFC7919 - Appendix A.1: ffdhe2048 - https://www.rfc-editor.org/rfc/rfc7919#appendix-A.1 - -commit 84f45c6ed5357de206153b1524620335814d05d9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-25 15:28:39 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-11-25 15:28:39 +0900 - - Place continue-on-error consistently - - Once it fails on "Perform CodeQL Analysis", it proceeds to subsequent - steps and fails because required files are not created by previous - steps. When we have a continue-on-error, all subsequent steps that rely - on the step should have a continue-on-error as well. - -commit de37b780508d4ced5837f39446d3c8c93ef9ec7c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-25 14:43:29 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-11-25 14:43:34 +0900 - - Omit a broken https test on MinGW - - This started to reliably fail on MinGW at an irrelevant commit: - https://github.com/ruby/ruby/actions/runs/6981002841/job/18997302124 - https://github.com/ruby/ruby/actions/runs/6981946473/job/19000104223 - https://github.com/ruby/ruby/actions/runs/6983823136/job/19005613809 - https://github.com/ruby/ruby/actions/runs/6983912116/job/19005844596 - https://github.com/ruby/ruby/actions/runs/6984215921/job/19006649495 - https://github.com/ruby/ruby/actions/runs/6984383103/job/19007100446 - https://github.com/ruby/ruby/actions/runs/6986489509/job/19012000642 - - So this failure is not detecting a new bug. Let's skip this until we fix - this test for MinGW. - -commit 7276d4b4e87bfdc9b609f481a734e39c499de253 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2021-09-18 09:17:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-25 11:24:43 +0900 - - [ruby/resolv] Support a :raise_timeout_errors option to raise timeouts as Resolv::ResolvError - - This allows to differentiate a timeout from an NXDOMAIN response. - - Fixes [Bug #18151] - - https://github.com/ruby/resolv/commit/c0e5abab76 - -commit fb7add495454322ea00efa7549feb957cb1ca538 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-25 04:48:02 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-25 04:48:02 +0900 - - Switch shape test to use exhaust_shapes - -commit 974d18fd0c13bd19120cad70187f5b646c901dff - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2021-03-09 08:28:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-25 04:17:19 +0900 - - [ruby/resolv] Fix the fallback from UDP to TCP due to message truncation - - If truncation is detected, return immediately from decode so that - the UDP connection can be retried with TCP, instead of failing to - decode due to trying to decode a truncated response. - - Fixes [Bug #13513] - - https://github.com/ruby/resolv/commit/0de996dbca - -commit 269c705f93c4db631f4cad89991bc5d69a7dcd03 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-25 00:25:06 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-25 03:29:04 +0900 - - Fix compaction for generic ivars - - When generic instance variable has a shape, it is marked movable. If it - it transitions to too complex, it needs to update references otherwise - it may have incorrect references. - -commit e201b81f79828c30500947fe8c8ea3c515e3d112 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-11-11 14:12:12 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-25 03:16:15 +0900 - - Mark cc->cme_ for refinement callcaches as well - - This is required for the same reason that super CC needs it. - See 36023d5cb751d62fca0c27901c07527b20170f4d. - - Reproducer: - - def cached_foo_callsite(obj) = obj.foo - - class Foo - def foo = :v1 - - module R - refine Foo do - def foo = :unused - end - end - end - - obj = Foo.new - cached_foo_callsite(obj) # set up cc with cme for foo=:v1 - - class Foo - def foo = :v2 - end - GC.start # cme for foo=:v1 collected, if not reachable by cached_foo_callsite - - cached_foo_callsite(obj) - - [Bug #19994] - -commit 99e1f7b60717bc5ca3b160f10f4a8fe1521cba7c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-24 04:53:53 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-24 23:28:34 +0900 - - Abort GC on shutdown - - On large Ruby applications, shutdown may be slow if a major GC has just - started because rb_objspace_call_finalizer completes the GC. - - This commit adds gc_abort which discards the mark stack if during - incremental marking and stops sweeping if during lazy sweeping. - -commit 406dafbb347cb81f6d256d18ac9fd2908a9cb8ef - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-24 20:36:55 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-11-24 21:54:35 +0900 - - [PRISM] Insert Tracepoint line events on line change - -commit 1cba1b3992dcc7476a24e00e4207cfd38e37d8d4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-24 20:00:13 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-24 20:00:13 +0900 - - Check `windres` message using the found `windres` only if needed - -commit 0c0875fe6050a79e5525a71f6819168bd4947ff8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-24 19:37:54 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-24 19:38:55 +0900 - - [DOC] Mention `Time.find_timezone` method - -commit 2ecc372a5d623ff4e470c354c771f8797e527c2d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-24 19:16:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-24 19:38:55 +0900 - - [DOC] State timezone info in the string wins `in:` keyword - -commit 045e74d8e484bca963eba6210d85222fa9362615 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-24 17:28:52 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-24 19:38:55 +0900 - - [DOC] Simplify signature of `Time.new` - -commit 9d7ac1ba1ca279df14400814516fab14240cdc35 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-13 17:45:12 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-24 19:38:55 +0900 - - [DOC] Add links about timezones - -commit 24e0b185ab7ea67eea298fc2ad7985f7ce4deba1 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-11-24 08:06:14 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-11-24 17:36:20 +0900 - - .travis.yml: Add s390x again. - - As Travis CI IBM z pipeine is operational again, I will add s390x again to check - the case. Though Travis s390x infra team is still investigating the root cause. - https://www.traviscistatus.com/ - - Please revert this commit or comment on the - <https://bugs.ruby-lang.org/issues/20013>, when you see the s390x builds are not - starting again. - - Sorry for inconvenience. - -commit 87ddfb33a0bb7f771d4a1aee0c27c598267fb926 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-11-21 12:59:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-24 16:26:27 +0900 - - [rubygems/rubygems] Fix typo missing do - - https://github.com/rubygems/rubygems/commit/4eade32ad6 - -commit f792b55b2138c75bfc4efe1d15af5e924f4349bc - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-11-21 12:52:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-24 16:26:26 +0900 - - [rubygems/rubygems] Prefer String#each_line in Gem::Command - - Replace ``String#split("\n").each`` with ``String#each_line``. - - https://github.com/rubygems/rubygems/commit/958744807d - -commit 12f4e9655e6278b14f3b75ccccf63a535d72c120 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-11-24 13:39:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-24 13:39:24 +0900 - - Add recommendations on link formatting in documentation - -commit 02cc9d48f1958e8f22757116358cf5863cb109f4 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-11-24 13:06:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-24 13:06:25 +0900 - - [ruby/resolv] Catch EPROTONOSUPPORT as a sign of no IPv6 as well - (https://github.com/ruby/resolv/pull/41) - - If IPv6 is disabled inside a freebsd jail, it seems this returns - EPROTONOSUPPORT and not EAFNOSUPPORT. In both cases, we should simply - try some other listed DNS servers. - - Fixes [Bug #19928] https://bugs.ruby-lang.org/issues/19928 - - https://github.com/ruby/resolv/commit/5e2d48708b - -commit e3b485213d06a5d9a07650174a2be9e20cb39e57 - Author: Kasumi Hanazuki <kasumi@rollingapple.net> - AuthorDate: 2023-11-24 10:42:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-24 10:42:08 +0900 - - [ruby/resolv] Implement dohpath SvcParam - (https://github.com/ruby/resolv/pull/33) - - * Implement dohpath SvcParam [RFC 9461] - - This patch implements "dohpath" SvcParam proposed in - [draft-ietf-add-svcb-dns-08]. This parameter specifies a URI template - for the :path used in DNS-over-HTTPS requests. - - "dohpath" is employed by [DDR], also a to-be-published Proposed Standard - that specifies how to upgrade DNS transport to a more secure one, i.d., - DNS-over-TLS or DNS-over-HTTPS. DDR is deployed in the public DNS - resolvers including Cloudflare DNS, Google Public DNS, and Quad9. - - [RFC 9461]: https://datatracker.ietf.org/doc/rfc9461/ - [DDR]: https://datatracker.ietf.org/doc/draft-ietf-add-ddr/ - - https://github.com/ruby/resolv/commit/da9c023539 - - Co-authored-by: Sorah Fukumori <her@sorah.jp> - -commit 608a518b42736edc6533a120a240ff92ca4a8a60 - Author: Kasumi Hanazuki <kasumi@rollingapple.net> - AuthorDate: 2023-11-24 10:35:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-24 10:35:33 +0900 - - [ruby/resolv] Implement SVCB and HTTPS RRs - (https://github.com/ruby/resolv/pull/32) - - * Add MessageDecoder#get_list - - This method repeats yielding until all the data upto the current limit - is consumed, and then returns an Array containig the block results. - - * Implement SVCB and HTTPS RRs [RFC 9460] - - > This patch implements SVCB and HTTPS resource record types defined in - > [RFC 9460]. - > - > The RR types are now supported by many server implementations including - > BIND, unbound, PowerDNS, and Knot DNS. Major browsers such as Chrome, - > Edge, and Safari have started to query HTTPS records, with the records - > gradually adopted by websites. Also, SVCB is actually deployed in the - > public DNS resolvers such as Cloudflare DNS and Google Public DNS for - > [DDR]. - > - > With such wide adoption, we have plenty of real-world use cases, and - > it is unlikely the wire format will change further in an incompatible - > way. It is time to implement them in the client libraries! - > - > # Rationale for proposed API - > - > ## `Resolv::DNS::Resource::IN::ServiceBinding` - > - > This is an abstract class for SVCB-compatible RR types. - > SVCB-compatible RR types, as defined in the Draft, shares the wire - > format and the semantics of their RDATA fields with SVCB to allow - > implementations to share the processing of these RR types. So we do - > so. - > - > The interface of this class is straightforward: It has three - > attributes `priority`, `target`, and `params`, which correspond the - > RDATA fields SvcPriority, TargetName, and SvcParams, resp. - > - > SVCB RR type is defined specifically within IN class. Thus, this - > class is placed in the `Resolv::DNS::Resource::IN` namespace. - > - > ## `Resolv::DNS::Resource::IN::SVCB`, `Resolv::DNS::Resource::IN::HTTPS` - > - > Just inherits ServiceBinding class. - > - > ## `Resolv::DNS::SvcParam` - > - > This class represents a pair of a SvcParamKey and a SvcParamValue. - > Aligned with the design of `Resolv::DNS::Resource`, each SvcParamKey - > has its own subclass of `Resolv::DNS::SvcParam`. - > - > ## `Resolv::DNS::SvcParam::Generic` - > - > This is an abstract class representing a SvcParamKey that is unknown - > to this library. `Generic.create(key)` dynamically defines its - > subclass for specific `key`. E.g., `Generic.create(667)` will define - > `Generic::Key667`. - > - > This class holds SvcParamValue in its wire format. - > - > SvcParam with an unknown SvcParamKey will be decoded as a subclass of - > this class. Also, users of this library can generate a non-supported - > SvcParam if they know its wire format. - > - > ## `Resolv::DNS::SvcParams` - > - > This is conceptually a set of `SvcParam`s, whose elements have the - > unique SvcParamKeys. It behaves like a set, and for convenience - > provides indexing by SvcParamKey. - > - > - `#initialize(params)` takes an Enumerable of `SvcParam`s as the - > initial content. If it contains `SvcParam`s with the duplicate key, - > the one that appears last takes precedence. - > - `#[](key)` fetches the `SvcParam` with the given key. The key can be - > specified by its name (e.g., `:alpn`) or number (e.g., `1`). - > - `#add(param)` adds a `SvcParam` to the set. If the set already has a - > `SvcParam` with the same key, it will be replaced. - > - `#delete(key)` deletes a `SvcParam` by its key and returns it. The key - > can be specified by its name or number. - - * Update comments referring to draft-ietf-dnsop-svcb-https-12 - - Published as RFC 9460. https://datatracker.ietf.org/doc/rfc9460/ - - [draft-ietf-dnsop-svcb-https-12]: https://datatracker.ietf.org/doc/draft-ietf-dnsop-svcb-https/12/ - [RFC 9460]: https://datatracker.ietf.org/doc/rfc9460/ - [DDR]: https://datatracker.ietf.org/doc/draft-ietf-add-ddr/ - - https://github.com/ruby/resolv/commit/b3ced7f039 - -commit 1ffaff884e3e0704393b7b7bd312798da094f709 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-24 08:37:07 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-24 10:30:18 +0900 - - Allow ivars movement in too_complex RCLASSes to fix crash - - Previously, because gc_update_object_references() did not update the - VALUEs in the too_complex ivar st_table for T_CLASS and T_MODULE - objects, GC compaction could finish with corrupted objects. - - - start with `klass`, not too_complex - - GC incremental step marks `klass` and its ivars - - ruby code makes `klass` too_complex - - GC compaction runs and move `klass` ivars, but because `klass` is - too_complex, its ivars are not updated by gc_update_object_references(), - leaving T_NONE or T_MOVED objects in the ivar table. - - Co-authored-by: Peter Zhu <peter@peterzhu.ca> - -commit 22de08811e28115da29616790bf9cad2ecdb7913 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-24 08:26:58 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-24 10:30:18 +0900 - - Avoid marking IDs in too_complex tables and rename gc_update_tbl_refs() - - Marking both keys and values versus marking just values is an important - distinction, but previously, gc_update_tbl_refs() and gc_update_table_refs() - had names that were too similar. - - The st_table storing ivars for too_complex T_OBJECTs have IDs as keys, - but we were marking the IDs unnecessary previously, maybe due to the - confusing naming. - -commit f05d586cc99ceed0666459603bfe2aa77a2291ab - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-11-24 05:33:43 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-24 05:33:43 +0900 - - YJIT: record `num_send_cfunc` stat (#9022) - - * YJIT: record num_send_cfunc stat - - Also report num_send_known_cfunc as percentage of num_send_cfunc - - * Rename num_send_known_cfunc => num_send_cfunc_inline - - Name seems more descriptive of what we do with out custom codegen - -commit 315240e73bac5a00e7f8f3e9d7cb77f903281544 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-23 00:00:01 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-24 03:23:29 +0900 - - Implement Write Barriers on Enumerator - -commit 055a4f09ca8ef6852280d66997b974171a7c2863 - Author: Eric Mueller <nevinera@gmail.com> - AuthorDate: 2023-11-19 22:06:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-24 03:03:17 +0900 - - [rubygems/rubygems] Don't require 'json' unless it's actually needed - - https://github.com/rubygems/rubygems/commit/97ee203fd5 - -commit c424d15cb95f0f5a0db711974f7c76928c9633b1 - Author: Eric Mueller <nevinera@gmail.com> - AuthorDate: 2023-11-16 13:11:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-24 03:03:17 +0900 - - [rubygems/rubygems] Add --json bundle-outdated flag to produce json-parseable output - - https://github.com/rubygems/rubygems/commit/65efa44bc0 - -commit a54c98a29f2086d46c95bc15e77dade7dcd18bba - Author: Eric Mueller <nevinera@gmail.com> - AuthorDate: 2023-11-16 12:45:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-24 03:03:16 +0900 - - [rubygems/rubygems] Factor group-filtering to a private method to reduce repetition - - We're about to expand the repeated bit of code, so drying it up a little - is warranted. - - https://github.com/rubygems/rubygems/commit/e69c658be6 - -commit 11d7c75fb33138e9ecadcf222286897826aa0a36 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-11-24 02:33:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-24 02:33:13 +0900 - - [ruby/irb] Handle handle_exception's exception - (https://github.com/ruby/irb/pull/780) - - https://github.com/ruby/irb/commit/d42138c477 - -commit ecdb11288113b5e8b907530512af449f3ffc6c07 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-24 01:45:02 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-24 02:16:57 +0900 - - Fix `rp(too_complex_t_object)` tripping assert - - Previously, it tripped the assert about too_complex in - ROBJECT_IV_CAPACITY(). This fixes double faults for some crashes and - helps with use during development. - -commit 440b59db10bf3cd163092f5b20d32a7654c2d6ff - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-24 00:53:12 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-24 00:53:12 +0900 - - YJIT: Apply patches ignoring page_end_reserve (#9015) - -commit 95369ac0a3b326e1cee18e843d409bdf023abc00 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-24 00:50:42 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-24 00:50:42 +0900 - - YJIT: Fix jmp_ptr_bytes on x86_64 (#9016) - -commit 285a41d79356a49051d5c7370cf2714a76e6397d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-23 00:11:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-23 23:39:30 +0900 - - [ruby/prism] Remove blank line - - https://github.com/ruby/prism/commit/6e5258938a - -commit 7b20dd9f91b4941e4f161dfd2d8b68b33a347a4c - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-23 00:06:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-23 23:39:30 +0900 - - [ruby/prism] Fix LocalVariableTargetNode depth in patterns - - Fix https://github.com/ruby/prism/pull/1821 - - https://github.com/ruby/prism/commit/7d023a26b4 - -commit a31cdc6ee9bfe517e7eaffdca7c8bfeefd0c1df1 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-23 00:06:00 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-23 23:11:24 +0900 - - Add tests for compaction during evacuation of ivars - - Extracted from PR #8932. - - Co-Authored-By: Jean Boussier <byroot@ruby-lang.org> - -commit 7f7613c2c7550d3b008fc132821ccf305f119cac - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-23 00:04:57 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-23 23:11:24 +0900 - - Fix compacting during evacuation of generic ivars - - When evacuating generic instance variables, the instance variables exist - in both the array and the ST table. We need to ensure it has switched - to the ST table before performing any operations that can trigger GC - compaction. - -commit f1c32c0ee08e924e202f529ee8438d2de4f2702a - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-23 17:44:47 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-23 19:19:12 +0900 - - vm_setivar_slowpath: only optimize T_OBJECT - - We've seen occasional CI failures on i686 in this codepath: - - ``` - [BUG] vm_setivar_slowpath: didn't find ivar @verify_depth in shape - ``` - - Generic ivars are very complex to get right, but also quite rare. - I don't see a good reason to take the risk to give them an optimized - path here, when the much more common T_CLASS/T_MODULE don't have one. - - Having an optimization here means duplicating the fairly brittle - logic, which is a recipe for bugs, and I don't think it's worth - it in such case. - -commit 784fdecc4c9f6ba9a8fc872518872ed6bdbc6670 - Author: Pierrick Bouvier <101587250+pbo-linaro@users.noreply.github.com> - AuthorDate: 2023-11-23 17:17:28 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-23 17:17:28 +0900 - - windows-arm64 support (#8995) - - * [win32] fix compilation for windows-arm64 - - Credits to MSYS2 Ruby package using this patch. - - * [win32] nm use full options - - Fix compilation error when using MSYS2 environment. - Credits to MSYS2 Ruby package using this patch. - - * [win32] detect llvm-windres (used for windows-arm64) - - When adding preprocessor option for llvm-windres (using clang as - parameter), it fails. Thus, do not add this. - - It's needed to be able to compile windows-arm64 version, because MSYS2 - toolchain is LLVM based (instead of GCC/binutils). - - * [win32] pioinfo detection for windows-arm64 - - This fixes "unexpected ucrtbase.dll" for native windows-arm64 ruby - binary. It does not solve issue with x64 version emulated on this - platform. - - Value of pioinfo pointer can be found in ucrtbase.dll at latest adrp/add - sequence before return of _isatty function. This works for both release - and debug ucrt. - - Due to the nature of aarch64 ISA (vs x86 or x64), it's needed to - disassemble instructions to retrieve offset value, which is a bit more - complicated than matching specific string patterns. - - Details about adrp/add usage can be found in this blog post: - https://devblogs.microsoft.com/oldnewthing/20220809-00/?p=106955 - For instruction decoding, the Arm documentation was used as a reference. - -commit e8b905896482f2952ccbb4d5bf0a1910edd07bf9 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-11-23 16:29:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-23 16:29:12 +0900 - - [ruby/irb] Hint debugger command in irb:rdbg session - (https://github.com/ruby/irb/pull/768) - - When user enters irb:rdbg session, they don't get the same hint that the - `debug` gem provides, like - - ``` - (rdbg) n # next command - ``` - - This means that users may accidentally execute commands when they want to - retrieve the value of a variable. - - So this commit adds a Reline output modifier to add a simiar hint: - - ``` - irb:rdbg(main):002> n # debug command - ``` - - It is not exactly the same as `debug`'s because in this case the importance - is to help users distinguish between value evaluation and debugger command - execution. - - https://github.com/ruby/irb/commit/fdf24de851 - -commit e2078ccd5a54e54e16bec8db96c45d467307e6c3 - Author: hogelog <konbu.komuro@gmail.com> - AuthorDate: 2023-11-23 16:24:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-23 16:24:35 +0900 - - [ruby/irb] Fix failure of more command with -R option - (https://github.com/ruby/irb/pull/781) - - https://github.com/ruby/irb/commit/7d6849e44e - -commit 926bfc3bc0cfea976533c8eba8cda1fa298124e2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-23 08:13:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-23 08:13:32 +0900 - - YJIT: Avoid a register spill on arm64 (#9014) - -commit 5672fb63d21ca8311513c44a82ffe5a0c8f55240 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-22 23:24:25 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-23 06:01:00 +0900 - - Implement TracePoint on VWA - -commit 8d6175bf64748eb646a83c74ff7bd541fdec166d - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-11-23 05:29:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-23 05:29:51 +0900 - - [ruby/irb] Require prism >= 0.18.0 (MatchWriteNode#targets and - CaseMatchNode) - (https://github.com/ruby/irb/pull/778) - - https://github.com/ruby/irb/commit/943c14b12e - -commit 7a93bee4f845f496742b03a0e575ed13631971b7 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-11-23 04:06:37 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-23 04:06:37 +0900 - - YJIT: add an extra btest for shape too complex (#9013) - - Following Jean Boussier's comment that some shape bugs were not - caught by our tests, I'm trying to improve our test coverage a - tiny bit. - -commit 3720d4c39af7e88f4be98f5d8e1d8a3d47db5208 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-19 10:06:04 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-11-23 03:16:20 +0900 - - [wasm] Upload install directory as artifact to GitHub Actions - -commit 7e9f00f34f4d89c749879872b36fa2c8bbf1d4c3 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-19 10:37:19 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-11-23 03:16:20 +0900 - - [wasm] Build baseruby from the same revision for cross-compiling - - > Note that on cross compiling BASERUBY should be the same version of the building ruby. - > https://github.com/ruby/ruby/wiki/Developer-How-To#prerequisite - -commit 55cad1835ebd57117bc60c2bfc0f8d5ff08a9b64 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-22 23:22:52 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-11-23 02:47:11 +0900 - - [wasm] Update binaryen to version 113 - -commit 29c2c63d6c45670a4ca38af8a98891ee480835f6 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-22 22:24:48 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-11-23 02:47:11 +0900 - - [wasm] Update wasmtime to version 15 - -commit 3ecedebee12733e3e71fbfeafe3b0a8dfcbb0154 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-22 22:21:21 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-11-23 02:47:11 +0900 - - [wasm] Update wasi-sdk to version 20 - -commit c8d99fa662e459f678e0dd12a2d954a20cc1a97e - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-22 23:23:02 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-23 02:42:04 +0900 - - Embed ThreadGroup object - - These are rare but embedding them is trivial and make them fit - in a 40B slot. - -commit 295d648f766d46c5da059dac26b0373f986b6a28 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-23 00:23:04 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-11-23 02:18:53 +0900 - - [wasm] Use xmalloc/xfree for jmpbuf allocation to trigger GC properly - - `rb_vm_tag_jmpbuf_{init,deinit}` are safe to raise exception since the - given tag is not yet pushed to `ec->tag` or already popped from it at - the time, so `ec->tag` is always valid and it's safe to raise exception - when xmalloc fails. - -commit 341321f11596dfef5e9af13fa1fad797fbfcdf67 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-23 01:35:42 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-23 02:17:58 +0900 - - Fix off-by-one with RubyVM::Shape.exhaust_shapes - - Previously, the method left one shape available (MAX_SHAPE_ID) when - called without arguments. - -commit 0e59d91eeddcff4a28add1ce7796ee9cd9ae9e10 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-23 01:08:53 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-11-23 02:15:42 +0900 - - [wasm] Avoid malloc during longjmp - - `longjmp` can be called to raise `NoMemoryError` or to trigger GC when - `malloc` fails to allocate memory in `ruby_xmalloc` family. In such - case, `malloc` call in `longjmp` will fail again, and Asyncify unwinding - operation corrupts the memory space by using the failed pointer as - Asyncify buffer. This commit uses statically allocated buffer to avoid - such situation. - -commit c1fc1a00ea9633961153451d0e927db49c1b268d - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-23 01:59:54 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-23 01:59:54 +0900 - - [wasm] Fix Asyncify loop exit condition for normal return (#9007) - - [wasm] Fix Asyncify loop exit condition for normal return - - Stop calling `asyncify_stop_unwind` when the main function returns - without any unwinding. In the era when Asyncify buffers were allocated - on the stack, the `top` and `end` fields were remained in the stack - space even after the main function returned, so buffer-overflow check in - the `asyncify_stop_unwind` function passed. But now, the `top` and `end` - fields are part of the jump buffer allocated on the heap and they are - deallocated with `free` when the corresponding VM tag is popped. So, the - buffer-overflow check in the `asyncify_stop_unwind` function failed when - the main fuction returned without any unwinding, and we have to break - the asyncify loop before calling `asyncify_stop_unwind`. - - Related commit: https://github.com/ruby/ruby.wasm/commit/bc46b12b127e4b6625a100f373504ed5ea45ae66 - -commit 94144801ebd9d25d02697b921858f99cd99bd9a8 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-11-23 00:49:58 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-11-23 01:16:58 +0900 - - .travis.yml: Drop s390x temporarily. - - The builds are not starting. - - You can check the Travis status on the ticket, - <https://bugs.ruby-lang.org/issues/20013>. - -commit 9691532428766340462f77ab5b601f9979ebd006 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-23 00:01:37 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-23 01:10:03 +0900 - - Get rid of flatten_memo_data_type - - We can use an hidden Hash instead, it's simpler, triggers - write barriers, handle compaction, etc. - -commit 6968b289e756d0df8eec1c1f7d6e5d0596dfda21 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-23 00:13:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-23 00:45:33 +0900 - - [ruby/prism] Check void values in singleton class (`class <<`) - - Follow up the ruby/ruby#8917 change. - - https://github.com/ruby/prism/commit/f6bac4d3bf - -commit 1f06d168bae7926fe518e30f30f41bc1fbfaf161 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-23 00:15:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-23 00:15:07 +0900 - - [ruby/prism] Add new doc to gemspec - - https://github.com/ruby/prism/commit/99dfca6c1d - -commit 8f707e8030c8d3f6c25297bdcfea1e238041205e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-22 23:37:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 23:53:29 +0900 - - [ruby/prism] Join range checks into the main parse_expression switch - - https://github.com/ruby/prism/commit/ed4523464b - -commit 8794836bf256c4bad51111b085f9d07e463432a0 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-15 23:05:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 23:53:28 +0900 - - [ruby/prism] Fix associativity of binary range with begin-less range - - Fix https://github.com/ruby/prism/pull/1828 - - https://github.com/ruby/prism/commit/22c0640e48 - -commit 2aefbbaab9c9a86fb70f30bca86ed73411679d6d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-22 23:32:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 23:53:28 +0900 - - [ruby/prism] Combine expression checks into a single switch - - https://github.com/ruby/prism/commit/825d5d7bd4 - -commit cdd07781b00b41b4f1f25fe9b12cd43d60a92834 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-21 12:20:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 23:53:27 +0900 - - [ruby/prism] Remove TODO - - https://github.com/ruby/prism/commit/d6d718487d - -commit 76f9abced749c081f7301d3260438312a8a10ebb - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-20 13:23:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 23:53:27 +0900 - - [ruby/prism] Reject statements at non-statement posisions - - Fix https://github.com/ruby/prism/pull/1547 - - https://github.com/ruby/prism/commit/cdb643aeab - -commit cc7a5dcd06d288552bf51188bed19e9508790d0a - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-20 22:31:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 23:53:27 +0900 - - [ruby/prism] Add and use pm_parser_local_depth_constant_id - - https://github.com/ruby/prism/pull/1877#discussion_r1398974248 - - https://github.com/ruby/prism/commit/0f545fe636 - -commit 154b2d666d51498e39b8414afb448882c4285288 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-19 10:41:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 23:53:26 +0900 - - [ruby/prism] Allow `&` forwarding in a method having `...` parameter - - Fix https://github.com/ruby/prism/pull/1839 - - https://github.com/ruby/prism/commit/5784ab749f - -commit b040c529a0bf98a22f180c82d2a63db626e4fac5 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-22 03:31:05 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-22 23:36:54 +0900 - - Implement dir on VWA - -commit b45442f8a81c793d1d6a0ce65a3aa856ae4452d5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-22 22:47:18 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-22 23:12:35 +0900 - - [prism] Add cp949 targets to common.mk - -commit e3ef05a4343f447883183bc28e515715eedad9c4 - Author: heyogrady <ogradypatrickj@gmail.com> - AuthorDate: 2023-11-22 13:17:09 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-22 23:12:35 +0900 - - [ruby/prism] Add `CP949` encoding - - https://github.com/ruby/prism/commit/9e78dfdf69 - -commit 4f031a745d528e0a8a626c340787c7c3ab9ea143 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-22 21:36:10 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-22 22:52:32 +0900 - - Embed File::Stat objects - - They are very short lived and fit in a 160B slot. - -commit 0f24ecf17ae43a9c2501d0f3e5b2a6d829fcdd7f - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-22 06:33:19 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-22 22:38:36 +0900 - - Implement Write Barriers on TracePoint - -commit 6d5aa796976d9c76d5416f78377fd26f2835ae94 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-11-22 22:04:46 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-11-22 22:30:54 +0900 - - .travis.yml: Allow failures for s390x. - - https://app.travis-ci.com/github/ruby/ruby/builds/267410310 - -commit e9ccceab1106fe887665646f2035f7005fc2a5a5 - Author: Patrick O'Grady <ogradypatrickj@gmail.com> - AuthorDate: 2023-11-22 22:21:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 22:21:15 +0900 - - [ruby/prism] Add KOI8-U encoding - (https://github.com/ruby/prism/pull/1906) - - * Add test for KOI8-U - - * Rename koi8 char_width function - - - Rename function for use with any KOI8-based encoding - - * Add KOI8-U encoding - - * Add encoding to encoding.md - - https://github.com/ruby/prism/commit/6cad4552f7 - -commit c05495530e0308d82a39bb5b248f711f0a485921 - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-20 20:20:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 22:17:12 +0900 - - [rubygems/rubygems] Fix universal lockfiles regression - - If a platform specific variant would not match the current Ruby, we would still be - considering it compatible with the initial resolution and adding its - platform to the lockfile, but we would later fail to materialize it for - installation due to not really being compatible. - - Fix is to only add platforms for variants that are also compatible with - current Ruby and RubyGems versions. - - https://github.com/rubygems/rubygems/commit/75d1290843 - -commit 018e6abf8509c7de2a8efb49741d594b15f49fbf - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-11-21 01:43:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 21:15:20 +0900 - - [ruby/prism] Move CallNode#name field between receiver and arguments - - * The same order as in source code. - * CallOrWriteNode, CallOperatorWriteNode, CallAndWriteNode already have - the correct order so it was also inconsistent with them. - - https://github.com/ruby/prism/commit/4434e4bc22 - -commit ea60bf912caa3ea193b7673b59b0113c1e708609 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-11-22 21:06:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 21:06:25 +0900 - - [ruby/irb] Rescue Exception, ignore warning in completion - doc_namespace - (https://github.com/ruby/irb/pull/777) - - https://github.com/ruby/irb/commit/c2f671611a - -commit 9ae6ee5a59e74e629f73222938b53a6eae8d2ded - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-22 18:27:46 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-22 21:04:21 +0900 - - Embed exec_arg objects - - They are very ephemeral, so avoiding the malloc churn - is desirable. - -commit cdc578ee008775e022f63fc9d567c92c59202505 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-22 18:20:47 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-11-22 19:36:23 +0900 - - Remove unneccesary defines in enumerator - -commit a3f9a98c29117b6aa8b98f45880688885b2a4170 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-22 18:19:46 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-11-22 19:36:23 +0900 - - Remove unneccesary memsize functions in enumerator - -commit 1e075a734f37f6f2e197c50284e3df24621a8882 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-21 23:24:26 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-11-22 19:36:23 +0900 - - VWA Embed the rest of the data objects in Enumerator - -commit 9e24d747ffbc1040d93ac53bff0c1ef0914419c8 - Author: John Bond <b4ldr@users.noreply.github.com> - AuthorDate: 2023-11-22 19:35:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 19:35:36 +0900 - - [ruby/resolv] IPv6: update to_s method to be RFC5952 compliant - (https://github.com/ruby/resolv/pull/25) - - * IPv6: update to_s method to be RFC5952 compliant - - I noticed that the resolv library does not honour RFC 5952 Section 4.2.2. - in relation to textural representation of ipv6 addresses: - - The symbol "::" MUST NOT be used to shorten just one 16-bit 0 field. - For example, the representation 2001:db8:0:1:1:1:1:1 is correct, but - 2001:db8::1:1:1:1:1 is not correct. - - Fixes https://github.com/ruby/resolv/pull/24 - - https://github.com/ruby/resolv/commit/5efcd6ed70 - - Co-authored-by: Sorah Fukumori <sora134@gmail.com> - -commit 6391ae9ebc0b7a6668e57aa9f3c7b76ff83fab70 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-22 17:16:43 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-22 18:24:35 +0900 - - objspace_dump.c: dump call cache ids with dump_append_id - - Not all `ID` have an associated string. - - Fixes a SEGFAULT in ObjectSpace.dump_all spec. - -commit 2d7fb9c2fa5ab6c967f8ff1bc350ce5d3d5344a2 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-22 01:23:56 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-22 18:12:07 +0900 - - Speedup test_shape.rb - - Many tests start by exhausting all shapes, which is a slow process. - By exposing a method to directly move the bump allocator forward - we cut test runtime in half. - - Before: - ``` - Finished tests in 1.544756s - ``` - - After: - ``` - Finished tests in 0.759733s, - ``` - -commit 0745c0c5efdd38d88970dcadad780da61f64655a - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-11-22 15:58:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 15:58:17 +0900 - - Update bundled gems list as of 2023-11-21 - -commit 31517c862760626c228b017a4a6e7c6003abeb84 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-22 13:07:44 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-22 13:07:44 +0900 - - Prevent a compiler warning: ‘zi’ may be used uninitialized - -commit 8e80cad9e9f70948c1c2d472b66a94c4151268f4 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-22 05:17:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 07:30:53 +0900 - - [ruby/prism] Add SPLAT flag on ArrayNode indicating if it contains splat element(s) - - This commit puts a SPLAT flag on any ArrayNodes which contain - SplatNode elements - - https://github.com/ruby/prism/commit/2fc1e7f181 - -commit 3db21d2d4c930b6199bd2eba7fa6ab2f017b8a89 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-22 05:46:48 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-22 07:29:07 +0900 - - [PRISM] Rename flag to CONTAINS_KEYWORD_SPLAT - - We need to do this change first on ruby/ruby before merging to - ruby/prism to avoid breaking ruby/ruby CI - -commit d68e5c6d19d1e903dc5ff309335e1ff1f6329868 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-11-22 07:25:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 07:25:28 +0900 - - [ruby/open3] [DOC] Open3 doc (https://github.com/ruby/open3/pull/21) - - https://github.com/ruby/open3/commit/3bdb402b18 - -commit bad351a93032941c2f19939440cb1bd283309501 - Author: Hiroya Fujinami <make.just.on@gmail.com> - AuthorDate: 2023-11-22 07:10:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 07:10:35 +0900 - - [ruby/prism] Remove handling OptionalNodeField in set_newline_flag - template - (https://github.com/ruby/prism/pull/1905) - - https://github.com/ruby/prism/commit/6f7cbc1ca9 - -commit c34d23fcc85dc7c0fc95fa7683a85f37b13e5a36 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-21 07:01:18 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-22 05:17:25 +0900 - - Implement WeakKeyMap on VWA - - Benchmark: - - ``` - puts(Benchmark.measure do - 10_000_000.times do - ObjectSpace::WeakKeyMap.new - end - end) - ``` - - Before: - - ``` - 2.554772 0.014167 2.568939 ( 2.575763) - ``` - - After: - - ``` - 1.994920 0.013583 2.008503 ( 2.012139) - ``` - -commit de337a312f84cb85e34f38d2d0f914b8d1fb8f51 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-21 06:58:23 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-22 05:17:25 +0900 - - Implement WeakMap on VWA - - Benchmark: - - ``` - puts(Benchmark.measure do - 10_000_000.times do - ObjectSpace::WeakMap.new - end - end) - ``` - - Before: - - ``` - 2.568662 0.014001 2.582663 ( 2.601743) - ``` - - After: - - ``` - 2.025523 0.008676 2.034199 ( 2.041760) - ``` - -commit 57fa69f26f134560e4de2e541a31d187dfc397c7 - Author: Bo Anderson <mail@boanderson.me> - AuthorDate: 2023-11-17 13:27:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 04:11:15 +0900 - - [rubygems/rubygems] Fix invalid platform removal missing adjacent platforms - - https://github.com/rubygems/rubygems/commit/4ce66c41a2 - -commit 7d6f812c311436e357fa3fd7e883c4ea65bbe9e5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-22 02:48:00 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-22 03:59:10 +0900 - - [ruby/prism] Update to v0.18.0 - - https://github.com/ruby/prism/commit/1398879d79 - -commit 209a0253f5869678d7228731605a1a5f21c76f32 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-11-22 02:23:37 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-11-22 02:46:50 +0900 - - Use count macros for counting instance variables - - We don't need to check for Qundef because the shape tells us the number - if IVs that are stored on the object - -commit f397650cda4e99a8eaf710ac5bcf73da960dc30b - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-22 02:22:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 02:22:18 +0900 - - [ruby/prism] Fix lex_state_beg_p - (https://github.com/ruby/prism/pull/1591) - - https://github.com/ruby/prism/commit/46b8576dd0 - -commit 91685c01d3de0b01c0f531917100e2458acaa2c6 - Author: Thiago Araujo <thd.araujo@gmail.com> - AuthorDate: 2023-11-22 02:11:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 02:12:00 +0900 - - [ruby/prism] feat: adds encoding for TIS-620 - (https://github.com/ruby/prism/pull/1901) - - https://github.com/ruby/prism/commit/2c308e6697 - -commit ad25313ca813eda99ac5ae56544a3ec9411f342e - Author: Hiroya Fujinami <make.just.on@gmail.com> - AuthorDate: 2023-11-22 02:03:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 02:03:33 +0900 - - [ruby/prism] Fix `..` and `...` to be non-associative - (https://github.com/ruby/prism/pull/1837) - - Fix https://github.com/ruby/prism/pull/1829 - - https://github.com/ruby/prism/commit/90b0b1974c - - Co-authored-by: Kevin Newton <kddnewton@gmail.com> - -commit 0aafd040c3fee4ad2b5dde4b58c1a4f1ee7ace18 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-21 21:47:49 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-22 01:41:27 +0900 - - Embed ibf_dump objects - -commit 7a9bb6d2a7d3d75cb8c3d83d09819d5bcea09796 - Author: Vinicius Stock <vinistock@users.noreply.github.com> - AuthorDate: 2023-11-22 01:39:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 01:39:27 +0900 - - [ruby/prism] Fix constant path full name when parent is not a - constant - (https://github.com/ruby/prism/pull/1742) - - * Raise if constant path parts contains nodes that can't be used to build full name - - * Fix typo in constant path error documentation - - Co-authored-by: Tim Morgan <tim@timmorgan.org> - - --------- - - https://github.com/ruby/prism/commit/d73a053262 - - Co-authored-by: Tim Morgan <tim@timmorgan.org> - -commit 8966d06b96f2c6396d4c7e58b7a51c9bdebbb694 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-22 01:36:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-22 01:36:12 +0900 - - [ruby/prism] Warning for ENDs in methods - (https://github.com/ruby/prism/pull/1899) - - https://github.com/ruby/prism/commit/1b41c2d56c - -commit a5b482837b743ae6121fc6ca52e5d52985ab93c8 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-21 21:56:21 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-22 01:35:46 +0900 - - Remove string concat node in prism - -commit ddacc0852895adfe3ffec83cdb79ba21f6db169f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-10 13:50:26 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-22 01:35:46 +0900 - - [ruby/prism] Remove string concat in favor of a flat list - - Right now when you have a lot of string concats it ends up being - difficult to work with because of the depth of the tree. You end - up descending very far for every string literal that is part of the - concat. - - There are already times when we use an interpolated string node to - group together two string segments that are part of the same string - (like when they are interupted by the contents of a heredoc). This - commit takes the same approach and replaces string concats with - interpolated string nodes. - - Now that they're a flat list, they should be much easier to work - with. There's still some missing information here that would be - useful to consumers: whether or not there is _actually_ any - interpolation contained in the list. We could remedy this with - another node type that is named something like string list, or we - could add a flag to interpolated string node indicating that there - is interpolation. Either way I want to solve that in a follow-up - commit, since this commit is valuable on its own. - - https://github.com/ruby/prism/commit/1e7ae3ad1b - -commit 903b0931a116691386e71fa30fb1698bbd785853 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-21 21:07:53 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-22 00:54:40 +0900 - - Refactor NameError::message and make it embeded - - These aren't particularly common, but avoiding the malloc churn - for small types is always nice, and this commit also modernize - and cleanup the TypedData API usage. - -commit 751d4b9913d3bbdf6cf09f67b037c7809b95e1ae - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-21 20:03:17 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-22 00:54:24 +0900 - - Make Process::Status embedded - - These are not very common, but they're very easy to convert. - -commit 95d4a52b3ae32abdb4912d3a65b96c056b5511de - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-22 00:28:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-22 00:28:45 +0900 - - YJIT: Skip dump-disasm if it fails to create a file (#8968) - -commit 7e7e2dde2403ad6d5b265ca541d15a51402e6bae - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-21 23:19:15 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-22 00:27:02 +0900 - - Fix memory leak when evacuating generic ivars - - The lookup in the table is using the wrong key when converting generic - instance variables to too complex, which means that it never looks up - the entry which leaks memory when the entry is overwritten. - -commit b4f551686b973b03665bcaa3ecf128c0a87ff58b - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-21 20:09:13 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-21 23:15:03 +0900 - - Get rid of useless dsize functions - - If we always return 0, we might as well not define - the function at all. - -commit f954a5663a6cb5fa9f55f45fd0f87e3e1eca9c17 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-11-21 22:02:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 22:02:21 +0900 - - [ruby/irb] Bump version to 1.9.1 - (https://github.com/ruby/irb/pull/773) - - https://github.com/ruby/irb/commit/997df3e849 - -commit 307af18fa0389135035c0c52f0597580af3008e4 - Author: Soutaro Matsumoto <matsumoto@soutaro.com> - AuthorDate: 2023-11-21 21:30:27 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-21 21:30:27 +0900 - - Bundle rbs-3.3.2 (#8974) - -commit f100c6477ab0a3c49e3256c4eb8efe312ffd0198 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-21 20:19:49 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-21 20:21:18 +0900 - - [Bug #20004] Revert "[Feature #19422] Enable shared by default on macOS" - - This reverts commit 9694445051c4192c8f659529133acab253bd0bc3. - - This change broke our release CI. - - https://github.com/ruby/actions/actions/runs/6599016994/job/17927644579#step:16:44 - - Invoking `/Users/runner/work/actions/actions/snapshot-master/ruby -rrubygems /Users/runner/work/actions/actions/snapshot-master/bin/gem --backtrace build lib/bundler/bundler.gemspec` failed with output: - ---------------------------------------------------------------------- - dyld[42417]: Library not loaded: '/usr/local/lib/libruby.3.3.dylib' - Referenced from: '/Users/runner/work/actions/actions/snapshot-master/ruby' - Reason: tried: '/usr/local/lib/libruby.3.3.dylib' (no such file), '/usr/lib/libruby.3.3.dylib' (no such file) - ---------------------------------------------------------------------- - -commit 1886ee190a26cca0308d69a32c91794f7560595a - Author: Soutaro Matsumoto <matsumoto@soutaro.com> - AuthorDate: 2023-11-21 18:21:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-21 18:21:24 +0900 - - Bundle rbs-3.3.1 (#8921) - - * bundle rbs-3.3.1 - * Restore diff/subtract tests - -commit 371a3a691f17d7fe93c39674d3d5257c8991f0c9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-15 23:35:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-21 17:21:26 +0900 - - Add EXTERNAL_PREFIX to ruby_abi_version - -commit 029871c3feb677d97a15658e4907b77181532ad9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-15 23:31:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-21 17:21:26 +0900 - - typedef ABI version types - -commit f5c3cda7d6e9053ae5ed66e36d13e568595ff1ec - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-07 12:10:00 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-21 15:15:23 +0900 - - Do not change hash type in Hash#assoc - -commit 1cf2fa3af50203f261341ff4c250735c9da5767b - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-08 17:34:09 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-21 15:15:23 +0900 - - Raise an exception when Hash#compare_by_identity during its iteration - -commit a787e0d6494443cfd9bd05ac746704079dcfd03f - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-08 17:09:33 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-21 15:15:23 +0900 - - Raise an exception if ar_table is converted to st_table during iteration - - ar_table may be converted to st_table by `ar_force_convert_table`. - If the conversion occurs during the iteration of ar_table, the iteration - may lead to memory corruption. - - This change prevents the catastrophy by throwing an exception when the - conversion is detected. - - This issue is reported by [SuperS](https://hackerone.com/superss) - -commit c3ab946e86134e05a81c0587ef1d5cdf1de4492f - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-11-15 08:57:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-21 14:39:06 +0900 - - `ObjectSpace.count_nodes` doesn't count nodes - - Node has not been managed by GC from Ruby 2.5. - Therefore these codes are not needed. If ObjectSpace depends on Node, - it needs to update the file when node type is updated. Delete node - related codes to avoid such update. - -commit a861c74813b79fd3d5fb2cf69276e8f90a2a0ba3 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-19 11:12:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-21 14:07:47 +0900 - - Add a test - -commit fe746747b49efb310989792681e171559581920c - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-14 17:15:37 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-21 14:07:47 +0900 - - Reject 'class << (return); end` by "void value expression" - -commit 04eb40b633397d03e4cbce41418626f4fabdcb02 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-11-16 20:32:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-21 14:06:26 +0900 - - [Bug #11183] Fix rb_complex_pow for special angles - - Add a special treatment for when the argument of self is an - integral multiple of 45 degrees. - - 1i ** (10 ** 100) #=> 1+0i - 1i ** (10 ** 100 + 1) #=> 0+1i - (1+1i) ** (10 ** 100) # warning: in a**b, b may be too big - #=> (Infinity+0.0i) - (1+1i) ** (10 ** 100 + 1) # warning: in a**b, b may be too big - #=> (Infinity+Infinity*i) - -commit b6b31f673d9514a8af8992b0f7abb8b0597d87af - Author: Hiroya Fujinami <make.just.on@gmail.com> - AuthorDate: 2023-11-21 11:45:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 11:45:12 +0900 - - [ruby/prism] Check a token after targets more strictly - (https://github.com/ruby/prism/pull/1878) - - Fix https://github.com/ruby/prism/pull/1832 - - https://github.com/ruby/prism/commit/060bcc81a8 - -commit 5299b4a362c000f13778a04acfcac5ec0cd33654 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-21 11:43:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 11:43:18 +0900 - - [ruby/prism] Build the ability to format errors - (https://github.com/ruby/prism/pull/1796) - - Previously, we only supported error messages that were constant - strings. This works for the most part, but there are some times - where we want to include some part of the source in the error - message to make it better. - - For example, instead of "Token is reserved" it's better to write - "_1 is reserved". - - To do this, we now support allocating error messages at runtime - that are built around format strings. - - https://github.com/ruby/prism/commit/7e6aa17deb - -commit 9fa524dd41be60654e8515f9e406f6f47f0ac7fa - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-21 11:38:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 11:38:07 +0900 - - [ruby/prism] Split up CaseNode and CaseMatchNode - (https://github.com/ruby/prism/pull/1801) - - https://github.com/ruby/prism/commit/4c1391ea56 - -commit 73d519ec461bee7c06e37abcb808443a05ec5a21 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-21 10:42:30 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-21 11:18:31 +0900 - - [prism] Remove pm_big5_hkscs from common.mk targets - -commit e16ff17374798fa476527ee3883e447a7e083c8a - Author: Ryan Garver <ragarver@gmail.com> - AuthorDate: 2023-11-19 07:49:48 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-21 11:18:31 +0900 - - Rename the big5-hkscs stuff to something more generic and add UAO sharing common code. - - Merge the Big5 extensions into pm_big5.c - -commit 6fce8c79807e69cfe475b5291e892567c869fbcc - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-26 08:52:37 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-11-21 09:09:48 +0900 - - Don't try compacting ivars on Classes that are "too complex" - - Too complex classes use a hash table to store ivs, and should always pin - their IVs. We shouldn't touch those classes in compaction. - -commit 7164715666cfbffd5540ee374eee2a5568342d2d - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-11-21 09:04:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 09:04:41 +0900 - - [ruby/irb] Enable Setting Completer Type through `IRB_COMPLETOR` - (https://github.com/ruby/irb/pull/771) - - I propose introducing the capability to set the IRB completion kinds via an environment variable, specifically `IRB_COMPLETOR=type`. - This feature aims to enhance the Rails console experience by allowing Rails users to specify their preferred completion more conveniently. - - Currently, when using the Rails console, there's no straightforward way to globally set the type completion across a Rails application repository. - It's possible to configure this setting by placing a `.irbrc` file at the project root. However, using a .irbrc file is not ideal as it allows for broad configurations and can potentially affect the production environment. - My suggestion focuses on allowing users to set the completion to 'type' in a minimal. - - This enhancement would be particularly beneficial for teams writing RBS in their Rails applications. - This type completer, integrated with RBS, would enhance completion accuracy, improving the Rails console experience. - - https://github.com/ruby/irb/commit/032f6da25f - -commit a182b2c5e1dbdbe8960912f8bac076d997a74e65 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-21 01:28:36 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-21 08:59:01 +0900 - - Implement Enumerator objects on VWA - - This commit implements Enumerator objects on VWA. This speeds allocations - and decreases memory usage. - - ``` - require "benchmark" - - ary = [] - - puts(Benchmark.measure do - 10_000_000.times do - u = ary.to_enum - end - end) - - puts `ps -o rss= -p #{$$}` - ``` - - Before: - - ``` - 1.500774 0.002717 1.503491 ( 1.506791) - 18512 - ``` - - After: - - ``` - 0.892580 0.002539 0.895119 ( 0.897642) - 16480 - ``` - -commit ad033207435b8e18f12c70643afbf68725948230 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-21 01:27:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-21 08:59:01 +0900 - - Support declarative marked TypedData objects on VWA - -commit 36afc11ece39a13bc0ca7ace8267d7a91070946a - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-21 08:03:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 08:03:23 +0900 - - [ruby/prism] Fix locations derived from arguments. - (https://github.com/ruby/prism/pull/1897) - - https://github.com/ruby/prism/commit/00b76ef254 - -commit 914640eaddcff7cccbd21fbea84d4ead1e91a5db - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-21 06:09:51 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-21 08:00:44 +0900 - - Use new match write targets - -commit e269096d15a4488a8ae34aca38752989e61304c7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-10 12:59:35 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-21 08:00:44 +0900 - - [ruby/prism] Replace match write locals with match write targets - - https://github.com/ruby/prism/commit/eec1862967 - -commit fa547cd70243710e90bf57377402cbbdf910efa3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-21 07:51:54 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-21 07:51:54 +0900 - - YJIT: Print a disasm path to stderr (#8967) - - YJIT: Print a perf map path to stderr - -commit f376163194686079452ddfd0af61ab505172c07c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-21 04:55:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-21 06:57:24 +0900 - - Fix crash when evacuating generic ivar - - When transitioning generic instance variable objects to too complex, we - set the shape first before performing inserting the new gen_ivtbl. The - st_insert for the new gen_ivtbl could allocate and cause a GC. If that - happens, then it will crash because the object will have a too complex - shape but not yet be backed by a st_table. - - This commit changes the order so that the insert happens first before - the new shape is set. - - The following script reproduces the issue: - - ``` - o = [] - o.instance_variable_set(:@a, 1) - - i = 0 - o = Object.new - while RubyVM::Shape.shapes_available > 0 - o.instance_variable_set(:"@i#{i}", 1) - i += 1 - end - - ary = 1_000.times.map { [] } - - GC.stress = true - ary.each do |o| - o.instance_variable_set(:@a, 1) - o.instance_variable_set(:@b, 1) - end - ``` - -commit 103bbd21f884c279fc8368dac5cc4f62d68231af - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-21 06:27:20 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-21 06:48:46 +0900 - - [PRISM] Updated LocalVariableTargetNodes too - -commit b913626bea138908102cb6b2c9a6bf9438428c76 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-21 05:40:35 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-21 06:48:46 +0900 - - [PRISM] Fix LocalVariableWriteNodes within blocks - - Prior to this commit, we weren't recursing up scopes to look for - the local definition. With this commit, we do so, fixing local writes - within blocks - -commit f9628fb4be1c5eb5a652a6c3d3d97530bdcc76a5 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-11-21 06:26:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-21 06:26:18 +0900 - - YJIT: make --yjit-max-versions=N option undocumented (#8962) - - Not useful for the vast majority of end users to change - this option. - -commit 323bec6295e46a6f4926e742f7444fc54924b527 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-09 16:39:12 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-21 05:45:29 +0900 - - RubyVM::InstructionSequence.compile_file_prism - - * Provide a new API compile_file_prism which mirrors compile_file - but uses prism to parse/compile. - * Provide the ability to run test-all with RUBY_ISEQ_DUMP_DEBUG set - to "prism". If it is, we'll use the new compile_file_prism API to - load iseqs during the test run. - -commit 2796e4ece24f62f7d952a894097726b85bbd6fc8 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-11-14 08:52:03 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-21 05:42:05 +0900 - - [PRISM] Implement once node for interpolated regex - - This PR implements the once node on interpolated regexes. - - There is a bug in Prism where the interpolated regex with the once flag - only works when there is not a local variable so the test uses a "1". - We'll need to fix that. - -commit c5d5929443d58d72cb9688a9fac6487ce17c1e9d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-21 01:47:54 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-21 05:12:34 +0900 - - [PRISM] Don't pop args to YieldNode - -commit 307a5cb20b3e34f6a3bd240e70ddc26bd268ace3 - Author: Lynne Ashminov <47822041+lynne-ashminov@users.noreply.github.com> - AuthorDate: 2023-11-21 05:06:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 05:06:14 +0900 - - [ruby/prism] adds encodings for ibm869 - (https://github.com/ruby/prism/pull/1886) - - https://github.com/ruby/prism/commit/41462400b7 - -commit 9fbdb26f06822305781a7fa12db1ee7249dbd0a8 - Author: Maple Ong <maple.ong@gusto.com> - AuthorDate: 2023-11-21 05:05:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 05:06:00 +0900 - - [ruby/prism] Add and test ibm863 encoding - (https://github.com/ruby/prism/pull/1853) - - * Add and test ibm863 - - * Remove dup encoding and add alias - - * Update test/prism/encoding_test.rb - - Co-authored-by: Kevin Newton <kddnewton@gmail.com> - - * Readd bitfield table lol - - --------- - - https://github.com/ruby/prism/commit/4cd756d7ff - - Co-authored-by: Kevin Newton <kddnewton@gmail.com> - -commit ffb1eb37e74334ae85d6bfee07d784a145e23dd8 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-21 01:23:07 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-21 02:04:13 +0900 - - proc.c: Make Method and UnboundMethod embded - - Avoid some needless malloc churn - - ``` - compare-ruby: ruby 3.3.0dev (2023-11-20T02:02:55Z master 701b0650de) [arm64-darwin22] - last_commit=[ruby/prism] feat: add encoding for IBM865 (https://github.com/ruby/prism/pull/1884) - built-ruby: ruby 3.3.0dev (2023-11-20T16:23:07Z embedded-methods e35284bfaa) [arm64-darwin22] - warming up.. - - | |compare-ruby|built-ruby| - |:------------------------|-----------:|---------:| - |allocate_method | 8.413M| 12.333M| - | | -| 1.47x| - |allocate_unbound_method | 8.083M| 11.607M| - | | -| 1.44x| - ``` - - ``` - prelude: | - class SomeClass - def foo - end - end - some_object = SomeClass.new - benchmark: - allocate_method: some_object.method(:foo) - allocate_unbound_method: SomeClass.instance_method(:foo) - ``` - -commit 5278742bf0bfcee343f31bcedea3f14896fa47f9 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-21 01:00:19 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-21 01:43:01 +0900 - - marshal.c: embed load and dump argument objects - - This avoid a bit of needless malloc churn. - -commit 05028f4d553776793467fa585b1080075f7c448e - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-21 00:35:58 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-21 01:27:32 +0900 - - compile.c: make pinned_list embedable - - This saves some malloc churn for small pin lists. - -commit 5b0256e3c47c0ff783291c80573489937abf163c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-21 01:12:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 01:12:50 +0900 - - [ruby/prism] Disallow defining a numbered parameter method - (https://github.com/ruby/prism/pull/1797) - - https://github.com/ruby/prism/commit/c13165e6aa - -commit f9fb05f9d04f4622f6080d582103c612f37cc1f5 - Author: David Wessman <david.wesmn@gmail.com> - AuthorDate: 2023-11-21 01:07:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 01:07:19 +0900 - - [ruby/prism] feat: Adds macCroatian encoding - (https://github.com/ruby/prism/pull/1880) - - * feat: Adds macCroatian encoding - - - Based on: - https://en.wikipedia.org/wiki/Mac_OS_Croatian_encoding - https://www.unicode.org/Public/MAPPINGS/VENDORS/APPLE/CROATIAN.TXT - - Co-authored-by: Josefine Rost <nijrost@gmail.com> - - * Use output from bin/encodings and adds to docs/encoding.md - - --------- - - https://github.com/ruby/prism/commit/019a82d8f3 - - Co-authored-by: Josefine Rost <nijrost@gmail.com> - -commit f2ed7eaba0275099842b5b8407250e2d410f2f25 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-21 01:07:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 01:07:06 +0900 - - [ruby/prism] Add character APIs for locations - (https://github.com/ruby/prism/pull/1809) - - https://github.com/ruby/prism/commit/d493ccd093 - -commit adee7dab3edc3d58cc3d7245398b75ab1de8d077 - Author: Hiroya Fujinami <make.just.on@gmail.com> - AuthorDate: 2023-11-21 00:58:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 00:58:19 +0900 - - [ruby/prism] Correctly parse the `resuce` modifier in the rhs of the - assignments - (https://github.com/ruby/prism/pull/1879) - - Fix https://github.com/ruby/prism/pull/1541 - - https://github.com/ruby/prism/commit/9fb276e1f4 - -commit 75d85f3f6f10581e1265f4b1d91ffb257bb4502a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-21 00:53:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 00:53:22 +0900 - - [ruby/prism] Remove non-ASCII source characters - (https://github.com/ruby/prism/pull/1787) - - https://github.com/ruby/prism/commit/5acc38a2f3 - -commit caa9ae780430a67c1ed3cb5f15b0e023452d76e4 - Author: Hiroya Fujinami <make.just.on@gmail.com> - AuthorDate: 2023-11-21 00:52:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-21 00:52:44 +0900 - - [ruby/prism] Fix parsing `...` in arguments - (https://github.com/ruby/prism/pull/1882) - - * Fix parsing `...` in arguments - - Fix https://github.com/ruby/prism/pull/1830 - Fix https://github.com/ruby/prism/pull/1831 - - * Rename the constant name to PM_ERR_ARGUMENT_FORWARDING_UNBOUND - - https://github.com/ruby/prism/pull/1882#discussion_r1398461156 - - https://github.com/ruby/prism/commit/519653aec2 - -commit 83da4a7e6291fbc919c1a5813f3e84b8fdd858d5 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-21 00:13:18 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-21 00:13:18 +0900 - - Fix crash when iterating over generic ivars - -commit 4dd11c067da85aa8af1b712d76f51d42ce2cee6f - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-11-14 09:03:24 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-21 00:05:09 +0900 - - Switching first argument in pm_interpolated_node_compile - - This changes the first argument in `pm_interpolated_node_compile` to use - a pointer. - -commit 46ef74f270d022068def440ab6208e1648030847 - Author: Étienne Barrié <etienne.barrie@gmail.com> - AuthorDate: 2023-11-17 18:24:02 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-20 23:23:56 +0900 - - Embed Thread::Backtrace::Location into Thread::Backtrace - - Co-authored-by: Jean Boussier <byroot@ruby-lang.org> - -commit 83c385719d95c178790e52f78e2b247d1476eb5e - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-20 21:48:34 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-20 22:33:20 +0900 - - Specialize String#dup - - `String#+@` is 2-3 times faster than `String#dup` because it can - directly go through `rb_str_dup` instead of using the generic - much slower `rb_obj_dup`. - - This fact led to the existance of the ugly `Performance/UnfreezeString` - rubocop performance rule that encourage users to rewrite the much - more readable and convenient `"foo".dup` into the ugly `(+"foo")`. - - Let's make that rubocop rule useless. - - ``` - compare-ruby: ruby 3.3.0dev (2023-11-20T02:02:55Z master 701b0650de) [arm64-darwin22] - last_commit=[ruby/prism] feat: add encoding for IBM865 (https://github.com/ruby/prism/pull/1884) - built-ruby: ruby 3.3.0dev (2023-11-20T12:51:45Z faster-str-lit-dup 6b745bbc5d) [arm64-darwin22] - warming up.. - - | |compare-ruby|built-ruby| - |:------|-----------:|---------:| - |uplus | 16.312M| 16.332M| - | | -| 1.00x| - |dup | 5.912M| 16.329M| - | | -| 2.76x| - ``` - -commit 701b0650de8a5b1436ce1abc65e0fcc2be480c2d - Author: Derek Moore <42558474+derekcmoore@users.noreply.github.com> - AuthorDate: 2023-11-20 11:02:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-20 11:02:55 +0900 - - [ruby/prism] feat: add encoding for IBM865 - (https://github.com/ruby/prism/pull/1884) - - * feat: add encoding for IBM865 - - * style: fix incorrect autoformat - - https://github.com/ruby/prism/commit/14c6ae0182 - -commit 9aee12cc28cbca40306784e54e38558688caa9f7 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-19 10:00:33 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-11-19 11:52:57 +0900 - - [wasm] Enable more ext libraries on CI as much as possible - -commit 37585fd62abbc4f4cd4b2ae7b5fbb11fbc8e62c0 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-11-19 11:42:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-19 11:42:33 +0900 - - [ruby/open3] [DOC] RDoc for Open3 - (https://github.com/ruby/open3/pull/20) - - https://github.com/ruby/open3/commit/4c9e7492eb - -commit 8b4b0b71777ff3371c2b4e7b8feca047f8f64511 - Author: Hiroya Fujinami <make.just.on@gmail.com> - AuthorDate: 2023-11-19 11:05:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-19 11:05:21 +0900 - - [ruby/prism] Don't add an invalid identifier capture to locals - (https://github.com/ruby/prism/pull/1836) - - * Don't add an invalid identifier capture to locals - - Fix https://github.com/ruby/prism/pull/1815 - - * Delay creating a MatchWriteNode - - https://github.com/ruby/prism/pull/1836#discussion_r1393716600 - - https://github.com/ruby/prism/commit/635f595a36 - -commit 5fea1d08bdeb120029f24e677f0cdcbb390dbbe0 - Author: Syed Faraaz Ahmad <faraaz98@live.com> - AuthorDate: 2023-11-19 10:05:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-19 10:05:41 +0900 - - [ruby/prism] feat: add encoding for ibm866 - (https://github.com/ruby/prism/pull/1864) - - Add encoding for ibm866 - - --------- - - https://github.com/ruby/prism/commit/1a96cc71f7 - - Co-authored-by: Kevin Newton <kddnewton@gmail.com> - -commit 5d2d0962ccac4f33dcd714622bcb1361f64a651f - Author: Orhan Toy <toyorhan@gmail.com> - AuthorDate: 2023-11-19 08:37:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-19 10:05:11 +0900 - - [ruby/prism] Add GB1988 encoding - - https://github.com/ruby/prism/commit/78d3fa7172 - -commit 71a30b7596915189a71e90ebf2c81844cf045248 - Author: Orhan Toy <toyorhan@gmail.com> - AuthorDate: 2023-11-19 08:23:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-19 10:03:19 +0900 - - [ruby/prism] Add macCyrillic encoding - - https://github.com/ruby/prism/commit/220b40921a - -commit db6492092f6ebcbaeecbd6851722c38619182bb1 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-11-19 07:52:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-19 09:56:27 +0900 - - [ruby/prism] Fix typos in comments and docs - - https://github.com/ruby/prism/commit/16b3d19758 - -commit bc744f3f0fbef90934b01f257001d8265055f48e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-19 03:53:42 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-19 03:53:42 +0900 - - [prism] Update common.mk for prism big5 hkscs - -commit cd4316a51f73817a04071bbf4e6e56e235e0430d - Author: Ryan Garver <ragarver@gmail.com> - AuthorDate: 2023-11-18 13:35:28 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-19 03:52:17 +0900 - - [ruby/prism] Big5 HKSCS encoding - - https://github.com/ruby/prism/commit/3ca9823eb4 - -commit bbf14bbba62621b51fafed26b6fe98fb8ae016a3 - Author: Mike Dalton <michaelcdalton@gmail.com> - AuthorDate: 2023-11-18 16:07:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-19 03:47:15 +0900 - - [ruby/prism] Add IBM864 encoding - - Fixes https://github.com/ruby/prism/pull/1868 - Related #1843 - - https://github.com/ruby/prism/commit/abc136dfc9 - -commit fdcb97833cae7580fc85ea5786c72bb575598043 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-18 00:03:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-19 03:43:10 +0900 - - [ruby/prism] Faster lex_keyword - - https://github.com/ruby/prism/commit/23a68dcda2 - -commit a6f9e6add264db1c8909add9b29dbc5ebead94dd - Author: Thomas Marshall <thomas@thomasmarshall.com> - AuthorDate: 2023-11-18 18:59:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-19 03:41:03 +0900 - - [ruby/prism] Add macCentEuro encoding - - https://github.com/ruby/prism/commit/ff95edbd99 - -commit 631b500dd569cb10e095e713999ad1f8093c9521 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-11-19 02:49:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-19 02:49:06 +0900 - - [ruby/irb] Fix irb crash on `{}.` completion - (https://github.com/ruby/irb/pull/764) - - https://github.com/ruby/irb/commit/07e4d540cc - -commit ae48d4ad2ef7abbf116ff28b2cd3748d4c654d80 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-10-31 03:52:02 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-11-19 02:44:42 +0900 - - Ensure keyword splat method argument is hash - - Commit e87d0882910001ef3b0c2ccd43bf00cee8c34a0c introduced a - regression where the keyword splat object passed by the caller - would be directly used by callee as keyword splat parameters, - if it implemented #to_hash. The return value of #to_hash would be - ignored in this case. - -commit c56dd94db0001b900a2dab3ee350a182d6bb42af - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-11-18 17:46:38 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-11-18 19:38:55 +0900 - - Lrama v0.5.10 - -commit f479e629ab497f325091096819fa5bf60c0d03b2 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-18 10:28:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-18 10:32:37 +0900 - - [ruby/prism] Revert "Ensure serialized file is little endian" - - https://github.com/ruby/prism/commit/4cec275fff - -commit 24fe22a5da21c9df8584a4ce6b6d1ce18ac41cc2 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-18 07:57:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-18 07:57:25 +0900 - - Fix ordering for auto compaction in get_overloaded_cme() - - Found through GC.stress + GC.auto_compact crashes in GH-8932. - Previously, the compaction run within `rb_method_entry_alloc()` could - move the `def->body.iseq.cref` and `iseqptr` set up before the call and - leave the `def` pointing to moved addresses. Nothing was marking `def` - during that GC run. - - Low probability reproducer: - - GC.stress = true - GC.auto_compact = true - arr = [] - alloc = 1000.times.map { [] } - alloc = nil - a = arr.first - GC.start - -commit ef72970a046270cc4b1d4ed029128876a9cbab88 - Author: Dana Sherson <robot@dana.sh> - AuthorDate: 2023-11-18 06:41:30 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-18 06:41:30 +0900 - - Fix File.directory? doc hidding File::Stat#directory? doc - - Now the documentation that was already in the codebase for - `File::Stat#directory?` shows up. - -commit 3dd77bc056de19a1cc0ad3fafdb8e49c429dec5a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-18 04:05:37 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-18 06:08:43 +0900 - - Fix corruption when out of shape during ivar remove - - Reproduction script: - - ``` - o = Object.new - 10.times { |i| o.instance_variable_set(:"@a#{i}", i) } - - i = 0 - a = Object.new - while RubyVM::Shape.shapes_available > 2 - a.instance_variable_set(:"@i#{i}", 1) - i += 1 - end - - o.remove_instance_variable(:@a0) - - puts o.instance_variable_get(:@a1) - ``` - - Before this patch, it would incorrectly output `2` and now it correctly - outputs `1`. - -commit 7c99e43c3f050244b06dbd18de4f605ea70d234c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-14 05:05:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-18 05:11:25 +0900 - - [ruby/prism] Ensure serialized file is little endian - - https://github.com/ruby/prism/commit/0c762ee68a - -commit cbdac2f031888fb1cf5fcbabb80c180c3c547adb - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-18 00:22:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-18 05:11:11 +0900 - - [ruby/prism] Silence clang analyzer warnings for the memory leaks - - https://github.com/ruby/prism/commit/68112c556e - -commit 585fdfe1f59951bcfe5c426601330c113c5a1e06 - Author: Peter Cai <222655+pcai@users.noreply.github.com> - AuthorDate: 2023-11-17 13:55:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-18 05:06:48 +0900 - - [ruby/prism] add Windows-874 encoding - - https://github.com/ruby/prism/commit/0670dd3b9a - -commit 229f6e5bb42d24838afb3f5820a5e951f8115788 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-18 05:03:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-18 05:06:28 +0900 - - [ruby/prism] Update spacing in encoding_test.rb - - https://github.com/ruby/prism/commit/56508c2201 - -commit 50b7b927a3a99d5959c94f48e8b084bab937fea1 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-18 00:53:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-18 05:06:27 +0900 - - [ruby/prism] Add macThai - - https://github.com/ruby/prism/commit/f654058f50 - -commit 0a081a33eb036101e7e61cf61e6390481cfe73c3 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-18 00:58:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-18 05:06:16 +0900 - - [ruby/prism] Add macRoman - - https://github.com/ruby/prism/commit/42b20ee399 - -commit 85dcfef23a16ce75575177b24e6726f8ab12d276 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-18 00:44:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-18 05:04:54 +0900 - - [ruby/prism] Add macUkraine - - https://github.com/ruby/prism/commit/440557fddc - -commit e5d6b4099e9f4027dbaaeb8b825ada572279b066 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-13 18:12:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-18 00:48:57 +0900 - - [ruby/prism] Do not allow trailing commas in calls without parenthesis - - https://github.com/ruby/prism/commit/f1d56da58f - -commit db4303f953c85b2b59d3d1af177727240353c2e5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-18 00:27:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-18 00:28:08 +0900 - - [ruby/prism] Never test locale encoding - - https://github.com/ruby/prism/commit/f0f057b055 - -commit c2f2090da6ef28764f7ba3cdeb984aec7243f4ca - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-17 23:50:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 23:50:31 +0900 - - [ruby/prism] Do not test locale encoding on windows - - https://github.com/ruby/prism/commit/8f40536431 - -commit 9ba49c61c28691c131e97d5ea0daf35ab9ea353f - Author: MSP-Greg <Greg.mpls@gmail.com> - AuthorDate: 2023-11-17 05:46:27 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-17 23:47:20 +0900 - - mingw.yml - remove encoding, run tests in cmd shell - -commit 4a26a65e428fbe4088c86068d5525d1f343702ee - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-17 03:32:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 23:32:40 +0900 - - [ruby/prism] Add macTurkish - - https://github.com/ruby/prism/commit/2232d4b6a0 - -commit 940f2e7f1893af17be6e35ef8f7ad09949a12709 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-17 21:40:37 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-17 22:22:07 +0900 - - size_pool_idx_for_size: Include debugging info in error message - - We ran into that case on our CI, including some sizes would help - debug it much easier. - -commit 94c9f166632a901e563463933efd42e618432d70 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-17 01:50:21 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-17 17:19:21 +0900 - - Refactor rb_obj_evacuate_ivs_to_hash_table - - That function is a bit too low level to called from multiple - places. It's always used in tandem with `rb_shape_set_too_complex` - and both have to know how the object is laid out to update the - `iv_ptr`. - - So instead we can provide two higher level function: - - - `rb_obj_copy_ivs_to_hash_table` to prepare a `st_table` from an - arbitrary oject. - - `rb_obj_convert_to_too_complex` to assign the new `st_table` - to the old object, and safely free the old `iv_ptr`. - - Unfortunately both can't be combined into one, because `rb_obj_copy_ivar` - need `rb_obj_copy_ivs_to_hash_table` to copy from one object - to another. - -commit 498b086c374608005278c0f7d105df1925e13a22 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-17 11:01:55 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-17 11:01:55 +0900 - - Skip test_ForwardingArgumentsNode - - due to a failure on a CI - - http://ci.rvm.jp/results/trunk-iseq_binary@ruby-sp2-docker/4779277 - ``` - expected: - == disasm: #<ISeq:prism_test_forwarding_arguments_node1@<compiled>:2 (2,8)-(4,11)> - local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: 1]) - [ 1] "..."@0 - 0000 putself ( 3) - 0001 getlocal_WC_0 ?@-2 - 0003 splatarray false - 0005 getblockparamproxy ?@-1, 0 - 0008 send <calldata!mid:prism_test_forwarding_arguments_node, argc:1, ARGS_SPLAT|ARGS_BLOCKARG|FCALL>, nil - 0011 leave ( 2) - actual: - == disasm: #<ISeq:prism_test_forwarding_arguments_node1@<compiled>:2 (2,8)-(4,11)> - local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: 1]) - [ 1] "..."@0 - 0000 putself ( 3) - 0001 getlocal_WC_0 ?@-2 - 0003 splatarray false - 0005 getblockparamproxy "!"@-1, 0 - 0008 send <calldata!mid:prism_test_forwarding_arguments_node, argc:1, ARGS_SPLAT|ARGS_BLOCKARG|FCALL>, nil - 0011 leave ( 2) - /tmp/ruby/src/trunk-iseq_binary/tool/lib/iseq_loader_checker.rb:36:in `exit': exit (SystemExit) - ``` - -commit 3bc41f4f0b0823e37ac0e89f7943dfe181e005b9 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-17 02:45:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 03:00:08 +0900 - - [ruby/prism] Add macGreek encoding - - https://github.com/ruby/prism/commit/c36d3fc647 - -commit ce853559310c1c0ae0c37521a18b0ba402c48a1b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-16 13:26:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:40 +0900 - - [ruby/prism] Only run encoding tests on CRuby - - https://github.com/ruby/prism/commit/a63acc0629 - -commit 4b2915f0b9f11d965f3c5185c06e23b56ddff78b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-16 13:15:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:40 +0900 - - [ruby/prism] Add macRomania encoding - - https://github.com/ruby/prism/commit/bb73801cf4 - -commit 6c2defdfaa275bccf733988cc2185f144bd8f355 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-16 09:35:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:39 +0900 - - [ruby/prism] Support for the macIceland encoding - - https://github.com/ruby/prism/commit/f433d1b51b - -commit 13bf8c1b46723792b31134cdb11619ed88ff2ca3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-16 09:11:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:38 +0900 - - [ruby/prism] EUC-JP can be triple byte - - https://github.com/ruby/prism/commit/de66ce874a - -commit b753e16945a4bf29ca0e84cecedc1363dffbfc19 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 14:17:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:38 +0900 - - [ruby/prism] IBM862 encoding - - https://github.com/ruby/prism/commit/151698bf86 - -commit 7dba4f424d41290131c229efbdd34930b27354bc - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 14:15:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:37 +0900 - - [ruby/prism] IBM861 encoding - - https://github.com/ruby/prism/commit/6d2b59384a - -commit 91af9e8d93de0bf91406b04ba90821108f87419c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 14:13:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:37 +0900 - - [ruby/prism] IBM860 encoding - - https://github.com/ruby/prism/commit/aa6163d77a - -commit a7df025c3f1b56444aef579f25cf7821ae4a0141 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 14:11:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:36 +0900 - - [ruby/prism] IBM857 encoding - - https://github.com/ruby/prism/commit/8c9b580f84 - -commit 076d0957b9f2f293a58a8572d7004e90b8affded - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 14:09:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:36 +0900 - - [ruby/prism] IBM855 encoding - - https://github.com/ruby/prism/commit/9354ad1848 - -commit b0a188655d17ee5904c5167473fee4e2d3369c0f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 14:07:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:35 +0900 - - [ruby/prism] IBM852 encoding - - https://github.com/ruby/prism/commit/45251fcbf1 - -commit f93e4ac18e04377dea56941fc7ce599cdc7ddbcf - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 14:04:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:34 +0900 - - [ruby/prism] Split up encoding comparisons based on first letter - - https://github.com/ruby/prism/commit/80fac1e4a9 - -commit ef748f353bd02a88e1ce2488738e3e191e874f74 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 13:50:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:34 +0900 - - [ruby/prism] IBM775 encoding - - https://github.com/ruby/prism/commit/65175641b1 - -commit ae3c3467467b86b01eb53cf160104ebf39a92ad0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 13:48:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:33 +0900 - - [ruby/prism] IBM-737 encoding - - https://github.com/ruby/prism/commit/af1a665939 - -commit 8c44d69b9f2fade0bde3e18b13e3eb6810ba684a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 13:44:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:33 +0900 - - [ruby/prism] IBM720 encoding - - https://github.com/ruby/prism/commit/fc1f6ea3af - -commit ba937eee0bad0de702bd19cfb467aad67c8d33c0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 13:41:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:32 +0900 - - [ruby/prism] IBM437 encoding - - https://github.com/ruby/prism/commit/d60329eeb5 - -commit f60b974393d76126bf6fc4566f7bf4c754c3ca70 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 13:15:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:32 +0900 - - [ruby/prism] Add cp855 encoding - - https://github.com/ruby/prism/commit/8069d143f5 - -commit 5d7e6842b5b886ae8d71196062a2608408c5b1ac - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 13:11:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:31 +0900 - - [ruby/prism] Add cp852 encoding - - https://github.com/ruby/prism/commit/ebe83490bf - -commit 63c490dc4efea44483d0f5b4e3a6b47a29aa8e84 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 13:00:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:30 +0900 - - [ruby/prism] Add remaining windows encodings - - https://github.com/ruby/prism/commit/e77b549a59 - -commit ca789e7232f95f485198a459fdf23bff16a2c370 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 12:52:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:30 +0900 - - [ruby/prism] Add windows-1250 encoding - - https://github.com/ruby/prism/commit/a362535ca4 - -commit aebc6e8b8db259b7eeee203f6ec4137019081d70 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 12:10:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:29 +0900 - - [ruby/prism] Fix parsing other encodings bytes >= 0x80 - - https://github.com/ruby/prism/commit/c787d2e076 - -commit f8dcb06ffaef25f06ae223ef79daec15a6d8bf96 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-12 12:09:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:39:29 +0900 - - [ruby/prism] Include GBK user-defined sections - - https://github.com/ruby/prism/commit/4f71d3bdb1 - -commit a6548e9eef1362d88708077ad3fc086c5fb9d04a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-17 02:16:43 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-17 02:16:43 +0900 - - [prism] Add cp51932 to common.mk - -commit 124319486b57bc3d242460c5c651f551ce9776f1 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-17 02:14:24 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-17 02:14:24 +0900 - - [prism] Ignore other generated files from prism - -commit d976e7cc4b50bb4ce3ea071894db9409ce9b4fd6 - Author: Maple Ong <maple.ong@gusto.com> - AuthorDate: 2023-11-16 08:41:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:13:17 +0900 - - [ruby/prism] Update gemspec - - https://github.com/ruby/prism/commit/1a10f6f9c0 - -commit 1ead19825dec47438a9de71ab585ac7d5ddf1dcf - Author: Maple Ong <maple.ong@gusto.com> - AuthorDate: 2023-11-16 08:41:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:13:17 +0900 - - [ruby/prism] Test cp51932 - - https://github.com/ruby/prism/commit/29ba8cd1f2 - -commit ae56db590fffb79902b7815a86e430732d8eed14 - Author: Maple Ong <maple.ong@gusto.com> - AuthorDate: 2023-11-16 08:40:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:13:16 +0900 - - [ruby/prism] Hook up encoding file to prism - - https://github.com/ruby/prism/commit/93ec917dfe - -commit 5277cf3eefd9401957349b4611caaaa65d99ec80 - Author: Maple Ong <maple.ong@gusto.com> - AuthorDate: 2023-11-16 08:40:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 02:13:16 +0900 - - [ruby/prism] Add cp51932 encoding file - - https://github.com/ruby/prism/commit/c67a0f4c78 - -commit 81b35fe7297957d78715a812f6edecec23c6e3b2 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-17 00:28:12 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-17 01:49:59 +0900 - - rb_evict_ivars_to_hash: get rid of the sahpe paramater - - It's only used to allocate the table with the right size, - but in some case we were passing `rb_shape_get_shape_by_id(SHAPE_OBJ_TOO_COMPLEX)` - which `next_iv_index` is a bit undefined. - - So overall we're better to just allocate a table the size of the existing - object, it should be close enough in the vast majority of cases, - and that's already a de-optimizaton path anyway. - -commit b92a92a3fff88a3a39bec72bfc48b1b6e936137e - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-11-17 01:28:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-17 01:28:07 +0900 - - [DOC] More on JSON extensions (#8898) - -commit 2524c8b5511753b1d854512d0a5b37afc4e2ff5c - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-11-17 01:27:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 01:27:41 +0900 - - [ruby/open3] [DOC] RDoc for Open3 - (https://github.com/ruby/open3/pull/19) - - https://github.com/ruby/open3/commit/577bee9696 - -commit e3f464522ca3d1d742a7bba7cb3ad132997a050f - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-11-16 17:55:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 00:13:08 +0900 - - [ruby/prism] Fix calls with splat without parenthesis - - https://github.com/ruby/prism/commit/d81a77e0e3 - -commit 64a122acfdd93d498a79a50c6ddf1887f253a952 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-16 15:26:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-17 00:12:01 +0900 - - [ruby/prism] Add test cases for `in` in `case` condition - - Fix https://github.com/ruby/prism/pull/1515 - - It is also fixed by #1807, so this adds only test cases. - - https://github.com/ruby/prism/commit/a0092f075e - -commit 9786b909f96804df50ed2ff0be0ef8c6eead4132 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-16 06:09:59 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-16 18:23:15 +0900 - - Fix regex match cache out-of-bounds access - - Previously the following read and wrote 1 byte out-of-bounds: - - $ valgrind ruby -e 'p /(\W+)[bx]\?/i.match? "aaaaaa aaaaaaaaa aaaa aaaaaaaa aaa aaaaxaaaaaaaaaaa aaaaa aaaaaaaaaaaa a ? aaa aaaa a ?"' 2> >(grep Invalid -A 30) - - Because of the `match_cache_point_index + 1` in - memoize_extended_match_cache_point() and - check_extended_match_cache_point(), we need one more byte of space. - -commit c65bb5a0f8a083e9a3fd7cec542ef7e494edfc48 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-16 16:53:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-16 18:14:48 +0900 - - Warn bundled gems before Ruby 3.4.0 - -commit 7415901ac29279fe27bea73d1415a617b42b3a65 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-16 16:08:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-16 18:14:48 +0900 - - Always revert or skip extended require of RubyGems. - -commit e374512682b9fcc8b47c633a946b99f722d77411 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-16 11:18:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-16 11:22:08 +0900 - - [ruby/rdoc] Revert "chore: Remove unnecessary argument for `join` method" - - This reverts commit https://github.com/ruby/rdoc/commit/4a1c74bc0a09. - - Since RDoc still supports ruby 2.6 which has not deprecated `$,`, the - argument of `Array#join` is not unnecessary yet. - - https://github.com/ruby/rdoc/commit/72897d32ed - -commit 8d160b9350b35ece2bac1669d8aa513622ca2a5b - Author: toshimaru <me@toshimaru.net> - AuthorDate: 2023-11-16 09:18:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-16 10:43:12 +0900 - - [ruby/rdoc] chore: Remove unnecessary argument for `join` method - - https://github.com/ruby/rdoc/commit/4a1c74bc0a - -commit 72242e69aa7ad1e8ec9c5d7533c3bfd22a16d239 - Author: toshimaru <me@toshimaru.net> - AuthorDate: 2023-11-16 09:18:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-16 10:43:12 +0900 - - [ruby/rdoc] fix: Fix NoMethodError for `tokens_to_s` method - - Calling `tokens_to_s` gets an error if `token_stream` is nil: - - ``` - undefined method `compact' for nil:NilClass (NoMethodError) - ``` - - So, fall back to an empty array if `@token_stream` is nil. - - https://github.com/ruby/rdoc/commit/452e4a2600 - -commit d2e7a70ee6865a92992d4d793cd08a2805d2658a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-16 07:55:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-16 08:08:11 +0900 - - [ruby/prism] Track the then keyword for conditionals - - https://github.com/ruby/prism/commit/fef0019a25 - -commit e9bc530795a13103ac5fd01475422cab632420cd - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-10 04:30:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-15 19:38:28 +0900 - - [rubygems/rubygems] Make temp gem home independent of pwd - - https://github.com/rubygems/rubygems/commit/5c36556d2e - -commit 5bf75c20a2098e626d0dd65708a35c46039c5310 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-15 17:52:46 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-15 19:27:10 +0900 - - Refactor the settings of test-all out - - test/runner.rb and tool/lib/test/unit/parallel.rb must use the same - settings. However, some settings were copied and pasted, while some were - added only to test/runner.rb. - This changeset creates tool/test/init.rb for all settings of test-unit, - which is loaded not only by test/runner.rb but also - tool/lib/test/unit/parallel.rb. - - Background: the GEM_HOME environment variable was removed in - test/runner.rb, which prohibit `require "rake"` (note that rake is a - bundled gem). However the parallel mode didn't refrect this setting, - i.e., `require "rake"` was allowed. - This leads to an inconsistency, which actually affected a test test - defines s test class *only when* `require "rake"` is successful. - (test/rubygems/test_gem_package_task.rb) - - https://github.com/ruby/ruby/actions/runs/6807729617/job/18511055636#step:8:1714 - ``` - /home/runner/work/ruby/ruby/src/tool/lib/test/unit.rb:729:in `const_get': uninitialized constant TestGemPackageTask (NameError) - - suites.map! {|r| ::Object.const_get(r[:testcase])} - ^^^^^^^^^^ - ``` - -commit 960a031a06e4401589cfa29673e27b0bf2895f6d - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-15 18:40:12 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-15 19:19:03 +0900 - - vm_setivar_slowpath: improve bug error message - - We're occasionally hitting this bug on CI, it would be useful - to see if the id is consistent. - -commit db8d437d4e2ff3f9c591cee1e5e1d6594e86301f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-15 15:27:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-15 17:52:40 +0900 - - No need to save `$VERBOSE` - -commit b003c95ef4904e31779c4015df6afe292d3fb975 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-15 15:25:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-15 17:52:40 +0900 - - Separate tests for Hash only from tests for Hash and its subclasses - -commit ad72d96fcc8c164c6a9e11d138f01b02661b9ab2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-14 22:10:08 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-15 17:52:40 +0900 - - Escape and quote non-local variable names - -commit 7998dcdedc7f1d3cfaabfc3f68ca7635f0e5e1d1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-14 22:07:15 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-15 17:52:40 +0900 - - Remove invariant condition - - The `while` loop condition dereferences `cfp` and no `break` there, - `cfp` cannot be NULL just after the loop. - -commit b69bbf588a3dd167d62dbb89f0cef25ebae4a7ea - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-10-23 05:25:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-15 17:33:14 +0900 - - [rubygems/rubygems] User bundler UA when downloading gems - - Gem::RemoteFetcher uses Gem::Request, which adds the RubyGems UA. - Gem::RemoteFetcher is used to download gems, as well as the full index. - We would like the bundler UA to be used whenever bundler is making - requests. - - This PR also avoids unsafely mutating the headers hash on the shared - `Gem::RemoteFetcher.fetcher` instance, which could cause corruption or - incorrect headers when making parallel requests. Instead, we create one - remote fetcher per rubygems remote, which is similar to the connection - segregation bundler is already doing - - https://github.com/rubygems/rubygems/commit/f0e8dacdec - -commit 536649f819ed8f2bb0f8f44b1a0ca5c6d1753b24 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-15 14:58:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-15 14:58:51 +0900 - - Fix IRB tests (#8925) - - * Revert "Fixup da2c2931a60" - - This reverts commit e1978a905a32af2d48b6e9efb6d0fe1656fddc5b. - - * Revert "Skip Type completion tests related with IRB::VERSION" - - This reverts commit da2c2931a602da22bc1fd10dc41f5c3a117bf502. - - * require irb/version to test IRB::VERSION - - --------- - - Co-authored-by: tompng <tomoyapenguin@gmail.com> - -commit e1978a905a32af2d48b6e9efb6d0fe1656fddc5b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-15 11:15:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-15 12:11:12 +0900 - - Fixup da2c2931a60 - -commit 9cba65fd18a090036ac745085b6bd362caea04dc - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-15 09:27:36 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-11-15 11:38:55 +0900 - - test: Follow-up fix for #8916 - - `test_thread_trace` is also flaky due to the same reason as #8916. - - https://rubyci.s3.amazonaws.com/centos7/ruby-master/log/20231114T213002Z.fail.html.gz - https://rubyci.s3.amazonaws.com/wsl2/ruby-master/log/20231114T090003Z.fail.html.gz - -commit da2c2931a602da22bc1fd10dc41f5c3a117bf502 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-15 10:34:22 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-15 11:02:16 +0900 - - Skip Type completion tests related with IRB::VERSION - -commit 197ab823bad0bce93bfd9248dcfac9e548d9e806 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-15 10:04:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-15 10:09:00 +0900 - - Revert "Tests of irb is still broken." - - This reverts commit 5398bbcbab702907430ee019d07f5dcf2b0ce4af. - - We explicitly load rubygems at rubygems_ext.rb - - https://github.com/rubygems/rubygems/commit/8840d8507be72ff32bcbbdfb14e0b54efb364ffa - -commit befad28f3041b2c26589ed7fc0e19fbe52893806 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-15 05:50:53 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-15 06:22:03 +0900 - - Resync prism delete bin/dot - -commit 93e9be2f69a916935ec97322a75b8516527e5b7e - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-14 17:05:16 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-15 06:22:03 +0900 - - [ruby/prism] Check value expressions on creating a node - - https://github.com/ruby/prism/commit/d60948bac3 - -commit 5048c4f461bb98880bc8cacc2bbee9660afa8790 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-14 16:20:41 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-15 06:22:03 +0900 - - [ruby/prism] Check value expressions on parsing arguments and assignments - - They are corresponding to `arg_value` in `parse.y`. - - https://github.com/ruby/prism/commit/a4a4834e0d - -commit ed755181925da920b8a9b07e167e92f3950d1b2a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-10 14:31:07 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-15 06:22:03 +0900 - - [ruby/prism] Rename librubyparser to libprism - - librubyparser was an artifact of the prototype that was initially - named ruby-parser. Instead, this renames it to libprism to be - consistent with the actual name. - - https://github.com/ruby/prism/commit/8600b06811 - -commit 80e379bda1aa38b601a3c010b401c566e1708189 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-14 16:20:41 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-15 06:22:02 +0900 - - [ruby/prism] Check value expressions on parsing arguments and assignments - - They are corresponding to `arg_value` in `parse.y`. - - https://github.com/ruby/prism/commit/a4a4834e0d - -commit bc84334af7e6100f0ede678704f5b80fcaabc0c9 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-04 02:36:28 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-15 06:22:02 +0900 - - [ruby/prism] Add the ability to convert nodes to dot - - https://github.com/ruby/prism/commit/3e4b4fb947 - -commit db8803d583c31767a2f6771ecdf929bf5ee6c278 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-02 02:29:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-15 06:19:12 +0900 - - [ruby/prism] More consistent lex modes with %q - - https://github.com/ruby/prism/commit/014f714ed1 - -commit 336d81a6718c64cade9f1dfcfdf159fbfa92ba3a - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-14 17:05:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-14 23:34:48 +0900 - - [ruby/prism] Check value expressions on creating a node - - https://github.com/ruby/prism/commit/d60948bac3 - -commit 499786de4658de5d9c1ebe68ec99fbbfdf63f8e1 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-14 16:20:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-14 23:34:48 +0900 - - [ruby/prism] Check value expressions on parsing arguments and assignments - - They are corresponding to `arg_value` in `parse.y`. - - https://github.com/ruby/prism/commit/a4a4834e0d - -commit 3439f1e62e60db0f154ffdb53a1217378b4c9038 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-14 15:40:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-14 23:34:47 +0900 - - [ruby/prism] Add parse_value_expression - - https://github.com/ruby/prism/commit/37fad74134 - -commit 52a0f1d14b76e4b095fc61323f669b1a1d6be960 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-13 16:03:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-14 23:34:47 +0900 - - [ruby/prism] Add "Unexpected void value expression" error - - https://github.com/ruby/prism/commit/88b7b8e1fc - -commit 26d11383e548dccd7493079daeb9626c059aa87f - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-11-14 08:14:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-14 23:25:41 +0900 - - [ruby/prism] fix: float suffix at end of file - - Found by fuzzing. - - https://github.com/ruby/prism/commit/d77d4fe2b7 - -commit d6d1a1839abb64b40e5490509b498757a68c77f1 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-11-13 06:29:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-14 23:11:55 +0900 - - [ruby/prism] fix: nested heredoc dedentation use-after-free - - Because the lex mode may be freed when popped, we need to store off - this value for dedentation. - - https://github.com/ruby/prism/commit/64007322f5 - - Co-authored-by: Kevin Newton <kddnewton@gmail.com> - -commit 6fb030e6f1f7cfe162f5db9fca0bc6e4ca0880ff - Author: Soutaro Matsumoto <soutaro@block.xyz> - AuthorDate: 2023-11-14 21:28:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-14 22:08:32 +0900 - - Skip TOPDIR test - -commit bb008f006cf4e8ab53e59cdbac9f3c002ff80b32 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-14 20:56:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-14 22:08:32 +0900 - - Update bundled gems manually - -commit e6b2cd15e34cbeaf07d8ced2db89d02272e9d5af - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-14 20:35:56 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-14 20:35:56 +0900 - - Skip test_diff_* from rbs tests. It used bundle command - -commit 63fdfa1312a8d54ff5f1493dd4759de0253848f1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-14 17:29:15 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-14 17:29:15 +0900 - - [DOC] Link Dir.exist? to File.directory? - -commit b01118f29c6cd4d74b0f7a9c1976c9b242528677 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-14 17:20:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-14 17:20:57 +0900 - - [DOC] Describe Dir.home - -commit 99355122753c4f2ac002fb55e0b31924e0e1cee4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-14 16:23:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-14 16:59:56 +0900 - - [ruby/rdoc] Fix TIDYLINK after braces - (https://github.com/ruby/rdoc/pull/1015) - - TIDYLINK multi-word label should not include braces. - - https://github.com/ruby/rdoc/commit/41ad3191e9 - -commit 50e1c293b780e70f333bee9ded27e11a2a2e0606 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-14 14:31:25 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-11-14 16:01:07 +0900 - - test: Assert only events originated from the test_settracefunc.rb test file - - This test suite is flaky on CI, because the test asserts events from - finalizers also. Tracing events from finalizers is not deterministic - and is not a part of test interests, so this commit changes the test - to assert only events originated from the test file itself. - -commit 19a7a7660c34c862689f99b4f9b0447be92cbffb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-14 15:39:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-14 15:56:58 +0900 - - [DOC] Adjust heading levels - - So that the first headings would be the top-most headings. - -commit caa9881fde884238e38c2decea97ecfca559280c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-14 13:53:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-14 15:56:57 +0900 - - [DOC] Fix doc/regexp.rdoc links - - - Rename regexp.rdoc to exclude from "Pages". This file is for to be - included in the "class Regexp" document, but it also appeared as a - separate page duplicately. - - Fix links on case-sensitive filesystems. - - Fix to use rdoc-ref instead of converted HTML page names. - -commit e020eb26f060d96e332a1beb1001716ddda7a7a6 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-11-13 03:47:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-14 14:25:46 +0900 - - [ruby/prism] fix: Handle zero-length block parameters in invalid Ruby - - Found by fuzzing. - - https://github.com/ruby/prism/commit/4cd6c8cf98 - -commit 33b92c2d6bcba16382cbb33159b8ce7e4d9802de - Author: Paul Bob <paul.ionut.bob@gmail.com> - AuthorDate: 2023-11-09 23:19:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-14 12:18:55 +0900 - - [rubygems/rubygems] improvement: include response body on fetch_http error - - https://github.com/rubygems/rubygems/commit/de4189af35 - -commit fabf5bead70edc8162dba24fad9f2a1cbe4ff85e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-11 06:17:51 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-14 08:26:36 +0900 - - Don't overwrite shape capacity when removing ivar - - Other objects may be using the shape, so we can't change the capacity - otherwise the other objects may have a buffer overflow. - -commit 68869e9bd921e4021a9ee8eee5a36377dd2b2a90 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-11 06:17:39 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-14 08:26:36 +0900 - - Revert "Revert "Remove SHAPE_CAPACITY_CHANGE shapes"" - - This reverts commit 5f3fb4f4e397735783743fe52a7899b614bece20. - -commit b41270842aae73bf59e17fb1d175a4ff557f0e87 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-10-14 02:31:56 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-11-14 08:03:11 +0900 - - Record more info from CALLCACHE in heap dumps - - This records the called_id and klass from imemo_callcache objects in - heap dumps. - -commit 775ed27d6d361c9c50236497dd4382bbf85068d9 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-14 06:36:21 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-14 07:48:55 +0900 - - [PRISM] Initialize keyword to silence warning - -commit c552a5f7b0d2ace0760499e88ad58e3b7711a267 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-11-14 07:14:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-14 07:14:24 +0900 - - YJIT: shrink `Context` down to 15 bytes (#8911) - - * WIP context refactoring - - * Refactor to remove Context.temp_mapping - -commit e8ab3f7010965e6d632457a316a76c68feee5007 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-14 05:19:25 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-11-14 06:00:10 +0900 - - test: Check file name in test_thread_add_trace_func also - - For better assert failure diagnostics. - -commit bbfd735b887de71de48c7f862e6e3842bcc03241 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-05 22:52:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-13 23:57:15 +0900 - - [rubygems/rubygems] TruffleRuby uses a bash prelude in default launchers - - https://github.com/rubygems/rubygems/commit/e119f4208a - -commit d5c3680a0c29890b85b868afe450d28e392c609e - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-13 14:42:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-13 22:34:24 +0900 - - [ruby/prism] Add tests for error cases on #1791, #1807, and #1810 - - https://github.com/ruby/prism/commit/231e965124 - -commit 90b49024c0d5fe8fe60942b96dcbd1f610042f1b - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-11-13 21:42:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-13 21:42:31 +0900 - - [ruby/reline] Fallback to 256color if COLORTERM != truecolor - (https://github.com/ruby/reline/pull/604) - - * Fallback to 256color if COLORTERM != truecolor - - * Add Reline::Face.force_truecolor to force truecolor without COLORTERM env - - https://github.com/ruby/reline/commit/090e1e4df0 - -commit 8e64c87f64508bf7192d44581632aff6dce15bf6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-08 13:35:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-13 20:33:00 +0900 - - [rubygems/rubygems] Make sure to `require "rubygems"` explicitly - - This is also done in bundler/lib/bundler/rubygems_integration.rb, but - bundler/lib/bundler.rb loads this file before it. - - https://github.com/rubygems/rubygems/commit/8840d8507b - -commit 50a5b76decf21f833da6c838e7acc7f991e47e00 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-11-12 07:18:01 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-11-13 19:17:16 +0900 - - [wasm] allocate Asyncify setjmp buffer in heap - - `rb_jmpbuf_t` type is considerably large due to inline-allocated - Asyncify buffer, and it leads to stack overflow even with small number - of C-method call frames. This commit allocates the Asyncify buffer used - by `rb_wasm_setjmp` in heap to mitigate the issue. - - This patch introduces a new type `rb_vm_tag_jmpbuf_t` to abstract the - representation of a jump buffer, and init/deinit hook points to manage - lifetime of the buffer. These changes are effectively NFC for non-wasm - platforms. - -commit f1b95095d6635567cc5820b3eb40d9618faa73ed - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-11-13 16:13:33 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-13 16:57:57 +0900 - - Revert "Wrap rb_objspace_reachable_objects_from_root with RB_VM_LOCK" - - This reverts commit 76dc327eeffefe02577999fe5f8215f762a581b6. - -commit a1887f4dc2e62455a605944468e59e647f698f1a - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-11-13 16:13:33 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-13 16:57:57 +0900 - - Revert "Fix crash caused by concurrent ObjectSpace.dump_all calls" - - This reverts commit 9a62fd3cbae2ebb60e2f9cad782af1ad18db4319. - -commit 9ca41e999159096cb0872b4babbb94bf5d1af4ce - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-09 21:56:29 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-13 16:45:20 +0900 - - GVL Instrumentation: pass thread->self as part of event data - - Context: https://github.com/ivoanjo/gvl-tracing/pull/4 - - Some hooks may want to collect data on a per thread basis. - Right now the only way to identify the concerned thread is to - use `rb_nativethread_self()` or similar, but even then because - of the thread cache or MaNy, two distinct Ruby threads may report - the same native thread id. - - By passing `thread->self`, hooks can use it as a key to store - the metadata. - - NB: Most hooks are executed outside the GVL, so such data collection - need to use a thread-safe data-structure, and shouldn't use the - reference in other ways from inside the hook. - - They must also either pin that value or handle compaction. - -commit 4376a17552670021a9175bb487be8eb16a2a97e9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-13 16:04:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-13 16:04:49 +0900 - - [DOC] Close a tag - -commit 44a6a13cbe8ead29a5d62f1f3d49343aab946f5e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-13 15:59:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-13 15:59:03 +0900 - - [DOC] Fix Timezone Objects description - - From the beginning when Timezone object support was introduced, - Timezone objects are allowed everywhere offset strings are allowed. - -commit 952de171c01cb1e96245bc0263884dd8655fd644 - Author: Sorah Fukumori <her@sorah.jp> - AuthorDate: 2023-11-13 07:57:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-13 11:28:48 +0900 - - make-snapshot: update RUBY_PATCHLEVEL_STR regexp - - the regexp to replace RUBY_PATCHLEVEL_STR for prerelease snapshots doesn't - match since GH-8578. - - follow-up: https://github.com/ruby/ruby/pull/8578 - follow-up: 68df43788dc237a1071f02b2d82768f844696315 - -commit 5bb756287244923f2817a5989fe9dc78930b4380 - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-11-10 23:14:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Explicitly define `@default_specifications_dir` for tests - - Resetting `@default_specifications_dir` to `nil` means that the - `Gem.default_specifications_dir` needs to be invoked. However, given - that this method might be overridden by operating_system.rb and similar, - this might lead to various test failures. Providing the default value - makes the issues go away. - - https://github.com/rubygems/rubygems/commit/59626cb650 - -commit 28f7a46f446a032762c273fd86f37196908c3b44 - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-11-10 00:34:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Provide more insightful test error output - - Original output: - - ~~~ - Failure: test_realworld_upgraded_default_gem(TestGemRequire): <false> is not true. - /mnt/test/rubygems/test_require.rb:474:in `test_realworld_upgraded_default_gem' - 471: File.write(path, code) - 472: - 473: output = Gem::Util.popen({ "GEM_HOME" => @gemhome }, *ruby_with_rubygems_in_load_path, path).strip - => 474: assert $?.success? - 475: refute_empty output - 476: assert_equal "999.99.9", output.lines[0].chomp - 477: # Make sure only files from the newer json gem are loaded, and no files from the default json gem - ~~~ - - New output: - - ~~~ - Failure: test_realworld_upgraded_default_gem(TestGemRequire) - /mnt/test/rubygems/test_require.rb:475:in `test_realworld_upgraded_default_gem' - 472: - 473: output = Gem::Util.popen({ "GEM_HOME" => @gemhome }, *ruby_with_rubygems_in_load_path, path).strip - 474: refute_empty output - => 475: assert_equal "999.99.9", output.lines[0].chomp - 476: # Make sure only files from the newer json gem are loaded, and no files from the default json gem - 477: assert_equal ["#{@gemhome}/gems/json-999.99.9/lib/json.rb"], output.lines.grep(%r{/gems/json-}).map(&:chomp) - 478: assert $?.success? - <"999.99.9"> expected but was - <"/mnt/tmp/test_rubygems_20231110-36663-of405r/test_realworld_upgraded_default_gem.rb:3:in `<main>': undefined method `version' for nil:NilClass (NoMethodError)"> - - diff: - ? 999 .99.9 - ? /mnt/tmp/test_rubygems_20231110-36663-of405r/test_realworld_upgraded_default_gem rb:3:in `<main>': undefined method `version' for nil:NilClass (NoMethodError) - ? ??? ???? - ~~~ - - It is more valuable to check the command output then the error code. If - the command fails for some reason, the output probably contains some - detail, while checking the return code tells not much. - - https://github.com/rubygems/rubygems/commit/b76062e852 - -commit 5bdbe242b3034f66157d78f933e6e784326b9720 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2022-10-25 22:21:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Add a warning in an edge case of using `gemspec` DSL - - If a Gemfile duplicates a development dependency also defined in a local - gemspec with a different requirement, the requirement in the local - gemspec will be silently ignored. - - This surprised me. - - I think we should either: - - * Make sure both requirements are considered, like it happens for - runtime dependencies (I added a spec to illustrate the current behavior - here). - - * Add a warning that the requirement in the gemspec will be ignored. - - I think the former is slightly preferable, but it may cause some - bundle's that previously resolve to no longer resolver. - - I went with the latter but the more I think about it, the more this - seems like it should behave like the former. - - https://github.com/rubygems/rubygems/commit/ad6843972f - -commit e2d7e53c5c50fed1df733cf66d353fb1dd90d8f0 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-28 03:52:01 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] This can be frozen now - - https://github.com/rubygems/rubygems/commit/d06544add2 - -commit 3757d9027c612c88fdbf449eacf7f8f6c9b2e932 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-28 03:50:20 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Remove now unnecessary dups - - https://github.com/rubygems/rubygems/commit/56ce2a6445 - -commit e6c84d05d0cfb9f20725716b93439746c697ce41 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-28 03:44:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Remove now unnecessary dup - - https://github.com/rubygems/rubygems/commit/3c1a6a7dfa - -commit c7bf511cbffefd826f6a980d4cf046d5d33fd5a1 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-28 03:43:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Add a note about `required_rubygems_version` in Bundler - - https://github.com/rubygems/rubygems/commit/9509d98b5c - -commit a4d80eee179cf4d0b126aa8c61888b7e08795a85 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-27 05:17:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Let RuboCop target Ruby 3.0 - - https://github.com/rubygems/rubygems/commit/70243b1d72 - -commit 50482cd1e5542f210565440bed7586821f774a29 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-27 05:12:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Drop support for Ruby 2.6 and Ruby 2.7 in Bundler - - https://github.com/rubygems/rubygems/commit/93619c97ff - -commit 54511303a46901a82e9b2d4ee460b2048e59a2e5 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-27 05:11:34 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Drop support for Ruby 2.6 and Ruby 2.7 in RubyGems - - https://github.com/rubygems/rubygems/commit/10c26a483d - -commit 435eb56f6175b7c9a16121ec8441f7492fa9aec5 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-17 22:18:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Automatically lock extra ruby platforms - - Since we started locking the specific platform in the lockfile, that has - created an annoying situation for users that don't develop on Linux. - They will create a lockfile on their machines, locking their local - platform, for example, darwin. But then that lockfile won't work - automatically when deploying to Heroku for example, because the lockfile - is frozen and the Linux platform is not included. - - There's the chance though that resolving against two platforms (Linux + - the local platform) won't succeed while resolving for just the current - platform will. So, instead, we check other platform specific variants - available for the resolution we initially found, and lock those - platforms and specs too if they satisfy the resolution. - - This is only done when generating new lockfiles from scratch, existing - lockfiles should keep working as before, and it's only done for "ruby - platforms", i.e., not Java or Windows which have their own complexities, - and so are excluded. - - With this change, we expect that MacOS users can bundle locally and - deploy to Heroku without needing to do anything special. - - https://github.com/rubygems/rubygems/commit/5f24f06bc5 - -commit 59b361aaca0194bd526e32b7053948a49da4e39d - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-20 17:22:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Refactor platform test helpers - - https://github.com/rubygems/rubygems/commit/7ab4c203f9 - -commit f273132bc017ee2d2c10f95f6629717f33ed54f9 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-17 01:23:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Extract builder to create a `LazySpecification` from full spec - - https://github.com/rubygems/rubygems/commit/957d3d9a7f - -commit 58b0a67432f5fd69d169ed4919ec0db6e6680279 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-07 01:58:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Extract a new small platform helper - - https://github.com/rubygems/rubygems/commit/8f7340df8e - -commit bd6aaa78c3f3590c9b24a6a9fe0d8a930580ab37 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2022-07-08 21:20:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Remove unused `SpecSet#merge` - - https://github.com/rubygems/rubygems/commit/53e0490b55 - -commit 196d1bf56e443dc041a322a084b575e7f3b995e1 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2022-02-10 18:05:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Pass source to `LazySpecification` initializer - - https://github.com/rubygems/rubygems/commit/05120e2fe8 - -commit 636b70d2a6cd2cb7dba0087ca9f9fd424eb6250b - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2022-02-10 03:31:49 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Allow setting metadata on LazySpecification - - This is a step forward towards eventually including metadata in the - lockfile. - - https://github.com/rubygems/rubygems/commit/56fc02b251 - -commit ea7cde64fbb02f10a40ce0979f8f8c1151f8f9c9 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2022-02-10 03:21:23 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Set LazySpecification dependencies directly - - https://github.com/rubygems/rubygems/commit/2462c8e04d - -commit 43b8b8875115f1883d7654a663a9238343cb90ab - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-11-09 23:59:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-13 11:06:10 +0900 - - [rubygems/rubygems] Report possible error prior checking output of gem uninstall - - Originally, the failed test case reported following error: - - ~~~ - Failure: test_gem_exec_gem_uninstall(TestGemCommandsExecCommand): - <""> was expected to include - <"Successfully uninstalled a-2\n">. - /mnt/test/rubygems/test_gem_commands_exec_command.rb:742:in `block in test_gem_exec_gem_uninstall' - 739: - 740: # assert_empty @ui.error - 741: refute_includes @ui.output, "running gem exec with" - => 742: assert_includes @ui.output, "Successfully uninstalled a-2\n" - 743: - 744: invoke "--verbose", "gem", "uninstall", "b" - 745: assert_includes @ui.output, "Successfully uninstalled b-2\n" - /mnt/lib/rubygems/user_interaction.rb:46:in `use_ui' - /mnt/lib/rubygems/user_interaction.rb:69:in `use_ui' - /mnt/test/rubygems/test_gem_commands_exec_command.rb:726:in `test_gem_exec_gem_uninstall' - ~~~ - - This does not tell much. Empty string is more often good sign, but not - in this case. However, checking error output first helps with - understanding possible issue: - - ~~~ - Failure: test_gem_exec_gem_uninstall(TestGemCommandsExecCommand): - <"ERROR: While executing gem ... (Gem::FilePermissionError)\n" + - " You don't have write permissions for the /builddir/bin directory.\n" + - "\t/mnt/lib/rubygems/uninstaller.rb:213:in `remove_executables'\n" + - - ... snip ... - - /mnt/test/rubygems/test_gem_commands_exec_command.rb:740:in `block in test_gem_exec_gem_uninstall' - 737: nil - 738: end - 739: - => 740: assert_empty @ui.error - 741: refute_includes @ui.output, "running gem exec with" - 742: assert_includes @ui.output, "Successfully uninstalled a-2\n" - 743: - /mnt/lib/rubygems/user_interaction.rb:46:in `use_ui' - /mnt/lib/rubygems/user_interaction.rb:69:in `use_ui' - /mnt/test/rubygems/test_gem_commands_exec_command.rb:726:in `test_gem_exec_gem_uninstall' - ~~~ - - BTW this issue is caused by operating_system.rb overriding - `Gem.operating_system_defaults` method and explicitly adding `--bindir` - option. - - https://github.com/rubygems/rubygems/commit/d98e36bbe7 - -commit 9a62fd3cbae2ebb60e2f9cad782af1ad18db4319 - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-11-07 20:08:34 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-13 01:50:37 +0900 - - Fix crash caused by concurrent ObjectSpace.dump_all calls - - Since the callback defined in the objspace module might give up the GVL, - we need to make sure the right cr->mfd value is set back after the GVL - is re-obtained. - -commit 76dc327eeffefe02577999fe5f8215f762a581b6 - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-11-07 20:06:33 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-13 01:50:37 +0900 - - Wrap rb_objspace_reachable_objects_from_root with RB_VM_LOCK - - rb_objspace_reachable_objects_from has it too, so I figure it's most - likely required for _from_root as well. - -commit 60e19a0b5fc9c067ee88751192dc56da618f5060 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-12 01:16:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-12 13:51:16 +0900 - - Just check if iteration level is non-zero - - The level in ivar is no longer needed to check if iterating, only used - for increment/decrement. - -commit 9ab64b1d70487055e8b7e02443546f524f1e7c9d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-12 00:34:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-12 13:51:15 +0900 - - Refactor hash iteration level - - - Make it unsigned like as in-flags bits - - Make it long since it should be fixable - - Reduce it to in-flags bits after decrement - -commit 94f82a65f7b0b896c8cd44831c35c18661d0ecf2 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-04 02:36:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-12 11:53:33 +0900 - - [ruby/prism] Add the ability to convert nodes to dot - - https://github.com/ruby/prism/commit/3e4b4fb947 - -commit 2fb1d374393da45f4931cbbc7e573e37ca97e00a - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-12 11:13:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-12 11:34:02 +0900 - - [ruby/prism] Reject invalid rational literals like `1e1r` on lexing - - Fix https://github.com/ruby/prism/pull/1586 - - https://github.com/ruby/prism/commit/b3bde866f2 - -commit e6916f13051ef0eebc223beb09a5f328a608c150 - Author: Marco Roth <marco.roth@intergga.ch> - AuthorDate: 2023-11-04 12:05:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-12 07:01:06 +0900 - - [ruby/prism] Implement JavaScript visitors - - https://github.com/ruby/prism/commit/ea00a1b3c6 - -commit cd91e8e73afa36961674ac55960bb45d53052607 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-11 14:44:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-12 05:37:28 +0900 - - [ruby/prism] Introduce non-associativility to `in` and `=>` - - Fix https://github.com/ruby/prism/pull/1596 - Fix https://github.com/ruby/prism/pull/1771 - Close https://github.com/ruby/prism/pull/1773 - - https://github.com/ruby/prism/commit/a3413e5605 - -commit 64f03460bae489b94684c6b0aa16e5a19e06f836 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-11 18:49:19 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-11 19:26:13 +0900 - - [DOC] Update comment for `DECIMAL_SIZE_OF_BITS` - -commit 9eac9d71786a8dbec520d0541a91149f01adf8ea - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-24 18:33:14 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-11 18:49:19 +0900 - - [Bug #19969] Compact st_table after deleted if possible - -commit 2a442121d1404f9519d83ac72ac24c58a8389b15 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-11 15:44:35 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-11 16:58:14 +0900 - - Stabilize outer variable list - - Sort outer variables by names to make dumped binary data stable. - -commit 1fe2bc4b22dc262e3a84d1f722f556267a0e0172 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-09 20:11:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-11 15:57:44 +0900 - - RCLASS_EXT is never NULL now - -commit 277a3ecbf5c8ba58cea40c50a6d57b2129d22377 - Author: Alan Wu <alanwu@ruby-lang.org> - AuthorDate: 2023-11-11 09:08:13 +0900 - Commit: Alan Wu <alanwu@ruby-lang.org> - CommitDate: 2023-11-11 09:08:13 +0900 - - [DOC] RubyVM::YJIT doc improvements - - * Weaken notice about API stability. A few public APIs in here now. - * Prune out APIs from the docs that are private in nature - * Enable markdown mode and ensure `--` options are quoted so they are - rendered as two dashes in the HTML. - -commit cdaca574ced468e21725703504537d0f5424b8f9 - Author: Alan Wu <alanwu@ruby-lang.org> - AuthorDate: 2023-11-11 09:08:05 +0900 - Commit: Alan Wu <alanwu@ruby-lang.org> - CommitDate: 2023-11-11 09:08:05 +0900 - - [DOC] NEWS.md update about code GC - - See <https://github.com/ruby/ruby/pull/8865> and - 50402db5a7d3bb2a9a93d63a63295b4d85a68088 - -commit f5fa90fe0bf8f606e80a86f02f939003e7aa6834 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-11 05:54:54 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-11 06:55:56 +0900 - - YJIT: Fix `clippy::useless_vec` in a test - -commit 8dfbfa15f6d0d8677cd1b4adb192643a05d02411 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-11 05:47:23 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-11 06:55:56 +0900 - - YJIT: Take cargo --fix for unnecessary calls to into() - -commit 408d5886cf653c1fbf51880095766fd54da737d2 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-11 05:26:02 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-11 06:55:56 +0900 - - YJIT: Auto fix for clippy::unnecessary_cast - -commit 0a93ea4808d0d5c2cd0a757abe664e572036fe80 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-11 05:21:56 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-11 06:55:56 +0900 - - YJIT: Auto fix for clippy::clone_on_copy - -commit 85db7baccb946c6bb463166acdd0fd7b12568d35 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-10 14:09:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-11 06:50:12 +0900 - - [ruby/prism] Remove extra locals added by ... - - https://github.com/ruby/prism/commit/b7850f2d30 - -commit 98e5ea94314340c9be37cc490739fd56c772c16b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-10 14:02:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-11 06:50:11 +0900 - - [ruby/prism] Disallow forwarding in blocks - - https://github.com/ruby/prism/commit/2bbd35943c - -commit 03aa1092adc33e8cdef417ac941f09c7380fc1ee - Author: Mateus Pereira <mateus@ombulabs.com> - AuthorDate: 2023-11-11 02:04:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-11 06:49:27 +0900 - - [ruby/prism] Add source code and changelog uris - - https://github.com/ruby/prism/commit/33a85f7867 - -commit 8044feb7ab75989d5c8bd40131801e80c939e55a - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-11-11 04:27:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-11 04:27:30 +0900 - - [ruby/irb] Bump version to 1.9.0 - (https://github.com/ruby/irb/pull/757) - - https://github.com/ruby/irb/commit/41548b8bd0 - -commit 82ce47415bf95eff0b8de91a61ede3e567a9167d - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-11-11 02:14:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-11 02:15:06 +0900 - - [ruby/open3] [DOC] RDoc for Open3 - (https://github.com/ruby/open3/pull/18) - - https://github.com/ruby/open3/commit/9f3f5d004c - -commit b8eb4bd4ce509cc959695e1bd4890836708d8f29 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-10 01:59:51 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-11 01:51:05 +0900 - - YJIT: Panic with more info when global invalidation patching fails - -commit 38fe710e08db3d93b6225f9c41c18c672e602d7f - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-10 02:57:45 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-11 01:51:05 +0900 - - YJIT: Invoke PosMarker callbacks only with solid positions - - Previously, PosMarker callbacks ran even when the assembler failed to - assemble its contents due to insufficient space. This was problematic - because when Assembler::compile() failed, the callbacks were given - positions that have no valid code, contrary to general expectation. - - For example, we use a PosMarker callback to record VM instruction - boundaries and patch in jumps to exits in case the guest program starts - tracing, however, previously, we could record a location near the end of - the code block, where there is no space to patch in jumps. I suspect - this is the cause of the recent occurrences of rare random failures on - GitHub Actions with the invariants.rs:529 "can rewrite existing code" - message. `--yjit-perf` also uses PosMarker and had a similar issue. - - Buffer the list of callbacks to fire, and only fire them when all code - in the assembler are written out successfully. It's more intuitive this - way. - -commit 5f3fb4f4e397735783743fe52a7899b614bece20 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-11 01:27:49 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-11 01:27:49 +0900 - - Revert "Remove SHAPE_CAPACITY_CHANGE shapes" - - This reverts commit f6910a61122931e4193bcc0fad18d839c319b720. - - We're seeing crashes in the test suite of Shopify's core monolith after - this change. - -commit 3b69637eba307a6e7a2951be0147e4811b77b535 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-10 19:56:40 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-10 23:56:42 +0900 - - Embed Backtrace objects - - rb_backtrace_t is 32B, so it fits well in a 80B slot. - - There is some unused spaces but given Backtrace objects are - rarely held onto it should be inconsequential and avoid - the malloc churn. - - Co-Authored-By: Étienne Barrié <etienne.barrie@gmail.com> - -commit a9f45aac6e2389ff826987771198729441bf6a85 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-10 19:53:50 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-10 23:56:42 +0900 - - rb_data_free: Fix freeing embedded TypedData - - The previous implementation was using the pointer given - by `DATA_PTR` in all cases. But in the case of an embedded - TypedData, that pointer is garbage, we need to use RTYPEDDATA_GET_DATA - to get the proper data pointer. - - Co-Authored-By: Étienne Barrié <etienne.barrie@gmail.com> - -commit a2442e91fded557fe79a49a86b84565ee66e34cc - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-10 18:21:28 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-10 23:56:22 +0900 - - Embed Backtrace::Location objects - - The struct is 16B, so they will use the 80B size pool, so on paper it - wastes 80 - 32 - 16 = 52B, however most malloc implementations will - either pad sizes or use an extra 16B for each segment, so in practice - the waste isn't that big. Also `Backtrace::Location` are rarely held - on for long, so avoiding the malloc churn help performance. - - Co-Authored-By: Étienne Barrié <etienne.barrie@gmail.com> - -commit 068bf59b336e299d42c399f72557e054b714a406 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-11-10 20:27:13 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-11-10 21:30:53 +0900 - - .travis.yml: Run arm64 without allow_failiures. - - Checking the past 10 builds in Travis CI arm64, it looks stable. So, disable - `allow_failures`. - - Also sorted the order of the jobs for the priority. The arm64 is the first. And - I would like to run arm32 using the arm64 pipeline a bit later after the - arm64 using the same arm64 pipeline. So, the arm32 is the last. - -commit cdd6127c823fbda8dd5ff5b1b4243d27db143737 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-10 18:07:01 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-10 19:00:50 +0900 - - [ruby/io-console] bump up to 0.6.1.dev.1 - - https://github.com/ruby/io-console/commit/057ab96a73 - -commit 83064592a6c25f3c89e1c437efd027adf36b913e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-10 17:31:02 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-10 19:00:48 +0900 - - [ruby/io-console] Include FFI version version.rb - - https://github.com/ruby/io-console/commit/b0c688c57e - -commit f08400a07a966fba8d56c496669868f927781aba - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-10 17:21:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-10 19:00:46 +0900 - - [ruby/io-console] Define IO::ConsoleMode::VERSION from gemspec - - https://github.com/ruby/io-console/commit/ebdbebf461 - -commit 5309e3c406b779f488c92bc88c02b751f596f09c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-10 16:45:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-10 19:00:45 +0900 - - [ruby/io-console] Update file list in gemspec - - https://github.com/ruby/io-console/commit/0bfde8372c - -commit c2a8141634d15000c420676cb5045ea78a72c1e1 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-11-08 16:16:58 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-11-08 16:17:43 +0900 - - NEWS entry for M:N thread scheduler. - -commit 7c731b5f7990d452dbda8dd88e401577c24e3153 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-11-08 15:19:16 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-11-08 15:19:16 +0900 - - NEWS entry for new TracePoint event `rescue` - -commit 5398bbcbab702907430ee019d07f5dcf2b0ce4af - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-10 08:29:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-10 08:29:55 +0900 - - Tests of irb is still broken. - - Re-apply "Skip TypeCompletion test in ruby ci" - - This reverts commit 589e2b6782f17d5a1d55021c0395d5d73224e9da. - -commit 589e2b6782f17d5a1d55021c0395d5d73224e9da - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-09 21:45:57 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-10 07:56:07 +0900 - - [ruby/irb] Revert "Skip TypeCompletion test in ruby ci - (https://github.com/ruby/irb/pull/748)" - (https://github.com/ruby/irb/pull/755) - - This reverts commit https://github.com/ruby/irb/commit/d394af0bbce4. - - https://github.com/ruby/irb/commit/a9d0145115 - -commit 293aced09177c1be6d054429010b06f03b882e74 - Author: Juanjo Bazán <jjbazan@gmail.com> - AuthorDate: 2023-11-09 22:31:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-10 07:53:26 +0900 - - Update checkout - -commit c49adfab5d269942c44ebfd83e8c107299fc8015 - Author: Hiroya Fujinami <make.just.on@gmail.com> - AuthorDate: 2023-11-10 01:24:15 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-10 01:24:15 +0900 - - Add "Optimization" section to regexp.rdoc (#8849) - - * Add "Optimization" section to regexp.rdoc - - * Apply the suggestions by @BurdetteLamar - - --------- - - Co-authored-by: Burdette Lamar <BurdetteLamar@Yahoo.com> - -commit ad3db6711c4aa48c82f4091342aab7394ee45736 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-09 23:27:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-09 23:27:55 +0900 - - Update files under .github other than workflows - - While `directory: "/"` is defaulted to ".github/workflows", we need to - update the files under ".github/actions". - -commit f6910a61122931e4193bcc0fad18d839c319b720 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-09 00:19:06 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-09 23:25:02 +0900 - - Remove SHAPE_CAPACITY_CHANGE shapes - - We don't need to create a shape to transition capacity as we can - transition the capacity when the capacity of the SHAPE_IVAR changes. - -commit c4efd170616c3ee82a07fda04f878120f1a97e98 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-11-09 22:15:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-09 22:15:26 +0900 - - [ruby/irb] Add command line option to select which completor to use - (https://github.com/ruby/irb/pull/754) - - * Add command line option to select which completor to use - - * Add test for completor argv - - https://github.com/ruby/irb/commit/1dec2708c9 - -commit ae1fad4cd7d88b464aaebad3d5769d27ba675183 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-09 00:00:32 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-09 21:45:59 +0900 - - [PRISM] Implement compilation for ForwardingArgumentssNode - -commit ea1b1ea1aa98bc9488564ef18aa4032aa1cb5536 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-08 22:05:52 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-09 20:38:10 +0900 - - String#force_encoding don't clear coderange if encoding is unchanged - - Some code out there blind calls `force_encoding` without checking - what the original encoding was, which clears the coderange uselessly. - - If the String is big, it can be a rather costly mistake. - - For instance the `rack-utf8_sanitizer` gem does this on request - bodies. - -commit 0a7e620a36a74c4fc604f9068fb839658678f96c - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-11-08 23:24:21 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-11-09 20:03:02 +0900 - - .travis.yml: Add arm64 case. - - In the past, I saw that the 2nd arm64 pipeline was unstable. Now I want to try - it to check if it is stable enough to run again. - - As far as I know, right now the only native arm64 cases are MacOS Arm - `macos-arm-oss` on GitHub Actions. And I want to add Linux arm64 case on - pull-request in CI. - -commit b013aae0c66fbef0faaab29ceeda18bae4fef608 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-09 18:17:46 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-09 19:45:02 +0900 - - IO#read always check the provided buffer is mutable - - Otherwise you can have work in some circumstance but not in others. - -commit 0f02fbd9ffc0c26fa160505872a6c0d0b0493028 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-09 16:39:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-09 18:21:45 +0900 - - Range check in pm_constant_id_lookup - -commit e824b69a86776a10d3b71b8578d32d8217667c97 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-09 16:29:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-09 18:21:45 +0900 - - Remove useless casts - -commit fae44d652477292ddc66c76111bdaf25f84267fe - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-11-09 16:01:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-09 17:37:20 +0900 - - [ruby/prism] Reset do_loop_stack around a body of a endless method definition - - Fix https://github.com/ruby/prism/pull/1772 - - https://github.com/ruby/prism/commit/cdf58e845e - -commit b73e087dbc91cf47ebff79e5eaa7a8ab2795a5e0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-09 16:37:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-09 16:37:03 +0900 - - [DOC] Fix typos - -commit 195a09cc7ff07f3488835ff9cc374e28f03b487e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-09 16:12:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-09 16:20:00 +0900 - - [ruby/digest] Suppress implicit cast down warnings - - https://github.com/ruby/digest/commit/2f3505bf3f - -commit 7e8d9f49b39b07f5be4505f83517fd2f9c807020 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-09 13:42:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-09 16:01:01 +0900 - - [Bug #18286] Show checksum of builtin_binary.inc for confirmation - -commit 22939382a897af32d9899fafedd5be807b0d555b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-19 20:23:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-09 16:01:01 +0900 - - [Bug #18286] Make builtin binary if sharable in universal binaries - -commit e2ef85b1090d8806f6b68e2fa93d929d02e543b5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-19 18:27:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-09 16:01:01 +0900 - - Finer granularity IBF dependendency - - It depends on only `VALUE` definition. Check for endianness and word - size instead of the platform name. - -commit 61bb5c0572cf8c35fb8f3b3accfb301df13d61da - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-19 18:06:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-09 16:01:01 +0900 - - Use `uint32_t` instead of `unsigned int` for the exact size - -commit 40d40a651ef8d9cd150503fc264b1c922f63fe61 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-09 13:40:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-09 16:01:01 +0900 - - Revert "Disable iseq-dumped builtin module for universal x86_64/arm64 binaries" - - This reverts commit 1d5598fe0d3470e7cab06a756d40a9221fcd501b. - -commit 486b674e2a8437bacb00c48038c04aec420c47a0 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-09 12:56:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-09 14:17:13 +0900 - - Do not allow test-all to load the bundled gems - - This change prevents default gems from inadvertently depending on - bundled gems. This issue was discovered by being able to - `require "rbs"` from test/irb. - -commit 1d5598fe0d3470e7cab06a756d40a9221fcd501b - Author: Ben Hamilton <benhamilton@google.com> - AuthorDate: 2023-02-24 05:31:53 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-11-09 12:24:01 +0900 - - Disable iseq-dumped builtin module for universal x86_64/arm64 binaries - - During the build, Ruby has special logic to serialize its own builtin - module to disk using the binary iseq format during the build (I assume - for speed so it doesn't have to parse builtin every time it starts - up). - - However, since iseq format is architecture-specific, when building on - x86_64 for universal x86_64 + arm64, the serialized builtin module is - written with the x86_64 architecture of the build machine, which fails - this check whenever ruby imports the builtin module on arm64: - - https://github.com/ruby/ruby/blob/1fdaa0666086529b3aae2d509a2e71c4247c3a12/compile.c#L13243 - - Thankfully, there's logic to disable this feature for cross-compiled builds: - - https://github.com/ruby/ruby/blob/1fdaa0666086529b3aae2d509a2e71c4247c3a12/builtin.c#L6 - - This disables the iseq logic for universal builds as well. - - Fixes [Bug #18286] - -commit a168426881480e0f07d75c5f830fb749c3b05249 - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-11-09 00:18:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-09 10:34:48 +0900 - - [rubygems/rubygems] Make the `test_build_extensions` more predictable - - The `test_build_extensions` make assumptions about return value of - `Gem.install_extension_in_lib`. Givent that RubyGems allow to override - this method via `defaults.rb` / `operating_system.rb`, this test might - not always pass. This change makes sure that the - `Gem.install_extension_in_lib` is predictable. - - https://github.com/rubygems/rubygems/commit/e83d0a5da8 - -commit 54547417129b2f3448dddcfba22d3f443f373da4 - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-11-09 00:10:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-09 10:34:48 +0900 - - [rubygems/rubygems] Use `extension_in_lib` helper instead of custom code - - `extension_in_lib` helper improves readibility and it also uses `stub` - on on background instead of custom code. - - https://github.com/rubygems/rubygems/commit/aacc8ac22c - -commit a1d0c048df2a4bd9fd85bd241fbf343f04ee2ae8 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-08 20:37:24 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-09 10:34:48 +0900 - - [rubygems/rubygems] Fix daily Bundler CI - - Daily Bundler CI against ruby-head is failing because ruby-head now - uses bigdecimal 3.1.5, so that gets locked by this spec. - - This change should make the test stable until bigdecimal 99.1.5 is - bundled with Ruby :) - - https://github.com/rubygems/rubygems/commit/830326041f - -commit 28356c2870e1a9606cff998e2b888bd5bd517b37 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-08 21:30:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-09 10:34:48 +0900 - - [rubygems/rubygems] Explicitly pass install-dir when installing system gems in Bundler specs - - We want to avoid any "user home" fallbacks, since that won't work with - Bundler. - - So if there's a permissions issue during specs, it's best to raise - immediately. - - https://github.com/rubygems/rubygems/commit/767a3e7533 - -commit f67a80cdc098783aae9ce84d9e141d2280978a49 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-08 20:31:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-09 10:34:48 +0900 - - [rubygems/rubygems] No need to let this command fail - - This command is not expected to fail. If it fails, we can stop the test. - - https://github.com/rubygems/rubygems/commit/2511a5b093 - -commit d9ac2d91e051201657e58f7860234fc09f4dfc48 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-11-08 20:30:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-09 10:34:48 +0900 - - [rubygems/rubygems] Remove unused logic - - https://github.com/rubygems/rubygems/commit/2eb2860e9e - -commit 5c8d2c2d4594a630187702f96e4de75aa5a31fa8 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-09 07:05:51 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-09 10:28:58 +0900 - - [PRISM] Always lookup idERROR_INFO consistently. - - We know where it is in the iseq local table, because we forced it using - `iseq_set_exception_local_table` when compiling the BEGIN_NODE, so we - can always look it up from the same place. - - Co-Authored-By Peter Zhu <peter@peterzhu.ca> - -commit 201853f4e1ae87eedb5cd255a80b088a7a40c59e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-05 14:10:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-09 07:17:43 +0900 - - [ruby/prism] Provide Parameters#signature for mirroring Method#parameters - - https://github.com/ruby/prism/commit/90b3245528 - -commit f9e34a1fd3387822903ff7a63405bf116e0c9803 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-09 02:49:58 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-09 06:15:47 +0900 - - [PRISM] Add tests for OptionalKeywordParameterNode - - This commit adds tests for the compilation of the - OptionalKeywordParameterNode, and fixes cases on the - RequiredKeywordParameterNode - -commit 70e4ff9feb9e5f7254f9dbe955dedbf56e73c8d5 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-08 07:28:21 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-09 06:15:47 +0900 - - [PRISM] Added tests for ForwardingParameterNode, KeywordRestParameterNode - -commit 26cff6ae2b7fe2259f942d1cf411c5af891b1de9 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-08 03:39:11 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-09 06:15:47 +0900 - - [PRISM] Add tests for several parameters nodes - - This commit adds tests for BlockParameterNode, RequiredParameterNode, - RequiredKeywordParameterNode and RestParameterNode - -commit 8d0eb872e8fd0cc1837318c4c242f4085df9812e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-09 03:29:10 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-09 03:29:10 +0900 - - Add foo.gemspec for failing test - - foo.gemspec was added in - rubygems/rubygems@8d699ed096960ed9a6636bd27143952ff5f8addc but was not - sync'd in commit b4bf8c9ee2d716adf5fc08e67c4b26d6a8f929c2. This causes - the spec to fail. - -commit ddd99a529005eade4e99735e7aba8166f4a32ca2 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-11-09 01:35:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-09 01:47:29 +0900 - - [ruby/tempfile] Make Tempfile#open return the underlying File - - Add test for this behavior. - - https://github.com/ruby/tempfile/commit/0ca31a6b8d - -commit eb2abc3f16685979ea87861900fb33b3a975589e - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-11-09 00:37:19 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-09 00:37:19 +0900 - - YJIT: refactor format_number (#8869) - - Replace enumerators with simpler and faster version that only inserts commas before '.' or end of integer string. - -commit 50402db5a7d3bb2a9a93d63a63295b4d85a68088 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-09 00:21:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-09 00:21:04 +0900 - - YJIT: Disable code GC (#8865) - - Co-authored-by: Alan Wu <alansi.xingwu@shopify.com> - Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - -commit ddcfc9feabf22ed6cc1071e65948a1d512a906fe - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-11-09 00:19:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-09 00:19:52 +0900 - - [ruby/tempfile] Fix Tempfile#{dup,clone} - - Instead of storing the delegate in @tmpfile, use __getobj__, since - delegate library already handles dup/clone for that. Copy the - unlinked, mode, and opts instance variables to the returned object - when using dup/clone. - - Split the close/unlink finalizer into two finalizers. The close - finalizer always closes when any Tempfile instance is GCed, since - each Tempfile instance uses a separate file descriptor. The unlink - finalizer unlinks only when the original and all duped/cloned - Tempfiles are GCed, since all share the same path. - - For Tempfile#open, undefine the close finalizer after closing the - current file, the redefine the close finalizer with the new file. - - Fixes [Bug #19441] - - https://github.com/ruby/tempfile/commit/dafabf9c7b - -commit d80009d1693fe3288be265ecc53ade362d89de59 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-11-08 23:26:27 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-08 23:26:27 +0900 - - [DOC] RDoc for module Process (#8847) - -commit f694bd158c4aaffbbb9e4b2f0608c6d428a4999c - Author: Adam Hess <HParker@github.com> - AuthorDate: 2023-11-07 15:46:42 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-08 22:05:58 +0900 - - Improve error and memory handling - - Apply Nobu's suggestions which improve style, memory handling and error correction. - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit 05cde4155cd43a79733ab4996db2d8b1f64c4fb5 - Author: Adam Hess <adamhess1991@gmail.com> - AuthorDate: 2023-11-01 16:01:55 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-08 22:05:58 +0900 - - fix regex from regex memory corruption - - before this change, creating a regex from a regex with a named capture, Regexp.new(/(?<name>)/), causes memory to be shared between the two named capture groups which can cause a segfault if the original is GCed. - -commit b4bf8c9ee2d716adf5fc08e67c4b26d6a8f929c2 - Author: Han Young <hanyang.tony@bytedance.com> - AuthorDate: 2023-11-01 12:58:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-08 21:40:22 +0900 - - [rubygems/rubygems] Ensure we are using the same extension dir - - Since #6945 the extension dir changed to Gem::BasicSpecification's implementation, we didn't hook that in rubygems_ext.rb. So for universal rubies, we ended up using the universal platform name when installing, but arch replaced platform name when checking. This lead to native extensions can never be correctly installed on universal rubies. - - Hook Gem::BasicSpecifications so the behavior is consistent on installing and checking. - - https://github.com/rubygems/rubygems/commit/8d699ed096 - -commit 7efe0669ae6194962dbd2abad359a761cee3f552 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-08 16:56:32 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-08 19:33:01 +0900 - - TypedData_Make_Struct0: cast RTYPEDDATA_GET_DATA return pointer - - Fixes: - - ``` - /usr/local/ruby/include/ruby-3.3.0+0/ruby/internal/core/rtypeddata.h:467:33: - error: invalid conversion from ‘void*’ to ‘parser_t*’ [-fpermissive] - 467 | (sval) = RTYPEDDATA_GET_DATA(result); \ - | ~~~~~~~~~~~~~~~~~~~^~~~~~~~ - | | - | void* - ``` - -commit d898e8d6f89fba34a9ee5c0e139f38ac807059e6 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-08 02:09:55 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-08 19:02:55 +0900 - - Refactor rb_shape_transition_shape_capa out - - Right now the `rb_shape_get_next` shape caller need to - first check if there is capacity left, and if not call - `rb_shape_transition_shape_capa` before it can call `rb_shape_get_next`. - - And on each of these it needs to checks if we got a TOO_COMPLEX - back. - - All this logic is duplicated in the interpreter, YJIT and RJIT. - - Instead we can have `rb_shape_get_next` do the capacity transition - when needed. The caller can compare the old and new shapes capacity - to know if resizing is needed. It also can check for TOO_COMPLEX - only once. - -commit 8cd6c65af13ce1ce5ec1b9bd7b8a12cfff52364b - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-11-08 16:03:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-08 16:04:15 +0900 - - [ruby/stringio] Development of 3.1.0 started. - - https://github.com/ruby/stringio/commit/a2f8ef1a6a - -commit 8da33bff8c871508b03776580e46bc90c722bd57 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-11-08 15:42:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-08 15:42:10 +0900 - - [ruby/irb] Skip TypeCompletion test in ruby ci - (https://github.com/ruby/irb/pull/748) - - https://github.com/ruby/irb/commit/d394af0bbc - -commit 7f565b923a62638e76b053f996e7149ec035b63d - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-08 15:39:19 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-08 15:39:19 +0900 - - Prevent a warning: assigned but unused variable - raised_exception - -commit 4da633361532663db344ead243a3a4fb4f82d2de - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-08 13:02:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-08 13:02:55 +0900 - - Export functions used for builtins - -commit e34401046566ad1938b1eec654a6bf69b1319102 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-11-08 11:46:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-08 11:46:33 +0900 - - [ruby/irb] Type based completion using Prism and RBS - (https://github.com/ruby/irb/pull/708) - - * Add completor using prism and rbs - - * Add TypeCompletion test - - * Switchable completors: RegexpCompletor and TypeCompletion::Completor - - * Add completion info to irb_info - - * Complete reserved words - - * Fix [*] (*) {**} and prism's change of KeywordParameterNode - - * Fix require, frozen_string_literal - - * Drop prism<=0.16.0 support - - * Add Completor.last_completion_error for debug report - - * Retrieve `self` and `Module.nesting` in more safe way - - * Support BasicObject - - * Handle lvar and ivar get exception correctly - - * Skip ivar reference test of non-self object in ruby < 3.2 - - * BaseScope to RootScope, move method objects constant under Methods - - * Remove unused Splat struct - - * Drop deeply nested array/hash type calculation from actual object. Now, calculation depth is 1 - - * Refactor loading rbs in test, change preload_in_thread not to cache Thread object - - * Use new option added in prism 0.17.1 to parse code with localvars - - * Add Prism version check and warn when :type completor cannot be enabled - - * build_type_completor should skip truffleruby (because endless method definition is not supported) - - https://github.com/ruby/irb/commit/1048c7ed7a - -commit 7ed37388fb9c0e85325b4e3db2ffbfca3f4179ad - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-11-08 09:46:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-08 09:46:17 +0900 - - [ruby/stringio] Add missing row separator encoding conversion - (https://github.com/ruby/stringio/pull/69) - - The conversion logic is borrowed from ruby/ruby's io.c: - https://github.com/ruby/ruby/blob/40391faeab608665da87a05c686c074f91a5a206/io.c#L4059-L4079 - - Fix ruby/stringio#68 - - Reported by IWAMOTO Kouichi. Thanks!!! - - https://github.com/ruby/stringio/commit/4b170c1a68 - -commit ce8301084f661f8a22b36bc6f7207bf40e8bf61d - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-10-11 09:40:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:26:58 +0900 - - [ruby/strscan] Bump version - - https://github.com/ruby/strscan/commit/1b3393be05 - -commit 9c2e0d49fe64d398edb9b95e642eb6a3dfc2a4c1 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-10-30 14:57:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:25:45 +0900 - - [ruby/fiddle] Remove garbage - - https://github.com/ruby/fiddle/commit/bbcb66e16e - -commit c19ea1066a22b8ef3b44050d42a47a8413d97692 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-10-30 14:48:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:25:45 +0900 - - [ruby/fiddle] Include stdbool.h explicitly for old Ruby - - https://github.com/ruby/fiddle/commit/74a05fb358 - -commit 2a6d6d3d65de43635a5f6ad38dbca170f1e40119 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-10-28 06:11:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:25:44 +0900 - - [ruby/fiddle] Use Ruby's true/false for C bool - - GitHub: fix https://github.com/ruby/fiddle/pull/130 - - Reported by Benoit Daloze. Thanks!!! - - https://github.com/ruby/fiddle/commit/2640e0148e - -commit d30ea5831e0aedada3362a2d268e7bc836b93f27 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-27 00:27:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:25:34 +0900 - - CI: Change the openssl_fips.cnf.tmpl and openssl_fips.cnf directories. - -commit c8d4b103a924aca45c6170a5f6122eec3084641a - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-10-21 20:56:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:17:23 +0900 - - [ruby/irb] Fix dancing-ruby Ctrl+C stop - (https://github.com/ruby/irb/pull/735) - - https://github.com/ruby/irb/commit/802b1cb6d8 - -commit d8e0337d02476f53bd4e33ffa014c7bf41e8ab15 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-23 01:42:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - Escape the target string to be checked - - Comparing file paths as strings may not work well for some reasons, - symlink, relative `__FILE__`, etc. - - Some alternatives are possible: comparing with `File.realpath`, or - with `File.identical?`, it should be most robust to escape the target - string contained within this file itself. - -commit e6e4b4884d42a228aa342758318e1621c2552b62 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2022-12-30 21:34:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Hack to get `Gem::Specification#extensions_dir` documented - - https://github.com/rubygems/rubygems/commit/625b8293f7 - -commit 9afd2957edca3f2d72476f1a187ef34ec99b5110 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-27 03:54:17 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Simplify spec wording and implementation - - https://github.com/rubygems/rubygems/commit/3e7f1379fb - -commit 9f67118d7bc790ee5c3449e28f76e428958bc5cb - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-27 03:50:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Simplify selecting specs with `force_ruby_platform` set - - https://github.com/rubygems/rubygems/commit/5f90a43635 - - Co-authored-by: Martin Emde <martin.emde@gmail.com> - -commit a131ea39b7b9c34304dfbf8112581c49ce9ff827 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-03 21:37:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Better error when having an insecure install folder - - https://github.com/rubygems/rubygems/commit/e41156e272 - -commit 05ea3bcf14f27e1b3c6d7dd97889d02f988b8920 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-03 20:03:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Remove redundant error class - - It's a `BundlerError`. - - https://github.com/rubygems/rubygems/commit/53ea676dab - -commit 5b076e00ce138ab4a81f0951dc23b82f015f011e - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-27 03:16:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Fix regression on old git versions - - https://github.com/rubygems/rubygems/commit/abd91ca2e5 - -commit 7f7a7f13ededda5c91d84c3493dc6ef3cec53d1a - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-27 01:44:20 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Don't show bug report template when GEM_HOME has no writable bit - - Instead, don't check that at all and proceed. If something fails to be - written inside GEM_HOME, we'll eventually fail with a proper permissions - error. - - In addition to that, the writable bit in GEM_HOME is not even reliable, - because only the immediate parent is actually checked when writing. For - example, - - ``` - $ mkdir -p foo/bar - $ chmod -w foo - $ touch foo/bar/baz # writes without issue - ``` - - https://github.com/rubygems/rubygems/commit/4bced7ac73 - -commit 2d719cd1468334a3507e4194a173da743b9987d1 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-26 04:30:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Remove unnecessary rescue - - https://github.com/rubygems/rubygems/commit/c0b549f943 - -commit ca7444cc44b1e939a31aa4366727b1ad09faa626 - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-10-24 00:12:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Allow `--install-dir` to be specified together with `--user-install` - - The combination of `install-dir` and `--user-install` used to be - disabled for no good reason. This even makes problem on Linux - distributions such as Fedora, where `--user-install` is set by default - via operating_system.rb. - - The `--install-dir` is already prefered over the `--user-install` by - the implementation, therefore just drop the check. - - https://github.com/rubygems/rubygems/commit/313b1c5e76 - -commit bd5368fdec1109b3bf3dfa635f6ab1d60cfc5ddc - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-10-23 23:19:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Don't use `util_installer` for user install - - It is not nice to require install directory to be always specified, - while this option is later ignored for user installed gems. - - Actually, the next step will be to remove `check_install_dir` check and - let the install dir override the user install. - - https://github.com/rubygems/rubygems/commit/beb79e929f - -commit d0ad90df6863490a5f780c45e060ab859db228ba - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-10-24 00:13:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Check for `:install_dir` precedence over `:user_install` - - https://github.com/rubygems/rubygems/commit/6539da07aa - -commit 42cf1307c3e110f5d01b74f16cbdd0f83e183abe - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2023-10-21 01:01:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Make the user installation less exceptional - - The main purpose is to put handling of user installation into the same - place as e.g. handling the --build-root option handling. There is no - reason why the --build-root option should not prefix also paths used for - user installation. - - Please note that the `util_installer` in - `test_generate_plugins_with_user_install` enforced the `:install_dir`, - which is against what user install is about. - - https://github.com/rubygems/rubygems/commit/0b10cb41aa - -commit acd428c823ea70faa12edf09af303b4f843d3691 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-10-01 08:18:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Remove kludge that should be unnecessary. - - https://github.com/rubygems/rubygems/commit/f1d44ecb62 - -commit 55840d0a331d0920cfecae44de7147ada7dff254 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-09-29 12:15:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [rubygems/rubygems] Allow test_gem_install_update_options to raise Errno::ACCES, in addition to Gem::FilePermissionError. - - https://github.com/rubygems/rubygems/commit/784fe2a814 - -commit d12e881009ba94e2aca6428756fc79cc33ba278b - Author: BurdetteLamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2021-09-22 02:38:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-08 09:04:28 +0900 - - [flori/json] Enhanced RDoc for Range extensions - - https://github.com/flori/json/commit/ec47749b53 - -commit 7367336c4e5691a15f95fb676d1b857407ade786 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-08 07:46:24 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-08 08:50:10 +0900 - - YJIT: Fix assert in OOM scenario - - We still need to do `jit.record_boundary_patch_point = false` - when gen_outlined_exit() returns `None` and we return with `?`. - Previously, we tripped the assert at codegen.rs:1042. - - Found with `--yjit-exec-mem-size=3` on the lobsters benchmark. - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - -commit a1c61f0ae5f5ecaa7d8289942b78e6b0c77118fe - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-10-17 07:35:26 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-08 07:43:43 +0900 - - YJIT: Use u32 for CodePtr to save 4 bytes each - - We've long had a size restriction on the code memory region such that a - u32 could refer to everything. This commit capitalizes on this - restriction by shrinking the size of `CodePtr` to be 4 bytes from 8. - - To derive a full raw pointer from a `CodePtr`, one needs a base pointer. - Both `CodeBlock` and `VirtualMemory` can be used for this purpose. The - base pointer is readily available everywhere, except for in the case of - the `jit_return` "branch". Generalize lea_label() to lea_jump_target() - in the IR to delay deriving the `jit_return` address until `compile()`, - when the base pointer is available. - - On railsbench, this yields roughly a 1% reduction to `yjit_alloc_size` - (58,397,765 to 57,742,248). - -commit aa6642de630cfc10063154d84e45a7bff30e9103 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-08 03:22:48 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-08 05:48:06 +0900 - - Use embedded TypedData for Time objects - - This drops the total size of a Time object from 86 bytes to 80 bytes. - - Running the benchmark benchmark/time_now.yml, this commit improves - performance of Time.now by about 30%: - - ``` - Time.now - Branch: 13159405.4 i/s - Master: 10036908.7 i/s - 1.31x slower - - Time.now(in: "+09:00") - Branch: 2712172.6 i/s - Master: 2138637.9 i/s - 1.27x slower - ``` - - It also decreases memory usage by about 20%: - - ``` - ary = 10_000_000.times.map { Time.now } - - puts `ps -o rss= -p #{$$}` - ``` - - Branch: 961792 - Master: 1196544 - - Co-Authored-By: Jean Boussier <byroot@ruby-lang.org> - -commit 392238e3fd76beb923de1ba3f8d8d6bd28c7030e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-04 06:05:01 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-08 05:48:06 +0900 - - Implement embedded TypedData objects - - This commit adds a new flag RUBY_TYPED_EMBEDDABLE that allows the data - of a TypedData object to be embedded after the object itself. This will - improve cache locality and allow us to save the 8 byte data pointer. - - Co-Authored-By: Jean Boussier <byroot@ruby-lang.org> - -commit bc07b0b9e1d55821acaa0effea67a9885a3bb56d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-07 22:10:23 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-08 03:15:16 +0900 - - [PRISM] Implement compilation for different parameters - - This commit compiles most parameter types, setting appropriate values on - the ISEQ_BODY. It also adds tests for callers and callees of methods, - using many versions of tests from bootstraptest - -commit d9d09381169dabc3ff954b7f307fbb06f9d928f5 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-11-08 02:46:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-08 02:46:07 +0900 - - YJIT: update yjit.md, add MPLR 2023 paper and bibtex (#8861) - - * YJIT: update yjit.md, add MPLR 2023 paper and bibtex - - * Update doc/yjit/yjit.md - -commit 1910bd42477f928b539f09c7ba2ac444bd368fd4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-07 23:26:14 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-08 00:59:45 +0900 - - String for string literal is not resizable - -commit 9877f3ada8019f559dc0f86911ef4bbddddb5677 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-08 00:54:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-08 00:54:33 +0900 - - YJIT: Inline basic Ruby methods (#8855) - - * YJIT: Inline basic Ruby methods - - * YJIT: Fix "InsnOut operand made it past register allocation" - - checktype should not generate a useless instruction. - -commit a294bb844c697799d8ba766aa2e5ba5449d05448 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2023-11-08 00:49:36 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-08 00:49:36 +0900 - - YJIT: handle out of shape situation in gen_setinstancevariable (#8857) - - If the VM ran out of shape, `rb_shape_transition_shape_capa` might - return `OBJ_TOO_COMPLEX_SHAPE`. - - Co-authored-by: Jean Boussier <byroot@ruby-lang.org> - -commit e8ef010a8106785797f9a863df2e3af890157a1a - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-11-08 00:38:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-08 00:38:53 +0900 - - [ruby/reline] Bump version to 0.4.0 - (https://github.com/ruby/reline/pull/601) - - https://github.com/ruby/reline/commit/d15ab72d4f - -commit 1cfc853be63d7945acc485f98a399b28f318e10d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-05 20:08:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-07 23:19:51 +0900 - - Suppress nonnull warning from gcc 13 - -commit 8becc889dbbacbc774c069f9e3da94f41b81efc2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-30 21:21:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-07 23:19:51 +0900 - - Suppress array-bounds warnings from gcc 13 - -commit f2d6b41c8ebcd49debbc6902a9556324dff6c0f8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-06 23:29:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-07 23:19:51 +0900 - - Ignore warnings about currently unsupported .debug_macinfo - -commit 6031fdc6322231f22a03657092e7d55ab03b0606 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-30 21:20:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-07 23:19:51 +0900 - - Select proper dsymutil for gcc 13 - -commit f8456b650bae8eef94acd80cb255a730177fe1ed - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-30 21:19:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-07 23:19:50 +0900 - - Ignore duplicate libraries warnings from gcc 13 - -commit e7bdd9e498306a64c5785bdb642d192e1f513c84 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-07 07:14:50 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-11-07 23:03:57 +0900 - - [PRISM] Move Local table setup into EnsureNode compilation - -commit b7d5a63b9a0f762ef15572c14b40a784a5c27c35 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-07 06:32:02 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-11-07 23:03:57 +0900 - - [PRISM] Don't generate leave insns for Ensure nodes - -commit 8ef7f273218ea0bbbdb1d32e34459cfbf342df97 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-03 08:29:20 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-11-07 23:03:57 +0900 - - [PRISM] CompileEnsureNode - -commit 237b85c25603a7bccc2bd13dc8da561ca687cc9d - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-02 07:26:40 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-11-07 23:03:57 +0900 - - [PRISM] PM_COMPILE into a specified LINK_ANCHOR - -commit ced84beb2518d173988bb92c6d96aa854a35abe6 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2022-08-16 19:43:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 19:22:30 +0900 - - [ruby/cgi] Add snake case aliases for escapeURIComponent - - As agreed in [Feature #18822] - - https://github.com/ruby/cgi/commit/9d1161ec9d - -commit f8ffe907f0ee7a4f60aeb165812c4045b5fddca4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 18:11:05 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-07 18:11:22 +0900 - - Added racc to warning targets of bundled gems - -commit 3d5fef77125a99458767c80347c01f383737efe7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 17:50:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 17:50:40 +0900 - - [ruby/zlib] Bump up 3.1.0 - - https://github.com/ruby/zlib/commit/2561e122ac - -commit 79544157e44ccf833205fcdce0b0f1bd9796dd65 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 17:38:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 17:47:03 +0900 - - [ruby/zlib] Support Ruby 2.5+ again - - https://github.com/ruby/zlib/commit/661ea3ec5f - -commit 123b2e2fb493618260dffca0dedbf685762ef6a3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 17:23:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 17:29:31 +0900 - - [ruby/cgi] Bump up 0.4.0 - - https://github.com/ruby/cgi/commit/6ddd5fc7d7 - -commit fbb63605c4dc9d0dbff3ba819bc78dae6193512b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 16:54:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 16:55:13 +0900 - - [ruby/pathname] Bump up 0.3.0 - - https://github.com/ruby/pathname/commit/f3d23679b0 - -commit b13d00a7c0e9795b4bdeaeffe2b7c25d6c61d95b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 16:35:01 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-07 16:37:06 +0900 - - [ruby/open-uri] Bump up 0.4.0 - - https://github.com/ruby/open-uri/commit/09df813305 - -commit 31dfebccbf758d27f7c72223434ffc92a7423fb9 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 16:31:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 16:32:00 +0900 - - [ruby/English] Bump up 0.8.0 - - https://github.com/ruby/English/commit/826ff728cf - -commit 78e07e29836cc9af74865f4f7234a22a6f6e752e - Author: Keith R. Bennett <keithrbennett@gmail.com> - AuthorDate: 2023-02-11 16:43:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 16:24:50 +0900 - - [ruby/English] Combine duplicate aliases into single sections to more clearly denote sameness and make more concise. - - https://github.com/ruby/English/commit/dcff090f6f - -commit 9857499d3dc4a1777f66951e88a2699698269fce - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 16:15:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 16:15:34 +0900 - - [ruby/fileutils] Bump up 1.7.2 - - https://github.com/ruby/fileutils/commit/577fd38f15 - -commit 3ac15f7e5791fb0f9307312f002286bd24a99a67 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 16:01:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 16:01:35 +0900 - - [ruby/base64] Bump up 0.2.0 - - https://github.com/ruby/base64/commit/09e839e5ad - -commit 48d8f62cddd5fec88c9b37906326a1ea33bc74b4 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-11-07 15:59:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 15:59:52 +0900 - - [ruby/base64] Enhanced Rdoc for Base64 - (https://github.com/ruby/base64/pull/7) - - * Enhanced Rdoc for Base64 - - * Enhanced RDoc for Base64 - - https://github.com/ruby/base64/commit/155c39a949 - -commit d63c29ceca1652e6c73b282a48a42daa23c28ec7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 15:55:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 15:55:45 +0900 - - [ruby/fcntl] Bump up 1.1.0 - - https://github.com/ruby/fcntl/commit/fe780abe07 - -commit 84b2a6ad5d8706c3719eccd982d6387c735413a0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 18:40:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-07 15:37:45 +0900 - - [ruby/drb] Removed old version on doc section - - https://github.com/ruby/drb/commit/104f1a4db3 - -commit ef3feae8e7231d8d3fca945b308ea68c39b385eb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 18:38:58 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-07 15:36:55 +0900 - - [ruby/drb] Load DRb::VERSION automatically - - https://github.com/ruby/drb/commit/b250502c43 - -commit 8d56260910e88c50beeaae6b92ca21f0fa86f839 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-22 05:12:22 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-07 15:35:37 +0900 - - [ruby/logger] [DOC] Fix broken link - - https://github.com/ruby/logger/commit/8c135bce9a - -commit 77f90867687725578e25c28ec15580912c4ba93b - Author: John Bachir <j@jjb.cc> - AuthorDate: 2023-07-09 15:03:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-07 15:29:58 +0900 - - [ruby/timeout] tests for blank seconds - - https://github.com/ruby/timeout/commit/54bc7639d2 - -commit 01d86818ff56720f479ceabc38c36e78a3f93e36 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 15:16:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 15:16:31 +0900 - - [ruby/ostruct] Bump up 0.6.0 - - https://github.com/ruby/ostruct/commit/0985296e72 - -commit eaf0ca4cfe7d7b53c3812b593a5e49db5dff9c74 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 14:52:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 14:52:50 +0900 - - [ruby/win32ole] Bump up 1.8.10 - - https://github.com/ruby/win32ole/commit/9a18f388a9 - -commit 65e1f918d9bc549045906bc16855f15d6bb242c6 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 14:37:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 14:40:13 +0900 - - [ruby/drb] Bump up 2.2.0 - - https://github.com/ruby/drb/commit/c62076f940 - -commit e584a619e13c93ae64e1af1d885c87c809f81635 - Author: Tim Kretschmer <krtschmr@users.noreply.github.com> - AuthorDate: 2023-11-01 11:34:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 14:35:18 +0900 - - [ruby/bigdecimal] fixed docs for .scale - - the scale of `1` is actually 0 - - https://github.com/ruby/bigdecimal/commit/9a8bc9c417 - -commit f0abe610a3a4d6d334402951d3abfa0185b958ef - Author: Koichi ITO <koic.ito@gmail.com> - AuthorDate: 2023-11-06 22:31:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 14:32:49 +0900 - - [ruby/bigdecimal] Update doc for bigdecimal/util - - Follow up https://github.com/ruby/bigdecimal/issues/89. - - `BigDecimal.new` has already been removed. This PR replaces `BigDecimal.new` with - `Kernel.BigDecimal` in the documentation, following the message below: - - > BigDecimal.new is deprecated; use Kernel.BigDecimal method instead. - - https://github.com/ruby/bigdecimal/commit/26d84ba766e971da8eaaf2ce41e7b89935fa68da - - https://github.com/ruby/bigdecimal/commit/dd52adf3b2 - -commit 7d2d0f054f6fcbf04f20baec261cdde10be8aa19 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 14:17:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 14:17:52 +0900 - - [ruby/logger] Bump up 1.6.0 - - https://github.com/ruby/logger/commit/0996f90650 - -commit 360607c7f1bb1cd75a882d4cbf63665d27a65044 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 14:09:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 14:09:48 +0900 - - [ruby/time] Bump up 0.3.0 - - https://github.com/ruby/time/commit/8dba14997c - -commit acf0f8551e6acc4f14143433e798c5cfb9087144 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 13:44:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 13:56:40 +0900 - - [ruby/timeout] Bump up 0.4.1 - - https://github.com/ruby/timeout/commit/a65e49cc31 - -commit f26e89c4a76b628d36b8389a4c9462de97cf4f12 - Author: John Bachir <j@jjb.cc> - AuthorDate: 2023-07-05 04:45:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 13:45:29 +0900 - - [ruby/timeout] nested exception tests for discussion - - https://github.com/ruby/timeout/commit/3e42aa4d84 - -commit 027f0a4564e64f888ab9d2c1e5546aae4003acee - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 13:08:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-07 13:37:17 +0900 - - [ruby/delegate] Bump up 0.3.1 - - https://github.com/ruby/delegate/commit/d4bdf89328 - -commit c3a11f1cfc9b5da62a45246e40aaac4bb8c42e83 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 13:20:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-07 13:21:23 +0900 - - [ruby/securerandom] Bump up 0.3.0 - - https://github.com/ruby/securerandom/commit/12c4ef3ea1 - -commit da2cf947bc9580a8d188ccfeae5588f89a140fd4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 13:15:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 13:16:02 +0900 - - [ruby/date] Bump up 3.3.4 - - https://github.com/ruby/date/commit/50e18d2684 - -commit eb4dd7001fd1e5a6e39a9a215c4c4fde96d5f771 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 13:06:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 13:06:59 +0900 - - [ruby/net-protocol] Bump up 0.2.2 - - https://github.com/ruby/net-protocol/commit/2d3c4b43a8 - -commit 0c55886fc2aad1688dbbb116803f36789f4cde9c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 11:53:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-07 12:54:09 +0900 - - [ruby/tempfile] Bump up 0.2.0 - - https://github.com/ruby/tempfile/commit/d6ddf7881e - -commit b94c407f69173d9e9422e655ed96dcc51c296adb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 12:44:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-07 12:53:16 +0900 - - [ruby/find] Bump up 0.2.0 - - https://github.com/ruby/find/commit/192237e766 - -commit b4901d54a5f89525de98a8775d4233c874a7d91e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 12:46:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 12:47:15 +0900 - - [ruby/getoptlong] Bump up 0.2.1 - - https://github.com/ruby/getoptlong/commit/f49629dfaa - -commit bf330853404b38c857d6c08bbc23f4483df93a51 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 12:42:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 12:42:58 +0900 - - [ruby/observer] Bump up 0.1.2 - - https://github.com/ruby/observer/commit/6c978e6196 - -commit 308d7943666f7aea7926809ee8dc071eeca35fae - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 12:10:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 12:10:45 +0900 - - [ruby/pstore] Bump up 0.1.3 - - https://github.com/ruby/pstore/commit/6d5c0833e7 - -commit eeaa2cdba2913096b14d4319804fafb715671867 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 11:52:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 11:52:46 +0900 - - [ruby/mutex_m] Bump up 0.2.0 - - https://github.com/ruby/mutex_m/commit/635da25a09 - -commit ad81af22d4a1a24c3a63a960d558d0131ee2a3d6 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 11:06:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-07 11:39:02 +0900 - - [ruby/tmpdir] Bump up 0.2.0 - - https://github.com/ruby/tmpdir/commit/8bbd87c8ac - -commit f32c5e1c94682537f38f29889da454454a7a8a44 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 11:31:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 11:32:01 +0900 - - [ruby/open3] Bump up 0.2.0 - - https://github.com/ruby/open3/commit/0db9a0afe7 - -commit 1fdb8ef15623f78a6319c698b166c8d3c3612f86 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 11:26:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 11:27:08 +0900 - - [ruby/rinda] Bump up 0.2.0 - - https://github.com/ruby/rinda/commit/f6d76b3927 - -commit d9f1211a2f2dbb37441f12c6bcdfa5838b454b68 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 10:59:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 10:59:17 +0900 - - [ruby/tsort] Bump up 0.2.0 - - https://github.com/ruby/tsort/commit/2b3fe78646 - -commit c9ee600cef88751aeda89e90fc25ac2e3199f3c9 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 10:46:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 10:46:40 +0900 - - [ruby/weakref] Bump up 0.1.3 - - https://github.com/ruby/weakref/commit/f763384744 - -commit 304194d73e3b74b2493bfae16ce6189046f911f5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-07 09:28:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-07 10:45:02 +0900 - - Remove files which are newly added but to be ignored - -commit 3f33bfa1e51afc916250e7a7a93e599b65a78987 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 10:40:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 10:40:53 +0900 - - [ruby/optparse] Bump up 0.4.0 - - https://github.com/ruby/optparse/commit/acbf6e3e12 - -commit e8fda04d0a5e96e7425259fc4c3d15bb20d6ea84 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 10:09:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 10:10:12 +0900 - - [ruby/prettyprint] Bump up 0.2.0 - - https://github.com/ruby/prettyprint/commit/5ea64f43fa - -commit 0ac39f226dc847cd4bd9211da17fa7b33a7b9c89 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 09:59:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 10:00:08 +0900 - - [ruby/pp] Bump up 0.5.0 - - https://github.com/ruby/pp/commit/6e086e6df9 - -commit 31c36a444a1cd948b28fd968aa002c8a4960023d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-07 09:56:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-07 09:56:54 +0900 - - Skip example for 07df8a5d5ee725eee00632717ea4deead5fc783b - -commit 07df8a5d5ee725eee00632717ea4deead5fc783b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-06 17:29:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 09:41:15 +0900 - - [ruby/English] Remove `$IGNORECASE` - - `$=` has been obsolete and has no effect since 1.9. - - https://github.com/ruby/English/commit/121939695a - -commit 49b6dc8f07ec6baafa0881d8cb14029a66a04621 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-07 04:11:35 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-07 04:39:09 +0900 - - Prevent cpu_set_t overflow even if there are more than 63 cores - - Do not use `pthread_attr_setaffinity_np` if `sched_getcpu()` exceeds - `CPU_SETSIZE`. (Using `CPU_ALLOC()` would be more appropriate.) - -commit deb6dd76e19273ad902857a0e4c3f37704326d09 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-07 04:08:27 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-07 04:39:09 +0900 - - Fix a memory leak - - pointed by @nobu - -commit dc636fec2ae5ab5b5b0a7749a9ef1dffc393737c - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-06 20:48:14 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-07 04:39:09 +0900 - - Use pthread_attr_setaffinity_np instead of pthread_setaffinity_np - -commit d0066211f2052bf1444ffeb11544860a12cebff2 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-06 20:30:56 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-07 04:39:09 +0900 - - Detach a pthread after pthread_setaffinity_np - - After a pthread for getaddrinfo is detached, we cannot predict when the - thread will exit. It would lead to a segfault by setting - pthread_setaffinity to the terminated pthread. I guess this problem - would be more likely to occur in high-load environments. - - This change detaches the pthread after pthread_setaffinity is called. - [Feature #19965] - -commit 15560cce5f8709b8790bfde1528007c26654d168 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-06 20:30:06 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-07 04:39:09 +0900 - - Revert "Do not use pthread_setaffinity_np on s390x" - - This reverts commit de82439215dd2770ef9a3a2cf5798bdadb788533. - -commit ee25ac49f3a487dea8a22ae65b33f2b927706a7c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-07 02:46:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-11-07 02:46:37 +0900 - - [DOC] Use a relative link like other links - - following up on https://github.com/ruby/ruby/pull/8832 - -commit 14bf7164a69944b4e54aa2502cb5749d700505e5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-07 02:12:44 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-11-07 02:13:16 +0900 - - Revert an unwanted sync from Reline - - It wasn't supposed to be sync-ed in: - 2dd32e7c3b6904e61b9068596f5e4e82920c1fb0 - -commit dc911a332b0aebcee7752ca52a70d678f626b8fa - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-06 22:34:57 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-07 01:10:41 +0900 - - Remove rb_complex_ivar_set - -commit e2ef957c239f33e9a51fbe7ae21076321790305c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-06 22:34:38 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-07 01:10:41 +0900 - - Use general_ivar_set for generic ivars - -commit 18f675912e975037962f8939456379e276722a23 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-06 22:32:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-07 01:10:41 +0900 - - Use general_ivar_set for Class ivars - -commit 679e98dc27c4711601801db8852c5b4bc5a9da76 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-06 22:29:41 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-07 01:10:41 +0900 - - Use general_ivar_set for Objects - -commit c747c67533ef901d10ef054d2f57a0b90702c7f9 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-06 22:28:20 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-07 01:10:41 +0900 - - Implement general_ivar_set - -commit 2dd32e7c3b6904e61b9068596f5e4e82920c1fb0 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-11-07 00:53:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-07 00:53:38 +0900 - - [ruby/reline] Test Reline::Face without mocking - (https://github.com/ruby/reline/pull/600) - - * Test Reline::Face without mocking - - Because `test-unit-rr` is not a default gem, using it would break CRuby's - CI. - - * Add ruby-core workflow - - https://github.com/ruby/reline/commit/d2189ac436 - -commit 16403f41abcbaccf32484d10575d3542dbb3247e - Author: HASUMI Hitoshi <hasumikin@gmail.com> - AuthorDate: 2023-11-06 23:40:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-06 23:40:42 +0900 - - [ruby/reline] Introduce a new class Reline::Face to configure - character attributes - (https://github.com/ruby/reline/pull/552) - - * Reine::Face - - * fix test_yamatanooroti - - * Define singleton methods to make accessors to attributes of a face - - * s/display/foreground/ - - * s/default/default_style/ && s/normal_line/default/ && s/enhanced_line/enhanced/ - - * fix typo - - * FaceConfig.new now takes keyword arguments - - * Update lib/reline/face.rb - - Co-authored-by: Stan Lo <stan001212@gmail.com> - - * Update test/reline/test_face.rb - - Co-authored-by: Stan Lo <stan001212@gmail.com> - - * Fix to correspond to frozen_string_literal - - * Face::FaceConfig -> Face::Config - - * ref https://github.com/ruby/reline/pull/552#pullrequestreview-1677282576 - - * delete unused ivar - - * ref https://github.com/ruby/reline/pull/552#discussion_r1358783723 - - * insert "\e[0m" into all SGR - - * tiny fix - - * ESSENTIAL_DEFINE_NAMES - - ref https://github.com/ruby/reline/pull/552#discussion_r1367722247 - - * Change to Hash-accessor style - - - Reline::Face[:completion_dialog].enhanced -> - Reline::Face[:completion_dialog][:enhanced] - - Reline::Face.configs shows all defined values - - * Cache array method call in local variable - - * Tests for Face configuration variations - - * resolve https://github.com/ruby/reline/pull/552#pullrequestreview-1710938154 - - * amend to - - * check invalid SGR parameter in :style - - * The order of define values should be preserved - - * Update test/reline/test_face.rb - - Co-authored-by: Stan Lo <stan001212@gmail.com> - - * Update test/reline/test_face.rb - - Co-authored-by: Stan Lo <stan001212@gmail.com> - - * Add methods: load_initial_config and reset_to_initial_config. And teardown in tests - - * omission in amending "style: :default" to "style: :reset" - - * refs https://github.com/ruby/reline/issues/598 - - * Fix link - - * amend method name - - * Update lib/reline/face.rb - - Co-authored-by: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - - --------- - - https://github.com/ruby/reline/commit/fdc1d3b1e5 - - Co-authored-by: Stan Lo <stan001212@gmail.com> - Co-authored-by: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - -commit f6ba87ca8899cd753306ffbca475b16c367995a3 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-02 03:22:08 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-06 22:39:07 +0900 - - [PRISM] Implement compilation for MultiWriteNodes, fix MultiTargetNodes - - Compilation now works for MultiWriteNodes and MultiTargetNodes, with - nesting on MultiWrites. See the tests added in this commit for example - behavior. - -commit 4a6bdbd6dc160c4614105f0478d398b2222429e0 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-06 19:10:37 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-06 20:39:52 +0900 - - generic_ivar_set: properly check for TOO_COMPLEX on capacity transition - -commit 460c7b22934a1cc98915877ef48fbf85bfe53239 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 19:08:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-06 19:08:41 +0900 - - [ruby/uri] Bump up 0.13.0 - - https://github.com/ruby/uri/commit/b50d37f7a1 - -commit 00e5abae3ffce61970118809b7f7ff5fb1294d7a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 18:48:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-06 19:03:04 +0900 - - [ruby/yaml] Bump up 0.3.0 - - https://github.com/ruby/yaml/commit/f83b0404d5 - -commit bda3f67f8b0f63c126e97e40bbf8a2de64c78190 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 18:46:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-06 18:46:21 +0900 - - [ruby/shellwords] Bump up 0.2.0 - - https://github.com/ruby/shellwords/commit/fc63ac832d - -commit b5e7065d9a710f070fdcdb09570d6b321e1af39e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 18:43:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-06 18:44:09 +0900 - - [ruby/singleton] Bump up 0.2.0 - - https://github.com/ruby/singleton/commit/3c7fb5f258 - -commit ebb18167185157b9f32f9338f7b5ec7bb4ed486e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 18:31:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-06 18:33:03 +0900 - - [ruby/benchmark] Bump up 0.3.0 - - https://github.com/ruby/benchmark/commit/81af12352d - -commit 5a1934416f5338514f3400b63344846e2e5217c4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 18:29:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-06 18:29:53 +0900 - - [ruby/un] Bump up 0.3.0 - - https://github.com/ruby/un/commit/1f636a6239 - -commit 479717b4506840615f72ba479133c5132a34ad2d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 18:29:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-06 18:29:53 +0900 - - [ruby/un] Removed commented-out code - - https://github.com/ruby/un/commit/0d6669bff0 - -commit 4329554f171fdb483cafa672df5f2a08741940c5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-06 16:59:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-06 17:58:47 +0900 - - [Bug #19985] Raise LoadError with the converted feature name - - `Kernel#require` converts feature name objects that have the `to_path` - method such as `Pathname`, but had used the original object on error - and had resulted in an unexpected `TypeError`. - -commit 7a6c72e03d27003366fd3c5d6169fe0097c7114c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 17:53:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-06 17:53:00 +0900 - - Update rdoc parsers generated by racc-1.7.3 - -commit ee13da3e2a3632eca6401bb510941f6ff20a7b55 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 17:29:31 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-06 17:40:34 +0900 - - [ruby/rdoc] Bump up 6.6.0 - - https://github.com/ruby/rdoc/commit/9c14229876 - -commit e3a19b8a4306ae3103e6a27cdac7482585aac453 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 17:22:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-06 17:23:09 +0900 - - [ruby/net-http] Bump up 0.4.0 - - https://github.com/ruby/net-http/commit/4be99c204c - -commit 66d266244c00c1f9ffcfbd2970386e0adcc2512a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-06 17:15:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-06 17:22:39 +0900 - - [ruby/net-http] Removed obsolated Revision constant - - https://github.com/ruby/net-http/commit/c1c5638014 - -commit 0cd6eb607a00f48b1c7870bf2cb9fb5d3dde13df - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-06 17:12:14 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-06 17:12:14 +0900 - - Fix the CI failure in OpenBSD - - LibreSSL seems not to support `scrypt`. - - https://rubyci.s3.amazonaws.com/openbsd-current/ruby-master/log/20231105T233005Z.fail.html.gz - ``` - 1) - OpenSSL::KDF.scrypt creates the same value with the same input ERROR - NoMethodError: undefined method `scrypt' for module OpenSSL::KDF - ``` - -commit 44a1d2e78995f6bf6ce85ab38128e05a034a58ad - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-11-06 16:09:29 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-11-06 16:09:29 +0900 - - NEWS.md: Add a mention to [Feature #19965] - -commit a763d085e446d4a3cb09bd5f6bcaffc30484e804 - Author: JorandeBoer <126490137+JorandeBoer@users.noreply.github.com> - AuthorDate: 2023-11-03 18:44:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-06 11:52:31 +0900 - - Updated building_ruby.md to include reference for building on Windows - - Looking at building_ruby.md it is unclear that you are able to build Ruby on Windows. To fix that a reference has been added to the windows.md file. - -commit 40391faeab608665da87a05c686c074f91a5a206 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-05 20:42:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-05 20:50:07 +0900 - - [ruby/etc] Fix inconsistent dll linkage warning - - https://github.com/ruby/etc/commit/e4c71e5996 - -commit a15aa259db16ad2cbd3805d253bae557b4dde0b8 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-11-04 13:12:30 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-11-05 12:04:52 +0900 - - Lrama v0.5.9 - -commit 368a1cb3c40ea7fd17809e6d2e78f6a77f770a29 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-05 02:14:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-05 02:14:26 +0900 - - Do not use non-ASCII chars in sources - - No encodings are guaranteed in C compilers, and other than UTF-8 - encodings may be assumed in some platforms, e.g., CP932 on Windows - Japanese edition, and may result in compilation errors. - -commit 054a4672cb8dbb9edb3f84c14c09ac17fbec1102 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-05 02:11:07 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-05 02:11:07 +0900 - - Check non-ASCII code in more sources including generated files - -commit 8ed733f8f22cdc56a9d2694078871cfc401cb029 - Author: alpaca-tc <alpaca-tc@alpaca.tc> - AuthorDate: 2023-11-04 23:04:51 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-05 00:54:22 +0900 - - ast.rb: Fix bug for source of multibyte characters - - first_column and last_column return byte positions, but existing implementations - did not consider multibyte. - -commit 79d0879536cb28ce2dc5887fc46afdca170fdc76 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-04 17:43:39 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-04 19:28:49 +0900 - - [ruby/stringio] Make STRINGIO_VERSION uniform - - https://github.com/ruby/stringio/commit/4400bf3380 - -commit b30783e02ea8cfd89b657f85b261d14920448e46 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-04 13:44:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-04 19:28:39 +0900 - - [ruby/stringio] Move Java version to Java directory - - https://github.com/ruby/stringio/commit/3f90a0d619 - -commit 9106ac4525e63362e47b690288d500bdde040834 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-11-04 16:01:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-04 16:01:03 +0900 - - Update bundled gems list as of 2023-11-04 - -commit 9f95b6eb5d3458cc79668afd24b0b10c161d7d84 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-04 14:18:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-11-04 14:18:16 +0900 - - Skip a test that is flaky with RJIT - - It's crashing inside the bug reporter after a crash, so not sure why - it's crashing. It's not really useful for maintaining RJIT to flag this - test failure, so let's just ignore it until we figure out why it fails. - - https://github.com/ruby/ruby/actions/runs/6752729246/job/18358439166 - -commit 6b2a3c84a5a6f06841a277439052ca17a4c65e08 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-04 11:29:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-04 11:29:42 +0900 - - Update newer version gems only - -commit 6e38076b1689af98ab1164af9119b9304e54829a - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-11-04 06:07:13 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-04 06:07:13 +0900 - - YJIT: implement two-step call threshold (#8839) - - * YJIT: implement two-step call threshold - - Automatically switch call threshold to a larger value for - larger, production-sized apps, while still allowing smaller apps - and command-line programs to start with a lower threshold. - - * Update yjit/src/options.rs - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - - * Make the new variables constants - - * Check that a custom call threshold was not specified - - --------- - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - -commit 38bdb9d0da1647a9b91463183a9b61330243d908 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-11-04 03:06:35 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-11-04 03:47:41 +0900 - - YJIT: Delete some dead code and enable lints - -commit 5a132c78641c252a7b04ca8a5a493fe7d5ce8bab - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-04 02:59:07 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-04 02:59:07 +0900 - - Update prism to v0.17.1 - -commit dd0330249e1f96467e37c80436445fb74b953a30 - Author: Vinicius Stock <vinicius.stock@shopify.com> - AuthorDate: 2023-11-04 01:20:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-04 02:53:54 +0900 - - [ruby/prism] Always fully qualify types for RBIs and avoid using attributes - - https://github.com/ruby/prism/commit/0d0d039f8e - -commit 9d308ad4958d5b624faa7f8aee03ed4456052ec7 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-11-04 00:02:57 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-11-04 01:12:27 +0900 - - .travis.yml: Add a RubyGems issue ticket link. - - Add a RubyGems issue ticket link. The issue happend in Travis arm32 at once. - -commit d4045b0660e9aafb8309a1dd0e470ee9c998c799 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-11-03 23:21:25 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-11-04 01:12:27 +0900 - - .travis.yml: Add Ruby and RubyGems version info. - - The version information is useful to report issues to Ruby and RubyGems - projects. - -commit cc9bcad79c4a49fb1772acf58358283f8492d043 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-04 00:47:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-04 00:47:22 +0900 - - [ruby/prism] Make old compilers happy - - https://github.com/ruby/prism/commit/145a67d1c3 - -commit cdb410f688a15781524b701689747f2e186028b4 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-03 07:47:37 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-11-04 00:19:28 +0900 - - [PRISM] Fix stack consistency with Popped begin - - When a begin node is popped it only needs to putnil if that nil is going - to be the return value, otherwise it can successfully be optimised out. - -commit c44c982c9332a2671d65d48273629fc265ddf530 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-04 00:00:14 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-04 00:17:37 +0900 - - [ruby/prism] Bump to version 0.17.0 - - https://github.com/ruby/prism/commit/61a306cd5c - -commit e010bf167478d3f62ee37aa8e0fc15e474e957ba - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-04 00:04:25 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-04 00:04:25 +0900 - - Fix typo in variable.c - -commit 81882ca42f2996c8d273f63270e06d7de09b2bd3 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-04 00:00:58 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-04 00:01:11 +0900 - - Use RB_OBJ_WRITE over RB_OBJ_WRITTEN in variable.c - -commit e345bf31f885878f30c06a2fc2d3945bd47de244 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-11-03 22:20:14 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-11-03 23:54:30 +0900 - - .travis.yml: s390x: Use GCC 11.4.0. - - Use GCC version 11.4.0 (gcc-11 package) instead of the default GCC 11.3.0 to - align with the GCC used in the RubyCI s390x server below. - - ``` - $ /usr/bin/gcc --version - gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0 - Copyright (C) 2021 Free Software Foundation, Inc. - This is free software; see the source for copying conditions. There is NO - warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - - $ ls -l /usr/bin/gcc - lrwxrwxrwx 1 root root 6 Aug 5 2021 /usr/bin/gcc -> gcc-11* - - $ dpkg -S /usr/bin/gcc-11 - gcc-11: /usr/bin/gcc-11 - ``` - - Ubuntu Jammy gcc-11: https://packages.ubuntu.com/jammy-updates/gcc-11 - -commit 47163f9cf9af6eb1f808b5a74784f9974a331a4e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 23:52:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-03 23:54:13 +0900 - - [ruby/prism] Rename suppress warnings to verbose - - https://github.com/ruby/prism/commit/fbb30216ca - -commit 4b5f516f2efbe73133c41f799b3afb9f776b4680 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 22:40:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-03 23:35:08 +0900 - - [ruby/prism] Split comment - - We were previously holding a type field on Comment to tell what - kind of comment it was. Instead, let's just use actual classes for - this. - - https://github.com/ruby/prism/commit/e76830ca6e - -commit 1321df773b6316d2e88dfcada7844e00762d5a94 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-03 21:53:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-03 23:15:32 +0900 - - Use shape capacity transitions for generic ivars - - This commit changes generic ivars to respect the capacity transition in - shapes rather than growing the capacity independently. - -commit ec86b2eb3947060cffbc95c7c236e110a269c7de - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 21:42:48 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-03 23:13:50 +0900 - - [prism] Update to use new options APIs - -commit aab2a6a8a3166c9d3eeaf7a41191afde515e6271 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 07:12:57 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-03 23:13:50 +0900 - - [ruby/prism] Fix up lint - - https://github.com/ruby/prism/commit/4f3a3e3ec1 - -commit e121efd8355a3ae21ce8527fc1e2a9ba5b19fc67 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 04:43:41 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-03 23:13:50 +0900 - - [ruby/prism] Wire up the options through JavaScript - - https://github.com/ruby/prism/commit/81a9b2817f - -commit 8587d9a8bff3f329b3ebaddc0764220aa1879a84 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 04:42:18 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-03 23:13:50 +0900 - - [ruby/prism] Wire up options through the Java parser - - https://github.com/ruby/prism/commit/13fa262669 - -commit d7d3243364ba39bfb5dddb10d5d6c8733b4ceb37 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 04:06:50 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-03 23:13:50 +0900 - - [ruby/prism] Properly support the start line option - - https://github.com/ruby/prism/commit/33cc75a4b7 - -commit 95d3f2eaec1456eb5a964c4622ccc723af020ef2 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 03:28:25 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-03 23:13:49 +0900 - - [ruby/prism] Properly support the suppress_warnings option - - https://github.com/ruby/prism/commit/84229529d7 - -commit 85af40c1d7e707b9f66138d863c69084fb5ae8ed - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 03:20:28 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-03 23:13:49 +0900 - - [ruby/prism] Properly support the encoding option - - https://github.com/ruby/prism/commit/4b538af20f - -commit 649659119490eb8df75a05f85f0ae8be78e42bed - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 03:13:28 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-03 23:13:49 +0900 - - [ruby/prism] Rename serialization APIs for consistency - - https://github.com/ruby/prism/commit/5a2252e3ac - -commit 05f5c545d232554b6ffb183d6948ad37f46df53b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 03:01:20 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-03 23:13:49 +0900 - - [ruby/prism] Wire up options through the FFI API - - https://github.com/ruby/prism/commit/f0aa8ad93b - -commit ca7297efd389eca792c706326d1af138acf5a4f6 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 01:48:19 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-03 23:13:49 +0900 - - [ruby/prism] Wire up options through the Ruby API - - https://github.com/ruby/prism/commit/8582d372a3 - -commit 2a0f2b776325f949ba6d311b0d90cbaaea825b63 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-03 00:15:37 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-03 23:13:49 +0900 - - [ruby/prism] Create an options struct for passing all of the possible options - - https://github.com/ruby/prism/commit/99e81619de - -commit a43a52d415dff3868297ab070da4d4fd820f6b37 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-11-03 20:44:36 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-11-03 21:56:26 +0900 - - .travis.yml: Reduce the parallel job number. - - I think the "1+$(nproc)" is too much. - -commit b92b9e1e9e078d6bc1066a9335efb9e31f3bd4d9 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-10-26 18:08:05 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-03 20:47:43 +0900 - - vm_getivar: assume the cached shape_id like have a common ancestor - - When an inline cache misses, it is very likely that the stale shape_id - and the current instance shape_id have a close common ancestor. - - For example if the instance variable is sometimes frozen sometimes - not, one of the two shape will be the direct parent of the other. - - Another pattern that commonly cause IC misses is "memoization", - in such case the object will have a "base common shape" and then - a number of close descendants. - - In addition, when we find a common ancestor, we store it in the - inline cache instead of the current shape. This help prevent the - cache from flip-flopping, ensuring the next lookup will be marginally - faster and more generally avoid writing in memory too much. - - However, now that shapes have an ancestors index, we only check - for a few ancestors before falling back to use the index. - - So overall this change speeds up what is assumed to be the more common - case, but makes what is assumed to be the less common case a bit slower. - - ``` - compare-ruby: ruby 3.3.0dev (2023-10-26T05:30:17Z master 701ca070b4) [arm64-darwin22] - built-ruby: ruby 3.3.0dev (2023-10-26T09:25:09Z shapes_double_sear.. a723a85235) [arm64-darwin22] - warming up...... - - | |compare-ruby|built-ruby| - |:------------------------------------|-----------:|---------:| - |vm_ivar_stable_shape | 11.672M| 11.679M| - | | -| 1.00x| - |vm_ivar_memoize_unstable_shape | 7.551M| 10.506M| - | | -| 1.39x| - |vm_ivar_memoize_unstable_shape_miss | 11.591M| 11.624M| - | | -| 1.00x| - |vm_ivar_unstable_undef | 9.037M| 7.981M| - | | 1.13x| -| - |vm_ivar_divergent_shape | 8.034M| 6.657M| - | | 1.21x| -| - |vm_ivar_divergent_shape_imbalanced | 10.471M| 9.231M| - | | 1.13x| -| - ``` - - Co-Authored-By: John Hawthorn <john@hawthorn.email> - -commit 0ae6a2a1cf8ed63d7682a717edeb676221725cdb - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-31 01:31:19 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-11-03 20:39:57 +0900 - - .travis.yml: Disable ppc64le allow_failures. - - Now I expect that Travis ppc64le always passes without any random failures by - the commit 1f1b9b0942ec12dde1af8000f8cb84692904fccc that is - a workaround to pass the `test/rdoc/test_rdoc_generator_json_index.rb` in - Travis ppc64le case. - -commit 981ec1d44ab21b5d7ebb57ab7047604450715877 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-03 18:28:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-03 20:17:00 +0900 - - Update bundled gems list as of 2023-11-03 - -commit 35da6f864a05624433be2c8059b87d30b899b370 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-03 18:42:20 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-03 19:52:17 +0900 - - rb_ivar_defined: handle complex modules - - It was assuming only objects can be complex. - -commit 1f1b9b0942ec12dde1af8000f8cb84692904fccc - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-31 00:32:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-03 19:30:28 +0900 - - [ruby/rdoc] test/rdoc/test_rdoc_generator_json_index.rb: pend in test_generate in ppc64le. - - We observed that this test randomly fails in the ruby/ruby Travis ppc64le case. - This commit is to pend the test_generate if the assertion for the generated - file's modified time fails in a ppc64le environment. - - Note that I didn't use the word "Travis CI" or Travis CI specific environment variables - such as `TRAVIS` and `TRAVIS_CPU_ARCH`[1] in the code. Because I wanted to prioritize the - rdoc's independence from the ruby/ruby. - - [1] https://docs.travis-ci.com/user/environment-variables/#default-environment-variables - - https://github.com/ruby/rdoc/commit/42cdad1cf2 - -commit dcb9ded6c9148a31361ba2318ed7d57fd0c41431 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-11-03 07:37:30 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-11-03 16:28:05 +0900 - - [PRISM] Fix CallNode with arguments when popped - - Previously emitting a call node with an argument followed by another - node would cause the argument to be mistakenly omitted from the argument - list causing a stack underflow. - - ``` - PRISM: ************************************************** - -- raw disasm-------- - 0000 putself ( 0) - 0001 send <calldata:puts, 1>, nil ( 0) - * 0004 pop ( 0) - 0005 putobject 1 ( 0) - 0007 leave ( 0) - --------------------- - ``` - -commit 5cff4c5aa375787924e2df5c0b981dd922b95a8c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-02 23:35:19 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-03 10:41:48 +0900 - - Fix onigmo name table without st - - Co-authored-by: Adam Hess <HParker@github.com> - -commit 8b02de8f41296d1a2449ecaeb24726f088ce899c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-03 09:32:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-03 09:32:32 +0900 - - Fix thread leakage - - Wait for the worker thread to finish. - -commit ac8ec004e5272d589caca30616dbe12862150188 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-02 19:02:43 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-03 07:34:58 +0900 - - Make String.new size pools aware. - - If the required capacity would fit in an embded string, - returns one. - - This can reduce malloc churn for code that use string buffers. - -commit ee7bf4643d2716d44e13a732caf588b1a6275f7a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-02 03:28:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-03 07:14:08 +0900 - - [ruby/prism] Handle invalid constants in the constant pool - - It's possible for us to parse a constant that is invalid in the - current encoding. To fix this, we wrap the intern function in an - rb_protect to ensure we always put a valid symbol into the AST. - - https://github.com/ruby/prism/commit/e78398554d - -commit c6f5c64639152b950d4d1ccbaa199b621099e2a5 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-03 03:13:33 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-03 05:46:43 +0900 - - [PRISM] Fix popped for ForNode - -commit 7f18448a8e086b79a806acae5dbdd967f321c783 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-03 03:08:03 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-03 05:46:43 +0900 - - [PRISM] Fix popped for CallOperatorWriteNode - -commit d8bdb15a8b0da0d4ff2338bbb8087fbeb0a17b27 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-03 03:07:00 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-03 05:46:43 +0900 - - [PRISM] Fix popped for Call{And,Or}WriteNode - -commit 5acced49c2cd9309bcd92f38542e79eb0af87dd1 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-03 03:04:09 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-03 05:46:43 +0900 - - [PRISM] Fix popped for SingletonClassNode - -commit 33f18b3d2fac1d79d33b895fca58290823765d07 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-03 03:00:58 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-03 05:46:43 +0900 - - [PRISM] Fix popped for CaseNode - -commit 62baf723b6204bb8a067f3d9df911b7962b57304 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-03 02:56:40 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-03 05:46:43 +0900 - - [PRISM] Fix popped for AssocSplatNode - -commit 8b4b3b1d385df481f67fd8e24e1e8dca1caca446 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-03 02:53:33 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-03 05:46:43 +0900 - - [PRISM] Fix popped for MatchWriteNode - -commit 0359f9ca674a9cb30729bf545ea0a07ab5344ec3 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-03 02:46:40 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-03 05:46:43 +0900 - - [PRISM] Fix popped for ConstantPathOperatorWriteNode - -commit ddf12e8a3be135baf77a8adc833a37f93cf8f3d1 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-03 02:45:44 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-03 05:46:43 +0900 - - [PRISM] Fix popped for ConstantPathOrWriteNode - -commit ca24136da61c9bca9a8260cb0ac2ff206f6f3843 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-03 02:36:45 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-03 05:46:43 +0900 - - [PRISM] Fix popped on DefinedNode - -commit 698654ca8456a7e08033cb4eab2d6e9cef7b1413 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-03 03:18:40 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-03 05:46:43 +0900 - - [PRISM] Fixed popped for ConstantPathAndWriteNode - -commit 00407894b559ccb97fb8beb7fc3c4cc55a5f11a7 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-03 02:27:52 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-03 05:46:43 +0900 - - [PRISM] Fix test infrastucture, comment out failing tests - - Unfortunately, 84dfa0fa5e451adb87beaf497165cb5a1bc93770 introduced - a bug where we were no longer testing the "popped" case because the - "; 1" meant to be appended to the source was no longer functioning - as intended. - - This commit re-introduces the popped case, and comments out all - now failing tests. - -commit 0cb1fc3850db6367fa720bf3b603bb1fde2ef813 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-03 01:38:24 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-03 03:57:14 +0900 - - Fix vm_getivar to handle module with TOO_COMPLEX shape - -commit 4c3cc25ea2bc176aa699d14f155b566655936a38 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-03 00:01:35 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-03 02:42:11 +0900 - - Use shape capacity transition for class ivars - - This commit changes class ivars to respect the capacity transition in - shapes rather than growing the capacity independently. - -commit 38ba040d8bda65321daad8d5bfa8956b5072e826 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-02 22:49:23 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-03 02:42:11 +0900 - - Make every initial size pool shape a root shape - - This commit makes every initial size pool shape a root shape and assigns - it a capacity of 0. - -commit ad4f973ecd0a3481ff1abaa972d457e9f5b5fb4e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-11-03 01:15:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-03 01:15:48 +0900 - - YJIT: Always define method codegen table at boot (#8807) - -commit 5f130e2111db82eaf2c609e9cc7c000f9bac95be - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-02 22:23:14 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-02 22:23:14 +0900 - - Fix write barrier in rb_copy_generic_ivar - -commit 944e0ae6982634456d0a394fe5a0f72c8cd8984b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-02 21:46:54 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-02 21:46:54 +0900 - - Remove duplicated code in generic_ivar_set - - There is a duplicated check for the object is too complex. - -commit 33795931a021c6abebe2c60864d88b8f4644ff70 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-02 18:37:09 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-02 20:00:42 +0900 - - Better handle running out of shapes in remove_shape_recursive - -commit 42f368ead50bb51935026f54d698fe18780230d2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-02 15:48:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-02 15:48:34 +0900 - - Suppressing additional message if it missed to detect gem name - -commit e10f7c9d5b7c3097cd0d7bc3b7b7bbd2078c02cc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-02 15:46:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-02 15:48:34 +0900 - - Fix to detect gem name logic. It's mistake to migrate bundled_gems.rb from rubygems_integration.rb - - https://github.com/ioquatix/bake/pull/15#issuecomment-1777985097 - -commit 7523ede7ba0a5c1487bb53b3169f1a2cbc13152d - Author: Lars Kanis <lars@greiz-reinsdorf.de> - AuthorDate: 2023-10-27 22:25:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-02 15:16:41 +0900 - - Windows: Fix description of runtimes - - `mswin` platform links to `vcruntimeXXX.dll` but `mingw-ucrt` doesn't. - -commit 7149543f249d7e29d223fde860770fded5762f0b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-02 15:13:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-02 15:13:40 +0900 - - Added TestRipper namespace to test_call_colon2 - -commit 1925c6d555e40b7c6c36ac9665b4cffed4b1d4cb - Author: lukeg <luke.gru@gmail.com> - AuthorDate: 2023-04-04 05:17:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-02 15:10:50 +0900 - - test/ripper: nest helper classes under TestRipper module - - Generic names like Node and NodeList should be namespaced properly. - -commit 4218e913d8d1d1e4c2fb123348fd98721e2b0ba8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-02 12:53:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-02 15:00:39 +0900 - - Fix functions for name tables as `st_foreach_callback_func` - -commit e34e8b93f8fac3ef40ab5ed8672fa003f3b4d9c0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-11-02 13:32:53 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-11-02 13:32:53 +0900 - - Support Pathname object for warning feature of bundled gems - -commit d9cb75b741c786a1198f7c7e9d1eead6818b9d17 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-02 03:58:50 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 11:16:33 +0900 - - List prism as a default gem - -commit ee90a7f981cc69c076f7443bd523596c9aef7bcd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-02 10:31:13 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-02 10:31:13 +0900 - - [DOC] Update the document for `FilePathStringValue` - -commit 45eee0cd9444634fb9fe9a7a8db5d394658e6c60 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-11-02 10:06:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-02 10:06:03 +0900 - - Remove duplicate to_path conversion - - `rb_file_open_str` calls `FilePathValue`, and the converted result is - not used in this function. - -commit d3ea9070bbbf04749e5fcd8339d71a9e73a86cfb - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-11-02 03:40:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-11-02 03:40:40 +0900 - - YJIT: skip to_a in format_number (#8815) - - String#chars returns an array instead of an enumerator since Ruby 2.0. - -commit 909afcb4fca393ce75cc63edc7656fd95a64f0f9 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-02 02:47:26 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-02 02:47:26 +0900 - - Fix SystemStackError in test_run_out_of_shape_for_class_cvar - -commit 52e127280bacf19f38284c68149351f192e71e5d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 22:51:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-02 02:40:16 +0900 - - [ruby/prism] Disallow assigning to numbered parameters in regexp - - https://github.com/ruby/prism/commit/ec419422f8 - -commit bdf8ce807ffe8e4bfd2947aba809855857b958ed - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-02 02:13:51 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-02 02:13:51 +0900 - - Fix remove_class_variable for too complex classes - -commit 90b21b864d7ec32c048731393f5ebe89a3b9024a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-02 01:14:30 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [prism] Updates for sync - -commit 3551abab063c4682c6cef57c15fc31da3400a360 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 04:40:50 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Fix up lint - - https://github.com/ruby/prism/commit/77d4056766 - -commit 690f3bbf5d67d8629d6e6d7305b79fcc5362b0c9 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 02:26:31 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Last remaining missing C comments - - https://github.com/ruby/prism/commit/e327449db6 - -commit e745af2f0e36f7ff3499019dfb038799a9d3d069 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 02:13:13 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Comment format for prism.c - - https://github.com/ruby/prism/commit/83f737ce17 - -commit 51079a89af4da2d410a069e0598e72ed454363fe - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 01:59:39 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] More documentation for ast.h - - https://github.com/ruby/prism/commit/84e22c5581 - -commit 17923cc876513707b4bedcd4437b229feb455099 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 01:54:54 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Even more C file documentation - - https://github.com/ruby/prism/commit/9c648ce615 - -commit 6b3b530cc1266aeaecb68a01e8511a794ea456ea - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 00:49:23 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Documentation for nodes - - https://github.com/ruby/prism/commit/69323d3df4 - -commit 171788c703f7b75dd85f09f6836886986074c4d1 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 00:46:01 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Remove unnecessary PM_EMPTY_ARGUMENTS - - https://github.com/ruby/prism/commit/271f3bf628 - -commit b12c795bdc49ae2c925b1476fc1d46800ac45fb7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 00:44:24 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Remove unnecessary PM_EMPTY_NODE_LIST - - https://github.com/ruby/prism/commit/857f72e1f4 - -commit f791db4433dcad178ee77c58c08f9c38e08a452f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 00:38:06 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Documentation for defines, version, and prettyprint - - https://github.com/ruby/prism/commit/e2e29bef2d - -commit 1de05631b50140c8510be0bf4413cc8b10fcd74b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 00:35:56 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Documentation for diagnostics and regexp - - https://github.com/ruby/prism/commit/16e0579044 - -commit affa6714bc90fd99d29cda092db007d626914af5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 00:29:29 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Documentation for constant pool - - https://github.com/ruby/prism/commit/76af64eb21 - -commit 87c6fb85483b63cf976d7738eb5a2b55e6f2b1d7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 21:54:52 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Documentation for the encodings - - https://github.com/ruby/prism/commit/52a0d80a15 - -commit 493439c9ce8d298f3fbd2c9c01d35fcc9add6d49 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 12:33:04 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Documentation for pm_strncasecmp - - https://github.com/ruby/prism/commit/26934263b7 - -commit e8a72b516f141de9581c2edd1d8eb101739477bb - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 12:28:54 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Documentation for more C functions - - https://github.com/ruby/prism/commit/88336e7d9f - -commit 86bfd6060d84cd559d48d713afbb83f814d8cd16 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 12:23:16 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Documentation for pm_newline_list_t - - https://github.com/ruby/prism/commit/97b3cc0af8 - -commit 8302f9986caf6679c728ae2b31b1211401f48d28 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 12:15:31 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Documentation for pm_string_t - - https://github.com/ruby/prism/commit/ff1d2ec579 - -commit b67994d6bf88fcfd66fc0368a03a92aa81fe8b11 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 12:09:18 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Even more C documentation - - https://github.com/ruby/prism/commit/bec5ca37a0 - -commit 7c8d93968009d1f3123ebc78906d4abb896e6905 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 10:58:48 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Start better documenting C API - - https://github.com/ruby/prism/commit/2b6e661bbc - -commit 4490979615338ea21619c2f1287759172c9a2437 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 04:11:24 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Finish Ruby documentation - - https://github.com/ruby/prism/commit/dfdcc98a3c - -commit 79034fbd503769ed2742003e31920733e9300909 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 03:43:45 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] More Ruby docs - - https://github.com/ruby/prism/commit/ca9a660f52 - -commit 953138698e4c2ba7a698ee133fbdc5d075556a5d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 03:19:16 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Docs for node.rb and parse_result.rb - - https://github.com/ruby/prism/commit/085da4feb9 - -commit 0a460b23e0e8a4cced92e752b46c2170e83cec63 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 03:00:44 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Add comments on flags - - https://github.com/ruby/prism/commit/3abd09c803 - -commit f12617ec9832ff8979cd86eb717fa9ee5820123e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 02:49:32 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Fix up Prism and Debug docs - - https://github.com/ruby/prism/commit/c2b7724d91 - -commit 73b6934cf27315ac52e7565f4ff7b889447f5593 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 02:40:55 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Fix up extension docs - - https://github.com/ruby/prism/commit/cfd4431c3e - -commit 5df14ecebe580c4bbe46aa09411c96f1f6ec66d0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 02:01:35 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-02 02:10:29 +0900 - - [ruby/prism] Fix up Ruby docs - - https://github.com/ruby/prism/commit/8062849d0d - -commit 8c0eb221b7d35cc2d2ad1b861167fcc3ee80c16b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 22:36:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-02 02:03:35 +0900 - - [ruby/prism] Forward parameters into arrays - - https://github.com/ruby/prism/commit/2a11bfee76 - -commit bb2e1d8eefc9a20c24614c3c2d428a01c87b529d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-02 02:02:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-02 02:03:10 +0900 - - [ruby/prism] Fix rescue modifier comment - - https://github.com/ruby/prism/commit/e13f2e4590 - -commit e6059d0c84b2347ce542f7fb655021f73f744447 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-02 00:37:13 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-02 00:37:13 +0900 - - Refactor rb_obj_remove_instance_variable - -commit 70e3e08881d3f7f59828776de6af8b1898ebfe77 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-02 00:05:46 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-02 00:05:46 +0900 - - Optimize for too complex objects - -commit e80ca70b9bd1ccfa319790475dc9c0dd125f4f0d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-01 21:36:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-01 23:40:45 +0900 - - [ruby/prism] Flip incorrect names of OptionalKeywordParameterNode and RequiredKeywordParameterNode - - https://github.com/ruby/prism/commit/c31f61e898 - -commit d0625099e0f691f44fb4c796d8d497d818bf7c8e - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-01 05:00:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-01 23:40:44 +0900 - - [ruby/prism] Split KeywordParameterNode into Optional and Required - - Prior to this commit, KeywordParameterNode included both optional - and required keywords. With this commit, it is split in two, with - `OptionalKeywordParameterNode`s no longer having a value field. - - https://github.com/ruby/prism/commit/89084d9af4 - -commit 717fb5bb0b0d9aa4dbc636ea87037703a941b34f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-11-01 22:02:00 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-11-01 23:36:21 +0900 - - [prism] Use a pointer for optional node list - -commit e3b4fe1b7695e22ce4970171de8514f0307dbce5 - Author: Sergey Fedorov <vital.had@gmail.com> - AuthorDate: 2023-11-01 17:53:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-11-01 23:29:15 +0900 - - thread_pthread.c: unbreak 10.5 Intel by restoring accidentally deleted macro - -commit b77148ae9f74c46e645d9ce7387619e67109d935 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-11-01 20:15:12 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-11-01 23:21:55 +0900 - - remove_instance_variable: Handle running out of shapes - - `remove_shape_recursive` wasn't considering that if we run out of - shapes, it might have to transition to SHAPE_TOO_COMPLEX. - - When this happens, we now return with an error and the caller - initiates the evacuation. - -commit 9c6dd25093f49d926ac71c3b91e1320d4bbc553a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-01 21:25:09 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-01 21:25:09 +0900 - - Fix removing non-existent ivar for too complex - -commit a1e24ab4841b8032b274bfd49c30adfdeb82b859 - Author: Cody Cutrer <cody@instructure.com> - AuthorDate: 2023-10-12 01:05:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-01 11:29:56 +0900 - - [rubygems/rubygems] avoid dependency on set - - it was a performance improvement only, but it causes failures in - unrelated tests - - https://github.com/rubygems/rubygems/commit/b4149cb9bf - -commit 836d9fe46b85dd28339d2dae891df2da153c8632 - Author: Cody Cutrer <cody@instructure.com> - AuthorDate: 2023-09-16 00:32:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-11-01 11:29:56 +0900 - - [rubygems/rubygems] Add Bundler::Plugin.loaded? helper - - Useful if your plugin introduces new methods to the DSL, so that - Gemfiles can easily abort if the plugin hasn't loaded yet - - https://github.com/rubygems/rubygems/commit/b733055c6e - -commit c3b7f275613507334fc4dcbfde0491ddaa786323 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-01 06:04:40 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-01 06:04:40 +0900 - - Fix remove_instance_variable for too complex generic ivar - -commit 60e207b47f377b04d11df9a9dbb0548a578c2776 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-01 06:01:28 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-01 06:01:28 +0900 - - Fix SystemStackError for test_run_out_of_shape_for_class - -commit 8889992b75f85c8080fc09c7a3a1cb6123a098c1 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-11-01 05:38:05 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-01 05:38:05 +0900 - - Fix remove_instance_variable for too complex class - -commit b7a3e2e71dc68ec56036f37ab5a1f94489436f96 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-01 03:57:25 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-01 03:57:25 +0900 - - [PRISM] Remove unnecessary variable - -commit b3744c749d74303aab0c560c9a2f223125009412 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-11-01 00:19:38 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-01 01:59:40 +0900 - - [PRISM] Implement compilation for SuperNode - -commit 57748ef2a26cbdfe075347c6f7064eb419b4949a - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-31 01:56:30 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-01 01:08:09 +0900 - - [PRISM] Compile forwarding super node - -commit e2d950733ee274e577813b5a4e930f617c60634f - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-10-31 22:38:35 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-01 01:07:54 +0900 - - Add ST table to gen_ivtbl for complex shapes - - On 32-bit systems, we must store the shape ID in the gen_ivtbl to not - lose the shape. If we directly store the ST table into the generic - ivar table, then we lose the shape. This makes it impossible to - determine the shape of the object and whether it is too complex or not. - -commit 1c45124c497089fa310c13ee4b9ea1d3ec2c2ca8 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-10-31 03:00:49 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-01 01:07:54 +0900 - - Create table for too complex generic variables - -commit 6f5e378057a02dadbb0173072f69c8a3f30f5649 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-31 01:50:56 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-01 01:07:54 +0900 - - Fix "too complex" iv sets on generic ivar objects - - We weren't taking in to account that objects with generic IV tables - could go "too complex" in the IV set code. This commit takes that in to - account and also ensures FL_EXIVAR is set when a geniv object - transitions to "too complex" - - Co-Authored-By: Jean Boussier <byroot@ruby-lang.org> - -commit ac7f913ca3af970225c9cc93b92eb5c403894180 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-10-30 22:55:13 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-01 01:07:54 +0900 - - Handle SHAPE_TOO_COMPLEX in `generic_ivar_set` - -commit 4aacc559d99988f395eced3534c7a6938bd356c8 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-10-30 20:29:59 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-11-01 01:07:54 +0900 - - Handle running out of shapes in `Object#dup` - - There is a handful of call sites where we may transition to - OBJ_TOO_COMPLEX_SHAPE if we just ran out of shapes, but that - weren't handling it properly. - -commit 85ad1025328989bb4e10436aed121b9136b0c8bf - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-31 05:57:27 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-11-01 00:51:06 +0900 - - [PRISM] Implement compilation for PostExecutionNode - - This commit implements compilation for the PostExeuctionNode by - using the ScopeNode to create child iseqs where appropriate. - -commit b5d54fc15955c636cc37b76931a6e3ce1d209f70 - Author: Cody Cutrer <cody@instructure.com> - AuthorDate: 2023-09-15 02:58:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-31 22:53:05 +0900 - - [rubygems/rubygems] Only remove bundler plugin gem when it's inside the cache - - https://github.com/rubygems/rubygems/commit/8d51390ca4 - -commit 3801503fe3d5c1440bc4e47a60e3e3bf5a22255d - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-10-31 21:35:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-31 21:54:13 +0900 - - [ruby/prism] Fix a possible malloc(0) - - https://github.com/ruby/prism/commit/fa108b8626 - -commit b0a2373e14d475cfcf6ce21d25cbde2518c0dddc - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-30 23:33:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-31 21:28:58 +0900 - - [ruby/prism] Share comment generation logic - - https://github.com/ruby/prism/commit/6e5556dbdf - -commit 322755a0076e74e5959c9f6b2682be79a60cef4e - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-10-31 18:14:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-31 20:14:07 +0900 - - [ruby/prism] Fix a possible null dereference - - https://github.com/ruby/prism/commit/7dbb8c7e3e - -commit d8a9245513184c1dcde94ea09d95560eab577f7e - Author: HParker <HParker@github.com> - AuthorDate: 2023-10-28 02:44:41 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-31 19:01:00 +0900 - - Add defined array node - -commit b05a7bc512e2bb0f4d097d9cc9f1db8859323798 - Author: HParker <HParker@github.com> - AuthorDate: 2023-10-27 06:54:38 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-31 19:01:00 +0900 - - compile defined with nested constants and stovetop - -commit 962c62057f153e7491e3d999129c437f4fe23d96 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-10-31 06:13:10 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-10-31 18:01:56 +0900 - - Fix warning in Prism compile For Node - -commit 51149f335e4aea3465bd52a98f85351455bf320e - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-20 21:30:18 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-31 17:49:12 +0900 - - Keep unused literal nodes - - For static analysis, it’s better to keep unused literal nodes. - If simply change `block_append` to fall through, both "unused literal ignored" - and "possibly useless use of a literal in void context" warnings - are shown for the same line. But it’s verbose then remove - "unused literal ignored" warning. - - This kind of optimization is already implemented on compile.c. - `compile_block` calls `iseq_compile_each0` with `popped = 1` when NODE_BLOCK - has next. - -commit eff59e93df1102d990a61965d906a28d55abc14a - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-10-31 16:00:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-31 16:00:00 +0900 - - Update bundled gems list as of 2023-10-30 - -commit d22767fd482aca2f2b9fb4f0bcf6d845f990fefd - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-10-31 08:52:25 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-10-31 14:12:07 +0900 - - Add a --disable-yjit job for Ubuntu CI - - Currently, we do not have an amd64 job that runs with YJIT disabled - and runs the full check task. Most amd64 jobs implicitly have YJIT - enabled, even though --enable-yjit was not specified. This makes it - easier to determine whether a problem is YJIT-related or not by - reviewing CI logs. - -commit 4adf418be963b3554962b2f27057be81486c57d9 - Author: Daisuke Aritomo <osyoyu@osyoyu.com> - AuthorDate: 2023-09-29 15:35:36 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-31 11:16:18 +0900 - - [Feature #10602] Add new API rb_profile_thread_frames() - - Add a new API rb_profile_thread_frames(), which is essentialy a - per-thread version of rb_profile_frames(). - - While the original rb_profile_frames() always returns results about the - current active thread obtained by GET_EC(), this new API takes a Thread - to be profiled as an argument. - - This should come in handy when profiling I/O-bound programs such as - webapps, since this new API allows us to learn about Threads performing - I/O (which do not have the GVL). - - Profiling worker threads (such as Sidekiq workers) may be another - application. - - Implements [Feature #10602] - - Co-authored-by: Mike Perham <mike@perham.net> - -commit 02ecc3c8550af1aab7916975e7019b2a3ffe8591 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-31 10:44:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-31 10:44:53 +0900 - - Disable wrong test - -commit f0b7895637d4c4e4a1c72cecaa8700495f12177b - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-31 04:20:07 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-31 06:07:04 +0900 - - [PRISM] Implement all argument types for CallNodes - -commit b17b0336b613b0873542f48f1417ebfeb0079efa - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-10-31 03:20:49 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-10-31 04:44:42 +0900 - - Document TEMP_CONSTANT_IDENTIFIER - -commit 9249b8622ba1c5e9b457a5cfccff09342d820594 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-10-30 22:49:17 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-10-31 04:44:42 +0900 - - Move constant indexing into rb_translate_prism - -commit 91fba0a3d2d00e3e532f6d84cac9e5477e2bdaa6 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-10-20 19:11:08 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-10-31 04:44:42 +0900 - - [Prism] Add ForNode tests - -commit 5dfba84cffd149c97e1cb7a1cb3e40869e127c5f - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-10-20 18:59:02 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-10-31 04:44:42 +0900 - - [Prism] Compile ForNode - - Fixes ruby/prism#1648 - -commit b0f715fa3bb5e89a11fa3449d216e77635426a58 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-10-20 18:58:23 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-10-31 04:44:42 +0900 - - More accurate functions documentation - -commit 85beca6e418baecddc0f01e8a7d86d42c3e96bbf - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-10-31 03:21:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-31 03:22:02 +0900 - - [ruby/irb] Use IRB's own doc for doc dialog tests - (https://github.com/ruby/irb/pull/743) - - * Use IRB's own doc for doc dialog tests - - * Run doc dialog tests for older Rubies too - - * Remove unnecessary CI setups - - https://github.com/ruby/irb/commit/97a2b86f0a - -commit b413760d66e4de5670148b01a6a2076452a2f757 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 01:35:39 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-31 01:35:39 +0900 - - [prism] Update prism to latest - -commit a7a70bce82e6335f034951a1422bc372d8225df4 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 01:27:03 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-31 01:27:03 +0900 - - rm prism type templates - -commit 674db715f5a141891a66e67004ca138696d3b0ad - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-31 01:03:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-31 01:21:28 +0900 - - [ruby/rdoc] test/rdoc/test_rdoc_generator_json_index.rb: Use assert_equal instead of assert. - - It's better because assert_equal prints the values when it fails. - - https://github.com/ruby/rdoc/commit/91d40ce8f8 - -commit 3a21da9591d3325d8a14dcbac3ad6aeaadebef81 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-10-30 23:47:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-31 01:19:54 +0900 - - [ruby/prism] Faster lex_identifier - - https://github.com/ruby/prism/commit/e44a9ae742 - -commit 2ab247d217c7bc312c3bcbb74636a60328f64109 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-31 00:56:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-31 00:56:42 +0900 - - Missing format string - - Do not use a variable as a format string. Also we usually don't - expect non-ascii data in C string literals. - -commit 7bf3d9343fc9ca34124026cb3806107a3a6ddf09 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 00:21:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-31 00:53:37 +0900 - - [ruby/prism] parse_inline_comments -> parse_comments - - https://github.com/ruby/prism/commit/bd4d248fd6 - -commit 7d8cfa0a40475c59364605f83b1b892bf068ae30 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-10-31 00:44:54 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-10-31 00:44:54 +0900 - - Update to ruby/spec@d56bd0f - -commit b09618e566af8b2cafd4f264f310125ddc5c4467 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-10-31 00:44:52 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-10-31 00:44:52 +0900 - - Update to ruby/mspec@d03ad9c - -commit 58d1fbcf3fc47fb5613f4854ab061f0035402713 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-10-31 00:44:47 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-10-31 00:44:47 +0900 - - Revert "OpenSSL::KDF.scrypt needs EVP_PBE_scrypt()" - - This reverts commit d434765faead1583ca9008bb579067a288085b93. - -commit d434765faead1583ca9008bb579067a288085b93 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-31 00:31:51 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-31 00:31:51 +0900 - - OpenSSL::KDF.scrypt needs EVP_PBE_scrypt() - -commit 9d1472496d688c815c14da325c43cdcbceed8e1c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-31 00:08:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-31 00:08:24 +0900 - - [ruby/prism] Remove newlines from magic comment test - - https://github.com/ruby/prism/commit/4a7be1fc50 - -commit ebb8da5438d5183fc79d788386a1848cb9ad4295 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-28 19:28:43 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-10-30 23:23:15 +0900 - - .travis.yml: Refactor. - - * Add notes. - * When you see Travis issue, please check the link below. - https://github.com/ruby/ruby/wiki/CI-Servers#travis-ci - * Added the following random failure. - The ppc64le failure has been happening randomly in Travis focal/jammy. - TestRDocGeneratorJsonIndex#test_generate fails randomly. - https://app.travis-ci.com/github/ruby/ruby/jobs/612380961#L2900 - * Update the comments. - * Remove empty lines in nested YAML elements aligning with other parts. - -commit 753b1ab194f315bd6e5dcf29682ff348806e5769 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-28 22:45:45 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-10-30 23:23:15 +0900 - - .travis.yml: Disable s390x allow_failures. - - To avoid unintentional new failures. Feel free to enable it again when the case - is unstable. - -commit ca7296767b5db9a401bc64738984f35880061a73 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-28 19:19:23 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-10-30 23:23:15 +0900 - - .travis.yml: Remove optflags=-O1 except arm32. - - We want to align the used build flags with RubyCI ppc64le Ubuntu jammy server - as much as possible to avoid Travis specific issues. - - Still keep the -O1 for only arm32 due to the following issue. - https://bugs.ruby-lang.org/issues/19981 - -commit 5d7904ff7da8a824db672ee4d59d7127eaf00206 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-23 22:41:00 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-10-30 23:23:15 +0900 - - .travis.yml: Upgrade the Ubuntu ppc64le to 22.04 (Jammy). - - Seeing the recent successes on RubyCI ppc64le Ubuntu jammy servers, it's time - to upgrade Travis ppc64le to jammy. - - http://rubyci.s3.amazonaws.com/ppc64le/ruby-master/recent.html - - Upgrade the gcc version to the latest version 11.4.0 to align the gcc - version used in the RubyCI ppc64le server's gcc version. - -commit 1d51e4cadfbc1f445d00887189e06047759c9aec - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2023-10-28 00:14:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-30 23:15:47 +0900 - - [ruby/prism] Improve comment generation in templates - - The existing comment generation was hard to read and was making a lot of string manipulation. However, ERB files are already designed to do string manipulation, so we can use that instead. - - So, instead of doing a split and a map, I opted to use the `#each_line` method to iterate over the lines of the file. - - Also, in order to add an optional space padding at the beginning of the line, I opted to pad it with a space and to then right trim it. This makes sure that no space is left behind if the line is empty, but a space is added if the line is not empty. - - https://github.com/ruby/prism/commit/5736711e70 - -commit ab4781b64d945e962575f2eac20b72185235d23b - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-10-30 21:49:46 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-10-30 21:49:46 +0900 - - Update to ruby/spec@bd7017f - -commit 14fa5e39d72c84d3e12e10dc5d77a6e6200c10f5 - Author: Christian van Rensen <christian.van.rensen@tngtech.com> - AuthorDate: 2022-07-29 01:30:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-30 18:27:06 +0900 - - [ruby/net-http] fix no_proxy behaviour - - https://github.com/ruby/net-http/commit/f4951dc42a - -commit f109269a0392940df2b314e16502c4509b94a290 - Author: Christian van Rensen <christian.van.rensen@tngtech.com> - AuthorDate: 2022-07-29 01:29:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-30 18:27:06 +0900 - - [ruby/net-http] fix a false-negative test - - * no_proxy is meant to operate on the destination address, not on the name of the proxy - * if both end with `'.example'`, the test does not nail down the behaviour - - https://github.com/ruby/net-http/commit/bb9a5cfa3d - -commit f757a5d3ceb62a1f049f7060429b5b3bac6ad545 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-30 17:23:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-30 17:35:13 +0900 - - [ruby/yaml] Compatibility for Psych 4 - - https://github.com/ruby/yaml/commit/b4b72ae0b4 - -commit 5c1b7633fcd9c7c43974b72bd36cab1f9e9bd186 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-30 12:01:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-30 13:46:09 +0900 - - [rubygems/rubygems] Relax matching pattern for rake version - - https://github.com/rubygems/rubygems/commit/a89f74c27e - -commit 34cb174800e1e41323807c99386641b688927adc - Author: Hiroya Fujinami <make.just.on@gmail.com> - AuthorDate: 2023-10-30 13:10:42 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-30 13:10:42 +0900 - - Optimize regexp matching for look-around and atomic groups (#7931) - -commit 13c9cbe09ef310c7ddf055d57ebf4586e9f9a111 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-30 00:19:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-30 00:19:43 +0900 - - Embed `rb_args_info` in `rb_node_args_t` - -commit fbd55120f3c58dc7d16b3870a8f36f07277bb338 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-29 21:27:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-29 21:27:49 +0900 - - Cast up before multiplication - -commit 88f1d380ea431bc807e221fa07f4ac157539fdf7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-29 16:14:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-29 16:15:24 +0900 - - [ruby/etc] Start 1.4.3 - - https://github.com/ruby/etc/commit/a9e4d4730d - -commit db7a4be846453bc0143f61532d4061a9cad95639 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-10-28 23:47:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-28 23:47:46 +0900 - - [ruby/irb] Easter egg for autocomplete mode - (https://github.com/ruby/irb/pull/737) - - * Show easter-egg inside document dialog in autocomplete mode - - * Show more easter_egg(dancing or logo) when Alt+d is pressed in autocomplete mode - - https://github.com/ruby/irb/commit/a8e5cc7354 - -commit a447a6d1a9c08166ee517a53d3e824ac5bf12ed3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-28 22:18:17 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-28 22:18:17 +0900 - - Extract transcoding assertions - - - Prefix `check_both_ways` with `assert_` to show proper failure - lines. - - - Extract dedicated assertions for Encoding::UndefinedConversionError - and Encoding::InvalidByteSequenceError. - -commit 83ecdd1dce18246de631eb3b5d8308145bb269f5 - Author: Jun Aruga <junaruga@users.noreply.github.com> - AuthorDate: 2023-10-28 18:12:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-28 18:12:25 +0900 - - Revert ".travis.yml: Drop s390x temporarily." (#8792) - - It seems the Travis s390x is recovered again now. - - This reverts commit 95cc0f946eb641be8dea4b7118598be77d993183. - -commit 3eaae72855b23158e2148566bb8a7667bfb395cb - Author: Jun Aruga <junaruga@users.noreply.github.com> - AuthorDate: 2023-10-28 18:10:30 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-28 18:10:30 +0900 - - test/fiber/test_queue.rb: Make the stuck test fail. (#8791) - - test/fiber/test_queue.rb: Make the stuck tests fail. - - We observed the 2 tests in the `test/fiber/test_queue.rb` getting stuck - in some GCC compilers in Ubuntu ppc64le focal/jammy, even when the timeout - `queue.pop(timeout: 0.0001)` is set in the code. - - This commit is to make the tests fail rather than getting stuck. - -commit 7e6204dd10857a6f1fb72119082ff7797686c089 - Author: Lars Kanis <lars@greiz-reinsdorf.de> - AuthorDate: 2023-10-28 01:47:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-28 10:44:16 +0900 - - Windows: Add libffi as a build dependency - - Otherwise the fiddle extension isn't build. - -commit 2714d7507aa053d1804095f7ce3b869c56f64337 - Author: License Update <license.update@rubygems.org> - AuthorDate: 2023-10-08 09:23:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-28 07:14:37 +0900 - - [rubygems/rubygems] Update SPDX license list as of 2023-10-05 - - https://github.com/rubygems/rubygems/commit/e69a43ac9f - -commit 49d442116470ca5e1fcc9eb198411640fbbe446a - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-28 03:35:25 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-10-28 04:56:31 +0900 - - .travis.yml: Disable allow_failures for arm32. - - I want to disable allow_failures if possible to avoid unintentional new - failures. It seems that the arm32 case is stable. - - Feel free to enable allow_failures again when you see the case is unstable. - -commit ddf5a33c4cff25aa1d76a29ce480383f816fd930 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-23 22:41:00 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-10-28 04:56:31 +0900 - - .travis.yml: Upgrade the Ubuntu arm32 to 22.04 (Jammy). - - Upgrade the gcc version to the latest version 11.4.0 to align the gcc - version used in the RubyCI arm64 server. - -commit 4aee6931c35a80af846f7100cb8aa1525618e580 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-10-27 23:41:03 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-10-28 04:09:03 +0900 - - Make get_next_shape_internal idempotent - - Since the check for MAX_SHAPE_ID was done before even checking - if the transition we're looking for even exists, as soon as the - max shape is reached, get_next_shape_internal would always return - `TOO_COMPLEX` regardless of whether the transition we're looking - for already exist or not. - - In addition to entirely de-optimize all newly created objects, it - also made an assertion fail in `vm_setivar`: - - ``` - vm_setivar:rb_shape_get_next_iv_shape(rb_shape_get_shape_by_id(source_shape_id), id) == dest_shape - ``` - -commit d654d580f388a1ffc60e74d4b05f753c884ec543 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-10-28 03:28:56 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-10-28 03:28:56 +0900 - - Revert "Add debug info for flaky test_warmup_frees_pages" - - This reverts commit db3b814cb0ff6ffe83fe0c4f66cd6ce8951c3ca7. - - This debugging information is no longer needed. - -commit c201dbc0ada03b985e297d22d6dfa24b7bac12ce - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-28 02:55:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-28 03:09:14 +0900 - - [ruby/prism] Prism.parse_inline_comments - - https://github.com/ruby/prism/commit/5b72f84480 - -commit df10e10314e860c73c57e6bf43cf84aac7686270 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-28 02:34:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-28 03:09:14 +0900 - - [ruby/prism] Parse inline comments - - https://github.com/ruby/prism/commit/44090d9f26 - -commit 95cc0f946eb641be8dea4b7118598be77d993183 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-28 00:01:03 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-10-28 02:16:13 +0900 - - .travis.yml: Drop s390x temporarily. - - The s390x pipeline is unstable with the error "No output has been received" - or doesn't start. See <https://travis-ci.community/t/13811>. - -commit a0b7574e59a695475815c97dd798f745944bc2df - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-27 20:01:37 +0900 - Commit: Jun Aruga <junaruga@users.noreply.github.com> - CommitDate: 2023-10-28 02:16:13 +0900 - - .travis.yml: Simplify Travis CI. - - * Remove CI functions for make test-all. - I want to simplify the `.travis.yml` for us to maintain it easily. When we - need to skip a test, we can fix the test file directly. - I removed the `tool/ci_functions.sh` too. I confirmed the file is not used in - any other files. - * .travis.yml: Remove a notification for IRC channel. - GitHub Actions don't use this notification. The setting is outdated. - * Fix to skip the commit including the document keyword. - There were 2 `if` syntax lines in the file. - * Remove ccache. - -commit 7979c009a762d9b447f7ef286af2d314b7c11a6c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-10-28 00:00:12 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-10-28 00:00:12 +0900 - - Fix bug for removed weak references - - rb_darray_foreach gives a pointer to the entry, so we need to deference - it to read the value. - -commit 26a05c42173f0f6ad188a28c3ea508b18b376d6b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-27 11:04:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-27 23:23:17 +0900 - - [ruby/prism] Use printf attribute and then fix warnings - - https://github.com/ruby/prism/commit/3193902c43 - -commit 15ee9c7c1b693f29b6b2dbe7b47488bf154e481c - Author: Jun Aruga <junaruga@users.noreply.github.com> - AuthorDate: 2023-10-27 22:53:43 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-27 22:53:43 +0900 - - [DOC] README.md: Remove Cirrus CI badge image. (#8785) - - We removed the `.cirrus.yml` at the commit - <01b5d1d2ff6ca91b2909dfa67295f59b53e6f065>. - Let's remove the badge image too. - -commit 7e4d2bb81d3933acbde4fcd8fb849dc9e0955565 - Author: Vinicius Stock <vinicius.stock@shopify.com> - AuthorDate: 2023-10-27 05:32:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-27 22:45:53 +0900 - - [ruby/prism] Move static annotations into _static files - - https://github.com/ruby/prism/commit/9a6d735890 - -commit 06173a41dd189d869f25b049ce6e0a0be931379b - Author: Vinicius Stock <vinicius.stock@shopify.com> - AuthorDate: 2023-10-27 05:26:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-27 22:45:52 +0900 - - [ruby/prism] Add rbi_class to fields - - https://github.com/ruby/prism/commit/568fb39e2c - -commit 544f64075bc42a2935624403201c78468e180d3d - Author: Vinicius Stock <vinicius.stock@shopify.com> - AuthorDate: 2023-10-20 00:17:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-27 22:45:52 +0900 - - [ruby/prism] Add RBI and RBS templates for Prism - - https://github.com/ruby/prism/commit/b62305ff3e - - Co-authored-by: Stan Lo <st0012@users.noreply.github.com> - -commit a8af5d3808535b584b8c0a061f035f5468ba930c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-24 03:31:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-27 22:40:25 +0900 - - [ruby/prism] Use MatchWriteNode on split InterpolatedREN - - https://github.com/ruby/prism/commit/ee54244800 - -commit 934beac1182814ec785baab2a84e886f5f2859b2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-27 16:57:21 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-27 16:57:21 +0900 - - Select the destination for the latest date by whether inplace mode - -commit bba94659345acda0a0269321083181166300e899 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-27 15:17:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-27 15:17:50 +0900 - - Let bundled_gems use matzbot's token for git push - -commit a40e2b8ee9632b07064af4c99efdafda814df391 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-23 23:42:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-27 11:09:33 +0900 - - [ruby/prism] Fix parsing lone assoc splat within hash patterns - - https://github.com/ruby/prism/commit/1da5e05672 - -commit 9a618b95cdee82b64257a248c31d49ae9f066fea - Author: Lars Kanis <lars@greiz-reinsdorf.de> - AuthorDate: 2023-10-27 10:16:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-27 10:16:18 +0900 - - [Feature #19244] Windows: Prefer USERPROFILE over HOMEPATH on startup as well - -commit bbf1d621ba05b345a695df554773a6dee6106d50 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-27 05:28:25 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-27 06:49:42 +0900 - - Decrease redblack cache / shape size in debug - - When running tests in debug mode, we have tests that try to exhaust the - space used for shapes and the redblack cache. However, this can cause - Out of Memory issues on some machines, so this commit decreases the - cache sizes when RUBY_DEBUG is enabled - -commit 8e62596e38fc4a9247f306fb81c95ee85a42acbe - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-10-26 18:45:52 +0900 - Commit: Aaron Patterson <tenderlove@ruby-lang.org> - CommitDate: 2023-10-27 05:07:08 +0900 - - Move some defines from shape.h to shape.c - - If they are only used there, we might as well not expose them. - -commit 719b40bdf636ff21b3951da2843595c538ead46c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-27 04:47:01 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-27 04:47:01 +0900 - - [prism] Update prettyprint deps - -commit 6e8ff9d27570d75307e69094cee68abc4f6b74ab - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-18 03:00:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-27 04:43:17 +0900 - - [ruby/prism] Allow regexp flags to change - - https://github.com/ruby/prism/commit/88a61cc30c - -commit f3e77f36c5f821f837db8b6007c4bb298ff1678f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-27 04:40:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-27 04:40:21 +0900 - - [ruby/prism] Fix up newline test - - https://github.com/ruby/prism/commit/9fdb41d8ba - -commit 55b81e419fd527a323a8506a120d0de4d80b4a00 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-27 04:23:46 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-27 04:23:46 +0900 - - Use new prism prettyprint APIs - -commit 21dc64534b841ed905e7ea0806e125de13e2f250 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-25 01:42:16 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-27 04:19:52 +0900 - - [ruby/prism] Regenerate snapshots - - https://github.com/ruby/prism/commit/160df9a687 - -commit d1bb858d476446ab82e6caa29c061a0da734c8eb - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-25 01:28:53 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-27 04:19:43 +0900 - - [ruby/prism] Match existing Ruby prettyprint - - https://github.com/ruby/prism/commit/6d8358c083 - -commit e9aa2398b9d8eb04a0013fa5420214382ea3457a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-24 23:04:48 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-27 04:19:35 +0900 - - [ruby/prism] Get general prettyprint structure working - - https://github.com/ruby/prism/commit/7c9cf63d4c - -commit 9792be3610c62e0413bbdd878c64bbafbba3ffbd - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-10-18 19:54:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-27 04:12:04 +0900 - - [ruby/prism] Avoid warning for pm_token_buffer_t initialization - - * This was causing this error on macOS Mojave: - src/prism.c:8216:48: error: suggest braces around initialization of subobject [-Werror,-Wmissing-braces] - pm_token_buffer_t token_buffer = { 0 }; - ^ - - https://github.com/ruby/prism/commit/5055fc04fd - -commit 6241cfab74ad8a996875dc79a9b0355cf67853aa - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-27 00:37:56 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-27 04:08:31 +0900 - - [prism] handle locals consistently - -commit e3258dd627dd05e707f6f344af2073c20f45a6d6 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-27 04:03:33 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-27 04:03:33 +0900 - - Integrate new prism multi target names - -commit 018f0a9c5fda185f91edf3da797b9e1b1df14706 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-27 03:56:21 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-27 03:59:13 +0900 - - [ruby/prism] Rename to lefts/rights - - https://github.com/ruby/prism/commit/e6deed05a5 - -commit 922f48f08158332c8cf94ad37f9e307f80200bf9 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-24 02:43:22 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-27 03:59:07 +0900 - - [ruby/prism] Remove RequiredDestructuredParameterNode in favor of MultiTargetNode - - https://github.com/ruby/prism/commit/6d1858192e - -commit 533bd1d1fa1bc0a9de1f8818b3a3275e9d50e6cc - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-24 01:59:41 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-27 03:59:00 +0900 - - [ruby/prism] Ensure no extra multi-target nodes are created for splats - - https://github.com/ruby/prism/commit/e60240d54b - -commit 82acca915afedbef22d1a791fac43f50c71294d5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-24 01:30:14 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-27 03:58:55 +0900 - - [ruby/prism] Ensure no extra multi-target nodes are created - - https://github.com/ruby/prism/commit/ec31fd827f - -commit 234e8fb819f0fc1d6f05a02976ae1c01e6cace2d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-24 01:06:21 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-27 03:58:48 +0900 - - [ruby/prism] Split up multi target/write targets - - https://github.com/ruby/prism/commit/dda7a0da52 - -commit 7e4ee92de225473d3ad3ac8d0a27bd02a2905738 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-27 03:02:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-27 03:47:50 +0900 - - [ruby/prism] Add KeywordSplat flag to ArgumentsNode - - Method calls with keyword splat args compile differently than - without since they merge the keyword arg hash with the keyword splat - hash. We know this information at parse time, so can set a flag - which the compiler can use. - - https://github.com/ruby/prism/commit/e5f8a9a3cd - -commit a082e560bb3b875dfcce5ff4743a04e76e008d46 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-10-25 02:17:18 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-27 03:11:52 +0900 - - [PRISM] Implement regex encoding flags - - Added the correct encoding to the allocated regex. This required making - a new method to set the encoding and pass that to `rb_enc_reg_new` - instead of `rb_reg_new`. The former `rb_reg_new` would set the encoding - to ASCII8BIT regardless of encoding flag. - -commit 2573d568848f1dc54e6fb4d9ce203d75cc31fc3d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-27 00:46:19 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-27 01:29:04 +0900 - - [PRISM] Change --dump keyword to prism_parsetree - -commit b57b7acc20f46b77809d9882ba3fc9169c2610ce - Author: lukeg <luke.gru@gmail.com> - AuthorDate: 2023-01-13 02:05:07 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-27 01:07:12 +0900 - - add more shapes tests - -commit 4f8a33eb055d5fed76851ac8194851ffb8f79b48 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-27 00:03:18 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-27 00:47:28 +0900 - - [PRISM] Cleanup macro usage for common ADD_INSN - -commit 8f4a8cd05b95861b59ba70c59c2a12cdb16dde73 - Author: HParker <HParker@github.com> - AuthorDate: 2023-10-25 17:07:26 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 23:54:26 +0900 - - teach prism define to compile basic types - -commit 9570a88bb3c86c79a25562a341452002be457c12 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-26 19:02:55 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 23:42:15 +0900 - - [PRISM] Implement compilation for ConstantPathAndWriteNode - -commit ec2878c11bb0b5549c49ef2ae842a886c3905aa9 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-26 18:57:05 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 23:42:15 +0900 - - [PRISM] Implement compilation for ConstantPathOrWriteNode - -commit b5f61750b94e7f9c16876f6a5e9e97e066ea5d18 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-26 03:00:24 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 23:42:15 +0900 - - [PRISM] Implemented ConstantPathOperatorWriteNode - -commit 631ddb34e4479259acbfa42b8d19cc03464da8f3 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-10-12 23:54:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-26 23:34:41 +0900 - - [ruby/prism] Split Prism::Loader#load_node in one lambda per node type - - * Otherwise load_node is too big to compile and is forced to run in interpreter: - https://github.com/oracle/truffleruby/issues/3293#issuecomment-1759730996 - * For the benchmark at https://github.com/oracle/truffleruby/issues/3293#issuecomment-1759790280 - TruffleRuby Native 23.1.0: - Before: 10.574041 After: 5.592436 - JRuby 9.4.3.0: - Before: 7.037780 After: 3.995317 - JRuby 9.4.3.0 -Xcompile.invokedynamic=true: - Before: 7.047832 After: 2.269294 - - https://github.com/ruby/prism/commit/a592ec346a - -commit 51ea82a7701afea79f5137445a28e8dfdf832e46 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-18 02:02:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-26 22:58:40 +0900 - - [ruby/prism] Expose options on match last line nodes - - https://github.com/ruby/prism/commit/0284b38861 - -commit 3ed317a441d5a66a56a41bc28399137d0012f3ae - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-26 22:44:32 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-26 22:50:40 +0900 - - Remove JavaScript templates - -commit feb1427ad8f3d6448d9f8d0c7009dfdf711b7f48 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-25 03:23:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-26 22:33:22 +0900 - - [ruby/prism] Compile with WASI - - https://github.com/ruby/prism/commit/73c44b0b9c - -commit bfb9b5e69921c91901cce820f54e79907a5ae829 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-25 03:24:36 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 20:45:43 +0900 - - [PRISM] Implement compilation for CaseNode - -commit 7b6b17a92b3006266375e9de4310e1937c182523 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-26 05:30:51 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 19:15:35 +0900 - - [PRISM] Rename new tests to use `assert_prism_eval` - -commit d6cb2dc6225dd544ca943e09df755a26324763a5 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-26 02:14:43 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 19:15:35 +0900 - - [PRISM] Refactor tests to deconflict with existing tests - -commit 8e5744588f9e04273f4c37268c9954c9174be671 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-26 00:58:45 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 19:15:35 +0900 - - [PRISM] Implement CallOperatorWriteNode - -commit 68a81b44e3907f2ceb4dc3864e65b565c42d1c63 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-26 00:40:30 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 19:15:35 +0900 - - [PRISM] Implement compilation for CallOrWriteNode - -commit e28a03303540d9554fe669a67b329d2414d0456c - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-26 00:34:03 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 19:15:35 +0900 - - [PRISM] Extract helper to use for CallOrWriteNode - -commit 2a8dbb1323a9ac8004d61efdfcba3ad2064d3d83 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-26 00:20:07 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 19:15:35 +0900 - - [PRISM] Implemented compilation for CallAndWriteNode - -commit 73d7fd8614e6ef3f55911932af96da908aa04bf8 - Author: Lars Kanis <lars@greiz-reinsdorf.de> - AuthorDate: 2022-12-27 08:34:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-26 19:00:54 +0900 - - Windows: Prefer USERPROFILE over HOMEPATH - - Enable the test commented out in ruby/ruby@d0f5dc9eac78ecade459. - Extracted from GH-7033, that is for initialization at start up time - and this test is unrelated to it. - -commit e74ea904ad29931c476b3af493e3ee089f5b4afa - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-10-26 18:56:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-26 18:56:21 +0900 - - [ruby/zlib] Check for z_size_t along with {crc,adler}32_z in - extconf.rb - (https://github.com/ruby/zlib/pull/69) - - The android NDK (android-ndk-r21e) does not have crc32_z, adler32_z, nor - z_size_t in its zlib.h header file. However, it _does_ have the crc32_z - and adler32_z symbols in the libz.a static library! - - mkmf performs two tests for have_func: - * It sees if a program that includes the header and takes the address of - the symbol can compile - * It sees if a program that defines the symbol as `extern void sym_name()` - and calls it can be linked - - If either test works, it considers the function present. The - android-ndk-r21e is passing the second test but not the first for - crc32_z/adler32_z. So, we define HAVE_ZLIB_SIZE_T_FUNCS, but then can't - actually compile the extension (since the prototypes aren't in the - header file). - - We can keep this working how it was working before by _also_ checking - for `have_type("z_size_t", "zlib.h")`. The have_type check _only_ looks - in the header file for the type; if a program including the header file - and using the type can't compile, the type is considered absent - regardless of what might be in libz.a. - - https://github.com/ruby/zlib/commit/3b9fe962d8 - -commit 701ca070b4c6fd334543c69e863c40c70178521c - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-26 14:29:20 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-26 14:30:17 +0900 - - Prevent a warning: assigned but unused variable - z - -commit ab9659620fb6607ac2e27ac143acbdafc36a4849 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-26 18:03:58 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-26 18:03:58 +0900 - - Revert "[ruby/prism] Use `cargo fmt`" - - This reverts commit 4259d5b5aefd58d0bf86ad20122beee53533ff59. - - This commits is wrong result of sync_default_gems.rb - -commit 825fbaa6df6ae3fdcc5a8a854882c4549924c52d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-26 16:52:17 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-26 17:28:50 +0900 - - [Feature #19362] [DOC] Add to NEWS.md - -commit 1507118f0b70fc8002b4b0f186b464c64965cd1e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-22 11:40:37 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-26 17:28:50 +0900 - - [Feature #19362] Call `#initialize_dup` hook at `Proc#dup` - -commit 7d159a87873d72027a8230d9cb63698d1f3c5cac - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-26 07:54:47 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-26 17:15:38 +0900 - - Lrama v0.5.8 - -commit c8d162c889008028b148437d02f36f4edaa749fd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-26 14:28:39 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-26 14:28:39 +0900 - - [Bug #19973] Warn duplicated keyword arguments after keyword splat - -commit 634e0ac140d890904c59eab8bdec09b80c78b1a4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-26 12:03:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-26 12:39:13 +0900 - - Fix test failure with __runner_options__ renaming - -commit 7717684d164d8ff8beece61170f0083c7dcb45fd - Author: lukeg <luke.gru@gmail.com> - AuthorDate: 2023-03-16 01:53:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-26 12:39:13 +0900 - - tool test/unit/testcase: rename vars @passed, @@current - - to @__passed__, @@__current__. - @passed is redefined in a few test suites, and this could lead to bugs. - - Also rename @options (Runner#options) to @__runner_options__, which is - only used in make test-tool anyway. - -commit ad06addbfe7e5c22b8cb75ebb85fffbeeda4a71c - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2022-04-17 01:17:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-26 12:20:27 +0900 - - [wasm] Check exts build working on ci - - This is a preparation for enabling spec test - -commit ac4d687656b0350879ea2e033d2f13d1765a7ce3 - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-10-16 07:45:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-26 11:17:54 +0900 - - [ruby/zlib] Fix misdetection of {crc32,alder32}_z in cloudflare zlib fork - - We use the Cloudflare fork of zlib - (https://github.com/cloudflare/zlib), which we find gives improved - performance on AWS Graviton ARM instances. That fork does not define - crc32_z and alder32_z functions. - - Until two days ago, Ruby's zlib gem worked fine, because cloudflare zlib - _also_ did not define z_size_t, which meant Ruby did not try and use - these functions. - - Since https://github.com/cloudflare/zlib/commit/a3ba99596d6271224d39ef9d6853511f51821e05 - however, cloudflare zlib _does_ define z_size_t (but NOT crc32_z or - alder32_z). The zlib gem would try and use these nonexistant - functions and not compile. - - This patch fixes it by actually specifically detecting the functions - that the gem wants to call, rather than just the presence of the - z_size_t type. - - https://github.com/ruby/zlib/commit/c96e8b9a57 - -commit 3ef7b632a07025472ac7a7f18f6433c089d7be88 - Author: fn ⌃ ⌥ <70830482+FnControlOption@users.noreply.github.com> - AuthorDate: 2022-01-07 06:19:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-26 10:56:47 +0900 - - Make beginless Range#size return nil if it ends with non-numeric - -commit 4259d5b5aefd58d0bf86ad20122beee53533ff59 - Author: Ian Ker-Seymer <ian.kerseymer@shopify.com> - AuthorDate: 2023-10-25 14:14:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-26 10:18:43 +0900 - - [ruby/prism] Use `cargo fmt` - - https://github.com/ruby/prism/commit/5969b827ae - -commit 0164ce893f0a683a8555072ac594401a33990d40 - Author: Michael Chui <saraid@users.noreply.github.com> - AuthorDate: 2018-10-19 07:42:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-26 10:12:49 +0900 - - add #to_str to URI::Generic - -commit b5f6e2a7c4c5119d9518a51e37d94418ec8f55f6 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-26 05:37:37 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 06:18:35 +0900 - - [PRISM] ScopeNode doesn't need void * anymore - -commit 8f71a5c53007b072341775e4161ec20b50ffc538 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-25 23:23:57 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 06:18:35 +0900 - - [PRISM] Move scope_node itself to CRuby, create prism_compile.h - -commit 0abf2d86b963089a52af9ee221d1b7da7ba9b2ee - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-25 04:54:44 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 06:18:35 +0900 - - [PRISM] Move pm_scope_node_init to prism_compile.c - - pm_scope_node_init is only used for CRuby, so should not live in the - ruby/prism repo. We will merge the changes here first so they're - not breaking, and will then remove from ruby/prism - -commit f87c31f3e061fc1ac6435a7f32be18e39d6abc06 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-25 05:08:50 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 05:27:00 +0900 - - [PRISM] Add PM_POP macro, cleanup missing macro usage - -commit 0a3eba0bf7312eaadf1af3ce58939a5c6855f6df - Author: HParker <HParker@github.com> - AuthorDate: 2023-10-26 04:06:58 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-26 04:51:20 +0900 - - Fix few test_prism_eval that snuck in - -commit 3fe2f2689f0074a4c880218ca08cb10137880760 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-10-25 01:18:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-26 03:52:38 +0900 - - [rubygems/rubygems] Raise exception on unexpected EOF in marshal - - Instead of NoMethodError being raised by accidentally trying to use nil - - https://github.com/rubygems/rubygems/commit/ac8f812bbf - -commit 7e7d1f0679d7cbfc43d4157435317ae2f961b995 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-10-25 01:23:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-26 03:51:37 +0900 - - [rubygems/rubygems] Avoid regexp match on every call to `Gem::Platform.local` - - The result of `arch` would be ignored if `@local` is set, so wrap all - the logic in `@local ||=` to short-circuit everything - - https://github.com/rubygems/rubygems/commit/b67d39f3e0 - -commit b0a970736491a8a5a1839ff698b85bbab676ba56 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-10-25 22:18:54 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-26 03:00:13 +0900 - - Use `assert_prism_eval` over `test_prism_eval` in helper - - When we use `test_prism_eval`, failed tests will point to the line - number of the `test_prism_eval` method definition instead of the test - that failed. If we use `assert_prism_eval` instead, failed tests will - properly poin to the test that failed because the test framework knows - to stop the backtrace earlier. - - Before line number in failure points to helper definition: - - ``` - Prism::TestCompilePrism#test_RegularExpressionNode = 0.21 s - 1) Failure: - Prism::TestCompilePrism#test_RegularExpressionNode [test/ruby/test_compile_prism.rb:755]: - </pit/> (Windows-31J) expected but was - </pit/> (US-ASCII). - ``` - - After line number in failure points to test that failed: - - ``` - Prism::TestCompilePrism#test_RegularExpressionNode = 0.00 s - 1) Failure: - Prism::TestCompilePrism#test_RegularExpressionNode [test/ruby/test_compile_prism.rb:334]: - </pit/> (Windows-31J) expected but was - </pit/> (US-ASCII). - ``` - -commit fa3cc4afcbdebfbf1485a7808189baba54e5eb79 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-10-25 07:12:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-26 02:24:06 +0900 - - [rubygems/rubygems] Set file path when eval-ing local specification in EndpointSpecification - - Not strictly necessary, but there is no reason not to be helpful and set the path - - https://github.com/rubygems/rubygems/commit/894c0303dd - -commit 8197bbb0a9c6f774c6906036a25f748db2b1d3e1 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-24 20:42:51 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 01:02:44 +0900 - - [PRISM] Toggled accepts_no_kwarg to true on NoKeywordsParameterNode - -commit fb0a30166d4a53c09d9544eba53901f7f736a201 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-23 23:28:04 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 01:02:44 +0900 - - [PRISM] Add tests for ParametersNode - -commit fe0827013b8bfda45419f375e817b2259e2c8b8f - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-23 23:24:35 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-26 01:02:44 +0900 - - [PRISM] Implement NoKeywordsParameterNode - -commit 2f8a719b6aa8b1e652d5e4114a811cf0a12f0f34 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2017-07-15 16:18:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-25 21:40:41 +0900 - - Removed unused argument - - Eventually, `read_escape` does not use `encp`. - -commit f26d53e90533232ac35ca0eae2ca7766c2af5ebb - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-25 20:37:21 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-25 20:37:21 +0900 - - Reduce the number of times IO is passed in send_io/recv_io test - - Since Linux 4.5, sendmsg(2) fails with ETOOMANYREFS if the number of - "in-flight" IOs, which has been sent by sendmsg(2) but has not yet - accepted by recvmsg(2), exceeds the RLIMIT_NOFILE resource limit. - - https://rubyci.s3.amazonaws.com/arm64-neoverse-n1/ruby-master/log/20231025T090004Z.fail.html.gz - ``` - 1) Error: - TestSocket_UNIXSocket#test_fd_passing_race_condition: - Errno::ETOOMANYREFS: Too many references: cannot splice - sendmsg(2) - ``` - - This change reduces the number of times of IO passing under 1024, - which is a default limit in many environments. - -commit de82439215dd2770ef9a3a2cf5798bdadb788533 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-25 20:04:18 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-25 20:04:18 +0900 - - Do not use pthread_setaffinity_np on s390x - - Looks like it randomly causes a segfault - - https://rubyci.s3.amazonaws.com/rhel_zlinux/ruby-master/log/20231025T093302Z.fail.html.gz - ``` - [11186/26148] TestNetHTTP_v1_2#test_set_form/home/chkbuild/build/20231025T093302Z/ruby/tool/lib/webrick/httprequest.rb:197: [BUG] Segmentation fault at 0x000003ff1ffff000 - ruby 3.3.0dev (2023-10-25T07:50:00Z master 526292d9fe) [s390x-linux] - ``` - -commit 1649486834a6d195623bbf6820f06eaeb26567a5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-25 18:49:37 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-25 18:49:37 +0900 - - Fixup 5461bc18f88 - -commit bf1362306e2c799b0e5ff222b0cdcdb8644adc27 - Author: OKURA Masafumi <masafumi.o1988@gmail.com> - AuthorDate: 2023-07-19 17:38:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-25 16:49:09 +0900 - - [Doc] Improve documentation of PP - - * Remove mention to `require 'pp'` for `pretty_inspect` - * Mention the need to add `require 'pp'` to customize - `#pretty_print(pp)` method - -commit 5461bc18f88f7f335f6456774498efd386c3012f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-25 16:47:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-25 16:47:26 +0900 - - omit failing test at arm64-neoverse-n1 - -commit 593de2b048ee1d5aa290e3fc630e64116f3fe943 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-04-26 15:45:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-25 16:34:48 +0900 - - Add tests for passing nil to Comparable#clamp(min, max) - -commit 55eb0d5c780e65139911569cc470b82b0c3b39a0 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-04-12 09:49:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-25 16:34:37 +0900 - - [DOC] Add doc for behavior when passing nil to Comparable#clamp(min, max) - -commit 3e64cf60b5162bb5dad772f300b7f6346e5f83f9 - Author: Hiroya Fujinami <make.just.on@gmail.com> - AuthorDate: 2023-10-25 16:32:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-25 16:32:25 +0900 - - Fix [Bug #19632]: Disable external iterator for frozen enumerator (#7791) - - * Fix [Bug #19632]: Disable external iterator for frozen enumerator - - Currently, methods to manipulate an external iterator like `#next` - and `#feed` can be called even if a receiver of an enumerator is - frozen. However, these methods change the state of an external - iterator in an enumerator. Therefore, it seems a BUG to me, and - these methods should raise FrozenError if the receiver is frozen. - - This fixed the following methods to raise FrozenError if the receiver is - frozen. - - - `Enumerator#next` - - `Enumerator#next_values` - - `Enumerator#peek` - - `Enumerator#peek_values` - - `Enumerator#feed` - - `Enumerator#rewind` - - * Fix a typo in the document - - Thanks @Maumagnaguagno. - -commit c5861903ac5f89cafb131400835b2e3b207ba928 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-24 21:07:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-25 09:46:09 +0900 - - [rubygems/rubygems] Handle CI configuration on ignore list for Gem::Specification#files - - https://github.com/rubygems/rubygems/commit/4bb0ef3e55 - -commit 820957b1ee43f296098197441680ce01f7ee1924 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-24 18:42:42 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-25 08:12:48 +0900 - - Remove unused macro - - `struct RNode_OP_ASGN22` was removed by 37a783a. - -commit a2badf306661a88ce3001077520655e2b9c6b27c - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-24 18:54:48 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-25 07:38:01 +0900 - - Follow up NODE_OP_ASGN2 structure change - -commit d8cb827f39d4c72d2a79e40371ba2a4fb3e95b28 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-25 04:43:22 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 06:23:17 +0900 - - Remove SHAPE_MAX_NUM_IVS - - There is no longer a limit on the number of IVs you can store. - SHAPE_MAX_NUM_IVS was used to work around the IV10K problem (the well - known problem where setting 10k instance variables in a row would be too - slow). The redblack tree works well at any shape depth, even depths - greater than 80, and solves the IV10K problem. - -commit 33bebee13aedb9f8a0d43cc6921910a690e6f73e - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-25 04:38:50 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 06:23:17 +0900 - - Use available constants - - We don't need to intern "initialize" all the time because we already - have `idInitialize` available - -commit afae8df373ba1b53b64bffa0e3df668d86585243 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-25 04:37:27 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 06:23:17 +0900 - - `get_next_shape_internal` should always return a shape - - If it runs out of shapes, or new variations aren't allowed, it will - return "too complex" - -commit cfd7c1a2763d727f8a578da27317b55111aa6894 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-25 04:20:46 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 06:23:17 +0900 - - Allow the shape tree to be traversed - - This commit allows the shape tree to be traversed to locate an existing - shape, but it doesn't necessarily allow you to create new variations. - -commit 3760baccac55a03b850072ba7daf611ed8883687 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-25 04:05:05 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 06:23:17 +0900 - - Remove new_shape_necessary code - - We always create new shapes until we run out! - -commit 702b8e3107a91f1a3ca230e68a9ef4086a8869b5 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-25 03:59:48 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 06:23:17 +0900 - - golf down ancestor caching - -commit ee8299864f6556926fdcf85a52b2d9080446ee81 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-25 04:35:07 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-25 04:35:07 +0900 - - Remove erroneous test_code.rb file - -commit 10756f3dea368bc5a10de57b4809aa4867c8e460 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-25 00:05:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-25 03:34:36 +0900 - - [ruby/prism] Add PostExecutionNode to pm_scope_node_init - - https://github.com/ruby/prism/commit/88fe6213af - -commit e71f343a99739fda900108c86c6b87182cbdbd1c - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-25 00:46:54 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 02:52:06 +0900 - - Addressing feedback - -commit 884c3195d910739d5c340a1b890d0500340a9463 - Author: Aaron Patterson <aaron.patterson@gmail.com> - AuthorDate: 2023-10-24 12:06:28 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 02:52:06 +0900 - - Update benchmark/vm_ivar_ic_miss.yml - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit dc81432482efa8d74d25f41993d95a8ca68f8128 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-24 08:57:31 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 02:52:06 +0900 - - updating bindgen - -commit 54230dea1b54990a4b046dd9a7052aba9c33f383 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-24 05:53:42 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 02:52:06 +0900 - - Don't cache on platforms without mmap - - We're only going to create a redblack tree on platforms that have mmap - -commit a3f66e09f6596259677f00255a9b6231a2739774 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-20 08:01:35 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 02:52:06 +0900 - - geniv objects can become too complex - -commit caf6a72348431e0e6b61be84919cd06c7a745189 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-20 03:00:54 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 02:52:06 +0900 - - remove IV limit / support complex shapes on classes - -commit 27c75319396b8e9fa43b33aca99725b7352a6dcb - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-13 06:43:30 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 02:52:06 +0900 - - increase the maximum number of ivs - -commit 84e4453436c3549b4fda6014cdd5fcc9e0b80755 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-02-08 10:46:42 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-25 02:52:06 +0900 - - Use a functional red-black tree for indexing the shapes - - This is an experimental commit that uses a functional red-black tree to - create an index of the ancestor shapes. It uses an Okasaki style - functional red black tree: - - https://www.cs.tufts.edu/comp/150FP/archive/chris-okasaki/redblack99.pdf - - This tree is advantageous because: - - * It offers O(n log n) insertions and O(n log n) lookups. - * It shares memory with previous "versions" of the tree - - When we insert a node in the tree, only the parts of the tree that need - to be rebalanced are newly allocated. Parts of the tree that don't need - to be rebalanced are not reallocated, so "new trees" are able to share - memory with old trees. This is in contrast to a sorted set where we - would have to duplicate the set, and also resort the set on each - insertion. - - I've added a new stat to RubyVM.stat so we can understand how the red - black tree increases. - -commit 5c4978c11c4ea9569d5d99a86936fbef0ab7fa52 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-24 16:22:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-25 01:31:43 +0900 - - [rubygems/rubygems] Handle empty array - - https://github.com/rubygems/rubygems/commit/7c0afdd9af - -commit c86c6a84f53a21330702ebd21cc1a65d7776171d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-24 22:21:21 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-24 22:59:09 +0900 - - [Bug #19968] Revert RBS revision to test - - This reverts the commits for the master branch of RBS: - - - commit f717faac632dd8664d0967f8e639b84d5d032854: "Update rbs - revision to test" - - The target revision to test is in master branch, not for 3.2.x. - - - commit 9e93af5329f35092c3de3ea37d4e9e181b800bb2: "Skip RBS - `RbConfig::TOPDIR` test that is `nil` before installation" - - RbConfig_test.rb is not updated in 3.2.x branch. - -commit 25c1204fe730868e63919820ce0ab372768f6188 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-19 14:33:32 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-24 12:22:53 +0900 - - rb_getaddrinfo should return EAI_AGAIN instead of EAGAIN - -commit c08020254ef841c9ca233445e6cd1d0cf49e2756 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-19 14:14:31 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-24 12:22:53 +0900 - - Indent critical regions with blocks - - Cosmetic change per ko1's preference - -commit acd774263c17889d81e940ca7d1c935c9109c7b7 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-18 21:14:27 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-24 12:22:53 +0900 - - Do not use pthread on mingw - -commit 16d6a22757e064806284d86337997762a50bf6a6 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-18 19:46:40 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-24 12:22:53 +0900 - - Make rb_getnameinfo interruptible - - Same as previous commit for rb_getnameinfo. - -commit 3dc311bdc8badb680267f5a10e0c467ddd9dfe4c - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-18 18:48:29 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-24 12:22:53 +0900 - - Make rb_getaddrinfo interruptible - - When pthread_create is available, rb_getaddrinfo creates a pthread and - executes getaddrinfo(3) in it. The caller thread waits for the pthread - to complete, but detaches it if interrupted. This allows name resolution - to be interuppted by Timeout.timeout, etc. even if it takes a long time - (for example, when the DNS server does not respond). [Feature #19965] - -commit efd58f19ea473ac34d27658997eee6af3521e1d9 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-18 16:32:38 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-24 12:22:53 +0900 - - Expand macro branches to make them plain - -commit 25ef8d262a267d608aa3ac74481b3c3abd75ee34 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-18 16:19:51 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-24 12:22:53 +0900 - - Refactor GETADDRINFO_IMPL instead of GETADDRINFO_EMU - - This is a preparation for introducing cancellable - getaddrinfo/getnameinfo. - -commit 9ce607a8d4944de3ebda23d7879bb60fa74121f0 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-18 15:51:49 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-24 12:22:53 +0900 - - refactor a call to getaddrinfo - -commit 30f5a2bbcd0151ce25b1e55dcff31626d4ab253a - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2022-06-25 22:13:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-24 07:53:00 +0900 - - [ruby/io-nonblock] Don't define nonblock methods if they are defined by core. - - https://github.com/ruby/io-nonblock/commit/5d3991859c - -commit 39207b496eb1f45750bc664c8796f5aa3f5d641e - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-24 02:49:39 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-24 05:22:55 +0900 - - [PRISM] Implement compilation for PreExecutionNodes - -commit 5abff9dbff4f2e50b4b65fa00438a5e67bfd7c49 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-23 22:46:37 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-24 05:22:55 +0900 - - [PRISM] Add PM_PUTNIL macro - -commit 7c4e3ca27b0263dff770fc52a451a00a30e5aa9d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-23 22:33:38 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-24 05:15:52 +0900 - - [PRISM] Fix AssocSplat node - - This commit emits the correct instructions for hashes which have - both AssocSplat and Assoc nodes contained within them - -commit 062d6050b05dba8c0cc915e83a05a418a1c8ab1d - Author: dearblue <dearblue@users.osdn.me> - AuthorDate: 2023-10-23 23:49:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-24 04:52:22 +0900 - - [rubygems/rubygems] Ignore non-tar format `.gem` files during search - - Previously, `rake install` or `rake update` would fail if there was a non-tar format `.gem` file in the current working directory. - - https://github.com/rubygems/rubygems/commit/f562788f1d - -commit 60196b4780954841617f9aef796566e0d28a3ec1 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-24 00:29:48 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-24 01:59:48 +0900 - - [PRISM] Fix __LINE__ to be 1-indexed by default - -commit f9e122b3d65ec00cb501fd8d3df175c8453f261f - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-21 00:25:26 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-24 01:59:48 +0900 - - [PRISM] Add several tests - -commit 62c674f98cc74b4f1be1b909d69523f95bffe59f - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-21 00:03:02 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-24 00:37:50 +0900 - - [PRISM] Fix compilation for IfNode, UnlessNode - - This properly implements the branch condition for FlipFlopNodes on - If / UnlessNodes, and also fixes the bug in UnlessNodes - -commit 296da1a2b8fdcd8d420ced94ab553b7d3fa517d9 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-24 00:30:38 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-24 00:30:38 +0900 - - [PRISM] Add tests for BlockNode, BlockLocalVariableNode, BlockParamet… (#8725) - - [PRISM] Add tests for BlockNode, BlockLocalVariableNode, BlockParametersNode - -commit f20e91fbf70a28b54bf4bf0f8bb5783572f8dd70 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-10-21 15:20:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-23 23:56:18 +0900 - - [ruby/prism] Avoid String#chars in DedentingHeredoc#to_a - - Prefer String#[] directly. - - https://github.com/ruby/prism/commit/916f991220 - -commit f82d0ab5d117cf2e7cac8fd84a25ba7077da8947 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-10-19 01:27:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-23 21:50:14 +0900 - - [ruby/prism] Exclude comments when only serializing semantic fields - - https://github.com/ruby/prism/commit/6f4fab362e - -commit 839b763119d4953f7f426d939ee112e0daf1333d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-23 15:18:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-23 17:40:33 +0900 - - Use named reference for dyna_push - -commit 7e80f0b5a2eefc8599990a8ec826c555d2378374 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-23 15:16:25 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-23 17:40:33 +0900 - - Extract p_in_kwarg to save and update lexer contexts - -commit 428f9f5dc067f73e553f9947c587a8bdd53972be - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-23 15:08:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-23 17:40:33 +0900 - - Move push_pvtbl and push_pktbl in nterms - -commit 3b05238289b973af3d5ff73d750ba243c0c2fa3f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-23 14:15:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-23 17:40:33 +0900 - - Extract p_assoc and p_in to save lexer contexts - -commit df5bf5bb591af2d5382fb7746489bfd1d4b7df81 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-23 17:27:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-23 17:28:50 +0900 - - Removed unnecessary libraries of sync_tool - -commit 9844371c6f2243a5edddbc01204321034e21ba04 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-23 17:09:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-23 17:22:27 +0900 - - sync_tool is unnecessary now. - - We can use https://github.com/ruby/test-unit-ruby-core for testing the default gems. - -commit e6fcf07a6f3e50ca9f7698f70e536ad72fde8d92 - Author: ydah <13041216+ydah@users.noreply.github.com> - AuthorDate: 2023-10-23 14:11:00 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-23 17:04:27 +0900 - - Use `-H` option instead of `-h` option - - Follow up: https://github.com/ruby/lrama/pull/139 - -commit 8942c73e6a19a6a102eedf295cc6a924c08d0af1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-23 14:57:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-23 16:59:08 +0900 - - [rubygems/rubygems] Disabled Style/HashSyntax for keyword arguments - - https://github.com/rubygems/rubygems/commit/9b61b33568 - -commit e5364ea496a193560c0dc339f82a67674d26fee2 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-10-10 22:32:12 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-10-23 16:33:15 +0900 - - rb_shape_transition_shape_capa: use optimal sizes transitions - - Previously the growth was 3(embed), 6, 12, 24, ... - - With this change it's now 3(embed), 8, 16, 32, 64, ... by default. - - However, since power of two isn't the best size for all allocators, - if `malloc_usable_size` is vailable, we use it to discover the best - offset. - - On Linux/glibc 2.35 for instance, the growth will be 3(embed), 7, 15, 31 - to avoid wasting 8B per object. - - Test program: - - ```c - - size_t test(size_t slots) { - size_t allocated = slots * VALUE_SIZE; - void *test_ptr = malloc(allocated); - size_t wasted = malloc_usable_size(test_ptr) - allocated; - free(test_ptr); - fprintf(stderr, "slots = %lu, wasted_bytes = %lu\n", slots, wasted); - return wasted; - } - - int main(int argc, char *argv[]) { - size_t best_padding = 0; - size_t padding = 0; - for (padding = 0; padding <= 2; padding++) { - size_t wasted = test(8 - padding); - if (wasted == 0) { - best_padding = padding; - break; - } - } - - size_t index = 0; - fprintf(stderr, "=============== naive ================\n"); - - size_t list_size = 4; - for (index = 0; index < 10; index++) { - test(list_size); - list_size *= 2; - } - - fprintf(stderr, "=============== auto-padded (-%lu) ================\n", best_padding); - - list_size = 4; - for (index = 0; index < 10; index ++) { - test(list_size - best_padding); - list_size *= 2; - } - - fprintf(stderr, "\n\n"); - return 0; - } - ``` - - ``` - ===== glibc ====== - slots = 8, wasted_bytes = 8 - slots = 7, wasted_bytes = 0 - =============== naive ================ - slots = 4, wasted_bytes = 8 - slots = 8, wasted_bytes = 8 - slots = 16, wasted_bytes = 8 - slots = 32, wasted_bytes = 8 - slots = 64, wasted_bytes = 8 - slots = 128, wasted_bytes = 8 - slots = 256, wasted_bytes = 8 - slots = 512, wasted_bytes = 8 - slots = 1024, wasted_bytes = 8 - slots = 2048, wasted_bytes = 8 - =============== auto-padded (-1) ================ - slots = 3, wasted_bytes = 0 - slots = 7, wasted_bytes = 0 - slots = 15, wasted_bytes = 0 - slots = 31, wasted_bytes = 0 - slots = 63, wasted_bytes = 0 - slots = 127, wasted_bytes = 0 - slots = 255, wasted_bytes = 0 - slots = 511, wasted_bytes = 0 - slots = 1023, wasted_bytes = 0 - slots = 2047, wasted_bytes = 0 - ``` - - ``` - ========== jemalloc ======= - slots = 8, wasted_bytes = 0 - =============== naive ================ - slots = 4, wasted_bytes = 0 - slots = 8, wasted_bytes = 0 - slots = 16, wasted_bytes = 0 - slots = 32, wasted_bytes = 0 - slots = 64, wasted_bytes = 0 - slots = 128, wasted_bytes = 0 - slots = 256, wasted_bytes = 0 - slots = 512, wasted_bytes = 0 - slots = 1024, wasted_bytes = 0 - slots = 2048, wasted_bytes = 0 - =============== auto-padded (-0) ================ - slots = 4, wasted_bytes = 0 - slots = 8, wasted_bytes = 0 - slots = 16, wasted_bytes = 0 - slots = 32, wasted_bytes = 0 - slots = 64, wasted_bytes = 0 - slots = 128, wasted_bytes = 0 - slots = 256, wasted_bytes = 0 - slots = 512, wasted_bytes = 0 - slots = 1024, wasted_bytes = 0 - slots = 2048, wasted_bytes = 0 - ``` - -commit e7d845b1d0154651962f34eefb37ffb0ac0c4e0a - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-16 17:36:37 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-23 13:59:01 +0900 - - [rubygems/rubygems] Restore using old way of passing Ruby version to resolver - - We used `Bundler::RubyVersion.system.gem_version` for a long time, but I - changed this to `Gem.ruby_version` at - https://github.com/rubygems/rubygems/commit/94f96439438e. It's unclear why I did that - though since I believe it was unrelated to the fix in there. - - Bootboot patches `Bundler::RubyVersion` to customize how Bundler works - with Ruby versions, and that change broke that. - - Since it's unclear to me how to achieve what Bootboot is doing with the - current code, and there was no strong reason for the change, let's - restore it for now. - - https://github.com/rubygems/rubygems/commit/8ec36c6017 - -commit 6dcd4e90d8d2a2db06a140cf10c5d9519360fc69 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-10-21 12:16:24 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-23 13:59:01 +0900 - - [rubygems/rubygems] Handle base64 encoded checksums in lockfile for future compatibility. - - Save checksums using = as separator. - - https://github.com/rubygems/rubygems/commit/a36ad7d160 - -commit c667de72ff9de195e1cab4b1937973e841ff89ae - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-09-02 07:15:49 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-23 13:59:01 +0900 - - [rubygems/rubygems] Improve errors and register checksums reliably - - Improve error reporting for checksums, raises a new error class. - - Solve for multi-source checksum errors. - - Add CHECKSUMS to tool/bundler/(dev|standard|rubocop)26_gems.rb - - https://github.com/rubygems/rubygems/commit/26ceee0e76 - - Co-authored-by: Samuel Giddins <segiddins@segiddins.me> - -commit 6362bfdc337c1929a381734ded417b796f9767bf - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-09-04 00:17:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-23 13:59:01 +0900 - - [rubygems/rubygems] rename Index#== to Index#subset? - - https://github.com/rubygems/rubygems/commit/a96a561087 - -commit 92f23a48e3bb7555ca99fc49e15b250a70f9d086 - Author: Martin Emde <martinemde@users.noreply.github.com> - AuthorDate: 2023-08-31 07:15:52 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-23 13:59:01 +0900 - - [rubygems/rubygems] Refactor Checksum classes and methods to reduce - code. - (https://github.com/rubygems/rubygems/pull/6917) - - https://github.com/rubygems/rubygems/commit/2238bdaadc - -commit c5fd94073ff2e22b6eea29c242c7e4a12ed7c865 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-10 05:45:56 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-23 13:59:01 +0900 - - [rubygems/rubygems] Refactor to checksums stored via source - - This gets the specs passing, and handles the fact that we expect - checkums to be pinned only to a particular source - - This also avoids reading in .gem files during lockfile generation, - instead allowing us to query the source for each resolved gem to grab - the checksum - - Finally, this opens up a route to having user-stored checksum databases, - similar to how other package managers do this! - - Add checksums to dev lockfiles - - Handle full name conflicts from different original_platforms when adding checksums to store from compact index - - Specs passing on Bundler 3 - - https://github.com/rubygems/rubygems/commit/86c7084e1c - -commit 69d7e9a12eb6e3dbfa1b1021b73c2afcbf7d4a46 - Author: Mercedes Bernard <mercedesrbernard@gmail.com> - AuthorDate: 2023-02-11 04:34:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-23 13:59:01 +0900 - - [rubygems/rubygems] Use the server checksum, then calculate from gem on disk if possible - - 1. Use the checksum provided by the server if provided: provides security - knowing if the gem you downloaded matches the gem on the server - - 2. Calculate the checksum from the gem on disk: provides security knowing - if the gem has changed between installs - - 3. In some cases, neither is possible in which case we don't put anything - in the checksum and we maintain functionality as it is today - - Add the checksums to specs in the index if we already have them - - Prior to checksums, we didn't lose any information when overwriting specs - in the index with stubs. But now when we overwrite EndpointSpecifications - or RemoteSpecifications with more generic specs, we could lose checksum - info. This manually sets checksum info so we keep it in the index. - - https://github.com/rubygems/rubygems/commit/de00a4f153 - -commit ad08674d8dc17c4ca031ce20760c4a4779c83e27 - Author: Thong Kuah <tkuah@gitlab.com> - AuthorDate: 2022-08-01 08:42:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-23 13:59:01 +0900 - - [rubygems/rubygems] Add CHECKSUMS for each gem in lockfile - - We lock the checksum for each resolved spec under a new CHECKSUMS - section in the lockfile. - - If the locked spec does not resolve for the local platform, we preserve - the locked checksum, similar to how we preserve specs. - - Checksum locking only makes sense on install. The compact index - information is only available then. - - https://github.com/rubygems/rubygems/commit/bde37ca6bf - -commit 2d468358a516f575d013f07801079e0906c61f0c - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-23 09:07:23 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-23 13:14:15 +0900 - - Lrama v0.5.7 - -commit 11468269486d855f606cff5d0fa848772bc5c0cd - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-10-23 03:23:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-23 05:17:44 +0900 - - [rubygems/rubygems] Fix spelling of extraneous - - https://github.com/rubygems/rubygems/commit/af61829432 - -commit b84e6fe93ee35111b592f9e10e30bc460a077d0b - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-10-22 20:12:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-22 20:12:16 +0900 - - [DOC] Mention the omission of a superclass when reopening a class - -commit e721a7aec77754f42a44e05d115adb7ae676197c - Author: Yuki Tsujimoto <46666464+ytjmt@users.noreply.github.com> - AuthorDate: 2023-10-22 18:47:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-22 18:47:22 +0900 - - [DOC] Update documentation for typical implementation of hash - -commit 7578bc35f9b6a2e88f43a5c48dc1b209fc972eaa - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-22 11:52:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-22 12:18:34 +0900 - - [ruby/io-console] Intersperse Win32 and termios implementations - - So that the both sources appear in RDoc generated HTMLs. - - https://github.com/ruby/io-console/commit/beec164a47 - -commit 8c0c7be65b21dc34156919b04b834e26a429037e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-22 11:18:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-22 11:30:39 +0900 - - [ruby/io-console] Start 0.6.1 - - https://github.com/ruby/io-console/commit/06307a755d - -commit c7731b35eb460d75587ac9e81eb279153c6b9e82 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-22 11:04:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-22 11:09:06 +0900 - - [ruby/io-console] [DOC] Split .document files to sync with ruby/ruby - - https://github.com/ruby/io-console/commit/13e0bcac9f - -commit 9e93af5329f35092c3de3ea37d4e9e181b800bb2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-21 20:32:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-22 08:44:52 +0900 - - Skip RBS `RbConfig::TOPDIR` test that is `nil` before installation - -commit 0ca5182ae506e2518fc68f3512d173f547ebfbf1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-21 20:30:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-22 08:44:52 +0900 - - RBS no longer has test/stdlib/Prime_test.rb - -commit f717faac632dd8664d0967f8e639b84d5d032854 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-21 19:42:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-22 08:44:52 +0900 - - Update rbs revision to test - -commit cabf3dac360adfb639badcb6c19a19796a79b38c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-22 07:53:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-22 07:58:43 +0900 - - [ruby/io-console] [DOC] Add .document - - https://github.com/ruby/io-console/commit/62a677b51a - -commit 499e66d05cb8c57c1d51cbcfc5f1ff3ba2944ed3 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-10-20 11:13:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-22 05:35:34 +0900 - - [rubygems/rubygems] Gem::NameTuple equality ignores Gem::Platform/string platform variation - - https://github.com/rubygems/rubygems/commit/49aaa46708 - -commit 745879b5edd385f936bfe086a16fab1f05a4bd15 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-10-22 03:05:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-22 03:06:00 +0900 - - [ruby/irb] Minor refactors around irb.rb - (https://github.com/ruby/irb/pull/736) - - * Remove dead method - - * Simplify IRB.version - - * Move private Irb methods together - - * Centralise @CONF initialization/assignment in init.rb - - * Move attr_* calls above initialize method - - https://github.com/ruby/irb/commit/cf23be4395 - -commit 361bce8d2c4c90a01eb3b7365a87dec0d93bb2b6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-21 23:47:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-21 23:47:29 +0900 - - [Bug #19967] Ignore library before build - -commit 38b79b05fd615b9e055f100f02faf5f5942e45c3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-21 19:47:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-21 19:47:05 +0900 - - Fallback job status to normal if no tty - -commit 54b9b80b84760717aadb8bf67f638785ed895a58 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-21 16:45:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-21 16:45:03 +0900 - - [Bug #19967] Delete real path - -commit 5e24a4e3920da5ff71f18f4dfe0928b2221285b4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-21 15:42:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-21 15:42:41 +0900 - - Strip universal_archnames - -commit 642875e474b4e6a13770b1dbbc33d466ba5e0718 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-20 22:20:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-21 14:05:21 +0900 - - [Bug #19967] Revert "configure.ac: LIBPATHENV on macOS" - - This reverts commit 1961c786aab243b3eb60e7238224e87975d88056. These - environment variables should no longer propagate to child processes. - -commit 665b4c5b2a31078d7db0173ad60daad0b463c1fd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-20 20:45:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-21 14:05:20 +0900 - - [Bug #19967] Reset `LIBPATHENV` env after started - - Not to affect other tools invoked as child processes. - -commit 6d1ed3def8a79047b3e55dd3e6ddb83544794e02 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-20 18:09:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-21 14:05:20 +0900 - - Avoid duplicate path in library paths - -commit 55d954721e25ada90482f6d3f751a12fc982620b - Author: Charles Oliver Nutter <headius@headius.com> - AuthorDate: 2023-10-21 13:30:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-21 13:30:40 +0900 - - Raise TypeError for bad IO::Buffer.map argument (#8728) - - * Raise TypeError when IO::Buffer.map argument is neither IO nor implements #fileno - - * Use UNREACHABLE_CODE - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - - * Use macro for undef check - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - - --------- - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit 0e62802c3bdc2167b1c8e5f9db014f1e421f2c62 - Author: Charles Oliver Nutter <headius@headius.com> - AuthorDate: 2023-10-21 11:00:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-21 11:00:18 +0900 - - Extract IO::Buffer.for string locking test (#8729) - - String locking with locktmp is not really part of the public API, - and the test relies in a side effect of using it to protect the - buffer. On other implementations without locktmp this does not - fail. Separate into its own test so it can be excluded from public - API expectations. - -commit 8a88172fd44defba0e73ebef41d33a44ac71941d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-21 05:12:38 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-21 05:12:38 +0900 - - YJIT: Skip printing stats at exit if --yjit-disable (#8727) - -commit 01787d53bfef987a34832ade02376b2f9e364327 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-20 05:50:21 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-21 04:29:06 +0900 - - [PRISM] Setup encodings in prism compiler - -commit fab7018346488a693d34ea81f1e9d6fec476f06e - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-10-21 02:00:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-21 02:00:52 +0900 - - YJIT: On test_bug_19316, only check the result - - Because the `&` call checks for interrupts, the test was accidentally - timing dependent. Stop checking for exits. - - [Bug #19921] - - Reported-by: Vít Ondruch <vondruch@redhat.com> - Reported-by: Mamoru Tasaka <mtasaka@fedoraproject.org> - -commit 1c48d15d6bdaa1f863e147165ba7052962119060 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-19 06:14:45 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-20 23:49:53 +0900 - - Add tests for all implemented nodes, leave ones that need fixing commented out - -commit 40624d4921095beee4765b49a35e6e8ec30fa17a - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-19 05:43:13 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-20 23:49:53 +0900 - - Added TODOs on all implemented nodes, matched ordering - -commit a426a230de4deb8771b0134a367f4ad28658476a - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-19 05:14:13 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-20 23:49:53 +0900 - - [PRISM] Fixed StringConcatNode, uncommented tests - -commit 8b3d044004be68acf2e71d43c51d99db3deff514 - Author: Herwin <herwinw@herwinw.nl> - AuthorDate: 2023-10-20 18:26:37 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-20 18:26:37 +0900 - - [DOC] Indentation fix in comments of MatchData#inspect - - The old version did not add syntax highlighting to the code block, and - included the "Related:" line in the code block as well. - -commit 0061eaddc9de7e80ebce6fadd00b92beed46bbee - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-20 16:33:23 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-20 16:33:23 +0900 - - [DOC] `configure -C` tips - -commit 9d1940ba3c3bd08a8f2c630e51524186e350fdd5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-20 10:01:09 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-20 15:16:34 +0900 - - [Bug #19966] [PRISM] Fix singleton method definition - -commit 84dfa0fa5e451adb87beaf497165cb5a1bc93770 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-20 10:00:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-20 15:16:34 +0900 - - [PRISM] Enclose in the test class - -commit bb849ffdb18305f01457de4e9848c830eb83a2d7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-20 14:34:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-20 14:34:08 +0900 - - Added explicitly begin-end block for Ruby 2.4. - - strscan, ipaddr and some default gems still support Ruby 2.4. - - After this, I extract this CoreAssertions to their repositories. - -commit 9ea1ee66c9852557f32f511db10ccc26e1f8c938 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-20 09:04:00 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-20 12:56:04 +0900 - - Stop creating ripper.h because it's not used - -commit 097648897059c14e1dd818338da68de0255b7e00 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-20 11:23:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-20 11:37:07 +0900 - - [ruby/logger] Bump up required ruby version to 2.5 - - https://github.com/ruby/logger/commit/ac911eae2b - -commit 13b33b109f2d0bb17164a743c2f71cbe67a36422 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-20 11:22:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-20 11:37:04 +0900 - - [ruby/logger] Use Gemfile instead of Gem::Specification#add_development_dependency - - https://github.com/ruby/logger/commit/7b51af263f - -commit 62c1d8187b21b7741284d179c7cb313ee661f806 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-20 09:51:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-20 09:52:03 +0900 - - Partly revert a change in #8705 - - Having this variable actually helps the performance of non-JITed calls. - - ----- ----------- ---------- ---------- ---------- ------------- ------------ - bench before (ms) stddev (%) after (ms) stddev (%) after 1st itr before/after - fib 241.9 0.5 225.4 1.0 1.06 1.07 - ----- ----------- ---------- ---------- ---------- ------------- ------------ - - (benchmarked with --yjit-cold-threshold=0) - -commit 1640dbdedd3817f1a4e0df6476fe75aa794a2dd1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-20 09:10:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-20 09:13:55 +0900 - - Sort gem names - -commit 2a56a6c3af9b36bc762855995723a23f9f5bd4d8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-20 09:09:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-20 09:13:55 +0900 - - racc is also extracted to bundled gems - -commit 985370406d2c5150fa3e0f23cdae605ec1a60fdb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-20 09:12:08 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-20 09:12:09 +0900 - - Call rb_jit_cont_init() even earlier - - To fix https://github.com/ruby/ruby/actions/runs/6581593578/job/17881779994 - -commit a9d7525fb420e721da38c0959dcc8980cd0cf38e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-20 09:04:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-20 09:06:23 +0900 - - Avoid initializing jit_cont_lock multiple times - - Contrary to my initial assumption, rb_threadptr_root_fiber_setup() is - called for each Ractor, not just once at boot. I changed the place to - call rb_jit_cont_init() to avoid calling it multiple times. - -commit 72f97ee06ebca8d33ca419c7b413568fca6c3b7e - Author: Matheus Richard <matheusrichardt@gmail.com> - AuthorDate: 2023-10-20 08:45:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-20 08:45:07 +0900 - - [DOC] Improve docs for how to generate documentation - - It might not be obvious how to get the build directory and the Makefile - set up. - -commit bd2aee67c172b033f8b18fc2182b5f4d2ef50bec - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-20 08:33:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-20 08:37:11 +0900 - - [DOC] "is now bundled" is ambiguous - - I think it meant it's now a bundled "gem", but "is now bundled" implies - it's a new gem that was neither default nor bundled gems. So I changed - wording. - - I also want to change the subjects and reorder them so that it will read: - "The following default gem" (new) -> "The following default gem" (updated) -> - "The following bundled gem" (new) -> "The following bundled gem" (updated). - -commit a9df1e699048eb0245015a6a2faa6e9e2d1dfeb9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-20 08:31:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-20 08:31:26 +0900 - - Ignore inputs to tool/update-NEWS-gemlist.rb - - generated by check_misc - -commit c221af2c3d0d0f7955214c14dfd66c8ccc7103e0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-20 08:25:08 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-20 08:25:33 +0900 - - [DOC] Prism is a new default gem - -commit 6d42f4dd2d1beacefb144c5caba0b80499d6681c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-20 08:09:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-20 08:10:14 +0900 - - Avoid using a system Ruby if possible - - in tool/update-NEWS-gemlist.rb - -commit 08e25985d1cadf9487e0a02f3956236e1158b210 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-18 23:59:34 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-20 07:56:20 +0900 - - Expand OP_ASGN1 nd_args to nd_index and nd_rvalue - - ARGSCAT has been used for nd_args to hold index and rvalue, - because there was limitation on the number of members for Node. - We can easily change structure of node now, let's expand it. - -commit 7fb909e240888f3187c8fdd20dee6e51d2a5c9d3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-20 07:50:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-20 07:50:46 +0900 - - [DOC] Reverse-merge YJIT release note changes - -commit 47f950c89ab89a2fb24c71d6bde1cec23fda3325 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-20 07:47:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-20 07:47:19 +0900 - - [DOC] Update NEWS.md about RubyVM::YJIT.enable - - --yjit-disable, and --yjit-perf - -commit 3467355450960050759618681ffd048614b24d93 - Author: Herwin <herwinw@herwinw.nl> - AuthorDate: 2023-10-20 07:18:03 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-20 07:18:03 +0900 - - [DOC] Fix typo in docs of Regexp#deconstruct_keys - - of => if - -commit 5bbb6fd6c3d26ffb7b1ffbe674c43cd07f3153ba - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-19 13:35:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-20 07:15:24 +0900 - - Add printf format attributes to `rb_parser_config_t` - -commit 205cbc09d342c0c3db371ca8207d189e1c0186f1 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-10-20 03:00:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-20 06:40:21 +0900 - - [rubygems/rubygems] Reuse Gem::RemoteFetcher instance in bundler - - Closes https://github.com/rubygems/rubygems/issues/7076 - - Bundler will now use the same (shared) remote fetcher instance that - RubyGems uses. - - This will allow installs to use a shared connection pool, which - represents a significant performance improvement on a clean install. - - https://github.com/rubygems/rubygems/commit/cd87b40fe1 - -commit af222d4db27b018a5e4a406ec668c479c68c0446 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-10-20 01:22:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-20 05:02:47 +0900 - - [rubygems/rubygems] Update vendored thor to v1.3.0 - - See https://github.com/rails/thor/releases/tag/v1.3.0 - - https://github.com/rubygems/rubygems/commit/3c7165474b - -commit 3e65115cef8dec7d280784fdd7324ede529051be - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-10-20 04:29:31 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-20 04:29:31 +0900 - - YJIT: remove unused `--yjit-greedy-versioning` command-line option (#8713) - -commit 9194f489c94a4498bcfa1e858a31ecdef833b4c9 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-10-20 02:48:27 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-10-20 04:14:20 +0900 - - YJIT: Make test_yjit.rb faster with --yjit-stats=quiet - - The for-human stats summaries are not relevant for the children - `test_yjit.rb` spawns. Avoid compiling and running the printing code. - On a -O0 dev build this halves the time for `test_yjit.rb` on my machine. - -commit 9047fe5ea4e8c989c1081aa10f741a413c546534 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-10-20 02:41:38 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-10-20 04:14:20 +0900 - - YJIT: Print exit reasons on failure in test_yjit.rb - - For <https://bugs.ruby-lang.org/issues/19921>, I suspect the test is - failing due to a timing related interrupt, which on paper could - happen with slow-enough GC runs. - - In any case, it's helpful for debugging to have more information when - tests fail. - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - -commit cdc2a18541a42e63a8a0a3c2c5b72978ace01afa - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-10-19 02:34:51 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-10-20 03:56:35 +0900 - - YJIT: Return Option from asm.compile() for has_dropped_bytes() - - So that we get a reminder to check CodeBlock::has_dropped_bytes(). - Internally, asm.compile() already checks it, and this patch just - propagates it out to the caller with a `#[must_use]`. - - Code GC logic moved out one level in entry_stub_hit(), so the body - can freely use `?` - -commit 6beb09c2c99a2575027bdbc60a6fbb099416f74d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-20 02:54:35 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-20 02:54:35 +0900 - - YJIT: Add RubyVM::YJIT.enable (#8705) - -commit 62e340251b577e3a9d11ac5c2b75ad49b8036294 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-10-19 23:31:16 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-10-20 00:57:43 +0900 - - Don't add anonymous locals when ISEQ binary debug is on - -commit 9d9aa63e8240fe2226e756e59876d7b3fe908f1d - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-10-19 08:36:42 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-10-20 00:50:36 +0900 - - YJIT: Enable the dead_code lint and delete some dead code - -commit c2d4c92a98527f416f4f9d5987c22c4cc8f584e7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-19 17:28:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-19 17:28:41 +0900 - - Extract a local variable - -commit 5e5a8cf752af362c7dad40f6a0b7aa93e18c5bd0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-19 15:47:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-19 15:55:40 +0900 - - [ruby/ostruct] Use Gemfile instead of Gem::Specification#add_development_dependency - - https://github.com/ruby/ostruct/commit/ed49920766 - -commit e6675861f3ddeabcc777dbb931a646868546382a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-19 13:57:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-19 13:57:32 +0900 - - Mentioned targeted libraries for warning feature of bundled gems - -commit 3605c9ae608e41f8e74af9fc537e891aa79d1165 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-19 13:51:31 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-19 13:51:31 +0900 - - Don't need to refer SINCE constant - -commit 3f5ec5c8661748afb9cc3cbf1aff113d602e1fad - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-10-13 08:33:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-19 12:11:23 +0900 - - [DOC] Add NEWS about Range#reverse_each for beginless ranges [Feature #18515] - -commit ccd2f8c1cada3df8eb6723bfdf164bc865699999 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-18 10:19:06 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-18 10:19:06 +0900 - - Skip some timeout tests on s390x - - They are too unstable on the machine. - - ``` - 1) Failure: - TestRegexp#test_timeout_shorter_than_global [/home/chkbuild/chkbuild/tmp/build/20231018T230003Z/ruby/test/ruby/test_regexp.rb:1788]: - Expected |0.2 - 0.962938869| (0.7629388690000001) to be <= 0.15000000000000002. - ``` - https://rubyci.s3.amazonaws.com/s390x/ruby-master/log/20231018T230003Z.fail.html.gz - - ``` - 1) Failure: - TestRegexp#test_timeout_longer_than_global [/home/chkbuild/chkbuild/tmp/build/20231017T140006Z/ruby/test/ruby/test_regexp.rb:1788]: - Expected |0.5 - 1.040696078| (0.5406960780000001) to be <= 0.375. - ``` - https://rubyci.s3.amazonaws.com/s390x/ruby-master/log/20231017T140006Z.fail.html.gz - -commit 10272b27900dd30981f59fe5e2aed8e14b4f729f - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-10-19 07:58:56 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-19 09:16:11 +0900 - - Use assert_separately to avoid defining `foo` - - When we eval the iseqs generated by prism, they can have side effects - like defining methods. In this case, we were defining the method "foo", - but other tests were expecting that the foo method would _not_ be - defined. - -commit 10c5063704c5bb086825c5e2e26ab7cacb7dbd7a - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-19 06:53:02 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-19 09:16:11 +0900 - - Address PR comments - -commit 1701b79b54a067aa4767710fef6559a23573aed4 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-19 03:51:30 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-19 09:16:11 +0900 - - Put line change back - -commit 5408ce8c17dab314c4610b76f51c32669bdd320d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-19 03:18:37 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-19 09:16:11 +0900 - - Fixed mistyping - -commit 252b0fc715f5a80325502b83ff6a89ad2f7c17b8 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-17 08:02:18 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-19 09:16:11 +0900 - - Temporarily removed location code on scope nodes - -commit ba3a99acaf4e024e4d17823f655665bc28f72e0a - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-17 07:36:25 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-19 09:16:11 +0900 - - Remove pm_compile_context_t, move the context onto ScopeNode - - We changed ScopeNodes to point to their parent (previous) ScopeNodes. - Accordingly, we can remove pm_compile_context_t, and store all - necessary context in ScopeNodes, allowing us to access locals from - outer scopes. - -commit a9512e80b01c8085c1bb8a1e30497541c844a6c1 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-17 07:36:07 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-10-19 09:16:11 +0900 - - Revert "Revert "[ruby/prism] Change ScopeNode to point to previous ScopeNode"" - - This reverts commit fd87372a7482cbf7672c44ef95bc1dc3b00bab7c. - -commit d2b0c9da2e0148c8c12ca58e21c482c1e66c2358 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-10-19 08:46:35 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-19 08:46:35 +0900 - - YJIT: Add a live ISeq counter - - It's an estimator for application size and could be used as a - compilation heuristic later. - - Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - -commit 0ac6fb225d15cbcd35b8122b151a17eaa92fafaf - Author: Katherine Oelsner <octokatherine@github.com> - AuthorDate: 2023-10-19 06:09:35 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-10-19 07:01:13 +0900 - - Add test for many ivars - - Co-authored-by: John Hawthorn <john@hawthorn.email> - -commit a7032b80af18b7f2eb3552c5231ca36a8c69f1be - Author: Katherine Oelsner <octokatherine@github.com> - AuthorDate: 2023-10-19 06:05:48 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-10-19 07:01:13 +0900 - - Revert "shape.h: Make attr_index_t uint8_t" - - This reverts commit e3afc212ec059525fe4e5387b2a3be920ffe0f0e. - -commit de0764501987aff0f9b19594a2cbd5583ccce660 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-10-19 06:13:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-19 06:13:21 +0900 - - [ruby/drb] Support :SSL{Min,Max}Version config options - - These are necessary to get the tests passing with LibreSSL 3.8.1+, - which dropped support for TLSv1.0 and TLSv1.1 for security reasons. - - This updates the tests to use TLSv1.2 on OpenBSD. This is only - strictly necessary on OpenBSD 7.4+, but it will work fine in previous - versions as well. - - https://github.com/ruby/drb/commit/32707b2db5 - -commit f51b92fe231266a1a184b8329d43520599d2017b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-19 06:07:03 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-19 06:07:03 +0900 - - YJIT: Add --yjit-perf (#8697) - - Co-authored-by: Alan Wu <alansi.xingwu@shopify.com> - -commit 6873f96abc2a924b264b6ed3818b2fe9cbf05d6c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-19 04:19:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-19 04:19:38 +0900 - - [ruby/prism] Bump to version 0.15.1 - - https://github.com/ruby/prism/commit/d906a8ceba - -commit 0f1e040068fac01856c5c4c0ba95305f10bdf8e5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-19 01:28:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-19 01:49:58 +0900 - - [ruby/prism] Bump to version 0.15.0 - - https://github.com/ruby/prism/commit/ee429f8d50 - -commit 8210cc4218b639b699c73ac273b62422d5718e10 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-18 00:45:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-19 01:09:16 +0900 - - [ruby/prism] Fix lex compat when dedent should be 0 - - https://github.com/ruby/prism/commit/41c0e0e06e - -commit c82b10bbc3a3293ba9464c27ac5e778c70d2fe9b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-18 06:45:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-19 01:08:32 +0900 - - [ruby/prism] Modify less of the CRuby locals - - https://github.com/ruby/prism/commit/aca24b3a17 - -commit 5d0604366e695066f32c94ebe3b4b827b2868a34 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-18 04:40:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-19 01:08:31 +0900 - - [ruby/prism] Add * and & to methods with ... - - https://github.com/ruby/prism/commit/e8114a786a - -commit 4358dd207f445259984d5535f1b545c8449fad35 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-18 04:33:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-19 01:08:31 +0900 - - [ruby/prism] Extract out constant pool bucket bits to constants - - https://github.com/ruby/prism/commit/1985a9ba51 - -commit f5f032295d49758032df4e4c257e423d3c96feb4 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-18 04:10:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-19 01:08:31 +0900 - - [ruby/prism] Provide "constant" constants, embedded in the code - - https://github.com/ruby/prism/commit/d469a56e7e - -commit 4f4016497e12af1b1a227bf0f7ff5e6b6e6f92ec - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-18 19:50:17 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-18 23:41:23 +0900 - - Handle `Timeout::Error` reported from workers - -commit 9c973f9555c2ccfb7f7637bde08a5261baad0e05 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-18 02:43:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-18 23:23:46 +0900 - - [ruby/prism] Use the unescaped regexp to scan for capture groups - - https://github.com/ruby/prism/commit/555551e8f2 - -commit 2a6f7cd9255b61e21cead0c761a513bde2899728 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-18 00:15:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-18 23:23:26 +0900 - - [ruby/prism] Index{Operator,And,Or}WriteNode - - Right now, our Call{Operator,And,Or}WriteNode nodes represent two - different concepts: - - ```ruby - foo.bar += 1 - foo[bar] += 1 - ``` - - These two statements are different in what they can support. The - former can never have arguments (or an opening_loc or closing_loc). - The former can also never have a block. Also, the former is a - variable method name. - - The latter is always going to be []/[]=, it can have any number of - arguments including blocks (`foo[&bar] ||= 1`), and will always - have an opening_loc and closing_loc. - - Furthermore, these statements end of having to take different paths - through the various compilers because with the latter you have to - consider the arguments and the block, whereas the former can - perform some additional peephole optimizations since there are - fewer values on the stack. - - For these reasons, I'm introducing Index{Operator,And,Or}WriteNode. - These nodes never have a read_name or write_name on them because - they are always []/[]=. They also support blocks, which the previous - write nodes didn't. As a benefit of introducing these nodes, I've - removed the opening_loc, closing_loc, and arguments from the older - write nodes because they will always be null. - - For the serialized format, both of these nodes end up being - smaller, and for in-memory we're storing fewer things in general, - so we have savings all around. - - I don't love that we are introducing another node that is a call - node since we generally want consumers to only have to handle a - single call, but these nodes are so specific that they would have - to be handled separately anyway since in fact call 2 methods. - - https://github.com/ruby/prism/commit/70155db9cd - -commit ef3f9f1a685effb51543d1f08831692fa68863a2 - Author: Kyle Stevens <kstevens715@gmail.com> - AuthorDate: 2023-10-14 20:32:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-18 19:17:58 +0900 - - [rubygems/rubygems] Allow uninstalling multiple versions of same gem - - Currently, you can install multiple versions of the same gem just fine: - - ``` - $ gem install simplecov:0.19.0 simplecov:0.22.0 - Fetching simplecov-0.19.0.gem - Successfully installed simplecov-0.19.0 - Parsing documentation for simplecov-0.19.0 - Installing ri documentation for simplecov-0.19.0 - Done installing documentation for simplecov after 0 seconds - Fetching simplecov-0.22.0.gem - Successfully installed simplecov-0.22.0 - Parsing documentation for simplecov-0.22.0 - Installing ri documentation for simplecov-0.22.0 - Done installing documentation for simplecov after 0 seconds - 2 gems installed - ``` - - But to uninstall both of them, you need to run the equivalent uninstall - command twice: - - ``` - ~$ gem uninstall simplecov:0.19.0 simplecov:0.22.0 - Successfully uninstalled simplecov-0.22.0 - ~$ gem uninstall simplecov:0.19.0 simplecov:0.22.0 - Gem 'simplecov' is not installed - Successfully uninstalled simplecov-0.19.0 - ``` - - This resolves that problem by using the gem's full name (which includes - the version) when tracking which ones have already been uninstalled so - when it gets to the second version listed it doesn't think it was - already uninstalled. - - https://github.com/rubygems/rubygems/commit/d96101b753 - -commit 8e6a2511387f47894407ea92494c0f5d3cdb51b8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-18 18:27:01 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-18 18:52:05 +0900 - - Remove unnecessary and misleading casts - -commit 46b8846b5c40cf4053f678dae1684f1c6eb52673 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-10-18 10:28:44 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-18 18:10:24 +0900 - - Show backtraces when failed - - If `assert_equal(backtrace_locations.size, profile_frames.size)` in - `TestProfileFrames#test_matches_backtrace_locations_main_thread` - failed, we do not have enough information about it like that: - - ``` - 1) Failure: - TestProfileFrames#test_matches_backtrace_locations_main_thread [/home/runner/work/ruby/ruby/src/test/-ext-/debug/test_profile_frames.rb:148]: - <31> expected but was - <30>. - ``` - - This patch shows both `backtrace_locations` and `profile_frames` - if failed. - -commit f546fe15d547472f60c4a2d2857321b3c5084f0f - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-10-18 18:01:43 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-10-18 18:01:43 +0900 - - Loosen assertion for flaky weak references test - -commit ac8ece81f26f29dc2f9d77fcdb0620a51ba26f1e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-18 12:40:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-18 14:51:48 +0900 - - Tweak the grammar - -commit 46766e922b46cb3bdc42fa0b2052265c2f6c2a65 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-18 12:26:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-18 14:51:48 +0900 - - normalize gem name without .so or .bundle - -commit 3b690b726df82f399023b26fdb7530fb9009acf5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-18 12:21:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-18 14:51:48 +0900 - - reject bundled gems if they are declared in Gemfile - -commit ff4c98f1251574e32a950f5793fba3afbc0838a7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-18 12:19:52 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-18 12:19:52 +0900 - - Fix total count when filters with class name given - -commit f13068afaa6f305746d92517662e8c0956d31e7b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-18 10:36:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-18 10:36:42 +0900 - - Escape method names containing control characters - -commit 6c46ccf226bc6440743b51af713864c062eba27f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-18 09:57:39 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-18 09:57:39 +0900 - - Prefer RbConfig.ruby over the 3.times fallback (#8691) - - It seems saner to use RbConfig.ruby than using ruby in a random ancestor - directory. - -commit 7a3a98e2be69fd3fa68e6ee1afa43c3160f22254 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-18 09:47:13 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-18 09:47:13 +0900 - - YJIT: Use RbConfig.ruby instead of EnvUtil.rubybin (#8689) - - Some people encounter an issue that test_yjit uses the installed Ruby - instead of the currently-running Ruby. It's fixed when they remove the - installed Ruby. - - However, test_yjit should run the currently-running Ruby for testing - YJIT in subprocesses. EnvUtil is unfortunately used outside tests as - well, so for compatibility reasons, this commit only changes the - argument given to EnvUtil.invoke_ruby to always use RbConfig.ruby. - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - -commit 36ee5d8ca824836e10ef18191d789a8b34f87fee - Author: Alan Wu <alanwu@ruby-lang.org> - AuthorDate: 2023-10-18 06:49:45 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-10-18 07:36:23 +0900 - - YJIT: Fix clippy::redundant_locals - - > note: `#[deny(clippy::redundant_locals)]` on by default - - On Rust 1.73.0. - -commit 2abd061e8beefbdead0296377948ce7a0098277b - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-10-18 01:14:56 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-10-18 04:24:55 +0900 - - YJIT: Remove call to compile() on empty Assembler - -commit 776d4dec69c81e2c94c36648205f513baa05551f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-17 20:13:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-18 02:55:42 +0900 - - Manage parallel test workers after timeout - -commit 8b520bd3fb239cbfba150644bf7c5676bb07a579 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-17 16:59:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-18 02:55:42 +0900 - - Add `jobs` optional keyword argument - -commit 5a3e8d2f187d54f336090c438ad9a202f137373a - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-10-18 02:13:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-18 02:50:38 +0900 - - [ruby/prism] Ensure last encoding flag wins - - You can't encoding a string with more than one encoding so ensure that - the last one wins. - - https://github.com/ruby/prism/commit/4182c988c9 - -commit d458b4127f1815e76774cb7c3c23b7c31dfd54bc - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-18 00:36:13 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-18 00:36:13 +0900 - - YJIT: Add a few missing counters for send fallback (#8681) - -commit 1f7234c0152df5dcf9a73acb352d20fcd3004ddf - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-04-04 10:24:47 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-10-18 00:30:35 +0900 - - YJIT: Lookup IDs on boot instead of binding to them - - Previously, the version-controlled `cruby_bindings.inc.rs` file - contained the build-time artifact `id.h`, which nobu mentioned hinders - the goal of having fewer magic numbers in the repository. - - Lookup the IDs YJIT needs on boot. It costs cycles, but it's fine since - YJIT only uses a handful of IDs at the moment. No perceptible - degradation to boot time found in my testing. - -commit 01b5d1d2ff6ca91b2909dfa67295f59b53e6f065 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-18 00:27:49 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-18 00:27:49 +0900 - - YJIT: Add a cargo job for Arm64 and remove .cirrus.yml (#8679) - - * YJIT: Add a cargo job for Arm64 - - * YJIT: Use command names as job names - - They look more consistent with jobs that use the command name as a job - name, such as `make (check)`, `make (test-bundled-gems)`, etc. - - * Remove .cirrus.yml - -commit 4c54492770cd7dcf03360c9061358f6e640b5075 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-17 20:09:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-17 21:07:25 +0900 - - Separate `test-precheck` target - - So that the tests can run without updating other than the programs. - -commit 03ac10898f7ee08342a8a5968f7b7095dd8692ae - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-17 16:58:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-17 21:07:25 +0900 - - Wait for `showflag` to finish to prevent interspersed outputs - -commit 2a8ac8ead5d4deb4fcef8f3c13c521eded2301c4 - Author: tompng <tomoyapenguin@gmail.com> - AuthorDate: 2023-09-12 02:53:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-17 20:07:57 +0900 - - [ruby/rdoc] Delay DidYouMean until NotFoundError#message is called - - https://github.com/ruby/rdoc/commit/b59ca2f981 - -commit 7362c484c8e5bdf9e05ac5dd10c23162a8e117ad - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-17 17:00:45 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-17 18:21:40 +0900 - - Use rb_getnameinfo instead of directly using getnameinfo - -commit c9990c8d0fdec0f79791ac3096ee6925fab0be7c - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-10-17 09:51:53 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-17 17:43:52 +0900 - - "+MN" in description - - If `RUBY_MN_THREADS=1` is given, this patch shows `+MN` in - `RUBY_DESCRIPTION` like: - - ``` - $ RUBY_MN_THREADS=1 ./miniruby --yjit -v - ruby 3.3.0dev (2023-10-17T04:10:14Z master 908f8fffa2) +YJIT +MN [x86_64-linux] - ``` - - Before this patch, a warning is displayed if `$VERBOSE` is given. - However it can make troubles with tests (with `$VERBOSE`), do not - show any warning with a MN threads configuration. - -commit aee1bfd88eca8fb9022138347b7c0390c0e6f545 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-17 15:48:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-17 15:48:05 +0900 - - Get rid of `set` with empty argument which dumps all definitions - -commit 908f8fffa2df19fa1b2fbd674149644e61e55e20 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-17 04:06:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-17 13:10:14 +0900 - - [rubygems/rubygems] Don't hide original error in `after(:suite)` hook - - For some reason, Windows builds are failing quite consistently now. - However, it seems that errors are happening before this directory is - even created, so removal fails, hiding the original error. - - Instead, don't let this removal fail due to files not existing. - - https://github.com/rubygems/rubygems/commit/7669d6c96e - -commit 9bd99cc171a8c226ea330f45a51fb3345813c6b4 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-17 04:47:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-17 09:42:31 +0900 - - [ruby/prism] Fix up super with a blockarg - - https://github.com/ruby/prism/commit/0ea19ed823 - -commit 448e8b5ebb1a6504351c2e30a7d945f10dbcdd78 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-16 18:35:10 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-17 08:09:49 +0900 - - Remove duplicated option - - `-d` option is basically same with `-h` (`--header`). - The difference is `-h` accept header file name. - Therefore remove `-d` option. - -commit 1ae8c624830715579dd67c5e5bd8a75514c417d3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-14 02:40:33 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-17 07:40:19 +0900 - - [ruby/prism] Load magic comments in java - - https://github.com/ruby/prism/commit/5d189ce33e - -commit 9f16f07cf1e340acd9c41acaf8d46394353a0cea - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-14 02:34:56 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-17 07:40:19 +0900 - - [ruby/prism] Additionally handle encoding comments in vim mode - - https://github.com/ruby/prism/commit/bf9bdb9d82 - -commit 5523a23469987f92e38d52d4332bde09bdd8896c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-14 01:16:11 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-17 07:40:19 +0900 - - [ruby/prism] Attach magic comments to the parse result - - https://github.com/ruby/prism/commit/c7ef25a79a - -commit 39dd3343d8672a70ebb0990c166d99a8b29ee19e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-14 00:56:08 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-17 07:40:19 +0900 - - [ruby/prism] Parse all magic comments - - https://github.com/ruby/prism/commit/2b3d59f424 - -commit fd87372a7482cbf7672c44ef95bc1dc3b00bab7c - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-17 07:20:26 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-10-17 07:20:26 +0900 - - Revert "[ruby/prism] Change ScopeNode to point to previous ScopeNode" - - This reverts commit 67a987f82bc8a2b7ec15581306873530821fcf9e. - -commit 67a987f82bc8a2b7ec15581306873530821fcf9e - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-17 06:28:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-17 06:53:11 +0900 - - [ruby/prism] Change ScopeNode to point to previous ScopeNode - - Amend ScopeNode to point to previous ScopeNode, and to have void* - pointers to constants and index_lookup_table - - https://github.com/ruby/prism/commit/0534324312 - -commit 3dec5dc3462286cdbdb53e496e6175a82bdc39b7 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-10-17 04:58:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-17 05:23:50 +0900 - - [ruby/net-http] Force TLS version to 1.2 when using LibreSSL - - This comment previously specified TLS 1.2, but actually set the - version to TLS 1.0. LibreSSL 3.8.1 (included in OpenBSD 7.4) - dropped support for TLS 1.0/1.1 for security reasons, which - broke this test. Switch the test to use TLS 1.2 as documented - so it will continue to work on OpenBSD 7.4+. - - https://github.com/ruby/net-http/commit/97be4de53a - -commit 10d88ec9c3bbc93b83b2ea5e93cb781fbf42f0be - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-17 04:00:01 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-17 04:00:01 +0900 - - [PRISM] Compile AliasGlobalVariableNode (#8675) - -commit 8f33d801c21c01fb15abed6cabd4d4b289554de3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-17 01:18:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-17 01:20:21 +0900 - - Just skip the job if not on ruby/ruby - - Using the same `runs-os` across all jobs in the same workflow makes it - more likely to pass in case one of these runners is experiencing an - outage. - - macos-arm-oss is generally not available outside ruby/ruby, so it's - fair to skip it for forks. - -commit 5b5643ae8b4ee1cbdbfecee3a9e994b7441dad95 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-17 00:12:54 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-17 00:12:54 +0900 - - Remove YJIT --repeat-count=2 job (#8669) - -commit 728286d0e83b033fe6e56674dab3fc8bf17cce43 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-16 22:31:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-16 22:31:32 +0900 - - [PRISM] Fix more bugs in the compiler (#8658) - - * Fixed ConstantPathWriteNode - * FIxed FlipFlopNode - -commit 6e88b72d7bdac5d959d525df6e3804f4c1eaf9ce - Author: Adam Hess <HParker@github.com> - AuthorDate: 2023-10-16 21:22:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-16 21:22:07 +0900 - - [PRISM] prevent underflow on popped splatarray (#8657) - - prevent underflow on popped splatarray - - This only emits the splat array node when not popped - -commit 06a4011964e02000f44097b12435b49957a12f02 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-16 20:11:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-16 21:09:05 +0900 - - [ruby/irb] Suppress "Switch to inspect mode" messages - - This message is displayed if STDIN is not a tty. The parallel test is - the case. - - https://github.com/ruby/irb/commit/e26e90e3fb - -commit d1f781b0d49f16d996e3ba848f386e6452aa68a0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-16 20:53:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-16 20:55:01 +0900 - - [ruby/psych] Bump up v5.1.1.1 - - https://github.com/ruby/psych/commit/51cc86ff3f - -commit f6e2f32a962c2c19a0418dfd2020c8c9ab32c8b0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-16 18:51:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-16 19:57:34 +0900 - - Build `rb_dynamic_description` at runtime - - To avoid creating literals for all combinations. - -commit 55a0d2c63b5054895e7d7c674ea633807ad9eaf2 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-10-15 14:42:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-16 19:39:44 +0900 - - [ruby/prism] Avoid unnecessary delete_prefix in LibRubyParser.resolve_type - - Only remove const prefix from non-pointer types. - - https://github.com/ruby/prism/commit/97c9ffeb42 - -commit 77ffa1a7c3af797078b2a8e84bfc6f2b0ba67820 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-05 03:08:49 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-16 13:52:57 +0900 - - [rubygems/rubygems] Raise an error when top level dependency does not resolve under all locked platforms - - https://github.com/rubygems/rubygems/commit/25304f3e8d - -commit 73ba4b76c20931ad5c786de3ae3ad92523bc1443 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-05 14:53:57 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-16 13:52:56 +0900 - - [rubygems/rubygems] Automatically remove invalid platforms before re-resolving - - https://github.com/rubygems/rubygems/commit/40989271dd - -commit b7ad9eda3c5b4c102077ebb9619b99b6141aab86 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-05 06:18:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-16 13:52:56 +0900 - - [rubygems/rubygems] Tweak platform mismatch resolution errors - - https://github.com/rubygems/rubygems/commit/20460bc1ee - -commit a1c73f1c881aab95bf3ed5316f2d6de62bba90d1 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-05 03:08:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-16 13:52:55 +0900 - - [rubygems/rubygems] Consistent usage of `local_platform` in Definition - - https://github.com/rubygems/rubygems/commit/5f28a68d79 - -commit a05904c8cefdf16feb164240f8aff0f83d43e75a - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-05 18:55:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-16 13:52:12 +0900 - - [rubygems/rubygems] The `lock` command should not be affected by frozen setting - - The `lock` command is specifically designed to manage the lockfile, so - running it should take precedence over any "frozen" setting. - - Besides that, "frozen" is not specifically designed as "lockfile cannot - be updated" but as "installation of gems should be prevented if gemfile - is not in sync with the lockfile". - - The lock command does not install any gems and preserves the property of - the lockfile being in sycn with its gemfile, so I think frozen should - not influence it. - - The current behavior is quite confusing when frozen is set. On an app - where rubocop can get lockfile updates - - ``` - $ bundle lock --update rubocop - Writing lockfile to /path/to/Gemfile.lock - ``` - - Completely silent, it makes you think that it has written the lockfile, - but still no updates. - - In verbose mode, it gives a bit more information, but still confusing - and unexpected, and does not change the lockfile: - - ``` - $ bundle lock --update rubocop --verbose - Running `bundle lock --update "rubocop" --verbose` with bundler 2.4.20 - Frozen, using resolution from the lockfile - Writing lockfile to /path/to/Gemfile.lock - ``` - - With this commit, it updates the lockfile as expected. - - https://github.com/rubygems/rubygems/commit/1d501ae8ea - -commit 4dbee36f84952d7a237a2fdd8fd8d3e2823692df - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-05 18:40:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-16 13:52:11 +0900 - - [rubygems/rubygems] Use instantiated definition directly - - https://github.com/rubygems/rubygems/commit/bc233af4d2 - -commit f37e9f42b95e033ec557fa3bf68282dd823ee199 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-10-07 08:18:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-16 13:51:09 +0900 - - [rubygems/rubygems] [PathSupport] Simplify logic: If `Gem.default_dir` is writable, use it. - - I couldn't find a cross-platform way to check "can I create this directory?" - - So I removed that, and went back to the original simpler logic of - "if the directory is writable, use it." - - https://github.com/rubygems/rubygems/commit/3aa86a56db - -commit 45a5ea5a0ac36d8cce05167cebcc2a0812c90019 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-10-01 08:18:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-16 13:51:08 +0900 - - [rubygems/rubygems] Remove kludge that should be unnecessary. - - https://github.com/rubygems/rubygems/commit/f1d44ecb62 - -commit 724398cce630edd5b5053333e0fbf6ae3b05c9c5 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-10-01 08:15:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-16 13:51:08 +0900 - - [rubygems/rubygems] Remove outdated/incorrect comment. - - The function is also significantly simpler than it used to be, - to the point I'm not sure it needs a comment. - - https://github.com/rubygems/rubygems/commit/29a0551e37 - -commit 3f5da31760476cf8a0340f03125c4b97c3cdbc97 - Author: Ellen Marie Dash <the@smallest.dog> - AuthorDate: 2023-10-01 08:13:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-16 13:51:07 +0900 - - [rubygems/rubygems] Rephrase "Defaulting to user installation" message. - - https://github.com/rubygems/rubygems/commit/b7c531347e - - Co-authored-by: David Rodríguez <deivid.rodriguez@riseup.net> - -commit cbf2e133c10b87bb7d1f858471e600af6c6e62d1 - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-01 04:01:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-16 13:49:49 +0900 - - Re-resolve when lockfile is invalid - - Move the check for unmet dependencies in lockfile just in time to be - able to re-resolve if unmet dependencies are found. - -commit 7e51cadc2e3574996f63e4afd235d6f3e19f3a59 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-15 21:15:43 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-16 09:48:05 +0900 - - Fix method coverage comparisons - - Although Ruby's hashes preserve the insertion order, the ordering of - method coverage results is inherently nondeterministic, because they - are collected using `ObjectSpace`. - -commit 833c930bd680044ae1f1432605427b2385f02d59 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-16 03:06:21 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-16 03:58:30 +0900 - - Remove unneeded checks - - Follow up of 591336a0f278bf963d01b6e9810cfc86a5b50620 - -commit 606452d1a92504d62f305f20d992577b47cab1e0 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-14 11:01:47 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-15 16:16:06 +0900 - - Remove not used fields from STR - -commit 5342dbf00bd87099a15e90d5375d44dff81493ac - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-14 10:57:47 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-15 16:16:06 +0900 - - Check node type before accessing nd_next - - This is also a preparation for removing not_used members from - STR NODE. Current codes work without node type check because NODE_STR - has not_used2 member corresponding to nd_next of NODE_LIST and - NODE_DSTR. However it causes problme once not_used members are - removed from NODE_STR. - -commit e7e31d77848797703de60ea4aa095a3ec9e6c762 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-14 10:53:44 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-15 16:16:06 +0900 - - Stop updating node type from NODE_STR to NODE_DSTR - - This is a preparation for removing not_used members from STR NODE. - Once not_used members are removed from STR NODE, STR NODE is smaller than - DSTR NODE. Therefore allocate NODE_DSTR instead of reusing NODE_STR. - -commit a4e3d595cd9e656630030619235c42c48b0a1446 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-12 23:49:29 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-15 16:16:06 +0900 - - Remove not used fields from XSTR - -commit cab67d227aaf9773cbf5bb56af23f7f38fcf0644 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-12 23:40:42 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-15 16:16:06 +0900 - - Remove not used fields from LIT - -commit dc8742f5cc0a7e6cdaa5610eeef2b056164d07f7 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-12 23:40:28 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-15 16:16:06 +0900 - - Remove not used fields from MATCH - -commit 591336a0f278bf963d01b6e9810cfc86a5b50620 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-10-15 14:53:14 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-10-15 15:35:45 +0900 - - Avoid the pointer hack in RCLASS_EXT - - ... because GCC 13 warns it. - - ``` - In file included from class.c:24: - In function ‘RCLASS_SET_ALLOCATOR’, - inlined from ‘class_alloc’ at class.c:251:5, - inlined from ‘rb_module_s_alloc’ at class.c:1045:17: - internal/class.h:159:43: warning: array subscript 0 is outside array bounds of ‘rb_classext_t[0]’ {aka ‘struct rb_classext_struct[]’} [-Warray-bounds=] - 159 | RCLASS_EXT(klass)->as.class.allocator = allocator; - | ^ - ``` - https://rubyci.s3.amazonaws.com/arch/ruby-master/log/20231015T030003Z.log.html.gz - -commit 985b0244dae306c8e436da234a8bd4c8c322acf5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-15 15:27:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-15 15:27:05 +0900 - - Revert an unneeded if on check_misc - - nobu says he wants to run this on [DOC] commits as well. - -commit 13dafb210e30613e68efa454caebf1d4319a2f09 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-14 00:00:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-15 14:43:41 +0900 - - [DOC] testing_ruby.md: Add spec/ for the explanation of the `make check`. - -commit df1887414a0b7efb19189788629eedcfd790c7e3 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-10-13 23:54:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-15 14:43:41 +0900 - - [DOC] testing_ruby.md: Remove the command prompt '$ ` aligning with other parts. - - Remove the command prompt '$ ` aligning with other parts in the document. - -commit ddd5be9efad0442b1976e8e3f8cc4936e9d6e61c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-15 14:33:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-15 14:33:40 +0900 - - Use the same if: guard for all jobs - -commit 341d2ad95c210cf0c14a47e2afb43434c1d528df - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-15 13:52:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-15 14:24:24 +0900 - - Use unique names for result jobs - - If these jobs have the same name, GitHub allows merging a pull request - as soon as one of these jobs finishes. - - We want to wait for all these jobs, so we have to use different names. - Since we don't skip this result job on [DOC], it's okay to use a - templated variable for this name. - -commit 222c4b85684424352d65125018d15a9e87d0a851 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-15 13:09:08 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-15 14:24:24 +0900 - - Add result job for required status checks - - We've been using matrix jobs as required status checks. However, when - [DOC] pull requests are created, the matrix content and templated - variables are not executed, which results in changing the name of the - matrix jobs. Then required status checks are considered missing because - of the different names. So we can't merge [DOC] PRs right now. - - This `result` is a known technique to check the composite status of - matrix jobs. https://github.com/orgs/community/discussions/26822 - The `result` job is not only a non-matrix job, which doesn't have the - above problem, but also an independent job that is not skipped by [DOC]. - `needs` works even if all dependent jobs are skipped, so this trick - works well. - - This is also useful when we want to change the content of matrix. When - we change one, we usually have to update branches of old pull requests - so that they get newly required jobs. However, with this method, only - `result` jobs are required, so you don't need to update old pull - requests. - - I still don't like the fact that now you cannot visualize which matrix - jobs are "Required", but this seems like the best compromise. - -commit 28bd3a96b9cf6830e94389d6288d0b6095de5993 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-15 14:06:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-15 14:06:42 +0900 - - The needs != '' check is broken - -commit 5cb76754ab7fbe90cbbbe1bc526011c3a28fd1cb - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-10-15 07:51:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-15 13:47:58 +0900 - - [DOC] Fix the argument name in the Numeric#step doc - -commit 83f929316e2ef860469886d8001b69a67f15a406 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-03 05:53:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-15 13:46:32 +0900 - - [rubygems/rubygems] Fix force_ruby_platform: when the lockfile only locks the ruby platform - - https://github.com/rubygems/rubygems/commit/7c50064c3c - -commit 48c6cea330259a66ccf9757b06418b0653ec1dfb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-15 13:00:50 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-15 13:00:50 +0900 - - YJIT: Count cold_iseq_entry by default (#8654) - -commit 55c5ebe0a02eee319eb6a965a08bb53c5dcc7feb - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-10-15 03:56:46 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-15 04:35:17 +0900 - - disable MN threads on s390s-linux - - I check the s390s-linux/Ubuntu system and I found that MN threads - doesn't work with: - - * function inlining (-O0 doesn't repro) - * Thread local specifier (`_Thread_local`. - With `pthread_get_specific works) - (it is not an issue of `__tls_get_addr()` written in thread.c) - * swap context with ucontext (coroutine/ucontext) - - I couldn't find out what is the root cause of this issue but - disable MN threads to make CI healthy. - -commit 7865cebfb7a113ed87409a41424c4fd617dee67c - Author: Alexandre ZANNI <16578570+noraj@users.noreply.github.com> - AuthorDate: 2023-10-14 21:16:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-15 01:46:14 +0900 - - [ruby/cgi] doc: fix method name - - there was probably a copy paste mistake in the example of unescapeURIComponent (copied from unescape) - - https://github.com/ruby/cgi/commit/f8fb627e90 - -commit 75fb3cf458fe41b2c935f54b9e5734ced3dc0ece - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-10-15 00:02:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-15 00:02:38 +0900 - - [ruby/irb] Restore encoding in InputCompletor test - (https://github.com/ruby/irb/pull/732) - - https://github.com/ruby/irb/commit/ef77c232cf - -commit 177d8ee056636511379f6971a6c4e46675264cf7 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-10-14 23:42:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-14 23:42:37 +0900 - - [ruby/irb] Bump version to 1.8.3 - (https://github.com/ruby/irb/pull/731) - - https://github.com/ruby/irb/commit/de79375ac1 - -commit 8e477af1d4ba5380a00c89078bd9661b213b42af - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-14 09:23:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-14 23:15:54 +0900 - - [ruby/prism] Put names on back reference read nodes - - https://github.com/ruby/prism/commit/10a6403293 - -commit 4e5c505bad2a2c6c62992a74b503d7213fbc2b93 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-10-14 23:12:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-14 23:12:43 +0900 - - [ruby/irb] Restore IRB::InputCompletor for compatibility - (https://github.com/ruby/irb/pull/730) - - https://github.com/ruby/irb/commit/77265efc5f - -commit 96cd73d78f8986db0aaab9368c2ffa6867613a37 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-14 16:51:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-14 18:38:24 +0900 - - Ignore symbols even in empty shared library - - On some platforms, such as FreeBSD and Oracle Linux, symbols defined - in the crt0 setup routine are exported from shared libraries. So - ignore the symbols that would be exported even in an empty shared - library. - -commit eb79b0319bc9b04067bd9c795f9447dd03615df2 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-10-14 08:32:22 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-14 13:26:02 +0900 - - release sched_lock before VM lock - - to avoid deadlock - - ```ruby - r = Ractor.new do - obj = Thread.new{} - Ractor.yield obj - rescue => e - e.message - end - p r.take - ``` - - ``` - (lldb) bt - * thread #1, name = 'miniruby', stop reason = signal SIGSTOP - * frame #0: 0x0000ffff44881410 libpthread.so.0`__lll_lock_wait + 88 - frame #1: 0x0000ffff4487a078 libpthread.so.0`__pthread_mutex_lock + 232 - frame #2: 0x0000aaab617c0980 miniruby`rb_native_mutex_lock(lock=<unavailable>) at thread_pthread.c:109:14 - frame #3: 0x0000aaab617c1d58 miniruby`ubf_event_waiting [inlined] thread_sched_lock_(th=0x0000aaab9df82980, file=<unavailable>, line=46, sched=0x0000aaab9dec79b8) at thread_pthread.c:351:5 - frame #4: 0x0000aaab617c1d50 miniruby`ubf_event_waiting(ptr=0x0000aaab9df82980) at thread_pthread_mn.c:46:5 - frame #5: 0x0000aaab617c6020 miniruby`rb_threadptr_interrupt [inlined] rb_threadptr_interrupt_common(trap=0, th=0x0000aaab9df82980) at thread.c:352:25 - frame #6: 0x0000aaab617c5fec miniruby`rb_threadptr_interrupt(th=0x0000aaab9df82980) at thread.c:365:5 - frame #7: 0x0000aaab617379b0 miniruby`rb_ractor_terminate_all at ractor.c:2364:13 - frame #8: 0x0000aaab6173797c miniruby`rb_ractor_terminate_all at ractor.c:2383:17 - frame #9: 0x0000aaab61737958 miniruby`rb_ractor_terminate_all [inlined] ractor_terminal_interrupt_all(vm=0x0000aaab9dea3320) at ractor.c:2375:1 - frame #10: 0x0000aaab61737950 miniruby`rb_ractor_terminate_all at ractor.c:2424:13 - frame #11: 0x0000aaab6164f108 miniruby`rb_ec_cleanup(ec=0x0000aaab9dea5900, ex=RUBY_TAG_NONE) at eval.c:239:9 - frame #12: 0x0000aaab6164fa3c miniruby`ruby_run_node(n=0x0000ffff417ed178) at eval.c:328:12 - frame #13: 0x0000aaab615a5ab0 miniruby`main at main.c:39:12 - frame #14: 0x0000aaab615a5a98 miniruby`main(argc=<unavailable>, argv=<unavailable>) at main.c:58:12 - frame #15: 0x0000ffff44714b2c libc.so.6`__libc_start_main + 228 - frame #16: 0x0000aaab615a5b0c miniruby`_start + 52 - (lldb) thread select 3 - * thread #3, name = 'bootstraptest.*', stop reason = signal SIGSTOP - frame #0: 0x0000ffff448813ec libpthread.so.0`__lll_lock_wait + 52 - libpthread.so.0`__lll_lock_wait: - -> 0xffff448813ec <+52>: svc #0 - 0xffff448813f0 <+56>: eor w20, w20, #0x80 - 0xffff448813f4 <+60>: sxtw x20, w20 - 0xffff448813f8 <+64>: b 0xffff44881414 ; <+92> - (lldb) bt - * thread #3, name = 'bootstraptest.*', stop reason = signal SIGSTOP - * frame #0: 0x0000ffff448813ec libpthread.so.0`__lll_lock_wait + 52 - frame #1: 0x0000ffff4487a078 libpthread.so.0`__pthread_mutex_lock + 232 - frame #2: 0x0000aaab617c0980 miniruby`rb_native_mutex_lock(lock=<unavailable>) at thread_pthread.c:109:14 - frame #3: 0x0000aaab61823d68 miniruby`rb_vm_lock_enter_body [inlined] vm_lock_enter(no_barrier=false, lev=0x0000ffff215bfbe4, locked=false, vm=0x0000aaab9dea3320, cr=0x0000aaab9dec7890) at vm_sync.c:57:9 - frame #4: 0x0000aaab61823d60 miniruby`rb_vm_lock_enter_body(lev=0x0000ffff215bfbe4) at vm_sync.c:119:9 - frame #5: 0x0000aaab617c1b30 miniruby`thread_sched_setup_running_threads [inlined] rb_vm_lock_enter(file=<unavailable>, line=597, lev=0x0000ffff215bfbe4) at vm_sync.h:75:9 - frame #6: 0x0000aaab617c1b14 miniruby`thread_sched_setup_running_threads(vm=0x0000aaab9dea3320, add_th=0x0000aaab9df82980, del_th=<unavailable>, add_timeslice_th=0x0000000000000000, cr=<unavailable>, sched=<unavailable>, sched=<unavailable>) at thread_pthread.c:597:9 - frame #7: 0x0000aaab617c29b4 miniruby`thread_sched_wait_running_turn at thread_pthread.c:614:5 - frame #8: 0x0000aaab617c298c miniruby`thread_sched_wait_running_turn(sched=0x0000aaab9dec79b8, th=0x0000aaab9df82980, can_direct_transfer=true) at thread_pthread.c:868:9 - frame #9: 0x0000aaab617c6f0c miniruby`thread_sched_wait_events(sched=0x0000aaab9dec79b8, th=0x0000aaab9df82980, fd=<unavailable>, events=<unavailable>, rel=<unavailable>) at thread_pthread_mn.c:90:17 - frame #10: 0x0000aaab617c7354 miniruby`rb_thread_terminate_all at thread_pthread.c:3248:13 - frame #11: 0x0000aaab617c733c miniruby`rb_thread_terminate_all(th=0x0000aaab9df82980) at thread.c:466:13 - frame #12: 0x0000aaab617c7a64 miniruby`thread_start_func_2(th=0x0000aaab9df82980, stack_start=<unavailable>) at thread.c:713:9 - frame #13: 0x0000aaab617c7d1c miniruby`co_start [inlined] call_thread_start_func_2(th=0x0000aaab9df82980) at thread_pthread.c:2165:5 - frame #14: 0x0000aaab617c7cd0 miniruby`co_start(from=<unavailable>, self=0x0000aaab9df0f760) at thread_pthread_mn.c:421:9 - ``` - -commit 16d14f425f1452e9117b5a23af24bc93f570541a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-14 12:53:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-14 12:53:23 +0900 - - Avoid using MATZBOT_GITHUB_TOKEN for pull requests - -commit b28c1d2c5644c726bba60cd35ce9313da6e86a4f - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-10-14 08:50:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-14 11:22:42 +0900 - - [Bug #19926] Fix Range#size for ranges with a Rational endpoint - -commit 25072d2e878ea6093f04c67e90c5cef33d70080a - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-14 08:46:12 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-14 11:12:20 +0900 - - Fix node type casts - - Use new node type set by nd_set_type. - -commit a405b28e85cc48d2be24cf7baef528f646d3b212 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-13 19:21:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-14 11:08:43 +0900 - - Delete heredoc line mark references - -commit 5fc9810bf3a0ac6eb9964ff30b0e1060270ab597 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-13 19:13:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-14 11:08:43 +0900 - - Shorten `rb_strterm_literal_t` members - -commit a075c55d0c29fa5c99c5a3b6f25540cf14ddaefd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-13 19:07:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-14 11:08:43 +0900 - - Manage `rb_strterm_t` without imemo - -commit cb06b6632a0d6e33522d75cab7836ff457a452b5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-13 03:33:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-14 11:08:43 +0900 - - Remove unions in `rb_strterm` structs for alignment - -commit 82c8f22a36bfcb04c6ebd422b9201d5487bc4ba4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-14 08:33:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-14 08:33:07 +0900 - - Use the variable to skip the checkout - -commit 9d6ff9c175537296c96394332c662a1ffb9a83f6 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-14 08:31:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-14 08:31:07 +0900 - - Skip a duplicated checkout - -commit d7f8c1ee9d226bb1c2049d862127e0ba43b3b755 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-14 08:19:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-14 08:19:32 +0900 - - Just reorder the checkout - -commit 0950f22cc0c848a73f1b80d0e63fcde6cd437890 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-14 08:18:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-14 08:18:17 +0900 - - secrets cannot be templated in a shared action - -commit 563ba5a6f1c2927b449de35fad5bed87a3dd5253 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-14 08:13:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-14 08:14:02 +0900 - - Give a token to the shared checkout as well - -commit 275c18525c5bd48529fd676cde710f1dedf91b4d - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-10-14 02:41:44 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-14 08:12:53 +0900 - - Allow `NON_SCALAR_THREAD_ID` machines - - s390x (Ubuntu) still fails tests with 62dfaeec2c. - -commit 5b08e9efd807eae9bb9c0fcd2ab2029aa298fe7e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-14 07:21:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-14 07:21:54 +0900 - - Use matzbot's token to push misc commits - - to bypass status checks of branch protection - -commit f6564fdd37ae313b5e17b7acffef77fcf2b0e9f3 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-10-14 04:52:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-14 06:11:07 +0900 - - [ruby/prism] Simplify DedentingHeredoc#to_a - - Move common ``results << token`` outside case-when. - - https://github.com/ruby/prism/commit/84d0722ee9 - -commit 81fbacb59d39ceb2e2bc6dc6bf52d727f148bfdf - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-14 04:48:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-14 04:48:15 +0900 - - [ruby/prism] Make PM_NODE_FLAG_COMMON_MASK into a constant - - https://github.com/ruby/prism/commit/ec66feb595 - -commit e700582d983e5fc40da621ec4a82aa46da11302b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-14 04:40:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-14 04:45:37 +0900 - - [ruby/prism] Bump version to 0.14.0 - - https://github.com/ruby/prism/commit/1731bf4520 - -commit 42484d1281868a50dd06cd819aaa3d9f977b3ae2 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-10-14 02:30:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-14 04:38:57 +0900 - - [ruby/prism] Move common flags to top bits - - Moves the common flag bits to the top. This lets us eliminate the `COMMON` - constant, and also allows us to group encoding flags on a nibble so we - can more easily mask them. - - https://github.com/ruby/prism/commit/895508659e - -commit 17697c968e8cd00cdd581459c11868d1f2025f3a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-14 04:34:59 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:34:59 +0900 - - [prism] Remove unused make target - -commit b5ee570eb8e782bf1b4ba80e0268b466e01533b8 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-14 04:05:04 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [prism] Remove unescape targets - -commit 11e946da2fa1af217a78c631cfbd88db5d0b5148 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-13 00:38:57 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Fix up PR failings - - https://github.com/ruby/prism/commit/11255f636e - -commit d06523bc52a4486db4193d7a6771e76c31157777 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-13 00:10:17 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Remove now-defunct semantic_field from nodes - - https://github.com/ruby/prism/commit/c82a9dad64 - -commit 2de0299839e01f3f96554dc55ed20437553326ac - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-13 00:03:31 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Final unescapes cleanup - - https://github.com/ruby/prism/commit/bfcd8262a4 - -commit 10e7e5bc8e3974ab531769c4d14c49b872668782 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-12 23:21:18 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Refactor unescape test to simplify - - https://github.com/ruby/prism/commit/4392775898 - -commit 37d958eaf4c9704c9b1bd2d05753748200e6644d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-12 22:59:21 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - Remove old unescaping code - -commit fa76cddc5b1eebf77c9c5bbe951f70fd6c115716 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-12 21:46:40 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Properly handle unescaping in regexp - - https://github.com/ruby/prism/commit/abf9fd6863 - -commit e4f1c06a9bb6012ac155b7a7789d2b5cb4e8abdc - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-12 09:56:33 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Use current_string to handle :" symbols - - https://github.com/ruby/prism/commit/eedeec8f9a - -commit a1de76296655154e3d8db782721efa230c7b4619 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-12 09:52:55 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Use current_string for :' symbols - - https://github.com/ruby/prism/commit/fadb5be520 - -commit 8bf0d381dcf199f8e2a7b40e4b51bfe275f5d2a6 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-12 09:45:39 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Use current_string for %s symbol literals - - https://github.com/ruby/prism/commit/52504f8911 - -commit d0614b5254d1767cdffdd32f13897dc10facc6a2 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-12 02:58:00 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Split up lines in tilde heredocs - - https://github.com/ruby/prism/commit/21fad0c2ce - -commit ad46fc093b1344b4129ef5199060402e9270b652 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-12 01:39:41 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Calculate heredoc common whitespace while lexing - - https://github.com/ruby/prism/commit/c3f43b64a3 - -commit d6424453dbb8cd2794e22a7d3ba400732e709ec2 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-12 00:12:41 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Enable remaining heredoc unescape tests - - https://github.com/ruby/prism/commit/c7ea4941c5 - -commit 24768d8a5786fe801b346b690a43bf256a380835 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 23:59:26 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Use current_string for escapes in heredocs - - https://github.com/ruby/prism/commit/fc49acfc59 - -commit 1a7364b3479603f94ee4287673ff8a1cc6577658 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 23:32:35 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Use create_unescaped functions for empty heredocs - - https://github.com/ruby/prism/commit/acec5a13cb - -commit da47a713258dd053f5d9170712be3d96c9e7d375 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 23:28:36 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Use current_string for x string escape sequences - - https://github.com/ruby/prism/commit/66ce9280bb - -commit a7f71e461e06288b02097a380158917ce495867f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 23:15:05 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Use token buffer for string lexing - - https://github.com/ruby/prism/commit/087cd8f28b - -commit 973ecf684884d4eaea970dcad18ee468b39d87c4 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 23:12:00 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Extract out a couple more token buffer functions - - https://github.com/ruby/prism/commit/341e027d23 - -commit af8484bc39bd5c4668fdafa528179b9a2fdebd23 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 23:02:16 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Capture the token buffer logic into its own struct and functions - - https://github.com/ruby/prism/commit/4334f0775b - -commit ef1e5b65dc14e1b76265eb9792545da2d9f3aa23 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 04:22:29 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Use current_string to handle escapes in string literals - - https://github.com/ruby/prism/commit/d912d48104 - -commit f64a0434dd215dbefa8c38e8768c68ea431e8d01 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 03:37:06 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Use current_string to handle %I - - https://github.com/ruby/prism/commit/831d5f4b45 - -commit 5fc34f1cde041e72597c873d3ada8f3b039b991f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 03:28:15 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Use current_string for handling %W lists - - https://github.com/ruby/prism/commit/edb1674725 - -commit 41ac8ddca34445076aba16504e1eeacae3cefed5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 03:22:23 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Extract out string handling for %W lists - - https://github.com/ruby/prism/commit/dba9bd6b1f - -commit 3c743445d727b2e1444c5aae4113056de4bdd530 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 03:14:59 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Use current_string to handle %i escapes - - https://github.com/ruby/prism/commit/9c90d0a777 - -commit 4e3013f42d4562d8e84e88e20e2f76668e8a58f6 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 03:13:53 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Use current_string to handle %w escapes - - https://github.com/ruby/prism/commit/b8420ea7ae - -commit 3dba3ab47d8d83378d916610d8f4769663ebdf27 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-11 00:28:41 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Strip out old char unescaping - - https://github.com/ruby/prism/commit/27ca207ab3 - -commit dd3986876a96f9e9fec078247d7d40b322f8fd17 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-10 23:52:44 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Handle remaining escape sequences for character literals - - https://github.com/ruby/prism/commit/ba33607034 - -commit 1a941c70e42c1e64b961088e953ded6a148e1351 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-07 11:00:01 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Track current_string to pass forward for character literals - - https://github.com/ruby/prism/commit/be1d8ae8bb - -commit e179e62bd22f85557decca5bfb81ea511ee5c5de - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-07 10:31:49 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Skip tests that are currently failing - - https://github.com/ruby/prism/commit/23b2336148 - -commit a0a0cd0caa2fc05e184afe6b932dc3e730a70351 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-07 10:25:05 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] Fix escaped 8 and escaped 9 - - https://github.com/ruby/prism/commit/c3a46e2de5 - -commit 8e223366fc30720582f9348f7a1426fe1fa7a9db - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-07 09:56:27 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-14 04:31:30 +0900 - - [ruby/prism] More thoroughly test unescapes - - https://github.com/ruby/prism/commit/e86196dde6 - -commit d7058852861d9d4cf762492057254a8b9e966b36 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-14 04:24:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-14 04:24:40 +0900 - - [PRISM] Add --dump=prism mode (#8643) - -commit 34add1e5955742d46f5138b3ded4a6d149675b9b - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-10-14 02:59:37 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-14 02:59:37 +0900 - - [PRISM] Compile fixes (#8644) - - * Fix compiling UndefNodes - * Fix compiling super on ClassNode - * Fix compile popped for ModuleNode - * Add checks for NULL nodes - * Only add newhash if not popped - -commit 92bdc3757f078138fe34a87c9db1b497fc00f68f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-14 01:39:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-14 01:40:44 +0900 - - Ignore the failures of CodeQL - - It randomly fails like this: - https://github.com/ruby/ruby/actions/runs/6510372995/job/17683918027 - - and we don't want to pay for and use a larger runner for the job that - only generates false positives most of the time. - -commit 62dfaeec2c3f6be255f48419307e69bfcfb3d849 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-10-13 23:53:59 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-14 00:52:51 +0900 - - disable MN schedulers for some platforms - - * on `__EMSCRIPTEN__` provides epoll* declarations, but no implementations. - * on `NON_SCALAR_THREAD_ID`, now we can not debug issues on x390s/Ubuntu so skip it. - - x390s/RHEL works fine, so I think we can remove second limitation but - I could not login to it so it seems hard to debug now. - -commit 0bf1749e9fcef24bf7bebbce2a62ee6c766d4c7c - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-10-13 23:41:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-13 23:41:53 +0900 - - YJIT: Fix argument clobbering in some block_arg+rest_param calls (#8647) - - Previously, for block argument callsites with some specific argument - count and callee local variable count combinations, YJIT ended up - writing over arguments that are supposed to be collected into a rest - parameter array unmodified. - - Detect when clobbering would happen and avoid it. Also, place the block - handler after the stack overflow check, since it writes to new stack - space. - - Reported-by: Takashi Kokubun <takashikkbn@gmail.com> - -commit 35edc14ee15332e192b6665df88c9bc0974d6bb7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-13 14:56:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-13 16:22:09 +0900 - - Ignore duplicated warning with native extension - -commit c6728caeb7ad63963737bd43f53cf4a667990b77 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-12 17:33:52 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-13 16:22:09 +0900 - - Fix wrong gem name - -commit fe5329f032c4c71b58ffe5ca3ba32ed955adfc01 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-12 16:59:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-13 16:22:09 +0900 - - Ignore warning on LoadError when running under Bundler - -commit 62eea99a1c492530319f63411cf54294b9d73791 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-12 16:53:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-13 16:22:09 +0900 - - Added recovery instructions for RubyGems - -commit fdf0589a954343c963731cf4b9e97fef6de415a3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-12 16:53:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-13 16:22:09 +0900 - - Surpressing double warnings - -commit b49346ee7344b6febd69cf2d1dd8161b6a4e774e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-12 16:38:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-13 16:22:09 +0900 - - Warn only LoadError without Bundler environment - -commit ba4fed47ecdf4bf80cb8be9f1ed5669a6a8a5988 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-12 15:45:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-13 16:22:09 +0900 - - Removed examples for warning bundled gems - -commit 57c2ae206f46e3c37ec8927dc51cffc53d47cda8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-12 14:48:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-13 16:22:09 +0900 - - Move additional warnings for Gem author under Gem::BUNDLED_GEMS. - -commit ea05ddbeff99b1c0766b0171d11a9fa84dce62ec - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-12 13:32:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-13 16:22:09 +0900 - - Move path normalization into Gem from Bundler class - -commit c2bdb198d78508853609257058aaebb6c364af7c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-12 13:24:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-13 16:22:09 +0900 - - Dont't handle inline Gemfile - -commit 75644f98e52075073a896704d1b16cb76b404fc9 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-12 12:53:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-13 16:22:09 +0900 - - Use Gem::BUNDLED_GEMS.warning? at Bundler.setup - -commit d8a74207e7a4e4ae92b33b0a12a5351270ebbe75 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-10-13 14:39:53 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-13 15:59:09 +0900 - - use `uint32_t` instead of `__uint32_t` - -commit 842d9c0afc525ef02396bf86c722da675bc6f69f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-13 09:30:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-13 09:30:04 +0900 - - Remove paths-ignore from required status checks (#8646) - -commit cdb36dfe7ddb7cbd7ed95e84b24114c8869a7e5e - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-10-13 01:14:17 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-13 09:19:31 +0900 - - fix `native_thread_destroy()` timing - - With M:N thread scheduler, the native thread (NT) related resources - should be freed when the NT is no longer needed. So the calling - `native_thread_destroy()` at the end of `is will be freed when - `thread_cleanup_func()` (at the end of Ruby thread) is not correct - timing. Call it when the corresponding Ruby thread is collected. - -commit 2794a8fef65eb16767c2f46f8f5058c10b4591b9 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-10 21:06:54 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-13 07:35:24 +0900 - - [Bug #19919] Warn class variable assignment and constant declaration in condition - -commit dcee3cc6ce026707e2eb142b117de445b723eecc - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-13 06:57:08 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-13 07:15:37 +0900 - - Avoid duplicating a --repeat-count=2 job - - --repeat-count=2 jobs are generally too slow for no good reason. - It doesn't seem related to testing the universal parser either. - -commit 3aba21511b37723b5212e44429f5e8585f53453a - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-10-13 06:35:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-13 06:36:13 +0900 - - [ruby/irb] Bump version to 1.8.2 - - https://github.com/ruby/irb/commit/47693a2213 - -commit 81399a5c464c8eafdb68fddb5e26a519390cd069 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-13 02:32:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-13 02:32:45 +0900 - - Use `lex_eol` macros - -commit 17b0643392749f45b7aacb64fc1c1bd704d42b4c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-13 02:28:35 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-13 02:28:35 +0900 - - [Bug #19924] Source code should be unsigned char stream - - Use `peekc` or `nextc` to fetch the next character, instead of reading - from `lex.pcur` directly, for compilers that plain char is signed. - -commit 2dca02e273489c802a9860284a17333ddf67f161 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-10-13 01:31:02 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-13 02:11:29 +0900 - - disable MN scheduler on !`USE_MN_THREADS` - -commit 1126bd8c65ab077392b559fedd8f9b07303313c9 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-10-13 01:54:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-13 01:54:09 +0900 - - [ruby/irb] Fix require path completion disturbing string method - completion - (https://github.com/ruby/irb/pull/726) - - https://github.com/ruby/irb/commit/e42dc74ce0 - -commit 10ba3fc302d68f977ce958b27a46ce0dab537f0c - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-10-12 23:35:12 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-13 01:09:41 +0900 - - Use `sysconf()` to get PAGE_SIZE - - Some systems use not 4096 page size (64KB for example). - -commit 4387af1b4a16fbd181a7c42424ffb8cf92d55110 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-10-12 06:35:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-13 01:01:40 +0900 - - [ruby/prism] Fix parsing symbols in strings after labels - - https://github.com/ruby/prism/commit/e16531650d - -commit 5c8764477faeae1c6f866b2613b4319ba183a86b - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-10-12 06:13:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-13 00:26:29 +0900 - - [ruby/prism] Increase the depth for the For node index variable - - In CRuby's parser locals in for nodes appear deeper in the ast than they - do in Prism, but we can fix that with a transparent scope - - https://github.com/ruby/prism/commit/460187f41e - -commit c23b25f75f6180b7428f9650e063b1e50fc161e2 - Author: Tanaka Akira <akr@fsij.org> - AuthorDate: 2023-10-13 00:00:58 +0900 - Commit: Tanaka Akira <akr@fsij.org> - CommitDate: 2023-10-13 00:00:58 +0900 - - describe the assumption for Range#overlap?. - - Range#overlap? assumes that there is no minimum value. - This assumption makes - +(...-Float::INFINITY).overlap?((...-Float::INFINITY))+ returns true - while +(...-Float::INFINITY)+ is empty. - -commit b2e1ddffa55463f1180af7f9b269a2d89140b131 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-10-12 23:05:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-12 23:05:34 +0900 - - YJIT: port call threshold logic from Rust to C for performance (#8628) - - * Port call threshold logic from Rust to C for performance - - * Prefix global/field names with yjit_ - - * Fix linker error - - * Fix preprocessor condition for rb_yjit_threshold_hit - - * Fix third linker issue - - * Exclude yjit_calls_at_interv from RJIT bindgen - - --------- - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - -commit 0c42c28531ea73a4a3e09dc12abe9f3264b87860 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-12 23:03:47 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-12 23:03:47 +0900 - - Test YJIT on macOS Arm64 GitHub Actions (#8633) - - * cp macos.yml yjit-macos.yml - - * Test YJIT on macOS Arm64 GitHub Actions - - * Add a non-YJIT macOS Arm64 job as well - -commit cf21c72cdbe9a9481925c978eccd211f7e9536ef - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-10-12 22:55:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 22:55:47 +0900 - - [ruby/irb] Fix test runner exit bug - (https://github.com/ruby/irb/pull/728) - - * Remove useless test setup and teardown that sets MAIN_CONTEXT to nil - - * Avoid adding command methods to main object in test - - https://github.com/ruby/irb/commit/f204829a08 - -commit e029375a7dc59897931fd3cfe334ffd4864f5049 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-10-12 21:53:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 21:53:31 +0900 - - [ruby/irb] Decouple RubyLex from prompt and line_no - (https://github.com/ruby/irb/pull/701) - - * Remove instance variable prompt and line_no from RubyLex - - * Fix prompt test - - * Rename prompt generating method and make it private - - https://github.com/ruby/irb/commit/1ceb97fe2e - -commit 9694445051c4192c8f659529133acab253bd0bc3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-09 19:38:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-12 19:26:07 +0900 - - [Feature #19422] Enable shared by default on macOS - -commit 52709a4862b91f2c7c0f0555d29f21ec3ed942d0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-12 15:54:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-12 17:46:01 +0900 - - Fix `dir_config` cache for -include and -lib options - - Set to "--with-" options, not "--without-" keys. - -commit 1cef5f597d24c55af3454ca652a06d7fa651d6b0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-12 15:07:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-12 17:46:01 +0900 - - Include default values in `dir_config` cache keys - - The extconf.rb in mysql2 gem repeats `dir_config('mysql')`, without - and with the default path. The third call returns the former results - even with the default path. Since it does not check the results of - the third call, that `nil` is passed to `find_library` as a path, and - fails with `NoMethodError`. - -commit 769f53eb7e9db306988bb99802b15942c1c755c3 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-09-28 13:10:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-12 17:34:49 +0900 - - Add benchmarks for Range#reverse_each - -commit 66fabefa0312859f5bbd7c95d745b677e44b20be - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2022-01-26 13:13:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-12 17:34:49 +0900 - - Add Range#reverse_each implementation for performance - -commit 1c871c08d9dc9893968067de339abd0e05836d74 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-10-12 03:30:10 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-10-12 17:22:32 +0900 - - Switch mid dump to dump_append_string_value - - I don't think it's possible to create a CI with a mid which would need - escaping to be in a JSON string, but I think we might as well not rely - on that assumption. - -commit 635b92099e7ddd1b2eca065134efcfdc7ad7bab3 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-10-12 03:09:04 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-10-12 17:22:32 +0900 - - Fix ObjectSpace.dump with super() callinfo - - super() uses 0 as mid for its callinfo, so we need to check for that to - avoid a segfault when using dump_all. - -commit feac15c1f3479f7d7641480a4608f3ac5d3b2fca - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-19 11:36:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 14:58:31 +0900 - - [ruby/securerandom] Extract `assert_uuid_v7` - - https://github.com/ruby/securerandom/commit/029677584d - -commit be1bbd5b7d40ad863ab35097765d3754726bbd54 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-04-10 10:53:13 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-12 14:47:01 +0900 - - M:N thread scheduler for Ractors - - This patch introduce M:N thread scheduler for Ractor system. - - In general, M:N thread scheduler employs N native threads (OS threads) - to manage M user-level threads (Ruby threads in this case). - On the Ruby interpreter, 1 native thread is provided for 1 Ractor - and all Ruby threads are managed by the native thread. - - From Ruby 1.9, the interpreter uses 1:1 thread scheduler which means - 1 Ruby thread has 1 native thread. M:N scheduler change this strategy. - - Because of compatibility issue (and stableness issue of the implementation) - main Ractor doesn't use M:N scheduler on default. On the other words, - threads on the main Ractor will be managed with 1:1 thread scheduler. - - There are additional settings by environment variables: - - `RUBY_MN_THREADS=1` enables M:N thread scheduler on the main ractor. - Note that non-main ractors use the M:N scheduler without this - configuration. With this configuration, single ractor applications - run threads on M:1 thread scheduler (green threads, user-level threads). - - `RUBY_MAX_CPU=n` specifies maximum number of native threads for - M:N scheduler (default: 8). - - This patch will be reverted soon if non-easy issues are found. - - [Bug #19842] - -commit 5140e6a4c3b7771830e3dd07e31626f81401f8e2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-12 08:22:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-12 08:22:20 +0900 - - Fix calling exit if irb_context is nil - - Trying to avoid a flaky failure like: - https://github.com/ruby/ruby/actions/runs/6486918029/job/17616113816 - -commit 70d583a7e08a948c33a1c55c46e30ed4df27aa48 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-12 08:05:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-12 08:05:16 +0900 - - Specify everything in matrix.include - - ubuntu.yml had that style because it needed a default value for configure. - For macos.yml, since `os` and `configure` always vary, there's no need - to declare them that way. - -commit eee1ea2a0e4dece6d5012460563a3550f349e3b6 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-12 07:56:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-12 07:56:17 +0900 - - Add test_task in the matrix for better labels - - They appear on GitHub and this looks nicer. - -commit 09a79d39d0838ddcd7ca691bef4cb06d9da761ba - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-12 07:55:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-12 07:55:01 +0900 - - Fix the way to specify extra jobs - -commit eca1c2e717e6a16e7abbf591f63d5a223c124023 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-12 07:50:29 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-12 07:50:38 +0900 - - Remove redundancy in macOS jobs - - I don't think we need to test the same OS twice or the same - configuration twice. This is similar to .github/workflows/ubuntu.yml. - - I also tweaked the label of Slack notifications. - -commit 94508a8a60bd3cc783ac48961c6857342f46e872 - Author: αlpha 0x00 <leetiankai@gmail.com> - AuthorDate: 2023-10-12 01:48:31 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-12 07:26:24 +0900 - - Fix Typo - -commit 9dcaa832592af0125ba6407a506b2b3953b2f81c - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-10-11 09:27:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 07:18:46 +0900 - - [rubygems/rubygems] Avoid excess Arrays when partitioning Gem::Version.canonical_segments - - https://github.com/rubygems/rubygems/commit/338c48f935 - -commit 8a8b23c0ccbb8450c99635c7be9ee871409ba17f - Author: Ellen Marie Dash <the@smallest.dog> - AuthorDate: 2023-10-01 08:13:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 04:07:29 +0900 - - [lib/rubygems/path_support.rb] Rephrase comment - - Co-authored-by: David Rodríguez <deivid.rodriguez@riseup.net> - -commit be32109d64be81e796d44880aab966aabb4ae294 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-09-30 16:17:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 04:07:29 +0900 - - [rubygems/rubygems] Move "Defaulting to user installation ..." message, so `--install-dir` and `--user-install` can suppress it. - - https://github.com/rubygems/rubygems/commit/6677fc6853 - -commit 28a6c4a1ad4935e1a0af7904e17733555988b88a - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-09-30 13:30:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 04:07:28 +0900 - - [rubygems/rubygems] Update incorrect comments. - - https://github.com/rubygems/rubygems/commit/6b21f593f3 - -commit c83f8ad8671afbd8e9ae70c2c4e69a80c6a96d67 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-09-30 12:50:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 04:07:28 +0900 - - [rubygems/rubygems] Simplify logic for Gem::PathSupport#home, and make GEM_HOME always overide it. - - https://github.com/rubygems/rubygems/commit/64273fd7e3 - -commit e84b73398b96ea7abbeb3a17caae71b365f5016d - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-09-30 11:59:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 04:07:28 +0900 - - [rubygems/rubygems] Call check_that_user_bin_dir_is_in_path ANY time Gem.paths.home == Gem.user_dir. - - (As opposed to only if `--user-install` is passed.) - - https://github.com/rubygems/rubygems/commit/0b42d0e869 - -commit ee9cb86bb49db0fe1613a5121a89587630506780 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-09-30 10:48:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 04:07:27 +0900 - - [rubygems/rubygems] Split out Gem::PathSupport#default_home_dir to fix "bundle doctor" specs. - - https://github.com/rubygems/rubygems/commit/d7f3f901f1 - -commit 0b9b07a717a31b7f3c87a9097c9fe1833efe9b1d - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-09-29 12:15:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 04:07:27 +0900 - - [rubygems/rubygems] Allow test_gem_install_update_options to raise Errno::ACCES, in addition to Gem::FilePermissionError. - - https://github.com/rubygems/rubygems/commit/784fe2a814 - -commit 225c05e3ec42a43ec21092017291ba24a51ccb15 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-09-29 11:30:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 04:07:27 +0900 - - [rubygems/rubygems] Update tests to match new implementation of falling back to user-writable directories. - - https://github.com/rubygems/rubygems/commit/a06e657ac6 - -commit 262f345344e23fb6db45e3796d3f717f30207f9e - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-09-29 10:59:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 04:07:26 +0900 - - [rubygems/rubygems] [test_gem_install_update_options.rb] Fix linter warnings. - - https://github.com/rubygems/rubygems/commit/cdcb8394f6 - -commit 4925570de260def52f722b0aec59ca6ef5b53cb9 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-04-01 11:24:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 04:07:26 +0900 - - [rubygems/rubygems] Try a different approach for fallback to --user-install. - - https://github.com/rubygems/rubygems/commit/13e0704c40 - -commit 7aebe2a52bac2a925c475c511640ad13a7d20490 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2022-02-01 13:20:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 04:07:26 +0900 - - [rubygems/rubygems] If GEM_HOME exists + isn't writable, use --user-install. - - https://github.com/rubygems/rubygems/commit/6d20585645 - -commit 9af5abd23acf567f5a5a88c3dbdd7676342256fa - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-10-06 18:18:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 03:26:00 +0900 - - [ruby/prism] Allow Scope nodes to be created for a For loop - - https://github.com/ruby/prism/commit/ded8711807 - -commit 802ca3a1023e8018599d36fda250cbe64e77013c - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-10-11 21:26:35 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-10-12 03:14:39 +0900 - - `RUBY_DEBUG_LOG` supports `%p` for pid - -commit f413e50ec22046dcdc8655061f9a7a5e5c1b9508 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-12 00:02:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 02:55:36 +0900 - - [ruby/prism] Add Node::type - - https://github.com/ruby/prism/commit/ca4943e3f9 - -commit 94cb5765e2e44716800cd466c64f81c048aaf95b - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-10-12 02:08:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 02:09:05 +0900 - - [ruby/irb] Rename current completor to RegexpCompletor and - refactored for future extension - (https://github.com/ruby/irb/pull/707) - - * Move completion implementation to completion/regexp_completor for future extension - - * Remove constant CompletionProc and PerfectMatchedProc and add a class method - - * Move document display logic to InputCompletor. Each completor only need to implement `completion_caididates` and `doc_namespace` - - * Move display_document logic to RelineInputMethod - - * Use RegexpCompletor directly. Not through class method of InputCompletor. - - * RegexpCompletor extends BaseCompletor, move back definition to completion.rb - - * Move display_document test to input_method test - - * Stop re-initialize completor on each completion phase - - * Store completor to ReadlineInputMethod's iver - - https://github.com/ruby/irb/commit/1e98521483 - -commit b9a6fca67d97f7319b20b24427d6dc4b8290cd24 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-10-11 08:41:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-12 02:02:25 +0900 - - [rubygems/rubygems] Don't delete the release version from pre-release string more than once - - https://github.com/rubygems/rubygems/commit/6485adda54 - -commit cc311e1c4599200dd7437cd578e61c83067e555c - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-10-11 23:16:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-11 23:16:39 +0900 - - [ruby/irb] Avoid locking the debug UI to a single thread - (https://github.com/ruby/irb/pull/725) - - Since `debug` stores and updates the target thread via its Session's - `@tc` variable, we don't need to and shouldn't lock the UI to the thread - that activates the integration. - - https://github.com/ruby/irb/commit/202efdbf0c - -commit f9fe7aeef46fc1e7782a942aaafa2b157b5548de - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-10 21:24:39 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-11 19:22:34 +0900 - - Extract NODE_FL_NEWLINE access to macro - -commit b17ae8889444bc3437ec88265cf9d90c9064def4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-11 14:09:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-11 15:45:17 +0900 - - [flori/json] skip TruffleRuby - - https://github.com/flori/json/commit/bab704eb49 - -commit e42df781d95c9558fbf552eed6cd2c4e4bd3f782 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-11 13:57:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-11 15:45:17 +0900 - - [flori/json] define_method is also private at Ruby 2.3 and 2.4 - - https://github.com/flori/json/commit/3804f38bf4 - -commit 1b19e9198d92e7eac3f3c5402243d6f7a052ede3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-11 13:55:39 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-11 15:45:17 +0900 - - [flori/json] remove_method of Module is private at Ruby 2.3 and 2.4 - - https://github.com/flori/json/commit/6cbadf6b6e - -commit e3afc212ec059525fe4e5387b2a3be920ffe0f0e - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-10-11 05:17:30 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-10-11 15:33:09 +0900 - - shape.h: Make attr_index_t uint8_t - - Given `SHAPE_MAX_NUM_IVS 80`, we transition to TOO_COMPLEX - way before we could overflow a 8bit counter. - - This reduce the size of `rb_shape_t` from 32B to 24B. - - If we decide to raise `SHAPE_MAX_NUM_IVS` we can always increase - that type again. - -commit 8f6a96e6ada05b2716ee6f441fd246beb5148426 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-11 15:09:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-11 15:13:53 +0900 - - [ruby/psych] Bump up v5.1.1 - - https://github.com/ruby/psych/commit/f306512d60 - -commit 40ab7b8c244de20007cb45846f41de3a01f7ea0c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-11 13:46:56 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-11 13:46:58 +0900 - - Skip test_bug_13526 with High Sierra - -commit 0fb10074e1be3031cef803d78ae8127239a99141 - Author: Kazuhiro NISHIYAMA <zn@mbf.nifty.com> - AuthorDate: 2023-10-11 11:38:04 +0900 - Commit: Kazuhiro NISHIYAMA <znz@users.noreply.github.com> - CommitDate: 2023-10-11 13:32:54 +0900 - - Fix error when gems/src is read-only - - When I shared srcdir as read-only in lima-vm, - `make install` causes following error: - - ``` - Update rbs to 33813a60752624d58dfe5ae770b39bfaf29fbaf1 - error: cannot open .git/FETCH_HEAD: Read-only file system - ``` - - I cannot find any ignore option for `git checkout --detach` - when already checked out. So I add `if`. - -commit 4d0a619f712bfd189dcedcf9998b143a731a2211 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-11 06:54:19 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-11 06:54:19 +0900 - - YJIT: Allow --yjit-trace-exits on release builds (#8619) - -commit a6d190fa4d33a848f063c3eec035035e34e55998 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-10-11 02:10:47 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-11 02:10:47 +0900 - - Update yjit.md - -commit 5cc44f48c51974a84a40480477a4afd8901ae7e4 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-10-10 20:12:17 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-10-10 21:47:54 +0900 - - Refactor rb_shape_transition_shape_capa to not accept capacity - - This way the groth factor is encapsulated, which allows - rb_shape_transition_shape_capa to be smarter about ideal sizes. - -commit fd21460898d2d5044c1bcc140927142921424791 - Author: Cody Cutrer <cody@instructure.com> - AuthorDate: 2023-10-10 02:35:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-10 18:02:10 +0900 - - [rubygems/rubygems] Update bundle-plugin man page - - The formatting was odd, and it hadn't been updated for how the global - source is handled. - - https://github.com/rubygems/rubygems/commit/bf19a266ab - -commit 47274ba8c1faa3dedcb3c44c6d5082e4d673591f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-10 12:21:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-10 16:32:40 +0900 - - Extract numparam nterms - -commit 9095e712a36ba8a707ec3c38088221314c17f3a1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-10 12:05:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-10 16:32:40 +0900 - - Use `rb_node_exits_t` instead of `NODE` - -commit e2998c42e1baa1cdb9dfb9298d492fd2c38fadce - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-10 11:59:01 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-10 16:32:40 +0900 - - Forward declaration of `struct RNode_DEF_TEMP` and its typedef - -commit c68f92aa584b1914fc5b169718a8803c6d1fe496 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-10-10 16:00:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-10 16:00:15 +0900 - - Update bundled gems list at 2023-10-10 - -commit 5245123a4b0f0457e0f6fcbf44bf9a8488ec21ee - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-10 08:00:31 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-10 11:05:29 +0900 - - Remove not used fields from DEFN - -commit c3fc70cc93ca7e8e29382372460c41734b4a7145 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-10-08 03:04:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-10 05:15:47 +0900 - - [rubygems/rubygems] Exempt default gem 'etc' in setup tests for rubies before 3.2 on windows - - https://github.com/rubygems/rubygems/commit/834ae8a29a - -commit a8d71535ffdf778e9de76bf013d71ce81ae4d333 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-09 22:57:21 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-10 00:09:52 +0900 - - Pre-allocate `NODE_DEFN`/`NODE_DEFS` nodes - - To fix the order of node IDs, for typeprof tests. - -commit 4c00ab7fd69ea0244e9e6617c4b42562d56df824 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-09 17:32:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-10 00:09:52 +0900 - - Refactor NODE_DEF_TEMP - - Use `NODE_DEF_TEMP` as the wrapper of `NODE_DEFS` in ripper, not only - of `NODE_DEFN`, so that `endless_method_name` works consistently. - -commit ceec988f2ebb22ada1c132ddcd64c38501748dc0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-09 19:58:14 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-10 00:09:52 +0900 - - ripper: Support member references in the DSL - -commit f44cee90480c103d911836f92a4e0e20c0eca1e5 - Author: Jacopo <beschi.jacopo@gmail.com> - AuthorDate: 2023-09-26 17:13:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-09 20:54:10 +0900 - - [rubygems/rubygems] Avoid duplicates -rbundler/setup in RUBYOPT with Ruby preview - - When using a Ruby preview the require path of `bundler/setup` is - similar to `-r/opt/ruby3.3.0-preview2/lib/ruby/3.3.0+0/bundler/setup`. - The special character `+` in the string makes the Regexp fail, - leading to multiple addition of the same require statement each time - `set_rubyopt` is called (e.g. server reloading). - Escaping the characters in the string esure a correct match with all - the different Ruby versions. - - https://github.com/rubygems/rubygems/commit/dd43dfa709 - -commit 0fdee133fccbd34af31f5f4ca530838920d8fc06 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-10-06 22:29:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-09 19:16:01 +0900 - - [ruby/prism] Attach the ast node to the scope - - So when building instruction sequences for a scope we can reference - items from the ast node that requires the scope. This is useful for for - loops, where the local variable tables from the parent scope will need - to be referenced. - - https://github.com/ruby/prism/commit/426b1ca094 - -commit 8c2a4932331987586d583fa58a6e80920c6743c5 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-09 15:57:40 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-09 19:08:23 +0900 - - Fix cast node type - -commit 3049b5e348be2595e4b8c5dbddcdaef5a82d0276 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-09 09:27:24 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-09 13:33:36 +0900 - - Differentiate VAR nodes - -commit 09b33ea15a10985b3260df055a4b58f335bb8c98 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-09 09:20:53 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-09 13:33:36 +0900 - - Differentiate CALL nodes - -commit b9a2348632514234ed2f175a50c0485a206a9e12 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-08 19:53:29 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-09 12:38:32 +0900 - - Take care of internal node type - - In parse.y, node can be NODE_DEF_TEMP or NODE_EXITS. - Hit "unknown node" without taking care of them. - For example `ruby --dump=y lib/cgi/util.rb` causes - "[BUG] unknown node: 107". - -commit b5d74f4f26c2c8b1d20dc0ceb0affece1ec96c3a - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-08 11:23:42 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-08 16:34:32 +0900 - - Remove not used fields from EVSTR - -commit 2b6228be48dc656c3e7a95919622e4b8561324cf - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-19 05:56:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-08 13:17:15 +0900 - - [rubygems/rubygems] Reduce allocations when parsing compact index - - This still allocates a ton (a string for each line, plus a bunch of - splits into arrays), but it helps a bit when Bundler has to go through - dependency resolution. - - ``` - ==> memprof.after.txt <== - Total allocated: 194.14 MB (2317172 objects) - Total retained: 60.81 MB (593164 objects) - - ==> memprof.before.txt <== - Total allocated: 211.97 MB (2404890 objects) - Total retained: 62.85 MB (640342 objects) - ``` - - https://github.com/rubygems/rubygems/commit/c68b41b0e5 - -commit bf71b0eda54b551db023cda9051b9be218c0f75d - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-19 04:47:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-08 01:04:42 +0900 - - [rubygems/rubygems] Optimize allocations in Gem::Version - - From running in a random rails app I have locally, here are the changes - - 1) for `bundle lock --update --bundler` (forcing Bundler to go through - dependency resolution) - - ``` - ==> memprof.after.txt <== - Total allocated: 2.98 MB (48307 objects) - Total retained: 1.21 MB (16507 objects) - - ==> memprof.before.txt <== - Total allocated: 12.62 MB (198506 objects) - Total retained: 1.30 MB (23133 objects) - ``` - - 2) for `bin/rails runner true` (essentially only bundler/setup) - - ``` - ==> memprof.after.txt <== - Total allocated: 59.50 kB (1017 objects) - Total retained: 25.08 kB (362 objects) - - ==> memprof.before.txt <== - Total allocated: 561.82 kB (8575 objects) - Total retained: 27.28 kB (513 objects) - ``` - - https://github.com/rubygems/rubygems/commit/35c8ed2cb8 - -commit 5810304c2edce3f9e889b4f55cf5c442a92d1a48 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-07 10:46:08 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-07 17:54:35 +0900 - - Remove not used fields from asgn nodes - -commit 529a651f82855956b6bd54794d629f91964e9de9 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-07 10:37:33 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-07 17:54:35 +0900 - - Differentiate ASGN nodes - -commit fbd534679fc2bbb6d81c858e47c3b2d51241e840 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-07 10:24:50 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-07 17:54:35 +0900 - - Correctly casting node for accessing nd_value and nd_vid in compile.c - -commit b7ee728a8332645220d4d4732e035a6700216261 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-07 10:10:45 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-07 17:54:35 +0900 - - Correctly casting node for accessing nd_value and nd_vid in parse.y - -commit f28d3803741f4e58b24154afbcead3726044ec4d - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-07 09:52:06 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-07 17:54:35 +0900 - - Pass nd_value to NODE_REQUIRED_KEYWORD_P - -commit b1a3c11c86fe93fb95fb7257b538c24e74aacbe2 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-07 09:46:01 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-07 17:54:35 +0900 - - Use rb_node_masgn_t instead of NODE - -commit 7eccc13c1f0be27063c979f94c34497712093bfd - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-10-06 21:18:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-06 23:10:28 +0900 - - [ruby/prism] Emit error when assigning to a numbered parameter - - https://github.com/ruby/prism/commit/66248ac2f6 - -commit 7b8d472100332c77bb47a2e4834459c4a625d109 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-06 19:03:51 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-06 22:20:19 +0900 - - [DOC] Fix platform-dependent directives and modifiers - - * 'j' and 'J' are not pointer directives. - * size of 'j' and 'J' are platform-dependent, may not be 64-bit. - * mention corresponding C types when native-size modifier is added. - - Co-Authored-By: BurdetteLamar <burdettelamar@yahoo.com> - -commit 7db4ce13ed051bc422c5db594bb41edbaeb1ae35 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-10-06 04:41:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-06 21:21:03 +0900 - - [ruby/prism] Introduce transparent scopes. - - A transparent scope is a scope that cannot have local variables added to - it's local table. When a local is added to it's table, it instead gets - added to the first non-transparent parent scope. - - This is used in for loops to ensure the correct depth for local - variables inside the body - - https://github.com/ruby/prism/commit/ddb8e82253 - - Co-Authored-By: Kevin Newton <kddnewton@gmail.com> - -commit 723318f5d7a6475f69fc0d095a4149547b6050a3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-06 17:38:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-06 18:45:20 +0900 - - [ruby/openssl] Exact checks with `assert_include` - - Where `assert_match` converts string matcher argument to regexp first - with escaping, `assert_include` does the same thing simpler. - - https://github.com/ruby/openssl/commit/81007e0a49 - -commit 95ced6d8d2b6639f3e29fe3d2de6e326d0a62718 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-06 16:02:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-06 16:37:52 +0900 - - [ruby/openssl] Exact checks with `assert_include` - - https://github.com/ruby/openssl/commit/9a6e24daaf - -commit 232e401b0f19cb5191ae7a0ec107fc9bf10c8145 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-06 13:53:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-06 16:33:44 +0900 - - Reuse `natstr` if it equals `endstr` - -commit b459bca0a62931143420db30e9ba5540cde48372 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-06 13:53:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-06 16:33:44 +0900 - - Use size of `uintptr_t` for `j` and `J` tests - - `RbConfig::SIZEOF` has been added later than the time this check was - committed first. - -commit 0202ca7cfc13866b603f5e093145ef80ac4728db - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-06 13:48:23 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-06 16:33:44 +0900 - - Move rbconfig to the top - - It is required in the always defined class level. - -commit 5c779dc45dfc53c4e7d50e2bb8e5ef0c61404b4d - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-06 08:27:42 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-06 15:32:33 +0900 - - Remove not used fields from MATCH3 - -commit 6a0c13c1d61a3afabc8b5e7874d92a7117e63ede - Author: Manu <git@manuraj.dev> - AuthorDate: 2023-10-04 21:22:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-06 14:38:21 +0900 - - [rubygems/rubygems] Update man page for bundle exec to reflect default flag value - - `--keep-file-descriptors` is true by default. - - https://github.com/rubygems/rubygems/commit/b28e88e228 - -commit 69b024d7ccb8d42bb0387a244dce4d444f619987 - Author: Vinicius Stock <vinicius.stock@shopify.com> - AuthorDate: 2023-10-04 04:29:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-06 10:57:34 +0900 - - [ruby/prism] Add full_name to ConstantPathNode and ConstantPathTargetNode - - https://github.com/ruby/prism/commit/b390553028 - -commit 58fc45325f25b64526ef2c467c37537a69aac4ac - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-05 20:31:34 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-06 07:31:53 +0900 - - Remove not used fields from YIELD - -commit f6a2af255b9ace4de5b10cb75788529dab9c42e9 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-05 17:49:41 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-06 07:31:22 +0900 - - Remove not used fields from ZLIST - -commit 8cb906d7067d9b4cdf7971e49f185c737f3ee1f9 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-10-06 06:31:54 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-10-06 06:31:54 +0900 - - YJIT: Simplify linker flavor check - - By not allowlisting every OS that could have a GNU flavor linker, - it's also a bigger tent - -commit 13bde94a9f017e04f01f090b27b98d0f4eb69b84 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-10-06 06:17:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-06 06:17:33 +0900 - - YJIT: shink local types from 8 to 4 bytes (#8597) - - * Shink local types from 8 to 4 bytes, context from 21 to 17 bytes - - Use repr(packed) - - * Add comment about Type being limited to 4 bits - -commit 7d1abd5d31af30cd1bdae968a997fe1ff33950fd - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-10-06 06:09:18 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-10-06 06:09:18 +0900 - - YJIT: Run bindgen - -commit 07a7c4bdaf27b80a8d791032986539d5188804c6 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-10-06 05:40:27 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-10-06 05:40:27 +0900 - - YJIT: Remove duplicate cfp->iseq accessor - -commit 41a6e4bdf9738e2cf1ea356422a429efeeb5a8f0 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-09-30 11:29:24 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-10-06 04:53:05 +0900 - - YJIT: Avoid writing return value to memory in `leave` - - Previously, at the end of `leave` we did - `*caller_cfp->sp = return_value`, like the interpreter. - With future changes that leaves the SP field uninitialized for C frames, - this will become problematic. For cases like returning from - `rb_funcall()`, the return value was written above the stack and - never read anyway (callers use the copy in the return register). - - Leave the return value in a register at the end of `leave` and have the - code at `cfp->jit_return` decide what to do with it. This avoids the - unnecessary memory write mentioned above. For JIT-to-JIT returns, it goes - through `asm.stack_push()` and benefits from register allocation for - stack temporaries. - - Mostly flat on benchmarks, with maybe some marginal speed improvements. - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - -commit a5cc6341c0688c346f70098652b2375c03df40aa - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-05 21:55:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-06 03:39:58 +0900 - - Remove `NODE_VALUES` - - This node type was added for the multi-value experiment back in 2004. - The feature itself was removed after a few years, but this is its - remnant. - -commit cf1223348a94000ff79d21ff3ecf6bd9ae7e8677 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-06 03:39:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-06 03:39:33 +0900 - - Remove unmatch parenthesis - - ``` - yjit/yjit.mk:48: Extraneous text after `ifneq' directive - ``` - -commit fd22d5debba8a2ed97de8f015aea1f120e5dc80d - Author: Thomas Hurst <tom@hur.st> - AuthorDate: 2023-10-06 02:23:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-06 02:23:51 +0900 - - YJIT: Build on BSD platforms with GNU make (#8591) - -commit 8d8fe5435567553a1b3381103585ed3214fbee81 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-10-05 20:48:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-06 01:35:45 +0900 - - [ruby/prism] Check for duplicate parameter names in destructured params - - https://github.com/ruby/prism/commit/c3438aabea - -commit 38cb92a00c65526898ec4d7949e7d0f9b75666a5 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-10-05 23:48:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-06 00:12:05 +0900 - - [ruby/prism] Check for duplicate names in shadow args - - https://github.com/ruby/prism/commit/e100c6b8ae - -commit fb9795cf7a25d675d1fd525997fd002a16f46aec - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-10-05 15:15:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-05 20:25:32 +0900 - - [ruby/prism] Fix parsing shadow args in lambda blocks - - https://github.com/ruby/prism/commit/53efaf252d - -commit 54f1d398d9a8e91d64aaa739c666292f3ff3f867 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-19 11:07:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-05 20:03:54 +0900 - - Make popcount bit-masks stricter - - Each bit run is upto the right shift count, so the each mask does not - need more upper bits. - -commit f087f2c74c99ec5fed04896d3dc91ff76c2b16b8 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2023-10-05 16:43:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-05 16:44:08 +0900 - - [ruby/stringio] StringIO#pread: handle 0 length like IO#pread - (https://github.com/ruby/stringio/pull/67) - - Fix: https://github.com/ruby/stringio/issues/66 - - If length is 0, IO#pread don't even try to read the IO, it simply return - the buffer untouched if there is one or a new empty buffer otherwise. - - It also doesn't validate the offset when length is 0. - - cc @jdelStrother @kou - - https://github.com/ruby/stringio/commit/37e9279337 - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - -commit 9d58f9382893a71d8badad605879c0120915fbee - Author: Brian Hawley <brian_hawley@yahoo.com> - AuthorDate: 2022-09-23 08:08:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-05 16:11:52 +0900 - - [ruby/net-http] Net::HTTPResponse nil checking - - Fix nil handling in read_body and stream_check. - - Fixes: #70 - - https://github.com/ruby/net-http/commit/36f916ac18 - -commit d088b9f77db962114dfab387e044bcf0f013c454 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-10-05 16:00:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-05 16:00:07 +0900 - - Update bundled gems list at 2023-10-05 - -commit efa18fd6b3cbef788d630d4d76fcf9c8d56c50b9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-05 13:05:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-05 14:23:42 +0900 - - Chain nodes to exit only - -commit 5c82b9baed33702a268f33849f8d5f0c0f0e94a8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-05 11:45:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-05 14:23:42 +0900 - - Do not chain unexpected node - -commit 696022a0cb8938c23e5297dd3b6acdec30f2f045 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-05 11:26:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-05 14:23:42 +0900 - - Differentiate `NODE_BREAK`/`NODE_NEXT`/`NODE_RETURN` - -commit f5f3b35b9320e0dfaf3c40f00d866dcb595d54ef - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-05 11:18:02 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-05 14:23:42 +0900 - - Remove unused nodes in NODE_RETURN and NODE_REDO - -commit 70e1635950fcf77ba43cffc110eac910332ea2a6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-05 10:52:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-05 14:23:42 +0900 - - Move internal NODE_DEF_TEMP to parse.y - -commit a472fd55dafcd1e3846615f0029431305b0f9c74 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-04 22:16:49 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-05 13:19:09 +0900 - - Remove not used fields from colon nodes - -commit 45350a0460a618392fd5b5022aac85c01de29066 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-04 22:01:14 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-05 13:19:09 +0900 - - Correctly casting node for accessing COLON node nd_mid in compile.c - -commit 4a3f88f161a6348cccf82a8350495ebbe8f9a945 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-04 21:37:26 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-05 13:19:09 +0900 - - Fix cast type - -commit 8705e734ed7d8348824dfa859d93fe5b144f0e8f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-05 03:43:29 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-05 03:43:29 +0900 - - Remove a binding.irb in rjit-bindgen - -commit 05b9b58d554042aef68462c727ae97325f986961 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-10-03 01:51:14 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-05 02:53:31 +0900 - - [Prism] Fix IfNode and ElseNode - - ElseNode looks to have been implemented at the same time as IfNode, but - was resulting in a stack underflow error. - - The following is from the test code - - ``` - if foo - bar - end - ``` - - ``` - ❯ make run - compiling compile.c - linking miniruby - ./miniruby -I./lib -I. -I.ext/common -r./arm64-darwin22-fake ./test.rb - CRUBY: ************************************************** - == disasm: #<ISeq:<compiled>@<compiled>:1 (1,0)-(2,19)> - 0000 putself ( 2)[Li] - 0001 opt_send_without_block <calldata!mid:foo, argc:0, FCALL|VCALL|ARGS_SIMPLE> - 0003 branchunless 9 - 0005 putself - 0006 opt_send_without_block <calldata!mid:bar, argc:0, FCALL|VCALL|ARGS_SIMPLE> - 0008 pop - 0009 putobject_INT2FIX_1_ - 0010 leave - PRISM: ************************************************** - -- raw disasm-------- - 0000 putself ( 2) - 0001 send <calldata:foo, 0>, nil ( 2) - 0004 branchunless <L001> ( 2) - 0006 jump <L000> ( 2) - <L000> [sp: 0] - * 0008 pop ( 1) - 0009 putself ( 2) - 0010 send <calldata:bar, 0>, nil ( 2) - 0013 pop ( 2) - 0014 jump <L002> ( 1) - <L001> [sp: 0] - <L002> [sp: -1] - 0016 putobject 1 ( 2) - 0018 leave ( 1) - --------------------- - <compiled>: <compiled>:1: argument stack underflow (-1) (SyntaxError) - make: *** [run] Error 1 - ``` - - This commit fixes the stack underflow error for both IfNode and ElseNode - and introduces tests for them. - -commit 7db6f448ed9ba6a5c27a750416cb6877711a7c05 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-05 01:40:08 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-05 02:25:46 +0900 - - Use a better variable name for w - -commit 577ff858bce3c9620c763d6481b082253f7e2bfd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-05 01:34:06 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-05 02:25:46 +0900 - - Make the function names consistent - -commit 01c462ce6aef82fe6dcdf54a4a3b33f1bc2d96b2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-05 01:30:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-05 02:25:46 +0900 - - YJIT: Move help descriptions to options.rs - -commit 49d27435d01cb5da6c7e344308577089e1a40598 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-04 22:57:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-05 02:25:46 +0900 - - Split `show_usage_line` and add `ruby_show_usage_line` - -commit 582369bb4b33f48a72f64ae12e6d00e30196adef - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-04 22:55:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-05 02:25:46 +0900 - - Remove magic numbers from `show_usage_line` - -commit 488c0ed051902623ecae4b5358401b0c73dcb8e0 - Author: gazayas <g-zayas@hotmail.com> - AuthorDate: 2023-10-04 20:14:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-05 02:00:09 +0900 - - [ruby/prism] Remove trailing parenthesis in Location#pretty_print - - https://github.com/ruby/prism/commit/8eaa199a28 - -commit 6ae2996e291750bab4ff59a06ba11c8d6bbe5aaa - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-10-05 00:19:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-05 00:19:55 +0900 - - Optimize `Range#count` by using `range_size` if possible - -commit e0c66b47499e9372fdf86610f0da65efb6f60af9 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-10-04 05:34:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-04 23:22:16 +0900 - - [ruby/prism] [rust] write flag accessor functions - - https://github.com/ruby/prism/commit/f2333ba4c8 - -commit cf2049cb559913e061f48b416b7dc52e7d394b01 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-10-04 05:07:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-04 23:22:15 +0900 - - [ruby/prism] give flag enums a non-`typedef`'d name - - https://github.com/ruby/prism/commit/630af5cb0e - -commit cd0b8d2441ac5cdd38116a3586389656151611ac - Author: Herwin <herwinw@herwinw.nl> - AuthorDate: 2023-10-04 23:02:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-04 23:02:08 +0900 - - [DOC] Fix typo in docs of IO: `#.` -> `$.` - -commit b43cc51dcad9859ea6c54cb4f03105c8511582de - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-10-04 21:13:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-04 21:13:33 +0900 - - [ruby/irb] Clear all context usages in RubyLex - (https://github.com/ruby/irb/pull/684) - - After this change, `RubyLex` will not interact with `Context` directly - in any way. This decoupling has a few benefits: - - - It makes `RubyLex` easier to test as it no longer has a dependency on - `Context`. We can see this from the removal of `build_context` from - `test_ruby_lex.rb`. - - It will make `RubyLex` easier to understand as it will not be affected - by state changes in `Context` objects. - - It allows `RubyLex` to be used in places where `Context` is not available. - - https://github.com/ruby/irb/commit/d5b262a076 - -commit 465bc682a2b4823899be19440b0fd3395c22a255 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-04 14:39:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-04 14:39:45 +0900 - - YJIT: Call mprotect after entry stub failure (#8582) - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - -commit 6d28f96986c46771f545ce0cdceac5b1fbf33338 - Author: Daisuke Aritomo <di.aritomo@gmail.com> - AuthorDate: 2023-10-04 14:12:50 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-04 14:12:50 +0900 - - [DOC] Fix description for `rb_postponed_job_register_one()` - - The current documentation for `rb_postponed_job_register_one()` is - explaining the differences with itself, where it should be explaining - the differences with `rb_postponed_job_register()`. - -commit ed8a3428e449711f014afa5cb22f4ff2780b0cfe - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-03 23:35:17 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-04 12:15:39 +0900 - - Remove not used fields from variable nodes - -commit e501613efa2b010d6d697a4df264a2cb6f4978fb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-08 18:29:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-04 11:50:15 +0900 - - [ruby/bigdecimal] Bump up to 3.1.5 - - https://github.com/ruby/bigdecimal/commit/c47802e813 - -commit d3fd4a6d32d89aaa566732dd7b62bd6065f7449e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-04 10:25:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-04 10:25:42 +0900 - - BigDecimal#to_s has not changed for fraction part - - The test for integer part was separated at dc54574adefe. - -commit ea491802fa4a6ce7070b318ffcad30cbeaf42635 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-10-04 06:45:46 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-04 06:45:46 +0900 - - YJIT: add heuristic to avoid compiling cold ISEQs (#8522) - - * YJIT: Add counter to measure how often we compile "cold" ISEQs (#535) - - Fix counter name in DEFAULT_COUNTERS - - YJIT: add --yjit-cold-threshold, don't compile cold ISEQs - - YJIT: increase default cold threshold to 200_000 - - Remove rb_yjit_call_threshold() - - Remove conflict markers - - Fix compilation errors - - Threshold 1 should compile immediately - - Debug deadlock issue with test_ractor - - Fix call threshold issue with tests - - * Revert exception threshold logic. Document option in yjid.md - - * (void) for 0 parameter functions in C99 - - * Rename iseq_entry_cold => cold_iseq_entry - - * Document --yjit-cold-threshold in ruby.c - - * Update doc/yjit/yjit.md - - Co-authored-by: Jean byroot Boussier <jean.boussier+github@shopify.com> - - * Shorten help string to appease test - - * Address bug found by Kokubun. Reorder logic. - - --------- - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - Co-authored-by: Jean byroot Boussier <jean.boussier+github@shopify.com> - -commit d47af931105583c1504965300492422e5af86b81 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-10-04 00:31:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-04 03:46:37 +0900 - - [ruby/prism] Provide pm_parser_err_current and pm_parser_err_previous - - https://github.com/ruby/prism/commit/4828c96939 - -commit ad0e8ddbdba135caa41a28ecbacc928f154ec126 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-30 09:55:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-04 03:46:36 +0900 - - [ruby/prism] Consolidate diagnostic appendings - - https://github.com/ruby/prism/commit/4f107d8962 - -commit accda74cbeb96a5539e0cf44741418654291d3c0 - Author: Daniel Colson <danieljamescolson@gmail.com> - AuthorDate: 2023-08-29 21:41:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-04 02:16:19 +0900 - - [rubygems/rubygems] Prevent gem activation in standalone mode - - As discussed in https://github.com/rubygems/rubygems/issues/6273#issuecomment-1449176658 - - The `gem` method behaves awkwardly in standalone mode. Assuming bundler - isn't loaded at all, a call to gem might activate a gem that is not part - of the bundle (because it's the gem method defined in - lib/rubygems/core_ext/kernel_gem.rb and not - lib/bundler/rubygems_integration.rb). And when running with - `--disable-gems`, the gem method won't be defined at all so we'll get a - NoMethodError. - - Calls to `gem` can appear in dependencies outside an application's - control. To work around this at GitHub we defined our own `Kernel#gem` - that no-ops. - - I agree with https://github.com/rubygems/rubygems/issues/6273#issuecomment-1440755882 - - > people using standalone mode don't want to activate gems like Kernel.gem - - This commit redefines `Kernel#gem` in the standalone script to no-op. - - https://github.com/rubygems/rubygems/commit/bea17b55f1 - -commit 1992aef7225b864613b22be5bfb164f5c909a71c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-04 01:54:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-04 01:54:24 +0900 - - YJIT: Stop spilling temps on jit_prepare_routine_call (#8581) - - YJIT: Remove spill_temps from jit_prepare_routine_call - -commit 68df43788dc237a1071f02b2d82768f844696315 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-04 01:19:54 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-04 01:19:54 +0900 - - Allow changing RUBY_PATCHLEVEL_STR if RUBY_PATCHLEVEL == -1 (#8578) - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit 5dfbf1a3814c4d84a5ae375751f5f935b2baae8f - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-10-04 00:10:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-04 00:10:59 +0900 - - [ruby/reline] Bump version to 0.3.9 - (https://github.com/ruby/reline/pull/594) - - https://github.com/ruby/reline/commit/b6fb72718a - -commit ed0661e618fa9fe9e685f755f02e3a1de2d4726b - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-01 04:42:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-03 18:42:31 +0900 - - [rubygems/rubygems] Don't re-resolve with prereleases if unlocked gem has no prereleases - - https://github.com/rubygems/rubygems/commit/d76dc70d90 - -commit b73ef929988a7cd87ce95c0e21b18ac04d8188d8 - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-10-01 04:18:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-03 18:42:31 +0900 - - [rubygems/rubygems] Fix typo - - https://github.com/rubygems/rubygems/commit/64e7a2656a - -commit b4ab013b275dcd671ce2d449ab2b5118384cbbc6 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-08-31 22:16:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-03 16:31:34 +0900 - - [DOC] Link fixes - -commit 25b536cc2f6f630d6b58949342bbedb903936465 - Author: Josef Šimánek <josef.simanek@gmail.com> - AuthorDate: 2023-09-28 09:08:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-03 16:13:18 +0900 - - [rubygems/rubygems] Fix invalid links in documentation. - - - wrap ENV variables in <code> - - fix rubygems.org link - - fix zenspider.com link - - https://github.com/rubygems/rubygems/commit/9eaac94a63 - -commit 9ffd659d47afea25ebd4ba96af45cb925c3199c6 - Author: Peter Boling <peter.boling@gmail.com> - AuthorDate: 2023-09-14 13:43:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-03 16:13:18 +0900 - - [rubygems/rubygems] 🐛 Specification of branch or ref with tag is ambiguous - - - Specs for GitProxy were incorrect and insufficient - - Specs are now correct and less insufficient - - https://github.com/rubygems/rubygems/commit/63d0a8cfd0 - -commit 16a97c7bbb5ef04da58e7136830b57707b5fc2ad - Author: Peter Boling <peter.boling@gmail.com> - AuthorDate: 2023-09-14 13:58:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-03 16:13:18 +0900 - - [rubygems/rubygems] 🚨 Rubocop Linting - - https://github.com/rubygems/rubygems/commit/2851e051c3 - -commit 0046c67dd8d56960de6579ba05cac622412c6d54 - Author: Josef Šimánek <josef.simanek@gmail.com> - AuthorDate: 2023-09-30 19:00:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-03 16:13:18 +0900 - - [rubygems/rubygems] Fix typo: eglible -> eligible. - - https://github.com/rubygems/rubygems/commit/1e487e1337 - -commit 798083fac807ff2c510f1072685f6b33e229b436 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-10-01 05:36:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-03 16:13:18 +0900 - - [ruby/csv] [DOC] Fix broken links - (https://github.com/ruby/csv/pull/283) - - https://github.com/ruby/csv/commit/af64a15b2f - -commit 2325e1cd81d721645ad600d93829604c13f6cbd8 - Author: Kosuke Shibata <56685224+shibaaaa@users.noreply.github.com> - AuthorDate: 2023-09-14 09:25:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-03 16:13:18 +0900 - - [ruby/csv] Add CSV::InvalidEncodingError - (https://github.com/ruby/csv/pull/287) - - To handle encoding errors in CSV parsing with the appropriate error - class - - https://github.com/ruby/csv/commit/68b44887e5 - -commit 457971f4e243a76084d06ae840f4218b7a2062a3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-03 14:42:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-03 14:42:47 +0900 - - [DOC] State the precision of `Process.times` as platform-defined - - Remove the bad example that can lead to misunderstanding as if this - precision is defined in Ruby. - -commit 8be9138de2f9c6ce418f43ee55f5e6bce645bc28 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-03 14:27:51 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-03 14:27:51 +0900 - - Check by integer modulo instead of float string - -commit 3b47fb2cb65336481ab339c612cc01d87a12c028 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-10-02 15:09:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-03 09:08:34 +0900 - - [rubygems/rubygems] Update suggested variable for bindir - - https://github.com/rubygems/rubygems/commit/f9cc6fed25 - -commit 492e9437dd33f64e283a9de21f49c65d3195c1f0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-03 06:09:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-03 06:09:51 +0900 - - YJIT: Fix assert_no_exits (#8579) - -commit e6d730023d6c7fe30e9a69ebb0826ed25c5f03b8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-10-03 06:09:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-10-03 06:09:26 +0900 - - Trigger Cirrus if YJIT tests are modified - -commit 9059dfce12995451a4374330baab49177fa717be - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-02 22:06:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-02 23:20:03 +0900 - - `yield` cannot be placed outside methods even in blocks - -commit 63e504d6e65765740a592ee785147e5eff0d9aed - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-10-02 10:16:53 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-10-02 22:49:13 +0900 - - Dump name of method for imemo callinfo - - This commit dumps the `mid` of the imemo callinfo when calling - `ObjectSpace.dump_all`. - -commit 1943ea06a6be4dddc235011a2dadc3fb326080a9 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-22 22:51:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-02 22:22:53 +0900 - - [ruby/prism] [DOC] Link fix - - https://github.com/ruby/prism/commit/472bdc4d70 - -commit fd984ac86920981a0fc8c05c36b2433697d2bce5 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-10-01 19:40:32 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-02 22:18:56 +0900 - - Adopt prism CallNode#name changes - -commit 87dad067e03f98df7a64d4ce555e1213847e8dbb - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-10-01 19:34:55 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-10-02 22:18:56 +0900 - - Sync with prism CallNode#name changes - - * https://github.com/ruby/prism/pull/1533 - -commit 4da04d5f43231d62c7c9fb93f3b610cef2086091 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-01 22:37:14 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-02 13:49:57 +0900 - - Include new node types into %printer - -commit 35e0e440a2babaae66159ee900e83ad491420c24 - Author: Charles Oliver Nutter <headius@headius.com> - AuthorDate: 2023-09-19 23:16:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-02 11:47:36 +0900 - - [ruby/psych] Update SnakeYAML Engine to 2.7 - - https://github.com/ruby/psych/commit/094c811588 - -commit 5c501bcbdb163f8e27d098e2149cf9840e1043ac - Author: Charles Oliver Nutter <headius@headius.com> - AuthorDate: 2023-09-18 23:54:23 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-10-02 11:47:35 +0900 - - [ruby/psych] Add test for code_point_limit - - Only supported on JRuby currently. - - https://github.com/ruby/psych/commit/0c1754eefe - -commit f208f78bdfc65341cb6547a378ff616b1928e48a - Author: Harshal Bhakta <harshal.c.bhakta@gmail.com> - AuthorDate: 2023-09-29 19:12:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-02 11:19:43 +0900 - - [rubygems/rubygems] Support Ruby's preview version format (Ex: 3.3.0-preview2) in Gemfile - - https://github.com/rubygems/rubygems/commit/4c1a0511b6 - -commit f3aea74c3d63a9b1e0f597b060bf84c14d1c70fc - Author: Graham Marlow <graham@onesignal.com> - AuthorDate: 2023-09-30 01:37:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-02 10:34:01 +0900 - - [rubygems/rubygems] Include gemspec in ExtensionTask for native gem tasks - - https://github.com/rubygems/rubygems/commit/042cfb7007 - -commit 1ed6fd899769e6cd66a1a3f66b7818d48ba4231b - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-01 23:46:19 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-02 09:41:45 +0900 - - Check the result of get_nd_recv before node type check for safety - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit 81668579ed0cf90b95f2fcc5755b51842fb65917 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-01 13:19:55 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-02 09:41:45 +0900 - - Remove not used fields from call nodes - -commit b1131851e085a4d1e5b56599adea1b851be97563 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-01 12:51:25 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-02 09:41:45 +0900 - - Correctly casting node for accessing nd_recv, nd_mid and nd_args in compile.c - -commit fdc329ea6f5bce922e95645a0c2118cfd3e1cdea - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-01 12:46:27 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-02 09:41:45 +0900 - - Correctly casting node for accessing nd_args in parse.y - -commit c1894a9d8b4522190de3a83a3929806b9acc88f4 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-10-01 11:43:46 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-02 09:41:45 +0900 - - Use rb_node_fcall_t instead of NODE - -commit f9490110e156d1cd5221433d3c1f41b0cfab1d01 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-10-02 08:37:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-10-02 08:37:40 +0900 - - [DOC] Another example for spawn (#8575) - -commit 4909747e5a1b49bb6a707727d5e43a61e37e7818 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-02 00:49:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-02 00:49:05 +0900 - - Use the hexdigit character class - -commit ec3d81629ff193e847dcab9afb20dffa14f2582a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-01 23:58:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-01 23:58:24 +0900 - - [Bug #19906] Add the test - -commit c74dc8b4af4ef1b32f65587f083fbeba4ca186fa - Author: HParker <HParker@github.com> - AuthorDate: 2023-09-30 06:06:26 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-10-01 23:55:19 +0900 - - Use reference counting to avoid memory leak in kwargs - - Tracks other callinfo that references the same kwargs and frees them when all references are cleared. - - [bug #19906] - - Co-authored-by: Peter Zhu <peter@peterzhu.ca> - -commit be09c8370b8f332620592b1837e040ded583489f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-01 22:33:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-01 22:33:31 +0900 - - tool/enc-unicode.rb: make the condition concice with flip-flop - - And regexps are not necessary here. - -commit 50756a1f085e3dc12dab27b22cbf60d4cabb027c - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-30 22:50:21 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-01 19:38:03 +0900 - - Use rb_node_block_pass_t instead of NODE - -commit 08239fd6af915d8a55c1e63c339cf749fecd0cae - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-30 22:05:10 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-01 19:38:03 +0900 - - Use rb_node_args_t and rb_node_args_aux_t instead of NODE - -commit b0d7935e800a2dd2556728bc463b5ed92f193f1b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-01 18:55:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-01 18:55:58 +0900 - - Move repeating `matches` and `unmatches` to keyword arguments - - And default to the corresponding instance variables. - -commit 3ae44035dd30480c988723d0b5d7089ec4d3271c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-10-01 18:23:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-10-01 18:23:49 +0900 - - Add tests for Unicode age property 15.0 - -commit cecd1de2eb33719269ce5fd68217cdab96a3dfad - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-30 17:18:50 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-10-01 09:19:42 +0900 - - Use rb_node_opt_arg_t and rb_node_kw_arg_t instead of NODE - -commit c9e28ea2f9d442f5efd2a2671ff81cd4308dcde2 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-10-01 02:56:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-01 02:56:06 +0900 - - [ruby/irb] Fix Reline's test failure running with `make test-all - TESTS='reline irb'` - (https://github.com/ruby/irb/pull/722) - - * Specify TestInputMethod in test to avoid RelineInputMethod to be used - - * Reset Reline in teardown to avoid test failure of `make test-all TESTS="irb reline"` - - https://github.com/ruby/irb/commit/5d67967eb1 - -commit 4c8fac07417d8724e55deb0b55376634fb0d56bc - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-30 23:54:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-10-01 01:58:59 +0900 - - [ruby/open3] [DOC] RDoc for Open3 - - https://github.com/ruby/open3/commit/0aadba9fe6 - -commit 20efab0b08872c61423f35295c86e50b0c4e5dfd - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-30 23:26:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-30 23:26:50 +0900 - - [ruby/open3] [DOC] RDoc for Open3 - (https://github.com/ruby/open3/pull/15) - - https://github.com/ruby/open3/commit/f3191920aa - -commit 4cf68908e59979306d6069b1828c209079bcb9b7 - Author: Josef Šimánek <josef.simanek@gmail.com> - AuthorDate: 2023-08-30 09:31:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-30 20:20:08 +0900 - - [rubygems/rubygems] Update SPDX list and warn on deprecated identifiers. - - https://github.com/rubygems/rubygems/commit/61667028f5 - -commit d647709d1acc7d56a3e89b5166c816d65fdb606d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-30 17:40:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-30 20:17:38 +0900 - - Extract `ripper_parser_params` - -commit 1cedecebb8c34e604078b079f6b105f3d816e412 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-30 16:06:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-30 20:14:53 +0900 - - Stop saving source locations unnecessarily - - `node_newnode` and `parser_dispatch_delayed_token` do not use or - change `ruby_sourceline`. - -commit 7592b07c2895935b4f08a627a5823813429c1c30 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-30 14:40:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-30 20:14:53 +0900 - - Take line number from the tracked token location - -commit 4997903c20e417dbc2eeed2736c9a4c544499a43 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-30 14:26:23 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 19:17:28 +0900 - - Remove not used fields from FOR_MASGN - -commit 94e79e4c2da8d69f45e67228a051bb1c09a367ec - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-30 17:41:14 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-30 19:03:04 +0900 - - Fix failures when all network interfaces are down - -commit 1fbccd02eeb37cf3ecd408b0ec2a71bdf78aa00f - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-30 16:28:03 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 18:53:40 +0900 - - Remove not used fields from OP_ASGN_AND, OP_ASGN_OR - -commit eba19d86d4fd6d10ccc9f2603187ca0f8ca806c4 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 21:50:18 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 17:20:54 +0900 - - Remove not used fields from HASH - -commit 97ac5deeecc6d7c9b870e98aaddf820659b2ebff - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-30 14:17:59 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 17:20:16 +0900 - - Remove not used fields from BEGIN - -commit 716a12902dfbcd285b5cba8d0bf9d1be4ea79d4b - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-30 12:48:06 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 17:02:50 +0900 - - Remove not used fields from ERROR - -commit db18428fff096d827cfb8968f8d099c2f83571c1 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 21:06:47 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 16:30:57 +0900 - - Remove not used fields from ITER, FOR - -commit 4c18615ffe2c267162db40f07588c48ea1328bb3 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 21:36:04 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 16:24:43 +0900 - - Remove not used fields from MODULE, SCLASS - -commit 4e90be4c93ff3cbb8ab2cce3264e21f769ee056e - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 22:03:48 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 13:23:32 +0900 - - Remove not used fields from ONCE - -commit d293d9e1917d28bf77f690e3c944b6ad876efd0c - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-28 20:44:45 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 13:11:32 +0900 - - Expand pattern_info struct into ARYPTN Node and FNDPTN Node - -commit 1b97c17e0364c532bc5651edaae9ce77a432eb1a - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-28 18:28:08 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 13:11:32 +0900 - - Remove not used fields from ARYPTN, FNDPTN - -commit 129d0068524e88bc7bb180590984ce363e84deb1 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-30 10:42:11 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 12:29:29 +0900 - - Remove not used fields from argument nodes - -commit 83af0b912826e5df03e089061160fb03c3878f7f - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 19:03:27 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 12:28:06 +0900 - - Remove not used fields from NTH_REF, BACK_REF - -commit 0a386b827bc280cdd7999a13ce3c1ce1300a0d60 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 22:21:13 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 11:23:20 +0900 - - Remove not used fields from ERRINFO - -commit fa54d06a408acbc60e718bae57e8c5d1a05cc160 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-29 21:15:55 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 11:22:06 +0900 - - Remove not used fields from POSTEXE - -commit 0b67e3fd3ee9969a0c92867bec365104f2b43897 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-30 10:55:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-30 10:55:48 +0900 - - YJIT: Chain-guard opt_mult overflow (#8554) - - * YJIT: Chain-guard opt_mult overflow - - * YJIT: Support regenerating Jo after Mul - -commit f9f728e804367ac8de4709884fec64c13a7cff54 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-29 21:03:51 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 10:48:07 +0900 - - Remove not used fields from DEFINED - -commit ef37bdeb4d6d70beba4fb6862064855472d3d157 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 21:32:00 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 10:27:39 +0900 - - Remove not used fields from AND, OR - -commit 443099377f8cdde96a22bf2291a7373a683e3790 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-29 18:54:28 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-30 10:15:25 +0900 - - Remove not used fields from LAMBDA - -commit 97564ddf2baa518e4bda5b7a59111943dc13f210 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-30 02:45:25 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-30 05:51:17 +0900 - - Fix memory leak in the parser - - Reproduction script: - - ``` - require "ripper" - - 10.times do - 20_000.times do - Ripper.parse("") - end - - puts `ps -o rss= -p #{$$}` - end - ``` - - Before: - - ``` - 28032 - 34432 - 40704 - 47232 - 53632 - 60032 - 66432 - 72832 - 79232 - 85632 - ``` - - After: - - ``` - 21760 - 21760 - 21760 - 21760 - 21760 - 21760 - 21760 - 21760 - 21760 - 21760 - ``` - -commit f88f5b59e8cd58f5a88013d192c8141ea0bb8499 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-30 04:56:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-30 05:41:23 +0900 - - [ruby/prism] remove `peek_string` to avoid subtle memory issues - - https://github.com/ruby/prism/commit/f393d30ce1 - -commit e05ea03553fcbbbf194dbf4cd982898480ae141b - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-30 02:48:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-30 02:56:01 +0900 - - [ruby/open3] [DOC] RDoc for Open3 - - https://github.com/ruby/open3/commit/69f9c49eb4 - -commit 873a8caf5889c7d6649e9c3a1ac7f72d86a6193a - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-30 00:40:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-30 02:56:01 +0900 - - [ruby/open3] [DOC] RDoc for Open3 - - https://github.com/ruby/open3/commit/f1d6988f13 - -commit 4274ebf0f6ced4c9e977c7cf7216e463ec9eb37a - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-30 00:27:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-30 02:56:00 +0900 - - [ruby/open3] [DOC] RDoc for Open3 - - https://github.com/ruby/open3/commit/a4d9fb99de - -commit 536f8d901c005d2ceffa70f9825e8ff067e4bbb6 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-29 07:26:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-30 02:56:00 +0900 - - [ruby/open3] [DOC] RDoc for Open3 - - https://github.com/ruby/open3/commit/8c06964d12 - -commit a2b64275145d178c285609c3158b77c2c2db9a8e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-29 20:38:54 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-30 02:39:01 +0900 - - Consolidate includes common to universal parser - -commit 5fa1e246b9ed9fda62c5416e0420f1dcd2dbb254 - Author: Jun Aruga <junaruga@users.noreply.github.com> - AuthorDate: 2023-09-30 01:16:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-30 01:16:58 +0900 - - .travis.yml: Upgrade the used Ubuntu s390x to 22.04 (Jammy). (#8401) - - Upgrade the used Ubuntu version from 20.04 (Focal) to 22.04 (Jammy), alignin - with RubyCI "s390x (Ubuntu)" server. - https://rubyci.org/ - - Note Travis CI supports Ubuntu 22.04 (Jammy). - https://docs.travis-ci.com/user/reference/jammy/ - - Set `DFLTCC=0` environment variable as a workaround to avoid the test failures - related to zlib in the `make test-all` and `make test-spec`. The failures can - happen with the zlib library applying the patch madler/zlib#410 to enable the - deflate algorithm producing a different compressed byte stream. - -commit 7278747d08a97e4b8e6470793d39b6107f69b0f3 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-09-29 18:29:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-30 01:14:29 +0900 - - [ruby/zlib] Revert "Workaround: Fix test failures on Ubuntu jammy s390x." - - This reverts commit https://github.com/ruby/zlib/commit/9f3b9c470c05 because we will - fix the issue on alternative way. - - https://github.com/ruby/zlib/commit/3dfe3f9110 - -commit 49d3bbe13b5d778052ff07c0eb22c91db5c83349 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-30 00:38:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-30 00:39:24 +0900 - - [ruby/prism] Add a logo - - https://github.com/ruby/prism/commit/d87607b874 - -commit 9861ec4fb90b795ba2f20b2eb6fa7efbd8f77497 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-29 04:26:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-30 00:26:06 +0900 - - [ruby/prism] Mark ranges as static literal - - https://github.com/ruby/prism/commit/4c77944dd4 - -commit be63e2515b180c962e4347ce4feda70a0659cac7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-30 00:20:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-30 00:21:50 +0900 - - [ruby/prism] Bump version - - https://github.com/ruby/prism/commit/3e44415ca2 - -commit 100ce34331c40eed7039233a15d80e8efa5a1ac3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-29 10:59:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-30 00:16:30 +0900 - - [ruby/prism] Add a type method for quick comparison - - https://github.com/ruby/prism/commit/0c7d9c3c01 - -commit 0d4c4b65733f1d6386dcf96ecd4605d752f66bba - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-29 23:08:15 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-29 23:08:15 +0900 - - YJIT: Use registers for passing C method arguments (#8538) - -commit 592acba5d583b2608f829a77cfd7a1fb95414717 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-29 23:03:02 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-29 23:03:02 +0900 - - YJIT: Report all insn exit reasons (#8541) - -commit a8578fff98d62b869101c43ead67fe37303672ec - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-29 23:01:50 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-29 23:01:50 +0900 - - YJIT: Remove obsoleted jit_rb_int_mul (#8539) - -commit 2de5c57dce510e809e7af4bb0289bfa0f92aca98 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-29 04:19:56 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-29 22:51:23 +0900 - - Move more things through pm_static_literal_value - -commit 2e25289aee55e023ce0481ecd00ff20b4d8952c0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-29 03:25:47 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-29 22:51:23 +0900 - - Handle static array nodes - -commit 38e3cafe62637b138700e04a8a6a1ee73fe5a5f2 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-28 23:51:57 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-29 22:51:23 +0900 - - Compile implicit nodes - -commit 396042a25c6c8f84cd08f9e5f10d46b834802c9f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-28 23:48:24 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-29 22:51:23 +0900 - - Fix up static hash compilation - -commit 9b2b2082a7e48f5406b3ed44f400eb3010ae60e0 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-09-29 20:27:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-29 22:38:05 +0900 - - [rubygems/rubygems] Handled unknown gems in bundled gems warning - - We have this code that started failing on 3.3.0-dev recently: - - ``` - irb(main):002> require File.join(RbConfig::CONFIG["rubylibdir"], "observer.rb") - /opt/rubies/3.3.0-dev-09-29/lib/ruby/3.3.0+0/bundled_gems.rb:86:in `<': comparison of String with nil failed (ArgumentError) - - end + " which #{RUBY_VERSION < SINCE[gem] ? "will be" : "is"} not part of the default gems since Ruby #{SINCE[gem]}" - ^^^^^^^^^^ - from /opt/rubies/3.3.0-dev-09-29/lib/ruby/3.3.0+0/bundled_gems.rb:86:in `warning?' - from /opt/rubies/3.3.0-dev-09-29/lib/ruby/3.3.0+0/bundled_gems.rb:92:in `block in <module:BUNDLED_GEMS>' - from <internal:/opt/rubies/3.3.0-dev-09-29/lib/ruby/3.3.0+0/rubygems/core_ext/kernel_require.rb>:42:in `block in require' - from <internal:/opt/rubies/3.3.0-dev-09-29/lib/ruby/3.3.0+0/rubygems/core_ext/kernel_require.rb>:39:in `synchronize' - from <internal:/opt/rubies/3.3.0-dev-09-29/lib/ruby/3.3.0+0/rubygems/core_ext/kernel_require.rb>:39:in `require' - from (irb):2:in `<main>' - from <internal:kernel>:187:in `loop' - from /opt/rubies/3.3.0-dev-09-29/lib/ruby/gems/3.3.0+0/gems/irb-1.8.1/exe/irb:9:in `<top (required)>' - from /Users/byroot/.gem/ruby/3.3.0/bin/irb:25:in `load' - from /Users/byroot/.gem/ruby/3.3.0/bin/irb:25:in `<main>' - ``` - - https://github.com/rubygems/rubygems/commit/d67eddb295 - -commit 4468b6ef3c30158f975168418c58e693c7b6e228 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-09-29 19:51:57 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-09-29 19:53:40 +0900 - - Fix documentation for rb_warn() and friends - - * rb_warn() does not warn if $VERBOSE is nil, the "always" is wrong. - * Talk about $VERBOSE and not -W since $VERBOSE can be changed at runtime. - -commit 7979f074277ae7e2ae8ad64099754d17f62e05a4 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-29 12:16:41 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-29 19:36:34 +0900 - - Change NODE DEF_TEMP nd_cval to `struct lex_context` - -commit 68ae87546e851d79528fffb648e35a65147eefac - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 18:51:19 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-29 19:36:34 +0900 - - Merge NODE_DEF_TEMP and NODE_DEF_TEMP2 - -commit 8d9e114f19ba0cbec41f63c77f3aef4d69834dfb - Author: Prem Sichanugrist <s@sikac.hu> - AuthorDate: 2023-09-29 13:13:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-29 19:32:12 +0900 - - Update documentation for `yield_self` and `then` - - The example usage for `then` was mistakenly placed next to `yield_self`. - -commit 01c765677566f227854d737efcf2c06d139ddbac - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-29 17:43:14 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-29 17:43:14 +0900 - - Fix to replace only `-e` that is a path name in `assert_crash_report` - -commit 5537a410594dfe54eeb86ec63e8860b63160f8ef - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 19:13:08 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-29 17:31:34 +0900 - - Remove not used fields from CASE, CASE2, CASE3 - -commit f14cee39b867e416b974856171b52f725cb4892a - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2023-09-29 15:48:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-29 15:48:55 +0900 - - [ruby/ostruct] Emit a performance warning when OpenStruct is used - (https://github.com/ruby/ostruct/pull/56) - - The OpenStruct documentation clearly state that it shouldn't - be used when performance is expected. - - Ruby 3.3 introduce a new category of warnings that is silenced - by default: performance. - - The expected use case is to enable this warning when looking - for potential performance issues within an application. - - As such I think it would make sense to emit a performance warning - when OpenStruct is used, as it may help pinpoint that a dependency - rely on it, etc. - - https://github.com/ruby/ostruct/commit/5826e12db8 - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - -commit b9bf419aa36e438760fda4109561358bb20d09f1 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 18:58:01 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-29 11:43:04 +0900 - - Remove not used fields from ALIAS, VALIAS, UNDEF - -commit 52f8b347a0cc0d0529d5ddaf3094631e8fd914f2 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 21:41:12 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-29 10:09:04 +0900 - - Remove not used fields from DOT2, DOT3, FLIP2, FLIP3 - -commit 37a783a30cbcc0f5381c955885e525cf702bb506 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 21:58:16 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-29 08:36:39 +0900 - - Merge RNode_OP_ASGN2 and RNode_OP_ASGN22 - -commit 23bcdda37771bbc606535e0a6b0b428b5c26e847 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-27 18:28:01 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-29 07:43:29 +0900 - - Remove not used fields from SELF, NIL, TRUE, FALSE - -commit ef13a49a7f4ed755584484f32aac5885b5aa1a0c - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-29 04:23:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-29 05:15:58 +0900 - - [ruby/open3] [DOC] RDoc for Open3 - - https://github.com/ruby/open3/commit/457cae3a51 - -commit 3ec6be1a4b94eed7b16601617c7f8b5eb10793b5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-29 01:58:19 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-29 04:13:09 +0900 - - More documentation for pattern matching compilation - -commit 9c8ba8467599e174d73241631add030478891f49 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-29 01:51:33 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-29 04:13:09 +0900 - - Support if and unless guards on patterns - -commit b1a28b05db87ff520807ccd55d34e69fcd6ea53c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-29 01:36:17 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-29 04:13:09 +0900 - - Support local variable targeting in pattern matching - -commit 41d3e23582b3030a652919ee10fda114d7eb5626 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-29 01:27:04 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-29 04:13:09 +0900 - - Support the AlternationPatternNode - -commit 64da9be3af4f7dbeb276df0168b70bdb52af7c4f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-29 01:19:50 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-29 04:13:09 +0900 - - Fill in other missing pattern matching expression types - -commit 6e88a56f63958a7939927545528df2aad78a32ff - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-29 01:14:38 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-29 04:13:09 +0900 - - Compile basic pattern matching expressions - -commit 223e9fcb275379c7b397b56f5b32efa616b0f7e7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-29 03:51:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-29 03:51:26 +0900 - - [ruby/prism] Self should not be marked as static literal - - https://github.com/ruby/prism/commit/81265ed8a7 - -commit cc6ffceeec3ec98a51b5c8445d3ef957e08406ab - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-29 03:37:44 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-29 03:37:44 +0900 - - [ruby/open3] [DOC] RDoc for Open3 - -commit 56cf1633a2509170d83e5fac64a77d933106adc5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-29 02:48:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-29 03:15:35 +0900 - - [ruby/prism] Turn on static literal for assoc, hash, and array nodes - - https://github.com/ruby/prism/commit/80c2c931b5 - -commit eaa0fbf9b956fa25e73c3d55e2eba8887324e233 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-29 01:58:07 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-29 03:14:17 +0900 - - Fix `retry` in nested `rescue` blocks - - Restore `rescue`-context from the outer context. - `retry` targets the next outer block except for between `rescue` and - `else` or `ensure`, otherwise, if there is no enclosing block, it - should be syntax error. - -commit 5a376f0f71e8ecc8a6cc0b9f35e63a8367275988 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-28 23:18:43 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-29 03:11:34 +0900 - - Consolidate regexp options, interpolated match last line - -commit d3574c117a637a4456aa3ee78e24d8df510b9355 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-09-19 06:44:51 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-09-29 02:43:45 +0900 - - Move IO#readline to Ruby - - This commit moves IO#readline to Ruby. In order to call C functions, - keyword arguments must be converted to hashes. Prior to this commit, - code like `io.readline(chomp: true)` would allocate a hash. This - commits moves the keyword "denaturing" to Ruby, allowing us to send - positional arguments to the C API and avoiding the hash allocation. - - Here is an allocation benchmark for the method: - - ``` - x = GC.stat(:total_allocated_objects) - File.open("/usr/share/dict/words") do |f| - f.readline(chomp: true) until f.eof? - end - p ALLOCATIONS: GC.stat(:total_allocated_objects) - x - ``` - - Before this commit, the output was this: - - ``` - $ make run - ./miniruby -I./lib -I. -I.ext/common -r./arm64-darwin22-fake ./test.rb - {:ALLOCATIONS=>707939} - ``` - - Now it is this: - - ``` - $ make run - ./miniruby -I./lib -I. -I.ext/common -r./arm64-darwin22-fake ./test.rb - {:ALLOCATIONS=>471962} - ``` - - [Bug #19890] [ruby-core:114803] - -commit 655bcee95a5eeca789646cf63a2c00120c7092b3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-29 02:32:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-29 02:32:04 +0900 - - [DOC] Add link - -commit 2e4e4c82c282622a94b9499c182a7e52e21a23b4 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-09-29 00:40:32 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-09-29 02:26:56 +0900 - - Add a mention about Socket#recv in NEWS.md - - [Misc #19012] - -commit 414c78115855296db0a1f8eaa1fd2df25d74fd30 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-09-22 03:52:24 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-29 00:51:30 +0900 - - [YARP] Implement MatchWriteNode - -commit f4580ce95cb41a48e64564daed96afa8e5a0a51c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-28 23:23:12 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 23:23:12 +0900 - - Fix order-dependent tests in test_compile_prism - -commit d4942546af0e2c0a4b53eaf5d2aeec36187fa5ba - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-09-28 22:53:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-28 22:53:30 +0900 - - [ruby/reline] Properly restore Reline::IOGate in test teardown - (https://github.com/ruby/reline/pull/593) - - * Properly restore Reline::IOGate in test teardown - - * GeneralIO.reset should reset class variable existence - - https://github.com/ruby/reline/commit/c16d33dae5 - -commit 20c561fe0c1194ad4dca265d79f7f8afc0469f3c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-28 22:48:26 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 22:48:26 +0900 - - Add indentation to ignore revs - -commit 40b2c8e5e7e6e5f83cee9276dc9c1922a69292d6 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-28 22:47:46 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 22:47:46 +0900 - - Fix up indentation in prism_compile.c - -commit a213d2144827ab3151d3291794e87fbfb8523a2e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-28 22:05:16 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 22:44:16 +0900 - - Move CRuby-specific prism files to top level - -commit 834560a923dcc4aa6685fb7fd7aecae1808217f1 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-09-28 18:45:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-28 22:32:02 +0900 - - [ruby/prism] Check whether the predicate is closed for conditionals - - https://github.com/ruby/prism/commit/bf43006d0a - -commit 7799fe90da49958af0d33d18c82f12012610f32a - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-09-28 03:24:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-28 22:31:22 +0900 - - [ruby/prism] Check for a semicolon or a newline after the inheritance operator - - https://github.com/ruby/prism/commit/0326ba6775 - -commit 0084bac47a49d787a86c4cfd4d238c24736eb659 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-09-28 04:31:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-28 22:24:57 +0900 - - [ruby/prism] Fix assertion failure for fwd params after rest - - https://github.com/ruby/prism/commit/f86bff6dd7 - -commit bf335bcb11501d56915240d06cb556235084b0f2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-28 17:53:02 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-28 17:53:02 +0900 - - Requires ruby/rbs#1550 - -commit b5e23d3e3b5ff2f5328aa43a2392ebe7c951a222 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-13 13:34:30 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-28 16:23:51 +0900 - - Syntax check of `yield` in the parser - -commit ad96962173c824aeb4ecdd1d9a2e98eaa23a7536 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-28 14:30:30 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-28 15:12:27 +0900 - - Jumps are possible in the top-level loop - -commit a790f83bac86f160087f1b21c181a9fe60ecefe8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-28 14:30:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-28 14:30:10 +0900 - - Suppress void context warnings in verbose mode - -commit e9bc51966ba3bfcc3ce928a9d2fcda01013ef50e - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-28 12:02:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-28 12:02:00 +0900 - - [DOC] RDoc for Open3.popen3 (#8521) - -commit 74c67811537c0c1840668c218dc0e2510d00b473 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-08-22 10:26:38 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-28 11:58:10 +0900 - - Change RNode structure from union to struct - - All kind of AST nodes use same struct RNode, which has u1, u2, u3 union members - for holding different kind of data. - This has two problems. - - 1. Low flexibility of data structure - - Some nodes, for example NODE_TRUE, don’t use u1, u2, u3. On the other hand, - NODE_OP_ASGN2 needs more than three union members. However they use same - structure definition, need to allocate three union members for NODE_TRUE and - need to separate NODE_OP_ASGN2 into another node. - This change removes the restriction so make it possible to - change data structure by each node type. - - 2. No compile time check for union member access - - It’s developer’s responsibility for using correct member for each node type when it’s union. - This change clarifies which node has which type of fields and enables compile time check. - - This commit also changes node_buffer_elem_struct buf management to handle - different size data with alignment. - -commit 684686a1e14d923b43cfd6c1d5a80222281a4070 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-09-28 11:47:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-28 11:47:00 +0900 - - Update bundled gems list at 2023-09-28 - -commit b72e320733c21c4309b8831a1a48d315f2b549d0 - Author: Soutaro Matsumoto <matsumoto@soutaro.com> - AuthorDate: 2023-09-28 11:30:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-28 11:30:08 +0900 - - Bundle RBS 3.2.2 - -commit 81c0d0e2fba7ba4e9047ac7842a263a5e23b8b8a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-28 09:30:35 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-28 10:10:11 +0900 - - [CI] Fix conditional for `RUBYOPT` - - Since GitHub has no real ternary [operator], the second expression - must be "truthy" value instead of an empty string which is evaluated - as `0`. - - - Some bundler tests seem trying to install old Rack where - `Rack::Utils.byte_ranges` method has been deprecated once. - - - Racc tests do not seem aware about warnings very well. - - [operator]: https://docs.github.com/actions/learn-github-actions/expressions#operators - -commit aa6764e66da2a6a9d27d6910b2c19e97607c56e9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-28 08:16:36 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-28 08:16:36 +0900 - - [CI] Fix indentation to concatenate the lines and pass the options - -commit dd5814ed1a7496274e733d567a830f7e56aa80e1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-28 08:01:35 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-28 08:01:35 +0900 - - Suppress void context warnings - -commit 54bbf9a6e92acd0b1581e2a7bb31aab1ecbdb176 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-09-28 05:53:37 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 07:36:23 +0900 - - [PRISM] Implement MatchLastLineNode - - This PR implements `MatchLastLineNode` for Prism. - - Related: ruby/prism#1335 - -commit 175ac32c62101c601ab701f08e3a781b3b088e62 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-28 04:21:45 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 04:41:05 +0900 - - Use new constant pool layout for prism - -commit 29555130951435c57fd9a6ab932192a3d180ee0d - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-20 02:56:49 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 04:41:05 +0900 - - [ruby/prism] rearrange the constant pool so IDs can be used for indexing - - https://github.com/ruby/prism/commit/6f243de0c7 - -commit 5b6a51ad9d586ea6fa5dc017763d0d264b7052ba - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-20 02:19:35 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 04:41:05 +0900 - - [ruby/prism] shrink `yp_constant_t` by 8 bytes - - https://github.com/ruby/prism/commit/5c01eb5e6f - -commit 62181e17da2db729eb6d95f6edff9e028ff557b6 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-09-27 07:31:55 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-09-28 03:57:50 +0900 - - Make {Queue,SizedQueue}#freeze raise TypeError - - Fixes [Bug #17146] - -commit 84312e688f7e30839ab0756dcd88fac21e265bd4 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-28 02:44:04 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-28 03:42:50 +0900 - - [DOC] Fix minor inconsistencies - -commit 224e76ada7b6b66ee65b371f9bfb802518d07552 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-28 01:58:44 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 02:57:38 +0900 - - Include recently added parse_test code in rename - -commit 3d0a46796b780417096b65de5edb590d3b1537f1 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-28 01:39:53 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 02:57:38 +0900 - - Rename YARP symbols to prism - -commit 4f73a7c2f7ff16aa78cf0dec2d4c7f90a2c41c9b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-28 01:24:48 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 02:57:38 +0900 - - Sync to prism rename commits - -commit 8ab56869a64fdccc094f4a83c6367fb23b72d38b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-28 01:22:36 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 02:57:38 +0900 - - Rename YARP filepaths to prism filepaths - -commit 7e0971eb5d679bb6219abb0ec238139aa6502c5a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-27 00:46:55 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - Update YARP build targets - -commit 758e70d3d47910394cb91cdf3adc924bf45334a7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-27 00:43:05 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - Update YARP gitignore - -commit 5f905026bcf1a2217570e93b8da1947dc8da4d35 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-23 00:57:13 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - [ruby/yarp] Move node ext and parse result to their own files - - https://github.com/ruby/yarp/commit/916828767c - -commit 7d11f58b6ed5d995b0fd224442fe49fdfa808a4b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-23 00:47:32 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - [ruby/yarp] Move lex compat into its own file - - https://github.com/ruby/yarp/commit/e90f88f21f - -commit 3e8aa3d1cc532095db88d37006beedc515e54048 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-23 00:43:12 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - [ruby/yarp] Move node inspector into its own file - - https://github.com/ruby/yarp/commit/1c843d2f22 - -commit 978f91a10ca8a15d711b6158d7d1240b09622ee3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-23 00:40:14 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - [ruby/yarp] Move debug into its own file - - https://github.com/ruby/yarp/commit/139362c90a - -commit aeb53cb50e75f01c7e77b0f789cd94a38ff580ab - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-23 00:33:20 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - [ruby/yarp] More documentation for desugar compiler - - https://github.com/ruby/yarp/commit/4a6df3c2a4 - -commit b18e05b18f5987cd5ce506af380558fd192d2d1c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-23 00:31:45 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - [ruby/yarp] Split up compiler versus visitor - - https://github.com/ruby/yarp/commit/2e6baa3f19 - -commit 3cec94624b0a0b308df03f5dba22dd5eb2e4f515 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-27 00:39:25 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - Rename compiler test to iseq test - -commit 0517ca3aac2c834a07dff981a4888f631d6330c6 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-27 00:33:05 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - Delete mutation visitor manually so sync can run - -commit 2a4a55f896c44896e10ad1e905c9e8a6a0f4ae92 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-22 23:57:00 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - [ruby/yarp] Move DSL into its own file - - https://github.com/ruby/yarp/commit/3d34404d80 - -commit 1c049c64c06552198678b29f9e235830e3d17e5a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-22 23:50:08 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - [ruby/yarp] Move BasicVisitor below ParseResult in yarp.rb - - https://github.com/ruby/yarp/commit/d51014582a - -commit 28cc144b63da9b3a533628e45919e776ceb77e43 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-22 23:38:48 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - [ruby/yarp] Move more features under autoload - - https://github.com/ruby/yarp/commit/2f1f3fa448 - -commit af8d475281858eccdbc1e557c795d81d6badd589 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-22 23:32:34 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - [ruby/yarp] Move dispatcher into its own autoload - - https://github.com/ruby/yarp/commit/52bd001ea2 - -commit be861053c5e19783d75c1d2cd66d6007b9ba5072 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-23 00:41:34 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 01:10:23 +0900 - - [ruby/yarp] Use less magical numbers for regular expression flags - - https://github.com/ruby/yarp/commit/c6a0abdd24 - -commit 2bc243b3dcd10d6de3efd80c3e91413d83b476fe - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-09-20 04:25:13 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-28 00:25:53 +0900 - - [YARP] Implement regex flags - - This fixes the TODO in the code that was passing 0 instead of the regex - flags. - -commit 2000cf918358460f9d7da86fb253318fcdbe8e57 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-28 00:08:54 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-28 00:08:54 +0900 - - [YARP] Implemented BlockArgumentNode (#8499) - -commit 5b36c11e21ce3ab227a0a3ec40d9bbb723524c4f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-12 00:35:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-27 21:53:01 +0900 - - Out of place jumps are valid in `defined?` - -commit 29e5fca7181de5f0db372374d5f39704f81f2731 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-11 01:02:34 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-27 21:53:01 +0900 - - Syntax check of `retry` in the parser - -commit ff8278e52c08e6b7bc33ba994b996595b1b65833 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-10 19:14:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-27 21:53:01 +0900 - - Fix error token location - -commit 9fd342f8d26b1a94c70ff2b76131cdac4f534672 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-08 20:03:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-27 21:53:01 +0900 - - Block exits are now syntax error in ripper - -commit e1250a5f9778f463a541bc1ee5a951f64c131bbf - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-08 02:16:15 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-27 21:53:01 +0900 - - Syntax check of block exits in the parser - -commit 50520cc1930331bccdb94730e17ddc01798f2be0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-27 16:18:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-27 16:18:05 +0900 - - [DOC] Missing comment markers - -commit 262a0cc8682cdcb58c28e2a9c64a984ac9171fed - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-27 15:50:37 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-27 15:50:37 +0900 - - [DOC] Missing comment marker - -commit bece8808744ee178a4c55c6954edd30fb93b9ad3 - Author: Ry Biesemeyer <ry.biesemeyer@elastic.co> - AuthorDate: 2021-12-03 01:09:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-27 14:20:58 +0900 - - [rubygems/rubygems] Centralize logic using `Pathname#relative_path_from` - - To avoid potential crashes when trying to jump from a drive to another - on Windows, and take the change refactor things a bit. - - https://github.com/rubygems/rubygems/commit/7c9a9a431a - -commit a812f1fed0e6e184447ca00b713d54b25be05911 - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-09-25 16:51:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-27 14:20:57 +0900 - - [rubygems/rubygems] Reword a couple of error messages - - When a path does not make a lot of sense. - - https://github.com/rubygems/rubygems/commit/d173c79e9a - -commit bc664609df6a5dfb95bc9c604bd0a661b3fbcf26 - Author: krororo <krororo.07@gmail.com> - AuthorDate: 2023-09-26 09:58:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-27 14:18:10 +0900 - - [rubygems/rubygems] Refactor full sha revision match logic - - https://github.com/rubygems/rubygems/commit/f0d8255ebd - -commit fbee93fc19420ea2b734cffc742ef34599c380db - Author: krororo <krororo.07@gmail.com> - AuthorDate: 2023-09-20 09:47:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-27 14:18:10 +0900 - - [rubygems/rubygems] Fix bundle install when older revisions of git source - - https://github.com/rubygems/rubygems/commit/a30712c0fc - -commit 57c3e45ee8d43c401ff1e52105ecbca2bd4e7550 - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-09-25 23:26:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-27 12:29:37 +0900 - - [rubygems/rubygems] Fix `bundle lock --minor --update <dep>` edge case - - When the latest allowed minor of `dep` adds a new dependency, that new - dependency would be incorrectly resolved to the latest minor of the - first major version. - - https://github.com/rubygems/rubygems/commit/fd50c9d4f3 - -commit 705bd6439de07db1502d2fc3ac6e13ae449fc12e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-27 03:23:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-27 03:23:59 +0900 - - [ruby/yarp] Ensure newlines are sorted in newline test - - https://github.com/ruby/yarp/commit/3bfefc44c4 - -commit a436805d3b3b82b34bc60c07763b31da2aba95b9 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-27 02:57:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-27 03:07:55 +0900 - - [ruby/yarp] Remove visitor usage to not rely on overriding visit - - https://github.com/ruby/yarp/commit/6903860981 - -commit 154bd04ee228ee3bee173a479d397074268cd4d6 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-27 00:28:36 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-27 00:28:36 +0900 - - [DOC] Fix link in process.c - -commit a40ab12768a47135fff9eafdfb445506e806a20e - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-26 23:01:44 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-27 00:26:19 +0900 - - [DOC] Refactor doc in process.c - -commit ef59175a68c448fe334125824b477a9e1d5629bc - Author: Adam Hess <HParker@github.com> - AuthorDate: 2023-09-26 08:03:04 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-27 00:12:21 +0900 - - fix iseq kwargs table and original_iseq leaks - - [bug #19903] - - Co-authored-by: Peter Zhu <peter@peterzhu.ca> - -commit 3f511a1d093a85da4f224c0651f8cf922f02f501 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-09-23 02:33:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-27 00:08:25 +0900 - - [ruby/yarp] Check predicate of while and until - - https://github.com/ruby/yarp/commit/f57a6066b5 - -commit 3f1cfc43bdefb45de643076be4602e7b3f432779 - Author: elfham <38372058+elfham@users.noreply.github.com> - AuthorDate: 2023-09-26 22:08:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-26 22:08:20 +0900 - - [ruby/reline] Fix config.rb to File.expand_path $include path in - inputrc - (https://github.com/ruby/reline/pull/592) - - * Fix config.rb to File.expand_path $include path in inputrc - - * fix bug of test_include_expand_path on Windows - - https://github.com/ruby/reline/commit/4d34e52d0b - -commit c2c0a083f024f9d0ee7a05c2cdbc4146ff3b2138 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-09-26 19:06:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-26 19:06:17 +0900 - - [ruby/irb] Disable pager in show-source test - (https://github.com/ruby/irb/pull/720) - - https://github.com/ruby/irb/commit/5669efa4c1 - -commit 4199e49cad0adddb48d58fa2b0a50563bfd40dac - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-09-19 20:18:00 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-26 17:31:10 +0900 - - Optimize Range#bsearch by reducing the number of Integer#+ calls - -commit 91042ec0ae2a8285ad68c101ff384bd7e3f4e260 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-09-20 07:01:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-26 17:31:10 +0900 - - Add benchmarks for Range#bsearch - -commit 6d7730ab98a0cb8708ff7f1ff163458cc3e1e0cd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-26 17:25:08 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-26 17:25:08 +0900 - - Run crash report test processes without `RUBY_ON_BUG` - - These processes are to be crashed, avoid running debugger. - -commit 8233572d45a23193d02a1f1f6bd09e997b0ccaa0 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-09-26 17:01:24 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-09-26 17:01:24 +0900 - - Prevent warnings: "unused literal ignored" - - ``` - [24688/26146] TestParse#test_named_capture_in_block(eval at /home/chkbuild/chkbuild/tmp/build/20230926T063004Z/ruby/test/ruby/test_parse.rb:999):1: warning: unused literal ignored - (eval at /home/chkbuild/chkbuild/tmp/build/20230926T063004Z/ruby/test/ruby/test_parse.rb:999):1: warning: unused literal ignored - (eval at /home/chkbuild/chkbuild/tmp/build/20230926T063004Z/ruby/test/ruby/test_parse.rb:999):1: warning: unused literal ignored - (eval at /home/chkbuild/chkbuild/tmp/build/20230926T063004Z/ruby/test/ruby/test_parse.rb:999):1: warning: unused literal ignored - (eval at /home/chkbuild/chkbuild/tmp/build/20230926T063004Z/ruby/test/ruby/test_parse.rb:999):1: warning: unused literal ignored - (eval at /home/chkbuild/chkbuild/tmp/build/20230926T063004Z/ruby/test/ruby/test_parse.rb:999):1: warning: possibly useless use of + in void context - = 0.00 s - ``` - -commit 55a297c8400f397465a2c9ecf0f5324691420d2a - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-09-26 16:42:47 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-09-26 16:42:47 +0900 - - Prevent warnings: "unused literal ignored" - - The test emits many warnings under `RUBYOPT=-w` - - ``` - [22699/26146] YARP::CompilerTest#test_FloatNode<compiled>:1: warning: unused literal ignored - <compiled>:1: warning: unused literal ignored - <compiled>:1: warning: unused literal ignored - <compiled>:1: warning: unused literal ignored - = 0.00 s - ``` - -commit 6b66b5fdedb2c9a9ee48e290d57ca7f8d55e01a2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-26 13:25:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-26 15:35:40 +0900 - - [Bug #19902] Update the coderange regarding the changed region - -commit f0d827860783afd34e12450dd310e50917d396e3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-26 14:28:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-26 14:28:49 +0900 - - Run crash report test processes without `RUBY_ON_BUG` - - These processes are to be crashed, avoid running debugger. - -commit 5eef125afe0c2b02dd4fc92a393bad95768fd330 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-26 09:02:37 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-26 09:02:37 +0900 - - Dump backtraces to an arbitrary stream when using libprocstat - -commit d2cc4437a13c0eda8e1003131a1ceef7050d38b0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-26 08:31:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-26 08:31:51 +0900 - - Labels cannot be at the end of block - -commit 295862e22ad88b3c7204df18b9b6a8560a1896f9 - Author: Jun Aruga <jaruga@ruby-lang.org> - AuthorDate: 2023-09-26 00:55:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-26 02:59:04 +0900 - - [ruby/zlib] Workaround: Fix test failures on Ubuntu jammy s390x. - - This commit fixes the test failures on the zlib in Ubuntu jammy s390x. - - According to the <https://packages.ubuntu.com/jammy-updates/zlib1g> - - `zlib_1.2.11.dfsg-2ubuntu9.2.debian.tar.xz`, - the zlib deb package is applying the patch 410.patch (madler/zlib#410), and - configured by `./configure --dfltcc` on Ubuntu jammy s390x. The `--dfltcc` - is to enable the deflate algorithm in hardware. - - It produces a different (but still valid) compressed byte stream, and causes - the test failures in ruby/zlib. As a workaround, set the environment variable - `DFLTCC=0` disabling the implementation in zlib on s390x to the failing tests. - - Note we need to test in a child Ruby process with `assert_separately` to test - on the `DFLTCC=0` set by the parent Ruby process. - - https://github.com/ruby/zlib/commit/9f3b9c470c - -commit ca2594535dd314086b5599fcd39cd80f863d80f4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-26 02:15:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-26 02:15:38 +0900 - - Add a missing label - -commit cbb38331dd3d0df2de0b7857ee655ab5c3a5229a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-26 02:07:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-26 02:07:32 +0900 - - Fix build on FreeBSD - -commit 766b06dfa3455c27959f8e45d28f3418e2b4ef3f - Author: elfham <38372058+elfham@users.noreply.github.com> - AuthorDate: 2023-09-25 23:28:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-25 23:28:21 +0900 - - [ruby/reline] Update to Unicode 15.1.0 - (https://github.com/ruby/reline/pull/591) - - https://github.com/ruby/reline/commit/c2fc1f771a - -commit 904413997fcc8a14020f01b411d4d8eecd88e670 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-10 00:13:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 23:22:52 +0900 - - [Feature #19790] [DOC] Fix the manual page as crash report - - Also add missing `%f` and `%F`. - -commit e2a5f0469c7073c2a4d0a6e9a0f493b9967ac984 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-25 21:41:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 23:04:09 +0900 - - Use named references for method/class/module definitions - -commit 03ef85bee7a9982f4ed30639a52402074ccf4202 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-25 20:25:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 23:04:09 +0900 - - Extract class/module context checks - -commit 56604c7a3bb5ee8485baf84c100d5662a2666176 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-25 19:52:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 23:04:09 +0900 - - Split the build of `RESBODY` nodes - -commit 4449dcac15c64d93462babaacb6fd8bf4c5d3c6b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-25 17:56:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 23:04:09 +0900 - - Reduce stack usage in `string_content` - -commit dd292640bf8219cfaf8b0127880631d89ce51322 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-24 23:54:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 23:04:09 +0900 - - Remove `escape_Qundef` - - Ripper dispatcher methods always escape `Qundef` by `get_value`. - -commit 963d12722e959788ea9dcfa09c5cfb18e9532567 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-24 23:19:15 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 23:04:09 +0900 - - Name midrules in complex rules - -commit fbe4db518289e0b70e770376236740b86b8e86e2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-25 02:28:36 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 23:04:09 +0900 - - ripper: Support named references in the DSL - -commit bab01d284c86b39952baaddb15901fd4a15e4151 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-13 15:02:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - [Feature #19790] Rename BUGREPORT_PATH as CRASH_REPORT - -commit f714448be7613017779d196daa72238b0efffaba - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-21 17:29:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - Honor the same option given later - -commit 70e8a08295114fa3cb112ddb42844889f7f98eb1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-09 18:25:34 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - Add `--bugreport-path` option - - It has precedence over the environment variable `RUBY_BUGREPORT_PATH`. - -commit 696f08238bc25a27e4b96c355c26bc0d27738548 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-10 00:16:02 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - Add "piping bug reports to a program" to the manual page - -commit 7c48a70c47998efd66c4fa3a062eaf66e6dd97d4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-05 22:12:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - Test bug_report - -commit 7e2775b057d19d5ed06877c3b02299e3b5d2beb7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-05 22:11:52 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - Invoke the command when RUBY_BUGREPORT_PATH starts with `|` - -commit 0f642907046e98cc026b50416bd63212b92112cd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-05 22:10:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - Add `rb_w32_uspawn_process` - -commit 6bb4c9de094c824cc3fa43ebeebeda2273fc86b4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-10 00:13:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - Add `RUBY_BUGREPORT_PATH` to the manual page - -commit 530b5ef6b6cf3c253f75f5c267234541f7ef4122 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-04 16:56:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - Test bug_report - -commit be40eacc9d20118e27cfa7d047f7fceea5ef6ab6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-05 19:56:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - Extract `expand_report_argument` - -commit 89b3c111ff0b846d9ded0cff3ca08cb566c6cc25 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-01 04:12:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - Redirect to RUBY_BUGREPORT_PATH file - -commit 85984a53e87dfbccb52aba952367fddea4a77870 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-04 15:30:36 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - Abort dumping when output failed - -commit ac244938e8b97c8bd42d1dc8ed820091e6ef5537 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-01 03:04:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-25 22:57:28 +0900 - - Dump backtraces to an arbitrary stream - -commit acd44902b917230066b4fc7ea6c7e12556274512 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-09-25 22:20:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-25 22:53:34 +0900 - - [ruby/yarp] Fix crashes in parsing block arguments - - https://github.com/ruby/yarp/commit/e1f2fde775 - -commit 0e808183eea91b610a17a941e4592b494e445203 - Author: David Rodriguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-09-23 05:22:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-25 16:13:21 +0900 - - [rubygems/rubygems] Allow standalone mode to work on a Windows edge case - - If a gem is located in a different drive than the Gemfile, standalone - mode will fail to generate the `bundler/setup` script, failing with an - error like - - ``` - ArgumentError: different prefix: "C:/" and "D:/a/rubygems/rubygems/bundler/tmp/2/bundled_app/bundle/bundler" - C:/hostedtoolcache/windows/Ruby/3.0.5/x64/lib/ruby/3.0.0/pathname.rb:528:in `relative_path_from' - D:/a/rubygems/rubygems/bundler/tmp/2/gems/system/gems/bundler-2.4.20/lib/bundler/installer/standalone.rb:58:in `gem_path' - D:/a/rubygems/rubygems/bundler/tmp/2/gems/system/gems/bundler-2.4.20/lib/bundler/installer/standalone.rb:33:in `block (2 levels) in paths' - D:/a/rubygems/rubygems/bundler/tmp/2/gems/system/gems/bundler-2.4.20/lib/bundler/installer/standalone.rb:32:in `map' - D:/a/rubygems/rubygems/bundler/tmp/2/gems/system/gems/bundler-2.4.20/lib/bundler/installer/standalone.rb:32:in `block in paths' - ``` - - I'm fixing this by falling back to using a full path in this case. - - This was caught by a failing spec, so I'm not adding new specs. - - https://github.com/rubygems/rubygems/commit/3cb9b9ab7a - -commit 36cd2b2a52dec47f9cf166a730026ada21fbd828 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-25 06:57:21 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-25 06:57:21 +0900 - - [DOC] Correction for doc guide + TOC fix in File (#8505) - -commit f43dac0df29c137ae966362f7faf26084468a0fb - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-24 22:07:52 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-24 22:07:52 +0900 - - Add rb_hash_free for the GC to use - -commit 36cdf163dfbcac5b0e7fedbd55c817b5d5c971fb - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-24 22:07:34 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-24 22:07:34 +0900 - - Add hash_st_free - -commit 34d802f32f00df1ac0220b62f72605827c16bad8 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-24 11:13:57 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-24 12:58:01 +0900 - - Refactor to use ripper_new_yylval2 - -commit 94d7c7080191b0ee3b4a8247788208aa732ce810 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-24 09:50:01 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-24 09:50:01 +0900 - - Fix test thread leakage - -commit f38f8d4f4ab5db40eb8a4f6d21b1b73e72b344f4 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-23 19:49:43 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-24 09:08:39 +0900 - - The first arg of NEW_OPT_ARG is always 0 - -commit c42261059dfebabbf0391327a5e077545a9bc438 - Author: Adam Hess <HParker@github.com> - AuthorDate: 2023-09-24 04:41:55 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-09-24 06:10:46 +0900 - - [Bug #19901] - - fix leak in module clone - - Co-authored-by: Peter Zhu <peter@peterzhu.ca> - -commit 61a2e9450c025b6a7499719089db5b4ae0317ce6 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-23 08:16:21 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-24 00:24:41 +0900 - - Fix memory leak in Hash#rehash for ST hashes - - We need to free the old ST table in Hash#rehash. - - Co-authored-by: Adam Hess <adamhess1991@gmail.com> - -commit 1da97292f86c30f863bfa1bc338b2d8e23124d2c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-23 16:05:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-09-23 16:05:47 +0900 - - Ignore rbs test failures - - For some reason, it's been failing only on YJIT, but apparently it's - reproducible on the interpreter as well. So it's not related to YJIT. - - rbs marked rbs tests on Ruby master as allow_failures - https://github.com/ruby/rbs/pull/1536, so it's known to not work on Ruby - master. - - We should revert this once we fix the flaky test failure on Ruby master. - -commit e581b78ed2d69a47a23deb167ea4a63b5f195fe9 - Author: Hartley McGuire <skipkayhil@gmail.com> - AuthorDate: 2022-12-15 08:32:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-23 11:22:25 +0900 - - Improve performance of include? by 5-10x - - Rails uses IPAddr#include? to evaluate what it should use as the - client's remote ip by filtering potential ips against a trusted list - of internal ips. In a _very_ minimal app, #include? was showing up in - a profile as ~1% of request time. - - The issue is that #include? was converting itself and the other value - passed in to ranges of IPAddr. This mean as a worst case (where other is - a non-IPAddr, like a String) then there would be 5 IPAddr instances - created (other -> IPAddr, and two each for the conversions to ranges). - However, wrapping the begin and end values as IPAddr is not needed - because they are necessarily fixed addresses already. - - This patch extracts the logic for getting the begin_addr and end_addr - from the #to_range method so that they can be used in #include? without - having to instantiate so many IPAddr. - - Benchmark: - - ```ruby - net1 = IPAddr.new("192.168.2.0/24") - net2 = IPAddr.new("192.168.2.100") - net3 = IPAddr.new("192.168.3.0") - net4 = IPAddr.new("192.168.2.0/16") - - Benchmark.ips do |x| - x.report("/24 includes address") { net1.include? net2 } - x.report("/24 not includes address") { net1.include? net3 } - x.report("/16 includes /24") { net4.include? net1 } - x.report("/24 not includes /16") { net1.include? net4 } - x.compare! - end - ``` - - Before: - - ``` - Comparison: - /24 not includes /16: 175041.3 i/s - /24 not includes address: 164933.2 i/s - 1.06x (± 0.00) slower - /16 includes /24: 163881.9 i/s - 1.07x (± 0.00) slower - /24 includes address: 163558.4 i/s - 1.07x (± 0.00) slower - ``` - - After: - - ``` - Comparison: - /24 not includes /16: 2588364.9 i/s - /24 not includes address: 1474650.7 i/s - 1.76x (± 0.00) slower - /16 includes /24: 1461351.0 i/s - 1.77x (± 0.00) slower - /24 includes address: 1425463.5 i/s - 1.82x (± 0.00) slower - ``` - -commit 2ceb5363f9b15cffd3901220463a1175a32b89f7 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-23 05:14:09 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-23 05:14:09 +0900 - - Try to fix compilation on m68k - - Compilation is failing on m68k-linux with: - - ``` - ./include/ruby/internal/static_assert.h:51:46: error: static assertion failed: "sizeof_method_def: offsetof(rb_method_definition_t, body)==8" - 51 | # define RBIMPL_STATIC_ASSERT0 __extension__ _Static_assert - | ^~~~~~~~~~~~~~ - ./include/ruby/internal/static_assert.h:70:5: note: in expansion of macro 'RBIMPL_STATIC_ASSERT0' - 70 | RBIMPL_STATIC_ASSERT0(expr, # name ": " # expr) - | ^~~~~~~~~~~~~~~~~~~~~ - ./internal/static_assert.h:13:24: note: in expansion of macro 'RBIMPL_STATIC_ASSERT' - 13 | # define STATIC_ASSERT RBIMPL_STATIC_ASSERT - | ^~~~~~~~~~~~~~~~~~~~ - ./method.h:203:1: note: in expansion of macro 'STATIC_ASSERT' - 203 | STATIC_ASSERT(sizeof_method_def, offsetof(rb_method_definition_t, body)==8); - | ^~~~~~~~~~~~~ - ``` - -commit d28589987913ec62862edbabd23fc770ed475770 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-23 03:53:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-23 03:53:55 +0900 - - [YARP] Use the integer base flag (#8476) - - Use the integer base flag - -commit 6de1a9238b3482d688dce873d22a4a2d61afc4a0 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-09-23 01:05:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-23 02:08:04 +0900 - - [ruby/yarp] Check class name to be a constant path node or a constant read node - - https://github.com/ruby/yarp/commit/fd7c44f13f - -commit 9abaf392b1dd7d91392c2a35541ab1838b0b9e2f - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-23 01:05:47 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-23 01:05:47 +0900 - - Resync yarp (#8498) - - * [YARP] Reject numbered parameters in block parameters - - * [YARP] Do not allow BEGIN except the toplevel - - --------- - - Co-authored-by: Haldun Bayhantopcu <haldun@github.com> - -commit c54e225f34957967709dee59c0d66b265fd30e05 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-09-23 00:18:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-23 00:47:56 +0900 - - [ruby/yarp] Introduce YP_TOKEN_METHOD_NAME - - https://github.com/ruby/yarp/commit/e855bf415c - -commit 7424143730f81d342995ab6345ffec5c68296da8 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-23 00:43:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-23 00:43:00 +0900 - - [YARP] Remove minor instances of rb_intern (#8497) - -commit ea5f8e123cb04f995ffd1f893a22e45d5693a8ea - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-22 23:43:28 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-22 23:45:54 +0900 - - Magical wait to get rid of deadlock on macOS - -commit 416a8202bc20dab6b6cae1de656f03f90e6da239 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-21 02:10:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 23:19:29 +0900 - - [ruby/yarp] use `yp_statements_node_body_length` a little bit more - - https://github.com/ruby/yarp/commit/65d8816178 - -commit 02022cef53895cf72181c70a306f5f54f752f069 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-22 23:16:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 23:17:07 +0900 - - [ruby/stringio] [DOC] Fix link - (https://github.com/ruby/stringio/pull/65) - - https://github.com/ruby/stringio/commit/e3ea087d04 - -commit a5ae5f71fd56357104977952a29db1e70aa658ea - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-20 11:10:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 23:07:48 +0900 - - [ruby/yarp] Fix listener leave event order - - https://github.com/ruby/yarp/commit/1e6e264836 - -commit 170e622aadc8287bfce78481036fca658b46c6e6 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-22 21:42:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 22:58:45 +0900 - - [ruby/prettyprint] [DOC] Link fixes - - https://github.com/ruby/prettyprint/commit/f1f583c827 - -commit 8b236e0c66da8f92e9fc33de66cfbc8e4b0c0763 - Author: Adam Hess <adamhess1991@gmail.com> - AuthorDate: 2023-09-21 01:26:31 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-22 22:44:58 +0900 - - [Bug #19896] - - fix memory leak in vm_method - - This introduces a unified reference_count to clarify who is referencing a method. - This also allows us to treat the refinement method as the def owner since it counts itself as a reference - - Co-authored-by: Peter Zhu <peter@peterzhu.ca> - -commit f59b488b5a7f6e46e3e6d80d2b0a269e7d937a30 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-09-22 22:00:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 22:00:32 +0900 - - [ruby/irb] Page show_source's output - (https://github.com/ruby/irb/pull/719) - - https://github.com/ruby/irb/commit/3cedc5cb62 - -commit c0d27af114740b67c6f278997b7f70f854b99e64 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-09-21 16:32:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 21:40:56 +0900 - - [ruby/yarp] Create arguments when necessary - - https://github.com/ruby/yarp/commit/123332f255 - -commit c8c35ded7427ad5742338495b2b46218616f1cb6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-22 19:41:52 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-22 19:41:52 +0900 - - [YARP] Suppress constant redefinition warning - - ``` - <compiled>:1: warning: already initialized constant Bar - test/yarp/compiler_test.rb:139: warning: previous definition of Bar was here - ``` - -commit 50e3b27db7ebf3bceffaaa2852e00a3c27e494c7 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-09-22 02:55:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 16:29:22 +0900 - - [ruby/zlib] Add truffleruby-head in CI - - * The latest release does not have this fix: - https://github.com/oracle/truffleruby/commit/c77f8bb35db084c99d1f5b14748267866004222e - - https://github.com/ruby/zlib/commit/8abc80b994 - -commit fb7a2ddb4be21a6d0def8286f341b1b4ee368fe0 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-20 23:51:39 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-22 11:25:53 +0900 - - Directly free structure managed by imemo tmpbuf - - NODE_ARGS, NODE_ARYPTN, NODE_FNDPTN manage memory of their - structure by imemo tmpbuf Object. - However rb_ast_struct has reference to NODE. Then these - memory can be freed directly when rb_ast_struct is freed. - - This commit reduces parser's dependency on CRuby functions. - -commit bf129370d32da9b673d242bb3c9661f2188b3ad0 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-09-20 05:59:07 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-22 07:00:49 +0900 - - [YARP] Implement ConstantPathTargetNode - - Co-Authored-By: kddnewton <kevin.newton@shopify.com> - -commit 48b141b49dc1f6509e33fb94d4beb474862d9b0a - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-22 05:58:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 06:08:28 +0900 - - [ruby/pstore] [DOC] Link fixes - - https://github.com/ruby/pstore/commit/3f328a1e0e - -commit 2df00640ff098a305eacee48cf2c77c9d9bdd81e - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-08-31 18:52:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 05:01:23 +0900 - - [ruby/openssl] Ruby/OpenSSL 3.2.0 - - https://github.com/ruby/openssl/commit/6b3dd6a372 - -commit a2f1195bebca468eed7e8bf650027e3d3747c141 - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-08-31 18:46:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 05:01:23 +0900 - - [ruby/openssl] Update README and gemspec description - - * Reword the description in README for more clarity. - - * Add a compatibility matrix of our stable branches and explain the - maintenance policy. - - * Remove the obsolete paragraph for how to use the gem in Ruby 2.3, - which is no longer supported. - - https://github.com/ruby/openssl/commit/7691034fcb - -commit 5c11dea40c94f669778946498fa5978abeeda537 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-19 11:02:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 04:53:56 +0900 - - [rubygems/rubygems] Reduce allocations when parsing lockfile - - ``` - ==> memprof.after.txt <== - Total allocated: 673.08 kB (7644 objects) - Total retained: 107.35 kB (1018 objects) - - ==> memprof.before.txt <== - Total allocated: 739.12 kB (9140 objects) - Total retained: 138.61 kB (1695 objects) - ``` - - Savings will scale by the number of lines in the lockfile - - https://github.com/rubygems/rubygems/commit/f6abf4439c - -commit c34a50de315c3cb9a4bf5b04c5ead8160b42d5f3 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-21 22:35:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 04:33:50 +0900 - - [ruby/yarp] encourage the compiler to compile `lex_keyword` more efficiently - - https://github.com/ruby/yarp/commit/f7bb139e2f - -commit a7b3217fff72df6a547ef9df4a28aa602523bd5f - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-22 04:28:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-22 04:28:08 +0900 - - [YARP] Add tests for popped instructions (#8494) - -commit 39a6272cf45c8946255c20708e6153ce8c222699 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-22 01:50:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 04:08:11 +0900 - - [rubygems/rubygems] Fix safe marshal test on jruby - - Allow for variance in order of dumped ivars, fix by setting the disallowed ivar on an object that will have no other ivars so the index is consistent - - https://github.com/rubygems/rubygems/commit/ccb8f42753 - -commit 812c8196b69b15713e7bdc9843329d9c490497a8 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-01 04:44:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 03:30:37 +0900 - - [rubygems/rubygems] Remove usage of Dir.chdir that just execute a subprocess - - Preferring instead to spawn the subprocess in the correct directory - - https://github.com/rubygems/rubygems/commit/ad5abd6a45 - -commit e9ed0b3068f54f32d5116ff9d73833d96229fde9 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-08 03:43:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 03:28:54 +0900 - - [rubygems/rubygems] Stop bundler eagerly loading all specs with exts - - We were setting the wrong `extension_dir` for git specs stubs - - Additionally, the call to `self.extension_dir` was loading the - remote spec, which was avoidable since the stub had an extension dir - (and in fact its #gem_build_complete_path does exactly what we want - anyway) - - Finally, now set the base_dir when loading the remote_spec from a - stub specification, since the git source sets the base dir for stubs - based on where the spec _will_ be installed to, and we want to preserve - that so the base_dir for the loaded spec & the stub are the same - - https://github.com/rubygems/rubygems/commit/a94acb465b - -commit 02fa2acbde50f282409346544844182e9a25cc6b - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-19 09:30:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 03:25:04 +0900 - - [rubygems/rubygems] Freeze more strings in generated gemspecs - - Specifically, this will have frozen string literals for: - - Gem platform tuple entries - - Gem::Version strings - - Gem::Specification#installed_by_version - - Dependency requirement strings - - https://github.com/rubygems/rubygems/commit/6195da5bdb - -commit 7f407e0240ebd41d9fb1ea1bbd15442ed8744b34 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-09-20 02:19:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 03:04:56 +0900 - - [ruby/openssl] Fix test_pkey_ec.rb on FIPS. - - https://github.com/ruby/openssl/commit/d07183f639 - -commit f370c4dc033ee2ac112343b37144fcdafd254fa3 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-09-20 02:54:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 03:04:55 +0900 - - [ruby/openssl] test_pkey.rb: Refactor the test_ed25519 on FIPS. - - * Split the test in the FIPS case as another test. - * test/openssl/utils.rb: Add omit_on_fips and omit_on_non_fips methods. - - https://github.com/ruby/openssl/commit/4d64c38ed0 - -commit 3123b2fa0e2e5eddde4f751e084282ba655cbd57 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-09-20 02:12:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-22 03:04:55 +0900 - - [ruby/openssl] test_fips.rb: Fix the `OpenSSL.fips_mode` affecting other tests. - - Run the test with `assert_separately` for the `false` value of the - `OpenSSL.fips_mode` not to affect other tests. - - https://github.com/ruby/openssl/commit/2fe3438d8a - -commit 22a44735f08009cd53c5aa9a7e912378869aa29a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-21 23:01:02 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-21 23:01:02 +0900 - - Use ANSI-style prototype declarations instead of the old K&R style - -commit 20bd19a9ad1a2052c5616af70d4dd67657a19143 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-21 18:18:27 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-21 18:18:27 +0900 - - Move YARP_BUILD_DIR to common.mk - - It does not need to be an absolute path. - -commit 0a423d4c4e84bc024d5dabe86227c1f0b509a898 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-21 13:32:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-21 16:40:58 +0900 - - [rubygems/rubygems] Aggressively optimize allocations in SafeMarshal - - Reduces allocations in a bundle install --full-index by an order of magnitude - - Main wins are (a) getting rid of exessive string allocations for exception message stack - - (b) Avoiding hash allocations caused by kwargs for #initialize - - (c) avoid using unpack to do bit math, its easy enough to do by hand - - (d) special case the most common elements so they can be read without an allocation - - (e) avoid string allocations every time a symbol->string lookup is done by using symbol#name - - https://github.com/rubygems/rubygems/commit/7d2ee51402 - -commit 7c98d520f4ae9bd2e2496f5bddc455af576c499f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-21 01:30:17 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-21 12:19:00 +0900 - - [Bug #19892] Clean intermediate files regardless `-keep_temp` - - Not to include such files in the result packages. - -commit 7ba88e13e00720a3190aca3bda3e7b50b390b096 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-21 01:28:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-21 12:19:00 +0900 - - Make `clean.create` to accept a block - - Like `File.open`, yield an IO to write the file. - -commit 2b41df247794103a4d392c763156b02451772237 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-21 10:50:08 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-21 12:18:41 +0900 - - `.NOTPARALLEL` with prerequisites needs recent GNU Make - - GNU Make prior to 4.4 just ignores the prerequisites, and runs - everything in serial. - -commit 7e350f53107533856b0a87c26e5a1e5505ea5d59 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-09-19 15:29:35 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-21 10:30:58 +0900 - - Optimize Range#bsearch for beginless/endless ranges within Fixnum - -commit ab637cad2b582e8247bafd87a3b0f6323d564f64 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-20 21:32:40 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-21 10:23:14 +0900 - - [Bug #19624] Clean up backquote IO - - It should not be hidden, since it can be grabbed by a fiber scheduler. - -commit 7ffee5681f85de3fe74c25a90e05e31616113123 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-16 03:08:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-21 04:48:28 +0900 - - [ruby/date] [DOC] Fix link - - https://github.com/ruby/date/commit/2adb917487 - -commit d6abca459f5c785aee0e77883710ec47fed1a98f - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-20 00:46:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-21 03:30:34 +0900 - - [ruby/yarp] Print locations using line / col instead of offsets - - This commit changes printing of locations to use the format - (start_line,start_column)-(end_line,end_column) instead of using - offsets. - - https://github.com/ruby/yarp/commit/c078696e22 - -commit 0a630fa461a7260235842e482f682deca30172d6 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-09-20 17:36:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-21 02:50:32 +0900 - - [ruby/yarp] Check whether the conditional predicate is closed - - https://github.com/ruby/yarp/commit/5022b51db2 - -commit 639971a0800a4ca1afe9c741e42c0fbd94aa0879 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-21 02:14:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-09-21 02:14:56 +0900 - - --disable-jit-support no longer exists - -commit 4c2fc88b2114045f496a0cd2743b7984d113e274 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-21 00:05:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-21 00:05:45 +0900 - - [YARP] Pop AliasNode when appropriate (#8466) - -commit 53a373078d75544f05c3fb1eb6c6ee2d95282a08 - Author: Nicholas Browning <shmolf@gmail.com> - AuthorDate: 2023-07-20 09:50:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-20 23:52:52 +0900 - - [DOC] initial operators commit - -commit 96c5a4be7b0d72502001734770af0f4a735c544c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-20 09:48:41 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-20 23:19:24 +0900 - - Fix memory leak in complemented method entries - - [Bug #19894] - - When a copy of a complemented method entry is created, there are two - issues: - - 1. IMEMO_FL_USER3 is not copied, so the complemented status is not - copied over. - 2. In rb_method_entry_clone we increment both alias_count and - complemented_count. However, when we free the method entry in - rb_method_definition_release, we only decrement one of the two - counters, resulting in the rb_method_definition_t being leaked. - - Co-authored-by: Adam Hess <adamhess1991@gmail.com> - -commit 3c11cdbcfe5ebcf430b0cdfefb0b92724eebe543 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-20 10:32:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-20 13:00:18 +0900 - - Fix the case of file to be ignored with to be removed - - The case of 7fc73ab5f6fbe46655855079954b26dcc14576b3, which modified - `.gitignore` and `.github/workflows/main.yml`. Both files need to be - rejected and restored, but since the latter file was not there before, - `git checkout` failed and the former file could not be restored along - with it. To fix this failure, restore the ignored files one by one. - -commit afaa164a058209e64dc2bedadc1fd932136d8ae5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-20 09:08:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-20 13:00:18 +0900 - - Add a successful sync test case - -commit 843c83ee5f8f4c26b70d7873df0c3d23de597b4c - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-25 04:31:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:03:04 +0900 - - [rubygems/rubygems] Give up, load Time via Marshal.load - - https://github.com/rubygems/rubygems/commit/6c92ba2ba3 - -commit f4a5fac0d2671ec98f50a561eefd4ca3702f7cb1 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-25 01:57:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:03:04 +0900 - - [rubygems/rubygems] Ruby 2.6 compat - - https://github.com/rubygems/rubygems/commit/1a84960af3 - -commit cadca9f67eba9e101558aa32594646c3ece17c31 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-25 01:23:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:03:03 +0900 - - [rubygems/rubygems] All rubies working with different time zones - - Tested with: - - `ruby -e 'trap("INT") { exit 1 }; TZ=%w[UTC +0000 -0000]; RUBY=%w[ruby-2.7 ruby-3.2.2 jruby-9.4 truffleruby-22 truffleruby-23]; TZ.product(RUBY).each { |t, r| puts ?**120, "TZ=#{t} RUBY=#{r}", "*"*120; system({"TZ"=>t,"RUBY"=>r}, *ARGV) }' zsh -lic 'chruby $RUBY; ruby -vw -Ilib test/rubygems/test_gem_safe_marshal.rb --verbose=progress'` - - https://github.com/rubygems/rubygems/commit/6192005afb - -commit c65c88e65c0d1c175dd2c33708b488e3f8268fda - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-24 12:46:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:03:03 +0900 - - [rubygems/rubygems] Tests passing on truffleruby 22 in addition to 23 - - https://github.com/rubygems/rubygems/commit/8065530d43 - -commit d3628e6ac4ac4703c88c594af649773205722287 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-24 10:58:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:03:02 +0900 - - [rubygems/rubygems] safe_load tests passing on jruby & truffleruby - - https://github.com/rubygems/rubygems/commit/a64b21b052 - -commit e52f9bd41e1c407ac675fa3d1fbaabec854f6968 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-22 01:13:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:03:02 +0900 - - [rubygems/rubygems] Bundler error handling - - https://github.com/rubygems/rubygems/commit/63b422b71a - -commit f0d1b0cc4b5a99de9dc709b8f43d8be8e18c7323 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-21 15:37:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:03:01 +0900 - - [rubygems/rubygems] Allow bundler to load from the dependency api - - https://github.com/rubygems/rubygems/commit/3303957286 - -commit fe90e83b482b7df84f6f1c7be70155df46dd4d3c - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-21 14:44:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:03:01 +0900 - - [rubygems/rubygems] Use safe_load in bundler when available - - https://github.com/rubygems/rubygems/commit/34d096e38a - -commit 7c6b500d8d5fad568780b21cc6a1deb3aa57e746 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-21 13:13:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:03:00 +0900 - - [rubygems/rubygems] Fix bundler specs using safe_load - - https://github.com/rubygems/rubygems/commit/ccb1bb5d3a - -commit 1fff3e44ff3248c2c0bbd2bd244d52f64cfdd8a5 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-21 02:42:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:03:00 +0900 - - [rubygems/rubygems] Verified working on mri/jruby/truffleruby with specs on rubygems.org - - https://github.com/rubygems/rubygems/commit/4f51741cc6 - -commit cdcc760dc0b3ca504b630e333c350da9e97dbbb2 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-19 07:49:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:02:59 +0900 - - [rubygems/rubygems] Broader version compatibility in marshal tests - - https://github.com/rubygems/rubygems/commit/6ec518c563 - -commit c80a4d453a26c1b5f1b57de31c8d1a2b69133a55 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-19 07:26:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:02:58 +0900 - - [rubygems/rubygems] Fix UTC time loading - - https://github.com/rubygems/rubygems/commit/2a4d0a44b0 - -commit d182d83ce929cd322f4a6fd134cd31be950eca77 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-19 05:35:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 11:02:58 +0900 - - [rubygems/rubygems] Add a Marshal.load replacement that walks an AST to safely load permitted classes/symbols - - https://github.com/rubygems/rubygems/commit/7e4478fe73 - -commit c47608494f961d2a8fe24b1a7b7f627b305cf7fe - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-09-15 01:52:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 10:16:54 +0900 - - [ruby/yarp] Convert constant pool entries to a string type in Java Loader - - * Fixes https://github.com/ruby/yarp/issues/1389 - * Fields of type `string` as kept as byte[]. - - https://github.com/ruby/yarp/commit/234c8f47c7 - -commit 38e98cbb6a29f984795504fbc64872526edd1197 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-20 08:34:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-20 08:34:50 +0900 - - Fix typo in "refinements" - -commit 4c1e367039d1a35f7eed8d2d80ce7eff2d69fcec - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-20 08:33:48 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-20 08:33:48 +0900 - - Restore deleted .gitignore - - It was deleted in 7fc73ab5f6fbe46655855079954b26dcc14576b3. - -commit 5b003148680fafe3574741a4003f3e8e68c0a6fa - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-20 06:09:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-09-20 06:10:38 +0900 - - Ignore JRuby extension sync - - Avoid alerting on failing with commits like - https://github.com/ruby/psych/commit/fb97d899c5a62b743159d5a3c77b0813d2cbf9b6 - -commit 3e4ccd6ddc4abbd3f08c628c4e56d54ef00c5bfa - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-20 00:35:22 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-20 04:38:41 +0900 - - [YARP] Use the static literal flag - -commit 7dee7e611661c335321c2bb8e6b4738ab9f7c2fd - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-09-19 22:46:30 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-20 03:52:32 +0900 - - [YARP] Implement GlobalVariableTargetNode - -commit 901d0b41254cfc41b337d755e9512ff78f51cbe2 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-20 03:24:06 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-20 03:25:01 +0900 - - Remove dead function Init_Method - - Init_Method no longer has any code, so we can remove it. - -commit 3fadb66bf18f75a607a8895e5aeca295ac89e17f - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-09-20 02:06:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 02:20:15 +0900 - - [ruby/yarp] Only use Ripper on CRuby - - https://github.com/ruby/yarp/commit/9c23f53d7b - -commit 7fc73ab5f6fbe46655855079954b26dcc14576b3 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-09-13 00:20:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 02:20:01 +0900 - - [ruby/yarp] Only keep semantic fields in Java, i.e. skip location fields - - * Add $YARP_SERIALIZE_ONLY_SEMANTICS_FIELDS to control where to serialize location fields at templating time, - this way there is no overhead for either case and nothing to check at runtime. - * Add a byte in the header to indicate whether location fields are included as expected. - * Fixes https://github.com/ruby/yarp/issues/807 - * Simplify the build-java CI job now that the FFI backend is available so JRuby can serialize. - * Support keeping some location fields which are still needed until there is a replacement - - https://github.com/ruby/yarp/commit/fc5cf2df12 - -commit 4da53fd3a7a08d80b0b63640a6351dd4d1250b72 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-20 01:30:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 01:57:46 +0900 - - [ruby/yarp] Better Node#pretty_print - - Respect the current indentation - - https://github.com/ruby/yarp/commit/068333ef49 - -commit a71001d34103a9539ad0deaf4cec0cebe71dc2a5 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-20 01:25:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 01:43:24 +0900 - - [ruby/yarp] Ignore parseing specific files on TruffleRuby to make CI green - - CI is currently failing due to an issue with Ripper on the latest - TruffleRuby version. This commit removes the offending tests from - running, to ensure CI is green again. - - https://github.com/ruby/yarp/commit/dae2c80c42 - -commit 0cda3ac45441a8325d40ab71074e93fe4c628c97 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-09-16 10:17:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 01:14:31 +0900 - - [ruby/yarp] fix: handling escaped whitespace in a %w list - - Introduces a new flavor of unescaping, YP_UNESCAPE_WHITESPACE, which - is the same as MINIMAL but also unescapes whitespace. - - Note that a spanning_heredoc.txt fixture test is updated to be less - wrong, but YARP's behavior doesn't yet fully match Ruby in this case. - - Fixes https://github.com/ruby/yarp/pull/1505 - - https://github.com/ruby/yarp/commit/0af69bdeb1 - -commit ffc1fc7a6df2c5d8d9f85d4db7c19e8af6fb6682 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-16 08:20:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 01:13:39 +0900 - - [ruby/yarp] Explicitly use u32 for constant pool - - https://github.com/ruby/yarp/commit/32b173e6c8 - -commit 2531ba4ba01b1303ae0c5a294d82a045b664da35 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-15 02:08:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 01:13:08 +0900 - - [ruby/yarp] Consistently place block arguments on block slot for call - - https://github.com/ruby/yarp/commit/fe208302e5 - -commit c7875340be63201adde698405d0c8a81a313d5bf - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-19 02:35:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 01:11:27 +0900 - - [ruby/yarp] fix computation of memsize for constant id lists - - https://github.com/ruby/yarp/commit/df72517fd1 - -commit 18622403acfb1e398a07b05d21d2ab39972c339e - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-16 01:56:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-20 01:11:27 +0900 - - [ruby/yarp] fix computation of memsize for node lists - - https://github.com/ruby/yarp/commit/02aab8b026 - -commit 5c5391f444624bcee6a258bcc7b4777c7c295ae7 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-09-19 05:35:02 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-19 22:54:15 +0900 - - [YARP] Implement ClassVariableTargetNode - -commit 2f8daa5f5128ca63154ae6adb139c24ec0e14b40 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-09-19 05:58:10 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-19 22:53:58 +0900 - - [YARP] Implement InstanceVariableTargetNode, LocalVariableTargetNode - -commit 91b10c0b77c5408cbbbc2fc6d678ee92b2d4b28a - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-09-19 05:50:33 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-19 22:53:39 +0900 - - [YARP] Implement ConstantTargetNode - -commit 4023637d20e4f9c4c4806e0fb27f868eea7612b3 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-19 06:07:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-19 16:25:51 +0900 - - [rubygems/rubygems] Reduce allocations for stub specifications - - This helps with memory usage during application boot time - - ``` - ==> memprof.after.txt <== - Total allocated: 1.43 MB (18852 objects) - Total retained: 421.12 kB (4352 objects) - - ==> memprof.before.txt <== - Total allocated: 2.43 MB (28355 objects) - Total retained: 469.69 kB (5425 objects) - ``` - - See https://bugs.ruby-lang.org/issues/19890 about the readline - allocations - - https://github.com/rubygems/rubygems/commit/d7eb66eee3 - -commit cea7e6ecca99ae7730ea5ac44ed15f62b1599664 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-19 06:16:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-19 16:14:53 +0900 - - [rubygems/rubygems] Lazily construct fetcher debug messages - - Avoids constructing several strings - - https://github.com/rubygems/rubygems/commit/8a322dbe11 - -commit 647390308239fbf82d159ecd83ed8df090af518d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-19 14:09:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-19 14:09:53 +0900 - - [Bug #18257] Register the class path of FrozenCore to mark - - ICLASS does not have the path usually, so it needs to be registered - separately. - -commit 4634405f7c7a7e0b5490ed3de35c12aad9c91bf5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-19 13:56:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-19 14:08:05 +0900 - - Stop exposing FrozenCore in headers - - Revert commit "Directly allocate FrozenCore as an ICLASS", - 813a5f4fc46a24ca1695d23c159250b9e1080ac7. - -commit b33e9f637d2af0b1dc447e31ffd3a31e26e47b13 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-09-19 11:13:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-19 11:22:15 +0900 - - [ruby/securerandom] Removed extra argument for build failure of ruby/ruby - - https://github.com/ruby/ruby/actions/runs/6230184763/job/16909829150 - - https://github.com/ruby/securerandom/commit/f60582432c - -commit dfb2b4cbc9aa5edc315e210bf6bfd92fcf6e45de - Author: nick evans <nicholas.evans@gmail.com> - AuthorDate: 2023-06-30 07:39:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-19 10:55:27 +0900 - - [ruby/securerandom] Add support for UUID version 7 - - Although the specification for UUIDv7 is still in draft, the UUIDv7 - algorithm has been relatively stable as it progresses to completion. - - Version 7 UUIDs can be very useful, because they are lexographically - sortable, which can improve e.g: database index locality. See section - 6.10 of the draft specification for further explanation: - - https://datatracker.ietf.org/doc/draft-ietf-uuidrev-rfc4122bis/ - - The specification allows up to 12 bits of extra timestamp precision, to - make UUID generation closer to monotonically increasing. This provides - between 1ms and ~240ns of timestamp precision. At the cost of some code - complexity and a small performance penalty, a kwarg may specify any - arbitrary precision between 0 and 12 extra bits. Any stronger - guarantees of monotonicity have considerably larger tradeoffs, so - nothing more is implemented. This limitation is documented. - - Ruby issue: https://bugs.ruby-lang.org/issues/19735 - - https://github.com/ruby/securerandom/commit/34ed1a2ec3 - -commit e77c766b7ab17e801c5cfa881754c392f8c13f0b - Author: 0x1eef <0x1eef@protonmail.com> - AuthorDate: 2023-09-15 15:35:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-19 10:32:18 +0900 - - [ruby/net-http] No longer neccessary to call `String#freeze` on string literals. - - See #144 - - https://github.com/ruby/net-http/commit/5a986c13d3 - -commit 465c222ef125a93b1cd457d18e70a7d58454f628 - Author: Yoshiki Takagi <yoshiki.tkg@gmail.com> - AuthorDate: 2023-09-16 16:24:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-19 10:06:35 +0900 - - [rubygems/rubygems] Bump actions/checkout to v4 in bundler gem template - - https://github.com/rubygems/rubygems/commit/5ed4c600da - -commit 230834d9bb5528834e7ddc7fcc616fef238eb6f5 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-09-19 08:58:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-19 10:04:54 +0900 - - [ruby/base64] Bump required_ruby_version to 2.4.0 - - The gem depends on String#unpack1, which was introduced in Ruby 2.4. - - https://github.com/ruby/base64/commit/9f0e4ba155 - -commit 0a2c4a60915fe07912ab5fb8a426e4d450b73564 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-19 08:27:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-19 08:27:18 +0900 - - [DOC] Add production performance tips to yjit.md (#8472) - - Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - -commit 1636f6abd62c03f77777d83324df3bfcedbe66c2 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-16 07:38:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-19 02:48:52 +0900 - - [ruby/yarp] Use compact_child_nodes where possible - - https://github.com/ruby/yarp/commit/c1911fa9b1 - -commit 54e676a88ba1a68b7302a32dad8c44197b55d5fe - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-19 01:34:20 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-19 01:34:20 +0900 - - [YARP] Restructure tests to compare YARP evaluation to CRuby evaluation (#8467) - - Previously, we were hardcoding the expected evaluation value. Now, - instead, we structure it so that we compare the YARP evaluation value - against CRuby's evaluation value. - -commit ec37636ab36af36155faa4dbcfebaa161dcf394d - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-09-12 18:53:57 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-18 22:34:38 +0900 - - Only sort the heap on platforms with compaction - -commit 8792e421ce5e501f87bdb449fe885e3a436a88f0 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-08-11 23:16:30 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-18 22:34:38 +0900 - - Allow pages to be sorted by pinned slot count - - By compacting into slots with pinned objects first, we improve the - efficiency of compaction. As it is less likely that there will exist - pages containing only pinned objects after compaction. This will - increase the number of free pages left after compaction and enable us to - free them. - - This used to be the default compaction method before it was removed - (inadvertently?) during the introduction of auto_compaction. - - This commit will sort the pages by the pinned slot count at the start of - a major GC that has been triggered by explicitly calling GC.compact (and - thus setting objspace->flags.during_compaction). - - It works using the same method by which we sort the heap by empty slot - count during GC.verify_compaction_references. - -commit 404a1c032a334768607d1d72b111201d0d243cfe - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-08-11 22:39:59 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-18 22:34:38 +0900 - - Move heap sorting into the main GC loop - - Previously it was only being sorted during the verify compaction - references stage - so would only happen during testing. - - This commit allows us to sort the heap prior to each explicit GC.compact - run - -commit d3852f71e4924b16a9fed6b43b86d11af036c432 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-08-09 05:09:37 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-18 22:34:38 +0900 - - Enable different heap sort methods during compaction - - pass the sorting function in as a function pointer so we don't always - sort by how empty a page is - -commit c492a7f8776fd384fc740f806536ec33c6fba59c - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-18 22:29:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-18 22:29:52 +0900 - - [YARP] Miscellaneous bug fixes (#8453) - - Miscellaneous bug fixes - -commit c87f2a4f156477ba962de19866a1f6298d567398 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-18 10:14:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-18 10:14:46 +0900 - - [Bug #19887] RUBYOPT should work without leading `-` - -commit 5c6e00b090a81d233ccff98e0d642e7dd0182bd0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-13 19:00:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-18 09:55:07 +0900 - - Simplify restoring ENV - -commit 8b4e54f9792769efd69028d19eb631cdf5fc60d9 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-09-18 06:25:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-18 06:25:49 +0900 - - [ruby/irb] Test should not depend on user's irbrc file specified by - ENV['IRBRC'] - (https://github.com/ruby/irb/pull/717) - - https://github.com/ruby/irb/commit/1d2d35dd33 - -commit 88262875fded2fc578e5bf6957dbf75068238538 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-18 02:23:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-18 02:23:59 +0900 - - Fix `git cat-file` condition - - When multiple files changed in the same directory to be removed, the - first file only was removed from changed set. - -commit 8d219a9bd7b484b301185319c940975e1d788b3e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-18 02:11:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-18 02:11:48 +0900 - - Refactor test_sync_default_gems.rb - -commit 5c94f3fe9d4c93dc3183494feb541959419077dc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-11 09:36:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-17 22:42:50 +0900 - - [ruby/fiddle] Suppress -Wundef warnings on arm64 macOS and Windows - (https://github.com/ruby/fiddle/pull/134) - - ``` - In file included from ../../../../ext/fiddle/fiddle.h:46: - /opt/local/include/ffi.h:477:5: warning: 'FFI_GO_CLOSURES' is not defined, evaluates to 0 [-Wundef] - ^ - ``` - - c.f. https://github.com/libffi/libffi/pull/796 - - https://github.com/ruby/fiddle/commit/d4feb57098 - -commit 72772a3caa16fd240aa1e9c9432e2d6492c0b0ac - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-16 11:45:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-17 22:05:58 +0900 - - [DOC] Mention "-" in ARGF - -commit 2dffd365048d48e4d8da8bd77a023f87d7266e9f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-17 21:11:54 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-17 21:11:54 +0900 - - Move special patterns to the common pattern - -commit bcb3247072e6973d0f6b50ca5fed238d5824bd28 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-17 19:18:23 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-17 19:18:23 +0900 - - [Bug #19778] Pass additional include options to INCFLAGS in common.mk - -commit e9a36f8abe3fae23878fd99ed5078717b9b7e826 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-17 15:30:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-17 16:22:01 +0900 - - Tag `p_lparen` and `p_lbracket` as `tbl` - - Remove tagging to the component for each reference. - -commit 69d7871b02fedf24de381c2bc514394eed9afd32 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-17 15:22:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-17 16:22:01 +0900 - - ripper: Preprocess ripper-dispatchable types only - - Keep the other types, which not having setter macros for ripper. - -commit df316be4016b0cce7aac4ccec52445d48606bf92 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-17 13:44:11 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-17 16:04:42 +0900 - - nd_aid of NODE_OP_ASGN_OR is not used then no need to set it - -commit cd67c0d2040f1ade0fe8b1533816281553bfe6e6 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-09-17 07:27:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-17 07:27:04 +0900 - - [ruby/irb] Test should not depend on user's irbrc file - (https://github.com/ruby/irb/pull/714) - - https://github.com/ruby/irb/commit/02703c46f9 - -commit 4aac7b1a9a3696ee06d193061a893e5290b79124 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-17 02:24:41 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-17 02:24:41 +0900 - - Another try to fix build in emscripten - - malloc_trim is defined in emscripten/emmalloc.h on emscripten. - -commit 25711683e86271385e8abe09a9c03782000e48db - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-09-16 08:58:26 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-09-17 00:02:31 +0900 - - Fix regression when testing inclusion in unbounded ranges - - Caused by 04a92a6764bf678919cf4b68a27496a39d6b886a. This treats - unbounded ranges of arbitrary objects the same as how unbounded - string ranges are treated: - - (..x) === y # (y <=> x) <= 0 - (...x) === y # (y <=> x) < 0 - (x..) === y # (x <=> y) <= 0 - - Fixes [Bug #19864] - -commit 8835ca23c138b2fa5e883acd6b368fdc25d7ce23 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-09-16 21:58:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 22:36:17 +0900 - - [ruby/yarp] Fix a possible null pointer deference - - https://github.com/ruby/yarp/commit/41f601b81b - -commit 209d5f8482d13a798f3ffd2faa6cbddb0f5b6724 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-16 22:08:55 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-16 22:08:55 +0900 - - Fix malloc_trim on emscripten - - ``` - gc.c:9746:5: error: implicit declaration of function 'malloc_trim' is invalid in C99 [-Werror,-Wimplicit-function-declaration] - malloc_trim(0); - ^ - ``` - - http://rubyci.s3.amazonaws.com/crossruby/crossruby-master-wasm32_emscripten/log/20230916T104311Z.fail.html.gz - -commit a8afedce6dfdbab8807134daa926b0936b5cd9a4 - Author: Chad Schroeder <chadrschroeder@users.noreply.github.com> - AuthorDate: 2023-09-16 21:48:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 21:48:32 +0900 - - [ruby/irb] Handle Concurrent Sessions and Saving Readline::HISTORY - (https://github.com/ruby/irb/pull/651) - - * handle concurrent sessions and saving Readline::HISTORY, fixes https://github.com/ruby/irb/pull/510 - - * separate tests - - * don't mutate the HISTORY object on the class - - * avoid repeated .to_i calls - - * remove intermediary history array - - * work with array, fix test comment - - --------- - - https://github.com/ruby/irb/commit/1681ada328 - - Co-authored-by: Stan Lo <stan001212@gmail.com> - -commit b4213a73b807cf8c8884e29d37308c46ca80352a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-14 22:45:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-16 17:24:21 +0900 - - [Feature #19839] Fix `Range#overlap?` for empty ranges - - Empty ranges do not overlap with any range. - - Regarding benchmarks, PR#8242 is significantly faster in some cases, - but one of these two cases is a wrong result. - - | |ActiveSupport| PR#8242|built-ruby| - |:--------------------------|------------:|-------:|---------:| - |(2..3).overlap?(1..1) | 7.761M| 15.053M| 32.368M| - | | -| 1.94x| 4.17x| - |(2..3).overlap?(2..4) | 25.720M| 55.070M| 21.981M| - | | 1.17x| 2.51x| -| - |(2..3).overlap?(4..5) | 7.616M| 15.048M| 21.730M| - | | -| 1.98x| 2.85x| - |(2..3).overlap?(2..1) | 25.585M| 56.545M| 32.786M| - | | -| 2.21x| 1.28x| - |(2..3).overlap?(0..1) | 7.554M| 14.755M| 32.545M| - | | -| 1.95x| 4.31x| - |(2..3).overlap?(...1) | 6.681M| 5.843M| 32.255M| - | | 1.14x| -| 5.52x| - |(2...3).overlap?(..2) | 6.676M| 5.817M| 21.572M| - | | 1.15x| -| 3.71x| - |(2...3).overlap?(3...) | 7.392M| 14.755M| 31.805M| - | | -| 2.00x| 4.30x| - |(2..3).overlap?('a'..'d') | 3.675M| 3.482M| 17.009M| - | | 1.06x| -| 4.89x| - -commit c3ef7a528b1fdfe7fc98b846fd2ccb0c07443682 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-09-16 06:08:59 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-09-16 16:52:46 +0900 - - Fix malloc_trim() on wasm32 - - ``` - compiling gc.c - gc.c:9746:5: error: implicit declaration of function 'malloc_trim' is invalid in C99 [-Werror,-Wimplicit-function-declaration] - malloc_trim(0); - ^ - 1 error generated. - ``` - -commit e9b503f1bb9692eda1d1f55f62c19d861b88a0d5 - Author: Shouichi Kamiya <shouichi.kamiya@gmail.com> - AuthorDate: 2023-08-18 10:30:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-16 14:57:19 +0900 - - [Feature #19839] Add Range#overlap? - - Add a method that returns true if two range overlap, otherwise false. - - ``` - (0..10).overlap?(5..15) #=> true - (0..10).overlap?(20..30) #=> false - ``` - -commit 7d08dbd015a16c27f2d9c77751e80fa6efba2d7a - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-09-16 12:10:09 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-16 12:10:09 +0900 - - Optimize Range#bsearch for beginless/endless ranges - - On Range#bsearch for endless ranges, we try positions at `begin + 2**i` (i = 0, 1, 2, ...) - to find a point that satisfies a given condition. - Subsequently, we perform binary searching with the interval `[begin, begin + 2**n]`. - - However, the interval `[begin + 2**(n-1), begin + 2**n]` is sufficient for binary search - because `begin + 2**(n-1)` does not satisfy the condition. - - The same applies to beginless ranges. - -commit 67dedf8cf634843488a477e53b9995b63e9aa291 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-16 11:56:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-16 12:00:06 +0900 - - Ignore changed files under removed paths - - This fixes the issue commit 43ab2acf8242c580b1ef5d644ea94d48669d4869 - "Resurrect gem-specific patterns for sync" described. - -commit 9aeb6e72db7a049a620a6d10836992dc9d0cf3b3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-16 10:41:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-16 10:41:00 +0900 - - YJIT: Avoid creating a vector in get_temp_regs() (#8446) - - * YJIT: Avoid creating a vector in get_temp_regs() - - Co-authored-by: Alan Wu <alansi.xingwu@shopify.com> - - * Remove unused import - - --------- - - Co-authored-by: Alan Wu <alansi.xingwu@shopify.com> - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - -commit 7f96c9be9e998adb0f9db751bf9cd65c157c1bd7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-16 09:27:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 09:32:52 +0900 - - [ruby/yarp] Bump to version 0.12.0 - - https://github.com/ruby/yarp/commit/c71137377f - -commit 43ab2acf8242c580b1ef5d644ea94d48669d4869 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-16 08:51:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-09-16 08:54:20 +0900 - - Resurrect gem-specific patterns for sync - - Yet another partial revert of https://github.com/ruby/ruby/pull/8329, - similar to 00f263e6c4. - - Repro: On ruby/ruby@1be64e34d0, `tool/sync_default_gems.rb yarp - 162c2088eec6ec8f0558559e082cd661c18ee02a` should exit successfully, but - it doesn't without this gem-specific handling. - -commit cb686b9cccf571a70f4ac85bef0ebb2b544fba97 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-16 00:09:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 08:32:05 +0900 - - [ruby/yarp] Handle missing clauses in case statement - - https://github.com/ruby/yarp/commit/1ad7fba5ef - -commit 4c28a61e835645fefa238536acd6334451fb2dde - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-16 01:19:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 08:21:36 +0900 - - [ruby/yarp] Ensure multi targets are only in valid locations - - https://github.com/ruby/yarp/commit/8bffb8a762 - -commit 8db3e3c3d290459f593cbaa7de7d9c4ec365681a - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-15 06:04:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 08:08:27 +0900 - - [ruby/yarp] require constant pool capacity to be a power of 2 - - https://github.com/ruby/yarp/commit/dea8d3f29f - -commit 7cec7d14c33d0043b2c122aee5c88fc5ec884e8a - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-09-16 08:03:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-16 08:03:48 +0900 - - YJIT: Fix object movement bug in iseq guard for invokeblock - - Since the compile-time iseq used in the guard was not marked and updated - during compaction, a runtime value reusing the address could falsely pass - the guard. - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - -commit 1be64e34d0881e5c66be51a892bcd3a056e8f5f0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-16 01:30:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 07:59:48 +0900 - - [ruby/yarp] Alnum cannot be %-literal delimiters - - https://github.com/ruby/yarp/commit/4ba6d5ca70 - -commit 18780c22f657be2a0251fbf174fb46fd8523fae7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-15 23:40:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 07:38:58 +0900 - - [ruby/yarp] Properly handle invalid underscores in number literals - - https://github.com/ruby/yarp/commit/35da3d1a4c - -commit b848700ccfffc0d4c424daa10ca29e19106e8e3f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-16 07:29:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 07:36:22 +0900 - - [ruby/yarp] Extract test listener to its own class - - https://github.com/ruby/yarp/commit/c8caa997c0 - -commit 35960ce65e0300d897033f2ff15191bd60a2c53d - Author: Vinicius Stock <vinicius.stock@shopify.com> - AuthorDate: 2023-09-16 04:42:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 07:36:22 +0900 - - [ruby/yarp] Add node event dispatcher - - This commit changes the node template to create a dispatcher class, - which can be used to walk an AST an emit events to all registered - listeners - - https://github.com/ruby/yarp/commit/03a45f85e6 - - Co-authored-by: Kevin Newton <kddnewton@users.noreply.github.com> - -commit 89bd1ebcb9cb6befef659eb7056569413347f168 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-16 02:41:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 07:25:33 +0900 - - [ruby/yarp] Fix unexpected { after method call with args - - https://github.com/ruby/yarp/commit/fe279d2d16 - -commit c2f7dae31742ac09c4d12e332c6a9e7c2fda1782 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-16 00:52:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 07:24:50 +0900 - - [ruby/yarp] Handle unterminated interpolated symbol - - https://github.com/ruby/yarp/commit/9222faa1c6 - -commit d2c75bb9372cf4f2e63082ca493c9bdf74280c3d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-16 00:36:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 07:24:38 +0900 - - [ruby/yarp] Handle missing terminators in parenthesized expression - - https://github.com/ruby/yarp/commit/a8b54e8ed0 - -commit ffe77c022ca02717576b9d272c43baf8ec81083d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-16 00:13:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 07:24:25 +0900 - - [ruby/yarp] Handle infinite opt terms after missing case predicate - - https://github.com/ruby/yarp/commit/d931e258d1 - -commit bbf9f11ce610cad35e076e5c647815dd3e1a4949 - Author: Andy Waite <andyw8@users.noreply.github.com> - AuthorDate: 2023-09-16 04:01:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 07:22:24 +0900 - - [ruby/yarp] Fix behaviour of locations for comments - - https://github.com/ruby/yarp/commit/b1ced67fba - -commit 010017d86d5ba6403e3406cae5986348ed08a678 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-09-15 11:33:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 07:01:11 +0900 - - [rubygems/rubygems] Reduce array allocations and concatenations in Index - - Remove the default nested hash in Index entirely - Index#search_all now yields or returns enum since that's what caller - needs. - - https://github.com/rubygems/rubygems/commit/c45ea3bbe2 - -commit 2cf5fe58fbe8053f661552786a93d8cad7c307e0 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-15 11:14:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 07:01:10 +0900 - - [rubygems/rubygems] Avoid allocating empty hashes in Index - - Since the hashes have a default proc that returns a (new) empty hash, we - can avoid allocating those empty hashes when we are only doing lookups. - - Test from running `bundle update --bundler` against a rails app I have - lying around: - - ``` - ==> memprof.after.txt <== - Total allocated: 9.71 MB (68282 objects) - Total retained: 4.87 MB (33791 objects) - - ==> memprof.before.txt <== - Total allocated: 10.83 MB (100596 objects) - Total retained: 5.02 MB (34721 objects) - ``` - - https://github.com/rubygems/rubygems/commit/8f7c9cb23e - -commit 4e8869c663f82f5745070e3bce8902b800b1b6a7 - Author: Tim Morgan <tim@timmorgan.org> - AuthorDate: 2023-09-16 03:17:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 06:47:28 +0900 - - [ruby/yarp] Use templated constants for Regexp options - - https://github.com/ruby/yarp/commit/38e1769c2e - -commit 101ac364a54b10a24e2351c2138b59a819665540 - Author: Tim Morgan <tim@timmorgan.org> - AuthorDate: 2023-09-16 01:26:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 06:47:27 +0900 - - [ruby/yarp] Return Regexp options that match MRI for e, u, s, and n - - https://github.com/ruby/yarp/commit/17dbf4ec46 - -commit 0996cf5593b212314221a7c2a72b8a52ece35e94 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-09-16 05:15:15 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-09-16 05:15:15 +0900 - - YJIT: Fix and enable the unused_imports warning - -commit 4012ba4ecf781a75fb967c8210ad19049cc3f8cc - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-16 03:01:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 03:02:04 +0900 - - [ruby/yarp] Fix string delimiter with "@" confused for embedded - variable - (https://github.com/ruby/yarp/pull/1521) - - https://github.com/ruby/yarp/commit/3ec0699622 - -commit e50b7bf784b53ac126986dd7f9fd22ccc9b59c60 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-16 02:59:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-16 02:59:48 +0900 - - [DOC] Globals doc (#8445) - -commit c423d6e0e48bd8a94548ff7a6275d93ae770f9d1 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-09-15 11:34:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 02:54:01 +0900 - - [rubygems/rubygems] Stop allocating the same settings keys repeatedly - - Running `bundle update --bundler` on a rails app locally: - - ``` - ==> memprof.after.txt <== - Total allocated: 301.90 kB (3794 objects) - Total retained: 73.24 kB (698 objects) - - ==> memprof.before.txt <== - Total allocated: 14.47 MB (196378 objects) - Total retained: 25.93 kB (202 objects) - ``` - - So for a slight increase in retained memory (all keys are now retained), - we go from about 200k allocations in the settings file to under 4k - - https://github.com/rubygems/rubygems/commit/e64debb6ae - -commit 4d86d932fdbe91e436a5680ffae2f4db1a23b3be - Author: Adam Hess <adamhess1991@gmail.com> - AuthorDate: 2023-09-16 00:54:37 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-16 02:24:32 +0900 - - Free all heap pages at shutdown - - previously heap_allocated_pages was decremented from heap_page_free causing only half the heap pages to be freed at shutdown - -commit a1dc1a3de9683daf5a543d6f618e17aabfcb8708 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-09-12 06:11:46 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-09-16 01:01:02 +0900 - - Return line 0 for JIT frames - - Frames pushed by YJIT have an unreliable PC. The PC could be garbage, - and if we try to read the line number with a garbage PC, then the - program can crash. - - This commit returns line 0 for programs where there is a `jit_return` - function. If `jit_return` has been set then this frame was pushed by - the JIT, and we cannot trust the PC. - - Here is a debugger session for a program that crashed due to a broken - PC: - - ``` - (lldb) p ruby_current_vm_ptr->ractor.main_thread->ec->cfp->iseq->body->iseq_encoded - (VALUE *) $0 = 0x0000000118a30e00 - (lldb) p/x ruby_current_vm_ptr->ractor.main_thread->ec->cfp->pc - (const VALUE *) $1 = 0x0000600000b02d00 - (lldb) p/x ruby_current_vm_ptr->ractor.main_thread->ec->cfp->jit_return - (void *) $2 = 0x000000010622942c - ``` - - You can see the PC is completely out of range, but there is a - `jit_return` pointer so we can avoid this crash. - -commit efe2822708d62bfe3ba858da526e6ef7d4724959 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-09-15 23:22:09 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-09-16 00:45:21 +0900 - - Process.warmup: invoke `malloc_trim` if available - - Similar to releasing free GC pages, releasing free malloc pages - reduce the amount of page faults post fork. - -commit 28fe88468d7bde129221415bfa874f4b70bf6843 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-16 00:38:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 00:41:02 +0900 - - [ruby/yarp] Add more tests for implicit hash values - - https://github.com/ruby/yarp/commit/1ddd74dc11 - -commit 5f9f2fd72e7cf1794fe050fb34d1f4413d1c3fb9 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-13 22:39:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 00:41:02 +0900 - - [ruby/yarp] Add implicit nodes for ommitted hash values - - https://github.com/ruby/yarp/commit/22130b3491 - -commit 5a6eae0b0a42262834d423aca5dbbf094e9a5c2f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 04:26:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 00:14:40 +0900 - - [ruby/yarp] Keep value for invalid local variable write in tree - - https://github.com/ruby/yarp/commit/eaafc829db - -commit fab25082c2ef0c0586225d16ba75a52739a2ac3e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 00:52:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 00:14:38 +0900 - - [ruby/yarp] Ensure owned constants are marked as shared when overtaken - - https://github.com/ruby/yarp/commit/d73f7c9cfa - -commit b5084877c0cd0d3ae74760642cabda1b214d87d2 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 00:39:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 00:14:37 +0900 - - [ruby/yarp] Disallow numbered parameters in multiple scopes - - https://github.com/ruby/yarp/commit/5fd4d3b89a - -commit a4b4ebc7c1cfce912e5b8d2d30bcd9f24897bdc5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 00:21:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 00:14:36 +0900 - - [ruby/yarp] Error when numbered parameters are written - - https://github.com/ruby/yarp/commit/65b536ba12 - -commit 6031ab18c79c38ab53d91281a13bd59d5824e907 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 00:16:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 00:14:34 +0900 - - [ruby/yarp] Support parsing numbered parameters - - https://github.com/ruby/yarp/commit/ffc8f35e56 - -commit 236fe914af897b9310dff920e53b179c607e21a0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-13 23:23:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 00:14:33 +0900 - - [ruby/yarp] Track explicit parameters on blocks - - https://github.com/ruby/yarp/commit/99c91931e0 - -commit 1badb09f615b4cb79ca7cc5ebb4736b7b5cccb7e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-15 22:07:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-16 00:14:19 +0900 - - [ruby/yarp] Properly handle missing method names - - https://github.com/ruby/yarp/commit/4a30c69051 - -commit 89802078f9f406be411032814e1960e62dbc7ce2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-15 15:39:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-15 17:27:36 +0900 - - [Bug #19882] Reject tokens invalid as symbols - -commit fe0225ff4d5af8b1f54009727b39d0d9b821eea3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-15 12:08:25 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-15 13:27:19 +0900 - - [Bug #19778] Add `-I` options for opt-dir to `$INCFLAGS` - - These options have been separated from `$CFLAGS` already in the - other places. - -commit 0117a6d389c5b607eaec1b7f917132efa356f665 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-09-15 10:33:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-15 10:33:32 +0900 - - Fix Thread#native_thread_id being cached across fork (#8418) - - The native thread ID can and does change on some operating systems (e.g. - Linux) after forking, so it needs to be re-queried. - - [Bug #19873] - - Notes: - Merged-By: nurse <naruse@airemix.jp> - -commit f08cac066e3d327f2925607d7a33c8e9738aa4ee - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-09-15 04:48:53 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-09-15 08:15:53 +0900 - - Don't call malloc with 0 - - It seems not-uncommon for methods to have no IV, ISE, or ICVARC caches. - Calling malloc with 0 will actually allocate something, so if there - aren't any caches (`ISEQ_IS_SIZE(body) == 0`), then we can avoid - allocating memory by not calling malloc. If there are no caches, then - theoretically nobody should be reading from the buffer anyway. - - This saves about 1MB on Lobsters benchmark. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8442 - -commit 982d6503b9715d8b2fe07ab6b94b08601a34426d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-15 07:49:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-15 07:49:40 +0900 - - YJIT: Skip Insn::Comment and format! if disasm is disabled (#8441) - - * YJIT: Skip Insn::Comment and format! - - if disasm is disabled - - Co-authored-by: Alan Wu <alansi.xingwu@shopify.com> - - * YJIT: Get rid of asm.comment - - --------- - - Co-authored-by: Alan Wu <alansi.xingwu@shopify.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 07b615bb3b55d1ab6548d1abf77aa8bc25bbb3e1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-15 07:02:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-09-15 07:02:12 +0900 - - Skip renaming OpenSSL DLLs - - to fix CI failures like: - https://github.com/ruby/ruby/actions/runs/6190995187/job/16808382442 - -commit 1961c5bb767a451928dc719d37c2b38f89d248c6 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-09-15 06:18:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-15 06:18:45 +0900 - - YJIT: Plug native stack overflow - - Previously, TestStack#test_machine_stack_size failed pretty consistently - on ARM64 macOS, with Rust code and part of the interpreter used for - per-instruction fallback (rb_vm_invokeblock() and friends) touching the - stack guard page and crashing with SEGV. I've also seen the same test - fail on x64 Linux, though with a different symptom. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8443 - - Merged-By: XrXr - -commit 66ffa15ce01e1b8d46738032e714be18194af3ca - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-09-13 10:54:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 04:43:21 +0900 - - [rubygems/rubygems] Gemfile ruby file: covers more version formats - - Increase test coverage and be explicit about what is and is not supported. - - https://github.com/rubygems/rubygems/commit/a096397a00 - -commit 0d33bc0cde5b9eca805cec1133e2c48ebdea5c84 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-12 04:26:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 04:16:39 +0900 - - [ruby/yarp] Simplify multi-target parsing - - This simplifies how we handle multi-targets, and also fixes a bug we - had where for loops were always getting multi-targets, even when there - was only a single target. - - https://github.com/ruby/yarp/commit/31eb8b7ad5 - -commit 0a8f3670d1c1aa4ec58a08642cccf5ee5dbf95ae - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 22:01:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 04:10:58 +0900 - - [ruby/yarp] Introduce MatchWriteNode - - This rarely used node holds information about the local variables - that need to get written in the case a regular expression is used on - the left-hand side of a =~ operator and it has named capture groups. - - Note that we already "handled" these nodes by adding locals to the - AST, but we didn't actually expose this information, making it - difficult to compile. - - The general idea behind this node is that it maintains the ability - for consumers to find all of the call nodes in the tree easily so - it's not flattening down. However, it should be okay because you - hopefully don't need any information in the call node to determine - what to compile because the locals list is on the top level. - - https://github.com/ruby/yarp/commit/e136e7f9a8 - -commit 9d2549ac311f98288bd42c4a8054cba46ca8ce32 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-15 01:09:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 04:10:47 +0900 - - [ruby/yarp] Write names should not underflow size_t - - If the read_name is invalid, we shouldn't try to set a write name. - - https://github.com/ruby/yarp/commit/06881c8ca7 - -commit 63d1e056650293bb77f9a5c11600013afa801bba - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-15 01:01:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 03:32:16 +0900 - - [ruby/yarp] Handle errors when operator writes on a call with a block - - https://github.com/ruby/yarp/commit/93bec2c173 - -commit fb1328e4676da4dfc174ccadc57899e2eac96a63 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-15 00:19:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 03:31:55 +0900 - - [ruby/yarp] Fix multi target parentheses locations - - https://github.com/ruby/yarp/commit/7f71527522 - -commit b098c4247b91b2ba6e3a6d872325d2812f7b5c5f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 04:07:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 03:31:43 +0900 - - [ruby/yarp] Remove deprecated aliases - - https://github.com/ruby/yarp/commit/db28e22363 - -commit de2fe8631cb17be78b7bafc2b31ec80a95f8a6ae - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 22:57:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 03:30:11 +0900 - - [ruby/yarp] Extract out parse_write_name - - https://github.com/ruby/yarp/commit/0d3e8cdcd7 - -commit 826bebb7d89928690334b632ef54d5c0edf73189 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 04:06:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 03:30:11 +0900 - - [ruby/yarp] Reject invalid call-operator-write - - https://github.com/ruby/yarp/commit/d3a852dac2 - -commit 7f6cf2d283621fc10994b377037522e1146645c6 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-13 23:10:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 03:28:46 +0900 - - [ruby/yarp] Use bytes instead of bit fields - - https://github.com/ruby/yarp/commit/890fa72fdd - -commit 581bda0cbafabb381b100302bb1c4179651121c9 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-13 02:06:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 03:28:45 +0900 - - [ruby/yarp] Add a frozen string flag - - https://github.com/ruby/yarp/commit/09248a1f9e - -commit 282e4388ed7a79cd39795a2e71875745f07557de - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-13 01:02:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 03:28:45 +0900 - - [ruby/yarp] Introduce a flag for a static literal check - - https://github.com/ruby/yarp/commit/c61658c0fd - -commit 500f38e06f6da1f309c9ac2d7835c07b615e3d48 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-13 01:53:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 03:28:44 +0900 - - [ruby/yarp] Parse frozen string literal comment - - https://github.com/ruby/yarp/commit/373898e7cb - -commit 122f3d64bedecf7fd49c984e4dc5fdbe4dae5a4e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-13 01:31:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 03:28:44 +0900 - - [ruby/yarp] Move booleans on the parser to the end so they are more compact - - https://github.com/ruby/yarp/commit/21a43034d0 - -commit 533c4072a9e4cc30c744a2ca0f0ce034d589482f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-15 03:16:21 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-15 03:16:21 +0900 - - [YARP] Fix up alias and true node (#8423) - - * [YARP] Use ALIAS_METHOD as opposed to ALIAS - - * [YARP] Use YP_TRUE_NODE instead of YP_NODE_TRUE_NODE - - Notes: - Merged-By: jemmaissroff - -commit fcc16991623653e72298b97ea0d5000ce6aa31c7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-15 02:55:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-15 02:55:00 +0900 - - YJIT: Initialize Vec with capacity for iterators (#8439) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 9cb33aad55e0a2cded3b09b0509b9c53fb0fa5ae - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-13 23:33:19 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-15 01:09:07 +0900 - - [Bug #19877] Fix flip-flop in block - - Notes: - Merged: https://github.com/ruby/ruby/pull/8440 - -commit 864bb8680cee48a2bed85703dc2e4070728362d4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-13 22:09:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-15 01:09:06 +0900 - - [Bug #19877] Named captures should take place from regexps in block - - Notes: - Merged: https://github.com/ruby/ruby/pull/8440 - -commit e8896a31d48e5797df3878696dcb50aed85b87c2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-13 21:55:12 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-15 01:09:06 +0900 - - [Bug #19877] Literals cannot have singleton methods even in blocks - - Notes: - Merged: https://github.com/ruby/ruby/pull/8440 - -commit 3f492921c8b7c787b150445e4f28691d9a886dcc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-13 21:22:52 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-15 01:09:06 +0900 - - Reuse `rb_reg_named_capture_assign_iter_impl` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8440 - -commit 6df0927be27ef4060d8ba33ca1e6918ddd7cf55b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 21:35:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-15 00:11:32 +0900 - - [ruby/yarp] Remove varargs entirely - - Following up on #1483, this removes our usage of varargs entirely. - Under the new approach we make explicit methods for the various - signatures. Because we know the type of everything any it's very - consistent, this makes it easier for compilers to inline. - - Also, I renamed the functions to be more consistent with each other - so that we'll have some more internal consistency. - - https://github.com/ruby/yarp/commit/87af9ba29b - -commit cdc69da9e5556375583730743a55c7ab7985e953 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-14 23:10:31 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-14 23:10:31 +0900 - - YJIT: Initialize Assembler vectors with capacity (#8437) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 1b6d2b91843cdd07d5dbc8cfd6354a83f06daf8c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-13 22:07:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-14 22:58:33 +0900 - - [ruby/yarp] Fix up unary minus precedence - - https://github.com/ruby/yarp/commit/6be28eeed0 - -commit 174aa53656b689277ab01bebd5d293dc0532f958 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 10:06:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-14 22:58:13 +0900 - - [ruby/yarp] Handle concat character literal and string - - https://github.com/ruby/yarp/commit/fb141b8d07 - -commit 57745450dd85567cbdce703f12c9825fd81e52a2 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 10:02:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-14 22:58:12 +0900 - - [ruby/yarp] Extract out heredoc parsing into parse_strings - - https://github.com/ruby/yarp/commit/c5a1094988 - -commit 72d008d88d32fe3eb3f7033d93c90a00cb7d7c61 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 04:39:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-14 22:58:12 +0900 - - [ruby/yarp] Extract out parse_strings - - https://github.com/ruby/yarp/commit/55446f7a43 - -commit b85bb90c3464bca8d19b73247ace809b44f35679 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-14 22:43:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-14 22:43:55 +0900 - - [DOC] Sort "Core classes updates" section - - Alphabetically by class or module names. - -commit 9a1c5a1268a7f50917ab9782b0315fc2244d6dcc - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-14 03:32:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-14 22:39:06 +0900 - - [ruby/yarp] Handle invalid operator write on fcall - - https://github.com/ruby/yarp/commit/22c800eab1 - -commit c95f344798226ec3378e0bd53d2f0a57d027155b - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-14 10:24:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-14 21:17:06 +0900 - - [ruby/yarp] get rid of `accept_any_p` and just use regular functions - - https://github.com/ruby/yarp/commit/4512daf769 - -commit a921d4be4367dc2af8818204ad4dee793265d3c7 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-14 10:24:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-14 21:17:06 +0900 - - [ruby/yarp] don't use varargs for common cases of `match_any_type_p` - - https://github.com/ruby/yarp/commit/79794b4833 - -commit 990234015c447876dbfde0a6994259342f57add9 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-14 09:36:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-14 21:17:05 +0900 - - [ruby/yarp] add some `const` qualifiers - - https://github.com/ruby/yarp/commit/e807462c6d - -commit a095740fed2a05a04806a1d3827bcaba02e45720 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-09-14 17:37:43 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-14 17:37:43 +0900 - - Fix `io_buffer_get_string` default length computation. (#8427) - - * Fix `io_buffer_get_string` default length computation. - - When an offset bigger than the size is given, the resulting length will be - computed incorrectly. Raise an argument error in this case. - - * Validate all arguments. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 998ae7c3f36b65f04471cd680b4c7ac78b3d9f30 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-14 15:19:15 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-14 15:26:25 +0900 - - [Bug #19868] Deprecate `Process::Status#&` and `Process::Status#>>` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8392 - -commit b6de0a6c69a4857ca4347f65d7c9a5cb6e52c5bd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-07 11:47:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-14 14:57:57 +0900 - - [Bug #19868] Suggest other Process::Status method for `&` and `>>` - - `Process::Status#&` and `Process::Status#>>` are provided only for - the backward compatibility with older Ruby than 1.8 where `$?` was - a `Fixnum`, and the knowledge about internals of system dependent - macros is necessary to use them. Modern programs and libraries - should not need these methods. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8392 - -commit efe5e6e8d05d607dde38ece66e035b8e746e65fb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-07 11:33:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-14 14:38:14 +0900 - - Negative value to Process::Status method for compatibility - - Notes: - Merged: https://github.com/ruby/ruby/pull/8392 - -commit e50fcca9a79d8e25b33ad3611df6bf4627faafbf - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-14 09:24:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-14 10:09:33 +0900 - - [ruby/yarp] make some encoding tables `const` - - https://github.com/ruby/yarp/commit/777c376deb - -commit f644996f2e6d41e9c3d2aeda326bb81d1bdf32d0 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-09-14 07:16:37 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-09-14 08:42:51 +0900 - - For YJIT Actions, don't filter test-spec backtraces - - I'm trying to debug a flaky `RuntimeError: nested #it` failure in - ruby/spec. Hopefully the full backtrace will give some clues. - - Last occurence: - https://github.com/ruby/ruby/actions/runs/6172578817/job/16753137038 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8436 - -commit 3d453bc672863e437c47caab47d0db5aab6e8629 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-14 04:55:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-14 06:26:44 +0900 - - [ruby/yarp] free strings in the ruby extension - - https://github.com/ruby/yarp/commit/87dbb6cf1f - -commit b49be2a70fd715b15f69dae776ba37d9b8d3a3fb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-14 05:44:23 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-14 05:44:23 +0900 - - YJIT: Skip adding past_page_bytes for past pages (#8433) - - YJIT: Skip adding past_pages_bytes for past pages - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 7f6c0efac7a8193dbc39ffb396651a94e04e43da - Author: Herwin <herwinw@users.noreply.github.com> - AuthorDate: 2023-09-14 00:06:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-14 02:37:12 +0900 - - Fix hyperlink for Script Encoding - - Notes: - Merged: https://github.com/ruby/ruby/pull/8432 - -commit ff329ce428c0de4d4c257bd4c10e46edb8863d02 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-13 23:48:14 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-13 23:48:14 +0900 - - YJIT: Make yjit_alloc_size available by default (#8426) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 721d21d30195f57b212e518ebf475a8c913955e0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-13 23:45:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-13 23:45:40 +0900 - - YJIT: Make compile_time_ns a default counter (#8425) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 90838a949053d7f240ddab2067b1dde8cca2ae7b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-13 09:48:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-13 22:50:13 +0900 - - [ruby/yarp] Fix associativity for a couple of operators - - https://github.com/ruby/yarp/commit/820774976d - -commit f9898b9ecab9851f32e1b3aad1176c801150f975 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-13 22:14:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-13 22:40:46 +0900 - - [ruby/yarp] Better handle invalid gvar writes - - https://github.com/ruby/yarp/commit/eaaebc17c8 - -commit ea75a682a9adfac1723308a1c032b7d9b68ffcb6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-13 11:48:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-13 21:48:39 +0900 - - [ruby/yarp] Mark empty flags as well as locations and blocks - - https://github.com/ruby/yarp/commit/b74ce35379 - -commit a0e66873053c2ce57a493294584da48ae600cafd - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-09-13 19:21:52 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-09-13 21:40:05 +0900 - - Use log2(b) instead of (log(b) / M_LN2) - - Co-Authored-By: Nobuyoshi Nakada <nobu@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/8429 - -commit 411572661a3995a0daacb6c866ea3ac6b52ad25b - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-09-13 18:56:24 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-09-13 21:40:05 +0900 - - math.c: Fix Math.log against huge bignum [Bug #19878] - - Notes: - Merged: https://github.com/ruby/ruby/pull/8429 - -commit 4655d2108ef14e66f64496f9029f65ba2302d9ea - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-13 13:06:03 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-13 18:03:49 +0900 - - Lrama v0.5.6 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8428 - -commit c75d54a36ca94ec25b5eb31925a0414f998df78c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-09-13 16:23:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-13 16:23:18 +0900 - - Fixup 1851824b1c7b816e41b567b5310bb18ab6f9ff7a - -commit 1851824b1c7b816e41b567b5310bb18ab6f9ff7a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-09-13 15:30:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-13 16:01:19 +0900 - - [flori/json] alias_method is private on Ruby 2.3 and 2.4 - - https://github.com/flori/json/commit/573ef94bc5 - -commit e22086bb6a5cee678f268ac2c30b9d19b55802d4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-13 12:11:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-13 12:11:43 +0900 - - Enable `.NOTPARALLEL` on `ripper_srcs` - - And add special treats only for old GNU make. - -commit 234722ed9fce33d7ec8152920636af663d527912 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-13 00:44:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-13 10:43:10 +0900 - - [Bug #19872] Refine TestRequireLib - - Always test only the scripts just under “lib", and just under - child directories which has not the same name script in the upper - level; instead of random sampling from whole libraries. - -commit 435b243978995237f7d4c386bb312d8cdae8b50b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-13 10:24:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-13 10:24:55 +0900 - - Suppress an unused variable warning - -commit c421f08f6b5c1cc9a52e713a81595a393ff66e8c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-11 02:47:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-13 09:55:04 +0900 - - [ruby/yarp] Handle parsing local variable singleton method definition - - https://github.com/ruby/yarp/commit/943204d56f - -commit 6e64d4370456190541705ec4c6cf3af6bf4ac647 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-06 00:44:35 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-13 08:30:37 +0900 - - [Bug #19862] Skip compiled result of never reachable expression - - Notes: - Merged: https://github.com/ruby/ruby/pull/8381 - -commit 19346c2336053b351673da030b00c704138252d8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-13 06:45:26 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-13 06:45:26 +0900 - - [Bug #19754] Make `IO::Buffer#get_string` check `offset` range (#8016) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 11c32e33ebe00e746579edc3f1358fdb4fe8cf85 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-09-13 05:25:29 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-09-13 05:33:18 +0900 - - Adjust CGI spec to pass when ran in isolation - - It failed with `NameError` because `Html3` is defined in the file that - `CGI::HtmlExtension` autoloads. - -commit 5edabd1cd57ea9a5c9fa9b782aa8df3da8781040 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-13 05:31:31 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-13 05:31:31 +0900 - - [DOC] RDoc for Process::Status (#8416) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit d43765c3a9d006599895538be12b5b45c1873085 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-09-02 07:47:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-13 04:42:46 +0900 - - [rubygems/rubygems] Unify LockfileParser loading of SPECS section - - Ensure unrecognized SPECS types are ignored - - https://github.com/rubygems/rubygems/commit/5b33e91075 - -commit 0ae7f2d1ac354cd92d513f934aede0cabd6dbc9f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-13 02:52:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-13 02:52:40 +0900 - - YJIT: Add compilation time counter (#8417) - - * YJIT: Add compilation time counter - - * YJIT: Use Instant instead - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit a98209b8a70345714ac5f3028e0591f3ee50bba7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-12 00:52:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-13 00:44:25 +0900 - - [ruby/yarp] Split AliasNode - - Into AliasGlobalVariableNode and AliasMethodNode. These have different - enough semantics that we feel comfortable splitting them up. - - https://github.com/ruby/yarp/commit/c1f3e6d344 - -commit 39ee3e22bd3d071c1c283b6b8dbd1af413342fb1 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-09-08 03:56:07 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-09-13 00:25:07 +0900 - - Make Kernel#lambda raise when given non-literal block - - Previously, Kernel#lambda returned a non-lambda proc when given a - non-literal block and issued a warning under the `:deprecated` category. - With this change, Kernel#lambda will always return a lambda proc, if it - returns without raising. - - Due to interactions with block passing optimizations, we previously had - two separate code paths for detecting whether Kernel#lambda got a - literal block. This change allows us to remove one path, the hack done - with rb_control_frame_t::block_code introduced in 85a337f for supporting - situations where Kernel#lambda returned a non-lambda proc. - - [Feature #19777] - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/8405 - -commit b90272b3b661bd2fd557332028b8feb568b6b9df - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-13 00:20:22 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-13 00:20:22 +0900 - - Fix typo in gc.c - -commit 385033ba0fe221097637943936973d0e9bd235a9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-21 17:25:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-12 23:28:48 +0900 - - Ensure signaled processes at opening FIFO terminated - - Notes: - Merged: https://github.com/ruby/ruby/pull/8421 - -commit 39336c1ab897cee3b9069d8650a1e2ace23d128f - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-12 22:39:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-12 22:39:24 +0900 - - [ruby/yarp] Heredocs can create Interpolated(X)StringNodes or - (X)StringNodes - (https://github.com/ruby/yarp/pull/1427) - - Prior to this commit, heredocs were automatically InterpolatedNodes - regardless of whether there was actually interpolation. With this - commit, heredocs are only interpolate if there is actually - interpolation - - https://github.com/ruby/yarp/commit/e9f436128b - -commit b55785579cf114acbb0d9809b9e429d31b7aa8f3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-12 19:23:00 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-12 22:02:48 +0900 - - Restore `in_defined` flag at nested `defined?` - -commit fe3eff08ee404dfae92f36138adb2dd51df99eb5 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-09-12 19:36:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-12 21:11:40 +0900 - - [ruby/yarp] Move the post required parameters after the rest parameter - - * See https://github.com/ruby/yarp/issues/1436 - - https://github.com/ruby/yarp/commit/6f4e9ff940 - -commit f1c78b23313e63eb31a213cc7277b1eb206a581b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-09-12 13:33:22 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-12 15:10:16 +0900 - - Suppress warning for shadowing outer local variable - - Notes: - Merged: https://github.com/ruby/ruby/pull/8419 - -commit 8953fc774c542a8bf3c9a2be39bcbd1d5341e3a8 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-12 01:05:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-12 06:49:51 +0900 - - [ruby/yarp] Provide a flag for the integer base - - https://github.com/ruby/yarp/commit/45dd046b83 - -commit b7ffa74d583100bb41b43bfdc8d883aea2e1fcad - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-12 01:32:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-12 06:42:03 +0900 - - [ruby/yarp] Introduce MatchLastLineNode and InterpolatedMatchLastLineNode - - These are replacements for regular expressions when they are used - alone as the predicate of a conditional. That's because they are - significantly different from a regular expression because they are - not evaluated for truthyness, but instead evaluated as a match - against the last line read by an IO object. - - https://github.com/ruby/yarp/commit/0f1c7780e8 - -commit aa69bd841aa5c35429e0dc08f5955a0dbd9176e5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-12 03:36:09 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-12 06:40:36 +0900 - - Use constant lookup for constant names - - Notes: - Merged: https://github.com/ruby/ruby/pull/8413 - -commit bfc82fe1d309263fcff91a515fd623ae987af95a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-12 03:26:21 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-12 06:40:36 +0900 - - Remove deprecated aliases from yarp compiler - - Notes: - Merged: https://github.com/ruby/ruby/pull/8413 - -commit 14a83e0879b8001c180576ff3a211a74288e3b40 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-12 04:33:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-12 06:32:15 +0900 - - [ruby/yarp] Update pretty_print to use inspect - - https://github.com/ruby/yarp/commit/c2b9b780c7 - -commit 203fdd738b0488206c03db9a7a307c170711b5ba - Author: negi0109 <negi0109.seg@gmail.com> - AuthorDate: 2023-09-12 04:13:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-12 06:06:22 +0900 - - [rubygems/rubygems] Fixed include realpath in error statement - - https://github.com/rubygems/rubygems/commit/ac3b85bd5e - -commit 8bb61077ad02c2b57eb5727b7da8a7a4fff28ef3 - Author: negi0109 <negi0109.seg@gmail.com> - AuthorDate: 2023-09-11 02:01:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-12 06:06:21 +0900 - - [rubygems/rubygems] Fixed false positive SymlinkError in symbolic link directory - - https://github.com/rubygems/rubygems/commit/58173ff2ea - -commit 1ae5dd6f320da502e1b4a032ed9c17e03a9f344f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-12 02:09:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-12 02:09:22 +0900 - - Rename `NODE_NEW_TEMPORAL` as `NODE_NEW_INTERNAL` - -commit 719f83446613f1e18f1a38cff0e00e7be88bbe14 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-12 00:31:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-12 01:18:32 +0900 - - [ruby/yarp] Mark flags as private - - The flags integer is an implementation detail. We want people to - use the query methods to access the individual fields so we are - freed from having to maintain a specific order. As such, this - commit changes the Ruby API to mark all flags fields as private - attr_readers. - - The only one that has a clear use case is returning the set of - options given to regular expressions, to mirror the Regexp#options - API. So, to support this use case, this commit introduces - RegularExpressionNode#options and InterpolatedRegularExpressionNode#options. - These APIs provide back the same integer so that they can be used - interchangeably. - - https://github.com/ruby/yarp/commit/4e6d5dd99f - -commit 05a853c2f21f60f9e1c544c2d0709f10de453571 - Author: Tim Morgan <tim@timmorgan.org> - AuthorDate: 2023-09-11 20:13:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-12 00:25:06 +0900 - - [ruby/yarp] Update fixtures - - https://github.com/ruby/yarp/commit/884f2ca8e4 - -commit 5a8767ed6c26a02ba8aecb6205cfad6cb991bc46 - Author: Tim Morgan <tim@timmorgan.org> - AuthorDate: 2023-09-11 20:01:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-12 00:25:06 +0900 - - [ruby/yarp] Fix order of Regexp flags - - https://github.com/ruby/yarp/commit/e421305ea2 - -commit 689dffc8576215239ae3c38633b3f2257208fc70 - Author: Tim Morgan <tim@timmorgan.org> - AuthorDate: 2023-09-11 20:13:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-12 00:25:05 +0900 - - [ruby/yarp] Add failing test for Regexp flags - - https://github.com/ruby/yarp/commit/16fe179c5f - -commit 05046b89550ad0cdeafc0e419e0eb4a155cc52fa - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-11 11:06:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-11 11:06:49 +0900 - - Add `modencs` target to build encodings/transcoders as modules - -commit 2cc32ad67c04eb58cb3035c7ef779f441d29e7d9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-11 11:04:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-11 11:04:33 +0900 - - Split commit recipe and pass more macros - -commit b8d0ab80bb4890cc81353f9231b4838d024eaa25 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-10 21:37:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-10 21:37:44 +0900 - - Declare `k_class` and `k_module` as `ctxt` - - So that it is not ncessary to specify the type each time. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8410 - -commit b5914a72a9134b3ccdbf2dd4416040b35934d182 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-08 09:17:09 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-10 19:45:33 +0900 - - Refactor to use same logic with other assignment nodes - - Notes: - Merged: https://github.com/ruby/ruby/pull/8400 - -commit 0e49f8173a854bfa826c7b772d6fd990f6c75d0c - Author: kudojp <heyjudejudejude1968@gmail.com> - AuthorDate: 2023-09-09 15:50:21 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-10 19:39:28 +0900 - - [DOC] Fix method docs of scheduler#io_read and scheduler#io_write - - Each of Fiber::Scheduler#io_read and io_write takes the "offset" as the fourth argument, which is not doucmented. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8407 - -commit b926ac51ccce215674dd945735a5162ef7d5be8a - Author: Herwin <herwinw@herwinw.nl> - AuthorDate: 2023-09-10 19:33:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-10 19:33:48 +0900 - - [DOC] Fix a typo in "Open Options" section of IO - - The word "and" was missing. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8409 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit b635a66e957e4dd3fed83ef1d72ce8c9b57e0430 - Author: Stan Lo <stan.lo@shopify.com> - AuthorDate: 2023-09-09 08:08:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-09 08:08:32 +0900 - - [DOC] Update Reline and IRB's maintainers list (#8406) - - Update Reline and IRB's maintainers list - - Maintainers' order follows the same order they appear in the projects' - contributors list as of the time this commit is made. - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 90dad2b12849b9151f62b1f3a9ac6090aadc8cc8 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-09-06 13:59:29 +0900 - Commit: Sutou Kouhei <kou@clear-code.com> - CommitDate: 2023-09-09 07:30:04 +0900 - - memory_view: Avoid using bit field - - Bit field's memory layout is implementation-defined. - - See also: - https://wiki.sei.cmu.edu/confluence/display/c/EXP11-C.+Do+not+make+assumptions+regarding+the+layout+of+structures+with+bit-fields - - If memory layout is implementation-defined, it's difficult to use from - FFI library such as Ruby-FFI. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8380 - -commit d9ede18154e125453bc6399463c58603b9a576a8 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-09 05:33:05 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-09 05:33:05 +0900 - - [YARP] Extract YP_COMPILE helper (#8403) - - Notes: - Merged-By: jemmaissroff - -commit f4443f3b1c6dd70b6b22470a7d5f8796175aace3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-09 04:46:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-09 04:50:47 +0900 - - [ruby/yarp] Increment version - - https://github.com/ruby/yarp/commit/2b41ceb754 - -commit c0f162caab6098b1709cce893c2c86fec88d0d4c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-09 03:33:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-09 04:38:17 +0900 - - [ruby/yarp] Template out a comment_targets method - - https://github.com/ruby/yarp/commit/a94af7c4c8 - -commit 5d73c0f3dfa489ec3380b997dd151a07e790562a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-09 03:27:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-09 04:38:17 +0900 - - [ruby/yarp] Move parse result mutations into their own files - - https://github.com/ruby/yarp/commit/3be8272fa2 - -commit 7fc4db35ee41944812011e04226609a1e5580091 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-09 04:33:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-09 04:33:51 +0900 - - [YARP] Implement compilation for RationalNodes, fix other num types (#8404) - - Notes: - Merged-By: jemmaissroff - -commit 6050b5a4e860b05f6b5e553d5883330a908079f9 - Author: Vinicius Stock <vinicius.stock@shopify.com> - AuthorDate: 2023-09-08 02:44:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-09 03:10:26 +0900 - - [ruby/yarp] Add ParseResult#attach_comments! to tie comments to their locations - - https://github.com/ruby/yarp/commit/ddc699156f - - Co-authored-by: Kevin Newton <kddnewton@users.noreply.github.com> - -commit 7f53da94fb23687ef3bea0507199196a00ca26f8 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-09-08 22:31:29 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-09 01:45:00 +0900 - - Fix weak_references count test - - This test creates a lot of Objects held in an array, and a set of weak - references to them using WeakMap. It then clears the array and frees it - and asserts that all the weak references to it are also gone. - - This test is failing because one of the dummy objects in our weakmap is - ending up on the stack, and so is being marked, even though we thought - that we'd removed the only reference to it. - - This behaviour has changed since this commit: - - https://github.com/ruby/ruby/commit/5b5ae3d9e064e17e2a7d8d21d739fcc62ae1075c - - which rewrites `Integer#times` from C into Ruby. This change is somehow - causing the last object we append to our array to consistently end up on - the stack during GC. - - This commit fixes the specific weakmap test by using an enumerator and - each, instead of `Integer#times`, and thus avoids having our last object - created end up on the stack. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8402 - -commit 60ef156b1463629d94cf7139430d129dd68a418f - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-09-09 01:30:55 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-09-09 01:33:58 +0900 - - [DOC] Kernel#{proc,lambda} don't issue warnings anymore - - They've been raising since 3.0.0. - -commit af5df9ee5ea6ad6270be020f74f9fb208e2bfb57 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-09 01:09:30 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-09 01:09:30 +0900 - - [YARP] Implement compilation for Regex / InterpolatedRegex (#8396) - - Notes: - Merged-By: jemmaissroff - -commit 8807b0dc96cbb0d0b72cddae2f41dd163589b7cc - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-08 23:40:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-08 23:40:07 +0900 - - [YARP] Implement compilation for InterpolatedXStringNode (#8395) - - * [YARP] Implemented compilation for InterpolatedXStringNode - - * Extract common function for interpolated nodes - - Notes: - Merged-By: jemmaissroff - -commit c7d61181d068b3471386749b6899dc7d3005273c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-08 03:20:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-08 22:40:28 +0900 - - [ruby/yarp] Flatten multitarget into multiwrite - - https://github.com/ruby/yarp/commit/1021dac372 - -commit f39b576e76b493b3fc5a9280295855fd8c9fb480 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-08 02:00:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-08 22:40:28 +0900 - - [ruby/yarp] Multi target nodes - - https://github.com/ruby/yarp/commit/fa53fe88e4 - -commit be21a056d229652ae5cf6926e96c1517aa43453f - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-09-08 17:44:46 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-08 17:44:46 +0900 - - Try default `gcc` 9.4.0 to see if it exhibits the same compiler bugs. (#8394) - - * Revert "Extract `do_mutex_lock_check_interrupts` to try and fix `ppc64le`. (#8393)" - - This reverts commit 5184b40dd4dc446660cd35c3e53896324e95b317. - - * .travis.yml: Try default gcc 9.4.0 instead of gcc-10 in ppc64le and s390x. - - Use gcc 9.4.0 instead of gcc-10 to avoid the current failures by a possible GCC - 10 compiler bug in the Travis ppc64le and s390x cases. And it also aligns with - RubyCI Ubuntu ppc64le and s390x where the default gcc is used. - - --------- - - Co-authored-by: Jun Aruga <jaruga@ruby-lang.org> - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit b6df6f911c6745a1e57a1d5dd7bc1c22a57722a8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-08 12:22:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-08 12:22:55 +0900 - - Continue even if addr or rnglists headers not found - - Fix up commit 31d1226, "Avoid aborting inside addr2line.c". - Source code informations did not appear in C level backtrace since - that change. - -commit 78233e83529d7e3aee030cc6760f45104247fe51 - Author: Ian Candy <ipc103@github.com> - AuthorDate: 2023-09-08 12:15:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-08 12:15:24 +0900 - - Add `String#getbyte` YJIT implementation (#8397) - - * Add getbyte JIT implementation - - Adds an implementation for String#getbyte for YJIT, along with a - bootstrap test. This should be helpful for pure Ruby implementations - and to avoid unneeded allocations. - - Co-authored-by: John Hawthorn <jhawthorn@github.com> - - * Skip the getbyte test for RJIT for now - - --------- - - Co-authored-by: John Hawthorn <jhawthorn@github.com> - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 89edce432115c1bb46b2de0f4cd1e50c6e02ec41 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-08 12:15:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-08 12:15:08 +0900 - - YJIT: Decrease IVAR_MAX_DEPTH to 8 (#8398) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 094f336a274ce83bc9868c7f9be0962b54ec46a7 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-09-04 09:02:57 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-09-08 05:51:56 +0900 - - GC: Only force alloc slowpath for NEWOBJ hook - - Previously, configuring any GC event hook would cause all allocations to - go through the newobj slowpath. We should only need to do that when the - newobj specifically is subscribed to. - - This renames flags.has_hook to flags.has_newobj_hook, to make this new - usage clear. newobj_of0 was the only place which previously checked this - flag. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8378 - -commit aed52151043561dbe9657abd07f1abfcd97df817 - Author: Matthew Draper <matthew@trebex.net> - AuthorDate: 2023-08-24 17:23:23 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-09-08 05:51:15 +0900 - - Optimize handle_interrupt(Exception => ..) as a common case - - When interrupt behavior is configured for all possible exceptions using - 'Exception', there's no need to iterate the pending exception's - ancestors for hash lookups. - - More significantly, by storing the catch-all timing symbol directly in - the mask stack, we can skip allocating the hash we would otherwise need. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8278 - -commit ed712e0e9d591bdaa84e9eaac832a9632aee5139 - Author: Matthew Draper <matthew@trebex.net> - AuthorDate: 2023-08-24 15:57:17 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-09-08 05:51:15 +0900 - - Skip allocation if handle_interrupt arg is already usable - - If the supplied hash is already frozen and compare-by-identity, we can - use it directly (still checking its contents are valid symbols), without - making a new copy. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8278 - -commit fcdedf7f47b0ec495a0e3adca4c3f44b84afa98e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-08 03:22:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-08 03:22:34 +0900 - - YJIT: Decrease SEND_MAX_DEPTH to 5 (#8390) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 60a52caf87c7e9ddfca73120c9d5b5030793ed77 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-09-08 02:07:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-08 03:13:51 +0900 - - [ruby/yarp] Avoid an extra "stop" parameter to yp_strspn_whitespace_newlines - - and use yp_strspn_inline_whitespace instead. - - Partially reverts implementation details from #1152 - - https://github.com/ruby/yarp/commit/c8f9f4cfde - -commit 5b5ae3d9e064e17e2a7d8d21d739fcc62ae1075c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-08 02:57:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-08 02:57:52 +0900 - - Rewrite Integer#times in Ruby (#8388) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 4efcaf956e27df365a1cf9e0cbb8d9a68eeb6995 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-09-04 10:27:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-08 01:36:56 +0900 - - [ruby/yarp] Extract error messages into diagnostic.c and use canonical message IDs - - The parser now passes around `yp_diagnostic_id_t` for diagnostic - messages instead of character strings, and we rely on the function - `diagnostic_message()` to resolve that to a string. - - In addition, many messages were edited so that the parser expresses - coordinate ideas in similar form [1] using consistent voice and - typographic conventions. - - Closes https://github.com/ruby/yarp/pull/1379, and makes progress on #941. - - [1] Strunk & White rule 19 - - https://github.com/ruby/yarp/commit/0b6dd85bf1 - -commit 2d37b44603f2031f0e95073ab77b418142c9eddd - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-09-06 16:47:07 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-09-08 01:31:16 +0900 - - Document that thread event hooks are called without the GVL - - Except for the `RESUMED` event. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8383 - -commit 7adc38b8957d3d36c71450f44ee5adfd8b2bfff9 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-07 23:59:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-07 23:59:51 +0900 - - [YARP] Miscellaneous small bug fixes (#8387) - - Notes: - Merged-By: jemmaissroff - -commit 630e49010cd91e97ce49d315b00d4ece193ebe82 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-07 21:45:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 23:02:40 +0900 - - [ruby/yarp] remove now-redundant `YP_TOKEN_NOT_PROVIDED_VALUE` - - https://github.com/ruby/yarp/commit/8f9a3c2345 - -commit 44b52c54164116b38462085916bffcda00a41a2a - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-07 21:44:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 23:02:40 +0900 - - [ruby/yarp] use `YP_LOCATION_*_VALUE` macros more consistently - - https://github.com/ruby/yarp/commit/bcad93e2fc - -commit 194584f20277a63164789aa83ae3841ef6e6eb8c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-07 01:43:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 23:01:21 +0900 - - [ruby/yarp] Introduce owned constants - - Before this commit, constants in the constant pool were assumed to - be slices of the source string. This works in _almost_ all cases. - - There are times, however, when a string needs to be synthesized. - This can occur when passing in locals that need to be scoped through - eval, or when generating method names like `foo=`. - - After this commit, there is a single bit `owned` boolean on - constants in the pool that indicates whether or not it is a slice - of the source string. If it is not, it is assumed to be allocated - memory that should be freed by the constant pool when the constant - pool is freed. - - When serializing, the most significant bit in the location of the - contents of the constant indicates whether or not it is owned. - When it is, instead of 4 bytes for the source offset and 4 bytes - for the length it is instead 4 bytes for the buffer offset and 4 - bytes the length. The contents of the owned constants are embedded - into the buffer after the constant pool itself. - - https://github.com/ruby/yarp/commit/461c047365 - -commit 0adca625ee34ced92da68ba144de32f44e7300cd - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-09-07 22:54:05 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-07 22:54:05 +0900 - - Remove function call for String#bytesize (#8389) - - * Remove function call for String#bytesize - - String size is stored in a consistent location, so we can eliminate the - function call. - - * Update yjit/src/codegen.rs - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - --------- - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 0c8928721e19dda1ce7b1a8797b18d199207708c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-07 22:10:50 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-09-07 22:10:50 +0900 - - [YARP] Use the correct field for the name on classes and modules - -commit 14970cfc8d4ae68d173a2df45abecc4c41220270 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-07 00:27:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 21:42:02 +0900 - - [ruby/yarp] Constants and def nodes - - https://github.com/ruby/yarp/commit/6b2421ce1b - -commit 9343ef250452c17b2842701805a4a0417165dd15 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-07 00:22:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 21:42:02 +0900 - - [ruby/yarp] Constants on rest parameter nodes - - https://github.com/ruby/yarp/commit/a6fdb8aae9 - -commit 3f78eec44ab2f06f05c699cbd90714716e13ebd7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-07 00:14:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 21:42:01 +0900 - - [ruby/yarp] Constants on keyword rest parameters - - https://github.com/ruby/yarp/commit/5e1a8fbc54 - -commit 9e21b33ece212b67d62cf47527a1d9e0251c9fdd - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-07 00:06:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 21:42:00 +0900 - - [ruby/yarp] Constants on keyword parameters - - https://github.com/ruby/yarp/commit/d2d4f25a23 - -commit e2a0f25888d089f6f858e584c3210c2d00ad3f12 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-07 04:30:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 21:41:45 +0900 - - [ruby/yarp] Remove name constant from classes/modules - - https://github.com/ruby/yarp/commit/26105f0b58 - -commit 5184b40dd4dc446660cd35c3e53896324e95b317 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-09-07 21:32:54 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-07 21:32:54 +0900 - - Extract `do_mutex_lock_check_interrupts` to try and fix `ppc64le`. (#8393) - - We found some tests were hanging in `do_mutex_lock`, specifically the - fiber scheduler autoload test. After much investigation, it may be a code - generation bug. Because we didn't change the code, but only extracted it - into a separate function, and it appears to fix the problem. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 009e0a3f9e26b30623ade32f7edf1806426f3a45 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-09-07 15:59:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 15:59:55 +0900 - - Update bundled gems list at 2023-09-07 - -commit bd046764e31267c83e7ae515d9bc7f09ffaa5b95 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-29 18:42:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-07 13:41:13 +0900 - - [Bug #19549] Check for variables to be interpolated - - Notes: - Merged: https://github.com/ruby/ruby/pull/7615 - -commit 05aaff2191cbe777d1efb915ab9652eeaa1c16b8 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-09-07 10:53:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-07 10:53:51 +0900 - - Reduce number of iterations in `TestFiberScheduler#test_autoload`. (#8391) - - `ppc64le` appears to be struggling with this test due to timeout. Let's see - if reducing the number of iterations can help improve the test performance. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit ac65fc833d79ad519c114647b3624a733cdd5485 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-07 10:05:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-07 10:05:10 +0900 - - [DOC] Fix up Process::Status#>> - -commit 89cb95679dfcb15e404d03959497e5b1dda78df3 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-09-01 13:38:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 09:33:29 +0900 - - [rubygems/rubygems] Reduce excess index creation and merging - - When @allow_cached is true, @allow_local is always true, - therefore, the #installed_specs will always be merged after #cached_specs - is called. This makes starting with installed_specs.dup redundant. - - When #cached_specs is called because @allow_remote is true and - @allow_cached is false, then installed_specs will be added after - cached_specs based on @allow_local. - - We never need to add installed_specs here, so don't. - - https://github.com/rubygems/rubygems/commit/49b38f9750 - -commit 86b93f74819dc814a223cd179d15b4d46dc3fc7a - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-09-01 12:11:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 09:33:28 +0900 - - [rubygems/rubygems] Improve efficiency of Index#use and #search_all - - Rename Index#use(override = true) to #merge! - - Rename Index @all_specs to @duplicates, it is not actually all specs. - @duplicates only holds specs that would have been overridden during a call to - Index#use or Index#merge! - - Reduced dupes in @duplicates by not double adding the new spec to the - index and the @duplicates during #merge! - - Reduce Array creation by using specialized methods when the one result - or no results are needed from the search. - - https://github.com/rubygems/rubygems/commit/47e91125db - -commit af1bedbbd93e952810149e79d7fa6c20960e5373 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-09-01 12:08:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 09:33:28 +0900 - - [rubygems/rubygems] Source::Rubygems#fetch_names is only called with override = false - - https://github.com/rubygems/rubygems/commit/790202691d - -commit 54274b8c65a0981f1c69055a1513ba3c614dd675 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-07 07:26:11 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-07 07:26:11 +0900 - - [DOC] Rdoc for Process::Status (#8386) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit acd626a58345247a2d98c3cff1233008a6e81c61 - Author: Vinicius Stock <vinicius.stock@shopify.com> - AuthorDate: 2023-09-07 04:21:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 04:50:21 +0900 - - [ruby/yarp] Consider source encoding for `slice` - - https://github.com/ruby/yarp/commit/8f59fc27cd - - Co-authored-by: Kevin Newton <kddnewton@users.noreply.github.com> - -commit fdf7aad902ccc9e2f32e4b6b3e21fb68a8788d16 - Author: Andy Waite <andyw8@users.noreply.github.com> - AuthorDate: 2023-08-30 05:42:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 03:37:41 +0900 - - [ruby/yarp] Fix `Location#end_column` - - https://github.com/ruby/yarp/commit/00e4711026 - -commit 12102d101af258d7a3e9695b736a189cd3658df1 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-07 03:20:23 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-07 03:20:23 +0900 - - Fix crash in WeakMap during compaction - - WeakMap can crash during compaction because the st_insert could allocate - memory. - -commit 746eede412f083dc93923e39e3299c69fce46c15 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-06 23:46:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 03:18:10 +0900 - - [ruby/yarp] Constant on block parameter node - - https://github.com/ruby/yarp/commit/2cd9a67150 - -commit 08929b344d89fb12fb3a12eccf686458dc820e6d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-07 02:31:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-07 02:31:50 +0900 - - Try to fix flaky test_warmup_frees_pages - - This test sometimes fails with: - - ``` - 1) Failure: - TestProcess#test_warmup_frees_pages [test/ruby/test_process.rb:2750]: - <202> expected but was - <203>. - ``` - -commit dee383b2625187ee2e9d27799aa83c2afe91caa2 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-07 01:19:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-07 01:19:43 +0900 - - [ruby/yarp] Constants on classes and modules - (https://github.com/ruby/yarp/pull/1409) - - https://github.com/ruby/yarp/commit/0a11ec579f - -commit 1d4d9a016a5e38d07cff7581c0bf82df784e5617 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-07 01:19:23 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-07 01:19:23 +0900 - - [YARP] ClassNode and ModuleNode use name_constant (#8384) - - Notes: - Merged-By: jemmaissroff - -commit b3b57f70cc1ee6f40ff10b2abaa51889abce2331 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-06 23:27:57 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-07 00:18:50 +0900 - - Fix missing write barrier in iseq instruction list - - There's a missing write barrier for operands in the iseq instruction - list, which can cause crashes. - - It can be reproduced when Ruby is compiled with `-DRUBY_DEBUG_ENV=1`. - Using the following command: - - ``` - RUBY_GC_HEAP_OLDOBJECT_LIMIT_FACTOR=0 RUBY_DEBUG=gc_stress ruby -w --disable=gems -Itool/lib -W0 test.rb - ``` - - The following script crashes: - - ``` - require "test/unit" - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8385 - -commit a52ac350ccb8eb2ab394548844ffe681f9f02d0f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-06 23:30:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-06 23:30:55 +0900 - - [ruby/yarp] Fix assert_raises in YARP - - https://github.com/ruby/yarp/commit/8f8f3530aa - -commit ae41bdac1ea96de1d75ddf9a4a0ca3dc827a501b - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-06 23:28:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-06 23:28:29 +0900 - - [YARP] Use constant_id lookups where possible (#8374) - - This commit extracts a `yp_constant_id_lookup` method and uses yp_constant_id_lookup where possible - - Notes: - Merged-By: jemmaissroff - -commit 5537169ef0a8a42f8923a545a1fa6a1768e0f0d6 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-06 22:06:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-06 23:20:13 +0900 - - [ruby/yarp] Temporarily add name_constant to replace name on ClassNode/ModuleNode - - https://github.com/ruby/yarp/commit/8f87686e9c - -commit dae6a0a29579291f7775e397c1523ce23fba1f48 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-05 23:22:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-06 23:19:58 +0900 - - [ruby/yarp] Introduce YARP::Pattern - - https://github.com/ruby/yarp/commit/2a12e9637b - -commit 4c9a036606afff049b1184b7a7c6d9d8a3a50307 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-06 02:53:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-06 22:00:23 +0900 - - [ruby/yarp] Add constants and constants - - https://github.com/ruby/yarp/commit/d7eaa89bc3 - -commit 6778d2c582d8f17b81b9a8894bd3b2c152050bd3 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-05 23:25:59 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-06 21:43:14 +0900 - - Support freeing the lowest memory address page - - This should help fix the following flaky test: - - ``` - 1) Failure: - TestProcess#test_warmup_frees_pages [test/ruby/test_process.rb:2751]: - <0> expected but was - <1>. - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8369 - -commit 6408da70b036de1d0f158f29051eadf4040ab471 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-09-06 04:43:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-06 21:30:36 +0900 - - [ruby/yarp] Add deprecated aliases of the form YP_NODE_<name>_NODE - - https://github.com/ruby/yarp/commit/ae1f45ff52 - -commit 6356f6d3cd4a8bd470176d80bd880882bf40beb8 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-09-04 18:33:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-06 21:30:36 +0900 - - [ruby/yarp] Rename YP_NODE_*_NODE to YP_*_NODE - - https://github.com/ruby/yarp/commit/d93b93f342 - -commit 5ba480e4eab7f0660a11bb21044aa4077aedf7d1 - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-08-29 18:26:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-06 19:51:53 +0900 - - Use the test-unit-ruby-core gem for Test::Unit::CoreAssertions - - test/lib/core_assertions.rb and its dependencies are now packaged in - the gem test-unit-ruby-core. Let's use it instead. - -commit 3fd90c0158f8170ad11c8a99354bb3347c7cc121 - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-08-30 00:02:37 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-06 19:31:11 +0900 - - [ruby/openssl] test/openssl/test_pkey_ec.rb: refactor tests for EC.builtin_curves - - Check that OpenSSL::PKey::EC.builtin_curves returns an array in the - expected format. - - Similarly to OpenSSL::Cipher.ciphers, OpenSSL::PKey::EC.builtin_curves - returns a list of known named curves rather than actually usable ones. - - https://github.com/ruby/openssl/issues/671 found that the list may - include unapproved (and thus unusable) curves when the FIPS module is - loaded. - - https://github.com/ruby/openssl/commit/c53cbabe00 - -commit 1d4a43e7b09d0c90be6bef839b0616fe6a9008cd - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-08-31 14:58:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-06 19:30:55 +0900 - - [ruby/openssl] test/openssl/test_ossl.rb: relax assertion for error messages - - The test case test_error_data utilizes the error message generated by - X509V3_EXT_nconf_nid(). The next commit will use X509V3_EXT_nconf(), - which generates a slightly different error message. Let's adapt the - check to it. - - https://github.com/ruby/openssl/commit/9cdfa3a4d1 - -commit 91e5f51607e38138045b67f80932f7a2a56f7d72 - Author: Michael Richardson <mcr@sandelman.ca> - AuthorDate: 2017-08-27 09:09:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-06 19:30:32 +0900 - - [ruby/openssl] x509ext: let X509::ExtensionFactory#create_ext take a dotted OID string - - instead of looking of NIDs and then using X509V3_EXT_nconf_nid, - instead just pass strings to X509V3_EXT_nconf, which has all the logic for - processing dealing with generic extensions - also process the oid through ln2nid() to retain compatibility. - - [rhe: tweaked commit message and added a test case] - - https://github.com/ruby/openssl/commit/9f15741331 - -commit 98d8f6128e7f8378bf6e34b5c12fae9bdd6d3f10 - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-08-31 14:12:57 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-06 19:28:47 +0900 - - [ruby/openssl] x509ext: test OpenSSL::X509::ExtensionFactory#create_ext with ln - - OpenSSL::X509::ExtensionFactory#create_ext and #create_extensions - accepts both sn (short names) and ln (long names) for registered OIDs. - - This is different from the behavior of the openssl command-line utility - which accepts only sn in openssl.cnf keys. - - Add a test case to check this. - - https://github.com/ruby/openssl/commit/91ae46c8d7 - -commit 9b6128c541386d6e375723bb9eb4161854d72112 - Author: Petrik <petrik@deheus.net> - AuthorDate: 2023-08-31 22:14:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-06 19:26:27 +0900 - - [ruby/openssl] Fix OCSP documentation - - `port` should be called on the `ocsp_uri` URI instead of `ocsp`, which - is just a string. - - https://github.com/ruby/openssl/commit/89a1c82dd0 - -commit 60a6de81a823cdb932d21fa5869c93853d3f2795 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-08-31 15:38:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-06 19:24:53 +0900 - - [ruby/openssl] Prefer String#unpack1 - (https://github.com/ruby/openssl/pull/586) - - String#unpack1 avoids the intermediate array created by String#unpack - for single elements, while also making a call to Array#first/[0] - unnecessary. - - https://github.com/ruby/openssl/commit/8eb0715a42 - -commit b6d7cdc2bad0eadbca73f3486917f0ec7a475814 - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-08-29 19:46:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-06 19:24:43 +0900 - - [ruby/openssl] ssl: use ffdhe2048 from RFC 7919 as the default DH group parameters - - In TLS 1.2 or before, if DH group parameters for DHE are not supplied - with SSLContext#tmp_dh= or #tmp_dh_callback=, we currently use the - self-generated parameters added in commit https://github.com/ruby/openssl/commit/bb3399a61c03 ("support 2048 - bit length DH-key", 2016-01-15) as the fallback. - - While there is no known weakness in the current parameters, it would be - a good idea to switch to pre-defined, more well audited parameters. - - This also allows the fallback to work in the FIPS mode. - - The PEM encoding was derived with: - - # RFC 7919 Appendix A.1. ffdhe2048 - print OpenSSL::PKey.read(OpenSSL::ASN1::Sequence([OpenSSL::ASN1::Integer((<<-END).split.join.to_i(16)), OpenSSL::ASN1::Integer(2)]).to_der).to_pem - FFFFFFFF FFFFFFFF ADF85458 A2BB4A9A AFDC5620 273D3CF1 - D8B9C583 CE2D3695 A9E13641 146433FB CC939DCE 249B3EF9 - 7D2FE363 630C75D8 F681B202 AEC4617A D3DF1ED5 D5FD6561 - 2433F51F 5F066ED0 85636555 3DED1AF3 B557135E 7F57C935 - 984F0C70 E0E68B77 E2A689DA F3EFE872 1DF158A1 36ADE735 - 30ACCA4F 483A797A BC0AB182 B324FB61 D108A94B B2C8E3FB - B96ADAB7 60D7F468 1D4F42A3 DE394DF4 AE56EDE7 6372BB19 - 0B07A7C8 EE0A6D70 9E02FCE1 CDF7E2EC C03404CD 28342F61 - 9172FE9C E98583FF 8E4F1232 EEF28183 C3FE3B1B 4C6FAD73 - 3BB5FCBC 2EC22005 C58EF183 7D1683B2 C6F34A26 C1B2EFFA - 886B4238 61285C97 FFFFFFFF FFFFFFFF - END - - https://github.com/ruby/openssl/commit/a5527cb4f4 - -commit 4a042b2255519eb3e2826609dd8c042e164e7a26 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2022-12-26 20:35:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-06 19:24:02 +0900 - - [ruby/openssl] Refactor Buffering consume_rbuff and getbyte methods - - Prefer ``slice!`` for ``Buffering#consume_rbuff`` and safe navigation with ``ord`` for ``Buffering#getbyte``, similar to ``each_byte``. - - https://github.com/ruby/openssl/commit/5f6abff178 - -commit 912f1cda0d2ddfb4e6a52d43952a0562cb0fb46d - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-08-31 21:34:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-06 19:20:57 +0900 - - [ruby/openssl] Remove OSSL_DEBUG compile-time option - - Remove the OSSL_DEBUG flag and OpenSSL.mem_check_start which is only - compiled when the flag is given. They are meant purely for development - of Ruby/OpenSSL. - - OpenSSL.mem_check_start helped us find memory leak bugs in past, but - it is no longer working with the recent OpenSSL versions. Let's just - remove it now. - - https://github.com/ruby/openssl/commit/8c7a6a17e2 - -commit abd0b9b28a8179687ff424fabcaf48bb3843e802 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-06 14:06:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-06 14:06:26 +0900 - - Exclude `-Wmisleading-indentation` when `-save-temps` - - That option may be triggered wrongly by pre-processed files. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8382 - -commit ae9623216110277691cae4cb6d56ba76f170cbd7 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-06 06:29:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-06 06:29:32 +0900 - - [YARP] Fix warning on compiling constant test (#8377) - - Notes: - Merged-By: jemmaissroff - -commit 767f984017ca264262d9ef04d1db78c6f361e65a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-06 03:16:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-06 04:13:30 +0900 - - [ruby/yarp] Flatten CallAndWriteNode, CallOrWriteNode, and CallOperatorWriteNode - - https://github.com/ruby/yarp/commit/8f26ffa0b2 - -commit 95e4bdcd6263a8106eac25458a48517aaa4456f8 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-06 02:58:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-06 04:13:29 +0900 - - [ruby/yarp] Rename CallNode#operator_loc to CallNode#call_operator_loc - - https://github.com/ruby/yarp/commit/fbcd307a54 - -commit 6c4df555fd879570cec152f7b378995e782dcd4f - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-09-06 03:46:44 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-09-06 03:46:44 +0900 - - YJIT: Silence Clippy for bindgen generated code - - New Clippy lint in 1.72.0 is breaking our build as GitHub has updated - their image. No point hearing about lints from generated code we don't - manually write. - -commit c384ef07991d08dc378bf6450363aaa654099813 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-06 01:34:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-06 03:41:51 +0900 - - [ruby/yarp] Introduce a BlockLocalVariableNode - - This is a tradeoff that I think is worth it. Right now we have a - location list that tracks the location of each of the block locals. - Instead, I'd like to make that a node list that has a proper node - in each spot in the list. In doing so, we eliminate the need to have - a location list at all, making it simpler on all of the various - consumers as we have one fewer field type. There should be minimal - memory implications here since this syntax is exceedingly rare. - - https://github.com/ruby/yarp/commit/04d329ddf0 - -commit 9a8398a18f364d3bcfc8d2744162d3572d9491e4 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-06 02:34:46 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-06 03:32:15 +0900 - - Introduce rb_gc_remove_weak - - If we're during incremental marking, then Ruby code can execute that - deallocates certain memory buffers that have been called with - rb_gc_mark_weak, which can cause use-after-free bugs. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8375 - -commit 06a1d16dc2108c54090a0fca8b356f39ef353a99 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-06 02:34:41 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-06 03:32:15 +0900 - - Reuse allocated buffer in WeakMap - - If the key exists in WeakMap and WeakKeyMap, then we can reuse the - buffer and we can avoid an allocation. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8375 - -commit bdfa885f87b291dac8d0d390ba06b7f69f48da34 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-06 02:58:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-06 02:58:16 +0900 - - [YARP] Fix aliasing instructions to use INT2FIX (#8373) - - Notes: - Merged-By: jemmaissroff - -commit a17a1cd53573048ef3574fd105c297fadef9e934 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-06 01:53:11 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-06 01:53:11 +0900 - - [DOC] Fix for RDoc for Process.kill (#8370) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 88b25294b0e8d75f7901444bc5b2dc9e79411bdf - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-06 01:23:35 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-06 01:23:35 +0900 - - Suppress macro redefinition warnings - - When building with ruby, `snprintf` is replaced with `ruby_snprintf`. - -commit ab9d1910ef2071589e4915e738b0a8abc97e2b6a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-02 02:22:37 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-05 23:55:23 +0900 - - Rename shady to uncollectible_wb_unprotected - - The term "shady object" was renamed to "uncollectible write barrier - unprotected object", so rename `has_uncollectible_shady_objects` to - `has_uncollectible_wb_unprotected_objects` for consistency. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8351 - -commit e3210177e3d5d431543e66257d78564901e34611 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-05 23:54:21 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-05 23:54:21 +0900 - - [YARP] Implemented Compiler for Constant(Or/Operator/And)Nodes (#8355) - - Notes: - Merged-By: jemmaissroff - -commit 7a930cf0e4ff4bf7d70ef927d6f20d3189edcd21 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-18 22:56:46 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-05 23:52:35 +0900 - - Pool more slots for large size pools - - We always sweep at least 2048 slots per sweep step, but only pool one - page. For large size pools, 2048 slots is many pages but one page is - very few slots. This commit changes it so that at least 1024 slots are - placed in the pooled pages per sweep step. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8249 - -commit 790df7d3837af6554b26664d6de9a4d167cea1c7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-05 23:23:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-05 23:24:00 +0900 - - [ruby/yarp] Fix up CI for Ruby 2.5 - - https://github.com/ruby/yarp/commit/462cb561a9 - -commit 89a4fd67453b33b7c709c715f01cfeff8efb2f9d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-04 23:50:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-05 22:47:54 +0900 - - [ruby/yarp] Switch `ERB.new` at startup - - https://github.com/ruby/yarp/commit/b87b4450cc - -commit e1713fa6a32070210322455d79ac4d3769aa6414 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-04 21:57:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-05 22:47:52 +0900 - - [ruby/yarp] Read template in UTF-8 - - https://github.com/ruby/yarp/commit/864b4ce99f - -commit 6110f415cd761fbfa3b6215b47dc81640032aa55 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-09-04 19:46:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-05 22:47:41 +0900 - - [ruby/yarp] The value field of ClassVariableWriteNode is never null/nil - - https://github.com/ruby/yarp/commit/2ddd2eff94 - -commit d83b5ea09d537431ff39d68de8832d5d7baf2db0 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-09-05 22:42:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-05 22:42:21 +0900 - - [ruby/irb] Bump version to 1.8.1 - (https://github.com/ruby/irb/pull/706) - - https://github.com/ruby/irb/commit/c7c838a4bf - -commit ef65183692789f80dc1c1ad569a449edfdd46120 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-05 22:27:11 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-05 22:27:11 +0900 - - Add check for T_NONE in rb_gc_mark_weak - - This commit adds a check for T_NONE in rb_gc_mark_weak, just like - gc_mark_ptr. This will help debugging. - -commit 5b157997e29ee41dd9c94861dde38d148bca941d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-05 21:09:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-05 21:09:41 +0900 - - [DOC] Fix up markup - -commit 7c8932365f043a4b6f44c55c432ceb6e028c1f2c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-05 20:36:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-05 20:36:45 +0900 - - [DOC] Fix signal list - - - Signal names can be symbols, as stated above. - - Supported signals and those values are platform dependent. - - Key sequences to send signal are configurable. - - Fix description of signal 0. - - Co-authored-by: Peter Zhu <peter@peterzhu.ca> - - Notes: - Merged: https://github.com/ruby/ruby/pull/8367 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 5b146eb5a15cce4c7a6ce279bd53e75a61d4a1f5 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-09-05 17:35:28 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-09-05 17:35:28 +0900 - - Prevent "ambiguous first argument" warnings - - ``` - /home/chkbuild/chkbuild/tmp/build/20230905T063003Z/ruby/test/yarp/compiler_test.rb:16: warning: ambiguous first argument; put parentheses or a space even after `+' operator - /home/chkbuild/chkbuild/tmp/build/20230905T063003Z/ruby/test/yarp/compiler_test.rb:17: warning: ambiguous first argument; put parentheses or a space even after `-' operator - /home/chkbuild/chkbuild/tmp/build/20230905T063003Z/ruby/test/yarp/compiler_test.rb:28: warning: ambiguous first argument; put parentheses or a space even after `+' operator - /home/chkbuild/chkbuild/tmp/build/20230905T063003Z/ruby/test/yarp/compiler_test.rb:29: warning: ambiguous first argument; put parentheses or a space even after `-' operator - ``` - - http://rubyci.s3.amazonaws.com/debian10/ruby-master/log/20230905T063003Z.log.html.gz - -commit 77db0ca6c881b6fc705873f471fe4c52bffc0d50 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-09-05 17:29:53 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-09-05 17:29:53 +0900 - - Prevent a warning: method redefined; discarding old included - - ``` - [ 3463/25719] JSONGeneratorTest#test_string_ext_included_calls_super/home/chkbuild/chkbuild/tmp/build/20230905T063003Z/ruby/test/json/json_generator_test.rb:411: warning: method redefined; discarding old included - /home/chkbuild/chkbuild/tmp/build/20230905T063003Z/ruby/test/json/json_generator_test.rb:399: warning: previous definition of included was here - ``` - - http://rubyci.s3.amazonaws.com/debian10/ruby-master/log/20230905T063003Z.log.html.gz - -commit 923d3517f145d9cb30bbc7d680aac32531de14ed - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-09-05 11:51:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-09-05 14:29:46 +0900 - - [flori/json] Removed code for Ruby 1.8 - - https://github.com/flori/json/commit/7f9c29038d - -commit 4a90c934278a0b1de11389dbbc208ee044117119 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-09-02 21:50:17 +0900 - Commit: Kazuki Tsujimoto <kazuki@callcc.net> - CommitDate: 2023-09-05 11:52:34 +0900 - - Pattern matching has not been experimental - - Notes: - Merged: https://github.com/ruby/ruby/pull/8360 - -commit c9af91148997d8a7d1dbcf5503fd5c46cbba0670 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-05 10:16:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-05 10:16:48 +0900 - - [DOC] RDoc for process.c (#8366) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit dab6d55db115448680968da1f46194886e5eac84 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-05 09:49:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-05 10:14:52 +0900 - - [ruby/rdoc] Remove code for versions older than Ruby 2.6 - - https://github.com/ruby/rdoc/commit/0d10f460eb - -commit 736092ec11c4a3e4aa643434a54b135a648765ea - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-05 09:48:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-05 10:14:51 +0900 - - [ruby/rdoc] Remove code for versions older than Ruby 2.3 - - https://github.com/ruby/rdoc/commit/a61b777df0 - -commit 3f6c92e9d592a2b122fb2260fccee7a7dd850cb8 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-02-20 07:46:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-05 09:45:42 +0900 - - [ruby/rdoc] Omit descriptions and parameter lists for methods defined in C not mentioned in call-seq - - This allows RDoc to better generate documentation for methods - following the Ruby core documentation guide (which omits aliases - in call-seq in most cases). This makes documentation for methods - defined in C more similar to methods defined in Ruby. For methods - defined in Ruby, the method description of the aliased method is - already not used (you have to explicitly document the alias to - use it). - - Internally, this adds AnyMethod#has_call_seq? and #skip_description?, - and updates Darkfish to: - - * only show the method name if there is a call-seq for the method, - but the call-seq omits the method - * to omit the method description if the method is an alias or has - aliases and has a call-seq that does not include the method - - See discussion in https://github.com/ruby/ruby/pull/7316 for - details. - - https://github.com/ruby/rdoc/commit/e3688de49b - -commit a14ba622da01c7774d0fb285b183097d19e3675e - Author: theo-squadracer <92919588+theo-squadracer@users.noreply.github.com> - AuthorDate: 2023-09-05 09:37:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-05 09:37:30 +0900 - - [ruby/rdoc] handle symbols declared with `%s` - - https://github.com/ruby/rdoc/commit/ed91c4b784 - -commit db3b814cb0ff6ffe83fe0c4f66cd6ce8951c3ca7 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-05 03:01:33 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-05 03:01:33 +0900 - - Add debug info for flaky test_warmup_frees_pages - - This test sometimes fails with: - - ``` - 1) Failure: - TestProcess#test_warmup_frees_pages [test/ruby/test_process.rb:2751]: - <0> expected but was - <1>. - ``` - - I'm not sure why, so add some debug info. - -commit 0b5c61494eb30c8c1867b9e6a52ad678e3f47901 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-09-04 23:07:46 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-09-04 23:07:46 +0900 - - Update to ruby/spec@96d1072 - -commit 3504f928dfb60b763e7b66149ca45cdbb45df78a - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-09-04 23:07:44 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-09-04 23:07:44 +0900 - - Update to ruby/mspec@55d1a62 - -commit 4f4c1170bc988104f3bd3321558099af7ea19c18 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-09-04 19:51:40 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-09-04 19:52:08 +0900 - - Revert "Don't reset line coverage for evaled code. (#8330)" - - This reverts commit 7e0f5df2f99693267d61636d23da47f79924e9d5. - - https://bugs.ruby-lang.org/issues/19857#note-7 - -commit 4cc56592932d36c202b2366ffe7ad71db2f5ea0b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-01 23:07:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-04 21:50:27 +0900 - - Keep write-barrier status after splicing array - - We don't need to remove the write-barrier protected status after - splicing an array. We can simply add it to the rememberset for marking - during the next GC. - - The benchmark illustrates the performance impact on minor GC: - - ``` - require "benchmark" - - arys = 1_000_000.times.map do - ary = Array.new(50) - ary.insert(1, 3) - ary - end - - 4.times { GC.start } - - puts(Benchmark.measure do - 1000.times do - GC.start(full_mark: false) - end - end) - ``` - - This branch: - - ``` - 1.309910 0.004342 1.314252 ( 1.314580) - ``` - - Master branch: - - ``` - 54.376091 0.219037 54.595128 ( 54.742996) - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8350 - -commit 2ac3e9abe98579261a21a2e33df16f1bff1ebc1d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-04 10:30:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-04 10:35:26 +0900 - - [Bug #18487] [DOC] Remove stale note in `set_trace_func` document - - `c-call` and `c-return` events no longer pass the nearest Ruby method - binding. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8364 - -commit ba8a7ab8a8afdd2160a22b34477920f4db00db8f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-04 10:20:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-04 10:35:26 +0900 - - [DOC] Update `set_trace_func` document - - - Clarify the class of event parameters - - Represent event names as strings - - Update the example to show the above - - Notes: - Merged: https://github.com/ruby/ruby/pull/8364 - -commit 3b7c8e90da5c27c9355c9890b333585b45ae67eb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-04 09:23:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-04 10:35:26 +0900 - - [DOC] Fix indent of `set_trace_func` document - - Notes: - Merged: https://github.com/ruby/ruby/pull/8364 - -commit 7e0f5df2f99693267d61636d23da47f79924e9d5 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-09-04 10:31:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-04 10:31:25 +0900 - - Don't reset line coverage for evaled code. (#8330) - - * Add failing test. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 40ab77eb3dd075536bcc3a6c225a7c245c247db8 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-04 04:36:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-04 04:36:51 +0900 - - [DOC] Process doc (#8363) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 3602e253e79b796661168b458e22ba1694ec06e5 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-09-03 02:13:57 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-03 08:46:35 +0900 - - [DOC] RDoc for process.c - - Notes: - Merged: https://github.com/ruby/ruby/pull/8361 - -commit f867e936a98b320c4609d631d2f3046d463e7fc4 - Author: Herwin <herwinw@herwinw.nl> - AuthorDate: 2023-09-03 01:49:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-03 01:49:40 +0900 - - [DOC] Fix layout in documentation of IO#fcntl - - Notes: - Merged: https://github.com/ruby/ruby/pull/8359 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 8cd62fbc174beae65d5670ea92611cc7a9c34d7d - Author: Dorian Marié (perso) <dorian@dorianmarie.fr> - AuthorDate: 2023-09-03 01:47:50 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-03 01:47:50 +0900 - - [DOC] Typo in Hash#key description "so/no such value" - - Notes: - Merged: https://github.com/ruby/ruby/pull/8357 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 3887b45f47c32cf0171046bc23efc3887d8b58fc - Author: Dorian Marié (perso) <dorian@dorianmarie.fr> - AuthorDate: 2023-09-03 01:46:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-03 01:46:33 +0900 - - [DOC] FIx typo in description of Hash#hash (regardless or/of order) - - Notes: - Merged: https://github.com/ruby/ruby/pull/8356 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit ef4dab6983267d6c6719629693baa59eb9c24543 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-03 00:43:10 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-03 00:43:10 +0900 - - [DOC] RDoc for process.c (#8358) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 678112c57c54688013c41b6f0faaeca9d997e106 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-02 22:23:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-02 22:23:21 +0900 - - [ruby/yarp] Fix up template reading with LANG=C - - https://github.com/ruby/yarp/commit/1ce1817e84 - -commit cfcb4a4e2609963900a2628471c1a3162ec20451 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-02 22:04:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-02 22:04:04 +0900 - - [DOC] RDoc for process.c (#8353) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit c86497340f80f4bf5cd689e1468566b88e1a0ef2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-02 08:38:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-02 08:39:00 +0900 - - [ruby/yarp] Try ignoring $LANG - - because the previous commit did not fix it. - - https://github.com/ruby/ruby/actions/runs/6054915979/job/16433070185#step:9:155 - - https://github.com/ruby/yarp/commit/8c9e4c1f15 - -commit 3c41ef4749dc5df78c6d500c7e16fef384b53b15 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-02 08:33:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-02 08:36:11 +0900 - - [ruby/yarp] Support LANG=C environments in template.rb - - https://github.com/ruby/yarp/commit/885d731cf5 - -commit d89b15cdce8a2fa36fc2a150551f0dd8e58814d7 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-09-01 07:12:47 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-09-02 08:23:28 +0900 - - Use end of char boundary in start_with? - - Previously we used the next character following the found prefix to - determine if the match ended on a broken character. - - This had caused surprising behaviour when a valid character was followed - by a UTF-8 continuation byte. - - This commit changes the behaviour to instead look for the end of the - last character in the prefix. - - [Bug #19784] - - Co-authored-by: ywenc <ywenc@github.com> - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/8348 - -commit 2ca0f01015d076d966ab1b0f28700a4424b86da6 - Author: ywenc <ywenc@github.com> - AuthorDate: 2023-09-01 06:52:50 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-09-02 08:23:28 +0900 - - Add regression tests for start_with?/delete_prefix - - Notes: - Merged: https://github.com/ruby/ruby/pull/8348 - -commit e8ef5b1281b9dce518902b3451096164c30bca5c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-02 03:51:50 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-09-02 08:18:11 +0900 - - [ruby/yarp] Provide a better inspect - - https://github.com/ruby/yarp/commit/ef14ae66e4 - -commit 00f263e6c4cc709e5bdcce2c903c12f5d76f8a37 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-09-02 08:02:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-09-02 08:17:59 +0900 - - sync_default_gems.rb: Deal with conflicts on ignored files - - that do not exist in the ruby/ruby side. - - This resurrects a line that had existed prior to #8329. - -commit c666077182e3408a6b8a3e83789f60d6cee30c70 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-01 22:40:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-02 07:52:14 +0900 - - [ruby/yarp] Add global variables to the constant pool - - https://github.com/ruby/yarp/commit/b48067b067 - -commit d1f83c37f890e5345e68853c5e268975d4396ffc - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-02 06:48:55 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-02 06:48:55 +0900 - - Try to fix flaky test for Process.warmup - - The test sometimes fails with: - - ``` - 1) Failure: - TestProcess#test_warmup_frees_pages [test/ruby/test_process.rb:2749]: - <0> expected but was - <1>. - ``` - - I think there's a page with an object that needs finalization, so run - GC to clear that object. - -commit 95308988b6f70c04c43015a78c93b3f876da5958 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-02 06:20:03 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-02 06:20:03 +0900 - - [YARP] Implement Compiling for And / Or / Operator Write Nodes (#8352) - - Notes: - Merged-By: jemmaissroff - -commit 7f9a2df02bf3fe066788a0cf02803ab26d22c311 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-02 01:48:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-02 05:59:40 +0900 - - [ruby/yarp] Update src/util/yp_string_list.c style - - https://github.com/ruby/yarp/commit/e4af2b3bc2 - -commit d99db1199d4318e97a26687571b10f7629604018 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-02 01:47:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-02 05:59:40 +0900 - - [ruby/yarp] Update src/util/yp_newline_list.c style - - https://github.com/ruby/yarp/commit/bd7fc2c946 - -commit d617b1b6309ad974a2fb2169740f3a2969ededa0 - Author: HParker <HParker@github.com> - AuthorDate: 2023-09-01 07:36:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-02 05:59:39 +0900 - - [ruby/yarp] remove reallocs preparing for custom memory management - - https://github.com/ruby/yarp/commit/bd0b421504 - -commit 1c622a6b5818a92ba664c3d8292cf01b98083e4e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-09-02 05:42:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-02 05:56:15 +0900 - - [ruby/yarp] Bump to v0.10.0 - - https://github.com/ruby/yarp/commit/b6164a76d9 - -commit 95def300d2202586dafea6cea8ebcc915f116b7a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-09-02 04:28:29 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-02 04:28:29 +0900 - - Fix flaky test for Process.warmup - - The test sometimes fails with: - - ``` - 1) Failure: - TestProcess#test_warmup_run_major_gc_and_compact [test/ruby/test_process.rb:2712]: - <2> expected but was - <3>. - ``` - -commit e8b646fe91abd48b68a470d71e3f7dbff6788cf0 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-02 03:30:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-02 03:30:22 +0900 - - [YARP] Implement BackReferenceReadNode, NumberedReferenceReadNode (#8344) - - Notes: - Merged-By: jemmaissroff - -commit c0bf4029e3ff0c53bcc8d25a3c881c997aee9209 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-02 03:12:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-02 03:12:55 +0900 - - [ruby/yarp] Print information about type, flags on AST templated - code - (https://github.com/ruby/yarp/pull/1380) - - This commit adds the node type and the node flags as comments to - the AST templated code. - - https://github.com/ruby/yarp/commit/f603f2037c - -commit cfe1edddbf0512f029eaf8c6d68194d476120c16 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-09-02 00:01:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-02 02:04:37 +0900 - - [ruby/yarp] fix: report syntax error for invalid hex escape - - Closes https://github.com/ruby/yarp/pull/1367 - - https://github.com/ruby/yarp/commit/b1ab54f526 - -commit 512f8217cb378c289b7d79cdf033715afcf82667 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-09-01 23:45:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-02 02:04:37 +0900 - - [ruby/yarp] fix: double-counting of errors in parsing escaped strings - - Essentially, this change updates `yp_unescape_calculate_difference` to - not create syntax errors, and we rely entirely on - `yp_unescape_manipulate_string` to report syntax errors. - - To do that, this PR adds another (!) parameter to `unescape`: - `yp_list_t *error_list`. When present, `unescape` reports syntax - errors (and otherwise does not). - - However, an edge case that needed to be addressed is reporting syntax - errors in this case: - - ?\u{1234 2345} - - In a string context, it's possible to have multiple codepoints by - doing something like `"\u{1234 2345}"`; however, in the character - literal context, this is a syntax error -- only a single codepoint is - allowed. - - Unfortunately, when `yp_unescape_manipulate_string` is called, there's - nothing to indicate that we are in a "character literal" context and - that only a single codepoint is valid. - - To make this work, this PR: - - - introduces a new static utility function in yarp.c, - `yp_char_literal_node_create_and_unescape`, which is called when - we're parsing `YP_TOKEN_CHARACTER_LITERAL` - - introduces a new (unexported) function, - `yp_unescape_manipulate_char_literal` which does the same thing as - `yp_unescape_manipulate_string` but tells `unescape` that only a - single codepoint is expected - - https://github.com/ruby/yarp/commit/f6a65840b5 - -commit bead5396503175b6873d1b4e60bd8c8d2c82b772 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-16 21:55:01 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-02 00:58:50 +0900 - - Incrementally mark even if we have free pages - - We move all pooled pages to free pages at the start of incremental - marking, so we shouldn't run incremental marking only when we have run - out of free pages. This causes incremental marking to always complete - in a single step. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8230 - -commit 58e0a3699f3eadf5f34107f86ad2b654e4764730 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-02 00:02:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-02 00:02:55 +0900 - - Fix YARP compiled send for popping (#8345) - - Prior to this commit, we were incorrectly popping callers and receivers - on CallNodes. We shouldn't pop any of these as they might have - side effects. - - Notes: - Merged-By: jemmaissroff - -commit 4f290bc3283accbec70ed2bbd613e40d88131220 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-02 00:02:37 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-02 00:02:37 +0900 - - [YARP] Small fixes for existing ConstantNodes (#8346) - - Popped was slightly inaccurate for ConstantNodes and leading to issues - if there was content after a ConstantNode. This fix doesn't pop - any ConstantWriteNode values. - - Notes: - Merged-By: jemmaissroff - -commit 771576f02185b1044f23a451e3ac6b58494844dc - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-28 08:29:35 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-09-01 22:31:59 +0900 - - Skip weak references to old objects in minor GC - - If we are in a minor GC and the object to mark is old, then the old - object should already be marked and cannot be reclaimed in this GC cycle - so we don't need to add it to the weak refences list. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8304 - -commit 7f6407c356789db9039a0e45fbb8792236601956 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-31 05:55:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-01 22:18:30 +0900 - - [ruby/yarp] Ensure node are present only once in the desugared AST - - https://github.com/ruby/yarp/commit/7b090bc23d - -commit a21b5a943fe20892168eb76ecd1723191650da30 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-31 05:48:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-01 22:18:30 +0900 - - [ruby/yarp] Move name_loc before value for LocalVariableWriteNode - - * Consistent with ClassVariableWriteNode, ConstantWriteNode, InstanceVariableWriteNode, GlobalVariableWriteNode. - * Fixes desugaring of local variable with operators. - - https://github.com/ruby/yarp/commit/9a66737775 - -commit f1f6f1b39ebec35462efed9b20bfac4b6409133f - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-31 05:43:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-01 22:18:30 +0900 - - [ruby/yarp] Make operator_loc the last field for GlobalVariableWriteNode - - * Consistent with ClassVariableWriteNode, ConstantWriteNode, InstanceVariableWriteNode, LocalVariableWriteNode. - * Fixes desugaring of global variable with operators. - - https://github.com/ruby/yarp/commit/fb5a53fc0b - -commit 4172036bc6ba77aded874f67b15d657bd7ee3241 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-31 05:22:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-01 22:18:29 +0900 - - [ruby/yarp] Do not desugar Foo::Bar {||,&&,+}= baz as it is incorrect without a temporary variable - - * See https://github.com/ruby/yarp/pull/1329#discussion_r1310775433 for details. - - https://github.com/ruby/yarp/commit/f0fdcba0c3 - -commit 7fb56df726d4e661fdec10266a54cf27e52d9892 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-31 04:29:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-01 22:18:29 +0900 - - [ruby/yarp] Fix comments for methods using desugar_or_write_defined_node - - https://github.com/ruby/yarp/commit/a39147736e - -commit 2efd59e2eb4ebf68f85ab6f07b1a4aea0584248a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-09-01 14:22:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-01 16:04:43 +0900 - - [rubygems/rubygems] Use assertion message strictly - - https://github.com/rubygems/rubygems/commit/98da5b9826 - -commit 4c040fe8503d664dce46bf2fd9d2cfe8be6fbf41 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-01 14:06:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-01 14:06:42 +0900 - - Copy compile options from AST directly without intermediate Hash - - Notes: - Merged: https://github.com/ruby/ruby/pull/8349 - -commit 1fbc8cdf0686657c12cc9014cb4714730adc2ec6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-01 13:39:36 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-01 13:39:36 +0900 - - Copy `rb_compile_option_t` only if needed - - Use `COMPILE_OPTION_DEFAULT` if nothing to change. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8349 - -commit 61f1657f68b9cddf8956380e53b8e7053eeb30c8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-01 13:36:15 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-01 13:36:15 +0900 - - Use macro argument not the variable directly - - Notes: - Merged: https://github.com/ruby/ruby/pull/8349 - -commit 45cd011d73ed1fac195d828c0565e2cac57f65fc - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-08-31 21:35:55 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-09-01 12:55:09 +0900 - - [Bug #19281] Allow semicolon in parenthesis at the first argument of command call - - Allow compstmt in the first argument of command call wrapped with parenthesis - like following arguments with parenthesis. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8347 - -commit df4c77608e76068deed58b2781674b0eb247c325 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-09-01 07:40:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-01 07:40:35 +0900 - - [ruby/yarp] fix: octal, hex, and unicode strings at the end of a - file - (https://github.com/ruby/yarp/pull/1371) - - * refactor: move EOF check into yp_unescape_calculate_difference - - parser_lex is a bit more readable when we can rely on that behavior - - * fix: octal and hex digits at the end of a file - - Previously this resulted in invalid memory access. - - * fix: unicode strings at the end of a file - - Previously this resulted in invalid memory access. - - * Unterminated curly-bracket unicode is a syntax error - - https://github.com/ruby/yarp/commit/21cf11acb5 - -commit 9930363aab6ac4b8d7034baff85cd86c17953dc9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-09-01 03:15:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-09-01 04:26:31 +0900 - - [Bug-18878] Parse qualified const with brace block as method call - - Notes: - Merged: https://github.com/ruby/ruby/pull/8343 - -commit 945945dad434dd2c014a4d310dc7dc51e6d4321e - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-08-31 23:45:57 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-01 03:31:18 +0900 - - Remove gc_mark_values - - Now that gc_mark_values and rb_gc_mark_values are identical, we should - remove one. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8341 - -commit 322548180d01ce99dcb8ecb3c36f2a9261554657 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-08-31 23:35:56 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-09-01 03:31:18 +0900 - - Prevent rb_gc_mark_values from pinning objects - - This is an internal only function not exposed to the C extension API. - It's only use so far is from rb_vm_mark, where it's used to mark the - values in the vm->trap_list.cmd array. - - There shouldn't be any reason why these cannot move. - - This commit allows them to move by updating their references during the - reference updating step of compaction. - - To do this we've introduced another internal function - rb_gc_update_values as a partner to rb_gc_mark_values. - - This allows us to refactor rb_gc_mark_values to not pin - - Notes: - Merged: https://github.com/ruby/ruby/pull/8341 - -commit 84fa8ae84eeb20a35ff2040dbf107c6d9babfdec - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-09-01 03:02:09 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-01 03:02:09 +0900 - - [DOC] RDoc for #spawn (#8342) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 8470acc1ec6c06c62d857d5a01f6f9438f27fa10 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-09-01 00:04:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-01 02:43:50 +0900 - - [ruby/yarp] add some `const` qualifiers to local variables - - https://github.com/ruby/yarp/commit/eb3c6eb928 - -commit ace41c556a72392a0244d78bca35718f188cf004 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-09-01 02:00:19 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-01 02:00:19 +0900 - - [YARP] Avoid if-else in yp_compile_node (#8336) - - Move last node case outside for loop. - - Notes: - Merged-By: jemmaissroff - -commit b90457b210e6b1dc465d82dd08db126ce1a8228e - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-09-01 01:56:13 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-09-01 01:56:13 +0900 - - [YARP] Implement SourceNodes (File, Line, Encoding) (#8328) - - * [YARP] Implement SourceNodes (File, Line, Encoding) - - Notes: - Merged-By: jemmaissroff - -commit 3678734fac7a4d3d7e160200153090dcba6e3d94 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-09-01 00:44:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-09-01 00:44:17 +0900 - - [ruby/irb] Drop rdoc's version requirement - (https://github.com/ruby/irb/pull/704) - - 1. The newer versions of rdoc requires pysch 4.0+, which could break apps - using Ruby 3.0 or 2.7. #703 has more detailed explanation on this. - 2. We actually don't use any version-specific rdoc APIs. So having a version - requirement is not necessary atm. - - https://github.com/ruby/irb/commit/3e6ba78c42 - -commit 43825fba6eb39980130fd9bf47acb2000cde55d3 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-08-26 10:52:02 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-08-31 23:46:24 +0900 - - YJIT: Handle getblockparamproxy with ifunc - - getblockparamproxy for "ifunc" behaves identically to iseq, in just - pushing rb_block_param_proxy. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8300 - -commit 0270210e4984957427a4cf3824b724b62bfa2eaf - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-08-31 16:23:30 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-08-31 23:43:58 +0900 - - TestSocket_UNIXSocket: stop testing empty packets - - OpenBSD and Solaris behave differently here. - - Linux does deliver the empty packet, which is questionable - as it's undistinguishable from a closed connection. - - It seems that OpenBSD and Solaris simply drop it. - - We could test the platform before doing the assertion, but - it would likely be fragile, and the entire web recommend - to not ever send an empty packet, so the value of this - assertion is low. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8338 - -commit b8e782c1b5d0c13c97160d1bae5bdc95c0fca1f8 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-31 23:27:10 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-31 23:27:10 +0900 - - [DOC] Link fix (#8340) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 8804a70387bbff1f1497feef0fa1cfa37df1845b - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-31 23:08:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 23:08:08 +0900 - - [ruby/irb] Require Reline 0.3.8+ - (https://github.com/ruby/irb/pull/702) - - Reline 0.3.8 reduces the chance of having a deadlock with the debugger - while using the new `irb:rdbg` integration. - - https://github.com/ruby/irb/commit/9b8c56b7d4 - -commit 4f0d58260a7f506ead198064d12a967edd11fe5e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-31 04:28:22 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-31 22:28:31 +0900 - - Correctly calculate initial pages - - The old algorithm could calculate an undercount for the initial pages - due to two issues: - - 1. It did not take into account that some heap pages will have one less - slot due to alignment. It assumed that every heap page would be able - to be fully filled with slots. Pages that are unaligned with the slot - size will lose one slot. The new algorithm assumes that every page - will be unaligned. - 2. It performed integer division, which truncates down. This means that - the number of pages might not actually satisfy the number of slots. - - This can cause the heap to grow in `gc_sweep_finish_size_pool` after - allocating all of the allocatable pages because the total number of - slots would be less than the initial configured number of slots. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8333 - -commit eb3d94f4baff70d2e120c9472a3851a4aa9c90d9 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-31 22:06:11 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-31 22:06:11 +0900 - - [DOC] RDoc for Kernel#system (#8309) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit c45176dbca2bd082cb199e9411e4dfc5ec162352 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-18 10:30:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-31 16:49:58 +0900 - - [Bug #19349] Respect `#to_int` of `base` argument - - Notes: - Merged: https://github.com/ruby/ruby/pull/7144 - -commit 24b2bb465f6847e5d5df1845e022c940fdf63f48 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-18 10:25:25 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-31 16:49:57 +0900 - - Separate test for `Kernel#Integer` with `base` argument - - Notes: - Merged: https://github.com/ruby/ruby/pull/7144 - -commit 07ddb3589fcc07f68e19dee56e0722f9e0ea0682 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-31 16:35:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 16:35:45 +0900 - - [ruby/shellwords] omit blank line - - https://github.com/ruby/shellwords/commit/b45de514ab - -commit 2ce1b77ce0e776281142ab23523b745c9416105e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-31 11:32:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-31 11:32:29 +0900 - - sync_default_gems.rb: Discard some error messages - - These messages are expected: - - `cat-file -e` at newly added entries. - - `commit --amend` when all changes removed. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8329 - -commit cbe36ef6ccb9cb19d97612a85eede68cb3c073cb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-31 11:24:08 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-31 11:32:21 +0900 - - sync_default_gems.rb: Remove the pattern for yarp - - Changes to `ext/yarp/extconf.rb` are detected as conflicts now, and - ignored. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8329 - -commit 3d2a83b9093019274b8ef22d4010fac433599533 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-31 10:35:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-31 10:54:26 +0900 - - sync_default_gems.rb: Remove the pattern for bundler - - The "bundler" directory at the top-level will be removed by more - generic rule for top-level new entries. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8329 - -commit 97df09f276424636c39653a5480f20a70cc71050 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-30 15:05:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-31 10:30:36 +0900 - - sync_default_gems.rb: Refactor - - - Filter out files to be ignored first, then resolve conflicts. - - Add "added by gem" files, instead of hard-code paths to add. - - Remove gem specific patterns covered by more generic rules. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8329 - -commit dc911a47cee378d1e495c61ec3e6dc24995bdf8e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-30 15:04:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-31 10:30:35 +0900 - - sync_default_gems.rb: Move ignored_paths to ignore_file_pattern_for - - Notes: - Merged: https://github.com/ruby/ruby/pull/8329 - -commit 0aa404b9573d028d87072f40ecb9b86dc161b7ef - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-31 05:49:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-31 08:37:11 +0900 - - Change heap init environment variable names - - This commit changes RUBY_GC_HEAP_INIT_SIZE_{40,80,160,320,640}_SLOTS to - RUBY_GC_HEAP_{0,1,2,3,4}_INIT_SLOTS. This is easier to use because the - user does not need to determine the slot sizes (which can vary between - 32 and 64 bit systems). They now just use the heap names - (`GC.stat_heap.keys`). - - Notes: - Merged: https://github.com/ruby/ruby/pull/8335 - -commit 4aa98b2760944b04b827d6ba4037548a93ef94ff - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-31 06:21:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 06:31:36 +0900 - - [ruby/yarp] Add a value to numbered references - - https://github.com/ruby/yarp/commit/5d9b048971 - -commit 36786cc381c118986e66d8c3184e25adbaeaf591 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-31 06:30:42 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-31 06:30:42 +0900 - - [YARP] Compile ProgramNode as ScopeNode (#8327) - - * [YARP] Compile ProgramNode as ScopeNode - - Notes: - Merged-By: jemmaissroff - -commit 0ec5021f3d14707d1354158b8dec26ba6e079396 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-31 06:27:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-31 06:27:08 +0900 - - [YARP] Implement BreakNode, NextNode, RedoNode (#8334) - - Notes: - Merged-By: jemmaissroff - -commit f1790fa4e713f364bd6983586c0ba749e7b54968 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-31 06:26:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-31 06:26:22 +0900 - - [YARP] Fix variables in compilation (#8326) - - * [YARP] Fixed several popped instructions - - * [YARP] Correctly compiling class path - - Notes: - Merged-By: jemmaissroff - -commit 6599ca44bbaf9d1084638b392a46f1b3277212b9 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-31 04:27:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 05:51:49 +0900 - - [ruby/yarp] simplify the calling convention for `unescape` - - We don't need to pass in a destination pointer _and_ a write_to_str - boolean flag. - - https://github.com/ruby/yarp/commit/347cb29ebb - -commit bbaae3681ca9b4d00f2bb2330da1c7e3ff06cd17 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-31 02:30:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 05:46:09 +0900 - - [ruby/yarp] fix: regular expression with start and end out of order - - Also, a similar test and fix for interpolated regular expressions. - - This snippet: - - <<-A.g//, - A - /{/, ''\ - - previously created a regular expression node with inverted start and - end: - - RegularExpressionNode(14...13)((14...15), (15...21), (12...13), ", ''", 0), - - which failed an assertion during serialization. - - After this change: - - RegularExpressionNode(12...15)((14...15), (15...21), (12...13), ", ''", 0), - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/5fef572f95 - -commit 6beaf010a447ce9fb35c85f9fb2f41685e2114ba - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-31 02:09:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 05:46:09 +0900 - - [ruby/yarp] fix: binary CallNode with out-of-order arg and receiver - - The snippet added in this commit previously resulted in a CallNode - with inverted start and end locations: - - > AssocNode(15...13)( - > CallNode(15...13)( - StringNode(15...17)((15...16), (16...16), (16...17), ""), - nil, - (12...13), - nil, - ArgumentsNode(12...13)([MissingNode(12...13)()]), - nil, - nil, - 0, - "/" - ), - MissingNode(13...13)(), - (13...13) - ), - - which failed an assertion during serialization. - - After this change, it looks better: - - > AssocNode(12...13)( - > CallNode(12...17)( - StringNode(15...17)((15...16), (16...16), (16...17), ""), - nil, - (12...13), - nil, - ArgumentsNode(12...13)([MissingNode(12...13)()]), - nil, - nil, - 0, - "/" - ), - MissingNode(13...13)(), - (13...13) - ), - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/040aa63ad6 - -commit f80582cda8fb0d994db0c1cdf1c282f3a049485c - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-30 22:59:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 05:46:08 +0900 - - [ruby/yarp] fix: StatementsNode with out-of-order body nodes - - The presence of the heredocs in this snippet with invalid syntax: - - for <<A + <<B - A - B - - causes the MissingNode to have a location after other nodes in the - list, resulting in a StatementsNode with inverted start and end - locations: - - [ForNode(0...14)( - MultiWriteNode(4...7)([InterpolatedStringNode(4...7)((4...7), [], (14...16))], nil, nil, nil, nil), - MissingNode(16...16)(), - > StatementsNode(16...14)( - [MissingNode(16...16)(), InterpolatedStringNode(10...13)((10...13), [], (16...18)), MissingNode(13...14)()] - ), - (0...3), - (16...16), - nil, - (14...14) - )] - - which failed an assertion during serialization. - - With this fix, the node's locations are: - - [ForNode(0...14)( - MultiWriteNode(4...7)([InterpolatedStringNode(4...7)((4...7), [], (14...16))], nil, nil, nil, nil), - MissingNode(16...16)(), - > StatementsNode(10...16)( - [MissingNode(16...16)(), InterpolatedStringNode(10...13)((10...13), [], (16...18)), MissingNode(13...14)()] - ), - (0...3), - (16...16), - nil, - (14...14) - )] - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/09bcedc05e - -commit 209eda599a06682b0d32aa84870038e854fc49ef - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-31 05:44:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 05:44:27 +0900 - - [ruby/yarp] BASERUBY fails because of .then not existing - - https://github.com/ruby/yarp/commit/db925f2b88 - -commit cc71e2344b21e6d9931e7bdd4434c08c56a8ea00 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-30 23:40:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 05:42:01 +0900 - - [ruby/yarp] Revisit lex.rake, make lex:rubygems more useable - - https://github.com/ruby/yarp/commit/4c76f4a0c0 - -commit c46858fd6aa360e2165fa415f05b1112531128b8 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-30 05:18:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 05:41:59 +0900 - - [ruby/yarp] Nest all of the YARP tests under the YARP namespace - - https://github.com/ruby/yarp/commit/440cf93a70 - -commit c0cb9efb16993b0898979844c54207f979b2bd44 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-31 05:12:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 05:41:40 +0900 - - [ruby/yarp] Fix up Rust config.yml reading - - https://github.com/ruby/yarp/commit/087f367847 - -commit ff024150e766a0db5ee9517ab1b0e7c84beca14b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-31 05:09:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 05:41:39 +0900 - - [ruby/yarp] Rename child_nodes to fields - - https://github.com/ruby/yarp/commit/715fce9264 - -commit f83070816dbe281e8cd2993494704c4a2af49a47 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-31 04:35:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 05:41:39 +0900 - - [ruby/yarp] Move templating logic until YARP - - https://github.com/ruby/yarp/commit/8b7430dbc7 - -commit 00dbee94ac71527cffbfa959a99f17457eb440fc - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-31 04:28:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 04:59:28 +0900 - - [ruby/yarp] Add class variables to the constant pool - - https://github.com/ruby/yarp/commit/be5cb60c83 - -commit 151e94fee5a54f07fa031942de72009c7f7b1d1d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-31 04:20:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 04:59:26 +0900 - - [ruby/yarp] Fix instance variable constant names - - https://github.com/ruby/yarp/commit/1f94f55fcb - -commit 082962e857833dfc16881cb4dfb44caa175590ba - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-05-26 12:12:20 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-08-31 04:47:39 +0900 - - Work around a hang in fork(2) on FreeBSD - - See bug https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=271490 - - On FreeBSDk, it's possible for fork(2) in a multithreaded process to - hang because of a bug in the lock handling of the dynamic linker. This - is now fixed on FreeBSD master, but it would be good if we could work - around it for Ruby CI which is running 13.1. - - Setting LD_BIND_NOW seems to work around the problem (probably because - the dynamic linker doesn't then need to resolve anything through the PLT - when it's first called). - - Notes: - Merged: https://github.com/ruby/ruby/pull/7867 - -commit 1ed70eb99f54a4221bf2e4644596922f676340cc - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-31 04:20:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 04:20:21 +0900 - - [ruby/yarp] Fix unused variable in YARPRubyAPITest - - https://github.com/ruby/yarp/commit/0556f971ce - -commit 49dff732e8734dccc7e30102cadc13290618d54a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-31 03:32:52 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-31 03:41:39 +0900 - - Update YARP APIs to handle uint8_t - -commit 7be08f3f58a818461b43c8f9a756d656e7e928c5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-29 23:48:20 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-31 03:41:23 +0900 - - [ruby/yarp] Switch from handling const char * to const uint8_t * - - https://github.com/ruby/yarp/commit/465e7bb0a9 - -commit eac3da173acf801638656c57a4554773c3af5ac0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-31 03:35:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:36:38 +0900 - - [ruby/yarp] Fix test-unit API in fuzzer test - - https://github.com/ruby/yarp/commit/d24f62566e - -commit 2d009805e71e76c4f7678409aea804e18df01446 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-31 03:03:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:27:52 +0900 - - [ruby/yarp] fix: comment followed by whitespace at end of file - - Previously this resulted in invalid memory access. - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/b248553dd6 - -commit ae7f9075592ea3570dfba831d086c423301fbcb7 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-31 02:52:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:27:51 +0900 - - [ruby/yarp] fix: heredoc with incomplete escape at end of file - - Previously this resulted in invalid memory access. - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/ec4abd87f4 - -commit 341f47a6dd3690754fe9660bc248875c7b810260 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-30 21:31:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:27:51 +0900 - - [ruby/yarp] fix: incomplete escape in regex at the end of file - - Previously this resulted in invalid memory access. - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/55b9dfb41c - -commit 7cebb9b737eddced828073453004720f9970be6a - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-30 12:03:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:27:51 +0900 - - [ruby/yarp] fix: incomplete escape in list at the end of file - - Previously this resulted in invalid memory access. - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/78ed75ed75 - -commit 46e47404a8734efd7f312e29e2fb705dd2f40291 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-30 11:40:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:27:50 +0900 - - [ruby/yarp] fix: trailing decimal, binary, octal, and hex numbers at end of file - - Previously this resulted in invalid memory access. - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/af5b85a27a - -commit c83552a596a34808651efca29a4f480bb5c579c6 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-30 11:30:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:27:49 +0900 - - [ruby/yarp] fix: trailing asterisk at end of file - - Previously this resulted in invalid memory access. - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/c86b4907b4 - -commit bd0268372e09eb45d088c44a534a5302bdca9796 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-30 06:01:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:27:49 +0900 - - [ruby/yarp] fix: trailing comment at end of file - - Previously this resulted in invalid memory access. - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/a1c9404906 - -commit 6f8126faebeddf8a93a7c0041c096bf584efcefb - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-30 04:38:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:27:48 +0900 - - [ruby/yarp] fix: string escape char "\" at the end of a file - - Previously this resulted in invalid memory access. - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/178862e2ca - -commit 476f38d62dd24caf80c586b642a25ede66b13fab - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-30 04:12:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:27:48 +0900 - - [ruby/yarp] fix: ":" at the end of a file - - Previously this resulted in invalid memory access. - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/c781c9fcd2 - -commit 3da139d28428d9889f6b6680400242f400e3175e - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-29 07:01:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:27:47 +0900 - - [ruby/yarp] fix: "$" at the end of a file - - Previously this resulted in invalid memory access as well as a - cascading failed assertion: - - src/enc/yp_unicode.c:2224: yp_utf_8_codepoint: Assertion `n >= 1' failed. - - Found by the fuzzer. - - https://github.com/ruby/yarp/commit/a34c534440 - -commit 440cdceffb7efef0aa93ad519b056a25d610f52d - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-30 05:36:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:27:47 +0900 - - [ruby/yarp] test: new test file for capturing interesting fuzzer snippets - - Note that we call `YARP.dump` for these fuzzer tests to better match - the fuzz.parse harness, which also serializes. - - https://github.com/ruby/yarp/commit/032ad047e9 - -commit f652c05a59506dfe931f23db4965f7e40033de5e - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-30 23:40:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 03:27:47 +0900 - - [ruby/yarp] debug: ensure valgrind will work when calling YARP.dump - - https://github.com/ruby/yarp/commit/deba3420d5 - -commit 1edb03788d27cf214365b849778a72c8c52c158f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-31 02:18:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-31 02:18:11 +0900 - - Stop using -v for rjit test-all - - It outputs way too many lines. It's hard to download the output from - GitHub Actions. - -commit c4998bc3f2f1978fbbe3f192f3d692523ee266d3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-29 21:38:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 01:51:17 +0900 - - [ruby/yarp] Desugar ||= more accurately - - Class variables, global variables, constants, and constant paths - should actually desugar to `defined?` instead of just reading the - value. - - https://github.com/ruby/yarp/commit/551a59b876 - -commit 06f54c9a8c3058883e4c42c5b0d3c6e498d2f3ad - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-31 01:43:56 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-31 01:43:56 +0900 - - Fix merge error on ruby_api_test.rb - -commit c5c0a3cf1772c9345373ecc4d7558f216b4ceb62 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-31 01:08:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 01:10:25 +0900 - - [ruby/yarp] Use assert_raise - - https://github.com/ruby/yarp/commit/b85e01d77d - -commit 9d8d2b81d21750774c60fd15b535a75ce61f04e7 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-08-31 00:42:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 01:10:25 +0900 - - [ruby/yarp] use a more idiomatic form of `assert_raises` - - https://github.com/ruby/yarp/commit/687213d2e3 - -commit c74039eec71b16c75965a36451ca14b18a81b278 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-31 00:38:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-31 00:38:27 +0900 - - use assert_raise - -commit e58fed128b737119e7e0f44292e8b0f0c8e691fb - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-31 00:14:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-31 00:14:51 +0900 - - YJIT: shrink Context from 29 to 21 bytes by reducing space used by TempMapping (#8321) - - * YJIT: merge tempmapping and temp types into a single-byte encoding - - YJIT: refactor to shrink Context by 8 bytes - - * Add tests, fix bug in TempMapping::map_to_local() - - * Update yjit/src/core.rs - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - * Update yjit/src/core.rs - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - * Fewer transmutes where `as` would suffice. Also repr(u8) - - * Update yjit/src/core.rs - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - * Update yjit/src/core.rs - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - * Update yjit/src/core.rs - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - --------- - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit c521b6f823154eeb6135881cec510fbff088b7ac - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-08-30 23:47:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-31 00:10:24 +0900 - - [ruby/yarp] add tests for `Location#join` - - https://github.com/ruby/yarp/commit/b01711396f - -commit 74f4d2683e22fe1507ff4a95648f53be86d90d41 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-26 23:51:34 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-30 22:18:10 +0900 - - sync_default_gems.rb: Remove Java templates - -commit 36a3899e9d464e243648694fa28398abbb4641ef - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-30 18:17:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-30 18:17:06 +0900 - - [ruby/irb] Bump version to 1.8.0 - (https://github.com/ruby/irb/pull/700) - - https://github.com/ruby/irb/commit/a061744ed3 - -commit bcc905100f1079e191632cfd02319c10af82dac0 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2022-09-20 23:10:56 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-08-30 17:07:18 +0900 - - BasicSocket#recv* return `nil` rather than an empty packet - - [Bug #19012] - - man recvmsg(2) states: - - > Return Value - > These calls return the number of bytes received, or -1 if an error occurred. - > The return value will be 0 when the peer has performed an orderly shutdown. - - Not too sure how one is supposed to make the difference between a packet of - size 0 and a closed connection. - - Notes: - Merged: https://github.com/ruby/ruby/pull/6407 - -commit acedbcb1b4eb6b362f11e783bff53c237d05afc6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-30 15:00:00 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-30 15:00:00 +0900 - - sync_default_gems.rb: Fix typo in replace_rdoc_ref_all - -commit c05737e09f1809715a672148258dd225cede331f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-30 14:59:17 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-30 14:59:17 +0900 - - sync_default_gems.rb: Transform by proc - -commit 2e648bfee4178399170437156af80d5f64ee96b9 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-08-29 21:32:34 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-08-30 12:47:09 +0900 - - [DOC] Detailed explanation when one line pattern matching is a void value expression - - Notes: - Merged: https://github.com/ruby/ruby/pull/8320 - -commit ad2a464e8fc6bd4daa5b20b3c69d94d52464a665 - Author: Soutaro Matsumoto <matsumoto@soutaro.com> - AuthorDate: 2023-08-30 11:10:41 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-30 11:10:41 +0900 - - Bundle RBS 3.2.1 (#8306) - - Notes: - Merged-By: soutaro <matsumoto@soutaro.com> - -commit e747e2c36b76262740da6070434a6768723397b2 - Author: Josh Nichols <josh@technicalpickles.com> - AuthorDate: 2023-08-30 08:01:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-30 09:36:38 +0900 - - [rubygems/rubygems] Update bundler/lib/bundler/settings.rb - - https://github.com/rubygems/rubygems/commit/75ffa8ef76 - - Co-authored-by: Martin Emde <martinemde@users.noreply.github.com> - -commit 6a876a61d7495ff64805cdda2756c5fc38846ef8 - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-29 09:02:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-30 09:36:38 +0900 - - [rubygems/rubygems] (Further) Improve Bundler::Settings#[] performance and memory usage - - I previously identified and improved this method over in https://github.com/rubygems/rubygems/pull/6884 - but while reviewing another memory_profiler profile, I realized another - gain we can eek out. - - This method keeps comes up in part because `configs` is allocating a new - Hash every time. My last change took advantage of that by using `map!` - on it. `configs` is called quite often, including in this `[]` method, - so there's a benefit to memoizing it. - - Back in `[]`, logically we are trying to find the first Hash in `configs` - that has a value for the given key. Currently, we end up `map` and - `compact` to just get that value. - - Instead, we can use a loop over `configs`, and break when we find the - value for the key. - - https://github.com/rubygems/rubygems/commit/b913cfc87b - -commit 3151d7876fac408ad7060b317ae7798263870daa - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-30 06:17:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-30 06:17:08 +0900 - - [YARP] Until Node, minor cleanup (#8325) - - * Remove conditional from yp_compile_if - - * Extracted yp_compile_while, compile UntilNode - - * Small checks for body / value that could be empty - -commit 80dc570a451ed493797fa68b59a8dd60c1fa51a6 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-30 05:13:15 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-30 05:13:15 +0900 - - Compile more YARP node types (#8322) - - * Add several more node simple types to YARP's compiler: - - Nodes include: DefinedNode, EmbeddedStatementsNode, - LocalVariableReadNode, LocalVariableWriteNode, MultiWriteNode, - OptionalParameterNode, SplatNode, YieldNode - - * Add AssocSplatNode, RangeNode - - * Add RangeNode, other helpers for future nodes - - * Add ArrayNode, HashNode, static literal helpers - - * Add branch conditionals - - * Add IfNode, UnlessNode - - * Add ScopeNode - - * NEW_ISEQ and NEW_CHILD_ISEQ implemented for YARP - - * Add nodes that depend on ScopeNode - - * Addressed PR comments - -commit b435161404ed960e02fadfd1c3d983d1fbfb91a0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-29 22:17:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-30 05:12:57 +0900 - - [ruby/yarp] Add instance variable names to the constant pool - - https://github.com/ruby/yarp/commit/f049932c44 - -commit 455153705c81fc1561317279da54daa5e5b479b3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-30 03:34:06 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-30 04:53:25 +0900 - - Tests for the YARP compiler - - Notes: - Merged: https://github.com/ruby/ruby/pull/8323 - -commit 5161c6c4cdf989ee63dbbe0baa81317f8e8ae491 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-28 22:06:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-30 04:33:31 +0900 - - [ruby/yarp] Statements inside ensure blocks can accept blocks - - https://github.com/ruby/yarp/commit/be84ea5343 - -commit 7a5df9d0ed7cbd0660803074b34623a1f1dc0768 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-29 10:31:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-30 04:31:36 +0900 - - [rubygems/rubygems] Fix bundle update --redownload - - It now does the redownloading/installing just like bundle install --redownload - - https://github.com/rubygems/rubygems/commit/3b058e5eca - -commit f37f357e808a7435f56946cd603a333feba7691b - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-30 03:08:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-30 03:36:16 +0900 - - [ruby/irb] Improve help/show_cmds message during debugger - integration - (https://github.com/ruby/irb/pull/693) - - * `help` should display debugger's help during irb:rdbg session - - * Update `show_cmds`'s output when in irb:rdbg session - - https://github.com/ruby/irb/commit/4029c2e564 - -commit c58561b5e3f597867a6e62f451a77ea27a6b9150 - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-08-30 02:50:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-30 02:55:02 +0900 - - [ruby/reline] Remove `ARGV.first` in east_asian_width.rb - (https://github.com/ruby/reline/pull/587) - - `ARGV.first` is the name of the EastAsianWidth file and is not needed for east_asian_width.rb - - https://github.com/ruby/reline/commit/6649bda31c - -commit 95efdef3b29bcf903bc3e11bed942bedf3ef95bb - Author: elfham <38372058+elfham@users.noreply.github.com> - AuthorDate: 2023-08-30 02:17:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-30 02:20:18 +0900 - - [ruby/reline] Set EastAsianWidth::UNICODE_VERSION - (https://github.com/ruby/reline/pull/586) - - * Set EastAsianWidth::UNICODE_VERSION - - * Commented out UNICODE_VERSION in Reline::Unicode::EastAsianWidth - - * Commented out UNICODE_VERSION in Reline::Unicode::EastAsianWidth - - https://github.com/ruby/reline/commit/6d94f2a26a - -commit 535045ab3b27dd42030e837bcd83b74ff075b84b - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-30 01:27:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-30 01:27:00 +0900 - - [YARP] Compile basic types (#8311) - - * Add a compile_context arg to yp_compile_node - - The compile_context will allow us to pass around the parser, and - the constants and lookup table (to be used in future commits). - - * Compile yp_program_node_t and yp_statements_node_t - - Add the compilation for program and statements node so that we can - successfully compile an empty program with YARP. - - * Helper functions for parsing numbers, strings, and symbols - - * Compile basic numeric / boolean node types in YARP - - * Compile StringNode and SymbolNodes in YARP - - * Compile several basic node types in YARP - - * Added error return for missing node - - Notes: - Merged-By: jemmaissroff - -commit 36e210718cc0242d3d1a043bd32b4618db592024 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-08-29 22:48:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-30 00:36:21 +0900 - - [ruby/yarp] simplify `context_pop` - - https://github.com/ruby/yarp/commit/fe85b595b6 - -commit 062eec75582dc0c813c945c2ce900e6ce0487610 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-08-30 00:34:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-30 00:34:49 +0900 - - [ruby/irb] Add --nomultiline indent and prompt test - (https://github.com/ruby/irb/pull/699) - - https://github.com/ruby/irb/commit/9b4aea753b - -commit 51e7fb533176abb53027729bcd52e77245757f10 - Author: Chad Schroeder <chadrschroeder@users.noreply.github.com> - AuthorDate: 2023-08-29 22:10:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-29 22:10:35 +0900 - - [ruby/irb] fixes https://github.com/ruby/irb/pull/524 - (https://github.com/ruby/irb/pull/696) - - https://github.com/ruby/irb/commit/59bcc07def - -commit 6ed1a504d49af09aac543ef39facaa11639add7e - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-29 21:54:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-29 21:54:25 +0900 - - [ruby/irb] irb:rdbg cleanups (https://github.com/ruby/irb/pull/697) - - * Remove unused method and constant from IRB::Debug - - * Update comments - - https://github.com/ruby/irb/commit/98914a963c - -commit 0cfb7796928f16f967fcf7b4d0a49fab6774001f - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-29 21:48:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-29 21:48:33 +0900 - - [ruby/irb] Fix test warnings (https://github.com/ruby/irb/pull/698) - - * Encoding should be saved before creating Irb objects - - * Fix unused local warning - - https://github.com/ruby/irb/commit/036ec31034 - -commit f0b43597ffbef0a43ca3459d8807bdc00ba4ec59 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-08-29 20:53:28 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-29 20:53:28 +0900 - - [DOC] Improved documentation. (#8319) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit cfae3ed42224b3e59cd6a02bf25a1d820e3b2b36 - Author: Petrik <petrik@deheus.net> - AuthorDate: 2023-08-29 19:37:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-29 19:48:28 +0900 - - Fix code example doc for Random.alphanumeric - - Notes: - Merged: https://github.com/ruby/ruby/pull/8317 - -commit 247fa3ca7666a5873a575ccfdb78c87753c2ad80 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-29 19:40:52 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-29 19:40:52 +0900 - - [DOC] Remove typo - -commit e46e48d690cf543193418ef08725cdbe31688975 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-08-29 19:24:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-29 19:24:55 +0900 - - Expose `rb_process_status_wait` and hide `rb_process_status_waitv`. (#8316) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 5ed42c980067d1e9970cfe2b5bc0527033e92a12 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-08-10 15:48:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-29 18:15:05 +0900 - - Development of 3.0.9 started. - -commit 0a219ef44af0cfb126799a7109c2e658172d7819 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-08-10 15:43:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-29 18:15:05 +0900 - - jruby: Add StringIO::VERSION (#59) - - Fixes GH-57 - -commit 13ed1d7b6012e006369a9074bdc070f1b6d57fc6 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-27 03:40:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-29 18:15:05 +0900 - - [ruby/yarp] Remove unnecessary NUL byte in string - - https://github.com/ruby/yarp/commit/af867e35b1 - -commit 221c2d0e19171f059461f8a8c3489cd9578ed43e - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-24 00:37:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-29 18:15:05 +0900 - - [ruby/irb] Print deprecation message for prompt_n methods - (https://github.com/ruby/irb/pull/691) - - They were removed in #685, but we should still keep them to avoid breaking - changes to tools like Chef. - - https://github.com/chef/chef/blob/533ff089479763f29045e4e6ddf388b73fc99338/lib/chef/shell.rb#L138 - - https://github.com/ruby/irb/commit/b585e0c835 - -commit 0cd92819c933ac3aea8eb173986b6478fcd1fbfe - Author: Summer ☀️ <4400771+smmr0@users.noreply.github.com> - AuthorDate: 2023-08-20 19:09:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-29 18:15:05 +0900 - - [ruby/irb] Remove unused `PROMPT_N` - (https://github.com/ruby/irb/pull/685) - - https://github.com/ruby/irb/commit/66e69fa0dc - -commit a28c5151f567cada0d2f5c0c3ec4df7f97b80784 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-08-29 14:49:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-29 18:00:44 +0900 - - Fix Array#bsearch when block returns a non-integer numeric value - - Notes: - Merged: https://github.com/ruby/ruby/pull/8314 - -commit f16c50772c97c9cbc2f9f1eb0087224a92c3c99b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-28 14:58:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-29 17:41:41 +0900 - - [rubygems/rubygems] rubocop -a - - https://github.com/rubygems/rubygems/commit/f240bfad2a - -commit 5e81127c1bb810734a410b3f5905e01ab6b37b3c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-29 17:41:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-29 17:41:26 +0900 - - Fixed broken -a option behavior - -commit 901b6d9c5025a30b3d7a5ed0a2c00baf9cfb061d - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-08-29 17:04:14 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-29 17:04:14 +0900 - - Validate the typed data before dereferencing the internal struct. (#8315) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 141102b0b08c4feb682210033cac8d0f042c4beb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-29 13:44:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-29 15:05:30 +0900 - - Expose Test.filter_backtrace for the default gems. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8313 - -commit 589cd0e511304be1419d4d7191eaf1063ef83fd5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-29 14:17:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-29 14:17:23 +0900 - - [DOC] Mention about https://bugs.ruby-lang.org/issues/19776 - -commit c0e913ae88057fed121d56f2057357b1e4c3b346 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-29 13:52:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-29 13:52:18 +0900 - - [DOC] Link method name references - -commit 7e5c662a6f2e8435f8103bc16185bed6759cc557 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-29 10:56:56 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-29 10:56:56 +0900 - - [Feature #18183] Add `chars:` option to `Random#alphanumeric` - -commit c4fc9477aa5f77a69a40b619b7144f2b118b772e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-29 10:20:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-29 10:20:52 +0900 - - sync_default_gems.rb: Continue if files added to the toplevel removed - -commit a6db6b150f2f37e05ea32fe6c13e4cf7a2f7838a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-28 17:47:30 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-29 09:22:28 +0900 - - sync_default_gems.rb: Split `sync_default_gems_with_commits` - -commit c02f978fd5653b5ca1959b6547c26a834ee1f043 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-08-28 22:04:10 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-08-29 08:26:18 +0900 - - Lrama v0.5.5 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8308 - -commit fd0df1f8c6845671c86eddd85c9bcced30501690 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-29 05:34:27 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-29 07:01:29 +0900 - - Fix growth in minor GC when we have initial slots - - If initial slots is set, then during a minor GC, if we have allocatable - pages but the heap is mostly full, then we will set `grow_heap` to true - since `total_slots` does not count allocatable pages so it will be less - than `init_slots`. This can cause `allocatable_pages` to grow to much - higher than desired since it will appear that the heap is mostly full. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8310 - -commit 5485680244bc40a9dba52e468fc5705973f2f5bd - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-29 05:33:28 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-29 07:01:29 +0900 - - Expose RVALUE_OLD_AGE in GC::INTERNAL_CONSTANTS - - Notes: - Merged: https://github.com/ruby/ruby/pull/8310 - -commit 85aa28e8a65b0b0691bf18f4af13adf080638035 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-29 04:29:46 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-08-29 06:14:33 +0900 - - RJIT: Remove Type::CArray and limit use of Type::CString - - See previous similar YJIT commit. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8299 - -commit 23c83d172c1e68a35e80548ea7efb64cc1c063b5 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-26 02:32:04 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-08-29 06:14:33 +0900 - - YJIT: Remove Type::CArray and limit use of Type::CString - - These types are essentially claims about what `RBASIC_CLASS(obj)` - returns. The field changes with singleton class creation, but we didn't - consider so previously and elided guards where we actually needed them. - - Found running ruby/spec with --yjit-verify-ctx. The assertion interface - makes extensive use of singleton classes. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8299 - -commit 3b815ed7da8261f45b84dcde2c900934f7379dac - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-29 05:55:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-29 05:55:58 +0900 - - Add yarp/yarp_compiler.c (#8042) - - * Add yarp/yarp_compiler.c as stencil for compiling YARP - - This commit adds yarp/yarp_compiler.c, and changes the sync script - to ensure that yarp/yarp_compiler.c will not get overwritten - - * [Misc #119772] Create and expose RubyVM::InstructionSequence.compile_yarp - - This commit creates the stencil for a compile_yarp function, which - we will continue to fill out. It allows us to check the output - of compiled YARP code against compiled code without using YARP. - - Notes: - Merged-By: jemmaissroff - -commit f726ad97406dc1c3bccfe74a53931552b9db755f - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-08-29 01:19:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-29 05:00:25 +0900 - - [ruby/yarp] use `memcmp` for block memory comparison - - https://github.com/ruby/yarp/commit/3563e5c5d5 - -commit 325240d0b6878612326cd182023c08ce2f092e36 - Author: Nathan Froyd <froydnj@gmail.com> - AuthorDate: 2023-08-29 03:13:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-29 05:00:15 +0900 - - [ruby/yarp] make `node.c` generated code more readable - - https://github.com/ruby/yarp/commit/0ffd61c87a - -commit 91de37c23ec6b048e45df79cef1cb93a86316929 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-27 08:31:46 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-29 04:05:19 +0900 - - Remove --disable-gems in assert_in_out_err - - assert_in_out_err adds --disable=gems so we don't need to add - --disable-gems in the args list. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8303 - -commit caf48487cafb8414c60f32b902decf0689ae2093 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-08-28 21:50:05 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-28 21:50:05 +0900 - - Restore `HAVE_RB_IO_T` macro for compatibility with `kgio`, `unicorn`, etc. (#8286) - - Notes: - Merged-By: nurse <naruse@airemix.jp> - -commit 9b87518ea0eff0c30c22db9c2394bb61db913646 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-28 05:43:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-28 21:37:31 +0900 - - [ruby/yarp] fix: %I list spanning a heredoc - - Similar to the previous %W fix, we accept a symbol node and - concatenate it onto an interpolated symbol. - - https://github.com/ruby/yarp/commit/6b5911b95e - -commit 29c5b851281da753ea0ae204afbd3f9010b466bc - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-28 05:40:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-28 21:37:30 +0900 - - [ruby/yarp] fix: %i list spanning a heredoc - - The fix here is similar to what we did in a previous commit for %w, to - accept two consecutive string tokens without a separator. - - https://github.com/ruby/yarp/commit/f869fbdbe5 - -commit 74812df4963b1ee56a015babf3798d48bae447c6 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-28 05:34:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-28 21:37:30 +0900 - - [ruby/yarp] fix: %W list spanning a heredoc - - Primarily this fix is to accept a string node and concatenate it onto - an interpolated string. - - https://github.com/ruby/yarp/commit/6df729fe72 - -commit 77e971b6ec93810842a8ef320e412174267dab6d - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-28 05:32:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-28 21:37:29 +0900 - - [ruby/yarp] fix: %w list spanning a heredoc - - Two fixes were necessary: - - - ensure we are handling newlines correctly - - accept two consecutive string tokens without a separator - - https://github.com/ruby/yarp/commit/4e707937cb - - Co-authored-by: Kevin Newton <kddnewton@gmail.com> - -commit 8926fd20f612aa6bae77844b8b6f5d14bf659cb1 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-28 05:19:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-28 21:37:28 +0900 - - [ruby/yarp] test: backfill tests for %q/%Q spanning a heredoc - - Also rename the fixture file - - https://github.com/ruby/yarp/commit/c148d955fd - -commit 2b9a05374032b3d287b91e6307d2817b6c962612 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-28 04:54:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-28 21:37:28 +0900 - - [ruby/yarp] fix: yp_interpolated_symbol_node_append - - Made this function's behavior match the interpolated_string - implementation. - - Previously, the start location was not set and left as 0. - - https://github.com/ruby/yarp/commit/87f348889f - -commit 06f5d8f3a04e147fd757f2ed15882592bb66e3a9 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-26 05:04:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-28 21:37:28 +0900 - - [ruby/yarp] Improve how we declare ripper exceptions in parse_test.rb - - Specific files are named earlier in the block, and we now have the - ability to skip just the lex matching, or skip ripper entirely (for - files that don't parse). - - https://github.com/ruby/yarp/commit/dcd3806dca - -commit 00439dbdb4909f0c78b37f6ed1e3f88c4cb05d46 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-26 10:31:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-28 17:52:50 +0900 - - sync_default_gems.rb: convert keys of REPOSITORIES to strings - - Referencing always after conversion to a symbol, and yielded gem name - is always converted to a string. - -commit 4963dd6b6432549b4685e31bf52b218a728cf50c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-28 17:14:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-28 17:14:58 +0900 - - Revert racc auto-sync support - - It's no longer a default gem actually. - Fixed the webhook side instead - https://github.com/ruby/git.ruby-lang.org/commit/3c27d860b4e39d10d63280b59d4db2cec518ae13. - -commit f5da7c379bc287a1e19200358c917ddc5628351e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-28 16:52:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-28 17:10:24 +0900 - - Ignore test/regress/ for racc - -commit 94275d96a86a411d632d1746a8c017bc7939a972 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-28 16:50:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-28 16:50:49 +0900 - - Add missing racc support to sync_default_gems - -commit 4221d9695dd71707f3d4e648c1ff397d2515a793 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-28 16:50:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-28 16:50:19 +0900 - - Sort repository names in sync_default_gems - -commit 23eb13d49daccd06e56d82884ac4bfd433f1b7be - Author: Imir Kiyamov <imir@MacBook-Pro-Imir-2.local> - AuthorDate: 2023-08-28 02:45:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-28 16:41:51 +0900 - - [rubygems/rubygems] Fixed malformed lockfile version on installing - - https://github.com/rubygems/rubygems/commit/c969a192bf - -commit b0ec1db8a72c530460abd9462ac75845362886bd - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-08-25 02:04:23 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-28 12:05:33 +0900 - - [ruby/openssl] ossl_pkey.c: Workaround: Decode with non-zero selections. - - This is a workaround for the decoding issue in ossl_pkey_read_generic(). - The issue happens in the case that a key management provider is different from - a decoding provider. - - Try all the non-zero selections in order, instead of selection 0 for OpenSSL 3 - to avoid the issue. - - https://github.com/ruby/openssl/commit/db688fa739 - -commit 69d9fda9f5b579c6992621f4cd165cd3ca7b4b3e - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-08-23 03:31:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-28 12:05:32 +0900 - - [ruby/openssl] Remove the pending logics by the pend_on_openssl_issue_21493. - - Because we will add a workaround to avoid this issue. - - https://github.com/ruby/openssl/commit/d157ba1d3b - -commit 80f35d96ae60fdf238ff62982094b4b4dbd13ecf - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-08-25 23:18:01 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-28 11:15:34 +0900 - - [rubygems/rubygems] Don't check for circular deps on full index sources - - https://github.com/rubygems/rubygems/commit/d275cdccb1 - -commit 2edf9fa23a78da59b5ff0d67a16037aecd38a00f - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-08-25 22:50:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-28 11:15:34 +0900 - - [rubygems/rubygems] Remove redundant checks - - https://github.com/rubygems/rubygems/commit/d66815633b - -commit 279dcfab7aea4474c6722fd39cbf65017edb4b2b - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-08-25 16:55:37 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-28 11:15:33 +0900 - - [rubygems/rubygems] Fix standalone install crashing when using legacy multi remote gemfiles - - If a legacy multi remote Gemfile depends transitively on a default gem, - then in standalone mode we'd fail to fetch the proper version from the - source that includes it, since we were adding it to `specs` (instead of - `remote_specs`), which was already including the default version of the - gem, and thus preventing the remote version from "overwriting that" and - being added to the index. We should add it to the `remote_specs` index - directly instead. - - https://github.com/rubygems/rubygems/commit/05f4f9dfc0 - -commit 7bf5f780281edc2fca83a0657e3a8d256e6e7065 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-08-22 06:05:57 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-28 11:15:32 +0900 - - [rubygems/rubygems] Refactor Fetcher#api_fetcher? and fetcher loading logic - - https://github.com/rubygems/rubygems/commit/f664d60114 - -commit 0c9d0684e1ab75277f8543db769dc7bdaccaa332 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-28 09:44:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-28 09:51:55 +0900 - - YARP: generated files from templates depend on config.yml - -commit 1cc700907d3ad3368272488a6f8960f2336bf26e - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-28 02:39:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-28 02:39:18 +0900 - - [DOC] More on method exec (#8302) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 5937d01f7f90d7cb30b25c5c942cbf948e46c9d6 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-28 00:56:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-28 01:18:15 +0900 - - [ruby/yarp] Rename constant pool fields to name or operator - - * `constant_id` and `operator_id` are confusing. - * See https://github.com/ruby/yarp/issues/1296 - - https://github.com/ruby/yarp/commit/09d0a144df - -commit 412e586afe1efd137872610a9ed6e93a45cf4c08 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-28 01:01:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-28 01:18:15 +0900 - - [ruby/yarp] Fix paths in library_symbols_test.rb - - https://github.com/ruby/yarp/commit/b5fba6d63f - -commit b7237e3bbd36e7c520c4cbaf1f866b6dcc265a99 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-22 03:13:24 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-27 22:39:29 +0900 - - Free all empty heap pages in Process.warmup - - This commit adds `free_empty_pages` which frees all empty heap pages and - moves the number of pages freed to the allocatable pages counter. This - is used in Process.warmup to improve performance because page - invalidation from copy-on-write is slower than allocating a new page. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8257 - -commit 5c98ee02d2ac7f20ab978be7645801adf03e4302 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-27 00:12:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-27 00:12:03 +0900 - - Define bounds-checking interfaces macro for each file - - Notes: - Merged: https://github.com/ruby/ruby/pull/8301 - -commit a97dedf761c6931cbb2b9267faad2395481a3f57 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-26 22:56:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 22:56:51 +0900 - - [ruby/irb] Fix deprecation test when ran multiple times - (https://github.com/ruby/irb/pull/695) - - https://github.com/ruby/irb/commit/ae0e5bb80f - -commit 9ea9f992487711fa1a66637edcaf1327d0cd5099 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-25 03:23:19 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-26 10:50:56 +0900 - - [Feature #19785] Deprecate RUBY_GC_HEAP_INIT_SLOTS - - This environment variable is replaced by - `RUBY_GC_HEAP_INIT_SIZE_%d_SLOTS`, so it doesn't make sense to keep it. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8147 - -commit e2b8eac767d41734520377b5cf6f4495b0444bc5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 09:17:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 09:20:44 +0900 - - [ruby/yarp] Bump to version 0.9.0 - - https://github.com/ruby/yarp/commit/b327e39527 - -commit b054c2fe06598f1141fdc337b10046f41f0e227c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-25 00:52:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-26 08:58:02 +0900 - - [Bug #19784] Fix behaviors against prefix with broken encoding - - - String#start_with? - - String#delete_prefix - - String#delete_prefix! - - Notes: - Merged: https://github.com/ruby/ruby/pull/8296 - -commit 808b06708884bf928b2e9c23ed5dcbbdf6665972 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-25 00:49:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-26 08:58:02 +0900 - - Split string tests - - Notes: - Merged: https://github.com/ruby/ruby/pull/8296 - -commit 00ac3a64ba57ecd8f10bf54f03297cdec0c538d6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-24 18:32:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-26 08:58:02 +0900 - - Introduce `at_char_boundary` function - - Notes: - Merged: https://github.com/ruby/ruby/pull/8296 - -commit cfdbbd67268a77177e485263cdd8fb416315e9a6 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-08-24 21:58:51 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-08-26 08:45:02 +0900 - - kw_rest_arg nd_cflag has not been used since 9720136 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8291 - -commit 96a809f621b742b6256545e85519002d0fd28a44 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-26 07:32:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-26 07:32:14 +0900 - - Use require_relative in JSON tests - - to prevent them from conflicting with yarp/test_helper - -commit 480aee4363d2bff26dcdd6b9280cf93ec0f1a06b - Author: Zack Deveau <zack.ref@gmail.com> - AuthorDate: 2023-08-26 07:27:56 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-26 07:27:56 +0900 - - Add Missing Counters to `rb_debug_counter_type` enum (#8297) - - Add missing counters to rb_debug_counter_type enum - - On master we have calls to the RB_DEBUG_COUNTER_INC macro - for counters that are not getting defined in the - rb_debug_counter_type enum. - - This commit adds those that are missing in order for - compilation to pass with -DUSE_RUBY_DEBUG_LOG. - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 00ec8dedb1fc0aff44ba3a37271ed30751cccadf - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 07:19:35 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-26 07:20:51 +0900 - - Update deps - - Notes: - Merged: https://github.com/ruby/ruby/pull/8298 - -commit 293959a7452cb69d4c80e94b243d84b4de702707 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 07:06:38 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-26 07:20:51 +0900 - - Remove config.h from targets necessary for YARP - - Notes: - Merged: https://github.com/ruby/ruby/pull/8298 - -commit ca9a44795b98f67cc3b51a59317c24dadb602bb5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 06:54:01 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-26 07:20:51 +0900 - - Remove version templating in YARP - - Notes: - Merged: https://github.com/ruby/ruby/pull/8298 - -commit aea7e9182835af4c9e1857038f03fc37a1474416 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 06:23:15 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-26 07:20:51 +0900 - - Fix sync script for YARP - - Notes: - Merged: https://github.com/ruby/ruby/pull/8298 - -commit b2d1c720ece67b110ab4ade6b8c9f3b640216c8a - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-08-26 06:59:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-26 06:59:45 +0900 - - Add documentation regarding how to build Ruby for debugging. (#8290) - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 439f069b4b421964dab39b0a01e0afdae89ea26c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-25 22:23:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 06:15:49 +0900 - - [ruby/yarp] Move tests from test/* to test/yarp/* to match CRuby - - This should make it easier on the sync to determine what changed - and hopefully result in fewer merge conflicts that have to be - manually resolved. - - https://github.com/ruby/yarp/commit/17d82afbfc - -commit 9b8602dd903b2515463a1a314cb8fdf735a354aa - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 04:22:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 06:10:19 +0900 - - [ruby/yarp] Introduce parse_lex instead of asking for a block - - https://github.com/ruby/yarp/commit/7e70339fe1 - -commit 76512d78fcde99458db211c0f958bd39cb23dd98 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 03:32:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 06:10:17 +0900 - - [ruby/yarp] Rename Location#to to Location#join, include checks - - https://github.com/ruby/yarp/commit/de8924e3ec - -commit 481388769407b533879e97510dc8160d094356e0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-23 23:53:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 06:10:17 +0900 - - [ruby/yarp] Accept a block to parse and parse_file to get lexer output as well - - https://github.com/ruby/yarp/commit/40fbf61a8d - -commit 0c1a749eef476045e0b098467a564e888ef03c47 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-23 02:26:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 06:10:16 +0900 - - [ruby/yarp] Fix nested multi assignment locations - - https://github.com/ruby/yarp/commit/9a65f002dc - -commit 20cf9e3ae8ef05d7fc44e2fda8c5b8233e8eb03e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-23 01:21:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 06:10:15 +0900 - - [ruby/yarp] Add a Location#to method for combining them - - https://github.com/ruby/yarp/commit/1db2de98ac - -commit 55a8add304cdc88a466d396588f1f2d0022f7c45 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-23 01:20:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 06:10:15 +0900 - - [ruby/yarp] Fix rational parsing - - https://github.com/ruby/yarp/commit/c8f31eb5b6 - -commit a31b069a8a0194ef589f0c81ff5da1b11374d7fd - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-22 10:12:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 06:10:13 +0900 - - [ruby/yarp] Track block opening and closing locations - - https://github.com/ruby/yarp/commit/7984e4ddc7 - -commit b9a2c96747cfac2bcc2883335b40f2a2d61d34cb - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-22 10:00:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 06:10:13 +0900 - - [ruby/yarp] Ensure interpolated symbols converted to regular symbols get opening and closing - - https://github.com/ruby/yarp/commit/386655d54f - -commit b112e89bb1de4019595647e62405e6b88902383e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-22 07:10:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 06:10:12 +0900 - - [ruby/yarp] Add closing_loc to WhileNode - - https://github.com/ruby/yarp/commit/b4132b876d - -commit df11a08d933bc0efa754ccb944d1c8997c56ee7d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-22 07:07:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 06:10:11 +0900 - - [ruby/yarp] Add closing_loc to UntilNode - - https://github.com/ruby/yarp/commit/4362cecc2c - -commit 74780c3e7f58e2c098f11f481c9ea0302a6a05de - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-22 06:56:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 06:10:10 +0900 - - [ruby/yarp] Call shorthand should not result in a message location - - https://github.com/ruby/yarp/commit/ad0f9d35e3 - -commit 85c8e8b9bd1c50c6affff019b8749271a64a9950 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 04:53:01 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-26 04:53:01 +0900 - - Fix VPATH for yarp/version.h - -commit 934552618e8b8a71b3910fdb35ee65f239379ce3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 04:48:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 04:48:51 +0900 - - [ruby/yarp] Fix relative require for version in YARP gemspec - - https://github.com/ruby/yarp/commit/ca8e8cfa0d - -commit a7c7cd11bc5c33173f3eeab8600819f84fe2d662 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 04:47:25 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-26 04:47:25 +0900 - - Update sync script to handle yarp/version.h - -commit 2e29bd6ce08bd52b15d94bc35bb443874565edb3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 04:43:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 04:43:49 +0900 - - [ruby/yarp] Use .rb suffix to find version file - - https://github.com/ruby/yarp/commit/7c530c79c2 - -commit d2392e1ce2b9fb113ca19cdcae2a2fe7f8a3c8ec - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 04:43:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 04:43:10 +0900 - - [ruby/yarp] Fix relative require in template script - - https://github.com/ruby/yarp/commit/dea9eb5a12 - -commit f603497105bd41c1863490a557ff105bf7e17830 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-21 23:27:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 04:37:17 +0900 - - [ruby/yarp] Use templating to avoid duplicating the YARP version in many places - - https://github.com/ruby/yarp/commit/9c359fd92e - -commit dd07b70253e958e547aff607d6a95a0bad77d56e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 04:33:14 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-26 04:33:14 +0900 - - Fix mutation visitor build for YARP templating - -commit 0df515c0959ec3b501132cf511a56f47d6f93682 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 02:03:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 04:31:33 +0900 - - [ruby/yarp] Mark local variable targets in pattern matching - - https://github.com/ruby/yarp/commit/6c6700a001 - -commit 7898b8e1ea01f3cc670543416d4d3ca90b3917aa - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 00:57:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 04:31:31 +0900 - - [ruby/yarp] Provide target node versions - - https://github.com/ruby/yarp/commit/a026564d38 - -commit aeef7091096ec8e6ad44e431610d966db7a2c33f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 00:53:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 04:31:31 +0900 - - [ruby/yarp] Split up parse_target and parse_write - - https://github.com/ruby/yarp/commit/75d8bb93ea - -commit 2ebaf077f61a078881a2c6f72355c69ba04f57e3 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 00:22:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 04:31:30 +0900 - - [ruby/yarp] Provide a desugar visitor - - https://github.com/ruby/yarp/commit/9fad513089 - -commit a38ca45b6570ab378890664c9e8683f0c16cdd78 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-25 23:49:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 04:31:28 +0900 - - [ruby/yarp] Split up AndWriteNode, OrWriteNode, OperatorWriteNode - - https://github.com/ruby/yarp/commit/6d3b3b5776 - -commit 649aba28f43534c729087238d01362a1f01bcc4a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-25 22:57:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 04:31:28 +0900 - - [ruby/yarp] Add Node#copy and MutationVisitor - - https://github.com/ruby/yarp/commit/3693091661 - -commit 3b9085ad24d774231d24716ef1f6ceb292174cc6 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-26 03:29:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 04:11:24 +0900 - - [ruby/yarp] Lambda params should not accept blocks - - https://github.com/ruby/yarp/commit/706daae0ac - -commit f84690c6e22a3941fed6887b837fb79ba5da5470 - Author: HParker <HParker@github.com> - AuthorDate: 2023-08-26 03:12:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 04:11:14 +0900 - - [ruby/yarp] ignore state on embexpr_end - - Ripper state can carry over from the previous node type making coparison less useful - - https://github.com/ruby/yarp/commit/74509728d4 - -commit 3525c460f9a916f8089cbeca65fc3e893ca5d633 - Author: Mike Dalessio <mike.dalessio@shopify.com> - AuthorDate: 2023-08-25 23:12:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 03:20:49 +0900 - - [ruby/yarp] fix: regexes and strings with escaped newline around a heredoc - - Found via the fuzzer. - - https://github.com/ruby/yarp/commit/501757135a - - Co-authored-by: Kevin Newton <kddnewton@gmail.com> - -commit bf3d48e18261595ac19057319f378bfd44928045 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-26 02:32:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 03:19:08 +0900 - - [ruby/yarp] Allow whitespace after "(en)coding" before ":", as in "encoding :" - - https://github.com/ruby/yarp/commit/d39a998182 - -commit 7d32011399cbc3aa7e4b728a440e13635a39f2ed - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-26 01:49:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-26 02:47:04 +0900 - - [Bug #19852] Use gem name without suffix - - Notes: - Merged: https://github.com/ruby/ruby/pull/8295 - -commit 40efbc7e406699a7a5c56802233d6748bf30805b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-26 00:51:39 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-26 02:08:53 +0900 - - [Bug #19851] Ripper: Hide internal block argument ID - - Notes: - Merged: https://github.com/ruby/ruby/pull/8293 - -commit 61c5c2f1c81b926beb20870615af5a738eb250bd - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-25 10:22:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-26 02:02:38 +0900 - - [ruby/yarp] Add names to classes and modules - - This should hopefully make it easier to compile these nodes, and - also for static analysis tools for having a quick label. - - https://github.com/ruby/yarp/commit/f086662144 - -commit fe73f9f24bd0f9c1f4059707a87c8588ca13a139 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-25 23:27:52 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-25 23:34:02 +0900 - - Replace only use of `snprintf` in parser - - Notes: - Merged: https://github.com/ruby/ruby/pull/8292 - -commit f5c8bdaa8ab1e42329c9877794fa5e3e936b2a55 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-25 04:26:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-25 22:01:21 +0900 - - Implement WeakKeyMap using weak references - - Notes: - Merged: https://github.com/ruby/ruby/pull/8113 - -commit ee9cc8e32e04597a4a86b391df2c19aed9fde3e5 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-25 04:26:10 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-25 22:01:21 +0900 - - Implement WeakMap using weak references - - Notes: - Merged: https://github.com/ruby/ruby/pull/8113 - -commit 2091bf94931bddcf23b196fc8fe108ebd7ec1648 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-24 23:48:39 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-25 22:01:21 +0900 - - Expose stats about weak references - - [Feature #19783] - - This commit adds stats about weak references to `GC.latest_gc_info`. - It adds the following two keys: - - - `weak_references_count`: number of weak references registered during - the last GC. - - `retained_weak_references_count`: number of weak references that - survived the last GC. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8113 - -commit bfb395c620b811b4b3cb7d535d58721268af285d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-25 03:21:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-25 22:01:21 +0900 - - Implement weak references in the GC - - [Feature #19783] - - This commit adds support for weak references in the GC through the - function `rb_gc_mark_weak`. Unlike strong references, weak references - does not mark the object, but rather lets the GC know that an object - refers to another one. If the child object is freed, the pointer from - the parent object is overwritten with `Qundef`. - - Co-Authored-By: Jean Boussier <byroot@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/8113 - -commit 633243958c1b19e7d934442e23ed3d7cc3d7691b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-24 23:42:04 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-25 22:01:21 +0900 - - Add _without_gc functions to darray - - These functions manipulate darray without the possibility of triggering - GC, which is used for places that cannot trigger GC. These functions - crash when the allocation fails. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8113 - -commit 7002d44c103fa2dfc4f4cd48ef1573fcd3a0dd73 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-25 22:00:04 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-25 22:00:04 +0900 - - Fix merge conflict in lib/yarp/lex_compat.rb - -commit ec7a2fdc03cba32894e1d25606195600e152c151 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-25 21:49:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 21:49:37 +0900 - - [ruby/yarp] Fix up lex compat on Ruby HEAD - - https://github.com/ruby/yarp/commit/7710cee248 - -commit b8cab92a3f1077abae7f5210b393fc4a1a909c28 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-25 13:17:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 21:39:13 +0900 - - [ruby/yarp] fix: unterminated regular expression with a heredoc - - Previously this snippet would track the same newline twice, leading to - a failed assertion in yp_newline_list_append. - - https://github.com/ruby/yarp/commit/1d3fe19a94 - -commit 90103f5d18df54f21af235e7e034db0dc473cfd0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-25 09:40:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 21:38:35 +0900 - - [ruby/yarp] Add the ability to serialize shared strings - - https://github.com/ruby/yarp/commit/8d18c7ae29 - -commit fe8f6dfed15333618f79ecf58944214f08c4f020 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-25 11:19:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-25 20:07:10 +0900 - - Remove yarp hack for BOM - - Notes: - Merged: https://github.com/ruby/ruby/pull/8281 - -commit 1f76e42b85be4031bdedcc3e457e8fa949195304 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-25 02:20:39 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-25 20:07:10 +0900 - - [Bug #19848] Flush BOM - - The token just after BOM needs to position at column 0, so that the - indentation matches closing line. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8281 - -commit 023b8ddd220f2451b51490ee2e48dedb211e2d1b - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-08-25 06:08:56 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-25 18:34:47 +0900 - - [rubygems/rubygems] Don't use full indexes unnecessarily on legacy Gemfiles - - On legacy Gemfiles with multiple remote sources, where all of them - support the compact index API, we were still falling back to full - indexes. - - Fixing this also allows to simplifying the code. - - https://github.com/rubygems/rubygems/commit/b1357c8e72 - -commit b5d03746359c1e316e0f69742353b2ea74230283 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-08-23 02:44:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-25 18:34:47 +0900 - - [ruby/openssl] Fix LIBRESSL_VERSION_NUMBER document mistake. - - * Fix the wrong man reference. - * According to the LIBRESSL_VERSION_NUMBER(3), the value always ends with 00f. - - ``` - $ man -M /home/jaruga/.local/libressl-6650dce/share/man/ 3 LIBRESSL_VERSION_NUMBER - ... - DESCRIPTION - OPENSSL_VERSION_NUMBER and LIBRESSL_VERSION_NUMBER are numeric release version - identifiers. The first two digits contain the major release number, the third and - fourth digits the minor release number, and the fifth and sixth digits the fix re‐ - lease number. For OpenSSL, the seventh and eight digits contain the patch release - number and the final digit is 0 for development, 1 to e for betas 1 to 14, or f - for release. For LibreSSL, OPENSSL_VERSION_NUMBER is always 0x020000000, and - LIBRESSL_VERSION_NUMBER always ends with 00f. - ``` - - https://github.com/ruby/openssl/commit/296c859d18 - -commit 503f98ebd386806fd434d8f41455e5ced3306301 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-25 17:09:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-25 18:23:05 +0900 - - Remove SCRIPT_LINES__ related member functions - - Notes: - Merged: https://github.com/ruby/ruby/pull/8289 - -commit 6aa16f9ec14a296f549dc955774ad2293d1c54d6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-25 16:53:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-25 18:23:05 +0900 - - Move SCRIPT_LINES__ away from parse.y - - Notes: - Merged: https://github.com/ruby/ruby/pull/8289 - -commit d9cba2fc74addc3e0a6da0fe230fd333fb1c31ac - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 16:06:53 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - include missing header - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit a736420ce560117e6f9491323b61608beb10f2cf - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 16:05:02 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - define back snprintf - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit 26cb3b56178d39b2b66ae795238b5834830f8f66 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 15:24:50 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - config.h has to be the very beginning - - This header defines several essential macros. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit 140daab5ac6bdba32036d17e12787dc241b5d61f - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 14:58:33 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - #include <stdarg.h> for va_list - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit fa327472caaa66a05ea0dcac2dd6cf58e30025e3 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 14:54:38 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - snprintf could be defined - - include/ruby/subst.h has `#define snprintf` which breaks here. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit 1614e5ebb2354603d5dca2a443a0bd669d21eda7 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 14:42:11 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - C structs cannot have two definitions - - Not allowed even the definitions are identical. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit 81620ed9b5553a80ea2c7d95b58c3217b1679459 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 14:39:44 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - needless duplicated typedef deleted - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit ddc5c204b21bb627fc25bda0f3aee28a0325a63e - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 14:37:05 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - VALUE is already defined - - This header is needed only when outside of the project - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit 197e91f35770959b5e8c9657c62f30664a1f4beb - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 14:28:15 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - build matrix for universal parser - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit 12ec1fb2b16be65f546151da85cbe842ca90dc3b - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 14:21:55 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - use configure-detected sanity of _Alignof - - This is actually already checked in (Ruby's) configure. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit fa54406f50c1c79a835e68cbc015ff7fc86ed92b - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 14:07:09 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - empty initializer is a C++ ism - - C99 does not allow this syntax. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit eec85a6309c189172bd5490ef87de5b8cdfc2ab6 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 14:06:56 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - tool/update-deps --fix - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit 097b766b41d4d2faac8e8649a2ac40abef920272 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 13:51:07 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - do not redefine a typedef - - duplicated typedef declaration was not allowed in C99. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit c914382db201bd1c4414fe3581d9da1af474ec18 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 13:47:10 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - do not redefine a typedef - - duplicated typedef declaration was not allowed in C99. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit fa2712981fc109368bf914e59577fcfdbf82379a - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 13:28:12 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - workaround clang-17 -Wc2x-extensions - - cf: https://github.com/llvm/llvm-project/commit/874217f99b99ab3c9026dc3b7bd84cd2beebde6e - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit b88bdf1ebba52a447a39c1fee815dd55bd48ff9e - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-25 12:19:13 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - direct use of CFLAGS - - Autoconf 2.71's `AC_PROG_CC` nukes `CC` variable, which we don't - want. For instance a user could specify `--with-gcc="gcc -std=c99"` - to _force_ C99 mode; but `AC_PROG_CC` just nulifies that `-std=c99` - part. - - `AC_PROG_CC` is called everywhere from inside of autoconf itself via - `AC_REQUIRE([AC_PROG_CC])`. It is not a wise idea to try avoiding - this macro at all. We need to reroute `-std=` flags to somewhere - else. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit eb57b6ba822f7027c215efe3543160d86be7fc5c - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-08-24 13:44:34 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-08-25 17:27:53 +0900 - - [CI]: LLVM 18 begun - - Notes: - Merged: https://github.com/ruby/ruby/pull/8274 - -commit f7359e112a2834e7360dcee3836508d2031b7e72 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-25 15:53:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-25 15:57:53 +0900 - - Suggest to add bundled gems into gemspec if 3rd party gem try to load gem from Gem::BUNDLED_GEMS::SINCE - - [Feature #19846] - -commit 70272ca65c59f787e48c219c8946b22ce310fef0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-25 13:10:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-25 13:11:06 +0900 - - Warn for bigdecimal.so case too - -commit 3a70afad32f183daa8b3ddc36cb75b27e47ef623 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-25 12:56:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-25 12:56:47 +0900 - - prime is bundled gems since Ruby 3.1.0. We should warn it under the bundler environment - -commit 28b2cb10d5e6ffb2bfb5ecc4ca472a4849b2c1b3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-25 12:52:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-25 12:52:10 +0900 - - We should also warn when loading 'bigdecimal/*' libraries - -commit bdd535eac6b7dbfae4697f4e965e8b07978322bf - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-25 12:33:23 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-25 12:52:10 +0900 - - Decorate Hash syntax for Gem::BUNDLED_GEMS::EXACT - -commit b635388a900206b673fc23b5442345236b84cd75 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-08-25 05:44:03 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-08-25 12:47:23 +0900 - - Check that __builtin_mul_overflow can handle long long - - Fixes [Bug #17646] - - Patch from xtkoba (Tee KOBAYASHI) - - Notes: - Merged: https://github.com/ruby/ruby/pull/8288 - -commit eb5eeb6f19b5e72162fa0f56ae12217112c3f21d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-25 10:46:33 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-25 10:48:04 +0900 - - [DOC] Fix link in NEWS.md - - I forgot to commit the second part in - 775df74feb597555f0944ace2d59d10a24d4421e. - -commit 6f1dfa7411324588360022d9f56c581c122e68ac - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-25 10:46:06 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-25 10:46:06 +0900 - - Resurrect srcs dependency for YARP templates (#8285) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 775df74feb597555f0944ace2d59d10a24d4421e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-25 10:45:34 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-25 10:45:34 +0900 - - [DOC] Fix link in NEWS.md - -commit 40d774bec68de3f252c0b252d9d0303a67bee0cb - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-08-25 10:28:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-25 10:28:33 +0900 - - Avoid memory dependency between instructions. (#8284) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 97a97d6d6cb68516555000b650cd69715587e53b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-25 07:05:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-25 07:05:04 +0900 - - mv test/bom_test.rb test/yarp/ - - This sync 0e3dc5a056abf51363070ad94de4a8097bc80197 wasn't successful. - -commit f9aea75747c64af69eecee666a824827e77d9acf - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-25 06:41:43 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-25 06:41:43 +0900 - - [DOC] RDoc for Process (#8282) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit ebb9034710f2f0e9ce27b451daa1cd279232de5c - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-25 06:32:45 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-08-25 06:37:07 +0900 - - Remove cfp parameter from hook_before_rewind() - - It's only used once, and it has to equal `ec->cfp`, so just use that. - -commit 05e827427f8eaf3958ba8d29c96ae1125e06fbe0 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-25 03:40:52 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-08-25 06:37:07 +0900 - - Make cfp constant and use it more in vm_exec_handle_exception() - - For writing THROW_DATA_VAL, being able to see that it's writing to the - same frame after modifying PC and SP is nice. - -commit 5937a0da80e2b41435c1b26a83e4f065bed4bd02 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-25 04:49:03 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-08-25 06:35:10 +0900 - - YJIT: Refactor to use Option<BlockHandler> in SpecVal - - We pass block around as `Option<BlockHandler>` having SpecVal - match that simplifes code matching for the `None` case. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8271 - -commit f61e620c4d68abeef1a220d7414d741bf3f981a8 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-24 08:07:30 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-08-25 06:35:10 +0900 - - YJIT: Move block handler SpecVal variants into BlockHandler - - A refactor so that the variants correspond to - branches in vm_caller_setup_arg_block(). - - Notes: - Merged: https://github.com/ruby/ruby/pull/8271 - -commit 0e3dc5a056abf51363070ad94de4a8097bc80197 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-25 00:09:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 06:30:01 +0900 - - [ruby/yarp] Fix lex compat with BOM - - * BOM should not impact looking for the encoding string - * We should re-encode tokens when the encoding changes - * BOM should change the column of comments only - - https://github.com/ruby/yarp/commit/119fc2d7b2 - -commit 90048241cad97573d830e86222ca4826a32da13e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-25 04:18:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 04:27:22 +0900 - - [ruby/yarp] A couple small stylistic updates for yp_scope_node - - * Ensure the node gets initialized in case of failure with no assertions - * Include lambda and top-level nodes for scopes - * Small indentation fixes - - https://github.com/ruby/yarp/commit/be29e07391 - -commit 90ff30e51e877b292e156f771e30a76876101387 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-25 03:40:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 04:06:02 +0900 - - [ruby/yarp] Requested changes - - https://github.com/ruby/yarp/commit/eb01ea17c1 - -commit 82d84d741eed6aab81323e42439a81dd7d0cecd2 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-25 03:26:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 04:06:01 +0900 - - [ruby/yarp] Added BlockNode case to ScopeNode, fixed ScopeNode to have body - - https://github.com/ruby/yarp/commit/8bd3f59621 - -commit ef82054bb5e74fcaf3ef6c803246f93b57e88c3d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-24 04:37:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 04:06:01 +0900 - - [ruby/yarp] Added ModuleNode - - https://github.com/ruby/yarp/commit/29754d818b - -commit 82e1434ef65cf1eead1e9828d12e2ed1a29de0fa - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-24 02:30:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 04:06:00 +0900 - - [ruby/yarp] Pulled scope node out of config.yml, added necessary void returns - - https://github.com/ruby/yarp/commit/926e6bdd88 - -commit d81634d3ef21b5b8072934a1e00f431e42cbce8a - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-09 01:48:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 04:06:00 +0900 - - [ruby/yarp] Add a ScopeNode and a way to create scope nodes from existing nodes - - This commit creates a scope node, and exposes a method to get - ScopeNodes from other existing nodes. It still has TODOs around - creating ScopeNodes for other types of nodes, which will be - done in future commits. - - https://github.com/ruby/yarp/commit/3b9ac5764d - -commit 75c9c2c4314bbce4a27c761e592d7db509039d79 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-25 02:46:14 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-25 02:46:14 +0900 - - [DOC] Process doc (#8279) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 58ca0cfa0714f501fd7aced2f91b5deaafaf0602 - Author: HParker <HParker@github.com> - AuthorDate: 2023-08-24 07:08:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 01:05:50 +0900 - - [ruby/yarp] Fix backslash-r (CR) delimited strings - - now CR can be used as a string delimiter - - https://github.com/ruby/yarp/commit/3d27bad797 - -commit 791d572ba8993a8be2c7e3f85c29c8f65c83fc03 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-24 23:22:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 01:05:37 +0900 - - [ruby/yarp] A couple of small stylistic changes - - * `le_len` to `eol_length` - * Braces on the same line as switch case - * `peek_addr` -> `peek_at` - * `peek_at` -> `peek_offset` - * `match_line_ending_addr` -> `match_eol_at` - * `match_line_ending_at` -> `match_eol_offset` - - https://github.com/ruby/yarp/commit/d7ffa9e64e - -commit 432702a427c167b09deb616aa4d5dd393dd1963b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-24 04:48:24 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-25 00:56:16 +0900 - - [ruby/yarp] Encoding-dependent escapes - - https://github.com/ruby/yarp/commit/36a5b801c4 - -commit 9aba46c6666350eb585926dd89bafab700ee560e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-25 00:56:09 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-25 00:56:09 +0900 - - Sync YARP to c175f712522cc315f45cd2da308768b90f324dd0 - -commit e1d7066a5f612c3f6977443d2b574dab67041ad6 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-25 00:35:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-25 00:35:40 +0900 - - [ruby/irb] Deprecate RubyLex and warn about referencing to it - (https://github.com/ruby/irb/pull/692) - - `RubyLex` has always been a private component of IRB, so we should - explicitly discourage usages of it. - Also, it should be placed under the `IRB` module like other components. - - https://github.com/ruby/irb/commit/069b5625f7 - -commit 20927a89c27948be866a5667117326ea02690a7c - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-24 00:39:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-24 22:45:29 +0900 - - [ruby/yarp] Improve handling of line endings - - Introduce three new inline helper functions: - - - `match_line_ending` - - `match_line_ending_at` - - `match_line_ending_addr` - - These functions are similar in signature to the `peek*` functions, but - return the length of the line ending being inspected (or 0 if no line - ending was found). - - These functions are then used to simplify how we're detecting line - endings throughout "src/yarp.c". - - Also: - - test coverage backfilled for `__END__` comments with CRLF line endings. - - error message for invalid `%` tokens updated to not include - the potential line endings. - - some small refactorings for readability along the way - - https://github.com/ruby/yarp/commit/a00067386d - -commit 5ec1fc52c1640c75899972ad99734ff22a90694a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-24 19:10:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-24 21:12:51 +0900 - - Escape non-ascii characters in prelude C comments - - Non-ASCII code are often warned by localized compilers. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8276 - -commit 554b370b7273b0aab70c302aee7491ba32f63794 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-24 19:48:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-24 21:12:51 +0900 - - Generate sources before checks - - Notes: - Merged: https://github.com/ruby/ruby/pull/8276 - -commit 84a12d657848dfb54f8cc556d344f017a793e95a - Author: Bo Anderson <mail@boanderson.me> - AuthorDate: 2023-08-22 02:02:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-24 19:09:06 +0900 - - Fix compile error on older systems without clock_get* - - Notes: - Merged: https://github.com/ruby/ruby/pull/8256 - -commit fbe7962b54096d52d15d31756db80cf5cca5ea98 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-24 14:08:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-24 14:14:56 +0900 - - [ruby/open-uri] Close leaked files - - https://github.com/ruby/open-uri/commit/c52ee9e430 - -commit 7e0d2c614341521a958f84adbeca738c6824f222 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-24 12:21:44 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-24 12:21:44 +0900 - - [DOC] RDoc for Process (#8253) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit d4c720a91bc7bb9ff31810e1720acffb939f7a2f - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-08-24 12:19:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-24 12:19:33 +0900 - - Fix support for dynamic keys. (#8273) - - * Skip RBS test. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit bd22bb259c183b91656bea72899fe91c31aeb44e - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-08-24 02:56:39 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-08-24 08:46:20 +0900 - - Handle Array#* raising ArgumentError in test - - Treat ArgumentError as NoMemoryError, so it will resize the array - and try again. - - Fixes [Bug #12500] - - Notes: - Merged: https://github.com/ruby/ruby/pull/8270 - -commit ce79887da0410f8b5afb16930da5635a8b632b5d - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-08-23 18:25:41 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-08-24 07:47:52 +0900 - - The first arg of NEW_KW_ARG macro is always 0 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8267 - -commit 2214bcb70d9f9120f1f3790ca340236c8f080991 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-24 06:37:16 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-08-24 07:07:49 +0900 - - Fix premature string collection during append - - Previously, the following crashed due to use-after-free - with AArch64 Alpine Linux 3.18.3 (aarch64-linux-musl): - - ```ruby - str = 'a' * (32*1024*1024) - p({z: str}) - ``` - - 32 MiB is the default for `GC_MALLOC_LIMIT_MAX`, and the crash - could be dodged by setting `RUBY_GC_MALLOC_LIMIT_MAX` to large values. - Under a debugger, one can see the `str2` of rb_str_buf_append() - getting prematurely collected while str_buf_cat4() allocates capacity. - - Add GC guards so the buffer of `str2` lives across the GC run - initiated in str_buf_cat4(). - - [Bug #19792] - -commit d7f1ea71555c4d359de529b6058e4338ae247063 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-24 06:30:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-24 06:32:26 +0900 - - Quarantine a very flaky spec - - https://github.com/ruby/ruby/actions/runs/5956398507/job/16157091112 - - This has been extremely flaky on macOS GitHub Actions. - Benoit suggested to quarantine it if it's too problematic (it is) and - there's no reasonable fix in a short time (it already took too long). - So this commit follows the suggestion. - - We should remove revert this once rb_cloexec_open() is fixed. - -commit 43c2c1ed4814c6e1f0d0d0ec88641e12bf5aa290 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-05-10 12:11:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-24 06:30:16 +0900 - - [ruby/open-uri] Make URI.open pass keywords - - Fixes [Bug #19238] - - https://github.com/ruby/open-uri/commit/f636d01b85 - -commit 544488f1145080e54424e1c8ac28795f37502302 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-24 06:22:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-24 06:22:47 +0900 - - Improve comments in sync_default_gems - -commit cdbc70d088c909fb5b554a8f764f09ebc3720634 - Author: HParker <HParker@github.com> - AuthorDate: 2023-08-23 02:53:39 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-24 06:16:12 +0900 - - [ruby/yarp] Match EOF after newline behavior - - in Ripper EOL after whitespace is returned as a on_nl node with the whitespace as the content - - k0kubun: This is a resync of 9aca3528aa1a1545468a508b02b77bc922bb7321. - git.ruby-lang.org had an old git version and the diff was wrong. - It now has a newer git, so this should succeed next time. - - https://github.com/ruby/yarp/commit/be16d1deed - -commit 455297d652829c9c6f68bc4224588967f41191f7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-24 05:56:48 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-24 05:56:49 +0900 - - Use https for remotes by default - - I was testing this script on git.ruby-lang.org to use its git version, - but it did not work because the server's default user doesn't have SSH - keys. - - https works for everyone, so it's a safer default. You shouldn't need to - push to that remote from ruby/ruby anyway. - -commit c6a07cc33fee26b03afa20d3e94e9332e09a2d07 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-24 05:43:46 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-24 05:43:47 +0900 - - Ignore more files for other gems as well - - e.g. bin/ for reline that was included in its last commit. - -commit eb795b0325c96c88e05f765d7ea015b220471a93 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-24 05:35:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-24 05:35:41 +0900 - - Avoid sync rule duplication between YARP and others - -commit f33c412ebcaac622a3b5b5ff38ec46bd13187578 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-24 03:09:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-24 03:29:25 +0900 - - [ruby/yarp] Constant paths followed by an & should be lexed as a call - - https://github.com/ruby/yarp/commit/b0a2ba2c4d - -commit cedb333063694f2ac87baeb5c49a81c26e0ddebf - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-08-22 14:46:03 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-08-24 03:20:17 +0900 - - Stop incrementing `jit_entry_calls` once threshold is hit - - Otherwise the ISeq page will constantly be written - into preventing it from being shared. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8259 - -commit 24bcd494735fe88537851ea096e6b14104f9032f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-24 02:48:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-24 03:06:49 +0900 - - [ruby/yarp] Fix first method param lex failures - - When Ripper encounters a method parameter that is the first - parameter and is an identifier and it shadows a local scope, it - incorrectly marks it as END|LABEL (because it think it's a local). - - We need to account for that in the lex compat in order to properly - compare. - - https://github.com/ruby/yarp/commit/15f725a1b1 - -commit 9aca3528aa1a1545468a508b02b77bc922bb7321 - Author: HParker <HParker@github.com> - AuthorDate: 2023-08-23 02:53:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-24 02:23:15 +0900 - - [ruby/yarp] Match EOF after newline behavior - - in Ripper EOL after whitespace is returned as a on_nl node with the whitespace as the content - - https://github.com/ruby/yarp/commit/be16d1deed - -commit 774845284fafd231be2208576da6669383f25998 - Author: Rafael Mendonça França <rafael@franca.dev> - AuthorDate: 2023-08-24 01:54:07 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-08-24 02:20:55 +0900 - - Change yjit stats list to be a unordered list - - Without using a list, this show as a single paragraph with all stats descriptions being in one single line - - Notes: - Merged: https://github.com/ruby/ruby/pull/8268 - -commit c837e1adfbcdf4d4df65f62d63c51c1111114b5f - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-21 10:05:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-24 01:07:37 +0900 - - [ruby/yarp] Add LABEL lex state when lexing a keyword params - - https://github.com/ruby/yarp/commit/422bcd0ebf - -commit 9c43ec621d72a7f98352f88b7fb27e0c599e1b7b - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-24 00:07:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-24 00:42:20 +0900 - - [ruby/yarp] fix: newline tracking for a comment at EOF - - https://github.com/ruby/yarp/commit/62fb0bddf5 - -commit 8f0a8e579da41c767e70628e7864e6bdf1631088 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-23 22:29:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-24 00:40:21 +0900 - - [ruby/yarp] Remove unnecessary loop - - https://github.com/ruby/yarp/commit/86e8741ee3 - -commit b4bc047f2f20d84ffce0ab3a4c7f5c5e9f6eb0b7 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-24 00:10:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-24 00:10:52 +0900 - - YJIT: Implement VM_CALL_ARGS_BLOCKARG with Proc for ISeq calls - - Rack uses this. Speculate that the `obj` in `the_call(&obj)` - will be a proc when the compile-time sample is a proc. - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/8117 - - Merged-By: XrXr - -commit f902df128dea9044c226ed88306fca4d3a26f623 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-23 06:59:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-24 00:08:35 +0900 - - [ruby/yarp] refactor: extract `peek_addr()` - - In many places in the code we use the idiom: - - x < parser->end && *x == 'y' - - which is essentially an extension of an existing pattern: - - - `peek()` looks at `parser->current.end` - - `peek_at()` looks at `(parser->current.end + offset)` - - This commit introduces a new inline function, `peek_addr`, which - accepts a pointer and encapsulates the address value check and - conditional dereferencing. The result is more readable code, and more - ubiquitous safety checks on pointer values, allowing us to rewrite the - above as: - - peek_addr(parser, x) == 'y' - - Also: - - - change the type of `peek_at()`'s offset argument from `size_t` to - `ptrdiff_t` so that it can accept negative offsets. - - use `current_token_starts_line` in one place where the equivalent - code is inline. - - use `peek` or `peek_at` to replace inline code in a few places - - These changes simplify the code and make it easier to visually spot - patterns, particularly around line-endings (which will be a subject of - a future pull request). - - https://github.com/ruby/yarp/commit/4c608d53ea - -commit 58c1ebb634c8469026e1bdd0f7e65bfe72b9d9fc - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-08-23 23:34:03 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-23 23:34:03 +0900 - - Fix guard-heap upgrades (#8264) - - * Fix guard-heap upgrades - - `getinstancevariable` was generating more heap guards than I thought. - It turns out that the upgrade code has a bug in it. - - Given the following Ruby code: - - ```ruby - class Foo - def initialize - @a = 1 - @b = 1 - end - - def foo - [@a, @b] - end - end - - foo = Foo.new - 10.times { foo.foo } - - puts RubyVM::YJIT.disasm Foo.instance_method(:foo) - ``` - - Before this commit, the machine code was like this: - - ``` - == BLOCK 1/4, ISEQ RANGE [0,3), 36 bytes ====================== - # Insn: 0000 getinstancevariable (stack_size: 0) - 0x5562fb831023: mov rax, qword ptr [r13 + 0x18] - # guard object is heap - 0x5562fb831027: test al, 7 - 0x5562fb83102a: jne 0x5562fb833080 - 0x5562fb831030: test rax, rax - 0x5562fb831033: je 0x5562fb833080 - # guard shape - 0x5562fb831039: cmp dword ptr [rax + 4], 0x18 - 0x5562fb83103d: jne 0x5562fb833062 - # reg_temps: 00000000 -> 00000001 - 0x5562fb831043: mov rsi, qword ptr [rax + 0x10] - - == BLOCK 2/4, ISEQ RANGE [3,6), 0 bytes ======================= - == BLOCK 3/4, ISEQ RANGE [3,6), 36 bytes ====================== - # regenerate_branch - # Insn: 0003 getinstancevariable (stack_size: 1) - # regenerate_branch - 0x5562fb831047: mov rax, qword ptr [r13 + 0x18] - # guard object is heap - 0x5562fb83104b: test al, 7 - 0x5562fb83104e: jne 0x5562fb8330db - 0x5562fb831054: test rax, rax - 0x5562fb831057: je 0x5562fb8330db - # guard shape - 0x5562fb83105d: cmp dword ptr [rax + 4], 0x18 - 0x5562fb831061: jne 0x5562fb8330ba - # reg_temps: 00000001 -> 00000011 - 0x5562fb831067: mov rdi, qword ptr [rax + 0x18] - ``` - - After this commit, the machine code has fewer guards for `self`: - - ``` - == BLOCK 1/4, ISEQ RANGE [0,3), 36 bytes ====================== - # Insn: 0000 getinstancevariable (stack_size: 0) - 0x55cb5db5f023: mov rax, qword ptr [r13 + 0x18] - # guard object is heap - 0x55cb5db5f027: test al, 7 - 0x55cb5db5f02a: jne 0x55cb5db61080 - 0x55cb5db5f030: test rax, rax - 0x55cb5db5f033: je 0x55cb5db61080 - # guard shape - 0x55cb5db5f039: cmp dword ptr [rax + 4], 0x18 - 0x55cb5db5f03d: jne 0x55cb5db61062 - # reg_temps: 00000000 -> 00000001 - 0x55cb5db5f043: mov rsi, qword ptr [rax + 0x10] - - == BLOCK 2/4, ISEQ RANGE [3,6), 0 bytes ======================= - == BLOCK 3/4, ISEQ RANGE [3,6), 18 bytes ====================== - # regenerate_branch - # Insn: 0003 getinstancevariable (stack_size: 1) - # regenerate_branch - 0x55cb5db5f047: mov rax, qword ptr [r13 + 0x18] - # guard shape - 0x55cb5db5f04b: cmp dword ptr [rax + 4], 0x18 - 0x55cb5db5f04f: jne 0x55cb5db610ba - # reg_temps: 00000001 -> 00000011 - 0x55cb5db5f055: mov rdi, qword ptr [rax + 0x18] - ``` - - Co-Authored-By: Takashi Kokubun <takashikkbn@gmail.com> - - * Fix array/string guards as well - - --------- - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 448ff162c49bb5b27060d4551c5ded6ba768b5dd - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-23 23:09:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-23 23:09:24 +0900 - - [DOC] Adding font usage to doc guide (#8255) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 129663c4a8e1522a862a26b99e997854186bafac - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-22 18:11:00 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-23 19:40:56 +0900 - - tool/lib/output.rb: Make `--color` option like GNU coreutils - -commit de4a1ca792996a682dc2fcf83093dd002a731a5e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-13 00:38:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-23 19:40:56 +0900 - - tool/lib/output.rb: Add `--create-only` and `--overwrite` options - -commit f1c6da65f4bcb3f3ed743aa2b763e236133a85c7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-13 00:38:14 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-23 19:40:55 +0900 - - tool/lib/output.rb: Add `--no-color` option - -commit e89150b1d403ebc6ced457561424a16ab59ea4ef - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-23 13:56:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-23 13:56:51 +0900 - - Render YARP templates into the build directory (#8266) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 347993e95c4604d6c9460b64bb28c9b4f442531c - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-08-23 07:14:37 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-08-23 13:45:20 +0900 - - Call ruby_init_setproctitle before process_options - - Fixes [Bug #11269] - - Notes: - Merged: https://github.com/ruby/ruby/pull/8265 - -commit b92d599eec432eb6c83d1d2b13109924aebd0ac7 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-08-02 03:20:05 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-23 13:09:18 +0900 - - Fix typo in anonymous class string - - If anonymous was shorted it should be `anon` not `annon`. Fixes typo in - APPEND_S for anonymous classes. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8154 - -commit 00054de6b5ca65f87ca561f31daeb094442638fc - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-08-22 18:24:14 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-08-23 07:59:54 +0900 - - Remove nd_entry from NODE_GASGN and NODE_GVAR - - After a0f12a0258e4020bd657ee80b7d8f22bd33ea223 NODE_GASGN and - NODE_GVAR hold same value on both nd_vid and nd_entry. - This commit stops setting value to nd_entry and makes to use only - nd_vid. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8261 - -commit ff552389137c2d0af16c63e82bfc7e123be30198 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-23 07:43:56 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-23 07:43:56 +0900 - - YJIT: x64: Split mem-to-mem Insn::Store like Insn::Mov - - The ARM backend allows for this so let's make x64 consistent. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8263 - - Merged-By: XrXr - -commit c23e2e19b7a5e4b919a8b87de0269c128bbb9a5e - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-23 06:36:12 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-23 06:36:12 +0900 - - YJIT: add code_region_overhead stat output (#8262) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 2d75069779fd1e9fe94b2e4da5e269641daddf0f - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-22 23:14:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-23 06:19:09 +0900 - - [ruby/yarp] Use require_relative for yarp/ffi - - https://github.com/ruby/yarp/commit/c0598f8805 - -commit 837c12b0c8711e593bfe0235f4fec2e8cf10bd75 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-23 05:31:36 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-23 05:31:36 +0900 - - Use STR_EMBED_P instead of testing STR_NOEMBED - -commit 9b373fb428872f6d17530b22ea40cc9083d17e18 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-23 02:17:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-23 03:04:59 +0900 - - [ruby/yarp] Fix small typo in templating to specify where template comes from - - https://github.com/ruby/yarp/commit/96d69ceef6 - -commit 7127f39bacbdc5dded044360f676e461ec124508 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-22 18:13:09 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-22 23:46:32 +0900 - - Add notes and name a magic number - -commit 0ed3624c626a2426ec79929a8c579eb398d6160a - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-08-22 18:02:21 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-08-22 20:01:25 +0900 - - Wrap nd_head in node dump message with brackets - - Notes: - Merged: https://github.com/ruby/ruby/pull/8260 - -commit 1c93288f8bbf667cb95eb7137b2fe64213894b77 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-22 14:35:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-22 14:35:25 +0900 - - Added bigdecimal to warning targets for the bundled gems. - - [Bug #19843] - -commit eec7a3f9ee0a40f4f5e22e0131c3acd486f31b14 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-22 13:42:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-22 13:45:55 +0900 - - [ruby/erb] Version 4.0.3 - - https://github.com/ruby/erb/commit/c594f2fb86 - -commit be889b6d6c3b919dc6a762c7cf0853b8d019cf55 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-22 13:45:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-22 13:45:33 +0900 - - Add a forgotten default value for ignored_paths - -commit 0955ca342ed01b61161e1a46015a58b54d2e7205 - Author: Josh Nichols <josh@technicalpickles.com> - AuthorDate: 2023-08-22 13:41:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-22 13:41:22 +0900 - - [ruby/erb] Enable frozen_string_literal in all files - (https://github.com/ruby/erb/pull/49) - - I was surprised to see erb show up when I was using memory_profiler on - my app. ERB::Compiler#compile has a blank string literal, and it - ended up allocating some 41532 blank strings for a relatively small surface - area. - - https://github.com/ruby/erb/commit/b7e45c2bdc - -commit 925ce3f4fbe2f05b8673a6dbc763ecab9f04fae1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-22 05:30:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-22 05:30:41 +0900 - - Skip commits that are empty after conflict resolution - -commit eee83af34c726e564d6505a81545ddb73e976404 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-22 05:24:06 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-22 05:24:06 +0900 - - Update yjit.md, document `--yjit-stats=quiet` - -commit 2502821abb0f2baf10a61c685a644a50a35c2cd9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-22 05:17:59 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-22 05:17:59 +0900 - - Exclude docs/ from YARP sync - -commit b9ef819116e90ad9c3af99046d001845b047427f - Author: Gaurav Khanna <gauravk92@gmail.com> - AuthorDate: 2023-08-22 05:14:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-22 05:14:35 +0900 - - [rubygems/rubygems] Support `ruby file: ".tool-versions"` in Gemfile - (https://github.com/rubygems/rubygems/pull/6898) - - Supports .tool-versions (ASDF) by checking for a line starting with "ruby" - before falling back to reading the entire file, as in .ruby-version. - - https://github.com/rubygems/rubygems/commit/6c0a3e793a - -commit 95e29b0423450447ea0adbf06564969f0e437673 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-22 03:47:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-22 04:00:55 +0900 - - [ruby/yarp] fix: avoid invalid memory read when CR is present without LF - - https://github.com/ruby/yarp/commit/2296c037de - -commit 461f8eaba74a7475bf97921e3ed45b63b126a190 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-21 05:38:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-22 04:00:52 +0900 - - [ruby/yarp] fix: parsing a '%' expression with a CR but not a newline - - Previously this failed an assertion and aborted. - - https://github.com/ruby/yarp/commit/a037d942a8 - -commit ca6db02c2a305bc990c144439996abfe984a6c5a - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-22 03:23:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-22 03:23:32 +0900 - - [ruby/irb] Avoid overriding user's `irb_name` setting in debugger - integration - (https://github.com/ruby/irb/pull/688) - - * Avoid overriding user's irb_name setting in debugger integration - - Instead of always setting `irb_name` to `irb:rdbg`, it should respect - the user's setting and only append `:rdbg` to it. - - * Introduce write_rc test helper - - https://github.com/ruby/irb/commit/2ce7593351 - -commit 7d26c03267cf1be643963355fc52efde1574b37a - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-22 02:45:56 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:45:56 +0900 - - Manually resync YARP - - YARP commits were synced out of order. We are doing this reset - commit to ensure that all files are currently correct and we can - proceed with monitoring syncs so this doesn't happen again. - -commit 2cecd3c8c1c62158d44c86fe782780394b227f24 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-20 11:18:43 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:43:25 +0900 - - [ruby/yarp] fix: newline tracking for nl-terminated % %q %Q - - https://github.com/ruby/yarp/commit/1e4940864b - -commit 9ca547b9fe8fd98b73184fffead1b2a44c37b4c5 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-20 03:25:54 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:43:24 +0900 - - [ruby/yarp] prefactor: extract yp_newline_list_check_append - - https://github.com/ruby/yarp/commit/149c74291b - -commit 926857eb1e124c62ef9cee52bb6c23c83e268ac6 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-20 03:03:35 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:43:23 +0900 - - [ruby/yarp] fix: support newline-terminated regular expressions - - Previously, parsing a snippet like this: - - %r\nfoo\n - - would result in tracking the second newline twice, resulting in a - failed runtime assertion. - - Fixing that issue reveals another bug, which is that the _first_ - newline was not being tracked at all. So we introduce a call to - yp_newline_list right when we construct the REGEXP_BEGIN token. - - https://github.com/ruby/yarp/commit/0d5d759091 - -commit e63bac3128a5ce584c904ee247ce5cafc5d0c56a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-19 09:47:58 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:43:21 +0900 - - [ruby/yarp] Rename statements to body where appropriate - - https://github.com/ruby/yarp/commit/0aa7d9d10c - -commit a7f40fc2d77e8317edaf3bbaa8835c2cafd29802 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-19 09:41:01 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:43:18 +0900 - - [ruby/yarp] Change AndWriteNode, OrWriteNode, OperatorWriteNode to contain write nodes - - It makes it more difficult to find all locations where a variable - is written to if they're just read nodes. To keep things consistent - we should make them write nodes. - - https://github.com/ruby/yarp/commit/840e094045 - -commit 988b0108fbc0caac2758e410edb8b5fcf6a62aad - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-19 04:09:38 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:43:16 +0900 - - [ruby/yarp] Consolidate OperatorAndWrite and OperatorOrWrite nodes - - https://github.com/ruby/yarp/commit/9e680a7598 - -commit 339b34be474debfb1a4452ecf5d62cd491bf07d2 - Author: HParker <HParker@github.com> - AuthorDate: 2023-08-18 01:41:14 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:43:15 +0900 - - [ruby/yarp] handle missing HEREDOC endline at start of heredoc - - https://github.com/ruby/yarp/commit/7b72493b6d - -commit 4fb2b3b6bf434a8dc027ca3a0cc3161e99eee26c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-19 00:54:45 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:43:13 +0900 - - [ruby/yarp] Ensure correct location with if/elsif, allow FOCUS env var, fix newlines on __END__ - - https://github.com/ruby/yarp/commit/9da0bc4452 - -commit 0fd57ee01d60f75f653e72f0b8647748bd422b5d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-18 22:16:10 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:43:12 +0900 - - [ruby/yarp] Handle interpolated regular expressions with the o flag for locals checking - - https://github.com/ruby/yarp/commit/db95191207 - -commit 524d99daaf14269e7bd1611051fffb35898e3fce - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-18 10:10:36 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:43:11 +0900 - - [ruby/yarp] Update to latest unparser - - https://github.com/ruby/yarp/commit/5ba7394261 - -commit 289c0da5b7de5d976610c210dd5258459f3f0c12 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-18 10:09:53 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:43:09 +0900 - - [ruby/yarp] Update to latest whitequark - - https://github.com/ruby/yarp/commit/3607efb01d - -commit 05c59995fa192c2e8c23196ccef61e2cc369d223 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-20 11:18:43 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:33:45 +0900 - - [ruby/yarp] fix: newline tracking for nl-terminated % %q %Q - - https://github.com/ruby/yarp/commit/1e4940864b - -commit dcc8afe9a40b94f5b678b8fc39e4c30ba63594c0 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-20 03:25:54 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:33:43 +0900 - - [ruby/yarp] prefactor: extract yp_newline_list_check_append - - https://github.com/ruby/yarp/commit/149c74291b - -commit 67cd60ed97b492bd960f425770ab1a04ef8aa187 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-22 02:32:12 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-08-22 02:32:12 +0900 - - Manually move files from test/snapshots to test/yarp/snapshots - -commit 817ffa8ec412baa4c33eba924840030a8beacbf0 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-22 01:52:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-22 01:52:34 +0900 - - YJIT: Remove unnecessary roundtrip conversion - -commit ac819f4db9bb79ba92547e1abd36336f36633583 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-20 03:03:35 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-22 01:22:53 +0900 - - [ruby/yarp] fix: support newline-terminated regular expressions - - Previously, parsing a snippet like this: - - %r\nfoo\n - - would result in tracking the second newline twice, resulting in a - failed runtime assertion. - - Fixing that issue reveals another bug, which is that the _first_ - newline was not being tracked at all. So we introduce a call to - yp_newline_list right when we construct the REGEXP_BEGIN token. - - https://github.com/ruby/yarp/commit/0d5d759091 - -commit f83c1d62bd42c7ba51e715610e9ca2410724d9e0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-18 10:06:45 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-22 01:20:11 +0900 - - [ruby/yarp] Update to latest seattlerb - - https://github.com/ruby/yarp/commit/d5365f08d0 - -commit 0c61406319802576a9b1c3e14802fc5eb9b8f803 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-22 01:07:19 +0900 - Commit: Kevin Newton <kddnewton@gmail.com> - CommitDate: 2023-08-22 01:20:07 +0900 - - Fix YARP sync - -commit 86ac17efde6cf98903513cac2538b15fc4ac80b2 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-22 00:42:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-22 00:42:15 +0900 - - [ruby/irb] Move input processing out of RubyLex - (https://github.com/ruby/irb/pull/683) - - * Add a test case for Ctrl-C handling - - * Test symbol aliases with integration tests - - There are a few places that also need to check symbol aliases before - `Irb#eval_input`. But since the current command test skip them, we - don't have test coverage on them. - - * Move each_top_level_statement and readmultiline to Irb - - This will save RubyLex from knowning information about commands and aliases. - - https://github.com/ruby/irb/commit/69cb5b5615 - -commit 2929c47243e30000ca4e273608b478cf8da42207 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-19 18:29:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-22 00:25:28 +0900 - - [ruby/yarp] Add a convenience value method for numeric literals - - https://github.com/ruby/yarp/commit/a328f27d8f - -commit 196116e576f7349c9efb51fb1fb265f7f8bb24b5 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-21 22:13:36 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-21 22:13:36 +0900 - - Refactor rb_ensure_iv_list_size - - We don't really need obj_ivar_heap_alloc and obj_ivar_heap_realloc since - they're just one liners. - -commit 8326bf1a215f93a2d1a14eeae2052bba1c2077c3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-20 18:09:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-21 13:46:08 +0900 - - [rubygems/rubygems] Confirm verification warnings - - Fix up https://github.com/rubygems/rubygems/pull/6882 - - https://github.com/rubygems/rubygems/commit/71c73ac6d9 - -commit 55f930aa7e55302e6c9772fa06c4fff18c1b5eba - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-20 04:29:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-21 02:32:57 +0900 - - [ruby/yarp] Use node kind for Ruby types - - * For example in ProgramNode: - # attr_reader statements: Node - => - # attr_reader statements: StatementsNode - - https://github.com/ruby/yarp/commit/ffed35238c - -commit 725ca2f9d808d180c57eaf49c2dd6bfcb9f701e4 - Author: Summer ☀️ <4400771+smmr0@users.noreply.github.com> - AuthorDate: 2023-08-21 02:21:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-21 02:22:01 +0900 - - [ruby/irb] Support `VISUAL` env var, and prefer it over `EDITOR` - (https://github.com/ruby/irb/pull/686) - - * Support `VISUAL` env var, and prefer it over `EDITOR` - - * Update test/irb/test_cmd.rb - - --------- - - https://github.com/ruby/irb/commit/399b872c31 - - Co-authored-by: Stan Lo <stan001212@gmail.com> - -commit 314ccdd60c5fe3dfa90651d271209e6d4adb2b52 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-21 02:16:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-21 02:16:22 +0900 - - [ruby/reline] Bump version to 0.3.8 - (https://github.com/ruby/reline/pull/582) - - https://github.com/ruby/reline/commit/3840d1f958 - -commit 405c295a21ba83e032cd2cc5a86e1edf9ee14ff4 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-08-21 02:03:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-21 02:03:32 +0900 - - [ruby/reline] Use fdiv for keyseq_timeout msec to sec conversion - (https://github.com/ruby/reline/pull/583) - - https://github.com/ruby/reline/commit/a6504acd63 - -commit 812272bdb2e2f68baa7da4b0a977bd898864a7f8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-19 19:51:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-20 20:12:45 +0900 - - Tempfile is not needed - -commit f0923164d8a32064cec53386f48dc0c340b9a15c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-19 19:35:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-20 20:12:44 +0900 - - Align the type of `num_entries` to `st_table` - -commit 7c226291d344c29236d51c604f885af05e7f1add - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-20 19:40:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 19:40:55 +0900 - - [ruby/reline] Remove Timeout usage - (https://github.com/ruby/reline/pull/580) - - Timeout's implementation relies on Thread, which would conflict with - `ruby/debug`'s thread-freezing implementation and has casued issues like - - - ruby/debug#877 - - ruby/debug#934 - - ruby/debug#1000 - - This commit avoids the issue by completely removing the use of Timeout. - - https://github.com/ruby/reline/commit/d4f0cd3fe1 - -commit 35442005132e60a728b59f0811da10fba95a851e - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-20 01:33:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:07:11 +0900 - - [rubygems/rubygems] fix lint - - https://github.com/rubygems/rubygems/commit/75c0f27b7e - -commit 7c4431e61cc00107af59a9f1c0a835a1405dda9f - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-20 01:23:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:07:05 +0900 - - [rubygems/rubygems] use a one-liner - - https://github.com/rubygems/rubygems/commit/46745885e8 - -commit e5efa01c7dfaaff0f7f45c3c87e65a84ed43bd34 - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-20 01:23:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:07:00 +0900 - - [rubygems/rubygems] handle removing `BUNDLE_`, since using start_with? would still include that - - https://github.com/rubygems/rubygems/commit/235d9b38d8 - -commit f0bf9391dc61a8cf2500c9e6f361d1c336edf7bd - Author: Martin Emde <martinemde@users.noreply.github.com> - AuthorDate: 2023-08-19 01:31:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:06:54 +0900 - - [rubygems/rubygems] Don't rely on globals when not matching regexp for "local." - - https://github.com/rubygems/rubygems/commit/e79ccdafd8 - -commit b5a0630cd039afe1aaf523bfe0dd66e282b0c587 - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-17 04:09:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:06:48 +0900 - - [rubygems/rubygems] Use ! methods once we have a new copy of the string. Use .prepend to avoid allocating a new string. - - https://github.com/rubygems/rubygems/commit/2ac35a661f - -commit 29aab66e6b7e71e139644817109c20a26fa05f3e - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-17 04:08:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:06:43 +0900 - - [rubygems/rubygems] call key.to_s once instead of multiple times to save when it's a symbol - - https://github.com/rubygems/rubygems/commit/535feb817c - -commit 239e35254bc26e747d40fd99e348d486d9ae9f87 - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-17 04:08:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:06:36 +0900 - - [rubygems/rubygems] Use value.match? only on Strings, which avoids allocating a matchdata, which is not used - - https://github.com/rubygems/rubygems/commit/cbf9ac93d7 - -commit 598048e3ddfc0dec301a4574af8d945cddee5e76 - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-17 04:07:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:06:31 +0900 - - [rubygems/rubygems] Use .to_s once in the beginning to save allocations if it's a symbol. - - https://github.com/rubygems/rubygems/commit/f8167db8a2 - -commit e921efa476dc24246dcb40452fa1e9c02e75675d - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-17 04:06:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:06:25 +0900 - - [rubygems/rubygems] name is often a symbol, so only to_s once to avoid allocating it multiple times - - https://github.com/rubygems/rubygems/commit/8eac49c429 - -commit 7cb6cbee953b8cf020e4e337bdbadd426460c71f - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-17 04:05:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:06:19 +0900 - - [rubygems/rubygems] String#start_with? is faster than regex with beginning boundaries - - https://github.com/rubygems/rubygems/commit/d7cde68034 - -commit b97e45d01a70ba0db6ad693332b041774c65bc3e - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-17 04:04:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:06:12 +0900 - - [rubygems/rubygems] Use ! methods on the array, since it is brand new. The individual keys are also new, so we can use ! methods on each individual one as well. - - https://github.com/rubygems/rubygems/commit/f2e912b9bb - -commit 2a61e1dccc85fc4c8d6d41ef246b96d0dde0096c - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-17 04:04:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:06:07 +0900 - - [rubygems/rubygems] Use Array#union to join these, instead of with | multiple times. This saves allocating 2 arrays - - https://github.com/rubygems/rubygems/commit/48c03b33b7 - -commit 79b187a45ecc0f99af97631a1771092874344092 - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-17 03:59:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:06:01 +0900 - - [rubygems/rubygems] config is a new Hash, and config.values is a new Array. that means we can use bang methods to avoid allocating new copies - - https://github.com/rubygems/rubygems/commit/8bc13fa55f - -commit 921c2bba4e4f0bb89d9ff354c05a176174586064 - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-17 03:57:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:05:56 +0900 - - [rubygems/rubygems] ENV.to_h returns a new hash, so we can `select!` it to avoid allocating another hash. - - `String#start_with?` is faster than regex that is bound to the start of - a string. - - https://github.com/rubygems/rubygems/commit/9b2006ef09 - -commit 7e5c3ec5b1fc0afae215ca00d7a1dd5d8f3799c0 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-19 00:08:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:05:29 +0900 - - Update specification.rb - - Co-authored-by: David Rodríguez <deivid.rodriguez@riseup.net> - -commit b68be40e245399b00988d254bc83c04cb045b713 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-18 07:47:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:05:23 +0900 - - [rubygems/rubygems] Use assert_raise instead of assert_raises - - For ruby-core compat - - https://github.com/rubygems/rubygems/commit/83aa7b794e - -commit 1935433f5f6fecc786955dcf80e8f65ada6bcaeb - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-08-18 07:38:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:05:17 +0900 - - [rubygems/rubygems] Ensure that loading multiple gemspecs with legacy YAML class references does not warn - - Before this, you would get constant redefinition warnings on Psych::DefaultKey - - Additionally, ensure the retries wont continue infinitely in the case of the ArgumentError not being caused by Marshal trying to load the undefined classes - - https://github.com/rubygems/rubygems/commit/919e8c2de4 - -commit f69f775f243ba2036b1b24a2beda1ca932040982 - Author: Akira Matsuda <ronnie@dio.jp> - AuthorDate: 2023-08-20 13:06:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 18:04:38 +0900 - - [rubygems/rubygems] choose_from_list may return nil index since - https://github.com/rubygems/rubygems/commit/abacb0cb34cd - - https://github.com/rubygems/rubygems/commit/5e2e9d6e50 - -commit d5ffbca5c4b0a6548cfb4bae36fab860861b529c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-20 13:29:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-20 13:29:42 +0900 - - Move `MKSTR` markers for fake.rb into coments - -commit 70ce3c8947c7f95897e56b397270c061dd50f280 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-19 21:00:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-20 03:02:39 +0900 - - [rubygems/rubygems] Fix leaked tempfiles - - Fix up https://github.com/rubygems/rubygems/pull/6882 - - https://github.com/rubygems/rubygems/commit/525b94a89f - -commit bd440bf85d6eff5ecf5132e93a0721cfcd38e5a5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-19 10:02:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-19 10:14:10 +0900 - - [ruby/yarp] Bump to version 0.8.0 - - https://github.com/ruby/yarp/commit/bfde753702 - -commit 1d0b627b708909d6e428e1ca6bfd565faf120f99 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-19 09:47:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-19 10:04:04 +0900 - - [ruby/yarp] Rename statements to body where appropriate - - https://github.com/ruby/yarp/commit/0aa7d9d10c - -commit 3dff315ed3e01f54980410008b73c6a838528e08 - Author: ywenc <ywenc@github.com> - AuthorDate: 2023-08-19 07:27:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-19 07:27:59 +0900 - - YJIT: Quiet mode when running with `--yjit-stats` (#8251) - - Quiet mode for running with --yjit-stats - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 07833049dffad4dd29435dd290b4e31d1c1e4f9a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-19 04:18:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-19 05:25:00 +0900 - - [ruby/yarp] Consolidate operator write nodes - - https://github.com/ruby/yarp/commit/22b287e2b1 - -commit ec47fc9539d8b18bcd5857d60acc84030eb95f47 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-19 04:09:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-19 05:24:56 +0900 - - [ruby/yarp] Consolidate OperatorAndWrite and OperatorOrWrite nodes - - https://github.com/ruby/yarp/commit/9e680a7598 - -commit 3d7a0301124aa1fb4a6fc1a92baf4f2601b8d2ea - Author: Ngan Pham <ngan@users.noreply.github.com> - AuthorDate: 2023-08-18 13:19:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-19 04:14:14 +0900 - - [rubygems/rubygems] Resolve ruby version file relative to bundle root - - This is a follow up to https://github.com/rubygems/rubygems/issues/6742. - This change makes it so that the version file is resolved relative to - the Bundle root instead of the working directory. - - Why is this useful? - - If you run a commnad (eg `rails`) from the `app/` directory, your bundle - would fail to load. - - https://github.com/rubygems/rubygems/commit/6d47ee98b9 - -commit e1505aebf2dd5876db227f3e0c70e9ad1c4302fd - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-17 16:33:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-19 03:30:49 +0900 - - [ruby/yarp] fix: multiple heredocs with embedded expressions with newlines - - Set heredoc_end to NULL at the start of lexing a heredoc, to avoid - having state from the previous heredoc confuse the parser's current - location. - - https://github.com/ruby/yarp/commit/21ee304f0e - -commit db076d8e84d6b2d03fb280aee3835e1f88150c00 - Author: HParker <HParker@github.com> - AuthorDate: 2023-08-18 01:41:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-19 03:05:09 +0900 - - [ruby/yarp] handle missing HEREDOC endline at start of heredoc - - https://github.com/ruby/yarp/commit/7b72493b6d - -commit 744bc4d5d0df32056d5352ed49ae504f6a031e78 - Author: John Hong <john.hong@shopify.com> - AuthorDate: 2023-08-18 11:06:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-19 01:42:49 +0900 - - [rubygems/rubygems] Make nil a valid license spec - - https://github.com/rubygems/rubygems/commit/675effb67e - -commit 4524aeba2f181df08b68587da140becd2dfa389f - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-19 00:30:52 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-08-19 01:17:37 +0900 - - YJIT: Fix return type of Integer#/ with T_FIXNUM inputs - - Issue found by running ruby/spec with `--yjit-verify-ctx`. Thanks! - - Notes: - Merged: https://github.com/ruby/ruby/pull/8250 - -commit c8d641998532c29714529e3c2e721bb1499658d5 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-18 23:25:36 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-18 23:25:36 +0900 - - Refactor ary_make_partial - -commit 314eed8a5ec9f1b46624b277dde75f8079026b7b - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-18 23:05:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-18 23:05:32 +0900 - - YJIT: implement fast path for integer multiplication in opt_mult (#8204) - - * YJIT: implement fast path for integer multiplication in opt_mult - - * Update yjit/src/codegen.rs - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - - * Implement mul with overflow checking on arm64 - - * Fix missing semicolon - - * Add arm splitting for lshift, rshift, urshift - - --------- - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 724223b4ca0117306529c9cbcfaedc3a07b840bf - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-18 04:52:14 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-18 22:24:45 +0900 - - Don't check for STR_NOEMBED in rb_fstring - - We don't need to check for STR_NOEMBED because the check above for - STR_EMBED_P means that it can never be false. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8238 - -commit 2800d1fd370e267d4379a4029a7d6e799387cd97 - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-08-18 05:44:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-18 21:51:14 +0900 - - [ruby/yarp] fix: unterminated % in arguments - - https://github.com/ruby/yarp/commit/efb3102369 - -commit 20106fe2274a88b8bea5413e3d7e9534f595d8a7 - Author: License Update <license.update@rubygems.org> - AuthorDate: 2023-08-18 12:21:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-18 17:21:13 +0900 - - [rubygems/rubygems] Update SPDX license list as of 2023-06-18 - - https://github.com/rubygems/rubygems/commit/3db9165335 - -commit 57dfd5c245525975243f2c0662c51ed82458d23c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 17:12:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 17:12:41 +0900 - - Revert "Fix tool/update-deps for YARP files" - - This reverts commit 6fff5c5ba23a2790c9d189de82e157c9fa986f96. - - Revert "Use $(top_srcdir) entries for mswin (#8244)" - - This reverts commit e327bf32bdfa610a0f1834048bb1422de992c073. - - Revert "Update dependencies" - - This reverts commit aba26a88040c322a188292447fd18a2b9c76c713. - - Revert "Use {$(VPATH)} for OpenBSD" - - This reverts commit 2046e054bc811fd6a8e30c926aa6c9c4a5884262. - - --- - - None of those revisions actually worked for both mswin and OpenBSD at - the same time. I need more time to build something that works for both. - -commit 6fff5c5ba23a2790c9d189de82e157c9fa986f96 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 17:07:05 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 17:07:05 +0900 - - Fix tool/update-deps for YARP files - -commit e327bf32bdfa610a0f1834048bb1422de992c073 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 16:48:13 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-18 16:48:13 +0900 - - Use $(top_srcdir) entries for mswin (#8244) - - While the $(VPATH) rules live in common.mk, mswin seems to ignore them. - We need to use $(VPATH) for OpenBSD, but we need to use the other one for mswin. - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit aba26a88040c322a188292447fd18a2b9c76c713 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 16:34:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 16:34:36 +0900 - - Update dependencies - -commit 2046e054bc811fd6a8e30c926aa6c9c4a5884262 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 16:07:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 16:20:11 +0900 - - Use {$(VPATH)} for OpenBSD - - Scratch build on OpenBSD has been failing since 67b5f63e97. - `make; make` works though. (`make` alone doesn't work) - - I have no idea what I'm doing, but I do know that this patch fixes - scratch build on an OpenBSD machine. - - My best guess is that BSD make isn't capable of distinguishing foo.c vs - ./foo.c in dependencies, and {$(VPATH)} becomes empty when it needs to be. - -commit 6a6dacb0d1ce47d413d75b6e45d07a8b08ace3fb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 14:04:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 14:12:38 +0900 - - Attempt to recover from YARP sync failures - -commit 412defc7ad75b755b4f001bb469691983203213f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-18 12:46:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-18 12:55:05 +0900 - - [ruby/io-console] Get rid of address of an rvalue on TruffleRuby - - https://github.com/ruby/io-console/commit/653c1cd33f - -commit 818ba30ee9e188c59385a56bc7560f43e90bce94 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-18 12:19:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-18 12:55:04 +0900 - - [ruby/io-console] Avoid the influence of special variable `$/` - - https://github.com/ruby/io-console/commit/5f71354332 - -commit cff8058701641c680de4924ea98d1b9d0efd9244 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-18 11:46:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-18 12:55:04 +0900 - - [ruby/io-console] Ensure to put a newline after password - - https://github.com/ruby/io-console/commit/15e36af171 - -commit 528da4347cb68d2e19373b3d0e517ec7d0d1ea90 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-18 10:36:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-18 12:55:03 +0900 - - [ruby/io-console] Flush after prompt - - https://github.com/ruby/io-console/commit/040a1d6259 - -commit 540cf43205262d8208516d4046caabfdae62a45a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-18 10:33:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-18 12:55:02 +0900 - - [ruby/io-console] Enable `getpass` methods always - - https://github.com/ruby/io-console/commit/57f9649df4 - -commit 1bbce42964a29f86f28b51285bf976c4a28a1a9e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-18 10:16:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-18 10:17:03 +0900 - - [ruby/io-console] [DOC] Remove a trailing space from the prompt too - - https://github.com/ruby/io-console/commit/85a155f25f - -commit 43802a088e204c32564c243d8f99f8980b150279 - Author: Olivier Lacan <hi@olivierlacan.com> - AuthorDate: 2023-08-18 09:28:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-18 10:02:42 +0900 - - [ruby/io-console] [DOC] IO::console.getpass usage example - - There were no clear example of this very useful method's usage anywhere - in the IO or IO::Console docs, which was a shame. - - https://github.com/ruby/io-console/commit/4d324586a8 - -commit ad2bad4ab42c490beca0bd3c5cd9846fdff238c2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 09:58:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 09:58:36 +0900 - - Fix the scope of rubygems conflict resolution - - The `git reset` and `rm_rf` are not necessary because `bundler/` is - considered as a `toplevels` and removed from the commit when there's - no conflict. - - For conflict cases, it's useful to remove them from the conflict targets - before moving on to fix other paths. - -commit 995fd11bdec4d84710249aef66a07b88e6b9bf46 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-18 09:03:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-18 09:06:57 +0900 - - [ruby/yarp] Remove strange :"#arg_rest" local - - https://github.com/ruby/yarp/commit/66ecec218d - -commit e913431687f2fffb1a8cc435e60c95eea887b087 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-08-16 02:39:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-18 08:16:57 +0900 - - [rubygems/rubygems] Raise Gem::Package::FormatError on EOF, indicating corrupt gem - - Gem::Package::TarReader::Entry now raises EOFError or returns nil - appropriately based on Ruby core IO.read and IO.readpartial behavior. - - Zlib will respond accordingly by raising Zlib::GzipFile::Error on EOF. - - When verifying a gem or extracting contents, raise FormatError similar - to other cases of corrupt gems. - - Addresses a bug where Gem::Package would attempt to call size on nil - instead of raising a more descriptive and useful error, leading users - to assume the problem is internal to rubygems. - - Remove unused error class TarReader::UnexpectedEOF that was never raised - since the NoMethodError on nil would happen first. Use EOFError instead. - - https://github.com/rubygems/rubygems/commit/dc6129644b - -commit e504c368943acd489c9be5bc249425e885605ff1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 07:06:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 07:06:57 +0900 - - Remove obsoleted yp_-renaming logic - - This has not been relevant since https://github.com/ruby/yarp/pull/1199. - -commit 78e7fd7b49ec2517006492039cd4f92b2cb4d85a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 07:03:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 07:04:14 +0900 - - Include YARP templated files in snapshots - - Those files should be part of CRuby distributions. - -commit 72a16c61dc6c6f5b55cd6b33d64a06baf919c93f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 06:52:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 06:52:23 +0900 - - Move the dependency of node.rb and serialize.rb - - to `main`. - - This is what lib/ruby_vm/rjit/instruction.rb currently does. Letting - .time depend on those files was just a workaround. - -commit 67b5f63e97eff714d2a028b593ac602515cdc1f1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 06:39:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-18 06:39:04 +0900 - - Render YARP templates in the build process (#8228) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 5d48825d55bedd1d0d9f975efa01cfc443b2451c - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-18 05:46:56 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-08-18 06:17:31 +0900 - - YJIT: Fix String#<< return type - - We previously falsely asserted that String#<< always returns a ::String - instance. Issue was discovered on CI with `--yjit-verify-ctx`. - - https://github.com/ruby/ruby/actions/runs/5893760435/job/15986002531 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8240 - -commit 9683eb06cf91664cfe18f61677b2624fbaf8e3b0 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-18 05:18:12 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-08-18 06:14:46 +0900 - - YJIT: Fix Kernel#respond_to? handling of rb_f_notimplement - - We should return false for this type of special methods but wasn't - previously. Was reproducible with: - - make test-all TESTS=../test/-ext-/test_notimplement.rb RUN_OPTS='--yjit-call-threshold=1' - - Notes: - Merged: https://github.com/ruby/ruby/pull/8239 - -commit 57ec167306672960ce4c65586a96752ad43461c7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 05:57:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 05:57:11 +0900 - - YARP: Ignore Rust sync failures - -commit 5db8b9b366271fb2ec25ca76722a3d25a4bb7de7 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-17 03:05:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-18 04:53:00 +0900 - - Move total_freed_objects to size pool - - This commit moves the `total_freed_objects` statistic to the size pool - which allows for `total_freed_objects` key in `GC.stat_heap`. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8231 - -commit 52506cbf516da1a606fad6a6779ab6136c4f353b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-17 02:54:55 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-18 04:53:00 +0900 - - Move total_allocated_objects to size pool - - This commit moves the `total_allocated_objects` statistic to the size - pool which allows for `total_allocated_objects` key in `GC.stat_heap`. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8231 - -commit 818998b41b41a4f2f4120b0a0b6a92e4009ee5ba - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 02:27:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 02:27:33 +0900 - - Refactor YARP_IGNORE_FILE_PATTERN - - `.git.*` covers those two cases. - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit f50e814dae946d49dd798976262ff60bd2797fbd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-18 02:01:54 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 02:01:57 +0900 - - Resync YARP to https://github.com/ruby/yarp/commit/11ad3fb590 - -commit 40002dd7dc2513ba5209da198a182f3b6a6a0e41 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-17 09:57:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 01:58:56 +0900 - - Resync YARP - - Notes: - Merged: https://github.com/ruby/ruby/pull/8234 - -commit 81d715099c93e8764d659a04a142822b8ec514e5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-15 22:18:44 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-18 01:58:56 +0900 - - [ruby/yarp] Treat yp_buffer_t as an opaque pointer - - Right now, we have to keep the buffer FFI object in sync with the - definition of yp_buffer_t because we access its fields directly. If - we add more fields or change the order, things will get out of sync. - - Instead, let's treat yp_buffer_t as an opaque pointer and access - its fields through accessor functions directly. This is more - consistent with how we handle strings anyway. - - https://github.com/ruby/yarp/commit/878d845eff - - Notes: - Merged: https://github.com/ruby/ruby/pull/8234 - -commit 75a4767525407755a33d3b140312c00f2cababd6 - Author: Ngan Pham <ngan@users.noreply.github.com> - AuthorDate: 2023-08-13 11:16:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-18 01:07:54 +0900 - - [rubygems/rubygems] Add `file` option to `ruby` method in Gemfile - - https://github.com/rubygems/rubygems/commit/fb9354b7bf - -commit 30a5b94517699589f6943163cd6b92f2f6c0023f - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-17 23:11:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-17 23:11:17 +0900 - - YJIT: implement side chain fallback for setlocal to avoid exiting (#8227) - - * YJIT: implement side chain fallback for setlocal to avoid exiting - - * Update yjit/src/codegen.rs - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - --------- - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 7433c8f7dde9eb82b94d59c71c17b4173047e008 - Author: Manu <git@manuraj.dev> - AuthorDate: 2023-08-12 16:27:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-17 19:39:31 +0900 - - [rubygems/rubygems] Clarify that `bundle info` takes a gem name - - https://github.com/rubygems/rubygems/commit/09ef74ef73 - -commit 8c447cffe441e68d73d6d6b1235b574439c34546 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-08-16 21:31:54 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-08-17 19:29:36 +0900 - - Lrama v0.5.4 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8236 - -commit d26b015e83e499e3bad61d6f2ef88eeca55fdedc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-17 12:18:01 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-17 16:30:01 +0900 - - [Bug #19831] Remove duplicate library options - - `$(LIBRUBYARG_SHARED)` is included in `$(LIBS)` in extension - libraries. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8235 - -commit e210b899dc803607bef1b395ace02dc9f96554ea - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-17 12:28:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-17 12:28:33 +0900 - - Move the PC regardless of the leaf flag (#8232) - - Co-authored-by: Alan Wu <alansi.xingwu@shopify.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 5bb946228550c7f171c27725860b153a675404f3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-16 21:39:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-17 10:57:09 +0900 - - [Bug #19831] Remove duplicate library options - - `$(MAINLIBS)` should be included in `$(LIBRUBYARG)` in cases it is - needed. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8233 - -commit 48b241e53fdb68c0ad115bcd23a43b310cc18db1 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-17 10:12:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-17 10:16:00 +0900 - - [ruby/yarp] Fix errors on locals test caused by LANG=C - - https://github.com/ruby/yarp/commit/8fae286bc9 - -commit 1c53e64c512668685bb7abaf1232518af3969496 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-17 09:55:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:55:56 +0900 - - Fix a regexp error - -commit cdb757f817b0721d79d43ae8de6f8198d6033177 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-17 09:55:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:55:32 +0900 - - Avoid synchronizing GitHub Actions from YARP - -commit 7183cf53f868c6a1abdc2ff4cb848c28c4858f05 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-16 08:47:48 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:51:52 +0900 - - Revert an unintended revert - -commit 45740e7a248b4b995644646e38d94b8be44fc60c - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-17 07:42:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Use _snprintf when using Windows versions prior to 2015 (< 1900) - - Ruby CI has informed us that snprintf is not available on Windows - versions, but _sprintf is supported. This commit allows us to use - _sprintf where applicable - - https://github.com/ruby/yarp/commit/818cc96afe - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit c989c1b068e944908d185bfab67b64bc52a072d0 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-16 06:34:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Omit locals test if running on a 32 bit machine - - https://github.com/ruby/yarp/commit/809d046f36 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 87f74a349e5ed337b708e3626dc946252dfc2c86 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-16 02:01:31 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - Update dependencies - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit f20dfd0803fb21a9332092922378a0de022eaa67 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-16 02:02:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - Fix the YARP init path - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 3873b1eb39a2070937dc62ac47f8b96df54a72fc - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-16 02:00:54 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - Resync YARP - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 957cd369fa38915241e0b66e852f66ac516de664 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-15 02:58:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Add test for empty heredoc - - https://github.com/ruby/yarp/commit/e49b63a79e - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 3536cad9022e1f4fc6e6fd3d629de005e7c3342a - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-13 02:21:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Fixes so `bundle exec rake` can run on JRuby and TruffleRuby - - https://github.com/ruby/yarp/commit/e6cea4fa08 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 958ac8d58680782cd839b657f290fe698c044f20 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-13 19:44:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Test all methods of the YARP Ruby API - - https://github.com/ruby/yarp/commit/a723f40baf - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit a8c70ed2b42013158c1d5ebe11b8ed5aeed8eb45 - Author: HParker <HParker@github.com> - AuthorDate: 2023-08-11 02:17:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] add a diagnostic for *rest in order after optional state - - https://github.com/ruby/yarp/commit/908244ba12 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit bf723b21ccd9d019bca5e33364a21f0219326547 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-11 03:16:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] More flip flop flags - - Whenever you see a `not` or a `!`, the receiver of that method should - potentially be marked as a flip-flop. - - https://github.com/ruby/yarp/commit/ba5977a40a - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit fb287fa425514ee26a156e9792e1e6380c0318b5 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-10 23:46:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Support the flipflop flag - - https://github.com/ruby/yarp/commit/6315890390 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit ecf2e84c05903cc7cdbc78310eae3cca794164d1 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-09 23:57:00 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Add a CHANGELOG - - https://github.com/ruby/yarp/commit/b490ff0919 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 86cc82a1ab339914ed7ebe787cb76f954a19120d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-09 23:17:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Improved comments, moved flags after type - - https://github.com/ruby/yarp/commit/4815d77e82 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 383c47f538974f57a1a5c7d1b174ce365fdd8698 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-09 05:55:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Separate yp_node_flags_t from yp_node_type_t - - Prior to this commit, we folded the flags into the type. This created - extra overhead when calculating the type and setting the flags. This - commit separates them. - - https://github.com/ruby/yarp/commit/b783a5678c - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 89de544442c8cd5db08a0fe4b582ba24e67f062e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-09 03:11:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Set constant path write node target type - - https://github.com/ruby/yarp/commit/771f7ed789 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit ee885237f6e39af4505b850f49637a2d274bc175 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-08 05:55:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Fix string concat parsing - - https://github.com/ruby/yarp/commit/58f839a3eb - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 77e52735f09411a94ce5ae8bdbac381bc0a49a44 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-08 06:19:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Fix warnings found from gcc-analyzer and clang-analyzer - - https://github.com/ruby/yarp/commit/1f9a6e05c4 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 9b952670bb4945ea227a72dd9b74ef5972a69757 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-08 02:11:59 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Less const_get - - Right now whenever you go to create a Ruby object from a C struct - we dynamically look up the constants. This is not great for - performance. Now instead we template out a constant for each VALUE - that holds the classes, and then directly reference it. - - https://github.com/ruby/yarp/commit/f4756cda77 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 96aebb42652c8a2dde0e33d45316da64d26be566 - Author: Thomas E. Enebo <tom.enebo@gmail.com> - AuthorDate: 2023-08-05 00:02:29 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Address PR comments - - - odd whitespace - - a couple of name changes - - properly read uint32_t when not properly aligned - - https://github.com/ruby/yarp/commit/3208ee3983 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit d6f9f3e498212eea18652028266d6c12b9ec429a - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-04 23:01:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Rename RescueNode#exception to RescueNode#reference - - https://github.com/ruby/yarp/commit/ad0eb4b2c3 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit a793260c159e991998efb6975b0fdff92d22c806 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-04 05:43:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Also rework regexp lexer to check terminators properly - - https://github.com/ruby/yarp/commit/4b157a8352 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 2ef54d38556c1c6bc95704fcb0dfa6a99041404d - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-04 05:27:21 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Rework the list lexer to check terminators properly - - https://github.com/ruby/yarp/commit/60315d0f13 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 5e9397279bbadb7d5cb08298e23e9fa76198b90e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-04 04:49:29 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Handle escaping in regexp slow path - - https://github.com/ruby/yarp/commit/8dd0a1b281 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 72571453204a0e91e474233b619183be8834edba - Author: Thomas E. Enebo <tom.enebo@gmail.com> - AuthorDate: 2023-08-04 03:19:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Clang beats gcc in pedantry - - Accidentally declared int32_t and not uint32_t and it was caught - on macos. - - https://github.com/ruby/yarp/commit/6581520793 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 1e0749e0328ebb7a670450d0375626b7adc789fb - Author: Thomas E. Enebo <tom.enebo@gmail.com> - AuthorDate: 2023-08-04 03:15:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Addressed review comments. - - Missing any tests and in fact this is untested so still a WIP. - - https://github.com/ruby/yarp/commit/5411abd651 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 0b6a26abff1a15103f4a3080619ea28b40774324 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-04 02:38:54 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Provide slow path for finding ) in regexp when encoding changes - - https://github.com/ruby/yarp/commit/c1064a65e3 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 0004565a919fde84def202432ef04cee0f7b689e - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-04 02:25:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Use yp_memchr in regexp parsing - - https://github.com/ruby/yarp/commit/08081dd24f - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 1ad0d198760d0f3295da86f66d099f28c9b50df7 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-07-06 04:59:28 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Parse individual snippets of test/fixtures/*.txt - - * To ensure the parser does not try to read bytes further than the end of each snippet. - - https://github.com/ruby/yarp/commit/1c4438bdde - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 3f64defe13b4a8712f95de009fc1f8b09e2bf779 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-03 23:35:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Make sure lexing ? does not read off the end - - https://github.com/ruby/yarp/commit/d694e3ebf2 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit d2eb82d9692c0ad2da36e5b910dd34c77395733a - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-03 04:37:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Fix test to use the new location of yarp.so - - https://github.com/ruby/yarp/commit/a22b204a11 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 1002b777c4d8c7036759a2cd28f3fea5352f98d6 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-03 04:22:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Automatically find the right line for yarp/serialize.rb newline test - - https://github.com/ruby/yarp/commit/5908130541 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 820a58c228b8dbd29915065f8e5f18a61442bb88 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-03 02:17:31 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Hide debug methods - - https://github.com/ruby/yarp/commit/aa0dc2f301 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 1ea9e444ecbd089b8216eff3cd5d05e34912736b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-02 23:28:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Fix memory leak from constant write node creation - - https://github.com/ruby/yarp/commit/0071bee0bb - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit e66e60cf696b7deaa6532273d18159b491a6e0b7 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-02 23:20:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Handle invalid multiple parameters - - https://github.com/ruby/yarp/commit/2f83265653 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 7a1c497426c38c301e65c74a77b5eead98887eba - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-02 23:08:59 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Add constant write node - - https://github.com/ruby/yarp/commit/a62f2f0153 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 9c61e0c831c8890bdfac5bf537bea21d4ae84e05 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-02 23:01:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Ensure token cannot begin an expression - - https://github.com/ruby/yarp/commit/837522217c - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 3d032cf3e894fbfea00a81acf1fd90a29de9bb63 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-02 22:49:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Simplify creation of numerics - - https://github.com/ruby/yarp/commit/e5f6ffa23a - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit b6f26c2e4a95e71f67b84e36b4368d6d820ffb5b - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-02 00:37:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Use common fields for yp_string_t - - * Otherwise it is undefined behavior to access the field of another `.as`. - * Accessing the right `.as` field according mode would be extra overhead. - - https://github.com/ruby/yarp/commit/7dc41ee803 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit ab2f638a275ae8aaf55a4937dcb3f898cf7ddad0 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-07-30 00:27:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Test YARP.parse_file by using it in tests - - https://github.com/ruby/yarp/commit/c603bba89a - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 7cc5b22bbc2768cb9280fcd879cc934b0f44deeb - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-07-29 23:55:48 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Add comment that extension.c should not contain non-trivial logic - - https://github.com/ruby/yarp/commit/638f6849be - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit e712bc9b937c7b9c2993f0d3289f64bb81c70970 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-07-29 23:49:54 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Move efficient file reading using demand paging to librubyparser - - * So it can be reused by the Fiddle backend, etc and not just the C extension. - * Add YP_STRING_MAPPED to use a consistent interface for yp_string_t. - That way yp_string_free() can be used like for other string types. - * Fix handling of empty file for !HAVE_MMAP && !_WIN32 - - https://github.com/ruby/yarp/commit/e40bc35801 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 2ccaaaa1017fa411134648bbaa6fa8f8b875e16d - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-07-29 23:13:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Add simpler exported unescape function to librubyparser - - * Moves logic from the C extension to librubyparser which can be shared with the Fiddle backend. - - https://github.com/ruby/yarp/commit/aa48d5e444 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 31960a9627f7810a294b835dfe073cab1106e1de - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-02 00:26:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Handle missing block parameters - - https://github.com/ruby/yarp/commit/bc9049418d - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit eca3b9343757c9d70dff5f4172396c0a6643cbf0 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-02 00:21:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] **nil can be a STAR_STAR token - - https://github.com/ruby/yarp/commit/33b06f252c - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit e56da35637cbb0107274047ea7ffb277d3ebddef - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-02 00:21:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Handle invalid regexps more gracefully - - https://github.com/ruby/yarp/commit/584a49f123 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 4c4e75c0de961e5a838f52bb056ddae505722489 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-02 00:16:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Add error cases for ustar appearing in infix position - - https://github.com/ruby/yarp/commit/8736c17359 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit cededf73dca8986aec44e01647be8bef8cb85579 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-02 00:11:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] For errored % characters, use TOKEN_PERCENT and not TOKEN_STRING_BEGIN - - https://github.com/ruby/yarp/commit/2ec671fe1e - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 242f3c3a77007c260d7d868cff3fd5f293e8aaa1 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-02 00:05:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Don't read off the end when parsing % literals - - https://github.com/ruby/yarp/commit/aff40871e6 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 45efbadba55beace717eaad384c7125c801abd86 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-01 03:17:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Enable all of -wconversion - - https://github.com/ruby/yarp/commit/638163f6c6 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit f1658efe38347ec90c87c64dcee4f8e4656aa388 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-01 02:34:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Split out newline test - - https://github.com/ruby/yarp/commit/eeb4f6cb9d - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 41e8ba01ae644d10e6aebc832fc616e1af8e7159 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-07-31 23:48:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Mark locations in the tree where newlines can occur - - https://github.com/ruby/yarp/commit/479e835756 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 86b32dac9223895f236c944548fbf5379a5b1037 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-07-31 22:33:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Handle pound terminator in isolation - - https://github.com/ruby/yarp/commit/1cfce46107 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit ede55edbd55ae0c476957723e18f8764679fde4b - Author: Thomas E. Enebo <tom.enebo@gmail.com> - AuthorDate: 2023-07-28 03:58:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Remove trailing whitespace - - https://github.com/ruby/yarp/commit/04de272383 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 76c77b5eca3f02db894819823d3a1ab55455754d - Author: Thomas E. Enebo <tom.enebo@gmail.com> - AuthorDate: 2023-07-28 03:46:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] WIP - Introduce contextually parsing programs vs evals - - This is more or less the code I used in my POC in JRuby - to parse evals. Evals depend on parent variable scopes - and will produce a different syntax tree. - - Questions: - 1. How does MRI compile evals currently? I cannot find anything. - 2. This passes in a char * of data. It does not encode the - variables we pass in because the system calling this already - knows. Is this adequate though? - 3. Can I get guidance on how best to test this? - - https://github.com/ruby/yarp/commit/f441b6fd2c - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit 0f8091947debc467b58a2b04c150dc7a38026ed3 - Author: Mike Dalessio <mike.dalessio@shopify.com> - AuthorDate: 2023-07-19 05:25:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - [ruby/yarp] Move the gem's C extension into lib/yarp/ - - and change the require from "yarp.so" to "yarp/yarp", which is more - aligned with existing community conventions for gems. - - https://github.com/ruby/yarp/commit/64b70e2658 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit c5dad5f1d74e4d1acbae943e00a9465a7c921fa5 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-08-16 01:29:00 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-17 09:47:32 +0900 - - Sync script updates - - Notes: - Merged: https://github.com/ruby/ruby/pull/8226 - -commit f339937abb6a5057a7ed57c52dad708349db5412 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-16 00:37:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-17 08:33:52 +0900 - - RJIT: Remove macros inherited from MJIT but no longer used - - Notes: - Merged: https://github.com/ruby/ruby/pull/8224 - -commit 0d7e847153ed5b6006b686085207527ff2f28853 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-16 23:52:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-16 23:52:04 +0900 - - Consider the special node when printing - - Appreciation to the reporter, Huichiao Tsai <hctsai.cs10@nycu.edu.tw>. - -commit 7d3634a121736eea1a43a332b9abd0540d3a6300 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-16 20:47:28 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-16 22:53:00 +0900 - - Extract GC for fd parts as `TRY_WITH_GC ` - -commit f0edcd8283e1aeda9ff2d04926ec8041b421f890 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-16 20:45:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-16 22:53:00 +0900 - - Extract platform dependent part as `fdopen_internal` - -commit 82e480ff40cd41de993b92ddc42ef79a807ff2be - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-16 15:45:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-16 22:52:59 +0900 - - Silent test-all on AppVeyor - -commit 089227e94823542acfdafa68541d330eee42ffea - Author: haseponpon <36598331+p0pemaru@users.noreply.github.com> - AuthorDate: 2023-08-16 22:51:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-16 22:51:17 +0900 - - [DOC] Specify the unit of return value for `Time#-` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8217 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 5a40f7db54dfcc7dadb75dde32c25b88c78d6a85 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-16 19:13:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-16 19:13:46 +0900 - - [ruby/irb] Encapsulate input details in Statement objects - (https://github.com/ruby/irb/pull/682) - - * Introduce Statement class - - * Split Statement class for better clarity - - https://github.com/ruby/irb/commit/65e8e68690 - -commit 0982c5fa00f6163d04b17229e72d128263b98d50 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-08-09 11:55:19 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-08-16 19:02:44 +0900 - - Resync Lrama v0.5.3 - - Previous sync included unrelated files and missed template file update. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8229 - -commit fe240b672b709e800f2b4fb996f04f2005329dab - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-08-11 04:37:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-16 15:03:38 +0900 - - [rubygems/rubygems] Show better error when PAT can't authenticate to a private server - - Before: - - ``` - Fetching gem metadata from https://rubygems.org/........ - Fetching source index from https://rubygems.pkg.github.com/my-org/ - - Bad username or password for https://x-access-token@rubygems.pkg.github.com/my-org/. - Please double-check your credentials and correct them. - ``` - - After: - - ``` - Fetching gem metadata from https://rubygems.org/........ - Fetching source index from https://rubygems.pkg.github.com/my-org/ - - Access token could not be authenticated for https://x-access-token@rubygems.pkg.github.com/my-org/. - Make sure it's valid and has the necessary scopes configured. - ``` - - https://github.com/rubygems/rubygems/commit/2ae69c964a - -commit e678affe70d7597464368197fb55d277f0c26bab - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-08-11 00:23:32 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-16 15:03:38 +0900 - - [rubygems/rubygems] Bad auth should not fallback either - - https://github.com/rubygems/rubygems/commit/ba3ea27869 - -commit c076ac8a5f5cc2850ac59bc2239354c33fc05961 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-08-11 03:38:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-16 15:03:38 +0900 - - [rubygems/rubygems] Use better status for authentication failures - - https://github.com/rubygems/rubygems/commit/ffa395411f - -commit 2e04336b6718b4ad59f9563b388d34cde24704ed - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-22 04:01:58 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-16 15:03:38 +0900 - - [rubygems/rubygems] Fix git source conservativeness - - https://github.com/rubygems/rubygems/commit/9a0e0dfd5b - -commit 4a3777bf6ba78473ace61fbaa663faaa4e7068e3 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-22 03:30:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-16 15:03:38 +0900 - - [rubygems/rubygems] Extract s.name to a variable - - https://github.com/rubygems/rubygems/commit/689c39b42f - -commit e92ace6be7e6501bfb7dec43a8d8abdf19ae80f0 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-22 03:20:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-16 15:03:38 +0900 - - [rubygems/rubygems] Remove unneeded stuff - - This should be only for path sources, and unrelated to git. - - https://github.com/rubygems/rubygems/commit/0d8f31eeed - -commit 7bb3e637ffedf34fa148d4fbf35b57681490c7e1 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-13 19:48:05 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-16 15:03:38 +0900 - - [rubygems/rubygems] Don't update locked sources when not necessary - - https://github.com/rubygems/rubygems/commit/cfc82b592a - -commit c57ab646cbefc50a8e8d21faec8a60643b1a057c - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-13 19:47:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-16 15:03:38 +0900 - - [rubygems/rubygems] Extract a `default_source` method - - https://github.com/rubygems/rubygems/commit/784e08348e - -commit 002165f8fec925740330e62984e28fcc0eb53ce1 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-12 19:38:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-16 15:03:38 +0900 - - [rubygems/rubygems] Move `lockfile_source` variable out of condition branch - - https://github.com/rubygems/rubygems/commit/efebc64250 - -commit 6bc63ab9bb3828a59e2c87619922a33bf6b27da3 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-12 18:15:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-16 15:03:38 +0900 - - [rubygems/rubygems] Refactor locked dep filtering more - - We only need to check whether the spec if for a direct dependency once. - - https://github.com/rubygems/rubygems/commit/65b455a5cb - -commit 86492fca653a105d926eb0cad9128e22b324a378 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-12 17:58:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-16 15:03:38 +0900 - - [rubygems/rubygems] Avoid unnecessary loop through dependencies - - https://github.com/rubygems/rubygems/commit/2ab63bb94d - -commit f1df06294474186137a9d1e80e65cb14ec3a5c66 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-08-14 23:02:42 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:42 +0900 - - [ruby/openssl] Enhance printing OpenSSL versions. - - * Updated the `OpenSSL::OPENSSL_VERSION_NUMBER` comment explaining the format. - * Added the `OpenSSL::LIBRESSL_VERSION_NUMBER` to print LibreSSL version number, - in the case that Ruby OpenSSL binding is compiled with LibreSSL. Note - `test/openssl/utils.rb#libressl?` is not using this value in it for now. - * Update `rake debug` to print the values in a readable way, adding - `OpenSSL::OPENSSL_VERSION_NUMBER` and `OpenSSL::LIBRESSL_VERSION_NUMBER`. - - https://github.com/ruby/openssl/commit/d19e6360ed - -commit f5ca8d0e3149098e4b6c4a14d129268ec43c71d5 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-08-10 03:35:01 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:42 +0900 - - [ruby/openssl] test/openssl/test_pkey.rb: Fix pending tests in FIPS case. - - https://github.com/ruby/openssl/commit/f9980d88aa - -commit 8ca0d53fd09b2032d990b0ab92ec63f408861dbc - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-08-15 00:13:22 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:42 +0900 - - [ruby/openssl] Use openssl? instead of OpenSSL::OPENSSL_VERSION_NUMBER. - - Update the `openssl?` method by adding status argument. - - Note the format is below. - - * OpenSSL 3: 0xMNN00PP0 (major minor 00 patch 0) - * OpenSSL 1: 0xMNNFFPPS (major minor fix patch status) - - See <https://www.openssl.org/docs/man1.1.1/man3/OPENSSL_VERSION_NUMBER.html> - for details. - - https://github.com/ruby/openssl/commit/db8deaacd3 - -commit 12bdacdca5d19988f3ffe60714f518ec7324b35a - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-07-01 21:53:38 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:41 +0900 - - [ruby/openssl] Include "additional data" message in OpenSSL errors - - Error entries in the OpenSSL error queue may contain additional - contextual information associated with the error, which can be helpful - when debugging. - - This "additional data" is currently only printed to stderr when - OpenSSL.debug is enabled. Let's include this in the exception messages - raised with ossl_raise(), too. - - $ ruby -Ilib -ropenssl -e'OpenSSL.debug=true; OpenSSL::SSL::SSLContext.new.ecdh_curves="P-256:not-a-curve"' - -e:1: warning: error on stack: error:0A080106:SSL routines:gid_cb:passed invalid argument (group 'not-a-curve' cannot be set) - -e:1:in `ecdh_curves=': passed invalid argument (group 'not-a-curve' cannot be set) (OpenSSL::SSL::SSLError) - from -e:1:in `<main>' - - https://github.com/ruby/openssl/commit/1c5bbdd68e - -commit 382b42be9446e1d215109cc47db9ebc156cb8f8f - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-07-01 21:55:31 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:41 +0900 - - [ruby/openssl] config: relax test assertions against error messages - - Test that the error message contains the necessary text instead of the - exact match. Exceptions raised by ossl_raise() may carry additional - context information in the message. - - https://github.com/ruby/openssl/commit/fd6f76c0d3 - -commit 01d368e7b06ccf34f92c535a117a2856956d2bcb - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-08-10 02:45:15 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:41 +0900 - - [ruby/openssl] ssl: raise SSLError if loading ca_file or ca_path fails - - When compiled with OpenSSL <= 1.1.1, OpenSSL::SSL::SSLContext#setup - does not raise an exception on an error return from - SSL_CTX_load_verify_locations(), but instead only prints a verbose-mode - warning. This is not helpful since it very likely indicates an actual - error, such as the specified file not being readable. - - Also, OpenSSL's error queue is not correctly cleared: - - $ ruby -w -ropenssl -e'OpenSSL.debug=true; ctx=OpenSSL::SSL::SSLContext.new; ctx.ca_file="bad-path"; ctx.setup; pp OpenSSL.errors' - -e:1: warning: can't set verify locations - ["error:02001002:system library:fopen:No such file or directory", - "error:2006D080:BIO routines:BIO_new_file:no such file", - "error:0B084002:x509 certificate routines:X509_load_cert_crl_file: system lib"] - - The behavior is currently different when compiled with OpenSSL >= 3.0: - SSLError is raised if SSL_CTX_load_verify_file() or - SSL_CTX_load_verify_dir() fails. - - This inconsistency was unintentionally introduced by commit https://github.com/ruby/openssl/commit/5375a55ffc35 - ("ssl: use SSL_CTX_load_verify_{file,dir}() if available", 2020-02-22). - However, raising SSLError seems more appropriate in this situation. - Let's adjust the OpenSSL <= 1.1.1 code so that it behaves the same way - as the OpenSSL >= 3.0 code currently does. - - Fixes: https://github.com/ruby/openssl/issues/649 - - https://github.com/ruby/openssl/commit/7eb10f7b75 - -commit 8dd5c20224771abacfcfba848d9465131f14f3fe - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-05-04 03:48:34 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:41 +0900 - - [ruby/openssl] Raise an error when the specified OpenSSL library directory doesn't exist. - - OpenSSL built from the source creates the library directory to the - `/path/to/openssl_dir/lib64` as a default. - In the case, the `bundle exec rake compile -- --with-openssl-dir=<openssl_dir>` - cannot compile with the lib64 directory, and may compile with system OpenSSL's - libraries unintentionally. This commit is to check this case to avoid linking - with an unintentional library directory. - - https://github.com/ruby/openssl/commit/ca54087462 - -commit 0eaee5c000bf2fc6e1866881a6f9a4d7820c16d4 - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-06-28 12:09:27 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:40 +0900 - - [ruby/openssl] [DOC] enhance RDoc for exporting pkeys - - Describe the behavior of OpenSSL::PKey::{DH,DSA,EC,RSA}#to_pem - and #to_der more clearly. They return a different result depending on - whether the pkey is a public or private key. This was not documented - adequately. - - Also, suggest the use of OpenSSL::PKey::PKey#private_to_pem - and #public_to_pem instead, if possible. - - https://github.com/ruby/openssl/commit/d22769af8f - -commit fae6fd07fe49d3149c922e15c5a75cd32631e858 - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-06-28 12:10:50 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:40 +0900 - - [ruby/openssl] [DOC] prefer PKey#private_to_pem and #public_to_pem in RDoc - - Suggest the use of OpenSSL::PKey::PKey#private_to_pem and #public_to_pem - in the top-level documentation. For new programs, these are recommended - over OpenSSL::PKey::RSA#export (also aliased as #to_s and #to_pem) - unless there is a specific reason to use it, i.e., unless the PKCS#1 - output format specifically is required. - - The output format of OpenSSL::PKey::RSA#export depends on whether the - key is a public key or a private key, which is very counter-intuitive. - - Additionally, when called with arguments to encrypt a private key, as in - this example, OpenSSL's own, non-standard format is used. The man page - of PEM_write_bio_PrivateKey_traditional(3) in OpenSSL 1.1.1 or later - states that it "should only be used for compatibility with legacy - programs". - - https://github.com/ruby/openssl/commit/56312038d6 - -commit 4541cd4cbae66900f8407ea8d2ec899634cd255d - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-06-29 20:26:06 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:40 +0900 - - [ruby/openssl] [DOC] prefer "password" to "passphrase" - - Let's consistently use the word "password". Although they are considered - synonymous, the mixed usage in the rdoc can cause confusion. - - OpenSSL::KDF.scrypt is an exception. This is because RFC 7914 refers to - the input parameter as "passphrase". - - https://github.com/ruby/openssl/commit/06d67640e9 - -commit 4465941e68e076d3198a071600f1047b7a382e0b - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-06-07 16:15:29 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:39 +0900 - - [ruby/openssl] Revert "Relax error message check for OpenSSL 3.1" - - This reverts commit https://github.com/ruby/openssl/commit/fc4629d246f2. - - The test case "test_connect_certificate_verify_failed_exception_message" - does want to check the reason behind a certificate verification failure - to be included in the exception message. - - https://github.com/ruby/openssl/commit/c309745eb8 - -commit cb344e4e25c0979e2dfd1492fb91eef137bf059f - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-06-07 16:01:01 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:39 +0900 - - [ruby/openssl] ssl: adjust "certificate verify failed" error on SSL_ERROR_SYSCALL - - Enrich SSLError's message with the low-level certificate verification - result, even if SSL_get_error() returns SSL_ERROR_SYSCALL. This is - currently done on SSL_ERROR_SSL only. - - According to the man page of SSL_get_error(), SSL_ERROR_SYSCALL may be - returned for "other errors, check the error queue for details". This - apparently means we have to treat SSL_ERROR_SYSCALL, if errno is not - set, as equivalent to SSL_ERROR_SSL. - - https://github.com/ruby/openssl/commit/5113777e82 - -commit 66a70582f4d7fea5dffac5925484640337d15e7f - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-06-07 15:52:52 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-08-16 14:48:39 +0900 - - [ruby/openssl] ssl: adjust styles of ossl_start_ssl() - - Expand tabs, insert some spaces, and adjust indentation of switch-case - to match Ruby's style. - - https://github.com/ruby/openssl/commit/10833aa8f6 - -commit af67ced3b0945e8ea67434f8e66ef1e602656438 - Author: Josh Nichols <josh@technicalpickles.com> - AuthorDate: 2023-08-16 02:31:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-16 10:40:13 +0900 - - [ruby/net-http] Update lib/net/http.rb - - @natematykiewicz's suggestion to avoid another string allocation - - https://github.com/ruby/net-http/commit/4a22c42338 - - Co-authored-by: Nate Matykiewicz <natematykiewicz@gmail.com> - -commit ae68a8df586e9f3b3211e9c174b7001e57ee6aee - Author: Josh Nichols <josh@technicalpickles.com> - AuthorDate: 2023-08-16 02:30:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-16 10:40:12 +0900 - - [ruby/net-http] Update lib/net/http/response.rb - - @natematykiewicz's suggestion to avoid a string allocation - - https://github.com/ruby/net-http/commit/925630f227 - - Co-authored-by: Nate Matykiewicz <natematykiewicz@gmail.com> - -commit ea321a654d4b4fd6d56a1cdd6e117c62075898ee - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-15 00:17:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-16 10:40:11 +0900 - - [ruby/net-http] use +'' everywhere - - https://github.com/ruby/net-http/commit/1077427152 - -commit 70da92cdf7ac75e071353c4551419ad02c284497 - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-15 00:17:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-16 10:40:10 +0900 - - [ruby/net-http] Fix on 2.7 - - https://github.com/ruby/net-http/commit/5194fd541e - -commit 4d21134f3f1645ae2042d836e750ad267ee1551f - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-13 01:19:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-16 10:40:09 +0900 - - [ruby/net-http] freeze rest of lib - - https://github.com/ruby/net-http/commit/455a74734a - -commit 4165ec91d87ff1fcb41e312d896bea8a678c9bab - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-12 08:04:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-16 10:40:08 +0900 - - [ruby/net-http] update net/http/response to be frozen string literal - - https://github.com/ruby/net-http/commit/dc3b4a75ca - -commit 2fbd8dca18a102cb3ffc5e7e6235c09fd0d04ba3 - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-12 07:02:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-16 10:40:08 +0900 - - [ruby/net-http] turn on frozen strings for net/http/generic_request - - https://github.com/ruby/net-http/commit/b92ade088d - -commit 8d04260acd8b6fba98867acc1a7e786495813fa0 - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-12 04:57:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-16 10:40:07 +0900 - - [ruby/net-http] turn on frozen strings for net/http/header - - https://github.com/ruby/net-http/commit/a5203c9f92 - -commit 0300ea5a6c8a7a49feed73318fc8a991aa89fcfc - Author: Josh Nichols <josh.nichols@gusto.com> - AuthorDate: 2023-08-14 01:55:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-16 10:39:08 +0900 - - [ruby/net-http] Improve performance of HTTPHeader#content_type - - In the existing implementation, `main_type` and `sub_type` would end up - being called multiple times potentially. - - Instead of doing that, save the result so it can be re-used. - - https://github.com/ruby/net-http/commit/179976f7ea - -commit 47b1a52826e5690969e26760d9d2536887f41f62 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-16 00:53:39 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-16 08:40:43 +0900 - - Split installation from build section - - Notes: - Merged: https://github.com/ruby/ruby/pull/8223 - -commit efd611ceb661a230f121797079376cdb4e831951 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-16 05:54:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-16 05:54:46 +0900 - - Revert "[ruby/yarp] rust: Initial yarp-sys" - - This reverts commit e6e23b92e3019e27471c9bf7a97db5f95e7a9a29. - - It seems like it wasn't added for ruby/ruby. - - We could fix tool/sync_default_gems.rb to deal with this, but we have a - pull request that changes that part now, so let me only revert this for - now and revisit this after merging that pull request. - -commit e6e23b92e3019e27471c9bf7a97db5f95e7a9a29 - Author: Steve Loveless <steve.loveless@gmail.com> - AuthorDate: 2023-06-27 14:04:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-16 05:52:06 +0900 - - [ruby/yarp] rust: Initial yarp-sys - - Still need to add more tests - - Update Cargo.toml; add README - - Switch yp_string_t_type variants to SNAKE_CASE - - Add unescape tests - - Add encoding callback tests - - Add pack_parse test - - Add diagnostic test - - Add comment test - - Add node tests - - Add string_list tests - - Add other string tests - - Add shared string test - - Add list tests - - Fixes for updated branch - - Run bundle install before running Rust tests - - Fix version test - - ci: Add proper config for rust-toolchain step for sanitizers - - ci: Fix tests, clippy - - Remove extra `bundle install`; run `bundle exec rake` - - Didn't realize `setup-ruby`'s `bundle-cache: true` runs `bundle install`. - - Remove `rake compile` from build.rs - - This is complicating CI for me; maybe we add it back later. - - Undo README formatting changes - - Fix UB in C callbacks - - Use slice+str instead of String for raw things - - Move bindings to bindings module - - Handle non-UTF-8 strings in paths - - rust ci: test with sanitizers; add -D warnings - - Update rust-bindings.yml - - Update Cargo.toml - - Don't need to compile extra crate_types - - PR changes - - Apply patch from @kddnewton - - Delete unescape_tests.rs - - Fix things after rebasing - - https://github.com/ruby/yarp/commit/273790e40b - -commit 0f94e653597dc2ae21ae39ac4c85266f3bb36ab6 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-15 00:24:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-16 04:18:05 +0900 - - Add stat force_incremental_marking_finish_count - - This commit adds key force_incremental_marking_finish_count to - GC.stat_heap. This statistic returns the number of times the size pool - has forced incremental marking to finish due to running out of slots. - -commit 8c5b9ebf7144af73cf52209b73b849c078133dff - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-16 03:43:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-16 03:43:58 +0900 - - [DOC] Improve doc guide compliance (#8221) - -commit d9d4ae511a692568af4638e3fb88dbfdcbcba19b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-15 18:31:37 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-15 23:30:41 +0900 - - Group configure outputs on GitHub Actions - -commit 6066f8d337977add0fae53aeebd14b045be2807f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-15 20:05:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-15 23:30:41 +0900 - - Fix a typo to suppress updating rbconfig.rb during `make up` - -commit b76c2ec0052afc303e254c1e748c2c2a585d6ad5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-14 22:28:19 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-15 23:30:40 +0900 - - Use `::` form workflow commands - -commit 9acc73d7c583649240906b079c270e6ce1d8c50f - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-15 23:08:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-15 23:08:48 +0900 - - YJIT: Optional parameter rework and bugfix (#8220) - - * YJIT: Fix splatting empty array with rest param - - * YJIT: Rework optional parameter handling to fix corner case - - The old code had a few unintuitive parts. The starting PC of the callee - was set in different places; `num_param`, which one would assume to be - static for a particular callee seemingly tallied to different amounts - depending on the what the caller passed; `opts_filled_with_splat` was - greater than zero even when the opts were not filled by items in the - splat array. Functionally, the bits that lets the callee know which - keyword parameters are unspecified were not passed properly when there - are optional parameters and a rest parameter, and then optional - parameters are all filled. - - Make `num_param` non-mut and use parameter information in the callee - iseq as-is. Move local variable nil fill and placing of the rest array - out of `gen_push_frame()` as they are only ever relevant for iseq calls. - Always place the rest array at `lead_num + opt_num` to fix the - previously buggy situation. - - * YJIT: Compile splat calls to iseqs with rest params - - Test interactions with optional parameters. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 2f57db6c778f18a6967b8d7bcca33593fa8f013b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-15 03:08:31 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-15 21:54:27 +0900 - - [DOC] Rename "memory pool" to "heap" - - Notes: - Merged: https://github.com/ruby/ruby/pull/8219 - -commit 01f74b28521069e2582fbd751c34b115fe033a2b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-15 03:06:03 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-15 21:54:27 +0900 - - [DOC] Improve docs about keys in GC.stat_heap - - Notes: - Merged: https://github.com/ruby/ruby/pull/8219 - -commit 2498140777020808a007691516e7bf8d8d862215 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-15 03:04:55 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-15 21:54:27 +0900 - - [DOC] Improve docs for GC.start - - Notes: - Merged: https://github.com/ruby/ruby/pull/8219 - -commit 300bc145892488b91f10438f06fe75d03809424c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-15 03:04:39 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-15 21:54:27 +0900 - - [DOC] Improve some GC docs - - Notes: - Merged: https://github.com/ruby/ruby/pull/8219 - -commit 52837fcec2340048f9bdc2169cde17243c5e9d6d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-15 00:48:39 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-15 00:48:39 +0900 - - [DOC] Remove Document-class from trace_point.rb - -commit 75c9487a98ebb27d38387a0c900ff5b1f34c30d2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-14 23:18:19 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-14 23:18:19 +0900 - - YJIT: Chain guard classes on instance_of (#8209) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 2a3acbc420cc94af07a16d45310554f616dc457a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-12 00:14:08 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-14 11:30:05 +0900 - - Fix test and precheck order for old GNU Make - -commit d33555eeaeac76a76c086c3dd09f53fff88d7f6a - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-14 10:23:41 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-14 10:23:41 +0900 - - [DOC] RDoc for numeric.rb (#8216) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 3080cf3decf18c72c1fc608c112048fff0614c9b - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-08-14 04:20:36 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-14 04:47:12 +0900 - - [DOC] Don't suppress autolinks - - Notes: - Merged: https://github.com/ruby/ruby/pull/8215 - -commit 7f8f62c93bf3d11a0321fa91823065a2ff36f6d0 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-14 03:30:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-14 03:30:34 +0900 - - [ruby/irb] Support seamless integration with ruby/debug - (https://github.com/ruby/irb/pull/575) - - * Support native integration with ruby/debug - - * Prevent using multi-irb and activating debugger at the same time - - Multi-irb makes a few assumptions: - - - IRB will manage all threads that host sub-irb sessions - - All IRB sessions will be run on the threads created by IRB itself - - However, when using the debugger these assumptions are broken: - - - `debug` will freeze ALL threads when it suspends the session (e.g. when - hitting a breakpoint, or performing step-debugging). - - Since the irb-debug integration runs IRB as the debugger's interface, - it will be run on the debugger's thread, which is not managed by IRB. - - So we should prevent the 2 features from being used at the same time. - To do that, we check if the other feature is already activated when - executing the commands that would activate the other feature. - - https://github.com/ruby/irb/commit/d8fb3246be - -commit 9099d62ac77cdca548bc4110e2cb03057ef0ac8f - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-14 00:23:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-14 00:23:04 +0900 - - [ruby/irb] Move IO configuration to IRB::Irb - (https://github.com/ruby/irb/pull/681) - - It shouldn't be `RubyLex`'s responsibility to handle IO. So this moves - the configuration to `IRB::Irb`. - - https://github.com/ruby/irb/commit/daff750076 - -commit eb221a37349806bc202dbea2c088754c674605fc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-13 15:30:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-13 15:30:58 +0900 - - Prohibit copying to `fixtures` and dot-direcotry just under `test` - - Do not add directories which would let chkbuild fires accidentally, to - just under `test`. The "fixtures" directory is often used to place - test stuffs. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8214 - -commit 83718b6bb299c483e60a638ccce98bc8ae1665a1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-13 15:24:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-13 15:24:58 +0900 - - Move test files of ruby/set under `test/set` - - Chkbuild fires accidentally on `test/fixtures` directory. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8214 - -commit efc9127790e2e725541de2c36780a852e6c1382c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-13 15:23:54 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-13 15:23:54 +0900 - - Prefix `excludes` with a dot to prevent chkbuild from firing wrongly - - Chkbuild runs for each directories just under `test` directory when - `test-all` failed. `test/excludes` itself should not be a target. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8214 - -commit b56e5c6b9425a19c04d4e59410463155ea9db30c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-13 01:00:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-13 02:26:49 +0900 - - Fix the precedence of `--backtrace-limit` option - - In general, if the same option specifying a single value is given - multiple times at the same level, the last one overrides the earlier - ones, unless prohibited. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8212 - -commit 546c5cfe4ce1335cb45f8e7b6d6da317c61509e7 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-08-13 01:44:38 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-13 02:04:04 +0900 - - [DOC] Don't suppress autolinks - - Notes: - Merged: https://github.com/ruby/ruby/pull/8213 - -commit b18462c14be62f7572ed03dee470ffb99ae74521 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-08-12 22:54:39 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-12 23:04:39 +0900 - - [DOC] Don't suppress autolinks - - Notes: - Merged: https://github.com/ruby/ruby/pull/8211 - -commit e1683b4958b217d246ff737bdd1b046554c73e18 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-08-12 19:19:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-12 19:19:24 +0900 - - [ruby/irb] Drop showing indent level number in DEFAULT prompt and - INF_RUBY prompt - (https://github.com/ruby/irb/pull/679) - - * Drop showing indent level number in DEFAULT prompt and INF_RUBY prompt - - * Update prompt part of test_rendering's expected result - - https://github.com/ruby/irb/commit/3847532e54 - -commit 680835085df7695b18af40c7a8554f2d314b5de5 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-12 19:17:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-12 19:17:52 +0900 - - [ruby/irb] Reline/ReadlineInputMethod should inherit - StdioInputMethod - (https://github.com/ruby/irb/pull/671) - - They are both built on top of stdio and are basically extended version - of StdioInputMethod. They also share several attributes and methods with - StdioInputMethod. - - https://github.com/ruby/irb/commit/c5f5abdbde - -commit d1b1e4a3ffc294b52c3934fdbce60807b9b708e7 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-08-12 16:00:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-12 16:00:20 +0900 - - Update bundled gems list at 2023-08-12 - -commit 6ebde0420224b73977a35877eb65f0d3700513d5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-12 12:33:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-12 12:33:05 +0900 - - [DOC] Update to use `SPECOPTS` instead of `MSPECOPT` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8210 - -commit 0eb21082146f4a95fa8645fe6ffe1e6929e61e55 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-12 12:32:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-12 12:32:31 +0900 - - Use the default test-spec formatter on Travis - - Notes: - Merged: https://github.com/ruby/ruby/pull/8210 - -commit 46c428a926b00f09b8e50dcd0366422d695e15c8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-11 21:52:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-12 11:19:10 +0900 - - Make test-spec on Windows silent a little - - Notes: - Merged: https://github.com/ruby/ruby/pull/8210 - -commit 2c9fbc51005c15600c03b4dc2f545eabd67734b9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-11 20:17:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-12 11:19:10 +0900 - - Add dotted counts - - Notes: - Merged: https://github.com/ruby/ruby/pull/8210 - -commit 2373feade50c5d32dad253ad0651a6a8c7c2a8ac - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2021-11-27 18:57:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-12 11:19:10 +0900 - - For parallel test - - Notes: - Merged: https://github.com/ruby/ruby/pull/8210 - -commit b377793b6e445ab007e14b51e38260e8613ce843 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2021-11-26 22:31:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-12 11:19:09 +0900 - - Fold dotted outputs from test-spec - - Notes: - Merged: https://github.com/ruby/ruby/pull/8210 - -commit 7740526b1ccf62a027984e35375bb30ccbc0a000 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-12 09:50:53 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-12 09:57:04 +0900 - - Reorder bp_check and jit_return in cfp - - It's the actual cfp[6] in the default build, so it's confusing to say - otherwise in the comment. - -commit 0e162457d686946c69caba6558fb400ace5d8b78 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-12 08:22:21 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-12 08:22:21 +0900 - - [DOC] Don't suppress autolinks (#8208) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 6ccc660d857e9e2275ce4b820291b79904821899 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-12 06:53:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-12 06:53:53 +0900 - - [DOC] Don't suppress autolinks (#8207) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 58424787fc5db65245471940e03241444d10f071 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-12 06:06:08 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-12 06:06:09 +0900 - - Extend the CI timeout for macOS - - https://github.com/ruby/ruby/actions/runs/5836610844/job/15830549311 - -commit 02e5095108e2ce38815fa9957619ed0a1cad4173 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-12 05:07:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-12 05:07:16 +0900 - - YJIT: Implement GET_BLOCK_HANDLER() for invokesuper (#8206) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit d42891079f6eac5e086c246b0a937ab44fa11823 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-08-12 03:51:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-12 03:51:25 +0900 - - [ruby/irb] Remove needless removal of trailing whitespace in - check_code_state - (https://github.com/ruby/irb/pull/678) - - https://github.com/ruby/irb/commit/4a6af7d1ed - -commit 0781e55206d94079c15ab315fc082f49bf8bf780 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-12 03:44:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-12 03:44:52 +0900 - - [ruby/irb] Move assignment check to RubyLex - (https://github.com/ruby/irb/pull/670) - - Since assignment check relies on tokenization with `Ripper`, it feels like - the responsibility of `RubyLex`. `Irb#eval_input` should simply get the result - when calling `each_top_level_statement` on `RubyLex`. - - https://github.com/ruby/irb/commit/89d1adb3fd - -commit c173c637ab7e971a5b6c56deabe9e1a7c95667fb - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-12 03:27:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-12 03:27:17 +0900 - - [ruby/irb] Skip integration tests in core CI - (https://github.com/ruby/irb/pull/677) - - We already skipped history integration tests in core CI in #675 due to - suspicion on nested IRB sessions don't work on certain operating systems. - - But after #669, the evaluation integration test also started to fail on - some Core CI suites. So, it looks like the integration test setup may not - work in Core CI, at least in some suites. - - Consider `ruby/irb` already has rather sophisticated test suite, I think - it's better to skip the integration tests in core CI for now. - - https://github.com/ruby/irb/commit/6f49b4c108 - -commit b6c66604d81d53fda9f717831eac4547891601ad - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-12 03:08:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-12 03:08:45 +0900 - - YJIT: increase max chain depth for expandarray (#8205) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 43721b1d4a474ff24612a62158b6c1cffc473335 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-12 01:18:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-12 01:18:58 +0900 - - [ruby/irb] Don't echo an expression's result when it ends with a - semicolon - (https://github.com/ruby/irb/pull/669) - - https://github.com/ruby/irb/commit/50185c2833 - -commit d3311e5cc3f4606afc9a12e4a4c7e1a19bd722d0 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-12 01:03:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-12 01:03:11 +0900 - - [ruby/irb] Add black and white color to IRB::Color - (https://github.com/ruby/irb/pull/676) - - https://github.com/ruby/irb/commit/a2763acade - -commit a8cd18f08d3ee7475340dfea5eebe2f6b164b5ec - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-12 00:01:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-12 00:01:16 +0900 - - YJIT: implement codegen for rb_int_lshift (#8201) - - * YJIT: implement codegen for rb_int_lshift - - * Update yjit/src/asm/x86_64/mod.rs - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - --------- - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 907560f5dc7831a30994b64d8207740629133abd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-11 15:23:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-11 15:23:48 +0900 - - Fix test-bundler dependencies - -commit 8fbb79f49ec94d48b5ef29bf53b12cbcd24c4bb6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-11 14:47:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-11 14:47:20 +0900 - - Fix order of test-syntax-suggest-prepare for old GNU Make - -commit a792890e9b92b284992a80f7acfcdb13cf142ba5 - Author: S-H-GAMELINKS <gamelinks007@gmail.com> - AuthorDate: 2023-08-09 20:56:16 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-08-11 13:50:00 +0900 - - Remove uneeded fix2int and rational_raw property for Universal Parser - - Notes: - Merged: https://github.com/ruby/ruby/pull/8190 - -commit 654b64822395ead530ac3ecae318197be85c8b52 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-11 12:08:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-11 12:08:29 +0900 - - YJIT: Implement checkmatch instruction (#8203) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit b7453b91dc1e5adc9d5ebe15c644cf5e0a54e3ac - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-11 01:19:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-11 09:46:46 +0900 - - [Bug #19831] Remove duplicate library options - - `$(MAINLIBS)` should include `$(LIBS)` already. - -commit d7c0fec40b700ac9c36b4bfeb2d05a4029d32192 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-11 09:44:00 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-11 09:44:08 +0900 - - Update an outdated YJIT binding - -commit f25e7eac0409d77d0f5e2d3954df680d00fb26f0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-11 09:41:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-11 09:43:10 +0900 - - Fix the yjit-bindgen job - - `YJIT_BINDGEN_DIFF_OPTS=--exit-code make yjit-bindgen` is not the same - as `make yjit-bindgen YJIT_BINDGEN_DIFF_OPTS=--exit-code`, of course. - -commit d2864ca330f7cc7f879e737a817e1161bead65c3 - Author: Sorah Fukumori <sorah@cookpad.com> - AuthorDate: 2023-08-11 05:12:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-11 05:12:21 +0900 - - [ruby/zlib] Zlib.gunzip should not fail with utf-8 strings - (https://github.com/ruby/zlib/pull/55) - - zstream_discard_input was encoding and character-aware when given input is user-provided, so this discards `len` chars instead of `len` bytes. - - Also Zlib.gunzip explains in its rdoc that it is equivalent with the following code, but this doesn't fail for UTF-8 String. - - ```ruby - string = %w[1f8b0800c28000000003cb48cdc9c9070086a6103605000000].pack("H*").force_encoding('UTF-8') - sio = StringIO.new(string) - p gz.read #=> "hello" - gz&.close - p Zlib.gunzip(string) #=> Zlib::DataError - ``` - - Reported and discovered by eagletmt at https://twitter.com/eagletmt/status/1689692467929694209 - - https://github.com/ruby/zlib/commit/c5e58bc62a - -commit b5b34c1f84ffbc87004d4761621040e3ceb3542d - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-11 03:47:03 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-11 03:47:03 +0900 - - YJIT: add mul() instruction to backend IR (#8195) - -commit 3ad306b4f09665f8555006dd78be38e298f7bd2d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-11 03:13:21 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-11 03:13:21 +0900 - - YJIT: Fallback megamorphic super/yield to dynamic dispatch (#8197) - - YJIT: Fallback megamorphic super/yield - - to dynamic dispatch - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit cc0fca2729368f5d5628829a329eb05a86728ace - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-11 00:29:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-11 01:56:50 +0900 - - Fix range of `--backtrace-limit` - - Also an option command line should have precedence over `RUBYOPT`. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8200 - -commit 92cf14b4c5ba4d18140be870bbc5530d1d9e7140 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-11 00:59:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-11 00:59:52 +0900 - - YJIT: Allow VM_CALL_ARGS_BLOCKARG on invokesuper (#8198) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 4ba348ec3e424088bbde1c8ce872420aa9f8a6ad - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-10 17:37:19 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-10 17:37:19 +0900 - - Explicitly require rspec/expectations tentatively - - Maybe only with load-relative, recent changes to bunder/setup.rb seem - affecting weirdly. It fails to load rspec/expectations.rb inside - rspec-core. - -commit bde55d09ede9095fb05dd001474f7ce99277e3ff - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-10 17:35:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-10 17:35:50 +0900 - - Make PREPARE_SYNTAX_SUGGEST include TEST_RUNNABLE prefix - - So that `make PREPARE_SYNTAX_SUGGEST= test-syntax-suggest` works. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8199 - -commit d2343368ab7e270118ea6baa9c6418bfed83135c - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-06-07 23:05:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-10 09:38:11 +0900 - - Deprecate Kernel#open and IO support for subprocess creation/forking - - Deprecate Kernel#open and IO support for subprocess creation and - forking. This deprecates subprocess creation and forking in - - - Kernel#open - - URI.open - - IO.binread - - IO.foreach - - IO.readlines - - IO.read - - IO.write - - This behavior is slated to be removed in Ruby 4.0 - - [Feature #19630] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7915 - -commit 984109b8363790723693ec04897b1155d899115f - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-10 07:28:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-10 07:28:55 +0900 - - [ruby/irb] Skip nested IRB tests in Ruby Core CI - (https://github.com/ruby/irb/pull/675) - - Sometimes the subprocess gets stuck in the nested IRB session until timed - out. We don't have enough information to debug it yet, so skip the tests - to unblock CI. - - https://github.com/ruby/irb/commit/606f18c80c - -commit 1ccd0eae112bce845b728e487cb124159f6eb01c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-10 06:46:42 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-10 06:46:42 +0900 - - YJIT: Chain guard method IDs for respond_to? (#8196) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 493acaf4d4634834ff010aca7f2fa5641f32416a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-10 04:34:30 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-10 04:34:30 +0900 - - YJIT: Distinguish exit and fallback reasons for invokesuper/invokeblock (#8194) - - YJIT: Distinguish exit and fallback reasons - - for invokesuper/invokeblock - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 0b8f15575a440f85ac686f5b0eae8f8b7c2b72e7 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-10 01:18:28 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-10 03:06:58 +0900 - - Fix memory leak for incomplete lambdas - - [Bug #19836] - - The parser does not free the chain of `struct vtable`, which causes - memory leaks. - - The following script reproduces this issue: - - ``` - 10.times do - 100_000.times do - Ripper.parse("-> {") - end - - puts `ps -o rss= -p #{$$}` - end - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8192 - -commit 5bc8fceca8d47ed1ef9c603c6531a408de36b60c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-10 00:03:13 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-10 03:06:58 +0900 - - Fix memory leak in parser for incomplete tokens - - [Bug #19835] - - The parser does not free the `tbl` of the `struct vtable` when there are - leftover `lvtbl` in the parser. This causes a memory leak. - - The following script reproduces this issue: - - ``` - 10.times do - 100_000.times do - Ripper.parse("class Foo") - end - - puts `ps -o rss= -p #{$$}` - end - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8192 - -commit d3efce69eaabf1ff81bcdf3631350a87ac0dda28 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-10 02:16:15 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-10 02:16:15 +0900 - - YJIT: Count throw instructions for each tag (#8188) - - * YJIT: Count throw instructions for each tag - - * Show % of each throw type - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit c9b30f9d76ec7c726a703a7f8aad95b5998e7d6c - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-10 02:12:21 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-10 02:12:21 +0900 - - YJIT: implement imul instruction encoding in x86 assembler (#8191) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit a41c617e41c09b028af36d42bde1a1c1f83a7c22 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-10 01:21:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-10 01:21:53 +0900 - - Implement MUL instruction for aarch64 (#8193) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit ab0f90f1f5583a64a125701e3b08f6620f029eb6 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-09 23:57:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-09 23:57:52 +0900 - - [ruby/irb] Fix nested IRB sessions' history saving - (https://github.com/ruby/irb/pull/652) - - 1. Dynamically including `HistorySavingAbility` makes things unnecessarily - complicated and should be avoided. - 2. Because both `Reline` and `Readline` use a single `HISTORY` constant - to store history data. When nesting IRB sessions, only the first IRB - session should handle history loading and saving so we can avoid - duplicating history. - 3. History saving callback should NOT be stored in `IRB.conf` as it's - recreated every time `IRB.setup` is called, which would happen when - nesting IRB sessions. - - https://github.com/ruby/irb/commit/0fef0ae160 - -commit 6acfc50bccf0c201f77c274281ac33920a0a6923 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-09 22:54:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-09 22:54:24 +0900 - - YJIT: Count all opt_getconstant_path exit reasons (#8187) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 5eef3ce21f09401814b9c4a1932e75f2fc962248 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-08-09 22:47:42 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-09 22:47:42 +0900 - - YJIT: Correct name of a counter (#8186) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 86f4415fb8e1da61eb9e844c68e41e30393eeac7 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-08-09 15:35:16 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-08-09 15:35:16 +0900 - - Prevent a warning: global variable `$VERSION' not initialized - -commit 48c3b0867221c79c0a079a006ae628318c4cb3a7 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-08-09 15:34:45 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-08-09 15:34:45 +0900 - - Prevent warnings: assigned but unused variable - -commit 1b0da1e6236ad9a380abfe4ca8b51f06c34bb6f9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-09 08:46:12 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-09 08:46:12 +0900 - - Skip running brew upgrade (#8189) - - This has been unstable: - https://github.com/ruby/ruby/actions/runs/5797755676/job/15713988590 - - and I'm not sure if we need that in the first place, assuming the - OS image itself is maintained by GitHub. - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit cd8d20cd1fbcf9bf9d438b306beb65b2417fcc04 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-09 08:06:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-09 08:06:22 +0900 - - YJIT: Compile exception handlers (#8171) - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 74b9c7d2079ce2b762bc555f491d00f863fcf94d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-08 22:07:06 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-08 22:44:13 +0900 - - Remove wrapper functions of RVALUE_REMEMBERED - - Functions rgengc_remembered, rgengc_remembered_sweep, and - rgengc_remembersetbits_get are just wrappers of RVALUE_REMEMBERED and - doesn't do much more. We can remove all those and use RVALUE_REMEMBERED - directly instead. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8137 - -commit 397a77557c38fb910a5491d47720298fc18c00bc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-05 11:11:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-08 22:21:39 +0900 - - [ruby/yarp] Fix wrong conversion and cast - - Conversions from `uint64_t`/`VALUE` to `long` may loose upper bits. - - https://github.com/ruby/yarp/commit/c26f650d96 - -commit 72d1a790cfe0e4a457db98c587f1acaa5e39f001 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-08 19:03:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-08 19:03:38 +0900 - - [Bug #19833] Fix index underflow at superclasses of `BasicObject` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8185 - -commit 694d99dda2f101cc261f00c7526b0e36b826b6f1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-06 23:34:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-08 08:48:53 +0900 - - Share duplicate code between Wasm and the others - - Notes: - Merged: https://github.com/ruby/ruby/pull/8182 - -commit 1a83474ded0b3ed90549c4c6e43e0b3e9ab09851 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-06 13:32:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-08 08:34:53 +0900 - - Simplify try-rescue loop - - Notes: - Merged: https://github.com/ruby/ruby/pull/8182 - -commit 89dbca894f677f7c6de1b648ad93d88548f22887 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-06 13:28:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-08 08:34:53 +0900 - - Remove unnecessary braces which make indents confusing - - Notes: - Merged: https://github.com/ruby/ruby/pull/8182 - -commit 0387b86c3a763fad64739ce0029d1af58253bfbf - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-08 00:30:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-08 00:30:13 +0900 - - [ruby/irb] Remove unused `InputMethod#initialize` - (https://github.com/ruby/irb/pull/635) - - * Remove unused InputMethod#initialize - - The constructor takes a `file_name` argument, but it is never used. The - only input method that needs a file is `FileInputMethod`, which has its - own constructor to take a file object directly. - - So the constructor in `InputMethod` is not needed and its child classes - don't need to call `super` in their constructors. - - * Remove unused FileInputMethod#file_name - - https://github.com/ruby/irb/commit/153b1e9d1c - -commit 589c01c4114ba247c7b8a981ddff839f4b0507bc - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-07 22:51:03 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-07 22:51:03 +0900 - - [DOC] RDoc for Process (#8179) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 11f33ba6204909ebbb142283bc9395d3343db28e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-06 17:24:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-07 10:32:47 +0900 - - Add hints of tag jumps for optimization - - Just as the state was originally passed as the return value of - `longjmp`, the state stored in EC cannot be 0 when the jump is - captured now too. - -commit ef5b1d19c1573290bcf9d5b33bf12656825d2e3b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-06 13:25:23 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-06 18:45:40 +0900 - - Turn `jit_exec` and `jit_compile` into macros if disabled - - Notes: - Merged: https://github.com/ruby/ruby/pull/8181 - -commit acd27e3ec3f89d06fb63c24e0fb4ee597af9ad36 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-05 11:03:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-06 18:45:40 +0900 - - Move `GC_CAN_COMPILE_COMPACTION` definition before used - - Notes: - Merged: https://github.com/ruby/ruby/pull/8181 - -commit 3651f985f0d950b636b3b75528855a25293c48b6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-06 09:26:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-06 09:26:20 +0900 - - Exclude files added to the toplevel - -commit ac07d881971292ea3cd4f2761648414e7cedb6ee - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-06 02:21:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-06 02:30:36 +0900 - - [ruby/yarp] Add a Requirements section in Build System docs - - https://github.com/ruby/yarp/commit/298025314c - -commit 489120f18b244689ba0481cfc717b2c66cc058b3 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-04 01:18:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-06 02:30:35 +0900 - - [ruby/yarp] Small fixes to docs/build_system.md - - https://github.com/ruby/yarp/commit/f9db0c282b - - Co-authored-by: Mike Dalessio <mike.dalessio@gmail.com> - -commit 11f10bb1ac4453ca1aab3f4055f7da9c6e950a56 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-04 01:17:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-06 02:30:35 +0900 - - [ruby/yarp] Clarify shared library - - https://github.com/ruby/yarp/commit/0b174b76f1 - - Co-authored-by: Mike Dalessio <mike.dalessio@gmail.com> - -commit 70ef66f2408c43bbbcf7a4df6e9e69131161a9c0 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-03 07:01:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-06 02:30:34 +0900 - - [ruby/yarp] Document the build system of YARP - - https://github.com/ruby/yarp/commit/85ae0e2816 - -commit 4e6861d3376eb7857d2b0a947c97b6fec8e5bf37 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-05 12:07:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-05 18:56:37 +0900 - - Fix `Gem::BUNDLED_GEMS.find_gem` return value - - If the required name is different from the found gem name, return the - gem name, instead of true that means the required name is an exact gem - name. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8178 - -commit e176f84138ff4fc5f7442cc969a281aeb714e7bd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-05 12:36:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-05 12:50:46 +0900 - - Just suppress a warning for non-Emscripten Wasm build - - Revert "Revert "Skip calling jit_exec on Wasm"" - - This reverts commit 2e94610f70baca4af004202f288a6b5dd10889ca. - - It's not about whether it's optimized away or not. I just don't want to - leave and maintain the callsite (e.g. signature) in the path where - YJIT is never built. - -commit 2e94610f70baca4af004202f288a6b5dd10889ca - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-05 10:47:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-05 12:12:42 +0900 - - Revert "Skip calling jit_exec on Wasm" - - This reverts commit e80752f9bbc5228dba3066cd95a81e2e496bd9d7. - - RJIT and YJIT are never enabled on Wasm. When both are disabled, - `jit_exec` is defined to return `Qundef` constantly, and is optimized - away. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8176 - -commit 4e7e972841f73b222e46b86ebff191e06fe49da5 - Author: S-H-GAMELINKS <gamelinks007@gmail.com> - AuthorDate: 2023-08-04 12:18:00 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-08-05 11:39:38 +0900 - - Remove uneeded int2big property for Universal Parser - - Notes: - Merged: https://github.com/ruby/ruby/pull/8170 - -commit f07ef1d54c3bbae62e2ddd7266932c294db91daf - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-08-04 19:16:38 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-08-05 10:32:41 +0900 - - Lrama v0.5.3 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8175 - -commit e80752f9bbc5228dba3066cd95a81e2e496bd9d7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-05 07:39:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-05 07:39:02 +0900 - - Skip calling jit_exec on Wasm - - We often break Wasm build when we modify how jit_exec works. I'm - planning to modify it again soon. - - We actually don't support running Ruby JIT on Wasm, so it doesn't seem - worth the maintenance effort. - -commit 8d7861e3daf64e0bd30b2f9fe56f94eadfde5d3f - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-05 03:57:56 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-05 03:57:56 +0900 - - YJIT: expand bitwise shift support in x86 assembler (#8174) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit c4066af35e6578aee39a1324d6209f45b0bfa265 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-05 02:13:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-05 02:13:55 +0900 - - [ruby/irb] Store integration tests' envs in an ivar - (https://github.com/ruby/irb/pull/668) - - https://github.com/ruby/irb/commit/bbd20445ea - -commit fc0b2a8df2327b40a2f6667c1567b3f8264b58a5 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-04 23:09:43 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-04 23:09:43 +0900 - - YJIT: guard for array_len >= num in expandarray (#8169) - - Avoid generating long dispatch chains for all array lengths seen. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 61b76e74afa0976ff97685aa6e762633a3d43376 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-04 00:08:22 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-04 22:13:57 +0900 - - Revert "Tests to move between size pools are flaky on Windows too" - - This reverts commit c5abe0d08f8f7686422e6eef374cf8c78aefacb6. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8166 - -commit 4b45b2764b293af45c159d3772692b52752e662a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-03 23:35:44 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-04 22:13:57 +0900 - - Don't check stack for moved after compaction - - We don't need to check stack for moved objects after compaction because - the mutator cannot run between marking the stack and the end of - compaction. However, the stack may have moved objects leftover from - marking and sweeping phases. This means that their pages will be - invalidated and all objects moved back. We don't need to move these - objects back. - - This also fixes the issue on Windows where some compaction tests - sometimes fail due to the page of the object being invalidated. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8166 - -commit 6b570ff2c0f3383f22a456eee6049715c9276383 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-04 19:23:29 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-04 21:12:09 +0900 - - Display call location with bundled gems warning - - Notes: - Merged: https://github.com/ruby/ruby/pull/8172 - -commit ae8fd392d5b97c650a44db8bbfad24664aa5e995 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-04 19:20:39 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-04 21:12:09 +0900 - - Fixed worng key of bundled_gems list - - Notes: - Merged: https://github.com/ruby/ruby/pull/8172 - -commit a0b695b4e6e2c2edc566558c0b9588dd3b85d712 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-04 18:11:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-04 21:12:09 +0900 - - Also decorate warning message with future tense for bundler - - Notes: - Merged: https://github.com/ruby/ruby/pull/8172 - -commit ede3c5ee0f2ffa616724ef455420ba82c01c49ab - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-04 18:08:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-04 21:12:09 +0900 - - Use future tense if current version is older than list version - - Notes: - Merged: https://github.com/ruby/ruby/pull/8172 - -commit 48f035228044e06634b46d59c8a255455cbddd70 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-04 13:50:07 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-04 20:59:46 +0900 - - Fetch the last element only when not empty - - Also `flag_keyword_hash` sets to 0 or a hash object. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8173 - -commit 0dc0c24cadb231091bb4dbe68860b2bd41713253 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-04 20:15:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-04 20:16:04 +0900 - - [ruby/irb] Fix IntegrationTestCase - (https://github.com/ruby/irb/pull/667) - - https://github.com/ruby/irb/commit/79fc6dcf5f - -commit 4f99240b2e457608e3a86926df7aa4baf535ef0d - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-04 05:14:44 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-04 05:14:44 +0900 - - YJIT: add jb (unsigned less-than) instruction to backend (#8168) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 98b4256aa7a558e19739ac1d39ba10179277e1f4 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-04 05:09:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-04 05:09:18 +0900 - - YJIT: handle expandarray_rhs_too_small case (#8161) - - * YJIT: handle expandarray_rhs_too_small case - - YJIT: fix csel bug in x86 backend, add test - - Remove commented out lines - - Refactor expandarray to use chain guards - - Propagate Type::Nil when known - - Update yjit/src/codegen.rs - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - * Add missing counter, use get_array_ptr() in expandarray - - * Make change suggested by Kokubun to reuse loop - - --------- - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 132f097149af36cb77308d9fe1c1a94940ab2089 - Author: Kunshan Wang <wks1986@gmail.com> - AuthorDate: 2023-08-03 21:35:22 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-04 03:52:44 +0900 - - No computing embed_capa_max in str_subseq - - Fix str_subseq so that it does not attempt to predict the size of the - object returned by str_alloc_heap. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8165 - -commit c65856d44f91cbcf8fd8172c609b96f936938070 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-04 00:12:07 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-04 00:12:07 +0900 - - Remove unneeded function prototype - - Function prototype for gc_mode_transition is not needed as it's not - used before the implementation. - -commit aeff31168ad59d29c0b5a068db0009d46558f3ab - Author: Kunshan Wang <wks1986@gmail.com> - AuthorDate: 2023-08-02 18:53:01 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-03 21:34:24 +0900 - - No computing embed_capa_max in ary_make_partial - - ary_make_partial now uses the actual embed_capa of an allocated heap - array to guide whether make an embedded copy or a slice view. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8164 - -commit 5336b2f0db928f2d89d9aedbec5337e58218ceed - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-03 13:43:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-03 13:43:04 +0900 - - Move a local variable declaration after the protected region - -commit 8f2bbbbcaf4b0b1686a40c4a1c7dd1909d307d40 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-03 02:02:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-03 13:17:41 +0900 - - Add assertion in `RHASH_AR_TABLE_BOUND` - -commit fe977314d5a9fdf721584c0396e1040960d78000 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-03 01:43:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-03 09:51:52 +0900 - - Check if reader members are set - -commit 4b6c584023f41827c891f33a16cb5db221b7cd19 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-03 06:02:37 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-03 09:11:08 +0900 - - Remove --disable-gems for assert_separately - - assert_separately adds --disable=gems so we don't need to add - --disable-gems when calling assert_separately. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8162 - -commit 5f5cc22b5f5983b3cea0a96bfc5584f645a90b8e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-03 08:23:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-03 08:23:55 +0900 - - gdb.py: Print Env based on EP instead of BP - - because EP could be escaped. - -commit 32e828bb4a6c65a392b2300f3bdf93008c7b6f25 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-03 03:35:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-03 03:35:08 +0900 - - [ruby/irb] Deprecate multi-irb commands - (https://github.com/ruby/irb/pull/654) - - * Deprecate multi-irb commands - - - Print deprecated message when any of the commands are used - - Put related commands under `Multi-irb` category with a deprecated - label - - * Update readme - - https://github.com/ruby/irb/commit/861731ac12 - -commit 8ecd300e1e51f9e56bf22a8c4fb64ef475612914 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-03 03:33:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-03 03:33:43 +0900 - - [ruby/irb] Extract integration testing helpers out of debug command - tests - (https://github.com/ruby/irb/pull/660) - - The ability to run a test case in a subprocess is useful for testing - many other features, like nested IRB sessions. So I think it's worth - extracting them into a new test case class. - - https://github.com/ruby/irb/commit/73b7a895f8 - -commit dc54574adefe798702cc93457655da40f4939669 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-03 01:53:03 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-08-03 01:53:03 +0900 - - Update to ruby/spec@9e278f5 - -commit e20f1e443f6d0a4d377ef237fffc1f4c6e27c9e1 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2023-08-03 00:33:12 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-03 00:33:12 +0900 - - YJIT: Fallback setivar if the receiver isn't T_OBJECT (#8160) - - Followup: https://github.com/ruby/ruby/pull/8152 - - If the receiver is a T_MODULE or T_CLASS and has a lot of - ivars, `get_next_shape_internal` will return `NULL`. - - Co-authored-by: Jean Boussier <byroot@ruby-lang.org> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 3c41a04b6cedbace1406d46a20a673f59b1502de - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-08-03 00:08:19 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-08-03 00:13:38 +0900 - - Fix encoding switches when RUBYOPT is empty or only spaces - - * Follow-up of dbbc3583ba432c279f07b1fa0afb0a8a9ba50c91 which broke this. - -commit a502cd80a592c90dc76daf06687ce67bdb183d02 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-02 23:55:07 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-02 23:55:07 +0900 - - Fix wrong assignment - -commit 81c198b5cfced7f9e8205e726bf686763370ce18 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-02 23:19:39 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-02 23:19:39 +0900 - - YJIT: Distinguish exit and fallback reasons for send (#8159) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 452debba22cfae0ed61042afb21f2bf86135c1dc - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-02 23:16:37 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-02 23:16:37 +0900 - - YJIT: Fix --yjit-dump-disasm coloring on less(1) (#8158) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit d405410e3c6ecfdefe345f2b78cf740effe784a1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-02 23:15:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-02 23:15:29 +0900 - - YJIT: Move ROBJECT_OFFSET_* to yjit.c (#8157) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 1d096c1e53581ed9fe94694c9760babd1e12e580 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-02 05:53:45 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-02 22:08:12 +0900 - - Fix crash in NoMethodError for dummy frames - - [Bug #19793] - - Dummy frames are created at the top level when requiring another file. - While requiring a file, it will try to convert using encodings. Some of - these encodings will not respond to to_str. If method_missing is - redefined on Object, then it will call method_missing and attempt raise - an error. However, the iseq is invalid as it's a dummy frame so it will - write an invalid iseq to the created NoMethodError. - - The following script crashes: - - ``` - GC.stress = true - - class Object - public :method_missing - end - - File.write("/tmp/empty.rb", "") - require "/tmp/empty.rb" - ``` - - With the following backtrace: - - ``` - frame #0: 0x00000001000fa8b8 miniruby`RVALUE_MARKED(obj=4308637824) at gc.c:1638:12 - frame #1: 0x00000001000fb440 miniruby`RVALUE_BLACK_P(obj=4308637824) at gc.c:1763:12 - frame #2: 0x00000001000facdc miniruby`gc_writebarrier_incremental(a=4308637824, b=4308332208, objspace=0x000000010180b000) at gc.c:8822:9 - frame #3: 0x00000001000faad8 miniruby`rb_gc_writebarrier(a=4308637824, b=4308332208) at gc.c:8864:17 - frame #4: 0x000000010016aff0 miniruby`rb_obj_written(a=4308637824, oldv=36, b=4308332208, filename="../iseq.c", line=1279) at gc.h:804:9 - frame #5: 0x0000000100162a60 miniruby`rb_obj_write(a=4308637824, slot=0x0000000100d09888, b=4308332208, filename="../iseq.c", line=1279) at gc.h:837:5 - frame #6: 0x0000000100165b0c miniruby`iseqw_new(iseq=0x0000000100d09880) at iseq.c:1279:9 - frame #7: 0x0000000100165a64 miniruby`rb_iseqw_new(iseq=0x0000000100d09880) at iseq.c:1289:12 - frame #8: 0x00000001000d8324 miniruby`name_err_init_attr(exc=4309777920, recv=4304780496, method=827660) at error.c:1830:35 - frame #9: 0x00000001000d1b80 miniruby`name_err_init(exc=4309777920, mesg=4308332496, recv=4304780496, method=827660) at error.c:1869:12 - frame #10: 0x00000001000d1bd4 miniruby`rb_nomethod_err_new(mesg=4308332496, recv=4304780496, method=827660, args=4308332448, priv=0) at error.c:1957:5 - frame #11: 0x000000010039049c miniruby`rb_make_no_method_exception(exc=4304914512, format=4308332496, obj=4304780496, argc=1, argv=0x000000016fdfab00, priv=0) at vm_eval.c:959:16 - frame #12: 0x00000001003b3274 miniruby`raise_method_missing(ec=0x0000000100b06f40, argc=1, argv=0x000000016fdfab00, obj=4304780496, last_call_status=MISSING_NOENTRY) at vm_eval.c:999:15 - frame #13: 0x00000001003945d4 miniruby`rb_method_missing(argc=1, argv=0x000000016fdfab00, obj=4304780496) at vm_eval.c:944:5 - ... - frame #23: 0x000000010038f5e4 miniruby`rb_vm_call_kw(ec=0x0000000100b06f40, recv=4304780496, id=2865, argc=1, argv=0x000000016fdfab00, me=0x0000000100cbfcf0, kw_splat=0) at vm_eval.c:326:12 - frame #24: 0x00000001003c18e4 miniruby`call_method_entry(ec=0x0000000100b06f40, defined_class=4304927952, obj=4304780496, id=2865, cme=0x0000000100cbfcf0, argc=1, argv=0x000000016fdfab00, kw_splat=0) at vm_method.c:2720:20 - frame #25: 0x00000001003c440c miniruby`check_funcall_exec(v=6171896792) at vm_eval.c:589:12 - frame #26: 0x00000001000dec00 miniruby`rb_vrescue2(b_proc=(miniruby`check_funcall_exec at vm_eval.c:587), data1=6171896792, r_proc=(miniruby`check_funcall_failed at vm_eval.c:596), data2=6171896792, args="Pȗ") at eval.c:919:18 - frame #27: 0x00000001000deab0 miniruby`rb_rescue2(b_proc=(miniruby`check_funcall_exec at vm_eval.c:587), data1=6171896792, r_proc=(miniruby`check_funcall_failed at vm_eval.c:596), data2=6171896792) at eval.c:900:17 - frame #28: 0x000000010039008c miniruby`check_funcall_missing(ec=0x0000000100b06f40, klass=4304923536, recv=4304780496, mid=3233, argc=0, argv=0x0000000000000000, respond=-1, def=36, kw_splat=0) at vm_eval.c:666:15 - frame #29: 0x000000010038fa60 miniruby`rb_check_funcall_default_kw(recv=4304780496, mid=3233, argc=0, argv=0x0000000000000000, def=36, kw_splat=0) at vm_eval.c:703:21 - frame #30: 0x000000010038fb04 miniruby`rb_check_funcall(recv=4304780496, mid=3233, argc=0, argv=0x0000000000000000) at vm_eval.c:685:12 - frame #31: 0x00000001001c469c miniruby`convert_type_with_id(val=4304780496, tname="String", method=3233, raise=0, index=-1) at object.c:3061:15 - frame #32: 0x00000001001c4a4c miniruby`rb_check_convert_type_with_id(val=4304780496, type=5, tname="String", method=3233) at object.c:3153:9 - frame #33: 0x00000001002d59f8 miniruby`rb_check_string_type(str=4304780496) at string.c:2571:11 - frame #34: 0x000000010014b7b0 miniruby`io_encoding_set(fptr=0x0000000100d09ca0, v1=4304780496, v2=4, opt=4) at io.c:11655:19 - frame #35: 0x0000000100139a58 miniruby`rb_io_set_encoding(argc=1, argv=0x000000016fdfb450, io=4308334032) at io.c:13497:5 - frame #36: 0x00000001003c0004 miniruby`ractor_safe_call_cfunc_m1(recv=4308334032, argc=1, argv=0x000000016fdfb450, func=(miniruby`rb_io_set_encoding at io.c:13487)) at vm_insnhelper.c:3271:12 - ... - frame #43: 0x0000000100390b08 miniruby`rb_funcall(recv=4308334032, mid=16593, n=1) at vm_eval.c:1137:12 - frame #44: 0x00000001002a43d8 miniruby`load_file_internal(argp_v=6171899936) at ruby.c:2500:5 - ... - ``` - -commit 85ee4a65a22ebe6f3c65f0b10397bd6ebb976333 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-02 19:30:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-02 19:55:31 +0900 - - Allow to override environment variables for debug - -commit ffe0f9eb6cfbc388a0da979ed173da94fae46c82 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-02 19:16:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-02 19:55:30 +0900 - - `EnvUtil.invoke_ruby` also passes ASAN options - -commit 28c2136722823ce5b69d07bd723b8a76b8b172d8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-02 17:17:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-02 18:56:13 +0900 - - [rubygems/rubygems] Replaced remained local to lockfile - - https://github.com/rubygems/rubygems/commit/6ed69223d4 - -commit fd8dd7199665ed26818a140de945cca71d6fc84b - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2023-06-08 12:27:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-02 18:18:17 +0900 - - Implement StringIO#pread (#56) - - Both for being closer to real IOs and also because it's a convenient API - in multithreaded scenarios. - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - -commit 201fd5751897618eb2a9a91f6f14241f0bad4744 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-09 15:25:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-02 18:17:27 +0900 - - [ruby/irb] Drop src_encoding.rb - (https://github.com/ruby/irb/pull/634) - - Its method `IRB.default_src_encoding` was only used in `magic-file.rb`, - which has been removed. - - https://github.com/ruby/irb/commit/ed98983b1f - -commit fe255277817b55ee0ca0113194043b66eacc0f3a - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-07-03 16:56:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-02 18:17:20 +0900 - - [ruby/fiddle] Include stdbool.h explicitly - - https://github.com/ruby/fiddle/commit/c313a74632 - -commit 673f4493b059fc1b1af8872dc9a9edfc652c7251 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-07-03 16:53:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-02 18:17:19 +0900 - - [ruby/fiddle] Include stdbool.h explicitly - - https://github.com/ruby/fiddle/commit/69ff680bf6 - -commit 15e8cf7ad95f5ea9ec95783e85a9ac5943f020f4 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-07-03 16:43:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-02 18:17:18 +0900 - - [ruby/fiddle] Add support for bool - - GitHub: fix https://github.com/ruby/fiddle/pull/130 - - Reported by Benoit Daloze. Thanks!!! - - https://github.com/ruby/fiddle/commit/bc6c66bbb9 - -commit 10588fa12136b30b44affa209cb49afd4a8d7aa7 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-07-03 16:43:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-02 18:17:16 +0900 - - [ruby/fiddle] Use ifdef - - https://github.com/ruby/fiddle/commit/6cdf53726d - -commit fd782dcd1e52326d81c5a776acfff362609df2f7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-08-02 14:22:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-08-02 14:25:16 +0900 - - Revert "YJIT: implement `expandarray_rhs_too_small` case (#8153)" - - This reverts commit 3b88a0bee841aee77bee306d9d34e587561515cf. - - This commit break aarch64 platform and Apple Silicon - -commit 15b2e912300f43fb6fdf9f663d0979efb464efba - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-01 16:25:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-02 13:21:20 +0900 - - Remove `kprintf` in addr2line.c - - According to @naruse, this `kprintf` was to avoid some segfaults, but - turned out it seemed another issue after all. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8148 - -commit 31d12267636d9694f5580bef9c74650b05671345 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-01 12:11:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-02 13:21:20 +0900 - - Avoid aborting inside addr2line.c - - Notes: - Merged: https://github.com/ruby/ruby/pull/8148 - -commit df6071c49ffa83bc215c41f744a76e37d48fc79a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-02 07:33:05 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-08-02 07:36:27 +0900 - - Do not auto-cancel builds on pull requests - - For some reason, there was a pull request that contains a YJIT change - but did not run Cirrus CI, which ended up failing Cirrus CI on master. - - This `auto_cancellation` config seems suspicious. Now that we have - `only_if`, I don't think we need an extra guard besides that. - -commit 5ff1c00e17cd83dd42e9d96d5b415c7c5f0f3615 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-02 06:46:14 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-02 06:46:14 +0900 - - YJIT: Let local yjit-bindgen exit successfully (#8156) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 3b88a0bee841aee77bee306d9d34e587561515cf - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-08-02 04:58:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-02 04:58:00 +0900 - - YJIT: implement `expandarray_rhs_too_small` case (#8153) - - * YJIT: handle expandarray_rhs_too_small case - - * YJIT: fix csel bug in x86 backend, add test - - * Remove commented out lines - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 16b91a346f734efea0933495804b53e3ae15f1da - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-08-02 03:43:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-02 03:43:32 +0900 - - YJIT: Fallback setivar if the next shape is too complex (#8152) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit d68c01fd314ebd6dc1d89c95a2734fad4f0953b0 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-08-01 17:25:20 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-08-01 22:46:17 +0900 - - support `rescue` event for TracePoint - - fix [Feature #19572] - - Notes: - Merged: https://github.com/ruby/ruby/pull/8150 - -commit f11ac06337fc56104172c3241393fd95d3a6c60d - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-01 21:51:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-01 21:51:30 +0900 - - [ruby/irb] Add workspace category - (https://github.com/ruby/irb/pull/661) - - * Create a new Workspace command category - - * Update readme - - https://github.com/ruby/irb/commit/310650c213 - -commit 382678d4112f4afc6272244c22924d2b004274b1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-31 11:12:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-01 19:00:31 +0900 - - [Bug #19788] Use the result of `tCOLON2` event - - Notes: - Merged: https://github.com/ruby/ruby/pull/8144 - -commit 6a5c548218035bfdaf226c7ab1d0af37c9480900 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-08-01 16:51:36 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-08-01 18:06:25 +0900 - - remove strange line event - - ```ruby - def helper_cant_rescue - begin - raise SyntaxError - rescue - cant_rescue # here - end - end - ``` - - on this case, a line event is reported on `cant_rescue` line - because of node structure. it should not be reported. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8149 - -commit 0622c78869b0e9381bd709e2330b7e24feb1fb46 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-08-01 14:54:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-01 14:54:16 +0900 - - [DOC] Update warning categories - - - Fix indentations of labeled lists. - - Mention performance category. - -commit 533dcb8e52dca91ce699c0990301939d69c102fc - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-08-01 10:44:56 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-01 10:44:56 +0900 - - RDoc for module Process (#8141) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 0b8045c9c9b9f9c3e22e38f7d77b273efb2db2b0 - Author: Shugo Maeda <shugo@ruby-lang.org> - AuthorDate: 2023-08-01 09:48:47 +0900 - Commit: Shugo Maeda <shugo@ruby-lang.org> - CommitDate: 2023-08-01 09:48:47 +0900 - - Supress warnings by Refinement#refined_class in test code - -commit de91ce980ad6022a506ec12c7eb20392a37e98fe - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-31 20:08:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-01 09:31:22 +0900 - - [rubygems/rubygems] Use Kernel.singleton_class - - https://github.com/rubygems/rubygems/commit/9be984f281 - -commit ec0e6809f9247a8028500d3e915ab01f63c7d59b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-01 09:02:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-01 09:02:32 +0900 - - Skip flaky test on Solaris - - This test is flaky on "SPARC Solaris 10 (gcc)" CI with this message: - - TestGCCompact#test_moving_objects_between_size_pools [test/ruby/test_gc_compact.rb:378]: - Expected 499 to be >= 500. - -commit 04f4e0aeb2e9543e360a566eca0d1cea859b13dd - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-08-01 04:26:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-01 05:10:23 +0900 - - [ruby/yarp] Document building, more macro changes - - https://github.com/ruby/yarp/commit/4214f262d2 - -commit 5d78ec8a94b7d44b5b152f4fad7e419a2436fe70 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-08-01 04:57:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-08-01 04:57:36 +0900 - - [ruby/irb] Decouple `edit` and `show_source` commands - (https://github.com/ruby/irb/pull/658) - - * Decouple `edit` command from `show_source` - - 2 commands should not depend on each other. If `edit` command also needs - to find a source, the source finding logic should be extracted into a - separate class. - - * Return nil if is not an actual file path - - * Refactor SourceFinder - - https://github.com/ruby/irb/commit/9790517a0c - -commit c01b17f7fc74f005f23da0405eb8bad08a269a18 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-01 04:12:20 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-01 04:12:20 +0900 - - Fix default value of global_init_slots - - Not setting a value to global_init_slots causes get_envparam_size to - output a broken default value. - -commit 954b7ac81ef503df3c1efc5566df985b08951d52 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-08-01 03:56:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-08-01 03:56:53 +0900 - - addr2line.c: fix `DW_FORM_ref_addr` parsing for DWARF 2 (#8146) - - addr2line.c: fix DW_FORM_ref_addr parsing for DWARF 2 - - This fixes a crash when retrieving backtrace info with YJIT enabled on - macOS with Rust 1.71.0. Since Rust 1.71.0, the DWARF info generated by - the Rust compiler uses DW_FORM_ref_addr instead of DW_FORM_ref4 for - pointers to other DIEs. - DW_FORM_ref_addr representation in DWARF 2 is different from DWARF 3+, - so we need to handle it separately. - This patch fixes the parsing of DW_FORM_ref_addr for DWARF 2, which is - the default DWARF version Rustc uses on macOS. - - See the DWARF 2.0.0 spec, section 7.5.4 Attribute Encodings - https://dwarfstd.org/doc/dwarf-2.0.0.pdf - - https://bugs.ruby-lang.org/issues/19789 - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 36d669b73db26368cb9492231be4b3d4ed97f111 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-08-01 03:52:25 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-01 03:52:25 +0900 - - Fix test_gc_parameter_init_slots - - If the stack is not cleared (e.g. compiling with -O0), then `ary` could - remain on the stack, which would be marked. Clear the array first to - make sure all the objects can be GC'd. - -commit 8b390a456ce7dc7ef942a8a2cfba2a944c3d25bd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-31 23:24:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-08-01 01:47:19 +0900 - - [DOC] Update description of `Process.daemon` arguments - - These arguments can only be `true` or `false` now. Also add markups. - -commit 547d2378acca6ee376a9f1b0a619c919e834b3cb - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-31 23:26:43 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-01 00:46:53 +0900 - - Assert that at least one element has been embedded - - It's not guaranteed that the first element will always be embedded. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8116 - -commit b98838b65cbf8fa2d228f9e0249414cba4e3197d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-31 22:24:48 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-08-01 00:46:53 +0900 - - Store initial slots per size pool - - This commit stores the initial slots per size pool, configured with - the environment variables `RUBY_GC_HEAP_INIT_SIZE_%d_SLOTS`. This - ensures that the configured initial slots remains a low bound for the - number of slots in the heap, which can prevent heaps from thrashing in - size. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8116 - -commit 1bda22f5fedea5364c6df321a3004c47c732144e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-31 23:23:30 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-31 23:23:30 +0900 - - `Refinement#refined_class` is now deprecated - -commit d42b9ffb20658b6c0e3f75d7a3f3917d976abb1f - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-29 00:28:44 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-31 22:17:18 +0900 - - Reuse Regexp ptr when recompiling - - When matching an incompatible encoding, the Regexp needs to recompile. - If `usecnt == 0`, then we can reuse the `ptr` because nothing else is - using it. This avoids allocating another `regex_t`. - - This speeds up matches that switch to incompatible encodings by 15%. - - Branch: - - ``` - Regex#match? with different encoding - 1.431M (± 1.3%) i/s - 7.264M in 5.076153s - Regex#match? with same encoding - 16.858M (± 1.1%) i/s - 85.347M in 5.063279s - ``` - - Base: - - ``` - Regex#match? with different encoding - 1.248M (± 2.0%) i/s - 6.342M in 5.083151s - Regex#match? with same encoding - 16.377M (± 1.1%) i/s - 82.519M in 5.039504s - ``` - - Script: - - ``` - regex = /foo/ - str1 = "日本語" - str2 = "English".force_encoding("ASCII-8BIT") - - Benchmark.ips do |x| - x.report("Regex#match? with different encoding") do |times| - i = 0 - while i < times - regex.match?(str1) - regex.match?(str2) - i += 1 - end - end - - x.report("Regex#match? with same encoding") do |times| - i = 0 - while i < times - regex.match?(str1) - i += 1 - end - end - end - ``` - -commit a542512b7c394847a488e9b94d9defebe26003ce - Author: Shugo Maeda <shugo@ruby-lang.org> - AuthorDate: 2023-07-14 15:13:14 +0900 - Commit: Shugo Maeda <shugo.maeda@gmail.com> - CommitDate: 2023-07-31 17:23:17 +0900 - - Add Refinement#target and deprecate Refinement#refined_class - - [Feature #19714] - - Notes: - Merged: https://github.com/ruby/ruby/pull/8075 - -commit cfd7729ce7a31c8b6ec5dd0e99c67b2932de4732 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-07-31 16:17:55 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-07-31 17:13:43 +0900 - - use inline cache for refinements - - From Ruby 3.0, refined method invocations are slow because - resolved methods are not cached by inline cache because of - conservertive strategy. However, `using` clears all caches - so that it seems safe to cache resolved method entries. - - This patch caches resolved method entries in inline cache - and clear all of inline method caches when `using` is called. - - fix [Bug #18572] - - ```ruby - # without refinements - - class C - def foo = :C - end - - N = 1_000_000 - - obj = C.new - require 'benchmark' - Benchmark.bm{|x| - x.report{N.times{ - obj.foo; obj.foo; obj.foo; obj.foo; obj.foo; - obj.foo; obj.foo; obj.foo; obj.foo; obj.foo; - obj.foo; obj.foo; obj.foo; obj.foo; obj.foo; - obj.foo; obj.foo; obj.foo; obj.foo; obj.foo; - }} - } - - _END__ - user system total real - master 0.362859 0.002544 0.365403 ( 0.365424) - modified 0.357251 0.000000 0.357251 ( 0.357258) - ``` - - ```ruby - # with refinment but without using - - class C - def foo = :C - end - - module R - refine C do - def foo = :R - end - end - - N = 1_000_000 - - obj = C.new - require 'benchmark' - Benchmark.bm{|x| - x.report{N.times{ - obj.foo; obj.foo; obj.foo; obj.foo; obj.foo; - obj.foo; obj.foo; obj.foo; obj.foo; obj.foo; - obj.foo; obj.foo; obj.foo; obj.foo; obj.foo; - obj.foo; obj.foo; obj.foo; obj.foo; obj.foo; - }} - } - __END__ - user system total real - master 0.957182 0.000000 0.957182 ( 0.957212) - modified 0.359228 0.000000 0.359228 ( 0.359238) - ``` - - ```ruby - # with using - - class C - def foo = :C - end - - module R - refine C do - def foo = :R - end - end - - N = 1_000_000 - - using R - - obj = C.new - require 'benchmark' - Benchmark.bm{|x| - x.report{N.times{ - obj.foo; obj.foo; obj.foo; obj.foo; obj.foo; - obj.foo; obj.foo; obj.foo; obj.foo; obj.foo; - obj.foo; obj.foo; obj.foo; obj.foo; obj.foo; - obj.foo; obj.foo; obj.foo; obj.foo; obj.foo; - }} - } - - Notes: - Merged: https://github.com/ruby/ruby/pull/8129 - -commit 280419d0e0ba3e96e19551c70cba789fbedd80e1 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-07-31 16:04:16 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-07-31 17:13:43 +0900 - - `calling->cd` instead of `calling->ci` - - `struct rb_calling_info::cd` is introduced and `rb_calling_info::ci` - is replaced with it to manipulate the inline cache of iseq while - method invocation process. So that `ci` can be acessed with - `calling->cd->ci`. It adds one indirection but it can be justified - by the following points: - - 1) `vm_search_method_fastpath()` doesn't need `ci` and also - `vm_call_iseq_setup_normal()` doesn't need `ci`. It means - reducing `cd->ci` access in `vm_sendish()` can make it faster. - - 2) most of method types need to access `ci` once in theory - so that 1 additional indirection doesn't matter. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8129 - -commit e40f8bbd20eb65d14992f1f7dce12b4c5edf614e - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-07-31 15:59:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-31 15:59:54 +0900 - - Update bundled gems list at 2023-07-31 - -commit a3c0e9d90d657d9b288fb4a50462684087f4162f - Author: Mat Sadler <mat@sourcetagsandcodes.com> - AuthorDate: 2023-07-29 13:19:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-31 15:25:21 +0900 - - [rubygems/rubygems] update Magnus library in Rust extension gem template - - https://github.com/rubygems/rubygems/commit/19a92a3367 - -commit 36023d5cb751d62fca0c27901c07527b20170f4d - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-07-31 12:26:27 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-07-31 14:04:31 +0900 - - mark `cc->cme_` if it is for `super` - - `vm_search_super_method()` makes orphan CCs (they are not connected - from ccs) and `cc->cme_` can be collected before without marking. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8145 - -commit 60ac719acc3e4eccab770ebdd959dffcb702f2f2 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-07-31 00:35:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-31 12:26:47 +0900 - - [ruby/optparse] [DOC] Corrections to tutorial - - https://github.com/ruby/optparse/commit/2940dbb65a - -commit 52722ea37b48411a1bc727411d46fdbad36c0084 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-30 19:38:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-30 19:38:18 +0900 - - Extract common variables - -commit b5c74d548872388921402ff2db36be15e924a89b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-30 15:13:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-30 15:13:58 +0900 - - Ease the `Encoding::CompatibilityError` test failure - - At the time this test first started using `assert_raise_with_message`, - it did not touch `Encoding.default_internal`. - -commit dfad14d83f1a51a537d03da285b71e9d87a6da7f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-30 11:24:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-30 11:35:22 +0900 - - [ruby/optparse] [DOC] Mark up constant and method names as code - - https://github.com/ruby/optparse/commit/e8bee0be8f - -commit 67be453d9d1e94b104ba2f092d89c33efac2a2e2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-29 10:21:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-30 10:37:43 +0900 - - [rubygems/rubygems] Set thread configurations inside block in the thread local manner - - https://github.com/rubygems/rubygems/commit/965e54b8f1 - -commit 0d86cc4caf1495507b2937654d3ed868278b9ddc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-28 14:26:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-30 10:36:23 +0900 - - [rubygems/rubygems] Use the dedicated method to convert file path - - The dedicated method `File.path` to deal with pathname-like objects - has been provided since ruby 1.9.0. - Also adds a test for rubygems/rubygems#6837. - - https://github.com/rubygems/rubygems/commit/258c6eda80 - -commit bde4080b3989b4f097371b5cadb82bf6cb7c45b1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-30 10:14:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-30 10:14:04 +0900 - - YJIT: Drop Copy trait from Context (#8138) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 087a2deccfb9d99961f1ce8526b80c5f72ee9a5d - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-07-30 07:08:33 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-07-30 08:11:53 +0900 - - check `cc->*` liveness strictly - - to fix SEGV like - http://ci.rvm.jp/results/trunk-repeat20-asserts@ruby-sp2-docker/4664004 - ``` - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(sigsegv+0x4f) [0x7fcb0343e7df] /tmp/ruby/src/trunk-repeat20-asserts/signal.c:920 - /lib/x86_64-linux-gnu/libc.so.6(0x7fcb02e4d520) [0x7fcb02e4d520] - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(RB_SPECIAL_CONST_P+0x13) [0x7fcb03311ea3] /tmp/ruby/src/trunk-repeat20-asserts/include/ruby/internal/special_consts.h:329 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(RB_BUILTIN_TYPE) /tmp/ruby/src/trunk-repeat20-asserts/include/ruby/internal/value_type.h:183 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_object_moved_p) /tmp/ruby/src/trunk-repeat20-asserts/gc.c:1624 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_object_moved_p+0xe) [0x7fcb0331ed16] /tmp/ruby/src/trunk-repeat20-asserts/include/ruby/internal/special_consts.h:329 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_ref_update_imemo) /tmp/ruby/src/trunk-repeat20-asserts/gc.c:10132 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_update_object_references) /tmp/ruby/src/trunk-repeat20-asserts/gc.c:10411 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_ref_update+0xab) [0x7fcb0331fcbb] /tmp/ruby/src/trunk-repeat20-asserts/gc.c:10570 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_update_references) /tmp/ruby/src/trunk-repeat20-asserts/gc.c:10604 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_compact_finish) /tmp/ruby/src/trunk-repeat20-asserts/gc.c:5425 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_sweep_compact) /tmp/ruby/src/trunk-repeat20-asserts/gc.c:8476 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_sweep) /tmp/ruby/src/trunk-repeat20-asserts/gc.c:6040 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_start+0xe25) [0x7fcb03325795] /tmp/ruby/src/trunk-repeat20-asserts/gc.c:9323 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(rb_multi_ractor_p+0x0) [0x7fcb03326108] /tmp/ruby/src/trunk-repeat20-asserts/gc.c:9208 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(rb_vm_lock_leave) /tmp/ruby/src/trunk-repeat20-asserts/vm_sync.h:92 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(garbage_collect) /tmp/ruby/src/trunk-repeat20-asserts/gc.c:9210 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(rbimpl_atomic_exchange+0x0) [0x7fcb033262b9] /tmp/ruby/src/trunk-repeat20-asserts/gc.c:9646 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_finalize_deferred) /tmp/ruby/src/trunk-repeat20-asserts/gc.c:4345 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_start_internal) /tmp/ruby/src/trunk-repeat20-asserts/gc.c:9647 - /tmp/ruby/build/trunk-repeat20-asserts/libruby.so.3.3(gc_compact) /tmp/ruby/src/trunk-repeat20-asserts/gc.c:10748 - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8142 - -commit 4bdb61b665665141402c46e14dc1bea245e13fd5 - Author: Joshua Young <djry1999@gmail.com> - AuthorDate: 2023-07-29 22:40:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-30 01:02:20 +0900 - - [DOC] Fix missing word in a comment - -commit 3d87eec94a4778cabd48726b00867a0092de5ad0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-27 08:26:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-30 00:44:13 +0900 - - Add examples of `return` in `eval` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8127 - -commit df5330b04eda80d00a1f406573ae6b9e5f71c533 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-07-26 21:08:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-30 00:31:48 +0900 - - [ruby/rdoc] Use a more portable way to check if code is parseable - - * The same as used in irb: https://github.com/ruby/irb/pull/134/files - * This works on all Ruby implementations, unlike `return` in BEGIN which - can be quite difficult to support. - - https://github.com/ruby/rdoc/commit/d19f7c66fe - -commit 628cc7e12d7e5cdee2fea7d4490f6f5fbef3adb9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-29 13:42:14 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-29 20:02:47 +0900 - - Change `HOME` too when testing sync_default_gems.rb - - As well as `GIT_CONFIG_GLOBAL`, which is supported since git 2.32. - -commit 4b91d6abb907fe3375fbd04a6af910d8b1792d78 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-29 20:02:13 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-29 20:02:13 +0900 - - Revert "Test sync_default_gems.rb only when git 2.32 is available" - - This reverts commit b0f44cfa5da53b90817732cb25b4d3a1cddecb89. - -commit 7a7aba755d8da34555445510dc568380d0d96791 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-07-29 13:41:28 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-07-29 14:25:15 +0900 - - check liveness of cc->klass and cc->cme_ - - `cc->klass` and `cc->cme_` can be free'ed while last marking - so that it should be checked bofore updating the pointers. - - Note that `T_MOVED` is living, but `is_live_object()` returns false. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8139 - -commit b0f44cfa5da53b90817732cb25b4d3a1cddecb89 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-29 11:49:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-29 11:49:53 +0900 - - Test sync_default_gems.rb only when git 2.32 is available - - With older git, as `GIT_CONFIG_GLOBAL` environment variable is not - supported, these tests clobber user's configurations. - -commit 6dc15cc8895b28800d5c187929d846ac4eb7cd3f - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-07-29 07:54:30 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-07-29 09:06:14 +0900 - - do not clear cme but invalidate cc - - To invalidate a cc, we need to clear cc->klass by `vm_cc_invalidate()`. - I hope this patch fix the CI failures. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8134 - -commit bcf823fddbe38e0503805a7ba6ded53c1bc1e19d - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-07-29 07:28:52 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-07-29 07:39:10 +0900 - - Revert "[rubygems/rubygems] Set thread configurations inside block" - - This reverts commit db80e947a382a6a9ef2295e81f5b97c6a8ecbce7. - - This patch uses `Thread.abort_on_exception = true` and it affects - all of threads. This is why CI systems fails. - - How to modify: - - - use `thread.abort_on_exception = true` for specific threads - - Run this code in a separated process - -commit 17b50cdb68ce016caee0d6fef8e8438a5bf5addb - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-07-24 08:18:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-29 01:08:11 +0900 - - [rubygems/rubygems] Add charset to Webauthn response content-type - - https://github.com/rubygems/rubygems/commit/442a3e8f37 - -commit db80e947a382a6a9ef2295e81f5b97c6a8ecbce7 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-07-24 08:18:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-29 01:08:10 +0900 - - [rubygems/rubygems] Set thread configurations inside block - - https://github.com/rubygems/rubygems/commit/860b145359 - -commit afca1a31d05f3334342628a93d4d796c95e5f5fe - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-07-20 14:42:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-29 01:08:10 +0900 - - [rubygems/rubygems] Create MockServer object to test WebAuthn logic to prevent real TCPServers from being created and be leaked into other tests - - https://github.com/rubygems/rubygems/commit/96d6cb33a2 - -commit 3954a87d65f004e5148597ffa927dc7b9eef6fb8 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-07-11 13:40:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-29 01:08:09 +0900 - - [rubygems/rubygems] Create MultifactorAuthFetcher to reduce duplication among tests - - https://github.com/rubygems/rubygems/commit/dead211206 - -commit e96b3138a85d42fe5ee5ef4ddd1ea12b784e8d80 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-07-01 13:20:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-29 01:08:09 +0900 - - [rubygems/rubygems] Use assert_raise in webauthn poller tests - - https://github.com/rubygems/rubygems/commit/0969ad330e - -commit 24913e3dda3d4ebd633e94e46ca221ebfcb9f89b - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-07-01 12:45:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-29 01:08:08 +0900 - - [rubygems/rubygems] Move Webauthn listener thread to WebauthnListener class - - https://github.com/rubygems/rubygems/commit/6ec474975e - -commit fce04f9a6c9935ef3f188558dce177e277b17711 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-06-30 05:10:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-29 01:08:08 +0900 - - [rubygems/rubygems] Move WebauthnListener into the Gem::GemcutterUtilities namespace - - https://github.com/rubygems/rubygems/commit/3080394f81 - -commit 108cc38a7658bfb8e9457f95baa5cdfbd175b64d - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-06-30 04:39:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-29 01:08:07 +0900 - - [rubygems/rubygems] Extract polling logic into its own class - - https://github.com/rubygems/rubygems/commit/218b83abed - -commit 023d0f662b4487c2bd6636c4fcf1e223ef4c8b30 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-06-22 06:21:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-29 01:08:07 +0900 - - [rubygems/rubygems] Add Webauthn verification poller to fetch OTP - - https://github.com/rubygems/rubygems/commit/39c5e86a67 - -commit 836e4eb3cd4c61823bf812957b555bb0ef79ade5 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-06-22 02:39:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-29 01:08:06 +0900 - - [rubygems/rubygems] Remove fetcher login in util_sign_in - - https://github.com/rubygems/rubygems/commit/8e6bc4485a - -commit 812dbe79f0c8f73fdb71214240ba1a1cd3b6a857 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-06-22 02:20:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-29 01:08:06 +0900 - - [rubygems/rubygems] Create SignInFetcher - - https://github.com/rubygems/rubygems/commit/38afc47899 - -commit 9f059d908ca6b8a31377ed1494547571e764ca10 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-26 19:02:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-28 22:17:54 +0900 - - Freeze test string to be shared for sharable-middle-substring - -commit af04e2692422e63edf0666daad4def52aac65141 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-26 16:57:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-28 22:17:53 +0900 - - Fill terminator properly - -commit 7cfabe1acc55b24fc2c479a87efa71cf74e9e8fc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-28 17:50:25 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-28 19:39:43 +0900 - - Preserve `ec` argument across `longjmp` - - Fix segfault on icc 2023.2. - An optimizer may allocate this argument to a register, and it may be - clobbered by `longjmp`, e.g. exceptions. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8135 - -commit 6391132c03ac08da0483adb986ff9a54e41f9e14 - Author: Ruby <test@ruby-lang.org> - AuthorDate: 2023-07-28 11:03:32 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-07-28 18:01:42 +0900 - - fix typo (CACH_ -> CACHE_) - -commit 5de82ed4015ab55ef2e1f8eaed1038a25cc55895 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-07-28 15:59:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-28 15:59:38 +0900 - - Update bundled gems list at 2023-07-28 - -commit 2deeb0e0bf8b871b556a7bd2be2817fbf3d50889 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-27 16:17:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-28 14:57:10 +0900 - - Removed unnecessary methods - - Notes: - Merged: https://github.com/ruby/ruby/pull/8126 - -commit 35517baae5a1bb5fa77771f7d465d0bf40c96a5d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-27 15:17:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-28 14:57:10 +0900 - - Use Gem::BUNDLED_GEMS::SINCE - - Notes: - Merged: https://github.com/ruby/ruby/pull/8126 - -commit 989f3add62f45d6bf0250810c3c14e2bf22ddb78 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-11 18:08:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-28 14:57:10 +0900 - - Warn default gems which will be gemified in future - - Notes: - Merged: https://github.com/ruby/ruby/pull/8126 - -commit b9c2f4a42417572a5edf5a21bf606456facd3731 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-28 14:49:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-28 14:49:03 +0900 - - Fixed gemfile path for upstream of bundler - -commit ce6c6c7cfae7bb328ef796b57a8daa1e6fba9955 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-28 13:15:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-28 13:15:12 +0900 - - Exclude lockfile from sync target - -commit 93f57dbcefcb4aebfc8625ffac47499498f743ed - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-28 12:49:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-28 12:49:55 +0900 - - Update description for test-bundler on gitignore - -commit 426434556f43e597da8ddfa33c659321971f1b83 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-28 12:47:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-28 12:47:31 +0900 - - Removed lockfile for test-bundler - -commit c330037c1a38cc257dbe21022fcc7b13159c2821 - Author: Ruby <test@ruby-lang.org> - AuthorDate: 2023-07-26 13:39:31 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-07-28 10:51:11 +0900 - - `cc->cme` should not be marked. - - cc is callcache. - - cc->klass (klass) should not be marked because if the klass is - free'ed, the cc->klass will be cleared by `vm_cc_invalidate()`. - - cc->cme (cme) should not be marked because if cc is invalidated - when cme is free'ed. - - klass marks cme if klass uses cme. - - caller classe's ccs->cme marks cc->cme. - - if cc is invalidated (klass doesn't refer the cc), - cc is invalidated by `vm_cc_invalidate()` and cc->cme is - not be accessed. - - On the multi-Ractors, cme will be collected with global GC - so that it is safe if GC is not interleaving while accessing - cc and cme. - - fix [Bug #19436] - - ```ruby - 10_000.times{|i| - # p i if (i%1_000) == 0 - - str = "x" * 1_000_000 - def str.foo = nil - eval "def call#{i}(s) = s.foo" - send "call#{i}", str - } - ``` - - Without this patch: - - ``` - real 1m5.639s - user 0m6.637s - sys 0m58.292s - ``` - - and with this patch: - - ``` - real 0m2.045s - user 0m1.627s - sys 0m0.164s - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8120 - -commit 44b19b01e22c0e2b24e97cbcab80aee953f978fd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-28 09:36:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-28 09:36:07 +0900 - - Remove an obsoleted initialization from Wasm - -commit 8c7cf2de98c56039820c2861d1f0ed85c0961e12 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-28 09:31:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-28 09:31:27 +0900 - - Remove an unused argument in vm_exec_core - -commit 38be9a9b72d606024eb94900ed834b08493a1518 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-28 09:27:05 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-28 09:27:05 +0900 - - Clean up OPT_STACK_CACHING (#8132) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit bf4d64d8d0a35a1e92707e0cb2706348f21eb9b5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-28 08:50:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-28 08:50:50 +0900 - - Remove an unused macro - - We've deleted opt_call_c_function instruction before. - -commit cf0c907bc7f7f435887a50b350a8b489aa7ff7f8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-28 08:35:30 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-28 08:35:30 +0900 - - YJIT: Count setivar too-complex exits (#8131) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 437a4ccbf2e944a7029fc55df789e0fbb945f162 - Author: Xavier Noria <fxn@hashref.com> - AuthorDate: 2023-07-28 06:01:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-28 08:07:19 +0900 - - [rubygems/rubygems] Restore support for Pathname objects in the replaced require - - https://github.com/rubygems/rubygems/commit/f7b4282ef7 - -commit 97219721752e7cc1eda51131d6a3cd753d37276c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-28 07:28:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-28 07:30:10 +0900 - - Resurrect rb_reg_prepare_re C API - - Existing strscan releases rely on this C API. It means that the current - Ruby master doesn't work if your Gemfile.lock has strscan unless it's - locked to 3.0.7, which is not released yet. - - To fix it, let's not remove the C API we've exposed to users. - -commit 5669a28fde3b767953b5a7d6e63cd8e53f0185eb - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-07-28 06:47:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-28 06:47:29 +0900 - - YJIT: implement missing `asm.jg` instruction in backend (#8130) - - YJIT: implement missing jg instruction in backend - - While trying to implement a specialize integer left shift, I ran - into a problem where we have no way to do a greater-than comparison - at the moment. Surprising we went this far without ever needing it. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 83f9d80c0b0b7752e490abb45145073d8d0e656d - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-07-28 06:09:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-28 06:09:08 +0900 - - downloader.rb: unlink broken symlink before caching to fix ENOENT - - On GitHub CI, the downloader's cache is shared across different jobs. - For some systems, the cached config.guess ends up being a symlink to - /usr/share/autoconf/build-aux/config.guess and containers that don't - have that file end up consuming the cache anyways, leading to ENOENT - when trying to cache the downloaded file. - - This error happened on forks: - - https://github.com/XrXr/ruby/actions/runs/5675262636/job/15380232344 - - https://github.com/peterzhu2118/ruby/actions/runs/5684765421/job/15408188728 - -commit f72f3ab15b79d35e3ddc53d7d3df0e75d5402575 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-28 04:39:05 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-28 04:39:05 +0900 - - Use onig_new_without_alloc for onig_new - -commit 7633299c5080b2b37b134ce3c1c82491d127d4d2 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-07-27 07:12:46 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-07-28 04:03:46 +0900 - - YJIT: getblockparamproxy for when block is a Proc - - Notes: - Merged: https://github.com/ruby/ruby/pull/8124 - -commit 34825ed20d25e6b06916876484c996caad036dd0 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-07-27 07:22:23 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-07-28 04:03:46 +0900 - - Revert "YJIT: Fix naming for a getblockparamproxy counter" - - This reverts commit e7804963f09d7df7f6cce44fbb3e37809c9a15cc. - Oops. The counter was for getblockparam, without "proxy", so - it was aptly named. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8124 - -commit 69b20d1196f363b3990694951832408556b4ac04 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-28 03:41:12 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-28 03:41:12 +0900 - - Don't load RREGEXP_PTR twice - -commit 511c51e116fdd44314bef977e941d90331d07efd - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-28 03:04:02 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-28 03:04:02 +0900 - - Refactor err string in rb_reg_prepare_re - -commit 7193b404a1a56e50f8046d0382914907020c1559 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-27 04:57:03 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-28 02:33:40 +0900 - - Add function rb_reg_onig_match - - rb_reg_onig_match performs preparation, error handling, and cleanup for - matching a regex against a string. This reduces repetitive code and - removes the need for StringScanner to access internal data of regex. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8123 - -commit e5effa4bd063f454f9f304e6f9fbf9dd8b353a76 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-28 02:09:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-28 02:09:17 +0900 - - YJIT: Use dynamic dispatch for megamorphic send (#8125) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit e27eab2f85f3d16a822b5c239d44d6fb34d72e5f - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-27 22:42:42 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-27 22:42:42 +0900 - - [ruby/strscan] Sync missed commit - - Syncs commit ruby/strscan@76b377a5d875ec77282d9319d62d8f24fe283b40. - -commit ccca097cb54e3c23fb2e9a83dacfffa84acdcad8 - Author: osyo-manga <manga.osyo@gmail.com> - AuthorDate: 2023-07-27 18:08:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-27 18:08:24 +0900 - - [ruby/reline] Add `kill-word` and `backward-kill-word` keymapping - support. - (https://github.com/ruby/reline/pull/570) - - Fix it - https://github.com/ruby/reline/issues/558 - - https://github.com/ruby/reline/commit/0f8000443e - - Co-authored-by: Stan Lo <stan001212@gmail.com> - -commit b201ac0bc037e460d96673f1d7386f1d2652b5c1 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-27 17:23:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-27 17:23:08 +0900 - - [ruby/reline] Bump version to 0.3.7 - (https://github.com/ruby/reline/pull/578) - - https://github.com/ruby/reline/commit/dc5a1b7c48 - -commit 46ca0e1ce44d4c81dd85453f3874b406b13e799f - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-07-27 16:00:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-27 16:00:06 +0900 - - Update bundled gems list at 2023-07-27 - -commit 9bdd48597297dcb01a7e07f5a0f716c4ea9cc1e1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-27 04:59:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-27 04:59:59 +0900 - - YJIT: Count the number of dynamic send dispatches (#8122) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 37160be439c9a368c206b2eec713820dc97e4e0f - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-07-27 02:15:10 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-07-27 02:58:15 +0900 - - YJIT: Fix naming for a getblockparamproxy counter - - The rest of the counters are prefixed with `gbpp_` and that's what - `yjit.rb` uses when printing the summary. This counter wasn't included - in the summary. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8121 - -commit 499eb3990faeaac2603787f2a41b2d9625e180dc - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-07-26 16:49:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-26 23:46:20 +0900 - - [ruby/yarp] Fix tests - - https://github.com/ruby/yarp/commit/50e745767e - -commit c680ae2ce1e535196eeb06228176d9308f7cab84 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-07-26 16:11:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-26 23:46:19 +0900 - - [ruby/yarp] Added locations to errors tests - - https://github.com/ruby/yarp/commit/108d1221ef - -commit 47ff17a413e9f345dd935479f703d3d2964b237d - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-07-26 04:38:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-26 23:46:19 +0900 - - [ruby/yarp] Fix error and warning locations - - https://github.com/ruby/yarp/commit/b91317ab39 - -commit bd5cc4d6a0150c0d32b49b73947f9dde1189a322 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-07-26 04:36:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-26 23:46:18 +0900 - - [ruby/yarp] Add comments test - - https://github.com/ruby/yarp/commit/6484af4165 - -commit 59e5bf2d1fdcdd65c17bfd08a6f7644acc41be04 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-07-26 04:14:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-26 23:46:17 +0900 - - [ruby/yarp] Fix comment locations - - https://github.com/ruby/yarp/commit/7d2a1f8f1f - -commit 8ca399d64023fd13bd17bc38132610ccb2ccc598 - Author: ywenc <ywenc@github.com> - AuthorDate: 2023-07-26 23:38:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-26 23:38:59 +0900 - - Implement `opt_aref_with` instruction (#8118) - - Implement gen_opt_aref_with - - Vm opt_aref_with is available - - Test opt_aref_with - - Stats for opt_aref_with - - Co-authored-by: jhawthorn <jhawthorn@github.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 786a864900ceee6ed89d7df81698bbbe7e7bd6ae - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-06-23 01:44:51 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-07-26 23:27:15 +0900 - - Make {Nil,True,False}Class#singleton_method always raise NameError - - {Nil,True,False}Class#singleton_methods always returns [] indicating - that there are no singleton methods defined, so #singleton_method - should be consistent with that. - - Fixes [Bug #11064] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7973 - -commit 9b405a18bea7825cba794e42a1fef58a48451ec3 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-21 20:38:25 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-07-26 18:41:23 +0900 - - Process.warmup: precompute strings coderange - - This both save time for when it will be eventually needed, - and avoid mutating heap pages after a potential fork. - - Instrumenting some large Rails app, I've witnessed up to - 58% of String instances having their coderange still unknown. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8112 - -commit 283b2fdab4be77d8721d7cf298168eb6e3798490 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-26 17:31:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-26 17:32:02 +0900 - - [ruby/irb] Page `ls`'s output (https://github.com/ruby/irb/pull/657) - - * Page ls command's output - - * Use Pager.page_content in show_cmds too - - https://github.com/ruby/irb/commit/82d1687302 - -commit 26aef1c73639718bc00c271ce7176bf3ee565c12 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-30 16:12:56 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-26 11:39:29 +0900 - - Use `lex_eol_p` family - - Notes: - Merged: https://github.com/ruby/ruby/pull/8119 - -commit 6500f85927135901f365d2ba1186c5c4f2881f8e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-21 12:21:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-26 08:51:57 +0900 - - Added Gem::BUNDLED_GEMS for warning feature of Bundler - -commit 14691d39e9bc312ea813ceb895f887ca6893e5d9 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-07-26 07:46:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-26 07:46:00 +0900 - - Revert "GitHub Actions: fix ENOENT for jobs running in forks" - - Revert b106cf2eef574535fa2a069493235b00d679d20a. - Sorry, it didn't actually fix the problem. See for example: - https://github.com/peterzhu2118/ruby/actions/runs/5659386206/job/15332833836 - - The plot thickens. - -commit d8cee5507361b2cd3f3baccb8fda45bad8389a70 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-26 03:33:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-26 03:33:23 +0900 - - [ruby/irb] Display `show_cmds`'s output in a pager when in TTY - environment - (https://github.com/ruby/irb/pull/647) - - This can: - - - Make it easier to scroll up and down the commands list - - Avoid pushing up users' previous output - - Allow users to do basic search with `/<word>` - - https://github.com/ruby/irb/commit/f94e8a66dd - -commit e1104017e3080fd432c0b5fdc3ae6e004ffd0834 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-26 02:20:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-26 02:20:04 +0900 - - YJIT: Fix cfp inconsistency on tailcall (#8107) - - [Bug #19781] - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 99162dee7aa478d8a65f028b098bdaa69e1ecad5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-25 16:07:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-25 19:30:15 +0900 - - [Bug #19751] Remove linemarkers in middle - - Notes: - Merged: https://github.com/ruby/ruby/pull/8115 - -commit 377639053dfdf8037a1b3d3211071c6af1916e35 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-25 18:39:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 18:39:58 +0900 - - [ruby/reline] Avoid using CSI # S for scroll down - (https://github.com/ruby/reline/pull/577) - - https://github.com/ruby/reline/commit/b67ee4e791 - -commit cf1f2e9d06a2fb699d911492425c4090e02b3eb1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-21 12:30:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:29 +0900 - - [rubygems/rubygems] bin/rubocop -A - - https://github.com/rubygems/rubygems/commit/e8a4184429 - -commit 979d1fa5fe57f441ceca10f513d6009ddd78b8f2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-21 12:21:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:28 +0900 - - [rubygems/rubygems] Extract Gem::BUNDLED_GEMS from Bundler - - https://github.com/rubygems/rubygems/commit/e30e86aa60 - -commit 8fbe7d0295fd38496b61e2e1a93c920f93892aa4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-21 10:21:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:28 +0900 - - [rubygems/rubygems] Skip warnings if bundled gems is already loaded - - https://github.com/rubygems/rubygems/commit/9583a7eb82 - -commit 422144d220e8cfec38c0b07b2ba142aa5fa9066b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-20 17:49:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:27 +0900 - - [rubygems/rubygems] Use Kernel.singleton_class - - https://github.com/rubygems/rubygems/commit/f2e8e054df - -commit 6bb34a7684955a45638f48101df01c1deaff8d62 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-20 13:24:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:27 +0900 - - [rubygems/rubygems] Don't reuse require argument - - https://github.com/rubygems/rubygems/commit/1712cd6149 - -commit 64530b545fec528de3423fbfe83dbe2138754715 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-20 12:58:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:26 +0900 - - [rubygems/rubygems] Added warnings targets for old version of Ruby - - https://github.com/rubygems/rubygems/commit/d0c1d97105 - -commit fc5dbea4c3aca71b97db22b47b934454705ceed8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-20 11:38:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:26 +0900 - - [rubygems/rubygems] Added Ruby version for bundled gems to warnings - - https://github.com/rubygems/rubygems/commit/d61c1362e7 - -commit ec600332fcf60a0d54cf5de1051d189270931ee3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-20 11:05:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:25 +0900 - - [rubygems/rubygems] Simplefied condition - - https://github.com/rubygems/rubygems/commit/5238fcf234 - -commit 2424b921b2e773343fa7dd670c40e26873adc22f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-20 11:02:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:25 +0900 - - [rubygems/rubygems] make bundled gemst list as constant under Gem namespace - - https://github.com/rubygems/rubygems/commit/438eac5447 - -commit cc2617ae3f82b6ae12965d9974680f3d15462745 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-20 10:41:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:24 +0900 - - [rubygems/rubygems] Added csv as stub gem to build_repo1 - - https://github.com/rubygems/rubygems/commit/d2f2597c31 - -commit df4ac25bd957b4a22acc3243de4af310efc473f1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-20 09:34:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:24 +0900 - - [rubygems/rubygems] Added examples for warnings feature - - https://github.com/rubygems/rubygems/commit/78807add23 - -commit 0ae227ebe22bcec74fcd5fd6acd1b724ab0d8c16 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-20 09:10:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:23 +0900 - - [rubygems/rubygems] Also check Kernel.require for infinite loop - - https://github.com/rubygems/rubygems/commit/961d9ac1bd - -commit a23fe8e84d8c73e45062008b4d020d47161858f3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-19 21:03:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:23 +0900 - - [rubygems/rubygems] Avoid infinite call of require - - https://github.com/rubygems/rubygems/commit/9c345bfa3e - -commit bb61e45ae7be8fb456561369d2c37600694f2887 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-19 20:57:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:22 +0900 - - [rubygems/rubygems] Keep Kernel#require private - - https://github.com/rubygems/rubygems/commit/cd59e73efa - -commit 95cde6e4c22946c03ddaa66f055d7671cd51e0ad - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-19 19:11:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:22 +0900 - - [rubygems/rubygems] Don't use redefine_method - - https://github.com/rubygems/rubygems/commit/f733f90110 - -commit f5e03ef31cde82b8d801d2d67eac4e9191dda2ca - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-19 16:35:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 15:23:21 +0900 - - [rubygems/rubygems] Warn if file is loaded without Gemfile - - https://github.com/rubygems/rubygems/commit/bf59dcdad1 - -commit 70eeec0cad7daa56bee91967657d7dd86ca36e18 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-19 22:42:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 13:52:54 +0900 - - [rubygems/rubygems] Simplify double loop - - https://github.com/rubygems/rubygems/commit/630dc02112 - -commit 1b27e7aa1fbd4c3c9a8640e94b1cd8818f4901d1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-19 22:38:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 13:52:54 +0900 - - [rubygems/rubygems] Use `Monitor#synchronize` to ensure to exit - - https://github.com/rubygems/rubygems/commit/b424353239 - -commit f72ddd92be0ea80cfc230c5d972d27f91dd3cb1b - Author: Kentaro Takeyama <n.y.skate.of.minds@gmail.com> - AuthorDate: 2023-07-23 10:19:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-25 08:58:06 +0900 - - [rubygems/rubygems] Bundler: Update bundle-outdated(1) man - - Updated output examples to current format since the output format has changed since version 2.2.0.dev - - https://github.com/rubygems/rubygems/commit/48d98f906a - -commit b106cf2eef574535fa2a069493235b00d679d20a - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-07-25 08:23:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-25 08:23:08 +0900 - - GitHub Actions: fix ENOENT for jobs running in forks - - https://github.com/peterzhu2118/ruby/actions/runs/5649652235/job/15304434412 - - > Errno::ENOENT: No such file or directory @ rb_sysopen - - > ./.downloaded-cache/config.guess: - > https://raw.githubusercontent.com/gcc-mirror/gcc/master/config.guess - - Unsure about the root cause but making sure the directory is there seems like a - plausible fix. Maybe the issue is sensitive to cache state. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8114 - - Merged-By: XrXr - -commit cef60e93e6db859b47c818f745be809feb04ae48 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-25 05:51:46 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-25 05:51:46 +0900 - - YJIT: Fallback send instructions to vm_sendish (#8106) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit c4e893ceb5811f3436f1e16cab769a16469b56b0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-25 00:01:52 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-25 00:01:52 +0900 - - Adjust brace nesting - -commit 1faeb44dfcf777ace28321e80d0ebf942161a0a7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-24 23:59:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-24 23:59:50 +0900 - - Check if macros are defined before using - - Assume macros with the same prefix would be defined together. - -commit 14d154076876a6566b273f0eb3c4a56c681a6b13 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-24 23:57:28 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-24 23:57:28 +0900 - - RString NULL ptr check only when RUBY_DEBUG - - Since edf01d4e82d8e44ee30ec41fbcb7f802bc8b8c5d, fake string treats - NULL as an empty string. - -commit 1780ad37483592d7752d314fbdb3bfd01966c229 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-24 23:41:01 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-24 23:41:01 +0900 - - Extract magic numbers - -commit 43a5c191358699fe8b19314763998cb8ca77ed90 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-07-13 18:49:28 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-07-24 21:51:20 +0900 - - Use the caller location as default filename for eval family of methods - - [Feature #19755] - - Before (in /tmp/test.rb): - - ```ruby - Object.class_eval("p __FILE__") # => "(eval)" - ``` - - After: - - ```ruby - Object.class_eval("p __FILE__") # => "(eval at /tmp/test.rb:1)" - ``` - - This makes it much easier to track down generated code in case - the author forgot to provide a filename argument. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8070 - -commit 14d16bdb1ad8e98d76ec2c43b2c1c412ff707d0b - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-07-21 23:42:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-24 15:08:54 +0900 - - [ruby/openssl] Always respect the openssl prefix chosen by truffle/openssl-prefix on TruffleRuby - - * See https://github.com/ruby/openssl/issues/650#issuecomment-1645699608 - - https://github.com/ruby/openssl/commit/ca738e7e13 - -commit dd1af4b22d99642c2300e60d37215ea3c43ba337 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-19 14:25:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-24 15:04:24 +0900 - - [rubygems/rubygems] Rename local to lockfile and global to system - - https://github.com/rubygems/rubygems/commit/456fd05d3a - -commit 34f541ae36877a6cc5d4c47898469742e1233948 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-11 00:01:17 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-24 15:03:15 +0900 - - [rubygems/rubygems] Avoid unnecessary network requests for local gem - - https://github.com/rubygems/rubygems/commit/ec5f04f7b1 - -commit 0b0df03b0d8c4077a9edb080793eab522c7b4cfc - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-07 18:20:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-24 15:03:15 +0900 - - [rubygems/rubygems] Avoid printing using messages when version has not changed - - https://github.com/rubygems/rubygems/commit/9635a2fd74 - -commit 8c82b3579154f12c19d916bd74c87dbe9818711e - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-04 23:41:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-24 15:03:15 +0900 - - [rubygems/rubygems] Exclude Bundler from missing locked dependencies check - - Bundler is special since it's not actually locked in the lockfile as a - regular gem (only via `BUNDLED WITH`). So exclude it from that check. - - https://github.com/rubygems/rubygems/commit/9f1756ec47 - -commit 0e7536bf490cf4b26cf075810e918a5840dbb08b - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-30 19:27:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-24 14:59:34 +0900 - - [rubygems/rubygems] Prefer squiggly heredocs over custom helper - - https://github.com/rubygems/rubygems/commit/258476c38a - -commit 5a43b0ddd5617ba611db9d2ab1dd7e8054a2c536 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-17 01:24:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-24 14:59:34 +0900 - - [rubygems/rubygems] Remove unused module inclusion - - https://github.com/rubygems/rubygems/commit/0f58ef6a32 - -commit c31a9cf829b529fa25903fcee7e9a70d8a08522b - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2022-07-10 04:00:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-24 14:59:33 +0900 - - [rubygems/rubygems] Refactor spec helpers for reading lockfiles - - https://github.com/rubygems/rubygems/commit/ea2a30ba08 - -commit ebc3174123c62bb20fb34a8a778a659aa4f1146d - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2022-07-10 03:26:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-24 14:59:32 +0900 - - [rubygems/rubygems] Simplify `bundle lock` specs - - https://github.com/rubygems/rubygems/commit/6301d3eece - -commit bcc160b449f63bc7608feaa125259bdedbe6e115 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-07-23 23:24:19 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-23 23:24:19 +0900 - - [DOC] RDoc for File::Constants (#8103) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 4dccb145a8d052220743a557de3bb82b037dbf82 - Author: nagachika <nagachika@ruby-lang.org> - AuthorDate: 2023-07-23 21:44:36 +0900 - Commit: nagachika <nagachika@ruby-lang.org> - CommitDate: 2023-07-23 22:47:09 +0900 - - tool/merger.rb: Support commit URLs as revisions - - Notes: - Merged: https://github.com/ruby/ruby/pull/8111 - -commit dd04def10f22296c9a98b4d796c100b9ad4e2388 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-22 13:07:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-22 13:07:04 +0900 - - Try to fix NoMethodError on update-deps - -commit 7cecd15587431e84088c62294bfbba134bfef173 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-22 12:57:53 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-22 12:57:54 +0900 - - Suppress flaky update-deps failures for any win32 files - - win32/win32.o was also unstable: - https://github.com/ruby/ruby/actions/runs/5628655900/job/15252762821?pr=8107 - - At this point, any win32 files seem suspicious. Let's just ignore all - such files. - -commit 11deab7906bd12d3c706aa162cb082e8bccbd2a8 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-22 04:44:24 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-22 04:44:24 +0900 - - Remove unused code in darray.h - -commit 83605bb6149ec65b670dac4fcd3afa3fb2e67114 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-22 02:29:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-22 02:50:19 +0900 - - Just assume rustc is in the container - - Notes: - Merged: https://github.com/ruby/ruby/pull/8105 - -commit 25267fdd69edc29fe0dc32745549f94a37e7485c - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-21 06:00:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-22 00:48:19 +0900 - - [ruby/yarp] Exclude heredoc_nested test for Rubies < 3.3 - - Ripper's lexemes were slightly different in Ruby 3.2 for Heredocs. - We ignored this complex heredoc test in this case because - Ripper's output has changed - - https://github.com/ruby/yarp/commit/59d3d4a899 - -commit 7fdf98ef39cc7b079502f0faa086b31f16f3b0c6 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-04 11:53:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-21 17:47:55 +0900 - - [rubygems/rubygems] Deprecate Gem::Platform.match - - https://github.com/rubygems/rubygems/commit/e3ba3e2225 - -commit f602cb55d72a1461328c0eeda04a05eadd8d4b69 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-19 23:23:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-21 16:48:49 +0900 - - [rubygems/rubygems] Boundary check in `Gem::StreamUI#choose_from_list` - - https://github.com/rubygems/rubygems/commit/abacb0cb34 - -commit 47c7c188e08dae5a81be9126f4ea2e201e981bba - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-21 14:52:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-21 14:52:43 +0900 - - Add comments to id.h and undef finished macros - -commit 210caa777b2ee2405b1d074b790b0183e0f6b27f - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-07-21 05:50:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-21 05:50:45 +0900 - - More RDoc for Dir.glob (#8088) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit c4ef3d767bc901d410cbaaf91f9eba02556552a7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-21 04:54:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-21 04:54:59 +0900 - - YJIT: Rename exec_instruction to yjit_insns_count (#8102) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit b71f79dd1782cf3af2462b879bcc4bc55f0bcd34 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-21 04:52:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-21 04:52:56 +0900 - - Add a missing * - - Co-authored-by: Alan Wu <alansi.xingwu@shopify.com> - -commit 1129488f6f789c4219eaf0f127cfb6ca8a66c205 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-21 04:04:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-21 04:04:16 +0900 - - Ignore win32/file.o on update-deps - - This job has been so flaky: - https://github.com/ruby/ruby/actions/runs/5614842978/job/15213840097 - -commit a7127745f197807a8eeda3a6a34b9a0eee4a2c71 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-21 03:54:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-21 03:55:31 +0900 - - Get rid of obsoleted __bp__ references - -commit 134d8741731101b4b115e3d92ac008f6cecee1d8 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-21 03:51:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-21 03:51:17 +0900 - - Sync YARP gemspec (#8101) - - * Sync YARP gemspec - - We were previously not syncing the YARP gemspec over which meant - that the Ruby YARP gem was out of sync. - - * Sync YARP node / lex_compat files - - Notes: - Merged-By: jemmaissroff - -commit 639aa76e820480d707b90028972a52fd2a30957a - Author: Kunshan Wang <wks1986@gmail.com> - AuthorDate: 2023-07-21 03:17:38 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-21 03:17:38 +0900 - - Embed struct rmatch into GC slot (#8097) - -commit 460c27dc15b5efc46a74cb2a7809ca3fa6ce72a7 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-07-17 18:41:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-21 02:58:52 +0900 - - [ruby/syntax_suggest] Handle new eval source location - - See https://bugs.ruby-lang.org/issues/19755 - - In Ruby 3.3, using `eval` without providing a source location - will now default to `"(eval at #{__FILE__}:#{__LINE__})"`. - - https://github.com/ruby/syntax_suggest/commit/8e5076472e - -commit b41fc9b9a4ad2043a9fabce15814eade9b252569 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-21 02:14:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-21 02:14:25 +0900 - - YJIT: Avoid undercounting retired_in_yjit (#8038) - - * YJIT: Count the number of failed instructions - - * Rename yjit_insns_count to exec_instructions instead - - * Hoist out the exec_instruction counter - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit abce8583e253e96cf1268926ee7fd790f980ea96 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-07-19 06:37:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-20 23:58:11 +0900 - - [ruby/yarp] Fix heredocs inside %W and %w lists - - The problem was that we were treating heredoc bodies as part of the %W - list because we didn't push the scanning cursor past the heredoc after - lexing out the here doc. To fix this, we changed the whitespace - scanning function to quit scanning when it reaches a newline but only in - the case that a heredoc is present. - - Additionally, we need to prevent double counting newlines in the case of - a heredoc. For example: - - ```ruby - %W(<<foo 123) - foo - ``` - - The newline after the `)` is counted as part of scanning the heredoc, so - we added logic to prevent double counting the newline when scanning the - rest of the %W list. - - https://github.com/ruby/yarp/commit/eb090d8126 - - Co-authored-by: Jemma Issroff <jemmaissroff@gmail.com> - -commit 76ea8ecbf3b412de4877ca2a8574f96590aac807 - Author: S-H-GAMELINKS <gamelinks007@gmail.com> - AuthorDate: 2023-07-16 01:11:39 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-20 21:55:44 +0900 - - Supress warning that variable may be used uninitialized with ripper building - - Notes: - Merged: https://github.com/ruby/ruby/pull/8081 - -commit dd8372b3f3290572a8b26eaa272f9a7131d164ca - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-07-20 05:59:17 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-07-20 21:38:58 +0900 - - cvc table entries can move - - Notes: - Merged: https://github.com/ruby/ruby/pull/8100 - -commit 62cb739ba5d36178b73ec718707afc9ed07f14f1 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-07-20 16:00:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-20 16:00:26 +0900 - - Update bundled gems list at 2023-07-20 - -commit 419fbc77e0c05358f8eb22392cd99050c4dfaf5f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-19 22:58:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-20 08:20:54 +0900 - - [rubygems/rubygems] Clear `YAML` constant if it was undefined previously - - https://github.com/rubygems/rubygems/commit/31d0311258 - -commit 84b5274143bf54f77f9950eeba72a64cc761dd45 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-20 05:15:01 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-20 05:15:01 +0900 - - [ruby/yarp] Resync YARP (#8098) - - Notes: - Merged-By: jemmaissroff - -commit 7380c73af410d33dc2d4a3d77871d2001531416f - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-07-19 22:31:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-19 22:31:17 +0900 - - [ruby/reline] Add assertion to auto_indent_proc's parameter, add - Ctrl-d exit test - (https://github.com/ruby/reline/pull/574) - - * Add auto_indent_proc's parameter assertion in multiline_repl - - * Add rendering test for Ctrl-d exit - - https://github.com/ruby/reline/commit/46db71132a - -commit ca561480eaf8aba3d1c7ac70725cb1a726b3a5ba - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-07-19 22:25:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-19 22:25:58 +0900 - - [ruby/reline] Always set ANSI CSI keybindings for Home, End, and - Arrow. - (https://github.com/ruby/reline/pull/569) - - https://github.com/ruby/reline/commit/f363a43a45 - -commit 0765b890b52975434f1f63fe561e1080ecf17013 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-19 14:35:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-19 14:35:43 +0900 - - Fix `USE_THREAD_CACHE=0` - -commit a3a74771f23b4e31c1aaa33e2ffb5ba4a1f51ffe - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-19 12:42:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-19 12:42:20 +0900 - - Add a corner case for `return` - -commit 45fd006185fe2404c058cc01f86791071d48e504 - Author: osyo-manga <manga.osyo@gmail.com> - AuthorDate: 2023-07-19 05:33:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-19 05:33:39 +0900 - - [ruby/reline] Fix [nil] is passed to auto_indent_proc when exit with - CTRL+d - (https://github.com/ruby/reline/pull/571) - - * Fix [nil] is passed to auto_indent_proc when exit with CTRL+d - - Fix it https://github.com/ruby/reline/issues/556 - - * not call auto_indent_proc when Ctrl+d. - - see: https://github.com/ruby/reline/pull/571#issuecomment-1637183195 - - https://github.com/ruby/reline/commit/0924f2a075 - -commit b4003079239f369632ce1ac68fb0575b41bb37be - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-07-19 05:31:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-19 05:31:40 +0900 - - [ruby/reline] Add missing `close` to test_rendering.rb - (https://github.com/ruby/reline/pull/573) - - https://github.com/ruby/reline/commit/7cd817036e - -commit ecbedf9bf125b158c683dd6f69ce966653cc9a33 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-19 00:00:58 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-19 03:52:37 +0900 - - Remove assumption about object order - - The address of objects can't be assumed since a later object may be - allocate in a swept slot. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8092 - -commit 4c03eab1aaa30ada3819930ae4e5f22ee534cb23 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-18 23:33:28 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-19 03:52:37 +0900 - - Lazily allocate pages at boot - - We can just set alloctable pages for the first size pool rather than - eagerly allocating pages. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8092 - -commit fe4d906f5fbacbe6e9267af3bd3503339bad63a9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-19 01:27:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-19 03:40:05 +0900 - - [Bug #19774] Fix segfault at `return` in `END` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8093 - -commit 9c94db7cfc584e982a6449b72e58a1cf25024177 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-19 00:43:25 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-19 00:43:25 +0900 - - Add tests for `return` in `BEGIN` and `END` blocks - -commit d6ad334d6ed55778961b05b1a4fa18912230bf12 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-19 00:18:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-19 00:18:58 +0900 - - [ruby/irb] Reduce boilerplate code in RubyLexTest - (https://github.com/ruby/irb/pull/644) - - * Avoid initialising Row at every test input - - * Extract common assertion patterns into methods - - * Remove unnecessary PromptRow strcut and boilerplate code - - https://github.com/ruby/irb/commit/1ba586c0c6 - -commit d1992d6df2abfb6f8d7c6700367c2b5c606ed5b4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-18 00:07:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-19 00:06:53 +0900 - - Reset signal handler before aborting due to sanitizer - - When aborting by a sanitizer, `SIGILL` or something is raised and - often results in raising the same signal infinitely. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8090 - -commit ebeecbd575a8df1ec235eea740f190e811c27228 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-18 00:06:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-19 00:06:53 +0900 - - Unify `writev` and `write` operations in `check_reserved_signal_` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8090 - -commit 19486ebd72465b7d14337b5547db0e98b7c0852a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-17 11:54:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-19 00:02:58 +0900 - - [flori/json] Re-generate parser.c - - https://github.com/flori/json/commit/82a75ba98e - - Notes: - Merged: https://github.com/ruby/ruby/pull/8091 - -commit 768668a4de144b348f7df59f680a644fe8c46928 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-17 11:45:00 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-19 00:02:58 +0900 - - [flori/json] Remove unnecessary code - - In `JSON#generate` and `JSON#fast_generate`: - - - When the given `opts` is a `JSON::State` the variable is set to - `nil`. - - But it will be never used as the next `if` blocks will not be - executed. - - `JSON::State#configure` does the conversion to `Hash`, the - conversions in the `if` block are just duplication. - - `JSON::State.new` does the same thing with `configure` when an - argument is given. - - https://github.com/flori/json/commit/5d9ab87f8e - - Notes: - Merged: https://github.com/ruby/ruby/pull/8091 - -commit 104089ce022437ca3b8dc00dcfa5c73dc55469f3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-17 11:44:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-19 00:02:58 +0900 - - [flori/json] [DOC] Remove duplicate sentence - - https://github.com/flori/json/commit/ed242667b4 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8091 - -commit f1f84ca71c3015666a1fe5f809b131b1e706e791 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-17 11:42:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-19 00:02:58 +0900 - - [flori/json] Remove `HAVE_RB_SCAN_ARGS_OPTIONAL_HASH` check - - This macro is defined since ruby 2.1, which is older than the required - ruby version. - - https://github.com/flori/json/commit/dd1d54e78a - - Notes: - Merged: https://github.com/ruby/ruby/pull/8091 - -commit 0db58dd0db092af8055372d97961bc3399a25767 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-18 22:53:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-18 22:53:31 +0900 - - [ruby/irb] Declare rdoc as dependency - (https://github.com/ruby/irb/pull/648) - - IRB already has several features that rely on rdoc, such as: - - - Autocompletion's document dialog - - Autocompletion's `PerfectMatchedProc` - - The `show_doc` command - - Easter egg - - And we could use its pager more in the future too. So it makes sense to - declare rdoc as a dependency instead of relying on the one bundled with - Ruby. - - https://github.com/ruby/irb/commit/4dffbb1dd3 - -commit b89b7d8fdc76b520cafc31566524f3054439d5d3 - Author: Ivanov-Anton <anton.i@didww.com> - AuthorDate: 2023-07-18 19:23:27 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-18 19:23:27 +0900 - - [DOC] Fix a magic comment in the section for `experimental_copy` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8087 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 56c8dab46891bb21b637ec64903bb0a38bb5d2a3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-18 11:36:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-18 12:25:55 +0900 - - [flori/json] Skip BigDecimal tests when it's missing to load - - https://github.com/flori/json/commit/3dd36c6077 - -commit 9f51810f340afca45257043cf1a5955da0379836 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-17 19:30:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-18 12:25:54 +0900 - - [flori/json] Skip unsupported test on JRuby - - https://github.com/flori/json/commit/7138bf32c7 - -commit 9977462fd9d06167c3bf77e5c22c3c5efcb3aecd - Author: Dimitar Haralanov <dharalanov@me.com> - AuthorDate: 2023-07-12 21:52:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-18 12:25:54 +0900 - - [flori/json] Rename JSON::ParseError to JSON:ParserError - - https://github.com/flori/json/commit/20b80ca317 - -commit b368990ce632aaa11581d3b8f9fa9fd77401121a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-18 11:32:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-18 11:55:47 +0900 - - [ruby/psych] Skip BigDecimal tests when it's missing to load - - https://github.com/ruby/psych/commit/e1dbfae7a6 - -commit f302e725e10ae05e613e2c24cae0741f65f2db91 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-07-18 02:57:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-18 02:57:58 +0900 - - Remove __bp__ and speed-up bmethod calls (#8060) - - Remove rb_control_frame_t::__bp__ and optimize bmethod calls - - This commit removes the __bp__ field from rb_control_frame_t. It was - introduced to help MJIT, but since MJIT was replaced by RJIT, we can use - vm_base_ptr() to compute it from the SP of the previous control frame - instead. Removing the field avoids needing to set it up when pushing new - frames. - - Simply removing __bp__ would cause crashes since RJIT and YJIT used a - slightly different stack layout for bmethod calls than the interpreter. - At the moment of the call, the two layouts looked as follows: - - ┌────────────┐ ┌────────────┐ - │ frame_base │ │ frame_base │ - ├────────────┤ ├────────────┤ - │ ... │ │ ... │ - ├────────────┤ ├────────────┤ - │ args │ │ args │ - ├────────────┤ └────────────┘<─prev_frame_sp - │ receiver │ - prev_frame_sp─>└────────────┘ - RJIT & YJIT interpreter - - Essentially, vm_base_ptr() needs to compute the address to frame_base - given prev_frame_sp in the diagrams. The presence of the receiver - created an off-by-one situation. - - Make the interpreter use the layout the JITs use for iseq-to-iseq - bmethod calls. Doing so removes unnecessary argument shifting and - vm_exec_core() re-entry from the interpreter, yielding a speed - improvement visible through `benchmark/vm_defined_method.yml`: - - patched: 7578743.1 i/s - master: 4796596.3 i/s - 1.58x slower - - C-to-iseq bmethod calls now store one more VALUE than before, but that - should have negligible impact on overall performance. - - Note that re-entering vm_exec_core() used to be necessary for firing - TracePoint events, but that's no longer the case since - 9121e57a5f50bc91bae48b3b91edb283bf96cb6b. - - Closes ruby/ruby#6428 - -commit 105bdba899fbb10aa51115c4cd074ea42eb9e3e6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-17 23:57:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-17 23:57:11 +0900 - - Fix logarithm of 0 with base - -commit d70484f0eb176a7ef7274972ff92b88905ea0edc - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-07-17 23:41:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-17 23:41:18 +0900 - - YJIT: refactoring to allow for fancier call threshold logic (#8078) - - * YJIT: refactoring to allow for fancier call threshold logic - - * Avoid potentially compiling functions multiple times. - - * Update vm.c - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - - --------- - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 1c4a523006e4a0994db4f166bd410fe1d35e8611 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-17 21:31:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-17 21:31:59 +0900 - - Move `posix_signal` declaration internal with prefix `ruby_` - -commit f1adc5866a77d9ed6e4b45bf277c38f2c6e90fd4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-17 19:50:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-17 19:50:47 +0900 - - Fix up to require objspace - -commit b998e6b79d3fa9326d4426ab8138a1e8bf0e2d0d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-17 19:49:00 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-17 19:49:00 +0900 - - Run `Process.warmup` tests in separate processes - -commit fa30b99c34291cde7b17cc709552bc5681729a12 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-04-05 15:40:07 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-07-17 18:20:15 +0900 - - Implement Process.warmup - - [Feature #18885] - - For now, the optimizations performed are: - - - Run a major GC - - Compact the heap - - Promote all surviving objects to oldgen - - Other optimizations may follow. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7662 - -commit 0a570a00699a08577270dc3fa0d7ebaf749d41a3 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-07-16 11:57:13 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-07-16 19:27:08 +0900 - - Fix `#line` directive filename of ripper.c - - Before: - - ```c - /* First part of user prologue. */ - #line 14 "parse.y" - ``` - - After: - - ```c - /* First part of user prologue. */ - #line 14 "ripper.y" - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8083 - -commit 5c77402d885799e2465e291bf879dcfbd06ba77c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-16 15:41:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-16 15:41:10 +0900 - - Fix null pointer access in Ripper#initialize - - In `rb_ruby_ripper_parser_allocate`, `r->p` is NULL between creating - `self` and `parser_params` assignment. As GC can happen there, the - typed-data functions for it need to consider the case. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8085 - -commit da39936ce165ea9462b9e192eb6b608485c94842 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-16 01:24:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-16 01:24:44 +0900 - - Prefer integer as base of intermediate logarithms - - As long as "floating point numbers" cannot accurately represent an - irrational number, the result of the natural logarithm cannot be - accurate. Logarithms with an integer base may have the possibility to - represent more accurately. - - Notes: - commits - - Merged: https://github.com/ruby/ruby/pull/8082 - -commit be98bfc4ee3a635315daaac4dae5093ccb107d11 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-07-16 03:12:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-16 03:12:05 +0900 - - [ruby/irb] Indent multiline percent literals - (https://github.com/ruby/irb/pull/643) - - https://github.com/ruby/irb/commit/18bb4022a9 - -commit 7ffb995f5e3b6d749adb700e014f80e9819af560 - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-07-16 00:59:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-16 00:59:18 +0900 - - [ruby/irb] Bump 1.7.4 (https://github.com/ruby/irb/pull/645) - - https://github.com/ruby/irb/commit/b0f650a766 - -commit c32b608e76c6da9396a133deae4b9196af6d5563 - Author: Tom Stuart <hi@tomstu.art> - AuthorDate: 2023-07-01 23:38:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-16 00:39:01 +0900 - - Add `--backtrace-limit` option to the man page - -commit de68e240c7a1ded3049ee23d8bf2db5a15f4f39b - Author: Tom Stuart <hi@tomstu.art> - AuthorDate: 2023-07-01 23:19:01 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-16 00:39:01 +0900 - - Allow -1 as the value of `--backtrace-limit` option - - -1 is a legitimate backtrace limit — in fact, it’s the default — so it - should be possible to provide it with the `--backtrace-limit` option. - -commit 125b4461dfa0a908c7fc6cd6964b080f89c88a47 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-14 02:12:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-16 00:39:01 +0900 - - Test that command line `--backtrace-limit` overrides RUBYOPT - - Co-authored-by: Tom Stuart <hi@tomstu.art> - -commit 72a3bb7edc0b5a0cad73e06f8b136f9360cccdd2 - Author: Tom Stuart <hi@tomstu.art> - AuthorDate: 2023-07-01 23:15:09 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-16 00:39:01 +0900 - - Allow `--backtrace-limit` option to appear in RUBYOPT - - There’s no reason to prevent RUBYOPT from controlling the backtrace - limit. In fact, Matz said [0] he was expecting this to be possible. - - [0] https://bugs.ruby-lang.org/issues/8661#note-27 - -commit e5825de7c9f07e4f7bd2b83ce8973e19a4652916 - Author: alexandre184 <110398901+alexandre184@users.noreply.github.com> - AuthorDate: 2023-07-15 16:36:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-15 16:36:53 +0900 - - [Bug #19769] Fix range of size 1 in `String#tr` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8080 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit f15123c34ce80f3928612befe2a9aaf4c9d27fda - Author: Marcelo Pereira <marcelovitor.pereira@gmail.com> - AuthorDate: 2022-07-29 22:09:54 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-15 15:24:43 +0900 - - Fix stack trace for rescued StopIteration - - Notes: - Merged: https://github.com/ruby/ruby/pull/6201 - -commit 82cd70ef935e6aac8cc929af24fb21c2157524f7 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-07-12 10:51:49 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-07-15 12:50:40 +0900 - - Use functions defined by parser_st.c to reduce dependency on st.c - - Notes: - Merged: https://github.com/ruby/ruby/pull/8057 - -commit 6d2174477b0198b565389ed02958f15ed817be89 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-15 05:40:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-15 06:00:51 +0900 - - [ruby/yarp] Remove pattern matching pinning to enable support for <= Ruby 3.0 - - Pattern matching variable pinning was introduced in Ruby 3.1. We - need to remove it from YARP to support earlier rubies. - - https://github.com/ruby/yarp/commit/b792c58e3b - -commit 4e0b287912054103c2c897d9f017fb9b57cecc13 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-14 22:43:10 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-15 02:53:34 +0900 - - Remove RGENGC_OLD_NEWOBJ_CHECK - - The code doesn't compile, so probably nobody is using this. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8072 - -commit 914b657a2bf9f2c67453473447f81e878b366206 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-14 22:41:28 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-15 02:53:20 +0900 - - Remove unused branch in write barrier - - The branch doesn't compile, so it's probably not used. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8073 - -commit ebb7552e6d19c07ea9cd79b42e960c684038a1f0 - Author: jinroq <2787780+jinroq@users.noreply.github.com> - AuthorDate: 2023-07-15 01:52:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-15 01:52:33 +0900 - - [Doc] Make build instructions easier to copy-and-paste - - Notes: - Merged: https://github.com/ruby/ruby/pull/8077 - - Merged-By: XrXr - -commit 174bc2257065785efbbefca797a50f0847bb6062 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-15 00:45:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-15 00:45:09 +0900 - - [ruby/irb] Fix history-saving feature - (https://github.com/ruby/irb/pull/642) - - * Define RelineInputMethod::HISTORY - - The HistorySavingAbility module doesn't do anything if the input method - class doesn't define HISTORY. - - - https://github.com/ruby/irb/blob/3ac96be660bf052902fb4e532c7a46cf294b71eb/lib/irb/history.rb#L10 - - https://github.com/ruby/irb/blob/3ac96be660bf052902fb4e532c7a46cf294b71eb/lib/irb/history.rb#L34 - - This patch defines RelineInputMethod::HISTORY to avoid this. - - * Improve history-saving's ability check - - Instead of checking the existence of `input_method_class::HISTORY`, we should - make every input method class declare if it supports history saving or not. - - Since the default value is `false`, it shouldn't break any custom input method - that inherits from `IRB::InputMethod`. - - https://github.com/ruby/irb/commit/aec7a5b3f5 - -commit bc8cc68aeff7ae3be1353f4077633cda4d30b54b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-14 14:33:21 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-14 18:35:23 +0900 - - Make dtoa.c buildable alone - - Notes: - Merged: https://github.com/ruby/ruby/pull/8074 - -commit cfc564ac40496a392f463658ea33954ea76d6b11 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-14 14:25:37 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-14 18:35:23 +0900 - - Include headers for `ruby_qsort` only if needed - - If GNU `qsort_r` is available, we use the function and these headers - are not used. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8074 - -commit ed3d8f74ec2eee43d50f9826e2f11ceea279823e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-14 14:03:34 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-14 18:35:23 +0900 - - Delete a macro that has never been used, probably added by mistake - - Notes: - Merged: https://github.com/ruby/ruby/pull/8074 - -commit 5d4fff845602872eef072e7611558b5f8762efe0 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-06-23 06:31:57 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-07-14 08:49:39 +0900 - - Tighten Time.new(string) parsing - - Disallow: - - * Only year-month - * Only year-month-day - * Preceding whitespace - * Trailing whitespace - - Fixes [Bug #19293] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7974 - -commit d814722fb8299c4baace3e76447a55a3d5478e3a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-14 07:14:43 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-14 07:14:43 +0900 - - YJIT: Make ratio_in_yjit always available (#8064) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit e850181acf0e68a162c75d47b7a0951ab7d878b1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-14 05:41:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-14 05:41:41 +0900 - - Fix a CI failure on rbs - - This commit applies https://github.com/ruby/rbs/pull/1374. - -commit 62ecf78b87c29038acaee427a4e9bd149fb876fe - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-13 23:36:49 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-14 03:48:14 +0900 - - Don't pass array into ary_heap_alloc - - We no longer need a reference to the array when allocating the buffer - because we no longer allocate through the transient heap. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8071 - -commit 87e1486d31b26749cc2768ca299faed1b7629d57 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-13 22:47:33 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-14 03:48:14 +0900 - - Remove unused references to the transient heap - - Notes: - Merged: https://github.com/ruby/ruby/pull/8071 - -commit 32231812845e5302bd457f7e4a534e7965d89d49 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-13 22:45:35 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-14 03:48:14 +0900 - - Remove RARRAY_CONST_PTR_TRANSIENT - - RARRAY_CONST_PTR now does the same things as RARRAY_CONST_PTR_TRANSIENT. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8071 - -commit de327ccb63db9f929949a499476647f8def84be2 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-13 22:42:24 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-14 03:48:14 +0900 - - Remove RARRAY_PTR_USE_TRANSIENT - - RARRAY_PTR_USE now does the same things as RARRAY_PTR_USE_TRANSIENT. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8071 - -commit 5ebc13311607a7af5423337d64b406c62b221bf9 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-13 22:40:46 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-14 03:48:14 +0900 - - Remove rb_array_ptr_use_{start,end} - - Notes: - Merged: https://github.com/ruby/ruby/pull/8071 - -commit 4999a53fe994f1b5b1957493126d350e12ef216a - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-14 01:52:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-14 01:52:13 +0900 - - [ruby/irb] Unpend RDoc dialog related tests - (https://github.com/ruby/irb/pull/640) - - * Unpend rdoc dialog tests - - Without these tests, we don't have any coverage on autocompletion's rdoc - dialog, which is what caused #638 to happen. - - * Pull ri doc on CI for the doc dialog test - - * Assert different screen result on CI and local machine - - https://github.com/ruby/irb/commit/3ac96be660 - -commit 6a62b9b200fdd447b773c149fdcd5a9088e66620 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-07-13 20:43:25 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-07-13 23:30:33 +0900 - - Remove unused forward declarations - - Notes: - Merged: https://github.com/ruby/ruby/pull/8069 - -commit db3b8f84f5b4d5357576a9ecd7ba81ccfe02b8ec - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-13 17:59:19 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-13 22:59:26 +0900 - - Set backtrace length limit at last - - Command line options should have higher precedence than the same - options in shebang and `RUBYOPT`. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8068 - -commit dbbc3583ba432c279f07b1fa0afb0a8a9ba50c91 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-13 17:08:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-13 22:59:26 +0900 - - Preserve already set options in `moreswitches` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8068 - -commit 1c2a4d9682decf3fc56fe16470b51f7290f2ae1c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-13 16:58:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-13 22:59:26 +0900 - - Shrink `ruby_cmdline_options_t` a bit - - Notes: - Merged: https://github.com/ruby/ruby/pull/8068 - -commit 1e7b67f73370056c7521306b9f037b6cbccf640d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-14 05:19:33 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-13 22:27:33 +0900 - - [Feature #19730] Remove transient heap - - Notes: - Merged: https://github.com/ruby/ruby/pull/7942 - -commit fff4773085bd70bf14ace146388dd0b9d80f244a - Author: Shane Becker <veganstraightedge@gmail.com> - AuthorDate: 2023-07-13 08:57:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-13 21:39:31 +0900 - - [DOC] Add parenthetical to explain what FIFO abbrev means - - Notes: - Merged: https://github.com/ruby/ruby/pull/8062 - -commit 0454887a0e64a7fbafd460580ae619e752d0e6e8 - Author: B. Burt <beeburrt@outlook.com> - AuthorDate: 2023-07-13 08:02:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-13 21:30:23 +0900 - - [ruby/getoptlong] [DOC] Add spaces to fix formatting in example - - To make the example code verbatim. - Fixes ruby/ruby#8061 - - https://github.com/ruby/getoptlong/commit/85fe502916 - -commit 76ef28186f5c470ef18c7a661f9c7a5d4dc696ea - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-13 20:30:44 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-13 20:30:44 +0900 - - [DOC] Removed redundant `the` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8067 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit e098468d7f91d2bfebf24597fb0f66bcbb78d9c3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-13 13:17:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-13 19:08:50 +0900 - - Let `[DOC]` in PR title skip CIs - - Notes: - Merged: https://github.com/ruby/ruby/pull/8065 - -commit 9c1fe9064c56cef3bde856d7fa1f907195af1003 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-12 11:15:19 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-13 17:55:55 +0900 - - [Feature #19757] Add new API `rb_data_define` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8066 - -commit d426343418aab6148706860bd1678ac309dc12c0 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-03-30 05:05:13 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-07-13 17:21:36 +0900 - - Store object age in a bitmap - - Closes [Feature #19729] - - Previously 2 bits of the flags on each RVALUE are reserved to store the - number of GC cycles that each object has survived. This commit - introduces a new bit array on the heap page, called age_bits, to store - that information instead. - - This patch still reserves one of the age bits in the flags (the old - FL_PROMOTED0 bit, now renamed FL_PROMOTED). - - This is set to 0 for young objects and 1 for old objects, and is used as - a performance optimisation for the write barrier. Fetching the age_bits - from the heap page and doing the required math to calculate if the - object was old or not would slow down the write barrier. So we keep this - bit synced in the flags for fast access. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7938 - -commit 7524675330eaf96caba155852bb06b34b809b2a9 - Author: Shane Becker <veganstraightedge@gmail.com> - AuthorDate: 2023-07-13 09:11:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-13 14:22:47 +0900 - - [DOC] Fix example code indentation from 3 to 2 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8063 - -commit 3ef6364a988ab24ca7fdbb7d1b6840b2a40f1466 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-13 12:51:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-13 14:01:28 +0900 - - Move bsearch test with Bigdecimal under the test_bigdecimal.rb - - When we extract bigdecimal as bundled gems, this test will be failed - with `make test-all`. - -commit 5dd969892f16fa4683edd9734564154411e3fdbc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-13 13:12:52 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-13 13:12:52 +0900 - - Wait for sleepr thread to finish not to leak - -commit c1fb25f6fc7427c25839493a6edd63199b794fdc - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-12 03:33:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-13 11:36:03 +0900 - - [rubygems/rubygems] Don't run any git commands when sorting and comparing git sources - - Previously, when sorting and comparing git Gemfile vs lockfile sources during - `bundler/setup` to figure out whether we need to re-resolve or not, we - would try to find the default branch if nothing more specific was - specified in the Gemfile. - - If the git cache has been deleted thought, that would fail. - - The error would still be swallowed (and the branch would simply not be - displayed), but trying to clone would still generate the side effect of - creating the parent folder for the clone. - - That could affect non-writable systems that don't expect `bundler/setup` - to write to the filesystem at all. - - To fix this, override `Bundler::Source::Git#identifier` to use - exclusively static information, so it does not even try to clone the - repo nor generate any side effects. - - https://github.com/rubygems/rubygems/commit/582eb2ef39 - -commit 8cf5297ba595af38a89ba8d2d428ae26b6bb00d2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-12 16:38:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-13 11:36:03 +0900 - - [rubygems/rubygems] Dont't use Bundler::VERSION - - https://github.com/rubygems/rubygems/commit/46cd9be69a - -commit d3305cab44ff6c9e59778c0737d8426fe8563ae8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-12 16:29:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-13 11:36:03 +0900 - - [rubygems/rubygems] restart with BUNDLE_VERSION if it's specified - - https://github.com/rubygems/rubygems/commit/57cfe7cf8d - -commit f16c880f776450771196c35cec10b9a5860a560f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-12 16:08:32 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-13 11:36:03 +0900 - - [rubygems/rubygems] Introduce bundle config set version feature - - https://github.com/rubygems/rubygems/commit/c431a1df52 - -commit 8f61a4c5b2f26df3a487c1a77b24488b437e793c - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-12 03:33:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-13 11:36:03 +0900 - - [rubygems/rubygems] Remove unused variable - - https://github.com/rubygems/rubygems/commit/802457b0a1 - -commit 7f9c2a9bdd06a925247297b46972603aa5b451be - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-13 11:16:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-13 11:16:04 +0900 - - [ruby/irb] Bump version to 1.7.3 - (https://github.com/ruby/irb/pull/639) - - https://github.com/ruby/irb/commit/621c8c2b7d - -commit b588fd552390c55809719100d803c36bc7430f2f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-13 08:38:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-13 08:38:18 +0900 - - Remove an unused `#if 0` code - -commit 81beb29988025871c04a225dfdfc0ba9bb1ff19c - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-13 04:55:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-13 04:55:19 +0900 - - [ruby/irb] Correct preferred_dialog_height's caller - (https://github.com/ruby/irb/pull/638) - - The caller should be the dialog itself, not Reline. - - https://github.com/ruby/irb/commit/418c2b945e - -commit a02f5eb56a53e6799e73cfbb96fc8ccd68fa5651 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-13 01:46:38 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-13 01:46:38 +0900 - - YARP resync (#8059) - - Notes: - Merged-By: jemmaissroff - -commit 47cb789332e80d51699ab95ef610a69f5556d44d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-13 00:34:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-13 01:22:54 +0900 - - [ruby/etc] Declare `getlogin` even if unistd.h is not available - - Although MinGW provides this header but not the function, Windows - version ruby provides the function. - - https://github.com/ruby/etc/commit/f7fa1884fa - -commit f4bf80623fe72295cfa4a64de38a062d81359643 - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-07-12 22:27:54 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-07-12 23:40:58 +0900 - - [ruby/openssl] [DOC] remove top-level example for - OpenSSL::Cipher#pkcs5_keyivgen - (https://github.com/ruby/openssl/pull/647) - - OpenSSL::Cipher#pkcs5_keyivgen should only be used when it is - absolutely necessary for compatibility with ancient applications. - Having an example can be misleading. We already have another example - for OpenSSL::Cipher in which PBKDF2 is used to derive a key. - - As described in the rdoc of OpenSSL::Cipher#pkcs5_keyivgen, it is - compatible with PKCS#5 PBES1 (PKCS#5 v1.5) only when used in combination - of a hash function MD2, MD5, or SHA-1, and a cipher DES-CBC or RC2-CBC. - This example uses MD5 as the hash function and combines it with AES. - This is considered insecure and also using a non-standard technique to - derive longer keys. - - https://github.com/ruby/openssl/commit/e379cc0cca - -commit 4b6d667c63481abd17ce5446bceb053c0881739f - Author: Ryo Kajiwara <sylph01@gmail.com> - AuthorDate: 2023-07-12 22:06:46 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-07-12 23:40:58 +0900 - - [ruby/openssl] Add support for raw private/public keys - (https://github.com/ruby/openssl/pull/646) - - Add OpenSSL::PKey.new_raw_private_key, #raw_private_key and public - equivalents. These methods are useful for importing and exporting keys - that support "raw private/public key". Currently, OpenSSL implements - X25519/X448 and Ed25519/Ed448 keys. - - [rhe: rewrote commit message] - - https://github.com/ruby/openssl/commit/3f29525618 - - Co-authored-by: Bart de Water <bartdewater@gmail.com> - -commit fb12522b009b0cf331d6cbbe3cc5c0f48381d57e - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-07-12 23:27:30 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-07-12 23:40:12 +0900 - - sync_default_gems.rb: ensure that commit messages end with \n - - Commit messages written on GitHub's Web UI apparently use \r\n as a - line separator and do not have a \n at the end of message, unlike those - normally made with the git CLI. This breaks the expectation of the - regexps used later. - -commit 4fced7860535c650aa20c10cc59c053943aeeb3d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-12 21:03:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-12 23:18:40 +0900 - - [ruby/etc] Check if the target file exists, not "depend" file - - https://github.com/ruby/etc/commit/b95ddef386 - -commit 2fa77fb82d14deb8c2fa2064305c9a7f0ae63057 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-12 20:39:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-12 23:18:39 +0900 - - [ruby/etc] Fix for srcdir with spaces - - Fixes https://github.com/ruby/etc/pull/22. - Build failure when the ruby installed directory name contains spaces. - - https://github.com/ruby/etc/commit/1ab19d5815 - -commit efd8ea366b31e7874c21a2e667ddeb69f2cddd7e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-12 16:20:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-12 23:18:39 +0900 - - [ruby/etc] Declare `getlogin` only if unistd.h is not available - - https://github.com/ruby/etc/commit/365398ea47 - -commit b90c48b1e20b955da99dfa954a33bb504a5f90f8 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-12 22:29:54 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-12 22:29:54 +0900 - - Add comment to test - - Add comment for 7299c8c0f165247853fac2fe337e7c2678e653c9. - -commit 4fbfc116ca375ba8ae3747fcf32fdb85c48683c9 - Author: Koichi ITO <koic.ito@gmail.com> - AuthorDate: 2023-07-12 19:00:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-12 21:29:29 +0900 - - [rubygems/rubygems] Update GitHub organization of Standard Ruby - - ## What was the end-user or developer problem that led to this PR? - - The old URL https://github.com/testdouble/standard is mentioned. - - ## What is your fix for the problem, implemented in this PR? - - This PR updates to the new URL https://github.com/standardrb/standard. - - https://github.com/rubygems/rubygems/commit/eeafba72fc - -commit 074bf01e13db1ac0407786a3bc1b85c13135fd36 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-12 13:31:19 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-12 13:31:19 +0900 - - Test `Comparable#clamp` with inverse arguments as well as a Range - -commit dfe782be17639aab05527b2fd816f524c0844a6b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-12 09:26:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-12 09:26:03 +0900 - - Refactor COLLECT_USAGE_INSN - -commit 503f987ead41f73205f2dbbfc93cd8ecd635c3a5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-12 06:39:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-12 06:39:32 +0900 - - Skip a flaky test for RJIT - -commit d45118aaafe4e1e8409c13dea462fbbaf8b4cb8c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-12 06:35:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-12 06:36:36 +0900 - - Remove obsoleted USE_INSNS_COUNTER macro for now - - I don't use that these days. I'd like to remove this to ease a change - I'm writing. I'll resurrect this when I need this again. - -commit 7299c8c0f165247853fac2fe337e7c2678e653c9 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-07-12 03:09:48 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-07-12 04:05:10 +0900 - - Try to fix flaky GC test - - assert_not_nil could allocate objects which may trigger the major GC, so - don't run the assertions until the major GC has been ran. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8055 - -commit d40935c6804b87664ba0313062dc27f3e8130832 - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-07-12 01:30:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-12 01:30:34 +0900 - - [ruby/irb] Bump version to 1.7.2 - (https://github.com/ruby/irb/pull/636) - - https://github.com/ruby/irb/commit/85d6b4d146 - -commit d62328251d2231210b7d214be3e26e1c5cd32a11 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-12 00:31:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-12 00:49:42 +0900 - - [ruby/yarp] Remove yp_location_for_node in preference of yp_newline_list_line_column - - https://github.com/ruby/yarp/commit/55aa813909 - -commit 4be92463b6d2d0ce82b15db2c7260150e28c27db - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-07-11 23:47:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-11 23:47:26 +0900 - - [ruby/irb] Require Reline 0.3.6 or higher - (https://github.com/ruby/irb/pull/632) - - * Require Reline 0.3.6 or higher - - "Multi-line multibyte regular expression raises exception" (https://github.com/ruby/irb/issues/627) is fixed in Reline 0.3.6. - - * Remove unnecessary conditional - -commit e770006486a84008e68d8ab0c01c4625f028a0de - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-07-11 23:17:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-11 23:17:48 +0900 - - YJIT: add counter for untracked gbpp exit reason (#8052) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 1b01140d8ab9642e1b5ed6e2e2e62195bc43fb1c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-11 19:52:37 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-11 19:52:37 +0900 - - Remove unused fstring - -commit 3874381c4483ba7794ac2abf157e265546f9bfa7 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-07-11 02:06:23 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-11 02:06:23 +0900 - - Fix autosplat conditions to handle ruby2_keywords case - - Autosplat should not occur if there are two arguments but second - argument is an array containing a ruby2_keywords splat. Only - autosplat if a single argument to be yielded to the block, and there - is no splatted flagged keyword hash passed. - - Fixes [Bug #19759] - - Notes: - Merged: https://github.com/ruby/ruby/pull/8039 - - Merged-By: jeremyevans <code@jeremyevans.net> - -commit 53c560156542915938ebebeac3e12352c04feb24 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-10 23:54:12 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-10 23:54:12 +0900 - - [ruby/yarp] Fix endless method definitions binding power to accept args (#8051) - - Notes: - Merged-By: jemmaissroff - -commit 880b29b74b7edaa3c8cddd7aeada3f498e0a65a7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-10 19:15:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-10 21:11:12 +0900 - - [rubygems/rubygems] Use `File::NULL` instead of hard coded null device names - - https://github.com/rubygems/rubygems/commit/44fe8e7f50 - -commit 2951e3d83b302b914d291b83f48ac59dc5df3198 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-10 19:19:37 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-10 19:21:47 +0900 - - Allow nmake to ignore errors - - cmd.exe can redirect file descriptor other than STDOUT, while - command.com couldn't. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8050 - -commit c8d0470bb0888bcb6719ba536e5f3f6a8b6551bb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-10 19:18:48 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-10 19:21:47 +0900 - - Use `File::NULL` instead of hard coded null device names - - Notes: - Merged: https://github.com/ruby/ruby/pull/8050 - -commit 092c9b266ab3175c40a78e8af99bb82a0f3d2f4b - Author: S-H-GAMELINKS <gamelinks007@gmail.com> - AuthorDate: 2023-07-10 12:10:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-10 19:06:18 +0900 - - Reuse rb_ractor_make_shareable function for rb_ractor_make_shareable_copy function - - Notes: - Merged: https://github.com/ruby/ruby/pull/8048 - -commit abfac2222bd51a03ec11b64f4770179cb6d06515 - Author: krk <keremkat@gmail.com> - AuthorDate: 2023-07-03 09:00:00 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-10 18:05:19 +0900 - - Add a realpath cache to reduce number of syscalls. - - Number of lstat and stat syscalls for each 'require'd file is doubled, - because rb_realpath_internal is called from two places with the same - arguments in require_internal; once for checking the realpaths cache, - and once in load_iseq_eval when iseq is not found. - - Introduce rb_realpath_internal_cached function to reuse the realpath_map - cache which memoizes rb_realpath_internal function, leading to less - syscalls and increased startup performance depending on the cost of the syscalls - in a particular environment. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8017 - -commit d516910b61586fc6de676cf75930788594afe479 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-10 16:36:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-10 16:36:03 +0900 - - Serially update only the ripper source, even with old GNU make - - Notes: - Merged: https://github.com/ruby/ruby/pull/8049 - -commit 9dcdffb8bf8a3654fd78bf1a58b30c8e13888a7a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-09 18:45:51 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-09 18:45:51 +0900 - - Make the string index functions closer to symmetric - - So that irregular parts may be more noticeable. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8047 - -commit 5e79d5a5608f9018a3deab53df9b2d7f42c9c464 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-09 16:39:28 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-09 16:39:28 +0900 - - Make `rb_str_rindex` return byte index - - Leave callers to convert byte index to char index, as well as - `rb_str_index`, so that `rb_str_rpartition` does not need to - re-convert char index to byte index. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8047 - -commit e2257831ab20915b839eeaff79c6ec45b498de77 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-09 01:38:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-09 16:21:02 +0900 - - [Bug #19763] Raise same message exception for regexp - - Notes: - Merged: https://github.com/ruby/ruby/pull/8045 - -commit 4e2f98be3907b85c6f470c41e7c00f53653b6e68 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-09 15:24:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-09 15:25:08 +0900 - - [ruby/irb] Avoid using Reline as a module - (https://github.com/ruby/irb/pull/633) - - Using it as a module makes it harder to understand methods' source. - -commit acd9c208d5ab8619b6102116f48fcfc06f47cb7e - Author: S-H-GAMELINKS <gamelinks007@gmail.com> - AuthorDate: 2023-07-09 13:25:45 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-07-09 15:00:52 +0900 - - Move some macro for universal parser - - Notes: - Merged: https://github.com/ruby/ruby/pull/8044 - -commit b2bccf053befd331553e9443b1f1c86b7aaf1296 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-07-09 11:04:40 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-07-09 13:02:25 +0900 - - Include ripper.h into `$distcleanfiles` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8046 - -commit 2903e9456f6990c068008eb823b90715e5a21932 - Author: alitaso345 <alice.maru345@gmail.com> - AuthorDate: 2023-07-08 22:30:05 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-07-09 08:16:00 +0900 - - Remove ISASCII definition - - The ISASCII definition was moved to parse.y( https://github.com/ruby/ruby/pull/8029 ), but the old definition wasn't removed. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8043 - -commit 33e00b79a06343c86b1b7aba714c0c5a142cf317 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-08 17:53:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-08 17:53:46 +0900 - - [ruby/reline] Bump version to 0.3.6 - (https://github.com/ruby/reline/pull/565) - - https://github.com/ruby/reline/commit/2503ddb9a6 - -commit 02f9b685e82ebde33a74e59e3e884db709a11d10 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-07-08 17:41:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-08 17:41:30 +0900 - - [ruby/reline] Ignore unhandled escape sequences - (https://github.com/ruby/reline/pull/522) - - * Add unassigned escape sequence matcher to KeyStroke - - * Do not insert ESC and unassigned ESC+key to input buffer - -commit 8b2a0ec8df6a09361fd835b792a5d200bc0e66af - Author: S-H-GAMELINKS <gamelinks007@gmail.com> - AuthorDate: 2023-07-08 11:05:38 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-07-08 15:26:55 +0900 - - Move ISASCII defination to parse.y - - Notes: - Merged: https://github.com/ruby/ruby/pull/8029 - -commit 3c4d788bfe7ea2fe2e9b6c0246237be45a41a12e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-08 01:47:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-08 11:31:17 +0900 - - macos: symbols for `rb_execution_context_t` should be internal - - Notes: - Merged: https://github.com/ruby/ruby/pull/8040 - -commit f052aa11f218bfd97b1423e3157aa65261ee3f27 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-08 00:05:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-08 11:31:17 +0900 - - macos: try --enable-shared - - Notes: - Merged: https://github.com/ruby/ruby/pull/8040 - -commit 46fe9ba0f5d32c7bb5767486c3b21c69fbac7373 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-07 23:43:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-08 11:31:17 +0900 - - macos: set configure options in the composite action - - Notes: - Merged: https://github.com/ruby/ruby/pull/8040 - -commit cceb41008758c2b7cdfaf7411ad3c48dfa62e4eb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-07 23:33:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-08 11:31:17 +0900 - - leaked-globals: check leaked symbols in libruby.so if enable-shared - - Notes: - Merged: https://github.com/ruby/ruby/pull/8040 - -commit 28ae4e46284428ccee509aaad8bf5c0d01571741 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-07 12:59:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-08 11:31:17 +0900 - - leaked-globals: ignore Address Sanitizer symbols - - Notes: - Merged: https://github.com/ruby/ruby/pull/8040 - -commit 7f2bd17fad806ab6b8e7be5e8fc138429f445f0e - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-07-08 05:37:36 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-08 05:37:36 +0900 - - [DOC] RDoc for dir.c (#8037) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit dadf17818cc962707f847435bd9f359850ac0d1c - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-08 04:55:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-08 04:55:58 +0900 - - Add ruby_globals to lldb for easier debugging (#8041) - - Notes: - Merged-By: jemmaissroff - -commit 9e3a5cc54f406be7a23f3b8eefa3202066e966aa - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-08 01:54:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-08 02:46:47 +0900 - - [ruby/yarp] Add a yp_location_for_node function to the C API - - yp_location_for_node takes a parser and a node and returns the - location in a way that can be punned into ruby/ruby types - - https://github.com/ruby/yarp/commit/75e06016a7 - -commit 31f83a6feaeed8c82ed571d17ab33755a75cbb18 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-08 01:54:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-08 02:46:46 +0900 - - [ruby/yarp] Add source to ParseResult - - https://github.com/ruby/yarp/commit/f3802e03e0 - -commit 61efa9c823263697b1625b411fff33d8dc3cd11d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-08 01:52:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-08 02:46:45 +0900 - - [ruby/yarp] Remove bin/newlines - - Since newlines are working, this bin/newlines is less helpful, and - we can remove the API for newlines - - https://github.com/ruby/yarp/commit/b538460b99 - -commit 24d9e21f84eced634b3e443ada2a57621b2b4b9b - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-08 02:27:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-08 02:27:25 +0900 - - [ruby/reline] Reduce direct references to `Reline::IOGate` - (https://github.com/ruby/reline/pull/566) - - * Avoid referencing IOGate from IOGate classes - - The only time those classes being used is when themselves being the IOGate. - So when referencing to IOGate, it's better to use `self` instead. - - * Avoid referencing to IOGate from LineEditor directly - - * Avoid referencing to IOGate from Core directly - - * Reference to Reline.core directly - - * Replace Reline::IOGate with Reline.core.io_gate - -commit a642a94b68a31c0e7c092087114c269132cdb159 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-07 09:16:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-07 09:28:27 +0900 - - llvm-objcopy is not provided by Xcode Command Line Tools. - - Revert "Disable YJIT if objcopy command is old" - - This reverts commit 75f8781c08da421d6bcfb2c3c8b7b74efea3bec2. - -commit 48d95de6a61230d8364952a18ea123e86b3525e5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-07 04:51:01 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-07 04:51:01 +0900 - - YJIT: Use registers to pass stack temps to C calls (#7920) - - * YJIT: Use registers to pass stack temps to C calls - - * YJIT: Update comments in ccall - -commit 06c2d3e0a04600981e147ca8ee32b6e4048c48ff - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-07 02:26:26 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-07 02:26:26 +0900 - - Resync YARP (#8036) - - It got out of sync again. After this re-sync, it should happen - cherry-picking automatically. - - Notes: - Merged-By: jemmaissroff - -commit 055f7219bc4ace48270b09630626305784d5a87e - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-07-06 23:34:28 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-07-07 01:27:13 +0900 - - Improve ArgumentError message for Module#set_temporary_name - - Notes: - Merged: https://github.com/ruby/ruby/pull/8035 - -commit 9ee1877e4ab535253b4f61302b9102d20e11db5a - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-07-06 20:25:21 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-07-07 01:27:13 +0900 - - Ensure the name given to Module#set_temporary_name is not a valid constant path - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/8035 - -commit e76022f41cd74d297189d85d74a18d9e7821fd94 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-07-06 20:32:23 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-07-07 01:27:13 +0900 - - Specs for Module#set_temporary_name should be in their own file - - Notes: - Merged: https://github.com/ruby/ruby/pull/8035 - -commit 2acb44e0440327ee5fea8d324fa6c121214e6b96 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-07-06 23:17:03 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-06 23:17:03 +0900 - - YJIT: add new stats counter for compiled ISEQ entry points (#8032) - - * YJIT: add new stats counter for compiled ISEQ entry points - - * Update yjit.rb - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - --------- - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 75f8781c08da421d6bcfb2c3c8b7b74efea3bec2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-06 21:16:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-06 21:16:00 +0900 - - Disable YJIT if objcopy command is old - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/8034 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 20478cafe15f1911a9f2e6f91a43a17c6430f44b - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-07-05 19:58:14 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-07-06 17:26:20 +0900 - - do not set environment variables - - These variables were used only once. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8027 - -commit d287d8591cf619f4ccf285ac0c6629de11692832 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-06 11:39:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-06 14:01:29 +0900 - - [rubygems/rubygems] Avoid to use Base64 library because I have a plan to base64 gem to bundled gems in ruby/ruby. - - https://github.com/rubygems/rubygems/commit/221797cfd1 - -commit 9c1776e6b09fbad4a13de35179c8e7c7c7e6ea08 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-06 06:21:02 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-06 06:21:02 +0900 - - YJIT: Use --yjit-exec-mem-size=128 by default (#8031) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit f314656c238f799e26f49658b798379ccaf376ea - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-06 06:18:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-06 06:18:51 +0900 - - Skip a failing spec for the latest bigdecimal - -commit f0f099a5ff608cd87cf988ceb46c94c471e2dc50 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-06 06:07:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-06 06:10:13 +0900 - - Disable clippy on Cirrus for now - - Notes: - Merged: https://github.com/ruby/ruby/pull/8030 - -commit 7c9ce38cdb781958c52a89b910ee83d5fea99048 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-06 03:30:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-07-06 06:10:13 +0900 - - Remove duplicated Rust installation - - Notes: - Merged: https://github.com/ruby/ruby/pull/8030 - -commit 163cdb4cd4af2d5f380c6c9cc8e5bf59ad524867 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-06 04:40:45 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-07-06 05:58:55 +0900 - - Deleted unnecessary YARP fuzzing doc file - - Notes: - Merged: https://github.com/ruby/ruby/pull/8007 - -commit 9614a61379d39c654693ac40758ba80129eea4d0 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-01 04:04:28 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-07-06 05:58:55 +0900 - - Fixed build scripts for YARP - - Notes: - Merged: https://github.com/ruby/ruby/pull/8007 - -commit bfb933371d80f5a4ba23f2e978050e33c74de80e - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-07-01 03:30:24 +0900 - Commit: Jemma Issroff <jemmaissroff@gmail.com> - CommitDate: 2023-07-06 05:58:55 +0900 - - Manual YARP resync - - Notes: - Merged: https://github.com/ruby/ruby/pull/8007 - -commit 6f9d1b4b0f8938c42aa767577c7c6761ed9de64a - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-07-06 05:21:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-06 05:21:13 +0900 - - [ruby/reline] Update Relin::IOGate dynamically when it is needed - (https://github.com/ruby/reline/pull/560) - - https://github.com/ruby/reline/commit/4680d1c9e0 - -commit 5f07f78e8698a2802dd544dc098b0c1d8080e702 - Author: cryptogopher <cryptogopher@noreply.me> - AuthorDate: 2023-07-02 20:44:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-06 05:15:53 +0900 - - [ruby/bigdecimal] Update to_s doc examples - - https://github.com/ruby/bigdecimal/commit/8a94a29cf1 - -commit 10f59dcbcd21807887ea0ebb1d0732f0fa32d416 - Author: cryptogopher <cryptogopher@noreply.me> - AuthorDate: 2023-07-01 23:24:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-06 05:15:52 +0900 - - [ruby/bigdecimal] Add .to_s('F') digit grouping for integer part - - https://github.com/ruby/bigdecimal/commit/f63544d465 - -commit cd7166cc8fff8d7316634a665975d4f4e21dde61 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-07-06 01:33:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-06 01:33:46 +0900 - - [ruby/reline] Fix wrong byte_pointer passed to auto_indent_proc - (https://github.com/ruby/reline/pull/562) - - https://github.com/ruby/reline/commit/4348354604 - -commit 833b32f503abb9712dbb3a6825b1730c8ee1e912 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-07-05 21:48:20 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-07-05 23:13:40 +0900 - - also disable yjit for clang < 10 - - They don't compile. I guess nobody actively maintain such old - compilers. Chances are the situation won't improve. Let's stop - testing yjit on them. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8028 - -commit dd7c590f8a4dafbc0d659d07645aea59586b0f70 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-07-05 20:44:04 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-07-05 23:13:40 +0900 - - disable yjit when for non-flonum - - YJIT does not interface with this flag. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8028 - -commit 00f9231534d9a9c19d68857f62343b5af28036f9 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-07-05 22:45:54 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-05 22:45:54 +0900 - - [DOC] RDoc for some of dir.c (#8026) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit bd9360248523de807db1855752491f46f1589afc - Author: ParadoxV5 <paradox.ver5@gmail.com> - AuthorDate: 2023-07-05 03:13:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-05 20:37:23 +0900 - - Sync man pages - - Co-Authored-By: David Rodríguez <2887858+deivid-rodriguez@users.noreply.github.com> - -commit 8984442154994d5cc5cb72d3825cfd34fa6af638 - Author: Jimmy H <paradox.ver5@gmail.com> - AuthorDate: 2023-07-02 15:11:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-05 20:37:20 +0900 - - [rubygems/rubygems] `gemfile.5`: Quote default glob to escape Markdown - - For consistency, I chose code format over plaintext escaping. - -commit 1e7ddfa7eaa9834f958db0646457e00b27ef4976 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-05 18:47:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-05 19:11:36 +0900 - - [ruby/psych] Extract accessor methods without forwardable - - We should leave additional dependency if we leave from them. - - https://github.com/ruby/psych/commit/3d0325a774 - -commit 62b4983416022d3b286b5b1f9fbd908e9a0cfb6d - Author: Masafumi Koba <473530+ybiquitous@users.noreply.github.com> - AuthorDate: 2023-07-05 13:09:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-05 13:09:08 +0900 - - [ruby/rdoc] [DOC] Improve CSS for "toggle source" hovering over one more method signatures - - This commit improves the behavior of showing the "toggle source" element on mouseover. - - For example, when a method has one more signatures by using `:call-seq:`, - - ```ruby - # :call-seq: - # foo {|element| ... } -> self - # foo -> new_enumeration - def foo - end - ``` - - The current CSS doesn't show "toggle source" even when hovering the second signature `foo -> new_enumeration`. - But this change will show "toggle source" always when hovering over any signature. - - For details about the `.method-header` element, see `lib/rdoc/generator/template/darkfish/class.rhtml`: - https://github.com/ruby/rdoc/blob/0e060c69f51ec4a877e5cde69b31d47eaeb2a2b9/lib/rdoc/generator/template/darkfish/class.rhtml#L101-L124 - - For example, see https://docs.ruby-lang.org/en/3.2/Array.html#method-i-delete - -commit 62754503d8ba0307e9f8581a5d1bf5b76f6437ae - Author: gemmaro <gemmaro.dev@gmail.com> - AuthorDate: 2023-07-05 12:39:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-05 12:39:18 +0900 - - [ruby/rdoc] [DOC] Fix to use KeyboardEvent.key over keyCode - - https://github.com/ruby/rdoc/commit/663edc807c - -commit 77fa4787bd26b5193a5cc72226c1a3469f91ba11 - Author: gemmaro <gemmaro.dev@gmail.com> - AuthorDate: 2022-09-24 23:29:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-05 12:37:28 +0900 - - [ruby/rdoc] Add keydown event listener to focus on search field - - https://github.com/ruby/rdoc/commit/db62e47df2 - -commit fd6da40fef5c6b818564ed0bc47672d1e069039c - Author: Andy Waite <13400+andyw8@users.noreply.github.com> - AuthorDate: 2023-07-05 05:45:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-05 05:45:07 +0900 - - [ruby/irb] Use `max_by` for `longest_cmd_name_length` - (https://github.com/ruby/irb/pull/628) - - https://github.com/ruby/irb/commit/5e87f3bfdd - - Co-authored-by: Andy Waite <andyw8@users.noreply.github.com> - -commit 6b2abe570f0ecb1ec0e401be0eb4172f35b78307 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-05 05:02:39 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-05 05:02:39 +0900 - - YJIT: Avoid reloading InsnOut operands (#8021) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit a1d4dada6b99f7762d2a4adcd3784bd63d3a2fd2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-07-05 04:57:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-05 04:57:32 +0900 - - YJIT: Break register cycles for C arguments (take 2) (#8018) - - * Revert "Revert "YJIT: Break register cycles for C arguments (#7918)"" - - This reverts commit 78ca085785460de46bfc4851a898d525c1698ef8. - - * Use shfited_live_ranges for the last-insn check - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit f6af5a1128754bdac07b8cf3c41a7397f113a130 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-05 00:17:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-05 00:17:41 +0900 - - [ruby/irb] Refactor eval history - (https://github.com/ruby/irb/pull/623) - - * Rename `ext/history.rb` to `ext/eval_history.rb` - - To confusion with `lib/irb/history.rb` - - * Add eval_history tests - - * Rename eval_history's History to EvalHistory to avoid confusion - -commit 296782ab60e63fe825461a199369c5dd8505c2b7 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-07-04 23:45:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-04 23:45:29 +0900 - - YJIT: Fix autosplat miscomp for blocks with optionals (#8006) - - * YJIT: Fix autosplat miscomp for blocks with optionals - - When passing an array as the sole argument to `yield`, and the yieldee - takes more than 1 optional parameter, the array is expanded similar - to `*array` splat calls. This is called "autosplat" in - `setup_parameters_complex()`. - - Previously, YJIT did not detect this autosplat condition. It passed the - array without expanding it, deviating from interpreter behavior. - Detect this conditon and refuse to compile it. - - Fixes: Shopify/yjit#313 - - * RJIT: Fix autosplat miscomp for blocks with optionals - - This is mirrors the same issue as YJIT. See previous commit. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 218f913aa6cd3bcbf715f229f400effee0f79ea6 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-07-04 18:49:28 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-07-04 23:18:54 +0900 - - Suppressing security alert of atty dependency by env_logger-0.9.0 - - Notes: - Merged: https://github.com/ruby/ruby/pull/8022 - -commit 0a8b5cac6613ef25c0bf5832a822f76546d9ed70 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-04 22:52:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-04 22:52:31 +0900 - - [ruby/reline] Refactor Reline::Core - (https://github.com/ruby/reline/pull/561) - - * Use Reline::Core.encoding instead of directly referencing IOGate - - * Set input/output based on the IOGate's interface - -commit 2e6a8a8610b235068b2dd1b99ed0c5993883c193 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-07-04 22:23:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-04 22:23:24 +0900 - - [DOC] Dir doc (#8014) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 9178a9987709efd74829462380e623e86a8de502 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-06-27 17:21:03 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-07-04 22:14:34 +0900 - - Remove reference to USE_RINCGC - - This compile time flag was removed in https://github.com/ruby/ruby/pull/7313 - - This commit cleans up some related dead code. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7982 - -commit 8ddfc177205d0b839cdce41435128dfcde2a1202 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-04 19:10:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-04 21:30:44 +0900 - - Use `uint_least32_t` - - The elements of `ruby_global_name_punct_bits` table are 32-bit masks. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8024 - -commit ab661556207046022860958d3c4f06bb289a7c97 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-07-03 22:36:05 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-07-04 20:13:49 +0900 - - fix substitution errors - - These expressions don't exist. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8020 - -commit 7ee39556db3db37953975d55adef1eb3a185777f - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-07-03 22:32:00 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-07-04 20:13:49 +0900 - - fix typo - - `matrix.name` doesn't exist. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8020 - -commit 72e58bbdc0d4f9c1c3914c7916fbf3847958b6e5 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-07-03 22:24:06 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-07-04 20:13:49 +0900 - - fix typo - - According to https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#check_suite - the key is "types", not "type". - - Notes: - Merged: https://github.com/ruby/ruby/pull/8020 - -commit 8ba5437fe561f4c0c5bb7355228caa4bb3397c74 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-07-03 17:01:16 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-07-04 20:13:49 +0900 - - annocheck: de-matrix - - This workflow have never needed matrix since its birth. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8020 - -commit 420d069cc2b9abcc1c7cc6a5d3cd6731bac4f54c - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-06-30 22:19:35 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-07-04 20:13:49 +0900 - - refactor extract mkdir - - Everyone does `mkdir build; src/autogen.sh`; why not merge them. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8020 - -commit 4f2f1ddf2225bd58d799429e1d9067c93d4c78f2 - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-07-01 05:40:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-04 14:54:26 +0900 - - [rubygems/rubygems] Test that git sources in lockfiles have stable sort order - - https://github.com/rubygems/rubygems/commit/4c982684ea - -commit 09382135de5e706d7b100900cc81ddf91f4d3314 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-30 20:45:39 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-04 14:54:26 +0900 - - [rubygems/rubygems] Fix git source lockfile unstability - - We have some flags that limit running git commit commands under certain - situations, for example, when running under `--local`. However, those - should only affect remote git operations, not local read-only operations - like `git --version`, or `git rev-parse --abbrev-ref HEAD`. - - This commit refactors things to achieve that. - - By doing this, the `#to_s` representation of a source is more - consistent, since we don't get any errors when reading the checked out - branch, and we avoid some flip-flop lockfile issues. - - https://github.com/rubygems/rubygems/commit/4a529fce81 - -commit 0ae2709dd71eaefe4a316bdbc9e97eaef3c7ae69 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-30 23:57:39 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-04 14:54:25 +0900 - - [rubygems/rubygems] When printing frozen errors, print only Gemfile information - - https://github.com/rubygems/rubygems/commit/93f74abc5f - -commit 0fcb4c6af72a5fe4222a705e161dc0b42d135fba - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-30 18:52:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-07-04 14:54:25 +0900 - - [rubygems/rubygems] Fix another incorrect removal of "ruby" platform from lockfile - - When dependencies in path sources have changed, we'll be re-resolving, - and we can't really know whether the resolution will be valid or invalid - for the Ruby platform, so skip the removal in that case. - - https://github.com/rubygems/rubygems/commit/afc3b0956f - -commit af9eeb19d8b73a951776ea91901618d6e038d030 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-03 22:48:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-03 22:48:23 +0900 - - [ruby/irb] Stop treating history-saving logic as extension - (https://github.com/ruby/irb/pull/613) - - Since `IRB.conf[:SAVE_HISTORY]` is assigned with 1000 by default, history-saving - is a feature enabled by default. So it should not be treated as an extension, - which adds unnecessary complexity to the code. - -commit 4430b73cee4aaa4f203e14368d93b3297505c63e - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-07-03 18:53:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-03 18:57:07 +0900 - - [ruby/timeout] Require Ruby >= 2.6 for the timeout gem - - * The test suite fails on 2.5. - * See https://github.com/ruby/timeout/pull/35 - - https://github.com/ruby/timeout/commit/03873a9237 - -commit 8281f8fd067017ac909bd16a66e64cfdfed06bc8 - Author: John Bachir <jjb@users.noreply.github.com> - AuthorDate: 2023-07-03 18:26:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-03 18:26:43 +0900 - - [ruby/timeout] Test that work is done in the same thread/fiber as - the caller - (https://github.com/ruby/timeout/pull/34) - - * see discussion in - https://github.com/ruby/timeout/pull/30#issuecomment-1616179651 - -commit 3e605a781970cef365002167634a1b5a176bffcb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-10-25 12:15:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-03 14:47:43 +0900 - - [ruby/tmpdir] [Bug #18933] Make `Dir.mktmpdir` Ractor-safe - - Fix https://bugs.ruby-lang.org/issues/18933 - - https://github.com/ruby/tmpdir/commit/446e636434 - -commit 4bfa4433830a4e48bc4ca43aef861d213affdd84 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-02 23:33:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-03 13:36:51 +0900 - - [Cirrus] Set up cargo environments just once at first - -commit d2ffd0ad3d225b6b9e121278146eae8500e9f259 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-02 20:20:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-03 13:36:42 +0900 - - [Cirrus] Share configuration using YAML aliases - - https://cirrus-ci.org/guide/tips-and-tricks/#sharing-configuration-between-tasks - -commit 3a761dcc91fcbed828699fcc38017f14a1a2db65 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-19 17:51:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-03 13:35:35 +0900 - - [Cirrus] Show CPU and memory info - -commit bde3b98a6040800e05c9cf448228f094f80b8fed - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-19 09:37:07 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-03 13:35:35 +0900 - - [Cirrus] Make gem download non-verbose - -commit 4a60764108663bf2088d843e55e18756f2b1293f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-20 21:34:07 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-03 13:35:14 +0900 - - [Cirrus] Run also crons other than nightly - -commit 7e333b7abfe4faa3b35680cd305daac67a36639e - Author: John Bachir <jjb@users.noreply.github.com> - AuthorDate: 2023-07-02 11:33:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-03 07:51:25 +0900 - - [ruby/timeout] require ruby version in gemspec - - https://github.com/ruby/timeout/commit/949445f591 - -commit 9682275b5493439334fb3933ce2da3b95271eb1c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-02 16:52:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-02 16:52:29 +0900 - - [Travis] make `.bundle` directory writable - - To create gem files from sources under `gems/src` for tests. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8012 - -commit 4bad2a9562aece90f6df9f3ef1c7ecdc2811c29f - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-02 13:49:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-02 13:49:07 +0900 - - [ruby/irb] Bump version to 1.7.1 - (https://github.com/ruby/irb/pull/621) - - https://github.com/ruby/irb/commit/b9a9dd97df - -commit fa6e14c45d85e2c2b21c69e04d87135dc5423a09 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-02 13:00:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-02 13:00:44 +0900 - - [DOC] Stop downloading Unicode data only for unicode_properties.rdoc - - Notes: - Merged: https://github.com/ruby/ruby/pull/8011 - -commit 765a19ab593b481f262a07be5d88484f820da3c2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-02 00:19:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-02 00:30:21 +0900 - - [ruby/psych] Remove private methods unused since #487 - - https://github.com/ruby/psych/commit/902c292f26 - -commit 08b3fb11524e6cde453476f24ac80fd60457dfef - Author: Janosch Müller <janosch84@gmail.com> - AuthorDate: 2023-07-01 23:22:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-01 23:22:17 +0900 - - [Bug #19728] Auto-generate unicode property docs - - https://bugs.ruby-lang.org/issues/19728 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7944 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 3fd1968d6f10579a36f77eb3838f6c62a3e9f205 - Author: S-H-GAMELINKS <gamelinks007@gmail.com> - AuthorDate: 2023-06-29 19:09:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-01 23:17:57 +0900 - - Introduce script_lines function for refactor script_lines_defined and script_lines_get functions - - Notes: - Merged: https://github.com/ruby/ruby/pull/7990 - -commit a70320b8cd2c8590fb01607cca354a9bc57dde0a - Author: jinroq <2787780+jinroq@users.noreply.github.com> - AuthorDate: 2023-06-29 11:44:54 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-01 23:16:54 +0900 - - Define `NO_SANITIZE` with reference to ext/bigdecimal/missing.c - -commit 174dbe33cc183e48897e8819ad694b0b44642a9f - Author: jinroq <2787780+jinroq@users.noreply.github.com> - AuthorDate: 2023-06-27 23:41:25 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-01 23:16:54 +0900 - - Supress `warning: ‘unsigned-integer-overflow’ attribute directive ignored [-Wattributes]` - -commit 1a6f3becbbd2b6f497dc6a5ebcc01316d5564243 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-01 15:14:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-01 15:14:27 +0900 - - Fallback `rb_iseq_complete` - - For compilers that do not eliminate references to functions that are - never called, such as SunC. - -commit 2952dbad5eedb3ed7d0bfdd8b6c7a546c775c76b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-07-01 12:22:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-07-01 12:22:22 +0900 - - [DOC] Move document for YARP - -commit 1bc8838d60ef3fc6812d3b64ed87caaf0ae943d9 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-07-01 11:37:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-07-01 11:37:53 +0900 - - Handle unterminated unicode escapes in regexps - - This fixes an infinite loop possible after ec3542229b29ec93062e9d90e877ea29d3c19472. - For \u{} escapes in regexps, skip validation in the parser, and rely on the regexp - code to handle validation. This is necessary so that invalid unicode escapes in - comments in extended regexps are allowed. - - Fixes [Bug #19750] - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/8003 - - Merged-By: jeremyevans <code@jeremyevans.net> - -commit 41779fede04d730f94690ddc9f2b36a4ff73ddb0 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-07-01 02:00:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-01 07:11:58 +0900 - - [rubygems/rubygems] Bump vendored net-http-persistent to 4.0.2 - - https://github.com/rubygems/rubygems/commit/b0edf39083 - -commit d49a92d036fb316757d7c4a12a2f9808875f35bf - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-07-01 03:28:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-01 03:31:49 +0900 - - [ruby/yarp] Move fuzz docs into docs/ directory, reference in README - - https://github.com/ruby/yarp/commit/97547b6192 - -commit 136fcd5118b844bb8399d69dc44414cb3bd2028a - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-07-01 02:41:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-07-01 02:42:00 +0900 - - [ruby/irb] Reduce internal operations' exposure to benchmarking - (https://github.com/ruby/irb/pull/618) - - * Test last value is assigned with measure enabled - - * Remove unnecessary `result` variable - - `Context#evaluate` always assigns the result of the evaluation to `_` so - we don't need to do it in `Irb#eval_input`. - - * Move benchmarking logic into `Context#evaluate` - - Current location of the benchmarking logic is too high up and includes - operations like command loading and argument transformation, which should - be excluded. So this commit moves it into `Context#evaluate` to reduce the - noise. - - We don't move it further down to `Workspace#evaluate` because `Context` - is an argument of the measure block, which is not available in `Workspace`. - -commit 39933496aeb3e1d70ccf183e9b096783adacd37f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-29 00:14:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-30 23:59:05 +0900 - - Remove duplicate declarations - -commit 0d0841ad4c08ef30a9aaa3012021f17b91e7ee7f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-30 17:52:21 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-30 23:59:05 +0900 - - Compile code for lazy ISeq loding always - -commit c1432a481615c7f1ad2c1426f0617f73599e2493 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-29 00:08:36 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-30 23:59:05 +0900 - - Compile disabled code for thread cache always - -commit e7dc8f0b276b87dfba755e967a37942321d3e6ea - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-28 23:04:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-30 23:59:05 +0900 - - Compile debugging code for symbol and ID always - -commit ac0163949a6ee678dfccec9f6e56422b91e5f0a9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-28 22:54:13 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-30 23:59:05 +0900 - - Compile code without Symbol GC always - -commit 469e644c93a0410b2b3a3a7523aed017e4f62715 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-28 22:45:34 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-30 23:59:04 +0900 - - Compile code for non-embedded CI always - -commit 5204ad56e17c336af6730ee93a2a9113a11a932d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-28 22:03:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-30 23:59:04 +0900 - - Compile debugging code for stress to class always - -commit 7a0a218dff0f01408b33815a027aa16707ab1cdc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-28 21:58:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-30 23:59:04 +0900 - - Compile debugging code for integer pack always - -commit d8d7591e6f1b60a5dfa097736c06021722405e8c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-28 21:55:25 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-30 23:59:03 +0900 - - Stop `DEBUG_FIND_TIME_NUMGUESS` compilation - - Debugging code for find_time_numguess is compiled always. - -commit 939873401058da7006e54cb94180163250fd35c1 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-06-30 23:23:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-30 23:23:24 +0900 - - [ruby/irb] Re-implement prev_spaces feature for pasted code - (https://github.com/ruby/irb/pull/607) - - https://github.com/ruby/irb/commit/9d97a192a5 - -commit 58386814a7c7275f66ffa111175fca2fe307a1b5 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-30 05:31:35 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-30 22:13:31 +0900 - - Don't check for null pointer in calls to free - - According to the C99 specification section 7.20.3.2 paragraph 2: - - > If ptr is a null pointer, no action occurs. - - So we do not need to check that the pointer is a null pointer. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8004 - -commit 37a893d12915b8860f6880d6a0c2859e096ab4ff - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-06-30 15:47:42 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-06-30 17:39:39 +0900 - - bit quiet - - Notes: - Merged: https://github.com/ruby/ruby/pull/8005 - -commit 7102324de39971cb2687d336e5d5e46fb9a744c7 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-06-30 15:23:35 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-06-30 17:39:39 +0900 - - fix YAML error - - `outputs` has to be a hash, but it seems previous expression - generated a null token and would have generated errors here. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8005 - -commit c90b8493fb6d4cad143bd024039adbbf783f847d - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-06-30 15:26:03 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-06-30 17:39:39 +0900 - - refactor delete unnecessary branches - - These conditions always hold. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8005 - -commit 34bf2d508585799fc6fd272750a1c053f38e06cf - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-06-29 17:02:49 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-06-30 17:39:39 +0900 - - refactor extract brew - - Use composite action to reduce copy & paste. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8005 - -commit e8d629ed76cab8b17f82f024b6b5f7eddb71ab51 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-06-29 10:02:23 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-06-30 11:18:06 +0900 - - refactor extract apt-get - - Use composite action to reduce copy & paste. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7998 - -commit d3ff43852b22f5463d22aab390ef340d9ebe4b06 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-30 04:25:31 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-30 08:07:26 +0900 - - Fix memory leak in Hash#replace - - Hash#replace can leak memory if the receiver has an ST table. - - Notes: - Merged: https://github.com/ruby/ruby/pull/8001 - -commit 1272865a8ee948816ee9f5484f8adba8e26f45e2 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-06-30 06:00:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-30 06:00:40 +0900 - - Fix broken wiki links (#8002) - - Since [Misc #19679] migrated the wiki, these links should be updated - to their new locations. - - Notes: - Merged-By: jemmaissroff - -commit bf2c18731d50075bb64e2639c097396276196cd9 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-30 00:52:48 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-30 00:52:48 +0900 - - Add memory leak test for allocating ST hashes - - Test for commit f0d08d11dcd404f3146c0d71d6ff743bbc6e7193. - -commit f0d08d11dcd404f3146c0d71d6ff743bbc6e7193 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-29 22:21:11 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-30 00:16:50 +0900 - - Fix memory leak when copying ST tables - - st_copy allocates a st_table, which is not needed for hashes since it is - allocated by VWA and embedded, so this causes a memory leak. - - The following script demonstrates the issue: - - ```ruby - 20.times do - 100_000.times do - {a: 1, b: 2, c: 3, d: 4, e: 5, f: 6, g: 7, h: 8, i: 9} - end - - puts `ps -o rss= -p #{$$}` - end - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/8000 - -commit df2b3a29987e9353596af76ed77f35d7366d654e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-29 22:14:55 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-30 00:16:50 +0900 - - Refactor rb_hash_replace to use hash_copy - - Notes: - Merged: https://github.com/ruby/ruby/pull/8000 - -commit 3cfcd3d1663169ad68e22e5efef35f8057173993 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-29 23:08:08 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-29 23:08:08 +0900 - - Ripper sources are generated at once - -commit c89f5191706549bb1d7e0277fc07a413714ddecc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-29 17:12:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-29 18:47:56 +0900 - - More dependencies for ripper - - Notes: - Merged: https://github.com/ruby/ruby/pull/7999 - -commit c7af39ecd8d78d9ffc312dcde2af3466c7bbaf5f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-21 14:13:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-29 17:47:45 +0900 - - Merge URI-0.12.2 for Bundler - -commit 4aa73f8f8abaaab2d0806cc3a180c09d2faea80c - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-06-29 11:44:12 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-06-29 16:58:11 +0900 - - proper path - - Source code is not always checked out to `.`. We need to specify - the exact place where the action.yml file is located. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7994 - -commit 48e646fd96a834709fdfdddf08b1ac7dd188d50f - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-06-28 23:17:54 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-06-29 16:58:11 +0900 - - refactor extract ${{ ghithub }} expressions - - Use composite action to reduce copy & paste. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7994 - -commit 26b69fd4071b88c24654b19109beeb2ee416c0fa - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-06-29 10:04:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-29 10:23:37 +0900 - - [ruby/yarp] Handle bad input for ascii printable - - https://github.com/ruby/yarp/commit/06242aa7a0 - -commit ab5421547c5546603c2383085005272ba7754fea - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-21 13:04:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-29 10:07:52 +0900 - - [ruby/uri] Bump up v0.12.2 - - https://github.com/ruby/uri/commit/e18e657ea8 - -commit 995ce947bed7e92bcda185f164d43089e6a1cf5e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-22 20:09:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-29 10:07:52 +0900 - - [ruby/uri] Fix quadratic backtracking on invalid port number - - https://hackerone.com/reports/1958260 - - https://github.com/ruby/uri/commit/9d7bcef1e6 - -commit 1eff362492f4a0ca8d6d036c958afa7961e827f0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-22 20:08:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-29 10:07:51 +0900 - - [ruby/uri] Fix quadratic backtracking on invalid relative URI - - https://hackerone.com/reports/1958260 - - https://github.com/ruby/uri/commit/9010ee2536 - -commit d4b662d6f8eb2ead3871e98d608e7e3d4b9949f0 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-06-28 11:47:15 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-06-29 09:27:12 +0900 - - template/Doxyfile.tmpl: modernise - - applied doxygen -g for Doxygen 1.9.7. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7986 - -commit 27d3fa2af05cf6540ddb05bd65d5b12321737074 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-29 00:35:23 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-29 02:47:48 +0900 - - Increase memory leak test timeout - - The test times out on some platforms, so increase the timeout. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7992 - -commit 78ecb93f9de8d5e134bd9482780080bd72099fed - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-06-29 02:33:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-29 02:33:20 +0900 - - [ruby/irb] Reduce test pend truffleruby - (https://github.com/ruby/irb/pull/619) - - https://github.com/ruby/irb/commit/b7b071774f - -commit 8f9d58a962c901de56df605823dc28767fb2d8ac - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-06-29 00:56:28 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-29 01:01:16 +0900 - - Repair broken link - - Notes: - Merged: https://github.com/ruby/ruby/pull/7993 - -commit a500eb9f8c487c9245d82f9b3c64cd3ddf44c836 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-28 03:34:03 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-28 22:50:51 +0900 - - Fix memory leak in Ripper - - The following script leaks memory in Ripper: - - ```ruby - require "ripper" - - 20.times do - 100_000.times do - Ripper.parse("") - end - - puts `ps -o rss= -p #{$$}` - end - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7985 - -commit 3d7a6bbc12d9eed9f1e0135c44fdeab08434e4b5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-28 09:28:15 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-28 22:42:04 +0900 - - Ensure the byte position is a valid boundary - - Notes: - Merged: https://github.com/ruby/ruby/pull/7991 - -commit 6528cf9fcf503706ec16d378b27469b0be51cbff - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-06-28 22:05:43 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-28 22:05:43 +0900 - - [DOC] Fixes for link fragments (#7981) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit bc3ac1872e4523334e3ed04c2bb70a55c4c43f98 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-28 14:44:01 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-28 17:23:32 +0900 - - [Bug #19748] Fix out-of-bound access in `String#byteindex` - -commit b954a4ebc67d408456a102fe13051e5cc9065878 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-06-26 14:41:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:37:10 +0900 - - [ruby/csv] Bump version - - https://github.com/ruby/csv/commit/e090da19b4 - -commit d6d60d4287f58200cc3725d19cb503be70e7d724 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-06-26 14:29:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:37:10 +0900 - - [ruby/csv] Fix a bug that the same line is used multiple times - - GitHub: fix https://github.com/ruby/csv/pull/279 - - It's happen when: - - * `keep_start`/`keep_{drop,back}` are nested. - (e.g.: `strip: true, skip_lines: /.../`) - * Row separator is `\r\n`. - * `InputScanner` is used. (Small input doesn't use `InputScanner`) - - Reported by Gabriel Nagy. Thanks!!! - - https://github.com/ruby/csv/commit/183635ab56 - -commit 539559d36e1355befd39c6964f3efd9dd3af4846 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-06-26 14:29:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:37:09 +0900 - - [ruby/csv] Remove nonexistent variable - - https://github.com/ruby/csv/commit/bfbd6bbf6f - -commit 1f46793406fbe16f4756500124e0ff4e90945823 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-06-26 09:51:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:37:09 +0900 - - [ruby/csv] parser: add one more trace - - https://github.com/ruby/csv/commit/5df650be0c - -commit 2098093fb478d766315cabcbf42e64d1fcf4abcc - Author: Mark Schneider <github@markschneider.com> - AuthorDate: 2023-05-31 11:30:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:37:08 +0900 - - [ruby/csv] docs: Add entry for backslash_quotes liberal parsing - (https://github.com/ruby/csv/pull/280) - - https://github.com/ruby/csv/commit/0dcfcd9c48 - -commit f1313caec1ec465836a20862f97b89e0865f9054 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2023-05-26 22:40:29 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:36:53 +0900 - - [ruby/fiddle] Mark Closure, Function and Handle as write barrier - protected - (https://github.com/ruby/fiddle/pull/129) - - They don't have a mark function, so they don't need any change. - - https://github.com/ruby/fiddle/commit/9bbc732aef - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - -commit 135d5fa36c29d98b999ab8128222d361a2e96779 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2023-05-26 05:19:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:36:52 +0900 - - [ruby/fiddle] Implement write barriers for Fiddle::Pointer - (https://github.com/ruby/fiddle/pull/127) - - Save from having to mark them on every minor. - - https://github.com/ruby/fiddle/commit/153c09c99f - - Co-authored-by: Jean Boussier <jean.boussier@gmail.com> - -commit 572b432e5012d5bf0afbbb6f70fc3b98011edd6b - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-05-24 17:23:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:36:52 +0900 - - [ruby/fiddle] Fix a typo - - https://github.com/ruby/fiddle/commit/4c0c5da1a5 - -commit 02661f5e9b03eb54509248755a8fae8b3e8089a4 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-05-24 17:19:01 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:36:51 +0900 - - [ruby/fiddle] Add support for converting "C" (one character string) to char - - GitHub: fix https://github.com/ruby/fiddle/pull/96 - - I wanted to add a test for this but I couldn't find a function that - has a "char" argument in libc... - - Reported by kojix2. Thanks!!! - - https://github.com/ruby/fiddle/commit/2c863ef8ba - -commit 74e049294eec6290f2a61dd434a9be32c829dd7d - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-05-24 16:50:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:36:51 +0900 - - [ruby/fiddle] Add support for more "short" variants - - https://github.com/ruby/fiddle/commit/4598e6cd50 - -commit 731d27729b62ca6ceb1f1dc74985cdb9a0478b50 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-05-24 16:50:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:36:50 +0900 - - [ruby/fiddle] Add support for more "short" variants - - https://github.com/ruby/fiddle/commit/2b22bb9d74 - -commit ebf14d01ba6c586e0ea6dd79ad19c5efa841d4c6 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-05-24 16:38:39 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:36:50 +0900 - - [ruby/fiddle] Add support for "long" variants - - GitHub: fix https://github.com/ruby/fiddle/pull/100 - - Reported by David M. Lary. Thanks!!! - - https://github.com/ruby/fiddle/commit/516333dd78 - -commit 85937f3a0afeb7a2b3f9b8cb0dcaa8a20c49e09d - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-03-17 00:52:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:36:49 +0900 - - [ruby/fiddle] Add a helper method for reading/writing memory - (https://github.com/ruby/fiddle/pull/123) - - This commit adds two new methods, `Fiddle::Pointer.read` and - `Fiddle::Pointer.write`. Both methods take an address, and will read or - write bytes at that address respectively. - - For example we can read from an address without making a Pointer object: - - ```ruby - Fiddle::Pointer.read(address, 5) # read 5 bytes - ``` - - We can also write to an address without allocating a Pointer object: - - ```ruby - Fiddle::Pointer.write(address, "bytes") # write 5 bytes - ``` - - This allows us to read / write memory at arbitrary addresses without - instantiating a new `Fiddle::Pointer` object. - - Examples where this API would be useful - [1](https://github.com/tenderlove/tenderjit/blob/f03481d28bff4d248746e596929b0841de65f181/lib/tenderjit/fiddle_hacks.rb#L26-L28) - [2](https://github.com/tenderlove/ruby/blob/77c8daa2d40dd58eeb3785ce17dea2ee38f308d1/lib/ruby_vm/rjit/c_pointer.rb#L193) - [3](https://github.com/tenderlove/ruby/blob/77c8daa2d40dd58eeb3785ce17dea2ee38f308d1/lib/ruby_vm/rjit/c_pointer.rb#L284) - - I also added a writer method for the same reasons as the reader. - - --------- - - https://github.com/ruby/fiddle/commit/04238cefed - - Co-authored-by: Sutou Kouhei <kou@clear-code.com> - -commit ae71bbbc44e9389e229c039d4717b1e7bcf63631 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-14 15:53:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-28 16:34:53 +0900 - - [ruby/syntax_suggest] [DOC] Fix method name - - https://github.com/ruby/syntax_suggest/commit/08a9afb64f - -commit 0cbfeb8210cd177bee95c512834c483daec36f74 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-28 12:39:52 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-28 14:06:28 +0900 - - [Bug #19746] `String#index` with regexp should clear `$~` unless matched - - Notes: - Merged: https://github.com/ruby/ruby/pull/7988 - -commit 9e709d0f4a55c6d3e0b66569b287b6bc3451cf23 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-28 12:27:35 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-28 14:06:28 +0900 - - Assert `$~` after `String#index` family - - Notes: - Merged: https://github.com/ruby/ruby/pull/7988 - -commit 3e08a5365598bbb11741b6c4479915a1067d3ce0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-28 09:23:15 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-28 09:23:15 +0900 - - Use the same capacities for memory leak tests - -commit 8aedfefb21bb44fb043f29692e807033d26dfda5 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-06-28 05:43:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-28 05:43:53 +0900 - - [ruby/irb] Remove keyword exception from Context#evaluate because - the value is always nil - (https://github.com/ruby/irb/pull/617) - - https://github.com/ruby/irb/commit/62691384f8 - -commit caddd0274b6c859ab4a55ae033c4bc69c85a0fa9 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-06-28 04:51:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-28 04:51:18 +0900 - - [ruby/irb] Move input line mutation out of `Context#evaluate` - (https://github.com/ruby/irb/pull/615) - - This makes sure `Context#evaluate` really just evaluates the input. - It will also make #575's implementation cleaner. - -commit 913e01e80ec5fd771ae096c992893d5e736e7fae - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-27 23:14:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-27 23:14:10 +0900 - - Stop allocating unused backref strings at `defined?` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7983 - -commit df5ae0a55005f7f02adbf21790300f28dc2e12fc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-27 22:39:15 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-27 22:39:15 +0900 - - Use `rb_reg_nth_defined` instead of `rb_match_nth_defined` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7983 - -commit eaad44adb2043f0b597196fd44cfaae8db3a3b18 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-06-27 19:18:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-27 19:19:03 +0900 - - [ruby/irb] Always add \n at the end of the test input in RubyLex - test - (https://github.com/ruby/irb/pull/614) - - https://github.com/ruby/irb/commit/e68c6128aa - -commit 9dd869859760600df2d12c39ebaea0a306272256 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-27 14:30:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-27 16:37:24 +0900 - - [rubygems/rubygems] Fixup - https://github.com/rubygems/rubygems/pull/6766 - - https://github.com/rubygems/rubygems/commit/c5c5797227 - -commit a99d0c1555f17fef9deb90d0dd7e95d3455c942f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-22 15:25:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-27 11:15:40 +0900 - - [rubygems/rubygems] Removed unused variable - - https://github.com/rubygems/rubygems/commit/68cc941bed - -commit 65c217933639b9f4f40d028440b09b046b0cf115 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-22 13:15:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-27 11:15:40 +0900 - - [rubygems/rubygems] Molinillo::DependencyGraph is initialized in Molinillo::Resolver#resolve - - https://github.com/rubygems/rubygems/commit/1c39e24c95 - -commit ec59b95cfd8f9ff59353f20ab9edbf4786e858fb - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-06-26 22:51:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-26 23:03:33 +0900 - - [ruby/yarp] Use smaller regexp options - - https://github.com/ruby/yarp/commit/4deb7c3ae0 - -commit 515bd4214497b3af02f6eef51b496ad9a0cf6b3b - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-06-26 22:55:11 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-06-26 22:55:11 +0900 - - Update to ruby/spec@30e1c35 - -commit f73fa299279ac322bd921691d1ba0e8bf2b39b5f - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-06-26 22:55:09 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-06-26 22:55:09 +0900 - - Update to ruby/mspec@3cf2d16 - -commit 4fc8b8f06dfe113a0e8444c36de9f4e633325849 - Author: Steven Johnstone <steven.james.johnstone@gmail.com> - AuthorDate: 2023-06-24 06:06:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-26 22:31:29 +0900 - - [ruby/yarp] Prevent reading/writing outside the bounds of options - - https://github.com/ruby/yarp/commit/52bed3cbe2 - -commit 44197e51dc13eb6a69a3ad6e0905896dcc5106f5 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-06-26 17:45:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-26 22:13:57 +0900 - - [ruby/yarp] Add missing snapshot - - https://github.com/ruby/yarp/commit/08f08a6cc4 - -commit 3acf5a27c9ae5be7b24774f0098750db229dc9ac - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-26 19:06:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-26 19:06:46 +0900 - - Suppress warnings - -commit dc940cc74050ec783882ad5914d8315011d89b8e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-26 18:24:39 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-26 18:25:21 +0900 - - [DOC] Nested ordered lists need more indents - -commit d1b6ff42fa0c7345713ec5e40c9cd782dac88948 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-26 13:49:02 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-26 13:52:07 +0900 - - Add the chopsticks code at RubyKaigi2023 - -commit ed587abffb48da991c33d232fd151683458938a9 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-06-25 22:46:44 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-26 05:44:59 +0900 - - Fix broken links - - Notes: - Merged: https://github.com/ruby/ruby/pull/7979 - -commit 83076272455cc9efd0c4319a8c0a30c4521c54ca - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-26 00:39:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-26 00:45:32 +0900 - - [ruby/uri] String literals are frozen now - - https://github.com/ruby/uri/commit/0b6ad60af6 - -commit c21436cb353f8194db647bde2a5ef434eb3dcb2a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-25 23:58:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-26 00:24:05 +0900 - - [ruby/uri] Fix host part in relative referece #83 - - In relative referece, host part can be ommitted but can not be empty. - - https://github.com/ruby/uri/commit/2980f0ba02 - -commit 15ec072a4266cba7b3548548ef48d85d296ae9e2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-25 17:20:34 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-25 17:21:31 +0900 - - [DOC] Parse documents under doc/yjit - -commit 0a9ef0548b31df6660baac923e23b50c98686a1d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-25 17:19:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-25 17:21:31 +0900 - - [DOC] Parse all documents under doc/regexp - -commit 9df5b4562e2d70e4f0812c477e0c894f0eaa35ab - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-06-25 16:00:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-25 16:00:17 +0900 - - Update bundled gems list at 2023-06-25 - -commit 00216c8aa0522fbb0bb9d1914881111cae133e42 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-06-25 14:12:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-25 14:12:16 +0900 - - [ruby/irb] Fix process_continue(rename to should_continue?) and - check_code_block(rename to check_code_syntax) - (https://github.com/ruby/irb/pull/611) - - https://github.com/ruby/irb/commit/b7f4bfaaa4 - -commit 406799cae8fe491cc9966233f19c5803c03d9149 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-06-25 07:20:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-25 07:20:43 +0900 - - [ruby/irb] Omit nesting_level, use indent_level to build prompt - string - (https://github.com/ruby/irb/pull/610) - - https://github.com/ruby/irb/commit/f01ff0811b - -commit a14915ca4baae40f08d288a38b8bfb595500ad90 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-06-22 01:44:30 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-06-25 00:41:32 +0900 - - Do not have Enumeratory::Lazy#zip mark result as packed - - Fixes [Bug #19569] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7967 - -commit c94b5f121dae49b931349ec60da243f98c8e3d82 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-17 11:33:12 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-24 19:17:37 +0900 - - De-duplicate parse_st.c code from st.c - - Notes: - Merged: https://github.com/ruby/ruby/pull/7956 - -commit 3443e43b625f4ba1821a101df9cdfd88347fbe6c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-16 22:14:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-24 19:17:37 +0900 - - Remove `st_functions_t` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7956 - -commit e02c7a7340f293ff4d6d6fc799bca485a257836e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-24 18:18:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-24 18:18:58 +0900 - - Ignore only warnings known by clang - - Clang 17 does not know warning group '-Wgnu-empty-initializer'. - -commit 97152d44dcd7072a22574cc15c82e4bfa901cd16 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-23 19:16:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-24 15:32:11 +0900 - - [ruby/yarp] Name test methods from relative paths - - Full path name of the source directory is a useless noise as tests. - - https://github.com/ruby/yarp/commit/44a7ae2e64 - -commit 261e3663fdabd1665d0b978ecd12b0ddb639b190 - Author: Steven Johnstone <steven.james.johnstone@gmail.com> - AuthorDate: 2023-06-23 23:43:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-24 04:56:40 +0900 - - [ruby/yarp] Check for eof in yp_regexp_char_is_eof - - https://github.com/ruby/yarp/commit/f3fbc5bf9e - -commit 6ee106ff7953c155fe9b04ae7d9fe4f4617d7348 - Author: Steven Johnstone <steven.james.johnstone@gmail.com> - AuthorDate: 2023-06-23 18:53:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-24 04:56:39 +0900 - - [ruby/yarp] If ? is last char of regexp buffer, don't read beyond it. - - https://github.com/ruby/yarp/commit/1764532572 - -commit 6dc231496501f01df43793efdd9aeb43349ed8bc - Author: Steven Johnstone <steven.james.johnstone@gmail.com> - AuthorDate: 2023-06-23 17:58:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-24 04:56:39 +0900 - - [ruby/yarp] Don't read past the end of input parsing regex group - - https://github.com/ruby/yarp/commit/03f5a330a9 - -commit 7ce6bcaf8b1f06ff27920f287f534b9c19d9ccc3 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-06-22 08:02:08 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-06-24 03:46:21 +0900 - - Expose rb_hash_resurrect - - This is for implementing the `duphash` instruction - - Notes: - Merged: https://github.com/ruby/ruby/pull/7969 - -commit 01507d2f80a99985c5f25027d87e58b8a97b3da2 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-23 23:35:36 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-23 23:37:04 +0900 - - Skip test on Solaris SPARC - - This test fails on Solaris SPARC with the following error and I can't - figure out why: - TestGCCompact#test_moving_hashes_down_size_pools - Expected 499 to be >= 500. - -commit 73529a12bbf5bb88b2596ca1169bd29dc75aa2e6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-23 14:54:50 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-23 14:54:50 +0900 - - Declare `RHASH_AR_TABLE` and `RHASH_ST_TABLE` return non-null - - Notes: - Merged: https://github.com/ruby/ruby/pull/7976 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit b7375770ef15c7d7b3fdf14bf1964a0209881f98 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-23 12:51:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-23 12:52:03 +0900 - - [ruby/timeout] Bump up v0.4.0 - - https://github.com/ruby/timeout/commit/413194f8d2 - -commit e8c9385123d6f7678b8c37f5543933703907abd2 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-06-23 03:24:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-23 03:24:46 +0900 - - [ruby/timeout] Raise exception instead of throw/catch for timeouts - (https://github.com/ruby/timeout/pull/30) - - throw/catch is used for non-local control flow, not for exceptional situations. - For exceptional situations, raise should be used instead. A timeout is an - exceptional situation, so it should use raise, not throw/catch. - - Timeout's implementation that uses throw/catch internally causes serious problems. - Consider the following code: - - ```ruby - def handle_exceptions - yield - rescue Exception => exc - handle_error # e.g. ROLLBACK for databases - raise - ensure - handle_exit unless exc # e.g. COMMIT for databases - end - - Timeout.timeout(1) do - handle_exceptions do - do_something - end - end - ``` - - This kind of design ensures that all exceptions are handled as errors, and - ensures that all exits (normal exit, early return, throw/catch) are not - handled as errors. With Timeout's throw/catch implementation, this type of - code does not work, since a timeout triggers the normal exit path. - - See https://github.com/rails/rails/pull/29333 for an example of the damage - Timeout's design has caused the Rails ecosystem. - - This switches Timeout.timeout to use raise/rescue internally. It adds a - Timeout::ExitException subclass of exception for the internal raise/rescue, - which Timeout.timeout will convert to Timeout::Error for backwards - compatibility. Timeout::Error remains a subclass of RuntimeError. - - This is how timeout used to work in Ruby 2.0. It was changed in Ruby 2.1, - after discussion in [Bug #8730] (commit - https://github.com/ruby/timeout/commit/238c003c921e in the timeout repository). I - think the change from using raise/rescue to using throw/catch has caused - significant harm to the Ruby ecosystem at large, and reverting it is - the most sensible choice. - - From the translation of [Bug #8730], it appears the issue was that - someone could rescue Exception and not reraise the exception, causing - timeout errors to be swallowed. However, such code is broken anyway. - Using throw/catch causes far worse problems, because then it becomes - impossible to differentiate between normal control flow and exceptional - control flow. - - Also related to this is [Bug #11344], which changed how - Thread.handle_interrupt interacted with Timeout. - - https://github.com/ruby/timeout/commit/f16545abe6 - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit b934976024ef4e1694ec47158d94bce0f6d003b7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-23 03:15:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-23 03:15:55 +0900 - - Prefer `0` over `NULL` as function pointers - - SunC warns use of `NULL`, pointer to data as function pointers. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7972 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 52f8de4f21b147468567f422ac9551ae5c194164 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-23 03:08:25 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-23 03:08:25 +0900 - - Remove dead code in hash.c - - RHASH_TABLE_NULL_P and ar_alloc_table are no longer needed since - all Hash will have AR tables. - -commit 218a8d8ef1504e98e59f65c135dba8d0991dca93 - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-06-23 02:07:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-23 02:07:23 +0900 - - [ruby/reline] Remove unused method - (https://github.com/ruby/reline/pull/557) - - `get_mbchar_byte_size_by_first_char` isn't used in Reline. - Also, this method implements the same functionality as `String#bytesize` and is unnecessary. - -commit de51a4a13eab2c4c5917de923edde33dfed6f22f - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-06-23 01:11:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-23 01:40:46 +0900 - - [ruby/ipaddr] Consider IPv4-mapped IPv6 addresses private if IPv4 address is private - - Fixes [Bug #19479] - - https://github.com/ruby/ipaddr/commit/7faa0768d3 - -commit 711cabec26eee20a30a2d8642b9f05ad6e7eeb49 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-06-23 01:23:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-23 01:23:07 +0900 - - Sync ruby/yarp to https://github.com/ruby/yarp/commit/89a00203af803032383338c943836da6bafca7d9 - -commit e8fb84265c897d5e64b1fcb71054ef7eebe13262 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-06-22 01:59:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-23 01:20:40 +0900 - - [ruby/yarp] Allow for block statements after elsif and else - - https://github.com/ruby/yarp/commit/4560cab235 - -commit 7fad7d345acae5a44bc12c1ee98220b83f6f249c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-06-23 01:01:28 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-23 01:19:39 +0900 - - [ruby/yarp] Do not leak file descriptors - - https://github.com/ruby/yarp/commit/83c2c45b28 - -commit b879528e24272d8fbe41fe0e4e07cadcca5b643c - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-06-22 00:25:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-23 01:19:36 +0900 - - [ruby/yarp] Do not leak memory from lex modes - - https://github.com/ruby/yarp/commit/df6661740c - -commit edd488109fe8a95ec8674886905fe503fc0f9108 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-06-23 00:59:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-23 00:59:04 +0900 - - Sync ruby/yarp with sync_default_gems - -commit 1344de56219cf83ca146c5346783f8483af534f9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-22 20:10:13 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-22 20:10:13 +0900 - - [Bug #19743] All but EOF can be read again after push-back - -commit 8142728b5a0b9cab217124e5dad33f8d46fd3652 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-21 17:44:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-22 18:44:41 +0900 - - [rubygems/rubygems] Prefer `assert_include` over mere `assert` - - https://github.com/rubygems/rubygems/commit/140405cee6 - -commit a651903a868d2cefd517b3a31025af443a35b8a9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-21 17:44:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-22 18:44:41 +0900 - - [rubygems/rubygems] Prefer `assert_predicate` over mere `assert` - - https://github.com/rubygems/rubygems/commit/0d10063824 - -commit 67ab8b4346f69d80ef6563b6269355adc41c472c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-21 17:17:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-22 18:44:40 +0900 - - [rubygems/rubygems] Fix argument order of `assert_equal` - - https://github.com/rubygems/rubygems/commit/a7c015f82b - -commit ddb431c96036a46afd5ef24ab2dde4743a11a4f8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-22 12:35:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-22 13:21:30 +0900 - - Fix leaked FD for an empty file - - Notes: - Merged: https://github.com/ruby/ruby/pull/7970 - -commit 010b8a29dc152f25e6182c73b48b706dfa02c3f4 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-06-22 06:56:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-22 07:05:10 +0900 - - [ruby/yarp] Set default external encoding for parse tests - - https://github.com/ruby/yarp/commit/e757fde3ed - -commit 2beb14506fb9ab53e26bd2757a7e0810f090bf31 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-06-22 06:31:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-22 06:31:45 +0900 - - Handle non-enum values to fix -Wreturn-type - - http://ci.rvm.jp/results/trunk-random1@ruby-sp2-docker/4612360 - -commit 39a40af14f04b5aad238323972c3fdea7dddad2b - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-06-22 06:28:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-22 06:28:30 +0900 - - [ruby/yarp] Truly fix snapshot testing on Ruby CI - - https://github.com/ruby/yarp/commit/c4e835711e - -commit 51ff9cd7473afcdb45ad49dcd292bb6818057509 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-06-22 06:21:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-22 06:23:17 +0900 - - [ruby/yarp] Actually fix snapshot tests - - https://github.com/ruby/yarp/commit/ba9e5b447e - -commit 06ed9fcd0b10ec6f9d2590771fa4c0636415abd1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-06-22 05:55:59 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-22 05:56:00 +0900 - - Stop asking YJIT team to review dependabot changes - -commit 2acb27cad7e88803ed39c41fee2f1783240431d4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-06-22 05:50:59 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-22 05:51:39 +0900 - - Fix -Wold-style-definition - - http://ci.rvm.jp/results/trunk-yjit@ruby-sp2-docker/4612329 - - Also, I changed the position of `{` to be consistent with the rest of - the codebase. - -commit 23e1c69717e4182967e962ea06df659e7c7e9d29 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-06-22 05:27:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-22 05:30:40 +0900 - - [ruby/yarp] Fix snapshot checking - - https://github.com/ruby/yarp/commit/05a60a0774 - -commit 4be594a5256adcc7b0114dde37b1d5455e6fb409 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-06-22 05:02:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-22 05:02:59 +0900 - - Don't report neutral results of Cirrus CI - -commit 585dbccb5142911be03afe2979e2d3ca65b19674 - Author: Kevin Newton <kddnewton@gmail.com> - AuthorDate: 2023-06-22 04:52:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-22 04:55:45 +0900 - - [ruby/yarp] Use binary for normalizing printed ASTs - - https://github.com/ruby/yarp/commit/814326de34 - -commit b0a3a6ade0c1c1c0a1764c2b4a9a893b54b9f025 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-06-22 01:49:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-22 03:40:25 +0900 - - [ruby/yarp] Fix invalid unescape sequence error for lower w - - https://github.com/ruby/yarp/commit/5a2c78367a - -commit fcf2f5a522cd5100ca67bbf96b46cf4fe02fb372 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-06-22 03:35:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-22 03:35:36 +0900 - - Let yarp use main branch instead - -commit cc7f765f2c12a9ba050b0d95f9d85f3923c8d944 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-06-21 00:53:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-22 03:25:39 +0900 - - [Feature #19741] Sync all files in yarp - - This commit is the initial sync of all files from ruby/yarp - into ruby/ruby. Notably, it does the following: - - * Sync all ruby/yarp/lib/ files to ruby/ruby/lib/yarp - * Sync all ruby/yarp/src/ files to ruby/ruby/yarp/ - * Sync all ruby/yarp/test/ files to ruby/ruby/test/yarp - - Notes: - Merged: https://github.com/ruby/ruby/pull/7964 - -commit 08478fefca827276d68e33f2e6a5940c85957a51 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-06-21 00:50:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-22 03:25:39 +0900 - - [Feature #19741] Added Init_YARP() to load from the yarp C extension - - Init_YARP is called from inits.c, and it loads the YARP C extension - correctly - - Notes: - Merged: https://github.com/ruby/ruby/pull/7964 - -commit d53e1f42ff183af96832f6ede8e54afff6c8082f - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-06-21 00:48:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-22 03:25:39 +0900 - - [Feature #19741] Add yarp to builds - - Add yarp to common.mk and windows builds to enable us to run yarp - correctly with CI. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7964 - -commit 03f1a6c4c57c469e8fb5858cf9676b6479f4610d - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-06-21 00:46:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-22 03:25:39 +0900 - - [Feature #19741] Add yarp to `tool/sync_default_gems.rb` sync script - - The default gems sync script now includes YARP, found in the - ruby/yarp repo. This script primarily syncs over the src, test, lib - directories. It also migrates all encoding files to be prefixed - with `yp_` in order to deconflict from existing encoding files. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7964 - -commit a87bce86bb2a7581943355b41abaf41a6ad18218 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-06-21 16:49:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-21 16:49:51 +0900 - - Allow setting the name of a class or module. (#7483) - - Introduce `Module#set_temporary_name` for setting identifiers for otherwise - anonymous modules/classes. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit e25403d0d97b737901d137c54635df0413155ad4 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-06-21 00:13:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-21 00:13:43 +0900 - - [ruby/irb] Improve indentation: bugfix, heredoc, embdoc, strings - (https://github.com/ruby/irb/pull/515) - - * Implement heredoc embdoc and string indentation with bugfix - - * Fix test_ruby_lex's indentation value - - * Add embdoc indent test - - * Add workaround for lines==[nil] passed to auto_indent when exit IRB with CTRL+d - -commit 9ce6e096370b150de4aa9e426726e1cc06f725b8 - Author: Yuta Kusuno <56626111+yutakusuno@users.noreply.github.com> - AuthorDate: 2023-06-20 23:02:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-20 23:02:58 +0900 - - [ruby/reline] Omit constant under Struct - (https://github.com/ruby/reline/pull/554) - - https://github.com/ruby/reline/commit/8761a11fa5 - -commit 932dd9f10e684fa99b059054fbc934607d85b45a - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-06-20 22:28:21 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-20 22:28:21 +0900 - - [DOC] Regexp doc (#7923) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 6be402e172a537000de58a28af389cb55dd62ec8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-20 20:10:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-20 20:10:46 +0900 - - [Bug #19736] Recover after unterminated interpolation - - Notes: - Merged: https://github.com/ruby/ruby/pull/7963 - -commit 9ac070d0ff16523c24b171e20123840e21b4dbec - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-20 14:02:40 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-20 14:02:40 +0900 - - Copy instance variables to regexp from marshaled data - - `rb_ivar_foreach` disallows `ST_DELETE`. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7962 - -commit 2dfbe91cad2ebc6aa1a925b1b77b7af07fec1403 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-20 12:39:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-20 13:57:42 +0900 - - Stop `rb_ivar_foreach` when callback returned `ST_STOP` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7962 - -commit 1edbaa850f6907c9b4bbaa083ef13a578f251da1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-20 12:04:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-20 13:35:13 +0900 - - Merge rubygems/rubygems HEAD - - Pick from https://github.com/rubygems/rubygems/commit/880dd95996c93adc1e032399816931b243c5fe17 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7961 - -commit 44ad176fc250553950ee7b54071d14aedc4183a5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-20 13:33:49 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-20 13:34:28 +0900 - - Update Racc entries on documents - -commit 9ff4399decef0036897d3cfb9ac2c710dea913ca - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-06-20 03:18:13 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-06-20 04:19:45 +0900 - - CI: work around vcpkg openssl issue with OpenSSL providers - - Currently, the openssl package from vcpkg uses an incorrect, hard-coded - default location for OpenSSL providers under C:\vcpkg\packages, which - is supposed to be a temporary directory. - - Override it with the OPENSSL_MODULES environment variable as a - temporary workaround. - -commit 11ee4f2b71afc2c41da2466d77262ced4c803634 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-17 12:46:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-20 02:24:38 +0900 - - [rubygems/rubygems] Suppress Content-Type warnings - - https://github.com/rubygems/rubygems/commit/97dbe4cabd - -commit 512cac32400ce1f3acf77226a435d3e8cf7347c5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-20 00:29:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-20 00:29:24 +0900 - - Remove taint and untrusted flags (#7958) - - * Make TAINT and UNTRUSTED flags zero - - These flags do nothing already, and should break nothing. - - * Remove TAINT and UNTRUSTED macros same as functions - - These macros had been defined to use with `#ifdef`, but should not be - used anymore. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit b8cd79c82fc0816a880e2a2cf77a6e6826a763a6 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-06-19 19:38:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-19 19:38:24 +0900 - - [ruby/irb] Add missing token that ignored by ripper - (https://github.com/ruby/irb/pull/608) - - https://github.com/ruby/irb/commit/1cd3b45402 - -commit 2a80bac9f08b6d743399158d5bb96061f450a679 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-19 18:28:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-19 18:28:10 +0900 - - Remove `--jobserver-auth` option which varies for each run - -commit e9f62fa5a762d367e3dc1818d29450ee8e9e25ab - Author: qwyng <ikusawasi@gmail.com> - AuthorDate: 2023-06-02 21:12:21 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-06-19 17:45:51 +0900 - - [ruby/openssl] add OpenSSL Provider support - - https://github.com/ruby/openssl/commit/189c167e40 - [rhe: tool/update-deps --fix to update ext/openssl/depend] - -commit e7440dcaeae68de421356e22c9126b4325ad7bff - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-16 23:58:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-19 11:24:14 +0900 - - [rubygems/rubygems] RemoteFetcher tests don't work with path including `+` - - https://github.com/rubygems/rubygems/commit/657d57621e - -commit 10e4a9a5c271366a426056566edbdef3f4311c9d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-16 23:55:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-19 11:24:13 +0900 - - [rubygems/rubygems] Escape regexp metachacters or use `assert_include` - - https://github.com/rubygems/rubygems/commit/6d445a85d7 - -commit af66b9b7203a22e6029872513c59a7284f381cf9 - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-06-07 03:46:43 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-06-19 01:57:09 +0900 - - [ruby/openssl] pkey: use unsigned type for bit fields - - clang generates a warning: - - ../../../../ext/openssl/ossl_pkey.c:326:22: error: implicit truncation from 'int' to a one-bit wide bit-field changes value from 1 to -1 [-Werror,-Wsingle-bit-bitfield-constant-conversion] - arg->interrupted = 1; - ^ ~ - 1 error generated. - - https://github.com/ruby/openssl/commit/4b2ba7b022 - -commit 397ebbc62dafef02c9c47ea2d67fd31253f7b81b - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-06-07 03:44:07 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-06-19 01:57:09 +0900 - - [ruby/openssl] Drop support for Ruby 2.6 - - Ruby 2.6 has reached EOL on 2022-03. Requiring Ruby 2.7 allows us to - use C99 syntax. - - https://github.com/ruby/openssl/commit/f6ba75e51e - -commit bc0539a9b7538c5cb0c194cc0a700466cfa1b003 - Author: Theo Buehler <tb@openbsd.org> - AuthorDate: 2023-04-12 02:43:49 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-06-19 01:57:09 +0900 - - [ruby/openssl] Fix modular square root test with LibreSSL >= 3.8 - - If x is a modular square root of a (mod p) then so is (p - x). Both - answers are valid. In particular, both 2 and 3 are valid square roots - of 4 (mod 5). Do not assume that a particular square root is chosen by - the algorithm. Indeed, the algorithm in OpenSSL and LibreSSL <= 3.7 - returns a non-deterministic answer in many cases. LibreSSL 3.8 and - later will always return the smaller of the two possible answers. This - breaks the current test case. - - Instead of checking for a particular square root, check that the square - of the claimed square root is the given value. This is always true. Add - the simplest test case where the answer is indeed non-deterministic. - - https://github.com/ruby/openssl/commit/93548ae959 - -commit 1d0a087d45ff898862eb829a718af5d855adfc7c - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2023-06-02 01:51:03 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-06-19 01:57:09 +0900 - - [ruby/openssl] extconf.rb: apply RUBY_OPENSSL_EXT{C,LD}FLAGS after checking features - - RUBY_OPENSSL_EXTCFLAGS and RUBY_OPENSSL_EXTLDFLAGS have been added for - the primary purpose of appending custom warning flags during - development and CI. - - Since checking programs generated by mkmf may not be completely - warning-free, we don't want to apply -Werror that may be supplied from - those environment variables. - - https://github.com/ruby/openssl/commit/2a95b971d5 - -commit 366d8005b100d83a711234b2aa6176810bad2525 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-04-18 02:05:48 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-06-19 01:57:09 +0900 - - [ruby/openssl] CI: Add the test/openssl/test_pkey.rb on the FIPS mode case. - - It's to test the `OpenSSL::PKey.read` in the `test/openssl/test_pkey.rb`. - - I added the pending status to the following tests failing on the FIPS mode - case in the `test/openssl/test_pkey.rb`. - - * `test_ed25519` - * `test_x25519` - * `test_compare?` - - https://github.com/ruby/openssl/commit/8149cdf6e8 - -commit 920bc71284f417f9044b0dc1822b1d29a8fc61e5 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-04-14 00:28:27 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-06-19 01:57:09 +0900 - - [ruby/openssl] Drop a common logic disabling the FIPS mode in the tests. - - We want to run the unit tests in the FIPS mode too. - - https://github.com/ruby/openssl/commit/ab92baff34 - -commit 2a4834057b30a26c38ece3961b370c0b2ee59380 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-04-13 00:15:21 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-06-19 01:57:09 +0900 - - [ruby/openssl] Workaround: Fix OpenSSL::PKey.read that cannot parse PKey in the FIPS mode. - - This commit is a workaround to avoid the error below that the - `OpenSSL::PKey.read` fails with the OpenSSL 3.0 FIPS mode. - - ``` - $ openssl genrsa -out key.pem 4096 - - $ ruby -e "require 'openssl'; OpenSSL::PKey.read(File.read('key.pem'))" - -e:1:in `read': Could not parse PKey (OpenSSL::PKey::PKeyError) - from -e:1:in `<main>' - ``` - - The root cause is on the OpenSSL side. The `OSSL_DECODER_CTX_set_selection` - doesn't apply the selection value properly if there are multiple providers, and - a provider (e.g. "base" provider) handles the decoder implementation, and - another provider (e.g. "fips" provider) handles the keys. - - The workaround is to create `OSSL_DECODER_CTX` variable each time without using - the `OSSL_DECODER_CTX_set_selection`. - - https://github.com/ruby/openssl/commit/5ff4a31621 - -commit 1965c09ee50b5202d45462cd8bc6224ca6e45ae9 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-03-13 17:51:53 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-06-19 01:57:09 +0900 - - [ruby/openssl] Implement Write Barrier for all OpenSSL types - - The vast majority have no reference so it's just a matter of setting the flags. - - For the couple exception, they have very little references so it's - easy. - - https://github.com/ruby/openssl/commit/2c7c6de69e - -commit 0a84bd6b0b5f947b4727b022c5768222b3e6d7d9 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-05-31 07:10:41 +0900 - Commit: Kazuki Yamaguchi <k@rhe.jp> - CommitDate: 2023-06-19 01:57:09 +0900 - - [ruby/openssl] Append flags from environment variables. - - According to the `mkmf.rb#init_mkmf`, there are command line options below. - - * `--with-cflags` to set the `cflags` - * `--with-ldflags` to set the `ldflags` - - For example the following command compiles with the specified flags. Note that - `MAKEFLAGS` is to print the compiler command lines. - - ``` - $ MAKEFLAGS="V=1" \ - bundle exec rake compile -- \ - --with-cflags="-Wundef -Werror" \ - --with-ldflags="-fstack-protector" - ``` - - However, I couldn't find command line options to append the flags. And this - commit is to append the `cflags` and `ldflags` by the environment variables. - - ``` - $ MAKEFLAGS="V=1" \ - RUBY_OPENSSL_EXTCFLAGS="-Wundef -Werror" \ - RUBY_OPENSSL_EXTLDFLAGS="-fstack-protector" \ - bundle exec rake compile - ``` - - https://github.com/ruby/openssl/commit/b551eb86f6 - -commit 7adab819074e448ffbb6e8d99e4edb0567e4405a - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-06-18 10:23:23 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-06-18 11:15:54 +0900 - - Fix the format of NODE_EVSTR rendered by dump_node - - Notes: - Merged: https://github.com/ruby/ruby/pull/7955 - -commit 4f79c83a6a040c27840bad0f85520e680deda564 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-06-17 17:34:01 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-06-18 10:10:52 +0900 - - Remove coverage_enabled from parser_params - - `yyparse` never changes the value of `coverage_enabled`. - `coverage_enabled` depends on only return value of `e_option_supplied`. - Therefore `parser_params` doesn't need to have `coverage_enabled. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7951 - -commit d444f1b1fa69accf8723520195f431ed42dcceed - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-06-17 19:32:38 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-06-17 22:02:13 +0900 - - Specify int bitfield as signed int bitfield - - sunc treats int bitfield as unsigned int. - This commit will fix build failure on sunc. - - * http://rubyci.s3.amazonaws.com/solaris10-sunc/ruby-master/log/20230617T100003Z.fail.html.gz - * http://rubyci.s3.amazonaws.com/solaris11-sunc/ruby-master/log/20230617T090011Z.fail.html.gz - - Notes: - Merged: https://github.com/ruby/ruby/pull/7952 - -commit 19c62b400d3458c4525f174515bcb616af7dfdfe - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-06-17 10:21:37 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-06-17 16:41:08 +0900 - - Replace parser & node compile_option from Hash to bit field - - This commit reduces dependency to CRuby object. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7950 - -commit e5ae7a16b49d4cf7c7069aeb01ed5c4e58152055 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-06-17 15:59:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-17 15:59:21 +0900 - - Update bundled gems list at 2023-06-17 - -commit b943e9c7b9d9cc8ba4bbf043414ab1ed4e1a8b5f - Author: Peter Arato <it.arato@gmail.com> - AuthorDate: 2023-06-15 01:50:40 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-17 15:48:03 +0900 - - Fixes [Bug #19732]. Add missing stdint.h header to event.h. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7945 - -commit ba0bcc52039a40d2a013de4e05c9fbc62e4f4be2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-17 11:30:23 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-17 13:24:58 +0900 - - Use ruby functions if `RUBY` is defined - - Notes: - Merged: https://github.com/ruby/ruby/pull/7949 - -commit 9001d54788568814a691a4f1dd86db47cf232e03 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-17 10:39:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-17 13:24:58 +0900 - - Expand `#ifdef RUBY` region - - Include the functions which are only used for - `rb_hash_bulk_insert_into_st_table`. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7949 - -commit 725739d65bf2a3369467f3b8ef9f2a0a125a4084 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-17 12:32:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-17 12:32:53 +0900 - - Remove no longer used variable - -commit 7b3a531fffcac5ba09edd050feccd9149205cd7e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-17 12:29:28 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-17 12:29:28 +0900 - - Split the bmethod proc test to avoid redefinition - -commit 1ff20944107a20009445b1caac19a9b3728a3729 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-16 18:47:36 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-16 22:32:52 +0900 - - Copy `nonempty_memcpy` without ruby implementation - - Notes: - Merged: https://github.com/ruby/ruby/pull/7948 - -commit 60cf48ca4f09270bd87063d645018bca593c04d1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-16 17:31:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-16 22:32:52 +0900 - - Suppress redefined macro warnings - - Notes: - Merged: https://github.com/ruby/ruby/pull/7948 - -commit 80dfe2bc4dd50f9d26586b7ac3516baf2eb7484a - Author: zzak <zzakscott@gmail.com> - AuthorDate: 2023-06-16 16:15:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-16 17:54:12 +0900 - - [ruby/rdoc] Fix missing closing colon for `:notnew:` - - https://github.com/ruby/rdoc/commit/1e550b7d02 - -commit 5bc1b56c14db279368c16a099c538189483c0a5a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-16 08:46:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-16 13:10:38 +0900 - - [rubygems/rubygems] Auto-correct Performance/FlatMap - - https://github.com/rubygems/rubygems/commit/b696edcd73 - -commit 364a6d56d776270da09604816d623047c66c5e32 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-06-16 00:39:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-16 00:39:58 +0900 - - [ruby/irb] Rewrite RubyLex to fix some bugs and make it possible to - add new features easily - (https://github.com/ruby/irb/pull/500) - - * Add nesting level parser for multiple use (indent, prompt, termination check) - - * Rewrite RubyLex using NestingParser - - * Add nesting parser tests, fix some existing tests - - * Add description comment, rename method to NestingParser - - * Add comments and tweak code to RubyLex - - * Update NestingParser test - - * Extract list of ltype tokens to constants - -commit 0c55ef11509d0cf480ef46b98965a63f6499c6bd - Author: Petrik <petrik@deheus.net> - AuthorDate: 2023-06-15 05:39:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-15 08:47:25 +0900 - - [ruby/rdoc] Use flat_map for better performance - - https://github.com/ruby/rdoc/commit/76192a280d - -commit c2f4b414804a4ccd3edeec87e6998beb60c002bb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-15 07:02:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:02:03 +0900 - - Merge rubygems/rubygems HEAD - - Pick from https://github.com/rubygems/rubygems/commit/7a7b234721c375874b7e22b1c5b14925b943f04e - -commit 827d66266be9feff10f71dd26fa04227423d134a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-14 16:51:53 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:28 +0900 - - [rubygems/rubygems] auto-correct Style/YodaCondition - - https://github.com/rubygems/rubygems/commit/6d9e8025dc - -commit 503b9bf1d4f6c9ef168a2dcd16e01b2e376a305f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-14 16:51:20 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:28 +0900 - - [rubygems/rubygems] Removed unnecessary disabling of Lint/DuplicateMethods - - https://github.com/rubygems/rubygems/commit/225fdf0b2e - -commit 2c219ab2155483e23d1a6e9fd5262d0206f837e4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-14 16:40:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:27 +0900 - - [rubygems/rubygems] Rubocop 1.51.0 or later didn't support Ruby 2.6 - - https://github.com/rubygems/rubygems/commit/522b5f1ecd - -commit 3e7f5b02aeb2a55b27d402024f42821684d85ec6 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-10 07:24:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:25 +0900 - - [rubygems/rubygems] Improve error message in frozen mode edge case - - When a top level dependency is missing from the lockfile, and we're in - frozen mode, we should also print a "frozen error". - - https://github.com/rubygems/rubygems/commit/3e82b835e3 - -commit e86f4c581b274a3e0bb198b1567cc9aa07d95343 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-10 07:19:39 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:25 +0900 - - [rubygems/rubygems] Improve frozen mode error message - - This error message is also printed when using `bundler/setup` in frozen - model, so we're not necessarily installing any gems when it happens. - - This new message play nicer with all situations. - - https://github.com/rubygems/rubygems/commit/6874bbacce - -commit 23ecaab8dd7e7153ee34cc2cdf43df4448d66e41 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-10 07:03:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:24 +0900 - - [rubygems/rubygems] Use "frozen" rather than "deployment" in error message - - I think it communicates better what's going on. - - https://github.com/rubygems/rubygems/commit/07a25767a4 - -commit 2ff9b7b93dc3929426be393ccd05ece2f89d8276 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-10 06:42:20 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:24 +0900 - - [rubygems/rubygems] Show missing spec in lockfile incomplete error message - - https://github.com/rubygems/rubygems/commit/b86caaa3d5 - -commit 21238f38a8eb881d403e47395781c2cc9eafbd9a - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-10 04:10:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:23 +0900 - - [rubygems/rubygems] Extract `Definition#no_resolved_needed?` - - https://github.com/rubygems/rubygems/commit/1ff8626571 - -commit 4f1b1817a8f5f51f9e3687dac465dabfb112883b - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-10 02:37:24 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:23 +0900 - - [rubygems/rubygems] There should always be a reason - - https://github.com/rubygems/rubygems/commit/4180008c2d - -commit c12168185e20b1b73a73d433425f2299221f2ddb - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-09 04:24:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:22 +0900 - - [rubygems/rubygems] Show relative path to Gemfile in error message - - For conciseness and consistency with printing the relative path to the - lockfile just before. - - https://github.com/rubygems/rubygems/commit/74cf6aea7c - -commit e7749c4dea1e580455264b6c4caa03d79524aef4 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-09 03:31:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:21 +0900 - - [rubygems/rubygems] Remove weird line breaks in the middle of error message - - https://github.com/rubygems/rubygems/commit/22b8caf42f - -commit 90c60e81380bfc8955135bc50f02a2018623ff98 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-09 02:58:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:21 +0900 - - [rubygems/rubygems] Simplify checking Gemfile vs lockfile sources - - https://github.com/rubygems/rubygems/commit/251e80aec6 - -commit 96e3f31c1e857fda1ce28b766dd766b67ceb682a - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-09 02:42:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:20 +0900 - - [rubygems/rubygems] Make frozen mode spec also pass on Bundler 3 - - https://github.com/rubygems/rubygems/commit/ad52f840f2 - -commit e1038f943fdfa2d156e800554718ed6e4e1b3828 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-06-09 02:40:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:20 +0900 - - [rubygems/rubygems] This spec is independent from global sources - - https://github.com/rubygems/rubygems/commit/d91c245921 - -commit 551b8a31a94eb114c266d5af1cfdf1d30ac5cb61 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-15 07:01:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-15 07:01:06 +0900 - - Update directory layout of rubygems/rubygems - -commit 813a5f4fc46a24ca1695d23c159250b9e1080ac7 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-14 21:01:15 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-14 23:42:40 +0900 - - Directly allocate FrozenCore as an ICLASS - - It's a bad idea to overwrite the flags as the garbage collector may have - set other flags. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7940 - -commit 37513490442322e82961bf6d06c1c86d55cb3830 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-14 17:52:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-14 17:52:49 +0900 - - [Cirrus] Cache the bundled gems in advance - -commit bd019ac87aa47c481348ec6b7e3773bba3028392 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-14 08:35:56 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-14 14:24:29 +0900 - - Removed rake-compiler dependency for test-bundled-gems - - It's needless with racc-1.7.1 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7943 - -commit 6e93320c1b5ee25331ffc300beb5f14f2630403f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-14 12:56:34 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-14 12:56:34 +0900 - - Update RDoc::RD parsers generated by racc-1.7.1 - -commit f9deff32a354d1f14653337d027c1e841551ff59 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-14 01:33:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-14 12:14:20 +0900 - - Show prerequisites for compile task - - Notes: - Merged: https://github.com/ruby/ruby/pull/7941 - -commit c5c15a565b9b88745fe08f2ff78c2e0e5b401498 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-14 01:21:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-14 12:14:20 +0900 - - Allow test-unit-ruby-core files to be loaded from bundled gems - - Separate the directly from the customized test-unit, since it may not - work with bundled gems. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7941 - -commit 8722342ca9b5f770e678ccc93c4f68351e267c3c - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-06-13 22:22:44 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-06-14 10:40:25 +0900 - - Lrama v0.5.2 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7939 - -commit 5a69e8bcefcb609bf02b278a19cd9bf9018cea82 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-06-13 23:55:38 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-13 23:55:38 +0900 - - Add tests to `String#byteslice` memory allocation behaviour. (#1909) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 91b106fe4b6473e0a1bc3a021d279ddc52bc7de6 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-06-13 20:02:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-13 20:02:26 +0900 - - [ruby/irb] Stanardise test class names with `Test` postfix instead - of prefix - (https://github.com/ruby/irb/pull/603) - - https://github.com/ruby/irb/commit/359cb28def - -commit 27d581ea6ccda94a5c999fa566add8a7b895c358 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-13 18:27:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-13 19:49:32 +0900 - - rexml is also bundled gems - - Notes: - Merged: https://github.com/ruby/ruby/pull/7937 - -commit e5cf6b6dbe7b571f83f7ef0f0c200f0a3c76bcea - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-13 17:58:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-13 19:49:32 +0900 - - Don't install bundled gems for test-bundled-gems and test-syntax-suggest - - Notes: - Merged: https://github.com/ruby/ruby/pull/7937 - -commit 5d91be7c1fe10ef52cd6075328b8c121fb5420c8 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-06-13 19:46:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-13 19:46:38 +0900 - - [ruby/irb] Use symbol.inspect instead of ":"+symbol.id2name to avoid - completion candidates including newline characters - (https://github.com/ruby/irb/pull/539) - - https://github.com/ruby/irb/commit/aaf0c46645 - -commit 27b07776c99dfb4a8a4e6885462786c03e9b0660 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-06-09 22:10:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-13 18:32:47 +0900 - - [rubygems/rubygems] Autoload shellwords when it's needed. - - https://github.com/rubygems/rubygems/commit/e916ccb2d9 - -commit c74f42a4fbbf1b0d9267be8c2a23e4b828447172 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-06-13 15:59:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-13 15:59:40 +0900 - - Update bundled gems list at 2023-06-13 - -commit 6d734a89751d5553f22dbb674247f25c825e9274 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-13 13:54:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-13 14:57:17 +0900 - - [ruby/uri] Fix RFC3986 regexps - - https://github.com/ruby/uri/commit/8e38592241 - -commit 3924dba552804773fd66d98a57539ccb16943835 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-13 12:28:32 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-13 12:28:33 +0900 - - Update the current URI maintainer - -commit 57c5b0a980c123f93082b168eff8ceab04085d2f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-10-13 18:01:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-13 12:25:45 +0900 - - [ruby/uri] Refactor RFC3986 regexps to make more readable - - https://github.com/ruby/uri/commit/3dfa19e920 - -commit 3168f618cb3426dc2923b3dd1f315e34f4d137cd - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-13 03:38:56 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-13 03:38:56 +0900 - - hash.c no longer needs the transient heap - -commit 78ca085785460de46bfc4851a898d525c1698ef8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-06-13 03:30:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-06-13 03:30:25 +0900 - - Revert "YJIT: Break register cycles for C arguments (#7918)" - - This reverts commit 888ba29e462075472776098f4f95eb6d3df8e730. - - It caused a CI failure - http://ci.rvm.jp/results/trunk-yjit@ruby-sp2-docker/4598881 - and I'm investigating it. - -commit 888ba29e462075472776098f4f95eb6d3df8e730 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-06-13 01:54:06 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-13 01:54:06 +0900 - - YJIT: Break register cycles for C arguments (#7918) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 6fe46ff967215e47ab2234e9b48663d2e3608081 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-06-12 21:13:32 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-06-12 23:20:05 +0900 - - When alloc size is too large, only allocate struct - - Notes: - Merged: https://github.com/ruby/ruby/pull/7933 - -commit 81836c6cb9fceb4cc8e9e95317a6cbb3d0ad181a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-12 20:06:19 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-12 20:22:01 +0900 - - Fix duplicate symbol errors when statically linking ripper - -commit 41035273d474aac9b6e847d1d5b92e56c84b1f6d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-12 11:39:13 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-12 19:10:42 +0900 - - [DOC] Should use `NULL` instead of zero - - Since no type information is available for variadic arguments, 0 is - passed as `int` without promoting to pointer. On platforms where - `sizeof(int) < sizeof(void*)`, the terminator argument may be read - together with an adjoining word, and may not be found. - -commit 70483f6ca4dfbf758106da43144c595ace7d62b6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-12 19:10:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-12 19:10:29 +0900 - - Add missing dependencies - -commit b481b673d753339204290d7582dbb91a6e14447a - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-05-28 20:00:20 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-06-12 18:23:48 +0900 - - [Feature #19719] Universal Parser - - Introduce Universal Parser mode for the parser. - This commit includes these changes: - - * Introduce `UNIVERSAL_PARSER` macro. All of CRuby related functions - are passed via `struct rb_parser_config_struct` when this macro is enabled. - * Add CI task with 'cppflags=-DUNIVERSAL_PARSER' for ubuntu. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7927 - -commit bcded49d1a01632db3f06ac20231496b3ad1f958 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-04-05 20:09:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-12 16:02:02 +0900 - - [ruby/psych] Update spec files - - https://github.com/ruby/psych/commit/ba6fc48591 - -commit f6e6d52b226015063ea3ee002517911d41333648 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-12 11:29:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-12 13:18:28 +0900 - - Try to skip Prime_test.rb - - Notes: - Merged: https://github.com/ruby/ruby/pull/7928 - -commit 8be4659b600d28f9f9b812ab2692a367260528d9 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-12 10:02:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-12 13:18:28 +0900 - - Run test-unit test without rake task to avoid yard dependency - - Notes: - Merged: https://github.com/ruby/ruby/pull/7928 - -commit 2ec181992b2f14c2f1c9b3bd94590f8503136f1c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-12 09:34:37 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-12 13:18:28 +0900 - - pry is not needed for test-bundled-gems - - Notes: - Merged: https://github.com/ruby/ruby/pull/7928 - -commit 10e6626426fcbac3978fa63e9dd0b95076339239 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-08 21:52:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-12 12:02:10 +0900 - - [ruby/psych] Prefer `assert_include` for simple strings - - https://github.com/ruby/psych/commit/33024ce2b0 - -commit 52131d84f28b197f4ccb4abd80ab71d61cf4143c - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-06-11 16:01:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-11 16:01:53 +0900 - - Update bundled gems list at 2023-06-11 - -commit e1ccb2838b65f23e7a21bdd416160d03dd73e7f8 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-06-11 00:01:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-11 00:01:46 +0900 - - [ruby/irb] Use `Kernel.warn` to print command alias warning - (https://github.com/ruby/irb/pull/601) - - This aligns with other warnings in irb and properly channel the message - to stderr. - -commit be86767eeff745ac4d0255fa5d14da99e32f59bd - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-06-10 23:13:01 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-10 23:13:01 +0900 - - Add VM_ASSERT on `fiber->blocking == 0`. (#7926) - - I have not seen any problems with this code, but this ensures the invariant. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit a41e088604e70302d01ae6ba41ae334e08bdc690 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-06-10 21:51:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-10 21:51:38 +0900 - - [ruby/irb] Remove the unused fork command definition - (https://github.com/ruby/irb/pull/600) - - https://github.com/ruby/irb/commit/b039b89343 - -commit ab6eb3786c94e69c561080cbb796c2381702a3a4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-09 16:10:30 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-09 20:22:30 +0900 - - Optimize `Regexp#dup` and `Regexp.new(/RE/)` - - When copying from another regexp, copy already built `regex_t` instead - of re-compiling its source. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7922 - -commit d54f66d1b4ce32d78b526b1ea9e3f213a763d07c - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-06-09 05:12:14 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-06-09 18:54:40 +0900 - - Assign into optimal size pools using String#split("") - - When String#split is used with an empty string as the field seperator it - effectively splits the original string into chars, and there is a - pre-existing fast path for this using SPLIT_TYPE_CHARS. - - However this path creates an empty array in the smallest size pool and - grows from there, despite already knowing the size of the desired array. - - This commit pre-allocates the correct size array in this case in order - to allow the arrays to be embedded and avoid being allocated in the - transient heap - - Notes: - Merged: https://github.com/ruby/ruby/pull/7919 - -commit 11cc1827c4e58cf5392fb488d612e6da58abbd21 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-09 16:30:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-09 16:30:55 +0900 - - Added entry for racc changes to NEWS.md - -commit eaf11d3dd45a5be3466d189d7283d7c502e7f17a - Author: Gareth Adams <gareth@bridge-u.com> - AuthorDate: 2023-06-07 01:18:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-09 00:20:05 +0900 - - [rubygems/rubygems] Stop publishing Gemfile in default gem template - - Similarly to how the other ignored files are intended for local - development and not for production, the Gemfile and Gemfile.lock files - for a gem only relate to local development and aren't useful to people - installing the gem. - - https://github.com/rubygems/rubygems/commit/59049c04be - -commit 441302be1add6f10a85ccbde551a0fb567c65a15 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-08 23:42:59 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-08 23:42:59 +0900 - - Remove RHASH_TRANSIENT_FLAG - - Hashes are no longer allocated on the transient heap. - -commit d9ef326d291189128c92fefaa9aa2217cd06e9a8 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-08 23:28:16 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-08 23:28:16 +0900 - - [DOC] Add comment about flags for Hash - -commit 3fe09eba9d040d275d8305fe1b00f2f22218b6c8 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-06-08 20:22:43 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-08 20:22:43 +0900 - - Add deprecations for public `struct rb_io` members. (#7916) - - * Add deprecations for public struct rb_io members. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit d6bddcb0137d5a640eb22fbd17f9aa83f71fbd48 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-08 18:05:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-08 18:05:07 +0900 - - racc/cparse is extracted from ruby/ruby repository - -commit e69bb9f0d7dab447d757c34f674474406e2bd8f1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-08 15:22:49 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-08 17:25:38 +0900 - - Bump up racc-1.7.0 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7877 - -commit ab5aade5abb28a8bce2d2e86fb4e6ca3ac492f23 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-01 12:13:53 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-08 17:25:38 +0900 - - Removed executable of racc - - Notes: - Merged: https://github.com/ruby/ruby/pull/7877 - -commit d24e514d54f9d9d062993f37467efef3498577c0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-31 19:14:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-08 17:25:38 +0900 - - Added racc dependency - - Notes: - Merged: https://github.com/ruby/ruby/pull/7877 - -commit 55e0f8cfe0fe34cc96524341fc2319e487589934 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-31 18:19:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-08 17:25:38 +0900 - - Removed sync task for racc - - Notes: - Merged: https://github.com/ruby/ruby/pull/7877 - -commit 044d0606e29e67d7ac8c1ef38867b88b445907b7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-31 18:19:05 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-08 17:25:38 +0900 - - Removed racc/cparse checking - - Notes: - Merged: https://github.com/ruby/ruby/pull/7877 - -commit d1775aa388bff73ca2d22344d4c3745f23bfe654 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-31 17:35:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-08 17:25:38 +0900 - - Try to promote racc as bundled gems - - Notes: - Merged: https://github.com/ruby/ruby/pull/7877 - -commit b90683be44d8821a1a8121b6364d653a47421914 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-08 16:41:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-08 16:51:44 +0900 - - [ruby/psych] Drop to support Ruby 2.4 because the latest version of core_assertions only support Ruby 2.5+ - - https://github.com/ruby/psych/commit/6ec316b7fa - -commit fe42d88ad28df395111cfb9f2f67e21910083df1 - Author: Sam James <sam@cmpct.info> - AuthorDate: 2023-06-08 15:22:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-08 15:22:00 +0900 - - Pass -Werror=lto-type-mismatch for GCC LTO jobs - - This helps to find possible LTO miscompilations earlier. See also - https://github.com/ruby/ruby/pull/7695. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7704 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 533368ccbd9b0abd1633f1d7ea4dc737d75f38e6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-08 11:07:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-08 12:06:40 +0900 - - Split long options from `proc_options` - -commit 6ffbd9614782935f1a726d64638c21fe3c2fc671 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-08 10:18:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-08 12:06:39 +0900 - - Split some options from `proc_options` - - `-W`, `-e`, `-K`, `-0`, `-E` and `--encoding` options. - -commit 182d3262fb4147d3bdc5c1970b00f165bdb59ae9 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-08 10:31:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-08 10:31:46 +0900 - - Sample files of racc is not available in ruby/ruby - -commit 7ef1a2387e7fb8f80e217a20678031153814ab72 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-08 10:20:32 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-08 10:20:32 +0900 - - Re-generate RDoc::RD parsers with racc-1.7.0 - -commit a84f2fe8d176a8fa57aa559022a862d568c54e98 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-08 10:13:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-08 10:13:00 +0900 - - Manually merge https://github.com/ruby/racc/pull/217 - -commit 0f2ebfee85af383f859d9fdc64d58f654282c2be - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-08 10:08:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-08 10:09:05 +0900 - - [ruby/racc] Bump up v1.7.0 - - https://github.com/ruby/racc/commit/0feca00301 - -commit 8206a821408cad106f96bd0da1fd517e1581b147 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-08 09:59:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-08 09:59:44 +0900 - - Update parser-text.rb with https://github.com/ruby/racc/pull/218 - -commit c0bbec2ec7f2e87242331c301cc6b617c2f9b0a0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-08 09:58:01 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-08 09:58:01 +0900 - - Fix wrong directory layout for racc test - -commit 0ee9bd5800979210219514e671ba9ae6271042f9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-06 15:28:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-08 09:49:51 +0900 - - [ruby/racc] Embed racc/info.rb too - - https://github.com/ruby/racc/commit/b5e121f304 - -commit 2b54c135ff3ae2fb362a5efaa542ec9236116add - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-06-06 23:21:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-06 23:21:29 +0900 - - YJIT: Avoid identity-based known-class guards for IO objects (#7911) - - `IO#reopen` is very special in that it is able to change the class and - singleton class of IO instances. In its presence, it is not correct to - assume that IO instances has a stable class/singleton class and guard - by comparing identity. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 7577c101ed6452de3e72fadb43db595946acc701 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-06 23:19:20 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-06 23:19:20 +0900 - - Unify length field for embedded and heap strings (#7908) - - * Unify length field for embedded and heap strings - - The length field is of the same type and position in RString for both - embedded and heap allocated strings, so we can unify it. - - * Remove RSTRING_EMBED_LEN - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit fae2f80d06f5058b40e91f62ba27fb01f2463d12 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-05 23:54:47 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-06 23:18:50 +0900 - - Revert debugging code in test_gc_compact.rb - -commit c3dc9fcc70514d2d74985e48ee24f7799a66899a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-05 23:54:28 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-06 23:18:50 +0900 - - Fix heap growth in GC.verify_compaction_references - - We should grow by at least gc_params.heap_init_slots, but the previous - calculation was incorrect. - -commit 79e8d91410d85509b554b0885f5bde6899c4b2da - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2021-08-13 05:45:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-06 10:52:57 +0900 - - [rubygems/rubygems] Delay cache access in `LockfileParser` - - It's the only part that needs "root folder resultion" to figure out the - folder for the cache, but it's only needed for some things, so run that - logic lazily when needed. - - https://github.com/rubygems/rubygems/commit/c7b9eae0bc - -commit 03246719ccb2a9c042487b59b31bcac8c30bbff1 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-05-27 04:56:17 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-06 10:52:57 +0900 - - [rubygems/rubygems] Fix `path` vs `deployment` precedence when path set through ENV - - The `deployment` setting sets `path` to `vendor/bundle` implicitly, but - that should only apply if `path` is not set explicitly, at any level. - - https://github.com/rubygems/rubygems/commit/3552c064c1 - -commit 7b317243ad25f4366d8c947bcb94c11aa795018f - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-05-27 04:53:34 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-06 10:52:56 +0900 - - [rubygems/rubygems] Unexclude some specs on bundler 3 - - These should all be passing on Bundler 3. - - https://github.com/rubygems/rubygems/commit/4a8c172965 - -commit 6353f1d5e8db2645f87a4dac8d7003517f027a80 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-05-27 04:47:22 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-06 10:52:56 +0900 - - [rubygems/rubygems] Fill in missing deployment specs - - https://github.com/rubygems/rubygems/commit/e16aa47b8f - -commit 603772440c85e0934d171cc89da31a7b57f57012 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-05-27 04:34:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-06 10:52:55 +0900 - - [rubygems/rubygems] Remove redundant specs - - They are already tested above. - - https://github.com/rubygems/rubygems/commit/23073dcece - -commit 8819dc43238c1ce79e7b4528d1dee66c4616ee87 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-05-26 19:16:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-06 10:52:54 +0900 - - [rubygems/rubygems] Always rely on $LOAD_PATH when jumping from exe to lib - - Normally, we use `require_relative` when requiring internal code. - However, Bundler may also load external code (for example, bundler - plugins), and when that external code loads Bundler itself, using - `require_relative` without setting up the `$LOAD_PATH` may lead into - double load errors. - - For example, when testing a Gemfile using plugins using our source code - tree, I get the following: - - ``` - ➜ plugins-dup ~/Code/rubygems/rubygems/bundler/exe/bundle - Fetching gem metadata from https://rubygems.org/. - Resolving dependencies... - Using bundler 2.5.0.dev - Installing extended_bundler-errors 0.3.3 - /Users/deivid/.asdf/installs/ruby/3.2.2/lib/ruby/site_ruby/3.2.0/bundler/version.rb:4: warning: already initialized constant Bundler::VERSION - /Users/deivid/Code/rubygems/rubygems/bundler/lib/bundler/version.rb:4: warning: previous definition of VERSION was here - /Users/deivid/.asdf/installs/ruby/3.2.2/lib/ruby/site_ruby/3.2.0/bundler/worker.rb:5: warning: already initialized constant Bundler::Worker::POISON - /Users/deivid/Code/rubygems/rubygems/bundler/lib/bundler/worker.rb:5: warning: previous definition of POISON was here - /Users/deivid/.asdf/installs/ruby/3.2.2/lib/ruby/site_ruby/3.2.0/bundler/vendor/fileutils/lib/fileutils.rb:183: warning: already initialized constant Bundler::FileUtils::VERSION - /Users/deivid/Code/rubygems/rubygems/bundler/lib/bundler/vendor/fileutils/lib/fileutils.rb:183: warning: previous definition of VERSION was here - /Users/deivid/.asdf/installs/ruby/3.2.2/lib/ruby/site_ruby/3.2.0/bundler/vendor/fileutils/lib/fileutils.rb:2165: warning: already initialized constant Bundler::FileUtils::Entry_::S_IF_DOOR - /Users/deivid/Code/rubygems/rubygems/bundler/lib/bundler/vendor/fileutils/lib/fileutils.rb:2165: warning: previous definition of S_IF_DOOR was here - /Users/deivid/.asdf/installs/ruby/3.2.2/lib/ruby/site_ruby/3.2.0/bundler/vendor/fileutils/lib/fileutils.rb:2461: warning: already initialized constant Bundler::FileUtils::Entry_::DIRECTORY_TERM - /Users/deivid/Code/rubygems/rubygems/bundler/lib/bundler/vendor/fileutils/lib/fileutils.rb:2461: warning: previous definition of DIRECTORY_TERM was here - /Users/deivid/.asdf/installs/ruby/3.2.2/lib/ruby/site_ruby/3.2.0/bundler/vendor/fileutils/lib/fileutils.rb:2569: warning: already initialized constant Bundler::FileUtils::OPT_TABLE - /Users/deivid/Code/rubygems/rubygems/bundler/lib/bundler/vendor/fileutils/lib/fileutils.rb:2569: warning: previous definition of OPT_TABLE was here - /Users/deivid/.asdf/installs/ruby/3.2.2/lib/ruby/site_ruby/3.2.0/bundler/vendor/fileutils/lib/fileutils.rb:2627: warning: already initialized constant Bundler::FileUtils::LOW_METHODS - /Users/deivid/Code/rubygems/rubygems/bundler/lib/bundler/vendor/fileutils/lib/fileutils.rb:2627: warning: previous definition of LOW_METHODS was here - /Users/deivid/.asdf/installs/ruby/3.2.2/lib/ruby/site_ruby/3.2.0/bundler/vendor/fileutils/lib/fileutils.rb:2634: warning: already initialized constant Bundler::FileUtils::METHODS - /Users/deivid/Code/rubygems/rubygems/bundler/lib/bundler/vendor/fileutils/lib/fileutils.rb:2634: warning: previous definition of METHODS was here - Failed to install plugin `extended_bundler-errors`, due to Bundler::Plugin::MalformattedPlugin (ArgumentError: Trying to register Bundler::GemfileError for status code 4 but - Bundler::GemfileError is already registered) - ``` - - Changing this to always use `$LOAD_PATH` fixes the problem. - - https://github.com/rubygems/rubygems/commit/121a861c39 - -commit 1f9e66836b71dd77aaef660628eb2455b4f28a3b - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-05-25 20:39:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-06 10:52:53 +0900 - - [rubygems/rubygems] Fix inline mode with multiple sources - - If we're in inline mode, Bundler first resolves using only local gems, - and if some gems are missing, then it re-resolves using remote gems. - However, "source resolution" from the initial "local" try was being - memoized, resulting in Bundler not looking for some gems remotely in the - second resolution. - - This commit forces a proper re-resolve in this case. - - https://github.com/rubygems/rubygems/commit/fdc631075e - -commit ebe1077330b36bfa960fd94392e26fdfbaa93951 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-06-06 06:58:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-06 06:58:04 +0900 - - YJIT: Fix a warning on cargo test (#7909) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 2543a6573f8936806e7a8f5efd5a7a753cb9d564 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-05-30 00:38:15 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-06 04:47:16 +0900 - - Implement Struct on VWA - - The benchmark results show that this feature has either a positive or - no impact on performance. The memory usage is also mostly unchanged, - except in hexapdf, where there is a decrease in RSS. - - -------------- ----------- ---------- --------- ----------- ---------- --------- -------------- ------------- - bench master (ms) stddev (%) RSS (MiB) branch (ms) stddev (%) RSS (MiB) branch 1st itr master/branch - activerecord 70.8 2.2 56.0 71.7 2.2 56.0 0.99 0.99 - erubi_rails 20.5 13.6 94.7 20.5 14.3 94.2 0.93 1.00 - hexapdf 2541.0 0.7 212.8 2544.4 0.7 203.4 1.00 1.00 - liquid-c 65.6 0.3 38.9 65.3 0.3 38.9 1.01 1.01 - liquid-compile 63.7 0.3 34.6 61.1 0.2 34.6 1.04 1.04 - liquid-render 163.1 0.1 37.1 163.3 0.1 37.1 1.00 1.00 - mail 139.3 0.1 50.5 137.0 0.1 50.1 0.99 1.02 - psych-load 2065.7 0.1 36.9 2068.2 0.1 37.3 1.00 1.00 - railsbench 2034.6 0.5 103.9 2031.9 0.5 103.8 1.02 1.00 - ruby-lsp 65.3 3.1 89.8 66.2 3.0 89.7 1.01 0.99 - sequel 73.2 1.0 40.3 73.4 1.0 40.3 1.00 1.00 - -------------- ----------- ---------- --------- ----------- ---------- --------- -------------- ------------- - - Notes: - Merged: https://github.com/ruby/ruby/pull/7871 - -commit 45ff2f4a89f64b20be240b654380e70e31b64619 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-06-06 04:12:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-06 04:12:16 +0900 - - [ruby/irb] Refactor ExtendCommand::Nop - (https://github.com/ruby/irb/pull/598) - - * Rename conf to irb_context - - * Drop Nop#irb method because it's only used by irb/ext/loader.rb - - We don't need to expose this method to all command classes, especially - when it's just an alias of `irb_context.irb`. - -commit 273b38475eca91e0a749d2c7a01342157a67633a - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-06-06 04:02:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-06 04:02:43 +0900 - - [ruby/irb] Simplify irb_info command - (https://github.com/ruby/irb/pull/597) - - https://github.com/ruby/irb/commit/0a0409c52b - -commit 76ee4edb97da67d2ab6f289de14cd3ac334c372d - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-06-06 03:34:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-06 03:34:10 +0900 - - [ruby/irb] Fixed string escaping omissions - (https://github.com/ruby/irb/pull/599) - - I received a `RegexpError` when I typed `::Array[`. - ::Array[/Users/mi/ghq/github.com/ruby/irb/lib/irb/completion.rb:236:in `retrieve_completion_data': premature end of char-class: /^Array[/ (RegexpError) - -commit 135a5eb716399443da58db342de6093c91b5ad62 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-06-03 04:26:02 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-06-06 03:11:12 +0900 - - Add missing write barrier - - We were missing the write barrier for class_value to cref. This should - fix the segv we were seeing in http://ci.rvm.jp/logfiles/brlog.trunk-gc-asserts.20230601-165052 - - Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7900 - -commit 40f090f4339820d19da8ecdf81a981489c22eb57 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-06-03 03:25:19 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-06-06 03:11:12 +0900 - - Revert "Revert "Fix cvar caching when class is cloned"" - - This reverts commit 10621f7cb9a0c70e568f89cce47a02e878af6778. - - This was reverted because the gc integrity build started failing. We - have figured out a fix so I'm reopening the PR. - - Original commit message: - - Fix cvar caching when class is cloned - - The class variable cache that was added in - ruby#4544 changed the behavior of class - variables on cloned classes. As reported when a class is cloned AND a - class variable was set, and the class variable was read from the - original class, reading a class variable from the cloned class would - return the value from the original class. - - This was happening because the IC (inline cache) is stored on the ISEQ - which is shared between the original and cloned class, therefore they - share the cache too. - - To fix this we are now storing the `cref` in the cache so that we can - check if it's equal to the current `cref`. If it's different we don't - want to read from the cache. If it's the same we do. Cloned classes - don't share the same cref with their original class. - - This will need to be backported to 3.1 in addition to 3.2 since the bug - exists in both versions. - - We also added a marking function which was missing. - - Fixes [Bug #19379] - - Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7900 - -commit 29ea3c5aaa9513fcd497781e7051c0f436725eb3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-01 08:15:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-06 02:10:49 +0900 - - [rubygems/rubygems] Try again with https://github.com/rubygems/rubygems/pull/6693 - - https://github.com/rubygems/rubygems/commit/73c0d5f059 - -commit 3cdafe9be19c7d8b9351f68338b0b94bac9903ee - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-05 18:43:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-05 23:59:39 +0900 - - Move per sections in help message - - Notes: - Merged: https://github.com/ruby/ruby/pull/7906 - -commit b5467ae38a5170d85d19499f18ea351c479bc414 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-05 10:09:23 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-05 23:59:39 +0900 - - Add additional info for `-0` to `--help` message - - Notes: - Merged: https://github.com/ruby/ruby/pull/7906 - -commit feb946c3e2a8aac09ceda2aa7d5d605d6bcedf96 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-04 23:03:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-05 23:59:39 +0900 - - Fold option lines in help message - - Notes: - Merged: https://github.com/ruby/ruby/pull/7906 - -commit 1a7ee14578526a043b68b017f661c801d0d489ea - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-05 22:49:35 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-05 22:49:35 +0900 - - [DOC] Update flags doc for strings - - The length of an embedded string is no longer in the flags. - -commit 542c70aab748cf17960cc2a0959ba490983ceae6 - Author: Daniel Pepper <pepper.daniel@gmail.com> - AuthorDate: 2023-06-05 13:29:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-05 13:29:37 +0900 - - [ruby/singleton] Simplify implementation of `Singleton#instance`. - (https://github.com/ruby/singleton/pull/9) - - - Add more tests to cover rails' usage. - -commit 3fe0f8c68bf2cd861b7061de8a662885e5aa5234 - Author: Yla Aioi <43639533+Little-Rubyist@users.noreply.github.com> - AuthorDate: 2023-06-05 12:05:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-05 12:05:58 +0900 - - [Bug #19685]: Add `-y` and `--yydebug` document to `--help` - - Add -y option information to `--help` - Fix a warning on the man page - - Notes: - Merged: https://github.com/ruby/ruby/pull/7870 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 3a4302c742622dda9fbaeeb90fd42364badc423d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-05 10:09:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-05 10:10:26 +0900 - - [ruby/singleton] Revert "Simplify the implementation - (https://github.com/ruby/singleton/pull/7)" - - This reverts commit https://github.com/ruby/singleton/commit/545b6b61a40d. - - This change break Rails CI: https://bugs.ruby-lang.org/issues/19711 - - https://github.com/ruby/singleton/commit/911531d508 - -commit 4275a8098e59c43daa4a85efce9465af296f46c9 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-06-05 00:24:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-05 00:24:30 +0900 - - [ruby/irb] Bump version to 1.7.0 - (https://github.com/ruby/irb/pull/596) - - https://github.com/ruby/irb/commit/c2e7002867 - -commit 73a31546aa2ceaa4de1ae9d52b1b46993a3f2be6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-03 20:50:40 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-03 20:50:40 +0900 - - Attrset name is not allowed as an attribute - -commit 4589056384cdc8ed7c8a99713b216b7176ff49b9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-02 20:25:08 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-03 20:22:10 +0900 - - Exit with a failure if any test files failed to load - - Notes: - Merged: https://github.com/ruby/ruby/pull/7897 - -commit e6bd1852fb0c4775f6bc9588df30a141013ec788 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-06-03 17:27:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-03 17:28:02 +0900 - - [ruby/reline] Bump version to 0.3.5 - (https://github.com/ruby/reline/pull/548) - - https://github.com/ruby/reline/commit/4330a52572 - -commit 0402193723647b8c4f57b1453fe2192ad2788d12 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-06-03 12:41:36 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-03 12:41:36 +0900 - - Fix `Thread#join(timeout)` when running inside the fiber scheduler. (#7903) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit a4d92475f69f0ca3dba0f497253e600c7f90a0ad - Author: Vinicius Stock <stock@hey.com> - AuthorDate: 2023-06-03 07:56:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-03 10:42:29 +0900 - - [ruby/rdoc] Auto-correct trailing new lines - - https://github.com/ruby/rdoc/commit/4b68c0728a - -commit bebd05fb51ea65bc57344b67100748200f8311eb - Author: Daniel Pepper <pepper.daniel@gmail.com> - AuthorDate: 2023-06-03 09:35:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-03 09:35:18 +0900 - - [ruby/singleton] Simplify the implementation - (https://github.com/ruby/singleton/pull/7) - - Remove `__init__` and move logic to `included`. - -commit 4e26ae3cb93d6f22edef9d4fa1221e94b7abded2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-06-03 06:16:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-03 06:16:52 +0900 - - YJIT: Use #[cfg] instead of if cfg! (#7899) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 22bea37cfc739139ed53a6da06d52249e7b12961 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-06-02 17:18:37 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-06-02 23:11:45 +0900 - - Stabilize test_latest_gc_info_need_major_by - - Fix: - ``` - 1) Failure: - TestGc#test_latest_gc_info_need_major_by [/home/runner/work/ruby/ruby/src/test/ruby/test_gc.rb:266]: - <nil> expected to not be nil. - ``` - - `GC.stat(:major_gc_count)` can be bumped while `GC.latest_gc_info(:need_major_by)` is still nil. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7895 - -commit 83056817298d188937d157b54918e99b689fc12e - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-06-02 22:54:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-02 22:54:07 +0900 - - [ruby/irb] Require `test/lib` helpers from main test helper - (https://github.com/ruby/irb/pull/595) - - Because they are handled differently in `ruby/irb` and `ruby/ruby`. - -commit e38fb050fa585135d3f8f158e3c6ccc12cb1439c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-02 21:18:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-02 21:18:06 +0900 - - [ruby/reline] Remove unnecessary conditions for - `Fiddle::TYPE_VARIADIC` - (https://github.com/ruby/reline/pull/547) - - https://github.com/ruby/reline/commit/71ba3a9432 - -commit c32a30ec09997b3ee846a33a6873ed0e66c8dc94 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-02 17:20:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-02 17:20:38 +0900 - - [ruby/stringio] Development of 3.0.8 started. - - https://github.com/ruby/stringio/commit/1587d3698e - -commit 21b61b21c29d81204ad7d6135005126dd9b5dd7e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-02 10:34:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-02 16:58:55 +0900 - - Fix the case no file under bin directory - - NMake cannot handle empty expanded targets. - -commit 729b92ea469c35e4ddfeacccff1b46bd1ed657eb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-01 22:15:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-02 14:27:06 +0900 - - [ruby/uri] Drop support for 2.4 - - https://github.com/ruby/uri/commit/21baf2ba16 - -commit 3a4206c7a1025053601329fdf0d90113d72f77af - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-05-31 21:02:04 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-06-02 09:28:30 +0900 - - No need to define "BISON" on extconf.rb - - "BISON" is defined in "ext/ripper/depend". - - Notes: - Merged: https://github.com/ruby/ruby/pull/7878 - -commit 10621f7cb9a0c70e568f89cce47a02e878af6778 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-06-02 06:55:36 +0900 - Commit: Aaron Patterson <tenderlove@ruby-lang.org> - CommitDate: 2023-06-02 06:55:36 +0900 - - Revert "Fix cvar caching when class is cloned" - - This reverts commit 77d1b082470790c17c24a2f406b4fec5d522636b. - -commit 2d2893f206b1ff012ac68bddbeb860ca737b765f - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-06-02 05:10:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-02 05:10:13 +0900 - - [ruby/irb] Improve debug command tests - (https://github.com/ruby/irb/pull/594) - - * Use require_relative for envutil.rb - - Requiring test helper files with `require_relative` allows running the tests - with `ruby -Itest test/irb/test_debug_cmd.rb` without having to set up - the load path. - - * Replace reline hack with TERM=dumb - -commit 39968112f53fb1f905b924fed557132c6ead601c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-06-02 01:16:21 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-02 01:16:21 +0900 - - YJIT: Introduce RubyVM::YJIT.stats_string (#7857) - - * YJIT: Introduce RubyVM::YJIT.printed_stats - - * Use #string instead - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - - * Rename it to #stats_string - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - --------- - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 77d1b082470790c17c24a2f406b4fec5d522636b - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-02-08 05:46:50 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-06-02 00:52:48 +0900 - - Fix cvar caching when class is cloned - - The class variable cache that was added in - https://github.com/ruby/ruby/pull/4544 changed the behavior of class - variables on cloned classes. As reported when a class is cloned AND a - class variable was set, and the class variable was read from the - original class, reading a class variable from the cloned class would - return the value from the original class. - - This was happening because the IC (inline cache) is stored on the ISEQ - which is shared between the original and cloned class, therefore they - share the cache too. - - To fix this we are now storing the `cref` in the cache so that we can - check if it's equal to the current `cref`. If it's different we don't - want to read from the cache. If it's the same we do. Cloned classes - don't share the same cref with their original class. - - This will need to be backported to 3.1 in addition to 3.2 since the bug - exists in both versions. - - We also added a marking function which was missing. - - Fixes [Bug #19379] - - Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7265 - -commit b7ee51e81dd63990ec27daaa151864214cbf85d2 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-06-01 22:54:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-01 22:54:08 +0900 - - Expose `enum rb_io_event` flags without `_t` suffix. (#7887) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 47a8de609595def385cb8c716b80d7a64b718310 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-06-01 21:46:10 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-01 21:46:10 +0900 - - Drop `_t` suffix from struct names. (#7886) - - POSIX reserves `_t` suffix in types. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit a5e1d549b508806b2fd14100683f504c7825a138 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-06-01 13:33:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-06-01 21:44:53 +0900 - - [DOC] Mention the edge case of `any?`/`all?` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7883 - -commit a16cffe384ab167c22b4ae44c05950732cec2ae6 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-05-31 22:58:17 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-01 21:32:29 +0900 - - Simplify duplicated code - - The capacity of the string can be calculated using the str_capacity - function. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7879 - -commit 8a8618d4f3b35a5f114a3a5e05c80a7edb30546c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-05-31 22:57:33 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-01 21:32:29 +0900 - - Don't refetch ptr and len - - The call to RSTRING_GETMEM already fetched the pointer and length, so we - don't need to fetch it again. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7879 - -commit d5a5333168690ea1e3453cdb6a5d042f46ba80b8 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-06-01 20:41:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-06-01 20:41:19 +0900 - - [ruby/stringio] Avoid direct struct usage. - (https://github.com/ruby/stringio/pull/54) - - We will eventually want to refactor this, but for now this is compatible - enough. - -commit 957b6a491fe6a9a2df467f83a37e7c34861f995c - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-06-01 18:41:41 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-06-01 18:41:41 +0900 - - rb_io_descriptor() is available since 3.1 - -commit 64ec1813ac56799b3a61d97fe52e706415c0d8df - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-06-01 17:43:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-01 17:43:45 +0900 - - Restores the changes in `io-console` without breaking backwards compatibility. (#7882) - - This reverts commit 35da41b29bf0a1a8fd2cd7e1d7fcb036ca8c2c7c. - - This updates `io-console` to avoid accessing the internal details of `rb_io_t` - and instead use `rb_io_descriptor` and `rb_io_path` etc. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit edee9b6a12ac846d7b3de2d704e170bf28178cb3 - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-06-01 17:37:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-01 17:37:18 +0900 - - Use a real Ruby mutex in rb_io_close_wait_list (#7884) - - Because a thread calling IO#close now blocks in a native condvar wait, - it's possible for there to be _no_ threads left to actually handle - incoming signals/ubf calls/etc. - - This manifested as failing tests on Solaris 10 (SPARC), because: - - * One thread called IO#close, which sent a SIGVTALRM to the other - thread to interrupt it, and then waited on the condvar to be notified - that the reading thread was done. - * One thread was calling IO#read, but it hadn't yet reached the actual - call to select(2) when the SIGVTALRM arrived, so it never unblocked - itself. - - This results in a deadlock. - - The fix is to use a real Ruby mutex for the close lock; that way, the - closing thread goes into sigwait-sleep and can keep trying to interrupt - the select(2) thread. - - See the discussion in: https://github.com/ruby/ruby/pull/7865/ - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit d8f333491e4c26df7ca577f40d7708d5aedf764f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-01 13:49:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-01 14:46:52 +0900 - - [ruby/syntax_suggest] Use hard-coded filename for executables. - - It's hard to handle between ruby/syntax_suggest and ruby/ruby at gemspec. - - https://github.com/ruby/syntax_suggest/commit/0ee7496668 - -commit a218ed569243e7544d8c4e3b348245a17f6c6a51 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-06-01 14:23:30 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-06-01 14:23:30 +0900 - - Hide the usage of `rb_io_t` where possible. (#7880) - - This retries the compatible parts of the previously reverted PR so we can continue to update related code without breaking backwards compatibility. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 35da41b29bf0a1a8fd2cd7e1d7fcb036ca8c2c7c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-06-01 09:35:49 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-06-01 09:36:55 +0900 - - Revert https://github.com/ruby/io-console/pull/43 - - This reverts commit 1889133c04f337fec3969cb5040a544088249046 and - commit 764207e47ce38d1b73774a8e65114c87bc888298. - - Followed up with https://github.com/ruby/ruby/commit/85dcc4866d9ff29834596e9186cc97d622ee06f8 - -commit 85dcc4866d9ff29834596e9186cc97d622ee06f8 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2023-06-01 08:43:22 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2023-06-01 08:43:22 +0900 - - Revert "Hide most of the implementation of `struct rb_io`. (#6511)" - - This reverts commit 18e55fc1e1ec20e8f3166e3059e76c885fc9f8f2. - - fix [Bug #19704] - https://bugs.ruby-lang.org/issues/19704 - This breaks compatibility for extension libraries. Such changes - need a discussion. - -commit e4163112f6b99d9c205f6bc260878dcb00954a13 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-01 05:16:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-01 05:16:50 +0900 - - More debug code to GC compaction test - -commit e8212c55f9a00ef5722ab8c6c093d418d581bcd2 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-06-01 03:01:11 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-06-01 03:03:30 +0900 - - Fix flaky test in test_objspace.rb - - Ensure that the frozen string is promoted to the old generation by - running the GC 4 times. - -commit 55c9c658bd6db1b317dc71de6edfefc96ca10a83 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-06-01 01:11:18 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-06-01 01:11:18 +0900 - - ruby/spec no longer supports 2.7 since it is EOL - -commit 1ac17693de4e80f7b1e11622dd77376e409cd4ea - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-05-31 22:22:52 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-05-31 22:22:52 +0900 - - Add debug code to GC compaction test - - This test is flaky on some CI systems. - -commit e502600fb9094fe9413db54ce93b7328bec40b9f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-31 15:15:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-31 15:15:59 +0900 - - Assertion on message length for the `-h` option - -commit 3bc5f6b240c84582da8ed1d48481118607b3c07f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-31 12:16:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-31 13:55:30 +0900 - - [rubygems/rubygems] tool_dir needs to handle ruby/ruby repo now - - https://github.com/rubygems/rubygems/commit/550d90f4ba - -commit 1f74e25c3bb9398c2b47fde771e35293e2c29ad9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-05-31 00:20:02 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-31 00:20:02 +0900 - - YJIT: Force showing a backtrace on panic (#7869) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 4bbeed61346d6016e2d72818e8068bedcb9f006d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-30 20:25:29 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-30 21:50:07 +0900 - - Merge RubyGems/Bundler master from 4076391fce5847689bf2ec402b17133fe4e32285 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7873 - -commit 30b960ba345fd462f98db204f47bba66819d9884 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-05-30 21:21:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-30 21:39:26 +0900 - - [ruby/io-nonblock] Add TruffleRuby support and add it in CI - - * Do not use a C extension on TruffleRuby for these 3 methods. - - https://github.com/ruby/io-nonblock/commit/1b8e52abfa - -commit c7c8e4c96e1ccba86e8ff3232df76144084516b3 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-05-30 21:20:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-30 21:39:25 +0900 - - [ruby/io-nonblock] Use the correct pattern for the fallback of rb_io_descriptor() - - * See https://github.com/ruby/io-console/pull/43/commits/d1d9aef45ceb14365fdf0ebee3e5ea06f27da682 - - https://github.com/ruby/io-nonblock/commit/dadb42422b - -commit ec9364e50077e88a222c24306209be0d776e27f3 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-03-24 10:40:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-30 10:43:48 +0900 - - [ruby/racc] Remove ErrorSymbolValue reference - - I cannot find where this is defined. I'm guessing neither this - nor the else branch is ever hit. I only found out when testing - VM changes, which had a bug that exposed this. - - https://github.com/ruby/racc/commit/8983d0c134 - -commit 18e55fc1e1ec20e8f3166e3059e76c885fc9f8f2 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-30 10:02:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-30 10:02:40 +0900 - - Hide most of the implementation of `struct rb_io`. (#6511) - - * Add rb_io_path and rb_io_open_descriptor. - - * Use rb_io_open_descriptor to create PTY objects - - * Rename FMODE_PREP -> FMODE_EXTERNAL and expose it - - FMODE_PREP I believe refers to the concept of a "pre-prepared" file, but - FMODE_EXTERNAL is clearer about what the file descriptor represents and - aligns with language in the IO::Buffer module. - - * Ensure that rb_io_open_descriptor closes the FD if it fails - - If FMODE_EXTERNAL is not set, then it's guaranteed that Ruby will be - responsible for closing your file, eventually, if you pass it to - rb_io_open_descriptor, even if it raises an exception. - - * Rename IS_EXTERNAL_FD -> RUBY_IO_EXTERNAL_P - - * Expose `rb_io_closed_p`. - - * Add `rb_io_mode` to get IO mode. - - --------- - - Co-authored-by: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit f61bd3ca806dab1de8052f70bb72938b8ef64edc - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-05-29 20:53:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-30 04:33:38 +0900 - - [ruby/cgi] Add TruffleRuby support and add it in CI - - https://github.com/ruby/cgi/commit/1240fec9c9 - -commit 610038f3bf6eae50c0ad4f16af02d4c50a812e2a - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-05-30 04:26:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-30 04:31:55 +0900 - - [ruby/etc] Use the correct pattern for the fallback of rb_io_descriptor() - - * See https://github.com/ruby/io-console/pull/43/commits/d1d9aef45ceb14365fdf0ebee3e5ea06f27da682 - - https://github.com/ruby/etc/commit/5185685003 - -commit 99ce41564e8f64155b22d1e1df77fbe7f980133e - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-05-30 01:33:51 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-05-30 01:33:51 +0900 - - Refactor guards for Time.new spec - -commit b7a26dfa16228cdfeb7e635df1e4f711908c667c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-05-29 23:45:31 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-05-30 00:55:39 +0900 - - Unify error messages of rb_num2ulong and rb_num2ull - - The error messages were slightly different due, which causes different - behaviour on 32-bit and 64-bit systems. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7872 - -commit c48d496e8cfdf8243d2beb28623954003adaf7fc - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-05-29 22:27:57 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-05-29 22:27:57 +0900 - - Update to ruby/spec@c3677cf - -commit 98f500d0958d12b1909f4638abf33682d75f3fe6 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-29 22:01:58 +0900 - Commit: Samuel Williams <samuel.williams@oriontransfer.co.nz> - CommitDate: 2023-05-29 22:01:58 +0900 - - [ruby/openssl] Remove usage of IO internals. - -commit 764207e47ce38d1b73774a8e65114c87bc888298 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-29 21:37:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-29 21:37:49 +0900 - - [ruby/io-console] Remove trailing whitespace. - - https://github.com/ruby/io-console/commit/55f1586463 - -commit 1889133c04f337fec3969cb5040a544088249046 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-29 21:30:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-29 21:30:32 +0900 - - [ruby/io-console] Remove usage of IO internals. - (https://github.com/ruby/io-console/pull/43) - - https://github.com/ruby/io-console/commit/4b839a504f - - Co-authored-by: Benoit Daloze <eregontp@gmail.com> - -commit 57459b83a9a52ab921094a1562fe3056df9a437a - Author: Jun Aruga <junaruga@users.noreply.github.com> - AuthorDate: 2023-05-29 17:09:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-29 17:09:32 +0900 - - mkmf: Add the extra option `--with-verbose` to enable verbose mode. (#7863) - - This commit is to add an extra option to enable verbose mode (V=1) in the - generated `Makefile` at runtime of the Ruby to print compiler command lines by - the commands below when building native extensions. It's possible to enable the - verbose mode by setting the environment variable `MAKEFLAGS="V=1"`[1] - implemented in GNU make. However, I wanted to make a consistent user-interface - not depending on the specific make's implementation. - - ``` - $ ruby /path/to/extconf.rb -- --with-verbose - ``` - - You can also add the extra option via rake-compiler gem. - - ``` - $ rake compiler -- --with-verbose - ``` - - If the extra option is not given, the value of the - `RbConfig::CONFIG["MKMF_VERBOSE"]` enabled by the configure option below is - used. - - ``` - $ ./configure --enable-mkmf-verbose - ``` - - For the unit tests, updated the following files. - - * The `test/mkmf/test_configuration.rb` was created to test the cases with the - `configuration` method and this implementation. - * Updated the `TestMkmf#assert_separately` to set the extra - arguments in `test/mkmf/base.rb`. Updated tests using the `assert_separately`. - * Added tests for `MakeMakefile#with_config` in the `test/mkmf/test_config.rb`. - - [1] https://www.gnu.org/software/make/manual/html_node/Variables_002fRecursion.html - - Fixes [Bug #19695] - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - - Notes: - Merged-By: junaruga - -commit d5ef373b1194bac64784ae316d125d7a2cf1988a - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-05-28 18:20:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-28 18:20:18 +0900 - - [ruby/irb] Set maximum document dialog height by - preferred_dialog_height provided by Reline - (https://github.com/ruby/irb/pull/591) - - https://github.com/ruby/irb/commit/df6907aca9 - -commit 14abb799c93c8e5cb7ce36d829fb805f80397d4c - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-28 17:40:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-28 17:40:38 +0900 - - [ruby/io-nonblock] Remove usage of IO internals. - (https://github.com/ruby/io-nonblock/pull/11) - - https://github.com/ruby/io-nonblock/commit/caa2b94d19 - -commit 55393645a12435305bb88907a628bedab69606d4 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-28 17:01:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-28 17:01:50 +0900 - - [ruby/io-nonblock] Revert "Remove usage of IO internals." - - This reverts commit https://github.com/ruby/io-nonblock/commit/9772b6dcb63c. - - https://github.com/ruby/io-nonblock/commit/08cabf78e1 - -commit 26dd9c5f0f8d17151ef721b46f94af0e6b3f484a - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-28 16:49:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-28 16:49:33 +0900 - - [ruby/io-nonblock] Remove usage of IO internals. - - https://github.com/ruby/io-nonblock/commit/9772b6dcb6 - -commit 881757c03f28c30c02754ed367e3c5494f46e800 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-28 14:08:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-28 14:09:02 +0900 - - [ruby/io-wait] Remove usage of IO internals. - (https://github.com/ruby/io-wait/pull/25) - - https://github.com/ruby/io-wait/commit/e5854b46c7 - -commit 00d6674636839329f54cad6daf5e5ca16cc3911e - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-28 14:08:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-28 14:08:40 +0900 - - [ruby/etc] Remove usage of IO internals. - (https://github.com/ruby/etc/pull/26) - - https://github.com/ruby/etc/commit/ea15eceb13 - -commit cf0b9e0db04925fc7bb31366b4dc053beab0bd57 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-05-28 00:07:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-28 00:07:29 +0900 - - [ruby/reline] Fix scrolldown condition in dialog rendering - (https://github.com/ruby/reline/pull/541) - - https://github.com/ruby/reline/commit/ad6faada3f - -commit 5d137a7f77ce1b4ca3514565de41fe8a2cf611a4 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-05-27 23:48:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-27 23:48:50 +0900 - - [ruby/reline] Use appropriate dialog height and reduce screen pushup - problem - (https://github.com/ruby/reline/pull/542) - - * Provide preferred_dialog_height for dialog positioning - - * Fix rendering test - -commit bf1bc5362e5edb2321665e9ce7c5c4e2e7d9f5ef - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-27 18:48:47 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-27 18:48:47 +0900 - - Improve `read`/`write`/`pread`/`pwrite` consistency. (#7860) - - * Documentation consistency. - - * Improve consistency of `pread`/`pwrite` implementation when given length. - - * Remove HAVE_PREAD / HAVE_PWRITE - it is no longer optional. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit c37ebfe08fb43242687e58a68628ade8101973d7 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-05-27 02:34:26 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-05-27 02:34:26 +0900 - - Remove dead code in string.c - - The STR_DEC_LEN macro is not used. - -commit c6e4337a995288b6cdadd33de591edb1bb02b384 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-27 02:07:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-27 02:07:47 +0900 - - [DOC] No document under win32 - - Also .document was removed at 57bc4cfa283582f7c4c7013bb8a979e0baf3236c. - -commit 94e5ecbbdd9ea1610dd8aaa55a6f9aa3ddb15ab1 - Author: Masafumi Koba <473530+ybiquitous@users.noreply.github.com> - AuthorDate: 2023-05-26 22:52:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-27 01:26:46 +0900 - - [ruby/rdoc] Improve `<summary>` CSS on sidebar - - - Use a smaller font size for the toggle symbol. (Currently, it seems a little too large) - - Use the child combinator (`>`) to unify selectors. - - Use `margin-left` instead of whitespace within the `content` property. - - Use `::` instead of outdated `:` for the pseudo-element symbol. - (See https://developer.mozilla.org/en-US/docs/Web/CSS/::before) - - https://github.com/ruby/rdoc/commit/61ce0a7d75 - -commit 54b7ce0bff461aae5492afd6df421669cbf1a73a - Author: Masafumi Koba <473530+ybiquitous@users.noreply.github.com> - AuthorDate: 2023-05-27 00:21:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-27 01:24:57 +0900 - - [ruby/rdoc] Improve layout CSS - - - Use the `grid` property for the page layout. - - https://caniuse.com/css-grid - - Adjust the `<main>` margin. - - Make the sidebar responsive and resizable. - - https://caniuse.com/css-math-functions - - https://caniuse.com/css-resize - - Note all modern browsers support the new CSS properties and functions used by this change. - - https://github.com/ruby/rdoc/commit/2db5097c41 - -commit 4847b7ac28d744dcf6caedd71dc5a7be21d4187c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-05-26 22:24:23 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-05-26 22:24:23 +0900 - - T_HASH is no longer on transient heap - -commit d62ae18797b938eac4ede99199914c827674b388 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-05-26 22:20:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-26 22:20:18 +0900 - - [DOC] Link fix (#7862) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit d1628feaaf1bfa9ed8cbd0f4fd14a7cc802b3cc1 - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-05-26 11:10:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-26 14:51:23 +0900 - - Remvoe very high timeout on test_race_gets_and_close - - This test should be fixed and fast now because the closing thread sleeps - appropriately waiting for the file descriptor to be unused. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7865 - -commit 66871c5a06d723f8350935ced1e88d8cc929d809 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-05-21 21:29:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-26 14:51:23 +0900 - - Fix busy-loop when waiting for file descriptors to close - - When one thread is closing a file descriptor whilst another thread is - concurrently reading it, we need to wait for the reading thread to be - done with it to prevent a potential EBADF (or, worse, file descriptor - reuse). - - At the moment, that is done by keeping a list of threads still using the - file descriptor in io_close_fptr. It then continually calls - rb_thread_schedule() in fptr_finalize_flush until said list is empty. - - That busy-looping seems to behave rather poorly on some OS's, - particulary FreeBSD. It can cause the TestIO#test_race_gets_and_close - test to fail (even with its very long 200 second timeout) because the - closing thread starves out the using thread. - - To fix that, I introduce the concept of struct rb_io_close_wait_list; a - list of threads still using a file descriptor that we want to close. We - call `rb_notify_fd_close` to let the thread scheduler know we're closing - a FD, which fills the list with threads. Then, we call - rb_notify_fd_close_wait which will block the thread until all of the - still-using threads are done. - - This is implemented with a condition variable sleep, so no busy-looping - is required. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7865 - -commit 54a74c42033e42869e69e7dc9e67efa1faf225be - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-05-26 11:02:30 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-26 14:51:23 +0900 - - Move rb_thread_cond_struct definition into thread_native.h - - On Win32, currently, rb_nativethread_cond_t is an incomplete type - because it's a typedef for `struct rb_thread_cond_struct`. That means - you can't actually allocate a rb_nativethread_cond_t unless you also - include THREAD_IMPL_H (since its defined in thread_win32.h) - (alternatively, including vm_core.h also works). - - Move the definition of rb_thread_cond_struct into thread_native.h to - alleviate this. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7865 - -commit 8c4da473dec7f733254aad4816857536e85f93f3 - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2023-05-26 11:11:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-26 14:48:08 +0900 - - Remove excessive timeout on test_wait_exception for FreeBSD - - This should now be fixed by the previous commit. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7864 - -commit 8e1abef46951c56ea4c9d164d33be5858e1e758d - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-05-19 08:12:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-26 14:48:08 +0900 - - Fix a potential busy-loop in the thread scheduler (esp. on FreeBSD) - - This patch fixes a potential busy-loop in the thread scheduler. If there - are two threads, the main thread (where Ruby signal handlers must run) - and a sleeping thread, it is possible for the following sequence of - events to occur: - - * The sleeping thread is in native_sleep -> sigwait_sleep A signal - * arives, kicking this thread out of rb_sigwait_sleep The sleeping - * thread calls THREAD_BLOCKING_END and eventually - thread_sched_to_running_common - * the sleeping thread writes into the sigwait_fd pipe by calling - rb_thread_wakeup_timer_thread - * the sleeping thread re-loops around in native_sleep() because - the desired sleep time has not actually yet expired - * that calls rb_sigwait_sleep again the ppoll() in rb_sigwait_sleep - * immediately returns because - of the byte written into the sigwait_fd by - rb_thread_wakeup_timer_thread - * that wakes the thread up again and kicks the whole cycle off again. - - Such a loop can only be broken by the main thread waking up and handling - the signal, such that ubf_threads_empty() below becomes true again; - however this loop can actually keep things so busy (and cause so much - contention on the main thread's interrupt_lock) that the main thread - doesn't deal with the signal for many seconds. This seems particuarly - likely on FreeBSD 13. - - (the cycle can also be broken by the sleeping thread finally elapsing - its desired sleep time). - - The fix for _this_ loop is to only wakeup the timer thrad in - thread_sched_to_running_common if the current thread is not itself the - sigwait thread. - - An almost identical loop also happens in the same circumstances because - the call to check_signals_nogvl (through sigwait_timeout) in - rb_sigwait_sleep returns true if there is any pending signal for the - main thread to handle. That then causes rb_sigwait_sleep to skip over - sleeping entirely. - - This is unnescessary and counterproductive, I believe; if the main - thread needs to be woken up that is done inline in check_signals_nogvl - anyway. - - See https://bugs.ruby-lang.org/issues/19680 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7864 - -commit d83f32c34b1d0e4dd49dd1f0af1b665c022b2872 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2022-09-13 09:57:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-26 06:51:15 +0900 - - [rubygems/rubygems] Load plugin immediately - - We can install RubyGems plugin by "gem install XXX". The installed - plugin is used from the NEXT "gem ...". - - For example, "gem install gem-src kaminari" doesn't use gem-src plugin - for kaminari. "gem install gem-src && gem install kaminari" uses - gem-src plugin for kaminari. - - How about loading a plugin immediately when the plugin is installed? - If this proposal is implemented, "gem install gem-src kaminari" works - like "gem install gem-src && gem install kaminari". - - https://github.com/rubygems/rubygems/commit/4917d96f4c - -commit e87f6c899e55f4d9452ce4d75cf2a725ae736aff - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-05-18 22:20:56 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-05-25 21:56:22 +0900 - - Don't immediately promote children of old objects - - [Feature #19678] - - References from an old object to a write barrier protected young object - will not immediately promote the young object. Instead, the young object - will age just like any other object, meaning that it has to survive - three collections before being promoted to the old generation. - References from an old object to a write barrier unprotected object will - place the parent object in the remember set for marking during minor - collections. This allows the child object to be reclaimed in minor - collections at the cost of increased time for minor collections. - - On one of [Shopify's highest traffic Ruby apps, Storefront - Renderer](https://shopify.engineering/how-shopify-reduced-storefront-response-times-rewrite), - we saw significant improvements after deploying this feature in - production. We compare the GC time and response time of web workers that - have the original behaviour (non-experimental group) and this new - behaviour (experimental group). We see that with this feature we spend - significantly less time in the GC, 0.81x on average, 0.88x on p99, and - 0.45x on p99.9. - - This translates to improvements in average response time (0.96x) and p99 - response time (0.92x). - - Notes: - Merged: https://github.com/ruby/ruby/pull/7821 - -commit e5bce57e1d3ab6eb8c218355e9b31fe3f2a9b1cd - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-25 18:11:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-25 18:11:36 +0900 - - [ruby/nkf] Bump up nkf-0.1.3 - - https://github.com/ruby/nkf/commit/bc90e2ed39 - -commit 3026a2f4e9f1b68a4fab6d933110b60f78a6c86a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-25 18:11:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-25 18:11:35 +0900 - - [ruby/nkf] Added missing extension configuration - - https://github.com/ruby/nkf/commit/e627a39dff - -commit 5ade6be7773b4162cfa9b19168077270914dd662 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-25 16:09:29 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-25 16:09:29 +0900 - - Fixup 5bfb317a938 - -commit 5bfb317a938e461a9f99fe209765263cfe23b4d5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-25 15:58:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-25 16:08:44 +0900 - - [ruby/benchmark] Don't use version.rb - - https://github.com/ruby/benchmark/commit/6d51b10500 - -commit 8e2fac7b9c9e9f83b6a84133678b5a98e799b84c - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-05-25 15:59:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-25 15:59:46 +0900 - - Update bundled gems list at 2023-05-25 - -commit d1237bc3a43ed87d9a8c574cfbb7e0399ae0ee76 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-25 15:47:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-25 15:47:48 +0900 - - Move gemspec files to top of lib directory. - - They have version.rb files with same directory. - But version.rb have been removed at https://github.com/ruby/ruby/pull/3375 - There is no reason to locate under the library name of directory. - -commit 492e0025fd1221681beafe28f1947b4dd1aefd9a - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-25 11:17:49 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-25 11:17:49 +0900 - - Allow environment variable to control madvise advice. (#7855) - - Introduce experimental support for explicitly specifying the `advice` value provided to `madvise` when releasing the fiber stack. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 31b28b31fa5a0452cb9d5f7eee88eebfebe5b4d1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-24 15:20:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-25 01:44:17 +0900 - - [ruby/csv] Support RJIT (https://github.com/ruby/csv/pull/281) - - In Ruby 3.3, MJIT is replaced with RJIT. - - https://github.com/ruby/csv/commit/cc6b47a4a7 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7851 - -commit 38ef537ce058fd994b776ad82c735d9d3eaf6d29 - Author: Luke Gruber <luke.gru@gmail.com> - AuthorDate: 2023-04-04 06:31:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-25 01:44:17 +0900 - - [ruby/csv] test: rename Helper to CSVHelper - (https://github.com/ruby/csv/pull/278) - - Rename it so that in ruby/ruby, the generic name Helper is not used. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7851 - -commit e151a2ff8ecfb26172c8e9643b53b00276658a50 - Author: Yuki Tsujimoto <46666464+ytjmt@users.noreply.github.com> - AuthorDate: 2023-03-14 05:40:13 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-25 01:44:17 +0900 - - [ruby/csv] docs: fix example in Recipe: Capture Unconverted Fields - (https://github.com/ruby/csv/pull/276) - - I've fixed the example in `Recipe: Capture Unconverted Fields`. - - https://ruby.github.io/csv/doc/csv/recipes/parsing_rdoc.html#label-Recipe-3A+Capture+Unconverted+Fields - - `parsed` is wrong: header row is missing and the values should be - integers. - - ``` - $ ruby -v - ruby 3.2.1 (2023-02-08 revision https://github.com/ruby/csv/commit/31819e82c8) [x86_64-darwin21] - - $ cat unconverted_fields.rb - require "csv" - - source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" - parsed = CSV.parse(source, converters: :integer, unconverted_fields: true) - p parsed - parsed.each {|row| p row.unconverted_fields } - - $ ruby unconverted_fields.rb - [["Name", "Value"], ["foo", 0], ["bar", 1], ["baz", 2]] - ["Name", "Value"] - ["foo", "0"] - ["bar", "1"] - ["baz", "2"] - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7851 - -commit 88876f02c1050be989500090763203a36c70597b - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2022-09-08 06:19:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-25 01:44:17 +0900 - - [ruby/csv] All Enumerable based methods consume the same lines with other methods - - This may have a performance penalty. We should benchmark this. - - GitHub: fix https://github.com/ruby/csv/pull/260 - - Reported by Lhoussaine Ghallou. Thanks!!! - - https://github.com/ruby/csv/commit/acc05116c5 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7851 - -commit 73c56e06c429ca713d3b612437d2087314a1062f - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2022-09-03 22:01:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-25 01:44:17 +0900 - - [ruby/csv] CSV#read consumes the same lines with other methods like CSV#shift - - GitHub: fix https://github.com/ruby/csv/pull/258 - - Reported by Lhoussaine Ghallou. Thanks!!! - - https://github.com/ruby/csv/commit/71e6d24e28 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7851 - -commit a0709d0aae9609688f13e16bbae7ef84da78b24b - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2022-06-18 22:32:35 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-25 01:44:17 +0900 - - [ruby/csv] Remove no longer required refinements - (https://github.com/ruby/csv/pull/250) - - Since PR #159, the minimum Ruby version is 2.5.0, a version which no - longer requires refinements for String#delete_suffix?, String#match? and - Regexp#match?. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7851 - -commit 55a900d9cc598e0670107149d7bb87ad8e006239 - Author: Sampat Badhe <sampatbadhe@gmail.com> - AuthorDate: 2022-01-31 06:25:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-25 01:44:17 +0900 - - [ruby/csv] Fix typos (https://github.com/ruby/csv/pull/236) - - https://github.com/ruby/csv/commit/d5e401266f - - Notes: - Merged: https://github.com/ruby/ruby/pull/7851 - -commit 81c57ae7ac1e3f2e1ffc5d5800848e927d5628a6 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2020-10-29 10:12:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-25 01:44:17 +0900 - - [ruby/csv] Small RDoc changes for recipes - (https://github.com/ruby/csv/pull/190) - - https://github.com/ruby/csv/commit/2102c78384 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7851 - -commit 347afd39a367dd01e0e4eb2de1cf17364044bfb0 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2020-08-18 09:37:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-25 01:44:17 +0900 - - [ruby/csv] Enhanced RDoc for CSV::Table - (https://github.com/ruby/csv/pull/166) - - https://github.com/ruby/csv/commit/1d685aede3 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7851 - -commit a23ae56c4d24ade9438393fc47d6f2b730e3f7a8 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-04 02:43:31 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-05-25 01:11:48 +0900 - - Add REMEMBERED_WB_UNPROTECTED_OBJECTS_LIMIT_RATIO - - [Feature #19571] - - This commit adds the environment variable - `RUBY_GC_HEAP_REMEMBERED_WB_UNPROTECTED_OBJECTS_LIMIT_RATIO` which is - used to calculate the `remembered_wb_unprotected_objects_limit` using a - ratio of `old_objects`. This should improve performance by reducing - major GC because, in a major GC, we mark all of the old objects, so we - should have more uncollectible WB unprotected objects before starting a - major GC. The default has been set to 0.01 (1% of old objects). - - On one of [Shopify's highest traffic Ruby apps, Storefront Renderer](https://shopify.engineering/how-shopify-reduced-storefront-response-times-rewrite), - we saw significant improvements after deploying this patch in - production. In the graphs below, we have the `tuned` group which uses - `RUBY_GC_HEAP_REMEMBERED_WB_UNPROTECTED_OBJECTS_LIMIT_RATIO=0.01` (the - default value), and an `untuned` group, which turns this feature off - with `RUBY_GC_HEAP_REMEMBERED_WB_UNPROTECTED_OBJECTS_LIMIT_RATIO=0`. We - see that the tuned group spends significantly less time in GC, on - average 0.67x of the time compared to the untuned group and 0.49x for - p99. We see this improvement in GC time translate to improvements in - response times. The average response time is now 0.96x of the time - compared to the untuned group and 0.86x for p99. - - https://user-images.githubusercontent.com/15860699/229559078-e23e8ce4-5f1f-4a2f-b5ef-5769f92b8c70.png - - Notes: - Merged: https://github.com/ruby/ruby/pull/7577 - -commit 6d976eb5348098a346d82065621e37925acae8b8 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-24 22:45:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-24 22:45:34 +0900 - - Fix "runs a C function with the global lock unlocked and unlocks IO with the generic RUBY_UBF_IO" on Windows. (#7848) - - * Enable borked spec. - - * Ensure win32 wrappers are visible and used. - - * Reorganise `read`/`write`/`pipe` in `thread_spec.c`. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 85b4cd7cf80d4029f65fde3e574b31f4b0e538ea - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-05-24 22:14:46 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-24 22:14:46 +0900 - - gc.c: get rid of unused objspace parameters (#7853) - - Notes: - Merged-By: byroot <byroot@ruby-lang.org> - -commit 5f65e8c5d5b625462121e01cc15e88be5729b60c - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-05-24 17:24:41 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-05-24 20:54:48 +0900 - - Rename `rb_node_name` to the original name - - 98637d421dbe8bcf86cc2effae5e26bb96a6a4da changes the name of - the function. However this function is exported as global, - then change the name to origin one for keeping compatibility. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7852 - -commit 135a0d26a11cf0d0825e4f80e00e2b430555d831 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-24 10:17:35 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-24 10:17:35 +0900 - - Improvements to `IO::Buffer` `read`/`write`/`pread`/`pwrite`. (#7826) - - - Fix IO::Buffer `read`/`write` to use a minimum length. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 12dfd9d1c980d17d8a0ea10bccb9cd7eca21b568 - Author: Ufuk Kayserilioglu <ufuk.kayserilioglu@shopify.com> - AuthorDate: 2021-10-25 21:48:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-24 09:37:30 +0900 - - [flori/json] Call `super` in `included` hook - - The C extension defines an `included` hook for the - `JSON::Ext::Generator::GeneratorMethods::String` module but neglects to - call `super` in the hook. This can break the functionality of various - other code that rely on the fact that `included` on `Module` will always - be called. - - https://github.com/flori/json/commit/cd8bbe56a3 - -commit 28056a6d161417bd7b3aed8099f59f4ac164b351 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-24 09:15:20 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-24 09:15:20 +0900 - - Add support for pread/pwrite on windows. (#7827) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 9592bc703922933c4196748a0e7221a53ad50b9b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-05-24 03:11:54 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-05-24 04:27:56 +0900 - - Remove dead code in rb_hash_replace - - We now always copy the ST table, so we don't need to initialize the ST - table of hash when hash2 is empty. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7846 - -commit a86f798fc2e979ea83ec55744f906b2a816c8681 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-05-24 02:45:44 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-05-24 04:27:56 +0900 - - Fix crash when replacing ST hash with AR hash - - With VWA, AR hashes are much larger than ST hashes. Hash#replace - attempts to directly copy the contents of AR hashes into ST hashes so - there will be memory corruption caused by writing past the end of memory. - - This commit changes it so that if a ST hash is being replaced with an AR - hash it will insert each element into the ST hash. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7846 - -commit 061e01ee5088b491ab702a567eb0d5bed1c5d429 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-05-17 03:27:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-24 03:37:09 +0900 - - [rubygems/rubygems] Remove forward slash in key regardless if it contains __ - - https://github.com/rubygems/rubygems/commit/33a02eec00 - -commit e854b050cce82b209a33f761ee8e017df0900a8a - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-05-17 03:26:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-24 03:37:08 +0900 - - [rubygems/rubygems] Modify invalid key check to accept keys with colons - - https://github.com/rubygems/rubygems/commit/413033198b - - Co-authored-by: Eric Herscovich <eric.herscovich@shopify.com> - -commit 92d6c9a7b1c3f8462e91e9b7de04b0b2012d54b3 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-05-24 01:16:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-24 01:16:37 +0900 - - [ruby/irb] Allow `show_source` for private methods - (https://github.com/ruby/irb/pull/589) - - * Allow `show_source` for private methods - - Fix https://github.com/ruby/irb/pull/577 - - * Pend tests on TruffleRuby - - It seems `eval(..., __LINE__ + 1)` does not work. - Other similar tests are also pended on TruffleRuby, so I think it - is acceptable. - - * Use `private_method_defined?` instead of `defined?` - -commit 24a6609ccb21af186d1cb73258abddb82e28a9f2 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-05-24 00:11:05 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-05-24 00:11:23 +0900 - - Remove dead code in ar_copy - - new_tab can no longer ever be NULL so this is dead code. - -commit 31ac8efca8ecb574e1e7b7c32cce54cb1b97f19a - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2023-05-23 22:51:28 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-23 22:51:28 +0900 - - Hash.new: print a deprecation warning when receiving keyword arguments (#7828) - - [Feature #19236] - - In Ruby 3.3, `Hash.new` shall print a deprecation warning if keyword arguments - are passed instead of treating them as an implicit positional Hash. - - This will allow to safely introduce a `capacity` keyword argument in 3.4 - - Co-authored-by: Jean Boussier <byroot@ruby-lang.org> - - Notes: - Merged-By: byroot <byroot@ruby-lang.org> - -commit 98637d421dbe8bcf86cc2effae5e26bb96a6a4da - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-05-22 21:55:49 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-05-23 18:05:35 +0900 - - Move `ruby_node_name` to node.c and rename prefix of the function - - Notes: - Merged: https://github.com/ruby/ruby/pull/7844 - -commit a7d70321005d302d9b5aaa2b83569aa899a5aaa9 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-23 10:05:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-23 10:05:47 +0900 - - Manually merge syntax_suggest-1.1.0 - -commit c638ffa700b7a9a28ba29a5b88d934efaba0e575 - Author: schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-04-22 07:34:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-23 10:05:47 +0900 - - [ruby/syntax_suggest] Fix - https://github.com/ruby/syntax_suggest/pull/187 Handle if/else with - empty/comment - line - - Reported in #187 this code: - - ``` - class Foo - def foo - if cond? - foo - else - # comment - end - end - - # ... - - def bar - if @recv - end_is_missing_here - end - end - ``` - - Triggers an incorrect suggestion: - - ``` - Unmatched keyword, missing `end' ? - 1 class Foo - 2 def foo - > 3 if cond? - > 5 else - 8 end - 16 end - ``` - - Part of the issue is that while scanning we're using newlines to determine when to stop and pause. This is useful for determining logically smaller chunks to evaluate but in this case it causes us to pause before grabbing the "end" that is right below the newline. This problem is similar to https://github.com/ruby/syntax_suggest/pull/179. - - However in the case of expanding same indentation "neighbors" I want to always grab all empty values at the end of the scan. I don't want to do that when changing indentation levels as it affects scan results. - - There may be some way to normalize this behavior between the two, but the tests really don't like that change. - - To fix this issue for expanding against different indentation I needed a way to first try and grab any additional newlines with the ability to rollback that guess. In #192 I experimented with decoupling scanning from the AroundBlockScan logic. It also added the ability to take a snapshot of the current scanner and rollback to prior changes. - - With this ability in place now we: - - - Grab extra empties before looking at the above/below line for the matching keyword/end statement - - If there's a match, grab it - - If there's no match, discard the newlines we picked up in the evaluation - - That solves the issue. - - https://github.com/ruby/syntax_suggest/commit/513646b912 - -commit aaf815c626816ccca227cb1f8f2a9b58f18f677a - Author: schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-04-15 03:46:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-23 10:05:47 +0900 - - [ruby/syntax_suggest] Refactor Scanner logic out of AroundBlockScan introduce history - - AroundBlockScan started as a utility class that was meant to be used as a DSL for scanning and making new blocks. As logic got added to this class it became hard to reason about what exactly is being mutated when. I pulled the scanning logic out into it's own class which gives us a clean separation of concerns. This allowed me to remove a lot of accessors that aren't core to the logic provided by AroundBlockScan. - - In addition to this refactor the ScanHistory class can snapshot a scan. This allows us to be more aggressive with scans in the future as we can now snapshot and rollback if it didn't turn out the way we wanted. - - The change comes with a minor perf impact: - - before: 5.092678 0.104299 5.196977 ( 5.226494) - after: 5.128536 0.099871 5.228407 ( 5.249542) - - This represents a 0.996x change in speed (where 1x would be no change and 2x would be twice as fast). This is a 0.38% decrease in performance which is negligible. It's likely coming from the extra blocks being created while scanning. This is negligible and if the history feature works well we might be able to make better block decisions which is means fewer calls to ripper which is the biggest bottleneck. - - While this doesn't fix https://github.com/ruby/syntax_suggest/issues/187 it's a good intermediate step that will hopefully make working on that issue easier. - - https://github.com/ruby/syntax_suggest/commit/ad8487d8aa - -commit b8bf0a52723322e469e94a4cb96286fd48e754ab - Author: schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-05-04 03:48:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-23 10:05:47 +0900 - - [ruby/syntax_suggest] Fix warning message - - The env var DEBUG does not work to produce detailed output. It is SYNTAX_SUGGEST_DEBUG. It was changed as part of the dead_end to syntax_suggest migration for Ruby 3.2 - - https://github.com/ruby/syntax_suggest/commit/c41da7aab7 - -commit f890345c03dc48072167df4bce45bc506dba2a1d - Author: Charles Oliver Nutter <headius@headius.com> - AuthorDate: 2023-05-19 23:11:43 +0900 - Commit: Charles Oliver Nutter <headius@headius.com> - CommitDate: 2023-05-23 09:49:53 +0900 - - Ensure producer threads do not start running early - - This test caused issues occasionally on JRuby because it's - possible for a producer thread to run to completion before the - status checks begin. This results in Thread#status returning false - and the =~ call triggering a warning (3.1) or error (3.2) and - either emitting thousands of deprecation warnings or failing - outright. - - The patch here introduces a mutex that remains locked until all - producer threads are seen to have started. The lock is then - released and the test proceeds. This prevents any producers from - running to completion, which in turn prevents consumers running to - completion, avoiding the warnings or error calling =~ on false. - - This patch also modifies the status checks to to_s the thread - status, preventing any prematurely terminated threads from - triggering similar deprecation warnings or missing method errors - when =~ is called on nil. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7830 - -commit ed7c7657ae0065a5007b443d146590e6e6a9dcbe - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-05-22 20:41:59 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-05-23 08:21:34 +0900 - - Remove deleted function - - `rb_parser_warn_location` was deleted by 0eeed5bcc5530edb0af2af2ccff09d067c59e8f9. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7839 - -commit 3bd98e7a91f81210c613b27e4846806c7244127d - Author: Noah Gibbs <noah.gibbs@shopify.com> - AuthorDate: 2023-05-22 22:48:32 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-05-23 06:45:00 +0900 - - Add documentation for some stats counters, and generally about YJIT stats - - Notes: - Merged: https://github.com/ruby/ruby/pull/7840 - -commit b0a25c9cf8053c3e9a9a44a62cd54befde4ecdfc - Author: Jun Aruga <junaruga@users.noreply.github.com> - AuthorDate: 2023-05-22 21:53:05 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-22 21:53:05 +0900 - - Revert "Apply timeout-scale to test_thr_kill." (#7838) - - This reverts commit bbbec4b87c1e66909f5bee9acd3e460b8c1ad663. - Because the commit is a bug. The `apply_timeout_scale` to scale the timeout is - called 2 times in the process. - - The `test/ruby/test_thread_queue.rb#test_thr_kill` is calling - `EnvUtil.apply_timeout_scale`, and - calling `tool/lib/core_assertions.rb#assert_normal_exit`. - calling `tool/lib/envutil.rb#invoke_ruby` (`EnvUtil.invoke_ruby`) - calling the `apply_timeout_scale`. - - ``` - $ make test-all V=1 TESTS="-v test/ruby/test_thread_queue.rb -n TestThreadQueue#test_thr_kill --timeout-scale=2" - ``` - - Notes: - Merged-By: junaruga - -commit bd786e78969f9d4a8699376ceafe10934b6ad533 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-22 12:58:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-22 12:58:17 +0900 - - Fix mutation on shared strings. (#7837) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit bcb16eb1e5d279e28d1e57c781531a8dea98eb8f - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-22 12:27:20 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-22 12:27:20 +0900 - - Rename `data` -> `buffer` for better readability. (#7836) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit a5819b5b2510556de0719317662d96096ce4089a - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-05-22 11:27:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-22 11:27:34 +0900 - - Allow the match cache optimization for atomic groups (#7804) - - Notes: - Merged-By: makenowjust <make.just.on@gmail.com> - -commit 872249e209fdb7b7c890a93b0f93a74a62d21aec - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-22 08:49:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-22 08:49:33 +0900 - - Don't leak pipes. (#7820) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 7f7a8fa555c3f12996114d13dc6908ea4e73c5b3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-21 23:00:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-21 23:00:27 +0900 - - Put `rb_fork` back into process.c - - Now, calling `rb_fork` directly breaks the PID cache and the timer - thread, so must use `rb_fork_ruby` or similar instead. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7834 - -commit 08675889802be222ae01db7d0d54c7e1b45bffc5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-21 16:47:14 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-21 16:47:14 +0900 - - Use `rb_fork_ruby` for `--help` pager - - Instead of `rb_fork`, to update `current_fork_gen` which has been - introduced at 3563e1383fe4ce13168cd3b9f4d5222d69d00061. - - Otherwise, the forked process attempts to stop the timer thread, but - raises an exception because the thread is not alive in the child and - dies because already no tag is present at that time. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7833 - -commit 4f4bc13eb92539b9e988aa27be1c1d01bd2e0fe6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-21 16:44:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-21 16:44:10 +0900 - - Skip too-complex-shape test which is always flaky regardless JIT - -commit 64e156f20c9da2f7977c11bccbd492f66140437f - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-05-21 11:57:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-21 11:57:50 +0900 - - [ruby/irb] Fix typo (https://github.com/ruby/irb/pull/587) - - * Fix typo - - * s/braking/breaking/g - - Co-authored-by: Stan Lo <stan001212@gmail.com> - - --------- - - https://github.com/ruby/irb/commit/5f8e69f5f2 - - Co-authored-by: Stan Lo <stan001212@gmail.com> - -commit b3f355cfbef3bee159bc7d05bd2df1dd63ffddc0 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-05-21 05:40:46 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-05-21 05:40:46 +0900 - - Set rlimit_nproc to 64 instead of 128 on OpenBSD for spawn_too_long_path tests - - This significantly reduces testing time, and may allow the test to - pass before timeout in CI. - -commit 8d242a33af19672977dcdcb8d32e9ad547bc0141 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-20 14:00:14 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-20 21:43:30 +0900 - - `rb_bug` prints a newline after the message - -commit 87217f26f120611d009f1b178d3cc5eaf1b8b515 - Author: nekoyama32767 <60657593+nekoyama32767@users.noreply.github.com> - AuthorDate: 2023-05-20 19:40:27 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-20 19:40:27 +0900 - - [Feature #19643] Direct primitive compare sort for `Array#sort_by` - - In most of case `sort_by` works on primitive type. - Using `qsort_r` with function pointer is much slower than compare data directly. - - I implement an intro sort which compare primitive data directly for `sort_by`. - We can even afford an O(n) type check before primitive data sort. - It still go faster. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7805 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 8db13c179e475e99f6155eb85f196aebe04cc39a - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-05-20 18:31:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-20 18:31:43 +0900 - - [ruby/reline] Bump version to 0.3.4 - (https://github.com/ruby/reline/pull/538) - - https://github.com/ruby/reline/commit/1fb0753bc1 - -commit 41512cd1bff9ad06823e7dfd4bd024b9e82b3edb - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-05-20 12:27:45 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-05-20 16:42:39 +0900 - - Lrama v0.5.1 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7831 - -commit 9ce6c08cafc96f59a6cdf7436c1e708a8c6e4ce8 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-05-20 13:28:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-20 13:28:23 +0900 - - [ruby/irb] Add assertion for dynamic_prompt's assertion execution - (https://github.com/ruby/irb/pull/586) - - Because the assertions for `dynamic_prompt` lives inside a block given to - `RubyLex`, they could be skipped unnoticed if the setup is not correct. - - This commit adds a simple assertion to check if the block was actually - executed. - -commit 6d9875ccbf78ca354e63f05a4e37ab1e2c14a9ac - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-05-20 10:08:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-20 10:08:58 +0900 - - [ruby/irb] Fix dynamic_prompt test not executed, remove unnecessary - set_input - (https://github.com/ruby/irb/pull/585) - - https://github.com/ruby/irb/commit/b5f3efdcf0 - -commit e8c9f727e8a9f0fe9fb1a6d61a60b8c8b479a87b - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-05-19 22:48:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-19 22:48:08 +0900 - - [ruby/irb] Simplify each_top_level_statement - (https://github.com/ruby/irb/pull/576) - - * Simplify each_top_level_statement, reduce instance vars - - * Update lib/irb/ruby-lex.rb - - Co-authored-by: Stan Lo <stan001212@gmail.com> - - * Remove unused ltype from TestRubyLex#check_state response - - * Remove unnecessary const path of TerminateLineInput - - * Combine duplicated code state check into method - - --------- - - https://github.com/ruby/irb/commit/172453cec4 - - Co-authored-by: Stan Lo <stan001212@gmail.com> - -commit 875adad948d48d13539075fff526fa5ecb5eba18 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-05-19 12:55:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-05-19 12:56:15 +0900 - - The too-complex test isn't stablefor RJIT either - - https://github.com/ruby/ruby/actions/runs/5020231516 - -commit b70e3f44c1d86fed92a63832fbf69a0764675ebb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-05-19 11:32:39 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-05-19 11:33:19 +0900 - - Skip test_dump_too_complex_shape for YJIT for now - - It fails too often with YJIT: - - * https://github.com/ruby/ruby/actions/runs/5015976941/jobs/8992254690 - * https://github.com/ruby/ruby/actions/runs/5017310353/jobs/8995281395 - * https://github.com/ruby/ruby/actions/runs/5019625711/jobs/9000322487 - * https://github.com/ruby/ruby/actions/runs/5019883965/jobs/9000836915 - - ref: https://github.com/ruby/ruby/pull/7646 - -commit b54b388f2a03a2ce553f8c02648f113403deb245 - Author: Adam Daniels <adam@mediadrive.ca> - AuthorDate: 2023-05-19 10:33:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-19 10:33:32 +0900 - - [ruby/irb] Display mod key as `Option` on Darwin platforms - (https://github.com/ruby/irb/pull/584) - - Check RUBY_PLATFORM for `darwin` and modify the mod key from `Alt` to - `Option`. - -commit 74600917a8eeff90ba28b857030052c5a4687155 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-19 09:08:39 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-19 09:25:11 +0900 - - [ruby/openssl] Revert "Skip OpenSSL::TestHMAC#test_dup when running with RHEL9" - - This reverts commit https://github.com/ruby/openssl/commit/9493d4a3bb26. - - https://github.com/ruby/openssl/commit/b880a023dd - -commit b26ddfd72f6acd33c44b764bfe78318b720fe3c5 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-05-17 05:01:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-19 09:25:11 +0900 - - [ruby/openssl] Fix warnings about the OPENSSL_FIPS macro in OpenSSL 1.1. - - The commit <https://github.com/ruby/openssl/commit/c5b2bc1268bc> made the warnings below - in the case of OpenSSL 1.1 where the `OPENSSL_FIPS` macro is not defined. - - ``` - $ bundle install --standalone - - $ bundle exec rake compile -- \ - --with-openssl-dir=$HOME/.local/openssl-1.1.1t-debug \ - --with-cflags="-Wundef" - mkdir -p tmp/x86_64-linux/openssl/3.2.1 - cd tmp/x86_64-linux/openssl/3.2.1 - /usr/local/ruby-3.2.1/bin/ruby -I. -r.rake-compiler-siteconf.rb ../../../../ext/openssl/extconf.rb -- --with-openssl-dir=/home/jaruga/.local/openssl-1.1.1t-debug --with-cflags=-Wundef - ... - gcc -I. -I/usr/local/ruby-3.2.1/include/ruby-3.2.0/x86_64-linux -I/usr/local/ruby-3.2.1/include/ruby-3.2.0/ruby/backward -I/usr/local/ruby-3.2.1/include/ruby-3.2.0 -I../../../../ext/openssl -DRUBY_EXTCONF_H=\"extconf.h\" -I/home/jaruga/.local/openssl-1.1.1t-debug/include -fPIC -Wundef -o ossl.o -c ../../../../ext/openssl/ossl.c - ../../../../ext/openssl/ossl.c: In function ‘ossl_fips_mode_get’: - ../../../../ext/openssl/ossl.c:425:7: warning: "OPENSSL_FIPS" is not defined, evaluates to 0 [-Wundef] - 425 | #elif OPENSSL_FIPS - | ^~~~~~~~~~~~ - ../../../../ext/openssl/ossl.c: In function ‘ossl_fips_mode_set’: - ../../../../ext/openssl/ossl.c:460:7: warning: "OPENSSL_FIPS" is not defined, evaluates to 0 [-Wundef] - 460 | #elif OPENSSL_FIPS - | ^~~~~~~~~~~~ - ../../../../ext/openssl/ossl.c: In function ‘Init_openssl’: - ../../../../ext/openssl/ossl.c:1218:7: warning: "OPENSSL_FIPS" is not defined, evaluates to 0 [-Wundef] - 1218 | #elif OPENSSL_FIPS - | ^~~~~~~~~~~~ - ... - cp tmp/x86_64-linux/openssl/3.2.1/openssl.so tmp/x86_64-linux/stage/lib/openssl.so - ``` - - https://github.com/ruby/openssl/commit/b4228cbcd6 - -commit 678d41bc51fe31834eec0b653ba0e47de5420aa0 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-03-17 05:36:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-19 09:25:10 +0900 - - [ruby/openssl] Implement FIPS functions on OpenSSL 3. - - This commit is to implement the `OpenSSL::OPENSSL_FIPS`, `ossl_fips_mode_get` - and `ossl_fips_mode_set` to pass the test `test/openssl/test_fips.rb`. - - It seems that the `OPENSSL_FIPS` macro is not used on the FIPS mode case any - more, and some FIPS related APIs also were removed in OpenSSL 3. - - See the document <https://github.com/openssl/openssl/blob/master/doc/man7/migration_guide.pod#removed-fips_mode-and-fips_mode_set> - the section OPENSSL 3.0 > Main Changes from OpenSSL 1.1.1 > - Other notable deprecations and changes - Removed FIPS_mode() and FIPS_mode_set() . - - The `OpenSSL::OPENSSL_FIPS` returns always true in OpenSSL 3 because the used - functions `EVP_default_properties_enable_fips` and `EVP_default_properties_is_fips_enabled` - works with the OpenSSL installed without FIPS option. - - The `TEST_RUBY_OPENSSL_FIPS_ENABLED` is set on the FIPS mode case on the CI. - Because I want to test that the `OpenSSL.fips_mode` returns the `true` or - 'false' surely in the CI. You can test the FIPS mode case by setting - `TEST_RUBY_OPENSSL_FIPS_ENABLED` on local too. Right now I don't find a better - way to get the status of the FIPS mode enabled or disabled for this purpose. I - am afraid of the possibility that the FIPS test case is unintentionally skipped. - - I also replaced the ambiguous "returns" with "should return" in the tests. - - https://github.com/ruby/openssl/commit/c5b2bc1268 - -commit 741a3bd5a547324be0d267bd77c3f5f2415c8c60 - Author: Jun Aruga <jaruga@redhat.com> - AuthorDate: 2023-03-17 01:19:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-19 09:25:10 +0900 - - [ruby/openssl] CI: Add OpenSSL FIPS mode case. - - test/openssl/fixtures/ssl/openssl_fips.cnf.tmpl: - - I referred to the following document for the openssl config file for FIPS mode. - <https://www.openssl.org/docs/manmaster/man7/fips_module.html> - - Making all applications use the FIPS module by default - - It seems that the `.include` syntax only requires the absolute path. - So, the placeholder OPENSSL_DIR in the template file is replaced with the - actual OpenSSL directory. - - .github/workflows/test.yml: - - The `TEST_RUBY_OPENSSL_FIPS_ENABLED` environment variable is set - in the FIPS mode CI case. It can be used in the unit tests. - - https://github.com/ruby/openssl/commit/18b017218c - -commit 94a513b08f616e0289f2fb4688659143d85f56ad - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-05-19 09:05:39 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-19 09:05:39 +0900 - - YJIT: Enable debug symbols in dev_nodebug (#7822) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit cfb79973537e081da0ab1aa828883524716efe72 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-05-19 04:00:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-19 04:00:33 +0900 - - [ruby/irb] Refactor RubyLex's input/io methods - (https://github.com/ruby/irb/pull/583) - - 1. Make `RubyLex#set_input` simply assign the input block. This matches - the behavior of `RubyLex#set_prompt`. - 2. Merge `RubyLex#set_input`'s IO configuration logic with `#set_auto_indent` - into `#configure_io`. - -commit d74b32db9d1e0234b17e4645d270394f7b657f85 - Author: lukeg <luke.gru@gmail.com> - AuthorDate: 2023-04-04 03:46:43 +0900 - Commit: Aaron Patterson <tenderlove@ruby-lang.org> - CommitDate: 2023-05-19 01:17:24 +0900 - - change to test/objectspace, don't rely on Object's shape not being "too complex" - -commit 0c3f699268a9b3d41b5023425a419c8b5cf00dbb - Author: S-H-GAMELINKS <gamelinks007@gmail.com> - AuthorDate: 2023-05-15 17:22:01 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-05-19 01:05:43 +0900 - - Introduce gc_mark_table macro - - Notes: - Merged: https://github.com/ruby/ruby/pull/7813 - -commit 2df5a697e2726a11f0441b13fb5c73dd549837c8 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-18 23:33:42 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-18 23:33:42 +0900 - - Add Fiber#kill, similar to Thread#kill. (#7823) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit b695f58d52ec047e44434c16c998c4a67d3e5571 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-05-18 12:28:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-18 12:28:31 +0900 - - [ruby/irb] Print deprecation warning for `help` command - (https://github.com/ruby/irb/pull/567) - - * Give show_doc its own command class - - * Print deprecation warning for `help` command - -commit cea9c30fa549885e36471f1782359df2bdcf895a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-20 05:16:27 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-05-17 22:19:40 +0900 - - Move ar_hint to ar_table_struct - - This allows Hashes with ST tables to fit int he 80 byte size pool. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7742 - -commit 0938964ba1af3924cf969fb809fc3598892bc20d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-20 05:02:36 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-05-17 22:19:40 +0900 - - Implement Hash ST tables on VWA - - Notes: - Merged: https://github.com/ruby/ruby/pull/7742 - -commit 5199f2aaf9527c97e6ec371e19748d0c2ac7a70e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-20 04:59:25 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-05-17 22:19:40 +0900 - - Implement Hash AR tables on VWA - - Notes: - Merged: https://github.com/ruby/ruby/pull/7742 - -commit 264ba0f89a52c6d0d6425da0cdfb12bbd420c619 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-05-17 13:42:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-17 13:42:32 +0900 - - [ruby/irb] Fix Test timedout in test_debug_cmd - (https://github.com/ruby/irb/pull/582) - - * Suppress Reline::IOGate.cursor_pos writing escape sequence in test_debug_cmd - - * Force use Reline::GeneralIO as Reline::IOGate and remove RUBY_DEBUG_NO_RELINE option for debug test - -commit 4d1ca2e1f964b6d70de34656a7893c76bd3d669b - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-16 12:49:06 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-16 12:49:06 +0900 - - Ensure SIGCHLD always uses a signal handler. (#7819) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 8945143464de77ca43eba000f77c5d04a1cdabb8 - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2022-09-04 23:34:24 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-05-16 03:52:59 +0900 - - [wasm] Allocate asyncify buffer on heap to save stack usage - - Notes: - Merged: https://github.com/ruby/ruby/pull/7818 - -commit ab7bb38aca0d2b5c2b81142a8e67fbff0f1a4a8a - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-15 23:14:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-15 23:14:51 +0900 - - Remove explicit SIGCHLD handling. (#7816) - - * Remove unused SIGCHLD handling. - - * Remove unused `init_sigchld`. - - * Remove unnecessary `#define RUBY_SIGCHLD (0)`. - - * Remove unused `SIGCHLD_LOSSY`. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 3fe45a3123760ba911fd21b1cfd1a44ce6745b0d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-15 19:10:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-15 19:10:24 +0900 - - Process parse.y without temporary files - - Notes: - Merged: https://github.com/ruby/ruby/pull/7817 - -commit 41dccb6a7bebfa8c0e5c8f6e6331a41fa01f9169 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-05-15 19:01:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-15 19:01:07 +0900 - - Lrama v0.5.0 (#7814) - - Notes: - Merged-By: yui-knk <spiketeika@gmail.com> - -commit c7067ed13d6cbe7fd8ba25418d2881f40fc4cbab - Author: Kunshan Wang <wks1986@gmail.com> - AuthorDate: 2023-05-15 13:08:00 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-15 15:12:30 +0900 - - Use the rb_sys_fail_str macro in signal.c - - Let signal.c include "internal/error.h" explicitly to ensure that the - identifier rb_sys_fail_str in signal.c refers to the macro defined in - "internal/error.h" instead of the actual function. - - That macro reads errno before evaluating its argument. Without this - change, the rb_signo2signm(sig) expression in the "trap" function in - signal.c will overwrite the errno before the actual rb_sys_fail_str - function reads the errno. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7812 - -commit 8bd4d8867a0222a3c30a0c7ee1f69b06baa8e91a - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-05-15 13:37:28 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-15 13:37:28 +0900 - - Unskip the test skipped in #4173 (#7809) - - This test was skipped 12 years ago because it was flaky on FreeBSD and - OpenBSD. Since then, Ruby's SIGCHLD handling has been substantially - re-written (mostly by Eric Wong @normalperson in 44fc3d08). - - These tests now in fact pass reliably on Ruby master on FreeBSD 13.2 and - OpenBSD 7.3. I stress-tested the test_wait_and_sigchild test on my - laptop by running four copies of the test in a loop on a 8-core VM; both - by itself and also as part of the whole test_process.rb file. I did not - see any failures. - - Let's unskip the test and close [#4173] out. I'll keep an eye out on Ruby - CI for any flakes in this file on BSD after this gets merged, but if we - don't see any I'm going to assume 44fc3d08 or related changes around - that time accidently fixed this bug. - - It's also probably important to unskip this test so that if another - attempt at removing the special SIGCHLD handling is made (like was - reverted in https://github.com/ruby/ruby/pull/7517), we get signal if - that breaks on FreeBSD/OpenBSD. - - [Fixes #4173] - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 0b2613f44309bddae45562c9f3a14ed43e56959b - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-05-15 11:13:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-15 11:13:51 +0900 - - `rb_io_puts` should not write zero length strings. (#7806) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 91c004885fc75a93cadf0094fa86ec3bd0ec25f5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-14 22:16:15 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-14 22:16:15 +0900 - - [Bug #19025] Numbered parameter names are always local variables - - Notes: - Merged: https://github.com/ruby/ruby/pull/7810 - -commit bdaa491565e31e3615d5da61551e08c7868db272 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-14 09:28:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-14 15:38:48 +0900 - - Add user argument to some macros used by bison - - Notes: - Merged: https://github.com/ruby/ruby/pull/7807 - -commit 3150516aab92c63fc22cf73d588e4584a8753b76 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-14 09:13:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-14 15:38:48 +0900 - - Preprocess input parse.y from stdin - - Notes: - Merged: https://github.com/ruby/ruby/pull/7807 - -commit edca57e6e37032cb4583f8d731eb81db94e3992d - Author: Yuta Saito <kateinoigakukun@gmail.com> - AuthorDate: 2023-05-14 12:59:39 +0900 - Commit: Yuta Saito <kateinoigakukun@gmail.com> - CommitDate: 2023-05-14 14:17:30 +0900 - - [wasm] Fix `unreachable` error during printing setjmp trace message - - Notes: - Merged: https://github.com/ruby/ruby/pull/7808 - -commit b632566f7efa758ece6963dcc8b4f3674a39b8d1 - Author: S-H-GAMELINKS <gamelinks007@gmail.com> - AuthorDate: 2023-05-09 21:23:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-14 10:32:25 +0900 - - Introduce anddot_multiple_assignment_check function - - Notes: - Merged: https://github.com/ruby/ruby/pull/7794 - -commit cee6903763074ac711875b11e544e726e17f195f - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-05-13 15:59:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-13 15:59:15 +0900 - - Update bundled gems list at 2023-05-13 - -commit 38ef5f7b35cab5064c4ed48c24bbd7a5eeb6e918 - Author: S-H-GAMELINKS <gamelinks007@gmail.com> - AuthorDate: 2023-05-12 12:03:19 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-13 14:54:18 +0900 - - Introduce math_arc macro - - Notes: - Merged: https://github.com/ruby/ruby/pull/7799 - -commit 5f411b9b3e45a40df788f85156d4337206686deb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-13 09:53:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-13 11:21:33 +0900 - - [rubygems/rubygems] Bump up thor-1.2.2 - - https://github.com/rubygems/rubygems/commit/d9a003b4e7 - -commit 93dd13d97a62fa1af80926e89d0ad9fb4570d539 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-05-13 10:04:28 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-13 10:04:28 +0900 - - Remove warnings and errors in `regexec.c` with `ONIG_DEBUG_...` macros (#7803) - - Notes: - Merged-By: makenowjust <make.just.on@gmail.com> - -commit c803e92d6638c985d7ec96804ac4c83b816011bd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-12 10:57:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-12 18:36:02 +0900 - - Return `errno` as the result instead of the global variable - -commit 30d72056711dc80249a428a9dd5714254d7e3119 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-12 10:49:25 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-12 18:36:02 +0900 - - Add `rb_sys_fail_sprintf` macro - -commit e3385f87831f036eaba96558cb4d83c8d5c43901 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-12 10:48:35 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-12 18:36:01 +0900 - - [Bug #19635] Preserve `errno` - - The following functions are turned into macros and no longer can be - used as expressions in core. - - rb_sys_fail - - rb_sys_fail_str - - rb_sys_fail_path - -commit a1b01e7701f9fc370f8dff777aad6d39a2c5a3e3 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-05-12 18:25:10 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-12 18:25:10 +0900 - - Use Lrama LALR parser generator instead of Bison - - https://bugs.ruby-lang.org/issues/19637 - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7798 - - Merged-By: yui-knk <spiketeika@gmail.com> - -commit d314fe42f987fcfaad67f102ec418ee4ca32ee99 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2023-05-12 17:15:13 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2023-05-12 17:15:13 +0900 - - Revert "Don't call action-slack if SLACK_WEBHOOK_URL is not set" - - This reverts commit 223a79e6830ca9c3619258ac00eebffb7754a0a1. - -commit 27a21ad201b04f9af6c206836b4c7543fb69a1e7 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-05-12 15:10:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-12 16:22:42 +0900 - - give up checking old compilers - - These old compilers needed old OSes, which are getting EODed. We - cannot maintain healthy binary of them (building compilers on our - own is quite haed). Let us just retire them. Fixes [Bug #19353] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7802 - -commit 223a79e6830ca9c3619258ac00eebffb7754a0a1 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2023-05-12 15:40:10 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2023-05-12 15:40:10 +0900 - - Don't call action-slack if SLACK_WEBHOOK_URL is not set - - For a PR, SLACK_WEBHOOK_URL is not set - -commit b742fb029d7d24f032c606cb72065b698db1aed6 - Author: Janosch Müller <janosch84@gmail.com> - AuthorDate: 2023-04-14 03:43:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-12 14:15:47 +0900 - - [DOC] Update how to run tool/enc-unicode.rb - -commit a19fa9b2bd94097e973fbdca48722c80b4d9b19f - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-05-10 23:49:44 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-05-10 23:49:44 +0900 - - Prevent warning: assigned but unused variable - - http://rubyci.s3.amazonaws.com/debian10/ruby-master/log/20230510T123003Z.log.html.gz - ``` - /home/chkbuild/chkbuild/tmp/build/20230510T123003Z/ruby/test/objspace/test_objspace.rb:224: warning: assigned but unused variable - c4 - /home/chkbuild/chkbuild/tmp/build/20230510T123003Z/ruby/test/ruby/test_class.rb:362: warning: assigned but unused variable - e - /home/chkbuild/chkbuild/tmp/build/20230510T123003Z/ruby/test/ruby/test_process.rb:2602: warning: assigned but unused variable - parent_pid - ``` - -commit 2d9bc3efe57fe0ec1a8171340c950fb98ca8c8f2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-13 21:45:56 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-10 17:14:20 +0900 - - [Bug #19597] Freeze script name - - Notes: - Merged: https://github.com/ruby/ruby/pull/7709 - -commit 0e5aecea11d6d214bf578edfbbdb126ceb4762cb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-10 15:47:39 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-10 15:47:39 +0900 - - [DOC] Move docs of `Array#first` and `Array#last` to array.rb - -commit 8866e082072f1d745fd6f5d94f19585dc3b62c2b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-10 15:03:58 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-10 15:03:58 +0900 - - Removed sync task for ext/readline - -commit 0ef6e718d9774484cd66cad5447d61ee985d8680 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-10 15:02:29 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-10 15:02:29 +0900 - - Merge https://github.com/rubygems/rubygems/pull/6655 manually. - -commit 9ed189e9aa4e1b1852b18ad01def9c738238299b - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-04-29 04:29:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-10 14:58:55 +0900 - - Update SPDX license list - -commit 71dc88df38f7bb7049aebf9c45e29fb808022541 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-10 09:56:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-10 09:56:54 +0900 - - Added entry about ext/readline - -commit 172077232e7f40b4dfedf6a5434c252b3d326fab - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-10 09:55:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-10 09:55:27 +0900 - - readline or libedit is no longer required to build ruby - -commit aec4e2d6787205b489af51e7acdba3be53980f07 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-10 09:53:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-10 09:53:02 +0900 - - Removed duplicated entry of readline.rb - -commit 507801c6d782d5708aabdccdb6799768beacffc4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-10 09:52:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-10 09:52:33 +0900 - - ext/readline is retired - -commit e1c84e8ee6a3a7d50ba726c18ea99395aa0bf4ce - Author: Noah Gibbs <noah.gibbs@shopify.com> - AuthorDate: 2023-05-10 04:40:26 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-10 04:40:26 +0900 - - For YJIT stats, set avg_len_in_yjit to 0 if denominator would be 0 (#7793) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 6404a0f2f822aaa698a3601937eae90beba56228 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-05-09 11:18:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-09 12:57:36 +0900 - - Fix broken link to maintainers page - - Notes: - Merged: https://github.com/ruby/ruby/pull/7792 - -commit 9d6bfe3815118e7734515d29f9f51c56176269e5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-09 12:10:34 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-09 12:57:12 +0900 - - Use debug-1.8.0 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7781 - -commit 59646e87983ff7ab04a8eccd92e789d77f4402ed - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-09 11:08:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-09 12:57:12 +0900 - - Allow to use development version of bundled gems for packaging - - Notes: - Merged: https://github.com/ruby/ruby/pull/7781 - -commit bb75e83d9f22c10b8893f3ff20fdd1d8d1825caf - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-09 10:23:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-09 12:57:12 +0900 - - We should not validate development version of bundled gems with fetch timing. - - We want to notify above situation when release time. So, I move this check into ruby/actions. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7781 - -commit 7397642021e26658987e4f7860c8ee2e04ff7fc8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-09 09:24:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-09 12:57:12 +0900 - - Use HEAD version of ruby/debug for testing - - Notes: - Merged: https://github.com/ruby/ruby/pull/7781 - -commit 9d3ab15827840bb10ffebc409df772b980e52ac5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-02 15:32:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-09 12:57:12 +0900 - - Relax regexp for console assertion - - Notes: - Merged: https://github.com/ruby/ruby/pull/7781 - -commit 59fd67fc3d405e529e038172e769ff20a8fb5535 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-02 09:08:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-09 12:57:12 +0900 - - Extract ext/readline - - Notes: - Merged: https://github.com/ruby/ruby/pull/7781 - -commit 5831f7c83177d6214aee1165df694bb4d4ae8ec6 - Author: Takumasa Ochi <aeroastro007@gmail.com> - AuthorDate: 2023-05-08 13:51:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-08 17:56:22 +0900 - - [rubygems/rubygems] Simplify code by Gem::Specification#runtime_dependencies - - https://github.com/rubygems/rubygems/commit/324139af8f - -commit 6987ec45b18924e9dcbf1439fe92a2ab7c7fc8bd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-08 16:21:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-08 16:21:21 +0900 - - [ruby/stringio] Drop support for ruby 2.6 or earlier - (https://github.com/ruby/stringio/pull/47) - - `rb_io_extract_modeenc` has been exported since ruby 2.7. - -commit fb23fba082cc5f2f422e1ede0e8081ffbda19501 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-05-08 11:28:56 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-05-08 12:23:39 +0900 - - add CI matrix for clang 17 / GCC 13 - - - https://github.com/llvm/llvm-project/commit/603c286334b07f568d39f6706c848f576914f323 - - https://github.com/gcc-mirror/gcc/commit/cc035c5d8672f87dc8c2756d9f8367903aa72d93 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7790 - -commit 5eca327fc50bebb06c6af103d109a1fef0895605 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-05-07 22:18:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-07 22:18:13 +0900 - - [ruby/reline] Fix dialog corrupts rendering by pushing up input line - too much - (https://github.com/ruby/reline/pull/524) - - * Do not render dialog where it overflows screen - - * Dialog rendering should Scroll down only when needed - - * Refactor screen_y_range calculation - - Co-authored-by: Stan Lo <stan001212@gmail.com> - - --------- - - https://github.com/ruby/reline/commit/bc0e3d1310 - - Co-authored-by: Stan Lo <stan001212@gmail.com> - -commit 8b2884c0b51e4733c09ecbb388ca1b236bad738b - Author: zzak <zzakscott@gmail.com> - AuthorDate: 2023-03-04 22:24:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-06 16:39:24 +0900 - - [ruby/rdoc] Isolate root dir if specified - - This ensures only files from the root directory are chosen, in order to allow a clean build from outside the source directory. - - https://github.com/ruby/rdoc/commit/f3b389aa9e - -commit 40438fc4d35738cad32d2bb7a0426ee2b1e32ade - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-05 22:52:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-05 23:01:50 +0900 - - [ruby/rdoc] Drop the support for 2.5 or earlier because of CVE-2021-31799 - - https://github.com/ruby/rdoc/commit/26136138aa - -commit da75560b6c3339c479b9554dd3edb3a691f31682 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-05 18:45:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-05 18:52:37 +0900 - - Continue checking all gemspec files after errors - -commit cfa6a892d05c5dcbd8fcd7c78cdbac49a8ff6100 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-05 18:32:13 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-05 18:52:36 +0900 - - Redirect to `IO::NULL` for the portability - -commit cc4c28d0cedc65cf1ffa62ef30579d17eb41758b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-04 22:56:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-05 09:46:11 +0900 - - [ruby/uri] Define test cases as qualified class names - - https://github.com/ruby/uri/commit/aaa22a2443 - -commit c598bc4603ad0cf1c788bf21aea2c1bd3a29f226 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-04 22:46:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-05 09:46:10 +0900 - - [ruby/uri] Increase repeat orders of magnitude - - https://github.com/ruby/uri/commit/cfbeade935 - -commit caa2180be0cf8499f83df6cce12511c1918abad2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-04 01:34:35 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-04 18:05:24 +0900 - - test_default_gems.rb: Stop using `git ls-files` - - Just validate syntax and the result class instead. - - Not only `git ls-files` doesn't make sence under ruby's repository, - some gemspec files hardcode `2>/dev/null`, which doesn't work of - course on other than Unix-like platforms. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7786 - -commit 2f9f44f077a53b14aa1fbd43111955251750d31f - Author: Ian Ker-Seymer <i.kerseymer@gmail.com> - AuthorDate: 2023-05-04 15:48:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-04 15:48:34 +0900 - - Ensure the VM is alive before accessing objspace in C API (Feature #19627) - - [Feature #19627] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7783 - - Merged-By: byroot <byroot@ruby-lang.org> - -commit e135a21a85f658cea380df47dca16f5e90c971cf - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-04 13:41:30 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-04 13:41:30 +0900 - - Define `RubyVM::Shape` dependent test only if available - -commit ac730d3e759207fd0ea7289815985ee867689b9c - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-05-04 13:15:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-04 13:15:51 +0900 - - Delay start of the match cache optimization (#7738) - - Notes: - Merged-By: makenowjust <make.just.on@gmail.com> - -commit 18b27185c37378c65fee12091c5ff90d5be2ec97 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-04 12:32:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-04 12:32:43 +0900 - - [DOC] regexp absent operator - - Notes: - Merged: https://github.com/ruby/ruby/pull/7785 - -commit 04ee666aab071cb6fd9a8b356b22d73250ca6b9b - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-04-18 19:36:57 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-05-03 17:43:46 +0900 - - Make the maximum shapes variation warning non-verbose - - [Feature #19538] - - Since that category is not enabled by default, making it a - verbose warning is redundant. Enabling performance warning should - work with the default verbosity level. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7733 - -commit 409a13e9ea018bbfa9dfc71c3427eff2dc4c4bd2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-03 14:19:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-03 14:38:27 +0900 - - [ruby/stringio] Update write-barrier at copying - - http://ci.rvm.jp/results/trunk-asserts@ruby-sp2-docker/4552803 - - ``` - verify_internal_consistency_reachable_i: WB miss (O->Y) 0x00007f752ddd5550 [3LM ] strio (StringIO)strio -> 0x00007f752d19b7d0 [0 ] T_STRING (String) len: 8, capa: 15 "to_strio" - <internal:/tmp/ruby/src/trunk-asserts/lib/rubygems/core_ext/kernel_require.rb>:53: [BUG] gc_verify_internal_consistency: found internal inconsistency. - ``` - - https://github.com/ruby/stringio/commit/2e8ab43cba - -commit 32cc6301b375583c0aa7d8fea480628131e6a2aa - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-02 15:52:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-03 02:06:36 +0900 - - [ruby/rdoc] [DOC] stop documenting fallback `MatchData#match_length` - - Also empty document of `Object`. - - https://github.com/ruby/rdoc/commit/ce32a3102b - -commit 5dfeffc614b62e42496b8e67dbc4ff08f7ea137c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-02 22:40:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-02 22:40:43 +0900 - - Allow EPIPE when the child process has exited before interrupt - -commit b15e88e0fcccb03b9cc5e4c1478ec9b10e26c961 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-01 10:34:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-02 17:39:18 +0900 - - [Bug #19619] Preserve numbered parameters context - - Preserve numbered parameters context across method definitions - -commit e47aa27dc799213066732fc7e34f2eeaf059b001 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-02 14:09:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-02 14:42:37 +0900 - - [ruby/rdoc] Section may not have `label` - - https://github.com/ruby/rdoc/commit/945f0cb3e9 - -commit 3833d0fee6e7c8747a153d0f3e31405b16ae57e3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-02 13:10:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-02 13:19:46 +0900 - - [ruby/rdoc] Fix references to nested label in table_of_contents - - Fixes https://github.com/ruby/rdoc/pull/1000 - - https://github.com/ruby/rdoc/commit/291e2b7e8b - -commit bd532fe3aefaa2e2d67bb344504c95405b5bf11a - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-05-02 06:01:06 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-02 06:01:06 +0900 - - YJIT: Move exits in gen_send_iseq to functions and use ? (#7725) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 13dfbcf7bf988922ed33e68456749b7179ab14bb - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-05-01 21:20:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-05-01 21:20:20 +0900 - - [ruby/reline] Rewrite dialog rendering - (https://github.com/ruby/reline/pull/492) - - * Rewrite dialog rendering - - * Fix failing test of dialog with small screen - - * Add multiple-dialog rendering test - - * Add description comments for each part of render_dialog_changes - -commit dd5ba1b725036d59ae473f5679057762cea54515 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-30 12:28:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-01 17:40:02 +0900 - - Update generate_spdx_license_list.rb - - - Follow up RegexpLiteral at 9264d834215aa7ce14b0273032a7686c20141db9. - - Split the code to be generated so that `REGEXP` does not need - escapes. - - Use `REGEXP.match?` since support for Ruby 2.3 or earlier has been - dropped. - -commit 90baadb904d7b952b7e596be8c1f9a50ef729b3a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-05-01 17:38:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-05-01 17:38:49 +0900 - - Ignore to sync used_cassettes.txt - -commit 33833aaf03bf6ec2bab66b68a6b1bfa6f57ae0ed - Author: Piotr Szotkowski <chastell@chastell.net> - AuthorDate: 2023-05-01 08:09:14 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-05-01 08:09:14 +0900 - - [DOC] hash.c: fix typo in `#<=>` docs - - Notes: - Merged: https://github.com/ruby/ruby/pull/7771 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 814f52a9ebd035ec6e20641c602fa42f64b5dbe0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-05-01 01:13:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-05-01 05:10:34 +0900 - - [Bug #19624] Hide internal IO for backquote - - Notes: - Merged: https://github.com/ruby/ruby/pull/7776 - -commit b82c06a711cbd1f812251a15c1e864027abe8c37 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-30 23:21:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-30 23:21:59 +0900 - - Handle private AREF call in compile.c - - Notes: - Merged: https://github.com/ruby/ruby/pull/7775 - -commit c2871161b453b37b444a759ebec6260c2c0fd0a4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-30 00:54:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-30 01:55:37 +0900 - - [ruby/rdoc] Fix polynominal backtracking - - Fix https://github.com/ruby/rdoc/pull/995 - - https://github.com/ruby/rdoc/commit/1311ca8c50 - -commit 85a9fd1902e2eba7910aa7490a8f09560dff451f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-28 23:46:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-30 01:55:36 +0900 - - [ruby/rdoc] Fix polynominal backtracking - - Fix https://github.com/ruby/rdoc/pull/995 - - https://github.com/ruby/rdoc/commit/adfa7db5b9 - -commit d23964360335ad561f252cb6fe8e90df7ebee90e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-29 02:09:55 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-29 11:28:26 +0900 - - core_assertions.rb: Support old rubies - - Some symbol argument might not be accepted by Process.clock_gettime. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7773 - -commit ecd42cfe39c13636defd4138cdbe92c709978812 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-29 10:40:39 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-29 10:40:39 +0900 - - Skip added tool files - - Get rid of accidents like 966f0d91e2a86fa1347cdafbe1af47e7350aa4ca. - -commit 8189a1400ebb0d9464203a6f70957254edc45faf - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-29 08:44:52 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-29 08:44:52 +0900 - - Revert "[ruby/rdoc] Update test libraries from ruby/ruby 2023-04-29" - - This reverts commit 966f0d91e2a86fa1347cdafbe1af47e7350aa4ca. - -commit e9930b51b205bd4e577b3787e8d8e7db8eebc237 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-29 02:20:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-29 02:20:20 +0900 - - [ruby/irb] Retire magic-file.rb - (https://github.com/ruby/irb/pull/574) - - `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: 3ee79e89 - - But now we expect files to be encoded in UTF-8 and don't specify encoding - through magic comments anymore, `MagicFile` can be retired. - -commit 966f0d91e2a86fa1347cdafbe1af47e7350aa4ca - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-29 00:48:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-29 01:09:20 +0900 - - [ruby/rdoc] Update test libraries from ruby/ruby 2023-04-29 - - From https://github.com/ruby/ruby/commit/74028c210c23a13b3168886efcf837b4bf930468 - - https://github.com/ruby/rdoc/commit/badc518c57 - -commit 7ba37cb7aad715b2927a6fdad89185df92ca8f23 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-28 20:26:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-28 20:29:02 +0900 - - [ruby/resolv] Prefer `Array#concat` over `#+=` on `Array` - - Fix https://bugs.ruby-lang.org/issues/19621 - - https://github.com/ruby/resolv/commit/7faaa78847 - -commit 35da0d4a6edb06ef541546e1fb58f72d4c20cdad - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-28 18:29:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-28 18:29:31 +0900 - - Support older git - - The -b flag is available since 2.28, but Ubuntu 20.04 uses 2.25. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7770 - -commit f6694b5bc89dffdc1d8b24f8c08ded1818b09d65 - Author: Soutaro Matsumoto <matsumoto@soutaro.com> - AuthorDate: 2023-04-28 11:04:03 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-28 11:04:03 +0900 - - Bundle rbs-3.1.0 (#7766) - - Notes: - Merged-By: soutaro <matsumoto@soutaro.com> - -commit f2c367734f847a7277f09c583a0476086313fdc9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-28 06:27:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-28 06:27:51 +0900 - - Introduce --enable-rjit=disasm - -commit 5cd4f35da634a33d993017bc0a9d82685201e8d4 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-28 00:42:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-28 00:42:21 +0900 - - [ruby/irb] Simplify Locale#load - (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 - -commit fef8cca822f6b69fe21cbab181ce5b5e0babff91 - Author: S-H-GAMELINKS <gamelinks007@gmail.com> - AuthorDate: 2023-04-20 21:56:38 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-04-27 22:16:42 +0900 - - Merge T_OBJECT case in rb_ivar_delete function - - Notes: - Merged: https://github.com/ruby/ruby/pull/7746 - -commit a58cae77f77d220f44d0d16f2dbf4770ac64bd1e - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-27 20:07:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-27 20:07:05 +0900 - - [ruby/irb] Stop using MagicFile for printing help messages - (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. - -commit c7bacf84f04201787d26e4a4be8aca61ff1e454b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-24 22:21:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-27 14:52:22 +0900 - - [Bug #19611] Remove never-reachable branch in logical expression - - Notes: - Merged: https://github.com/ruby/ruby/pull/7754 - -commit b0cb54a378f2c588a050dafe6db69cb4cdd2637e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-27 12:32:39 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-27 12:32:39 +0900 - - Constify `type` and `typed_flag` in `RTypedData` - - These must not be changed once initialized. - -commit dd406c5a911d2f4a16ce97016666760713540185 - Author: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - AuthorDate: 2023-04-18 14:47:54 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-27 11:25:57 +0900 - - Skip DW_FORM_GNU_* forms in addr2line.c - - DW_FORM_GNU_ref_alt and DW_FORM_GNU_strp_alt refer to data stored in an - external ELF file specified by a .gnu_debugaltlink attribute. These - attributes are generated by dwz(1), which extracts DWARF data common - amongst several files and stores it in a single, new file. It leaves - behind these two forms in the original file to point at the new, common - data. - - We don't support actually reading the .gnu_debugaltlink file in - addr2line.c (and maybe we don't really need to), but we do need to know - how to read the actual value of these forms so we can skip over the - right number of bytes and not lose track of where we are in the CU. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7731 - -commit 417eb83b48f2e9eb551e8dd5163778c3ef278972 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-27 10:19:44 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-27 10:19:48 +0900 - - RJIT: Tweak the default call threshold - - This number works better on yjit-bench (ruby-lsp). - -commit cbfb5fbb25a8b73127f69f47940c8d380270e6af - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-27 10:06:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-27 10:12:53 +0900 - - RJIT: Fix unspecified_bits with locals - -commit 12070005d46c23c47763a20d871d9de76a8022b3 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-04-18 07:46:49 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-04-27 04:02:23 +0900 - - Add a CI check for ext/Setup - - Notes: - Merged: https://github.com/ruby/ruby/pull/7729 - -commit adaff1fc496b6f01fb1c4c812b9b4082618e2f79 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-04-20 22:44:02 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-04-27 04:02:23 +0900 - - [Bug #19592] Fix ext/Setup support - - After [1], using ext/Setup to link some, but not all extensions failed - during linking. I did not know about this option, and had assumed that - only `--with-static-linked-ext` builds can include statically linked - extensions. - - Include the support code for statically linked extensions in all - configurations like before [1]. Initialize the table lazily to minimize - footprint on builds that have no statically linked extensions. - - [1]: 790cf4b6d0475614afb127b416e87cfa39044d67 "Fix autoload status of - statically linked extensions" - - Notes: - Merged: https://github.com/ruby/ruby/pull/7729 - -commit 92466e440d459cd21e89f8bfbe6d8438bcaa9389 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-27 01:52:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-27 01:52:51 +0900 - - [ruby/irb] Use a more tolerant way to check Locale#find's return - path - (https://github.com/ruby/irb/pull/572) - - https://github.com/ruby/irb/commit/0b648adf38 - -commit 3340a24634ea505c374b677a3cc9061f4428784e - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-27 01:39:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-27 01:39:19 +0900 - - [ruby/irb] Add tests for Locale#find and Locale#load - (https://github.com/ruby/irb/pull/570) - - https://github.com/ruby/irb/commit/710d5b1af5 - -commit fe0b23b42f6a2c774ad2b45851765625a151f834 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-27 00:05:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-27 00:06:05 +0900 - - [ruby/irb] Remove encoding_aliases.rb - (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. - -commit 6339cb70c3bcc54696e98c303dd4b26ed3d57afd - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-04-26 21:17:27 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-04-26 23:54:25 +0900 - - marshal.c: shallow freeze user objects - - When `freeze: true` argument is passed. - - [Bug #19427] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7764 - -commit 78be6696d864513ffad395ecd37d582143ca1216 - Author: Gary Tou <gary@garytou.com> - AuthorDate: 2023-04-26 22:08:16 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-04-26 23:21:20 +0900 - - Wrap `undef_method :a` with `ensure` - -commit 96a2e27185475d4b9138ecda4f38a35621d1d085 - Author: Gary Tou <gary@garytou.com> - AuthorDate: 2023-04-26 22:05:30 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-04-26 23:21:20 +0900 - - `klass == (VALUE)NULL` --> `!klass` - - Co-authored-by: Rafael Mendonça França <rafael@franca.dev> - -commit 5dd46a345a7f02a55ef26302ae4d52473c433da0 - Author: Gary Tou <gary@garytou.com> - AuthorDate: 2023-04-26 12:22:48 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-04-26 23:21:20 +0900 - - Test: `defined?(super)` in `BasicObject` returns `nil` - - Ensure it returns `nil` instead of segmentation faulting - -commit 1883dc5bde27caec44154b7ce1f06b07f95eab3d - Author: Gary Tou <gary@garytou.com> - AuthorDate: 2023-04-26 12:22:10 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-04-26 23:21:20 +0900 - - defined zsuper: Handle NULL superclass for `BasicObject` - - Prior to this commit, a segmentation fault occurred in `vm_defined`'s - `zsuper` implementation after NULL is returned as `BasicObject`'s superclass. - This fix returns false from `vm_defined` if the superclass is NULL. - - For example, the following code resulted in a segfault. - ```ruby - class BasicObject - def seg_fault - defined?(super) - end - end - - seg_fault - ``` - -commit ffce3117b6b615666cab8f92a7fc32ecefc0121c - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-04-26 17:12:12 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-04-26 17:58:32 +0900 - - add new debug log line on `rb_ractor_terminate_all` - - to leave the trace. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7763 - -commit 06b68db7cfd194de2c7c0bd45e18692f6f8a7b87 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-04-26 17:05:32 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-04-26 17:57:32 +0900 - - show a separator even if `ec` is NULL. - - `RUBY_DEBUG_LOG()` doesn't show anything if `GET_EC()` returns NULL, - but print a separator "\t" to make consistent TSV. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7761 - -commit 457824e2d3ddebef6435d43e0a4b22f738f9fae4 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-04-26 16:54:34 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-04-26 17:57:32 +0900 - - `RUBY_DEBUG_LOG_PID` for `RUBY_DEBUG_LOG()` - - `RUBY_DEBUG_LOG=stderr RUBY_DEBUG_LOG_PID=1 ruby ...` will prints - debug logs with PID. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7761 - -commit b90d87bf255c746cd103becd525e8550253602a4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-26 17:22:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-26 17:22:03 +0900 - - We need to checkout before BundledGem.dummy_gemspec checking. - - When newer version released rather than gems/bundled_gems defined, - `spec.version == Gem::Version.new(v)` always abort like: - - ``` - Unexpected versions between bundled_gems:3.0.4 and gemspec:3.1.0 - ``` - -commit 299d17a2f1ebda4efba7e634b9a5f7196f5274a8 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-25 20:00:05 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-26 13:13:25 +0900 - - [ruby/irb] Fix Locale's encoding lookup for Japanese encodings - (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. - -commit 5154d6beededf9d018c85316b982deb2babf40bb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-26 13:12:17 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-26 13:13:25 +0900 - - Revert "Temporary skipped failing assertions" - - This reverts commit e7cdce83e8c8797c481ccb54c260c0db1e1afa7c. - -commit bf3ed7e8266e02f96de4a369902dee7d9fdcd4bb - Author: Stan Lo <stan.lo@shopify.com> - AuthorDate: 2023-03-14 16:29:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-26 08:21:58 +0900 - - [ruby/pp] Remove patch added for Ruby 2.6/JRuby 9.3 - - https://github.com/ruby/pp/commit/09dae96129 - -commit c9b61ec53e2e2fc914d3f95e189b8e9f3bbd851a - Author: Stan Lo <stan.lo@shopify.com> - AuthorDate: 2023-03-14 15:59:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-26 08:21:57 +0900 - - [ruby/pp] Skip certain tests for JRuby - - https://github.com/ruby/pp/commit/f7bde31ca9 - -commit 82995d4615e993f1d13f3e826b93fbd65c47e19e - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-04-26 00:27:57 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-04-26 00:27:57 +0900 - - Update to ruby/spec@7f6ca5b - -commit e3d05001edf0326b24a06f0ec6cdc156663e3bf0 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-04-26 00:08:52 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-04-26 00:09:53 +0900 - - Workaround CRuby adding x86_64-linux-fake in $LOADED_FEATURES - -commit d562663e4098801c1d7fa7c64a335ea71231a598 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-04-26 00:04:25 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-04-26 00:09:53 +0900 - - Update to ruby/spec@7f69c86 - -commit d3da01cd110ca99dd0249ee9af92e12cf845998c - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-04-26 00:04:24 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-04-26 00:09:53 +0900 - - Update to ruby/mspec@1d8cf64 - -commit a82a24ed575c5f97b3755317f1a3bd6c9149a67e - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-04-03 03:28:01 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-04-26 00:06:16 +0900 - - Optimize method_missing calls - - CALLER_ARG_SPLAT is not necessary for method_missing. We just need - to unshift the method name into the arguments. - - This optimizes all method_missing calls: - - * mm(recv) ~9% - * mm(recv, *args) ~215% for args.length == 200 - * mm(recv, *args, **kw) ~55% for args.length == 200 - * mm(recv, **kw) ~22% - * mm(recv, kw: 1) ~100% - - Note that empty argument splats do get slower with this approach, - by about 30-40%. Other than non-empty argument splats, other - argument splats are faster, with the speedup depending on the - number of arguments. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7522 - -commit 583e9d24d419023bc1123190768297a468113613 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-04-03 03:06:13 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-04-26 00:06:16 +0900 - - Optimize symproc calls - - Similar to the bmethod/send optimization, this avoids using - CALLER_ARG_SPLAT if not necessary. As long as the receiver argument - can be shifted off, other arguments are passed through as-is. - - This optimizes the following types of calls: - - * symproc.(recv) ~5% - * symproc.(recv, *args) ~65% for args.length == 200 - * symproc.(recv, *args, **kw) ~45% for args.length == 200 - * symproc.(recv, **kw) ~30% - * symproc.(recv, kw: 1) ~100% - - Note that empty argument splats do get slower with this approach, - by about 2-3%. This is probably because iseq argument setup is - slower for empty argument splats than CALLER_SETUP_ARG is. Other - than non-empty argument splats, other argument splats are faster, - with the speedup depending on the number of arguments. - - The following types of calls are not optimized: - - * symproc.(*args) - * symproc.(*args, **kw) - - This is because the you cannot shift the receiver argument off - without first splatting the arg. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7522 - -commit 9b4bf02aa89fa9a9a568b7be045ab1df8053f0e6 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-04-02 12:55:43 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-04-26 00:06:16 +0900 - - Optimize send calls - - Similar to the bmethod optimization, this avoids using - CALLER_ARG_SPLAT if not necessary. As long as the method argument - can be shifted off, other arguments are passed through as-is. - - This optimizes the following types of calls: - - * send(meth, arg) ~5% - * send(meth, *args) ~75% for args.length == 200 - * send(meth, *args, **kw) ~50% for args.length == 200 - * send(meth, **kw) ~25% - * send(meth, kw: 1) ~115% - - Note that empty argument splats do get slower with this approach, - by about 20%. This is probably because iseq argument setup is - slower for empty argument splats than CALLER_SETUP_ARG is. Other - than non-empty argument splats, other argument splats are faster, - with the speedup depending on the number of arguments. - - The following types of calls are not optimized: - - * send(*args) - * send(*args, **kw) - - This is because the you cannot shift the method argument off - without first splatting the arg. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7522 - -commit af2da6419aba1e242e851664b4e6816aeb27f8cb - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-04-02 01:19:35 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-04-26 00:06:16 +0900 - - Optimize cfunc calls for f(*a) and f(*a, **kw) if kw is empty - - This optimizes the following calls: - - * ~10-15% for f(*a) when a does not end with a flagged keywords hash - * ~10-15% for f(*a) when a ends with an empty flagged keywords hash - * ~35-40% for f(*a, **kw) if kw is empty - - This still copies the array contents to the VM stack, but avoids some - overhead. It would be faster to use the array pointer directly, - but that could cause problems if the array was modified during - the call to the function. You could do that optimization for frozen - arrays, but as splatting frozen arrays is uncommon, and the speedup - is minimal (<5%), it doesn't seem worth it. - - The vm_send_cfunc benchmark has been updated to test additional cfunc - call types, and the numbers above were taken from the benchmark results. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7522 - -commit f6254f77f7a7c4d1f11180b3b382680868bd9ee4 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-03-24 06:39:31 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-04-26 00:06:16 +0900 - - Speed up calling iseq bmethods - - Currently, bmethod arguments are copied from the VM stack to the - C stack in vm_call_bmethod, then copied from the C stack to the VM - stack later in invoke_iseq_block_from_c. This is inefficient. - - This adds vm_call_iseq_bmethod and vm_call_noniseq_bmethod. - vm_call_iseq_bmethod is an optimized method that skips stack - copies (though there is one copy to remove the receiver from - the stack), and avoids calling vm_call_bmethod_body, - rb_vm_invoke_bmethod, invoke_block_from_c_proc, - invoke_iseq_block_from_c, and vm_yield_setup_args. - - Th vm_call_iseq_bmethod argument handling is similar to the - way normal iseq methods are called, and allows for similar - performance optimizations when using splats or keywords. - However, even in the no argument case it's still significantly - faster. - - A benchmark is added for bmethod calling. In my environment, - it improves bmethod calling performance by 38-59% for simple - bmethod calls, and up to 180% for bmethod calls passing - literal keywords on both sides. - - ``` - - ./miniruby-iseq-bmethod: 18159792.6 i/s - ./miniruby-m: 13174419.1 i/s - 1.38x slower - - bmethod_simple_1 - ./miniruby-iseq-bmethod: 15890745.4 i/s - ./miniruby-m: 10008972.7 i/s - 1.59x slower - - bmethod_simple_0_splat - ./miniruby-iseq-bmethod: 13142804.3 i/s - ./miniruby-m: 11168595.2 i/s - 1.18x slower - - bmethod_simple_1_splat - ./miniruby-iseq-bmethod: 12375791.0 i/s - ./miniruby-m: 8491140.1 i/s - 1.46x slower - - bmethod_no_splat - ./miniruby-iseq-bmethod: 10151258.8 i/s - ./miniruby-m: 8716664.1 i/s - 1.16x slower - - bmethod_0_splat - ./miniruby-iseq-bmethod: 8138802.5 i/s - ./miniruby-m: 7515600.2 i/s - 1.08x slower - - bmethod_1_splat - ./miniruby-iseq-bmethod: 8028372.7 i/s - ./miniruby-m: 5947658.6 i/s - 1.35x slower - - bmethod_10_splat - ./miniruby-iseq-bmethod: 6953514.1 i/s - ./miniruby-m: 4840132.9 i/s - 1.44x slower - - bmethod_100_splat - ./miniruby-iseq-bmethod: 5287288.4 i/s - ./miniruby-m: 2243218.4 i/s - 2.36x slower - - bmethod_kw - ./miniruby-iseq-bmethod: 8931358.2 i/s - ./miniruby-m: 3185818.6 i/s - 2.80x slower - - bmethod_no_kw - ./miniruby-iseq-bmethod: 12281287.4 i/s - ./miniruby-m: 10041727.9 i/s - 1.22x slower - - bmethod_kw_splat - ./miniruby-iseq-bmethod: 5618956.8 i/s - ./miniruby-m: 3657549.5 i/s - 1.54x slower - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7522 - -commit 99c6d19e502b5fdadbd367ae4b6bb3fab850fddc - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-03-07 08:58:58 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-04-26 00:06:16 +0900 - - Generalize cfunc large array splat fix to fix many additional cases raising SystemStackError - - Originally, when 2e7bceb34ea858649e1f975a934ce1894d1f06a6 fixed cfuncs to no - longer use the VM stack for large array splats, it was thought to have fully - fixed Bug #4040, since the issue was fixed for methods defined in Ruby (iseqs) - back in Ruby 2.2. - - After additional research, I determined that same issue affects almost all - types of method calls, not just iseq and cfunc calls. There were two main - types of remaining issues, important cases (where large array splat should - work) and pedantic cases (where large array splat raised SystemStackError - instead of ArgumentError). - - Important cases: - - ```ruby - define_method(:a){|*a|} - a(*1380888.times) - - def b(*a); end - send(:b, *1380888.times) - - :b.to_proc.call(self, *1380888.times) - - def d; yield(*1380888.times) end - d(&method(:b)) - - def self.method_missing(*a); end - not_a_method(*1380888.times) - - ``` - - Pedantic cases: - - ```ruby - def a; end - a(*1380888.times) - def b(_); end - b(*1380888.times) - def c(_=nil); end - c(*1380888.times) - - c = Class.new do - attr_accessor :a - alias b a= - end.new - c.a(*1380888.times) - c.b(*1380888.times) - - c = Struct.new(:a) do - alias b a= - end.new - c.a(*1380888.times) - c.b(*1380888.times) - ``` - - This patch fixes all usage of CALLER_SETUP_ARG with splatting a large - number of arguments, and required similar fixes to use a temporary - hidden array in three other cases where the VM would use the VM stack - for handling a large number of arguments. However, it is possible - there may be additional cases where splatting a large number - of arguments still causes a SystemStackError. - - This has a measurable performance impact, as it requires additional - checks for a large number of arguments in many additional cases. - - This change is fairly invasive, as there were many different VM - functions that needed to be modified to support this. To avoid - too much API change, I modified struct rb_calling_info to add a - heap_argv member for storing the array, so I would not have to - thread it through many functions. This struct is always stack - allocated, which helps ensure sure GC doesn't collect it early. - - Because of how invasive the changes are, and how rarely large - arrays are actually splatted in Ruby code, the existing test/spec - suites are not great at testing for correct behavior. To try to - find and fix all issues, I tested this in CI with - VM_ARGC_STACK_MAX to -1, ensuring that a temporary array is used - for all array splat method calls. This was very helpful in - finding breaking cases, especially ones involving flagged keyword - hashes. - - Fixes [Bug #4040] - - Co-authored-by: Jimmy Miller <jimmy.miller@shopify.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7522 - -commit e7cdce83e8c8797c481ccb54c260c0db1e1afa7c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-25 15:05:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-25 15:05:14 +0900 - - Temporary skipped failing assertions - -commit 758063e06823a9e95b7e0ddb97aeab53f339e6ae - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-25 14:46:01 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-25 14:46:01 +0900 - - Removed commented-out code - -commit 3d5febf65b46f1a76759aa68d10f0888748831ab - Author: schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-04-15 07:32:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-25 14:43:06 +0900 - - [ruby/syntax_suggest] Clean up output - - 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 - -commit f77dc6fb1630f01c2b5dd1a407931c829ad6e77c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-06 16:42:56 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-25 14:43:05 +0900 - - [ruby/syntax_suggest] standardrb --fix-unsafely spec/spec_helper.rb - - https://github.com/ruby/syntax_suggest/commit/6e266b3b2b - -commit 9ccf0a066d2f482df96709a865a3d302926399a4 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-24 22:03:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-25 14:41:06 +0900 - - [ruby/irb] Add tests for Locale class - (https://github.com/ruby/irb/pull/566) - - https://github.com/ruby/irb/commit/df32e024be - -commit ed887cbb4c3f9505745bb1110da56690a113afca - Author: Akinori MUSHA <knu@idaemons.org> - AuthorDate: 2023-04-25 10:57:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-25 10:58:12 +0900 - - [ruby/set] Update lib/set.rb - - https://github.com/ruby/set/commit/bc59f85f2f - -commit 15796ae1e80e32e8a4ff25d6663d89afc00025bb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 14:08:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-25 10:58:12 +0900 - - [ruby/set] Expose Set::VERSION - - https://github.com/ruby/set/commit/d39b33f463 - -commit c301ba0a663386881addb1d987cca5e73d35cf2e - Author: Akinori MUSHA <knu@idaemons.org> - AuthorDate: 2023-04-25 10:55:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-25 10:55:57 +0900 - - [ruby/abbrev] Update lib/abbrev.rb - - https://github.com/ruby/abbrev/commit/6fa790eac1 - -commit 8b9b075b833f1d5c48b2df75cbf898944ab09664 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 12:49:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-25 10:55:56 +0900 - - [ruby/abbrev] Expose Abbrev::VERSION - - https://github.com/ruby/abbrev/commit/255ca681c3 - -commit 85ed226cca1185ddf2fbcd4bf78cbace19e6695f - Author: Akinori MUSHA <knu@idaemons.org> - AuthorDate: 2023-04-25 10:50:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-25 10:51:26 +0900 - - [ruby/syslog] Improve the version extraction - - https://github.com/ruby/syslog/commit/34da65a002 - -commit a66c41d6006fdcf372474d56d4c6284636b9ed87 - Author: Akinori MUSHA <knu@idaemons.org> - AuthorDate: 2023-04-25 10:50:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-25 10:51:25 +0900 - - [ruby/syslog] Raise required_ruby_version - - https://github.com/ruby/syslog/commit/5289373016 - -commit 117fc8e72dc8500a4ab1f9ff0ef3a0a9ecc46786 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-21 13:22:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-25 10:51:24 +0900 - - [ruby/syslog] Expose Syslog::VERSION - - https://github.com/ruby/syslog/commit/ff5d72fcb9 - -commit 0bf10dfd25b0b18fcb97465845a08b53f5d595f8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-25 04:54:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-25 04:54:33 +0900 - - Avoid linking capstone by default - - Workaround for https://github.com/ruby/setup-ruby/pull/501#issuecomment-1520722486 - -commit f492e3b4e5ed30f6a592a3b644228bd335af7284 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-25 04:20:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-25 04:20:52 +0900 - - YJIT: Use general definedivar at the end of chains (#7756) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit f84d94b8039c1c44fd99690fd4b4e0184dab4fb5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-25 04:20:18 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-25 04:20:18 +0900 - - YJIT: Show definedivar exit reasons (#7755) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 8a132358d733d9cd81c6b83c9127e807a42c8ab9 - Author: Carl Brasic <cbrasic@gmail.com> - AuthorDate: 2023-04-25 01:31:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-25 01:31:13 +0900 - - [ruby/reline] Revert #335 (Trap TSTP to handle C-z) - (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> - -commit f8e7048348d022814736d0a7e49f2f2494db6a2f - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-03-24 05:44:04 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-04-24 23:37:20 +0900 - - Allow anonymous memberless Struct - - Previously, named memberless Structs were allowed, but anonymous - memberless Structs were not. - - Fixes [Bug #19416] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7587 - -commit 73fc81199de5e567e38f7ea9067260eb6866cbf9 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-24 23:10:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-24 23:10:36 +0900 - - [ruby/irb] Simplify the help command's implementation - (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. - -commit 805899dda29e36a42ffd9e076b9296f3bf13af5a - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-24 23:05:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-24 23:05:16 +0900 - - [ruby/irb] Filter out top-level methods when using `ls - <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. - -commit a8ba1ddd78544b4bda749051d44f7b2a8a0ec5ff - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-03-25 03:53:53 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-04-24 11:27:58 +0900 - - Use UTF-8 encoding for literal extended regexps with UTF-8 characters in comments - - Fixes [Bug #19455] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7592 - -commit ec211ad54d5ab8fef5031b8938028acaa1c5002a - Author: Yusuf Daniju <15727660+ydaniju@users.noreply.github.com> - AuthorDate: 2023-04-24 03:41:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-24 03:41:40 +0900 - - [ruby/irb] fix typo in tracer (https://github.com/ruby/irb/pull/565) - - https://github.com/ruby/irb/commit/2f567f3d3e - -commit dafbaabc04e5a2d34045af78629a7249fd8c7481 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-23 11:54:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-23 12:01:13 +0900 - - Check the precision of `getrusage` at runtime - -commit c5529aa5fc9cad4334bcb8ba36b96a9ea09c54e6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-19 20:01:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-22 21:21:35 +0900 - - Fix a guard of `Process.times` - - `GETRUSAGE_BASED_CLOCK_PROCESS_CPUTIME_ID` clock uses `getrusage` - always if available as the name states. That is if it is implemented - `getrusage` is available, regardless microseconds in its results. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7739 - -commit 4cff7a92b8c97bb86dc1027b674a688f5182e302 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-19 13:29:02 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-22 21:21:35 +0900 - - Fix an example of `Process.times` - - Prior to commit 5806c54447439f2ba22892e4045e78dd80f96f0c, it was "at - least one result with precision beyond milliseconds (with none-zero - microseconds) should exist"; after this commit, "at least one result - should have zero microseconds". This chance is lower than the - previous condition. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7739 - -commit 1702b0f438b2ac7c8b7d9c42bb5dfe23fad1df0f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-22 15:58:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-22 15:58:07 +0900 - - Remove unused opt_call_c_function insn (#7750) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit de5cd5a635e3b975ca7acc5caf0363f2811abd95 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-21 10:53:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-21 22:24:55 +0900 - - Use shorter path as `SPEC_TEMP_DIR` - - The temporary directory under the build directory may be too long as a - UNIX socket path. On macOS, the default `TMPDIR` per user is also - very long. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7749 - -commit e956052fa953d7e312a2f524127b2ac6ae1b0da2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-21 10:20:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-21 22:17:18 +0900 - - Skip when unix socket path is too long - - Eventually the path directly under "/tmp" is complained by `rm_r` in - spec/mspec/lib/mspec/helpers/fs.rb. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7749 - -commit 39bbbd767d6465080c6e1d6ba0da98c2762eedc6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-21 15:34:01 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-21 21:28:08 +0900 - - Add rubyspec-capiext on mswin - -commit 94a418d0bb6c1740801c9fd5a646a2683c5f8260 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-21 15:19:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-21 15:22:52 +0900 - - [ruby/rinda] Expose Rinda::VERSION - - https://github.com/ruby/rinda/commit/fa3865ac48 - -commit b9b43a10202573431ae211984b02c28792f58ef8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-21 13:34:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-21 13:46:10 +0900 - - [ruby/win32ole] Reuse WIN32OLE_VERSION for gem version - - https://github.com/ruby/win32ole/commit/bff3ea8b0b - -commit 9702a8142b8a4e97cde983300849590bfe73b8b1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-21 13:13:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-21 13:21:05 +0900 - - [ruby/fcntl] Expose Fcntl::VERSION - - https://github.com/ruby/fcntl/commit/cb8e414e9f - -commit 072ef7a1aad9c2a9296d1df29996da4068c50b94 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-04-20 02:40:40 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-04-21 08:09:16 +0900 - - YJIT: invokesuper: Remove cme mid matching check - - This check was introduced to match an assertion in the C YJIT when this - was originally introduced. I don't believe it's necessary for - correctness of the generated code. - - Co-authored-by: Adam Hess <HParker@github.com> - Co-authored-by: Daniel Colson <danieljamescolson@gmail.com> - Co-authored-by: Luan Vieira <luanzeba@github.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7740 - -commit a42c36c0f1b0439826b37c868fac4ded41e7aa91 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-21 07:35:27 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-21 07:35:27 +0900 - - YJIT: Merge lower_stack into the split pass (#7748) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit ae90fa981a18119a06b152bfec203e902aeed3b9 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-19 02:25:01 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-21 05:53:13 +0900 - - [DOC] Documentation for flags of RClass - - Notes: - Merged: https://github.com/ruby/ruby/pull/7734 - -commit 277098bde2353e408ff4195d5cad387f0739b83c - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-04-21 05:31:34 +0900 - Commit: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - CommitDate: 2023-04-21 05:31:34 +0900 - - Fix inaccurate comment - -commit 64a25977ed93f5c1d95d72359979a0b89dc9ffc0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-21 05:08:42 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-21 05:08:42 +0900 - - YJIT: Merge csel and mov on arm64 (#7747) - - * YJIT: Refactor arm64_split with &mut insn - - * YJIT: Merge csel and mov on arm64 - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 995b960c70c624639552a04c38c7822f9875c53d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-21 02:05:30 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-21 02:05:30 +0900 - - YJIT: Avoid splitting mov for small values on arm64 (#7745) - - * YJIT: Avoid splitting mov for small values on arm64 - - * Fix a comment - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - - * YJIT: Test the 0xffff boundary - - --------- - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit ce38ad6963b609b4054bba6165abb78414d5428e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-19 19:00:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-20 10:57:17 +0900 - - [rubygems/rubygems] util/rubocop -A - - https://github.com/rubygems/rubygems/commit/784e5e2fe5 - -commit b42f0094ce4198fac535bd69bf173732c0e53ab5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-19 18:56:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-20 10:57:17 +0900 - - [rubygems/rubygems] Support Symbol and URL keys - - https://github.com/rubygems/rubygems/commit/3bda049c73 - -commit 4bb0e01da2083bd537444ce7f27f3e1cdfa23712 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-19 18:41:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-20 10:57:17 +0900 - - [rubygems/rubygems] warn message when RubyGems handle invalid yaml like 'invalid: foo: bar' - - https://github.com/rubygems/rubygems/commit/b8d0c25b7e - -commit dbcdac00e6b9b9b72c0679e54d2ecef02a9cf3bc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-19 18:27:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-20 10:57:16 +0900 - - [rubygems/rubygems] Revert "Bundler::YAMLSerializer.load couldn't raise error when invalid yaml was provided" - - This reverts commit https://github.com/rubygems/rubygems/commit/cfcfde04c783. - - https://github.com/rubygems/rubygems/commit/ac21ae7083 - -commit ad4a160220abad330cb9ba41e5dcd5e46bb056f4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-20 10:20:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-20 10:28:29 +0900 - - Exit explicitly instead of ! - -commit 2d301945f67edda6495224889f82251229661169 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-20 10:16:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-20 10:25:44 +0900 - - Run source file checks on all branches - -commit 7821708c843b5d6a6f7b04f49bde6f649fd230bf - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-20 09:57:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-20 09:57:49 +0900 - - Use ASCII-compatible encoding for tests - - Since these files are written in a wide character encoding, stop at - first NUL byte and are actually empty. ASCII-incompatible encodings - have never been supported as source encoding. - -commit d2d0954c1618d90587f6f4804d9db0af0ef24ee1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-20 09:25:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-20 09:25:24 +0900 - - YJIT: Replace Mov with LoadInto on arm64 (#7744) - - * YJIT: Replace Mov with LoadInto on arm64 - - * YJIT: Add a test for the new pass - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 5fc11f306c6d38e46cc45f0ffabc5ea14084a11a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-20 08:30:43 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-20 08:30:43 +0900 - - YJIT: Tweak asm comments (#7743) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 2531bb0b66e8860b27c449d7815229b4763ab415 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-20 05:08:35 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-20 05:08:35 +0900 - - YJIT: Remove Insn::RegTemps (#7741) - - * YJIT: Remove Insn::RegTemps - - * Update a comment - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - --------- - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 74772840430fc3fca3f5fb0ad585d9cc48f512fb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-18 13:30:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-19 15:59:59 +0900 - - Hide Gem::MockGemUi. It's only used by tests - -commit d1c42da7a1212fe04dc86ed7a7439dd69380f08a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-18 19:37:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:24 +0900 - - [rubygems/rubygems] To use Gem::YAMLSerializer in Bundler - - https://github.com/rubygems/rubygems/commit/5351e01b32 - -commit 40d1a0004041f60301c8090ab8955024ebc35cc2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-18 19:30:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:23 +0900 - - [rubygems/rubygems] Copy YAMLSerializer from Bundler - - https://github.com/rubygems/rubygems/commit/6a97346708 - -commit 62e5ba537acbb439366ddfa99992c1151df55a24 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-18 11:03:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:23 +0900 - - [rubygems/rubygems] Added tests for load_with_rubygems_config_hash and dump_with_rubygems_yaml - - https://github.com/rubygems/rubygems/commit/0393f24119 - -commit 8b95b33a9d114d2f9f3852c289722c8393d10fd8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-18 10:59:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:22 +0900 - - [rubygems/rubygems] Bundler::YAMLSerializer.load couldn't raise error when invalid yaml was provided - - https://github.com/rubygems/rubygems/commit/cfcfde04c7 - -commit 92ab4e41dd6261d6f2fe04011508359544535164 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-18 10:13:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:22 +0900 - - [rubygems/rubygems] Replaced Gem::ConfigFile.dump_with_rubygems_yaml for saveing configuration - - https://github.com/rubygems/rubygems/commit/46438e61cd - -commit ef54a9aeb689164d99ccccc8cc92c588936fa321 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-18 09:57:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:21 +0900 - - [rubygems/rubygems] Introduce self.load_with_rubygems_config_hash - - https://github.com/rubygems/rubygems/commit/9175b8cf2a - -commit 644d7df021e17c70932da3173ec309ae1c8063d5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-18 09:51:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:21 +0900 - - [rubygems/rubygems] Introduce self.dump_with_rubygems_yaml - - https://github.com/rubygems/rubygems/commit/3d3b0d80a1 - -commit 45655089dac2f7ac5684f99607698d9eb6dae5d5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 20:46:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:20 +0900 - - [rubygems/rubygems] Removed trailing-slash for domain - - https://github.com/rubygems/rubygems/commit/81ba58f445 - -commit cdc2e3de108d448026bf793d2b482d6abf7ae236 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 20:24:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:20 +0900 - - [rubygems/rubygems] Wrap self.convert_rubygems_config_hash from Bundler::YAMLSerializer.load - - https://github.com/rubygems/rubygems/commit/080880ac23 - -commit 7b959f628801d9f411a2dcc231c25a06e9d6234f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 19:57:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:20 +0900 - - [rubygems/rubygems] Move all changes only in RubyGems - - https://github.com/rubygems/rubygems/commit/d842e2092f - -commit 30b3290f266609d502791ec5d2edb4885d89d462 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 19:21:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:19 +0900 - - [rubygems/rubygems] Added guard condition for replacing __ variable in YAML keys - - https://github.com/rubygems/rubygems/commit/e7d31405ea - -commit d0dc6179173a79635267bae951352d3dee5c5d13 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 19:07:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:19 +0900 - - [rubygems/rubygems] Replaced load_yaml_file with Bundler::YAMLSerializer - - https://github.com/rubygems/rubygems/commit/1ed5fc018e - -commit 3988b1d471ef79be3a86b3db893a0caaaa1d7ff1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 19:06:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:18 +0900 - - [rubygems/rubygems] api_key is always contained string - - https://github.com/rubygems/rubygems/commit/925f7f6717 - -commit bf8d8ce1ee196a508c934f6664af949ca98548e5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 18:54:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:18 +0900 - - [rubygems/rubygems] Keep compatiblity of Bundler specs - - https://github.com/rubygems/rubygems/commit/b211eeacba - -commit 364c2fea345a2b0cc5f1d975e1b55c7f542a7936 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 16:45:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:17 +0900 - - [rubygems/rubygems] Replaced empty hash to nil value in YAML - - https://github.com/rubygems/rubygems/commit/8771fbf53d - -commit 7e537e96131fd5f244544d3b07a362a2938ad1a2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 16:10:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:17 +0900 - - [rubygems/rubygems] Only convert old URL key name when it's contained double underscore - - https://github.com/rubygems/rubygems/commit/a4bfa2ef94 - -commit e684eb9e6126b3cae7d63efca9fe365a22ddefd7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 15:45:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:16 +0900 - - [rubygems/rubygems] Added missing require for Bundler::YAMLSerializer - - https://github.com/rubygems/rubygems/commit/55ef32fdd7 - -commit 9365492f63c4f8c590f8d2d08fbe5bed63ff1ed4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 15:26:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:16 +0900 - - [rubygems/rubygems] Fix regexp for Symbol - - https://github.com/rubygems/rubygems/commit/9a3ed682a0 - -commit 1225eff38f2128b94489d833722cc5be497d4377 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 15:10:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:15 +0900 - - [rubygems/rubygems] Don't use Psych - - https://github.com/rubygems/rubygems/commit/d6555aaa28 - -commit 038c6e773f1140485840e0789e275e0cdf880f0a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 15:05:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:15 +0900 - - [rubygems/rubygems] Added explicitly loading for Gem::SafeYAML - - https://github.com/rubygems/rubygems/commit/3d9d587dd7 - -commit 2c91ec086919d695db5d6d15b5124f192205fdab - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 15:05:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:15 +0900 - - [rubygems/rubygems] We need to convert empty string for nil value - - https://github.com/rubygems/rubygems/commit/348c82311f - -commit fd981ebf4c9661bb3ce243477a18fdb5413dde4e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 14:45:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:14 +0900 - - [rubygems/rubygems] Handle Symbol value - - https://github.com/rubygems/rubygems/commit/c98677d073 - -commit 2014dc5e3aef50eb59b05138af8f0f72935c4f58 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 14:42:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:14 +0900 - - [rubygems/rubygems] Handle Symbol key and Interger and Boolean values - - https://github.com/rubygems/rubygems/commit/63efdac045 - -commit 6f50ecfe664924c086879273a29a2ecea9e51683 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-17 13:44:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-19 15:56:13 +0900 - - [rubygems/rubygems] Try to use pure-ruby YAML serializer for configuration - - https://github.com/rubygems/rubygems/commit/3268d40974 - -commit 628e432739e1d2578d357420aa652a97eb8c2649 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-04-19 11:40:16 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-04-19 14:53:56 +0900 - - fix `NameError` message - - The following code produces two NameErrors respectively - and they are independent, but the second one can show - `private constant` message because of first NameError. - - ```ruby - class C - class PrivateClass; end - private_constant :PrivateClass - end - - begin - eval('class C::PrivateClass; end') - rescue => e - p e - end - - begin - Object.const_get 'Foo' - rescue => e - p e - end - - #<NameError: private constant C::PrivateClass referenced> - #<NameError: private constant C::Foo referenced> - #=> should be #<NameError: uninitialized constant Foo> - ``` - - It fails the test-all tests with - `make test-all TESTS='ruby/class ruby/parse --seed=58891 -v`. - - The reason is clear miss from https://github.com/ruby/ruby/commit/7387c08373a - - Notes: - Merged: https://github.com/ruby/ruby/pull/7736 - -commit a1c2c274eebcc2a5275b677ebf94a8dbff380770 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-04-19 13:08:28 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-19 13:08:28 +0900 - - Refactor `Regexp#match` cache implementation (#7724) - - * Refactor Regexp#match cache implementation - - Improved variable and function names - Fixed [Bug 19537] (Maybe fixed in https://github.com/ruby/ruby/pull/7694) - - * Add a comment of the glossary for "match cache" - - * Skip to reset match cache when no cache point on null check - - Notes: - Merged-By: makenowjust <make.just.on@gmail.com> - -commit bdffcd6df30d7f21cf1a3a174672e82074800451 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-04-19 05:53:37 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-04-19 09:16:22 +0900 - - Update RJIT to support newarray_send - - This also adds max / hash support - - Notes: - Merged: https://github.com/ruby/ruby/pull/6090 - -commit b816ea87725d85b0b9cf9628603245041a2d5123 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-04-19 05:16:14 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-04-19 09:16:22 +0900 - - Implement opt_newarray_send in YJIT - - This commit implements opt_newarray_send along with min / max / hash for - stack allocated arrays - - Notes: - Merged: https://github.com/ruby/ruby/pull/6090 - -commit 66938fc703af9df14d0bb5958e55728fc8fd481c - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2022-07-06 07:36:23 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-04-19 09:16:22 +0900 - - updating bindgen - - Notes: - Merged: https://github.com/ruby/ruby/pull/6090 - -commit c5fc1ce975ecdf1c6818714e47579c5d3531c4ca - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2022-06-07 09:27:56 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-04-19 09:16:22 +0900 - - Emit special instruction for array literal + .(hash|min|max) - - This commit introduces a new instruction `opt_newarray_send` which is - used when there is an array literal followed by either the `hash`, - `min`, or `max` method. - - ``` - [a, b, c].hash - ``` - - Will emit an `opt_newarray_send` instruction. This instruction falls - back to a method call if the "interested" method has been monkey - patched. - - Here are some examples of the instructions generated: - - ``` - $ ./miniruby --dump=insns -e '[@a, @b].max' - == disasm: #<ISeq:<main>@-e:1 (1,0)-(1,12)> (catch: FALSE) - 0000 getinstancevariable :@a, <is:0> ( 1)[Li] - 0003 getinstancevariable :@b, <is:1> - 0006 opt_newarray_send 2, :max - 0009 leave - $ ./miniruby --dump=insns -e '[@a, @b].min' - == disasm: #<ISeq:<main>@-e:1 (1,0)-(1,12)> (catch: FALSE) - 0000 getinstancevariable :@a, <is:0> ( 1)[Li] - 0003 getinstancevariable :@b, <is:1> - 0006 opt_newarray_send 2, :min - 0009 leave - $ ./miniruby --dump=insns -e '[@a, @b].hash' - == disasm: #<ISeq:<main>@-e:1 (1,0)-(1,13)> (catch: FALSE) - 0000 getinstancevariable :@a, <is:0> ( 1)[Li] - 0003 getinstancevariable :@b, <is:1> - 0006 opt_newarray_send 2, :hash - 0009 leave - ``` - - [Feature #18897] [ruby-core:109147] - - Co-authored-by: John Hawthorn <jhawthorn@github.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/6090 - -commit 3016f30c956413268655dcb25dbe5041684f9528 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-04-19 06:45:18 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-04-19 08:56:48 +0900 - - Return NULL to indicate the next shape isn't found - - During compaction we must fix up shapes on objects who were extended but - then became embedded. `rb_shape_traverse_from_new_root` is supposed to - walk shape trees looking for a matching shape. When a shape has a - "single child" we weren't returning NULL when the edge names didn't - match. - - In the case of a single outgoing edge, this patch returns NULL when the - child edge name doesn't match (similar to the case when a shape has a - hash of outgoing edges) - - Notes: - Merged: https://github.com/ruby/ruby/pull/7735 - -commit b09f5c7bf79d347aa6ed92964cff16d7da008ad9 - Author: Vladimir Dementyev <dementiev.vm@gmail.com> - AuthorDate: 2023-04-19 08:19:31 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-19 08:19:31 +0900 - - MatchData#named_captures: add optional symbolize_names keyword (#6952) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 2dff1d4fdabd0fafeeac675baaaf7b06bb3150f9 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-04-18 23:09:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-18 23:09:16 +0900 - - YJIT: Fix raw sample stack lengths in exit traces (#7728) - - yjit-trace-exits appends a synthetic sample for the instruction being - exited, but we didn't increment the size of the stack. Fixing this count - correctly lets us successfully generate a flamegraph from the exits. - - I also replaced the line number for instructions with 0, as I don't - think the previous value had meaning. - - Co-authored-by: Adam Hess <HParker@github.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 8519d94d3d8511080d3724fd328926d443cb95fa - Author: Kazuhiro NISHIYAMA <zn@mbf.nifty.com> - AuthorDate: 2023-04-18 10:41:00 +0900 - Commit: Kazuhiro NISHIYAMA <zn@mbf.nifty.com> - CommitDate: 2023-04-18 10:41:00 +0900 - - Update how to subscribe mailing lists - - - Update mailing lists domain - - Use 'join' instead of an alias 'subscribe'. - - Command should be in subject instead of body. - -commit 293913905e87c799c00c113900814987dce994e7 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-04-18 06:58:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-18 06:58:04 +0900 - - YJIT: Fixes failure reported by rails for opt+splat+rest (#7727) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 5aa3be65f4e003f3638258cdd6e10aabd9d05d2d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-18 06:57:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-18 06:57:33 +0900 - - YJIT: Spill a caller stack as late as possible (#7726) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit f3979aec76868f4bba992d267cbca7a757f4a8b6 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-04-14 18:26:09 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-04-17 17:29:46 +0900 - - Add spec for `Warning[:performance]` - - [Feature #19538] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7715 - -commit a0d1069e03fd52355e26d8cc3cbbed34632876e6 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-15 05:28:14 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-17 00:06:31 +0900 - - Make classes embedded on 32 bit - - Classes are now exactly 80 bytes when embedded, which perfectly fits the - 3rd size pool on 32 bit systems. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7719 - -commit 24b137336b71f77bf9ae9c532c0a5520709f73e8 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-15 05:27:37 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-17 00:06:31 +0900 - - Move shape ID to flags for classes on 32 bit - - Moves shape ID to FL_USER4 to FL_USER19 for the shape ID on 32 bit - systems. This makes the rb_classext_struct smaller so that it can be - embedded. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7719 - -commit d7bb7e70cc954925d896a4185d9eb28cee2c2b6f - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-15 05:26:46 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-17 00:06:31 +0900 - - Change RMODULE_ALLOCATED_BUT_NOT_INITIALIZED - - RCLASS_CLONED no longer uses FL_USER1, so we can make - RMODULE_ALLOCATED_BUT_NOT_INITIALIZED use FL_USER1. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7719 - -commit ad3d4e87d7e20c7e7ff2836567a44bb29368f3ec - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-15 05:25:06 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-17 00:06:31 +0900 - - Move RCLASS_CLONED to rb_classext_struct - - This commit moves RCLASS_CLONED from the flags to the - rb_classext_struct. This frees the FL_USER1 bit. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7719 - -commit fac814c2dc31afef272b45392a7389ef0bfa3a4f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-16 17:45:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-16 17:45:27 +0900 - - Fix `PLATFORM_GET_INC` - - On platforms where unaligned word access is not allowed, and if - `sizeof(val)` and `sizeof(type)` differ: - - - `val` > `type`, `val` will be a garbage. - - `val` < `type`, outside `val` will be clobbered. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7723 - -commit 29e01c6f5f8901bdaab818dfd4699cfa2a86b8e6 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-04-16 03:58:57 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-04-16 09:26:56 +0900 - - skip if `DidYouMean.formatter=` is not defined - - ruby/test_default_gems.rb can define empty `DidYouMean` module - because of the following line (second require) in the - `lib/did_you_mean/did_you_mean.gemspec`: - - ```ruby - begin - require_relative "lib/did_you_mean/version" - rescue LoadError # Fallback to load version file in ruby core repository - require_relative "version" - end - ``` - - It defines only `::DidYouMean::VERSION`. - - However, in the `test/ruby/test_patten_matching.rb` assumes that - if `defined?(DidYouMean)` is true, then there is a method `DidYouMean.formatter=` - and this assumption fails all tests in `test/ruby/test_patten_matching.rb` if - there is only a `::DidYouMean::VERSION`. - - To reproduce the failures, we need to repeat the following command: - - `make test-all TESTS='-v ruby/test_default_gems.rb ruby/pattern_matching'` - - (because the ruby/test_default_gems.rb should be run before the ruby/pattern_matching`) - - This patch introduces more strict gurds. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7722 - -commit 52449b5b75068872ce568ed00c4c7fb8e6c28072 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-03-30 23:23:14 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-04-15 23:29:46 +0900 - - Implement ObjectSpace::WeakMap#delete and ObjectSpace::WeakKeyMap#delete - - [Feature #19561] - - It's useful to be able to remove references from weak maps. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7629 - -commit 4dc2e5a850e6b44e715ca8fa31d21dddf5ec1491 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-04-15 23:09:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-15 23:09:04 +0900 - - Fix packed_data.rdoc - -commit 19aa30d5d515cd602211d4708e709913d5a136e1 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-04-15 18:31:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-15 18:32:05 +0900 - - [ruby/reline] Change Reline.add_dialog_proc(name, nil) to properly - remove dialog_proc - (https://github.com/ruby/reline/pull/532) - - https://github.com/ruby/reline/commit/43283b2f37 - -commit 5944a31614279e814fff6a47d034f5c034226855 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-15 11:48:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-15 11:48:11 +0900 - - [DOC] Update sample callback of `rb_objspace_each_objects` - - * refine liveness check - * fix missing closing brace - -commit a1db5ecd935ef1fc95ad8844f33f293fe22bfdf5 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-04-14 18:28:41 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-04-15 09:10:38 +0900 - - Add specs for ObjectSpace::WeakKeyMap - - [Feature #18498] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7716 - -commit 45c6b58768c53b5021a780c7e5fec2382e940b04 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-15 08:49:44 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-15 08:49:44 +0900 - - YJIT: Add a counter to all side exits (#7720) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 87c7de55e0ef34ea5a3ee1238216316035959b90 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-04-15 05:49:38 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-04-15 07:01:14 +0900 - - RJIT: Skip a YJIT test - - Despite applying a fix to RJIT similar to the YJIT fix, this test still - crashes RJIT. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7718 - -commit 0b95cbcbde8875effdbcbb676cb0a7f751a1d4c1 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-04-15 05:40:58 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-04-15 07:01:14 +0900 - - YJIT: Remove duplicate `asm.spill_temps()` - - `jit_prepare_routine_call()` calls it, and there is another call above on line 2302. - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7718 - -commit 31e67a476f2262e01a0829e8ab5e6d8a97e0724e - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-04-15 04:04:55 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-04-15 07:01:14 +0900 - - YJIT: Fix false object collection when setting ivar - - Previously, setinstancevariable could generate code that calls - `rb_ensure_iv_list_size()` without first updating `cfp->sp`. This means - in the event that a GC start from within said routine the top few - objects would not be marked, causing them to be falsly collected. - - Call `jit_prepare_routine_call()` first. - - [Bug #19601] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7718 - -commit 4501fb8b467cd40da5e160b82db7ea1a10d9e7ca - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-15 06:00:10 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-15 06:00:10 +0900 - - YJIT: Introduce Target::SideExit (#7712) - - * YJIT: Introduce Target::SideExit - - * YJIT: Obviate Insn::SideExitContext - - * YJIT: Avoid cloning a Context for each insn - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit d83e59e6b8b52002cc46a14d7d4dc69416379029 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-04-15 03:21:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-15 03:21:29 +0900 - - YJIT: Change to Option<CodegenStatus> (#7717) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 6c1b604e29c32baff612d8e26947255a5f3c70ac - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-04-14 17:07:33 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-04-14 17:07:33 +0900 - - Revert "Add specs for ObjectSpace::WeakKeyMap" - - This reverts commit fce8f9f24e4903784266fc9694f86ddd930d6141. - -commit fce8f9f24e4903784266fc9694f86ddd930d6141 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-03-31 17:58:56 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-04-14 16:57:04 +0900 - - Add specs for ObjectSpace::WeakKeyMap - - [Feature #18498] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7640 - -commit 6a5c355e4e7deb76363f474041d00465be3b317b - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-04-13 23:48:59 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-04-14 16:46:10 +0900 - - Add RB_WARN_CATEGORY_DEFAULT_BITS - - Followup: ac123f167a364c3d7a43eca78d564e41f6dbb91e - - RB_WARN_CATEGORY_ALL_BITS is exposed in a public header, so it - makes sense for it to be updated to contain all valid bits. - - Instead we introduce RB_WARN_CATEGORY_DEFAULT_BITS to list the - categories that are enabled by default. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7710 - -commit 67743d582317544d2c830b63d3423b04bad185a7 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-04-14 15:37:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-14 15:38:51 +0900 - - [ruby/stringio] Development of 3.0.7 started. - - https://github.com/ruby/stringio/commit/5d39880f70 - -commit 3733ee835b16052d1e1b8e309eb8cb7266209472 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-14 11:34:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-14 12:43:46 +0900 - - [ruby/readline-ext] Expose Readline::GEM_VERSION - - https://github.com/ruby/readline-ext/commit/70aa84b80e - -commit 283c19037423aa9ac86b1094950aec04210f9129 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-14 12:01:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-14 12:43:17 +0900 - - [ruby/nkf] Expose NKF::GEM_VERSION - - https://github.com/ruby/nkf/commit/0d0fb3a162 - -commit 8a06f1a69f987d37aa1b3701668a1a1b6c826667 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-14 11:06:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-14 12:42:36 +0900 - - [ruby/pathname] Expose Pathname::VERSION - - https://github.com/ruby/pathname/commit/2b0b1a82ee - -commit 1f115f141dd17f75049a5e17107906c5bcc372e1 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-04-13 04:33:16 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-04-14 12:22:36 +0900 - - Speed up rebuilding the loaded feature index - - Rebuilding the loaded feature index slowed down with the bug fix - for #17885 in 79a4484a072e9769b603e7b4fbdb15b1d7eccb15. The - slowdown was extreme if realpath emulation was used, but even when - not emulated, it could be about 10x slower. - - This adds loaded_features_realpath_map to rb_vm_struct. This is a - hidden hash mapping loaded feature paths to realpaths. When - rebuilding the loaded feature index, look at this hash to get - cached realpath values, and skip calling rb_check_realpath if a - cached value is found. - - Fixes [Bug #19246] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7699 - -commit 6beb755d810082ea3f557f54c687bc752a11cc7b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 13:24:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-14 10:52:08 +0900 - - [ruby/prettyprint] Expose PrettyPrint::VERSION - - https://github.com/ruby/prettyprint/commit/c6f3947e96 - -commit 3f8756484f221625bf7069f46bd876bfe3645940 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 13:23:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-14 10:49:51 +0900 - - [ruby/pp] Expose PP::VERSION - - https://github.com/ruby/pp/commit/3d0e65e79f - -commit 652f27330851e6154fc027515dcd43954a69cd9a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 13:29:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-14 10:46:38 +0900 - - [ruby/resolv] Expose Resolv::VERSION - - https://github.com/ruby/resolv/commit/6ab2385e89 - -commit ebe620def601d804b7dba1e00132b9bc10d5ef6f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 14:07:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-14 10:43:47 +0900 - - [ruby/securerandom] Expose SecureRandom::VERSION - - https://github.com/ruby/securerandom/commit/2e6434331d - -commit 60f22ebf86248388b41b4ec751d16700f2b4b621 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-13 22:50:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-14 10:22:09 +0900 - - [Bug #19533] Add spec of infinite range inclusion - - Notes: - Merged: https://github.com/ruby/ruby/pull/7574 - -commit fb17c833f542222afdf482924877d43aa577782d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-21 22:53:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-14 10:22:09 +0900 - - [Bug #19533] Fix infinite range inclusion with numeric value - - Notes: - Merged: https://github.com/ruby/ruby/pull/7574 - -commit 1a149aab776aa6741628eb35482eff1ded197fd2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-21 22:46:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-14 10:22:09 +0900 - - Extract range type check functions - - Notes: - Merged: https://github.com/ruby/ruby/pull/7574 - -commit 8286eed20bbc88ed607dfc38b6e0439934671a45 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-14 09:53:41 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-14 09:53:41 +0900 - - Allow testing a different version - -commit 08413f982cc35cbc7692616dd11ae9bf33de42df - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-04-14 08:21:02 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-14 08:21:02 +0900 - - YJIT: Add support for rest with option and splat args (#7698) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit f7d41b9d7bd9de48293909c904e95ebc353fc200 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-14 05:44:01 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-14 05:44:01 +0900 - - Fix compiler warning with compiling on 32 bit - - Fixes this compiler warning: - - vsnprintf.c:1074:43: warning: 'uqval' may be used uninitialized in this function [-Wmaybe-uninitialized] - -commit acc5c746482218ed51e602af88bb5c48f8d557d5 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-04-14 03:37:37 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-14 03:37:37 +0900 - - YJIT: Fix edge and total counts in exit_locations (#7702) - - The stackprof-format raw samples are suffixed with a count (ie. how many - times did the previously recorded side-exit repeat). Previously we were - correctly using this value to increment the :samples count, but not the - :total_samples count or edges. - - This made the stackprof aggregate results incorrect (though any - flamegraphs generated should have been correct, since those only rely on - raw samples). - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit bbe69fba595433d0a7d684b70c0117f49cecadb2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-14 02:54:09 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-14 02:54:09 +0900 - - YJIT: Use an enum to represent counters (#7701) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 2fcd3ea6d8d7d2c9894b7ba0483cb8aab3ce55cf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-14 01:20:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-14 01:20:29 +0900 - - YJIT: Move stack_opnd from Context to Assembler (#7700) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 847813ab132019ae541a163a82ac13055b7a82ed - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-04-14 00:02:09 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-14 00:02:09 +0900 - - [DOC] common.mk deals with various `make` varieties - - Notes: - Merged: https://github.com/ruby/ruby/pull/7690 - - Merged-By: XrXr - -commit ac123f167a364c3d7a43eca78d564e41f6dbb91e - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-04-13 19:11:14 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-04-13 23:36:17 +0900 - - Emit a performance warning when a class reached max variations - - [Feature #19538] - - This new `peformance` warning category is disabled by default. - It needs to be specifically enabled via `-W:performance` or `Warning[:performance] = true` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7708 - -commit 854baee2c936006d7f38ebb27ee577c00afc6249 - Author: Adam Hess <HParker@github.com> - AuthorDate: 2023-04-13 23:07:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-13 23:07:07 +0900 - - YJIT: Add a sampling option to exit tracing (#7693) - - Add a sampling option to trace exits - - Running YJIT with trace exits enabled can make very large metrics files. - This allows us to configure a sample rate to make tracing exits possible - on larger tests. This also updates the documented YJIT options. - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - Co-authored-by: John Hawthorn <john@hawthorn.email> - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 02a7e12b80823919fb614ad3ea6241d5115d14fe - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-13 00:40:34 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-13 21:38:35 +0900 - - Ensure throw data is not set as cause - - [Bug #19593] - - rb_ec_setup_exception did not check if errinfo is a throw_data. This can - cause crashes in code since it is assumed that id_cause is an object. - - We saw a crash in show_cause due to id_cause of errinfo being a - throw_data. It crashes on rb_obj_is_kind_of since it cannot be called on - T_IMEMO objects. - - Unfortunately, we couldn't find a reproduction script, however we - debugged the core dump and rb_ec_setup_exception is the only place where - id_cause is assigned from errinfo without checking if it is a - throw_data. - - ``` - 0x0000556c5708e6dd in sigsegv (sig=11, info=0x7f301befa3f0, ctx=0x7f301befa2c0) at signal.c:964 - 0x00007f301d046420 in <signal handler called> () at /lib/x86_64-linux-gnu/libpthread.so.0 - class_search_class_ancestor (c=139844586301760, cl=<optimized out>) at object.c:810 - rb_obj_is_kind_of (obj=obj@entry=139839221734880, c=139844586301760) at object.c:861 - 0x0000556c56f2f00f in show_cause - (errinfo=errinfo@entry=139838840645160, str=str@entry=139839221730520, opt=139839221730480, highlight=0, reverse=reverse@entry=0, backtrace_limit=backtrace_limit@entry=-1, shown_causes=0x7ffe9d1a2d68) at ./include/ruby/internal/special_consts.h:175 - ``` - - Co-Authored-By: Jean Boussier <byroot@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7696 - -commit 64e503eb62aff0952b655e9a86217e355f786146 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-04-13 15:36:24 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-04-13 19:50:00 +0900 - - avoid seeding - - 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 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7705 - -commit f09638fe25d86c4d619a1f45b1595c8a30c54cc4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-13 18:34:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-13 18:51:18 +0900 - - [ruby/time] Expose Time::VERSION - - https://github.com/ruby/time/commit/32793b56b7 - -commit cf77f7b5e72ed33516b93b5a20427e7a64475bef - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-24 17:16:34 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-13 18:51:18 +0900 - - [ruby/time] Bump version to 0.2.2 - - https://github.com/ruby/time/commit/5f080cf700 - -commit 8b924ebdf25fd77250d6ab69f162a2ab7fc888fc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 14:14:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-13 18:49:14 +0900 - - [ruby/tempfile] Expose Tempfile::VERSION - - https://github.com/ruby/tempfile/commit/6aa1f37dc4 - -commit 84d11498c2198659ae2771dcdad09b1a4a4769d0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 14:09:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-13 18:48:55 +0900 - - [ruby/shellwords] Expose Shellwords::VERSION - - https://github.com/ruby/shellwords/commit/e38b8b026a - -commit 61bd69470a68354b77fad65119c56cbf19f2c152 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 13:14:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-13 18:47:40 +0900 - - [ruby/open-uri] Expose OpenURI::VERSION - - https://github.com/ruby/open-uri/commit/666768d960 - -commit 76aaaf6434752b5dc407878a5268892f859b2bf5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-13 18:09:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-13 18:47:22 +0900 - - [ruby/un] Expose UN::VERSION - - https://github.com/ruby/un/commit/47bcad1804 - -commit de023b68aa32240d08e420f549edcb8df7d8452c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-13 15:43:34 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-13 18:08:08 +0900 - - Disable all warning categories other than `RB_WARN_CATEGORY_ALL_BITS` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7706 - -commit 0ca9a4e743efb180d7d831a6a69fc9af2cf5e61c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-13 14:55:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-13 17:38:46 +0900 - - [rubygems/rubygems] Extract alias variables for long name class - - https://github.com/rubygems/rubygems/commit/33caea928e - -commit 1f0974e654bf3c8a7dd321ae898174d942975686 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-13 14:49:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-13 17:38:45 +0900 - - [rubygems/rubygems] Downcase camel like cases of instance variable - - https://github.com/rubygems/rubygems/commit/4eaac27107 - -commit 80fa9b04042bd28f9c02364547de4e2f6f408bdd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-12 16:25:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-13 14:09:22 +0900 - - Fix declaration of `rb_rjit_entry_stub_hit` in rjit_c.c - - Notes: - Merged: https://github.com/ruby/ruby/pull/7695 - -commit 3612b1bed8b4a93fd85d4be448174d5c6ef4f473 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-03 17:26:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-13 14:07:27 +0900 - - [Feature #19590] Show the invalid clock argument - - Include the failed clock argument in the error message from - `Process.clock_gettime` and `Process.clock_getres`. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7687 - -commit 86db7a1cb87bc7cde49df2bac82d91ccdc514509 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-13 13:28:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-13 13:28:47 +0900 - - [DOC] Fix typos - -commit be08e1b14c25979f8727edde70b37fc48b808cac - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-04-13 08:32:07 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-04-13 09:48:34 +0900 - - RJIT: argc check in known cfuncs - - Notes: - Merged: https://github.com/ruby/ruby/pull/7697 - -commit 0ce2bdc76dd17aa3d42a352a6244c87a51e7606d - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-04-13 08:22:22 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-04-13 09:48:34 +0900 - - YJIT: Fix missing argc check in known cfuncs - - Previously we were missing a compile-time check that the known cfuncs - receive the correct number of arguments. - - We noticied this because in particular when using ARGS_SPLAT, which also - wasn't checked, YJIT would crash on code which was otherwise correct - (didn't raise exceptions in the VM). - - This still supports vararg (argc == -1) cfuncs. I added an additional - assertion that when we use the specialized codegen for one of these - known functions that the argc are popped off the stack correctly, which - should help ensure they're implemented correctly (previously the crash - was usually observed on a future `leave` insn). - - [Bug #19595] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7697 - -commit c8d8207aea7085b611c5f27016f1e55b4396d759 - Author: Marcin Rozmus <marcin.rozmus97@gmail.com> - AuthorDate: 2023-04-13 02:18:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-13 05:27:39 +0900 - - [rubygems/rubygems] Fix broken hyperlinks in bundle cache documentation - - https://github.com/rubygems/rubygems/commit/1ff3e7450a - -commit 00bbd31edb068f6ee4670df53ae66c4ba0ecb9bf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-13 04:11:44 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-13 04:11:44 +0900 - - YJIT: Let Assembler own Context (#7691) - - * YJIT: Let Assembler own Context - - * Update a comment - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - --------- - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 0ac3f2c20e50c22d298238f602f25f84248ac7a5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-12 14:54:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-12 18:35:32 +0900 - - [Bug #19587] Fix `reset_match_cache` arguments - - Notes: - Merged: https://github.com/ruby/ruby/pull/7694 - -commit 1b697d7cb5eac5b7a05f659fbbde56a73d81d704 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-12 12:48:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-12 18:35:32 +0900 - - Constify - - Notes: - Merged: https://github.com/ruby/ruby/pull/7694 - -commit 2e1a95b5699ed1151f90659e40eeb44c4330a882 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-12 12:12:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-12 18:35:32 +0900 - - Extract `bsearch_cache_index` function - - Notes: - Merged: https://github.com/ruby/ruby/pull/7694 - -commit f06a48a92af602e60ab6ae155345420efa3d15d3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-12 15:59:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-12 18:26:05 +0900 - - [rubygems/rubygems] Close the server for test - - https://github.com/rubygems/rubygems/commit/bf5e82fd14 - -commit 851344965ab9917af6caab39ac065e0f0d70b489 - Author: Ashley Ellis Pierce <anellis12@gmail.com> - AuthorDate: 2023-03-30 02:20:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 12:00:25 +0900 - - Ensure api_key is sent if basic auth not provided on webauthn_verification_url - - Co-authored-by: Jenny Shen <jenny.shen@shopify.com> - -commit 1b1485ae4dd25fd4a8f2ee20608b11f5b2a486f8 - Author: Eric Herscovich <eric.herscovich@shopify.com> - AuthorDate: 2023-03-21 03:44:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:59:18 +0900 - - Add message for otp bypass - - Update tests - - Fix wording of message - -commit b909ca94bde1d547467ddf7bd5431a3399b542ee - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-02-22 02:37:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:58:03 +0900 - - Terminate interaction after wait for otp thread completes to support jruby - -commit c7a8d63df84c4884cb30cc58292ec36efabfabbb - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-02-17 06:14:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:57:43 +0900 - - Terminate interaction when rescuing WebauthnVerificationError during wait_for_otp - - Co-authored-by: Betty Li <makewithbetty@gmail.com> - -commit cd60113faa41384cba31781eeb8fa51ea3ed2355 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-02-16 00:52:32 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:57:15 +0900 - - Use Webauthn Listener in wait_for_otp - -commit b6e860ba1bae04a1ce269a40ef4731fe52855a16 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-02-16 00:46:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:57:11 +0900 - - Add wait for webauthn otp when fetching otp - - Co-authored-by: Jacques Chester <jacques.chester@shopify.com> - -commit 774d1f1a0067e16a3dfdd0aed4bae66143de2140 - Author: Ashley Ellis Pierce <anellis12@gmail.com> - AuthorDate: 2023-01-24 06:21:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:56:33 +0900 - - Merge lines - -commit 096f6eec3e6be23991e752a6ce56a2efca7a47c9 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-02-28 00:07:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:51:07 +0900 - - [rubygems/rubygems] Refactor Webauthn listener response - Makes the response class a wrapper around Net::HTTPResponse - Builds a Net::HTTPResponse upon initialization - to_s returns a string representation of the response to send - Adds a Socket Responder class to send responses given a socket - - https://github.com/rubygems/rubygems/commit/7513c220b6 - - Co-authored-by: Jacques Chester <jacques.chester@shopify.com> - -commit ef85b6de42c9d73451eb392178e1faa95b002edd - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-02-22 02:48:37 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:51:06 +0900 - - [rubygems/rubygems] Add access control headers for all requests to allow RubyGems.org to render the response - - https://github.com/rubygems/rubygems/commit/22b329eb60 - -commit 353f9adcccc9928eb6fc0a7b581d31a1f5ca2d7b - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-02-16 13:36:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:51:05 +0900 - - [rubygems/rubygems] Add otp command tests - - https://github.com/rubygems/rubygems/commit/c494112063 - -commit 6e7bf0677d74a721e3be95e7e60d3033228bb73d - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-02-16 00:51:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:51:04 +0900 - - [rubygems/rubygems] Add WebauthnListener class - - https://github.com/rubygems/rubygems/commit/d42ddbb73c - - Co-authored-by: Ashley Ellis Pierce <anellis12@gmail.com> - Co-authored-by: Jacques Chester <jacques.chester@shopify.com> - -commit 27322e51a757f0ac6d1fd66802e02978def9904f - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-02-16 00:50:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:51:04 +0900 - - [rubygems/rubygems] Add MockBrowser helper class - - https://github.com/rubygems/rubygems/commit/2d763cfd47 - - Co-authored-by: Jacques Chester <jacques.chester@shopify.com> - -commit 354a5c646e12aa5fbed94f818c3e4b72f05735e3 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-02-16 00:49:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:51:03 +0900 - - [rubygems/rubygems] Add WebauthnVerificationError Exception - - https://github.com/rubygems/rubygems/commit/932c111f2c - -commit 332c4b672637c832bfa4ade64994b28de9fa6f64 - Author: Jenny Shen <jenny.shen@shopify.com> - AuthorDate: 2023-02-16 00:48:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:51:03 +0900 - - [rubygems/rubygems] Add WebauthnListener response classes - - https://github.com/rubygems/rubygems/commit/0e9a26acb1 - -commit ea95ec5443dae90800c0bd33274733323129b5f1 - Author: Ashley Ellis Pierce <anellis12@gmail.com> - AuthorDate: 2022-12-23 23:34:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:51:02 +0900 - - [rubygems/rubygems] Clarify message - - https://github.com/rubygems/rubygems/commit/d94173be49 - -commit 6275284f025dea81f4fdca8c80534d27263b003a - Author: Ashley Ellis Pierce <anellis12@gmail.com> - AuthorDate: 2022-12-21 06:01:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-12 11:51:01 +0900 - - [rubygems/rubygems] Ask user to otp at webauthn verification url - - https://github.com/rubygems/rubygems/commit/004eadb0c5 - -commit 57bc4cfa283582f7c4c7013bb8a979e0baf3236c - Author: Alan Wu <alanwu@ruby-lang.org> - AuthorDate: 2023-04-12 08:43:47 +0900 - Commit: Alan Wu <alanwu@ruby-lang.org> - CommitDate: 2023-04-12 08:43:47 +0900 - - [DOC] Remove obsolete win32/.document - - The README file moved in f499c81b01b5c4b7a2ce11d6467d793669d67695. - -commit c767e6f0c272a83a046c05dffc01409ae8f16e11 - Author: Alan Wu <alanwu@ruby-lang.org> - AuthorDate: 2023-04-12 08:35:30 +0900 - Commit: Alan Wu <alanwu@ruby-lang.org> - CommitDate: 2023-04-12 08:35:30 +0900 - - YJIT: Fix build on A64 - - Typo fix for the last commit (1432b37) - -commit 1432b3768aad4cfd95d584077f76c617dcc62978 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-12 06:59:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-12 06:59:21 +0900 - - YJIT: Fix a compilation warning in x86_64 - - This is used only for arm64's cb.jmp_ptr_bytes(). - -commit 91dcce5ed1e44ca2e64936b66699fc8c1c092f5c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-11 23:14:45 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-12 04:02:44 +0900 - - Change max_iv_count to type attr_index_t - - max_iv_count is calculated from next_iv_index of the shape, which is of - type attr_index_t, so we can also make max_iv_count of type - attr_index_t. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7689 - -commit ce99e50ede4e4981d7b008bbe17f72fa351a5978 - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-04-05 02:18:13 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-04-12 02:47:58 +0900 - - Move `catch_except_p` to `compile_data` - - The `catch_except_p` flag is used for communicating between parent and - child iseq's that a throw instruction was emitted. So for example if a - child iseq has a throw in it and the parent wants to catch the throw, we - use this flag to communicate to the parent iseq that a throw instruction - was emitted. - - This flag is only useful at compile time, it only impacts the - compilation process so it seems to be fine to move it from the iseq body - to the compile_data struct. - - Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7652 - -commit b4571097df4a6bd848f1195026d82a92f3a7f9d8 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-11 22:16:52 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-12 00:25:12 +0900 - - Enable 5 size pools on 32 bit systems - - This commit will allow 32 bit systems to take advantage of VWA. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7688 - -commit 7297374c5e3dc2b66ee55d918b3f933e78dd23fd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-12 00:02:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-12 00:02:52 +0900 - - YJIT: Reduce paddings if --yjit-exec-mem-size <= 128 on arm64 (#7671) - - * YJIT: Reduce paddings if --yjit-exec-mem-size <= 128 - - on arm64 - - * YJIT: Define jmp_ptr_bytes on CodeBlock - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 8c360ce713f57d4177de833297364f6f6d950420 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-04-11 17:55:46 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-04-11 23:56:14 +0900 - - hash.c: Fix hash_iter_lev_dec corrupting shape - - [Bug #19589] - - When decrementing `iter_lev` from `65` to `64` the flags would be - corrupted, causing the shape_id to be invalid. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7686 - -commit 7b230bc8486e7d451113c3c0301adcecfc09b893 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-11 06:09:13 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-11 21:31:56 +0900 - - [DOC] Documentation for flags of RObject - - Notes: - Merged: https://github.com/ruby/ruby/pull/7684 - -commit 0196c8527b619b685399e9a3ce6b5b4c7e30368a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-11 19:15:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-11 19:15:25 +0900 - - Removed file that is part of d89cc317c642848008f5b17a82196d25ddcdf124 - -commit d89cc317c642848008f5b17a82196d25ddcdf124 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-11 14:56:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-11 19:12:28 +0900 - - util/rubocop -A --only Style/NumericLiteralPrefix - -commit 1ff14a855ab2389017a0de958702644233dbeb9f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-11 08:35:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-11 08:35:48 +0900 - - YJIT: Avoid using a register for unspecified_bits (#7685) - - Fix [Bug #19586] - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 4af9bd52cbb8cff7d149a8565012ab1153a4b5b1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-11 03:22:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-11 03:22:12 +0900 - - Get rid of a breakpoint left in parse.y - -commit 2e50c07e2315e7e66acc567496f70c3e0ff895b2 - Author: Šimon Lukašík <isimluk@fedoraproject.org> - AuthorDate: 2023-04-10 21:20:42 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-10 21:20:42 +0900 - - [DOC] The Document-method hint is needed only in C files - - 'Document-method' string in C file has a special treatment. In Ruby source file, - however, it is considered to be part of the documentation. - - Note Numeric#size was migrated from C to Ruby, in 3208a5df2dfb429752a130a36274464e9924cf44 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7682 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit dc5f9387654a89ee18384ddec1bde5b44f7c238d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-10 15:23:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-10 15:23:44 +0900 - - Prefer `write_warn` over `write_warn2` with a string literal - - Notes: - Merged: https://github.com/ruby/ruby/pull/7681 - -commit c30cab8ce4d2ab21ef75e2a3218cb76b21d78407 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-10 15:13:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-10 15:13:26 +0900 - - [Bug #19570] Propagate message encoding to decorated message - -commit 917e7eb50f5371892de9af13ba7d4134bb9a21b4 - Author: Wai-Wai Ng <waiwai95@gmail.com> - AuthorDate: 2023-04-10 01:09:03 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-10 01:09:03 +0900 - - [DOC] Correct docs for Comparable - - Notes: - Merged: https://github.com/ruby/ruby/pull/7680 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 038f9ade3c4d965415e4956561975454cf9eeb21 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-09 22:47:26 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-09 22:47:26 +0900 - - Use tools appropriate with CC - - To get rid of mysterious errors such as: - - ``` - /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/nm: error: libruby.3.3-static.a(/): The end of the file was unexpectedly encountered - ``` - - and - - ``` - ld: warning: ignoring file ../../libruby.3.3-static.a, building for macOS-x86_64 but attempting to link with file built for macOS-x86_64 - Undefined symbols for architecture x86_64: - "_rb_rational_num", referenced from: - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7678 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit f7c8d3bf96e7e56f7a4bef4fe312f114b12004ef - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-04-09 22:41:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-09 22:44:12 +0900 - - [ruby/irb] Bump version to 1.6.4 - (https://github.com/ruby/irb/pull/560) - - https://github.com/ruby/irb/commit/01328da9b6 - -commit 671cfc20000db024f2aeaf602b1a77895c819abc - Author: HoNooD <honood@gmail.com> - AuthorDate: 2023-03-18 02:04:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-09 03:54:01 +0900 - - [ruby/bigdecimal] fix: typo in document comments of `f_BigDecimal` function - - https://github.com/ruby/bigdecimal/commit/13abe1fd78 - -commit 8ec95c6074e3bff60001c4792db63747b4a12e89 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-31 14:35:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-09 03:53:28 +0900 - - [ruby/bigdecimal] Remove set but unused variable - - This `prec` has not been used since https://github.com/ruby/bigdecimal/commit/1f5c46dbdd1c. - - https://github.com/ruby/bigdecimal/commit/08a0ad563d - -commit 957595f2182ee9002404258f5e495528f2285ed6 - Author: Kasumi Hanazuki <kasumi@rollingapple.net> - AuthorDate: 2023-04-08 21:25:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-08 23:16:59 +0900 - - [ruby/resolv] Do not compress domain name in SRV RDATA - - [RFC2782] prohibits use of name compression for the target host name - in the RDATA of a SRV record. - - [RFC2782]: https://datatracker.ietf.org/doc/rfc2782/ - - Closes: https://github.com/ruby/resolv/issues/29 - - https://github.com/ruby/resolv/commit/ac85724e17 - -commit e7f77e1e8979047b3ec2944d0aea7511282715d0 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-08 19:11:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-08 19:11:50 +0900 - - [ruby/irb] Simplify command method definition - (https://github.com/ruby/irb/pull/559) - - * Remove unnecessary command argument generation code - - Now that all the supported Ruby versions handle splat args and splat kwargs, - we don't need that args generation code anymore. - - * Remove unused command definition code - - If we look at `@EXTEND_COMMANDS`, all commands are defined in a file, which - means the `if load_file` branch is always executed. Therefore we can drop - the else branch of that condition. - - * Avoid defining unnecessary command methods - - There's no need to define another command method just to call `Command.execute`. - -commit 08324ab9eb97535b5994450186c5048be3c0cd62 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-08 12:47:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-08 12:47:27 +0900 - - Include `--no-llvm-bc` option in `NM` macro only if usable - - Notes: - Merged: https://github.com/ruby/ruby/pull/7677 - -commit a9bfb64153ae0a07d498d0976d335b65515fd1b1 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-04-07 13:13:10 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-04-08 01:49:15 +0900 - - Expose rb_sym_to_proc via RJIT - - This is needed for getblockparamproxy - - Notes: - Merged: https://github.com/ruby/ruby/pull/7673 - -commit ac8a16237c727ae2a1446ef6dc810d0e750971fb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-07 23:13:56 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-07 23:13:56 +0900 - - [Bug #19563] Yield words separators per lines - - So that newlines across a here-doc terminator will be separated - tokens. - - Cf. https://github.com/ruby/irb/pull/558 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7675 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 4df7c3946ab8da8af4c3c0e38a41ab3bd890fc7f - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-04-05 03:52:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-07 22:53:00 +0900 - - [rubygems/rubygems] Remove one fallback to full indexes on big gemfiles - - If Gemfile has a lot of dependencies, we have an optimization that uses - the full index in that case, assuming it's going to be faster. - - I think this is an old optimization that predates compact index API - times, I believe we no longer need it these days. - - Also, since a few releases ago we check for circular dependencies when - resolving by looping through all versions of each name and removing - those that have circular dependencies that would trip up the resolver. - - This loop becomes actually very slow when full indexes are used because - to find dependencies of a gemspec, we need to explicitly fetch the - marshaled gemspec (`gemspec.rz` endpoint) for it, so the optimization - has the opposite effect of making things very slow. - - https://github.com/rubygems/rubygems/commit/2f46289bd3 - -commit f8115ec727b6a63305d143c2869678c3a8210fa7 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-04-07 20:03:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-07 20:03:28 +0900 - - [ruby/irb] Fix RubyLex's heredoc_with_hembexpr test to avoid ripper - tokenizing issue - (https://github.com/ruby/irb/pull/558) - - https://github.com/ruby/irb/commit/f68e891ed1 - -commit 250e97c0fba48d1f87ccecb1b1e1b4bd2a30c388 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-07 09:15:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-07 14:13:05 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/FormatString - - https://github.com/rubygems/rubygems/commit/132a56569d - -commit 4adcfc8cd7a17593a6590025da2b03eebf4fd63c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-07 12:25:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-07 13:42:58 +0900 - - [Bug #19584] [DOC] Tweek description of `rb_gc_register_address` - -commit f99af439805fe51b38aa1cf79f9c657f857510f4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-05 23:48:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-07 13:42:48 +0900 - - [Bug#19161] Detect thread local storage specifier - - Checking by `__STDC_VERSION__` is unreliable because old gcc 4.8 - supports `-std=gnu11` option but does not implement `_Thread_local`. - Check the implementation directly instead. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7669 - -commit 75a2dff0e0ca310f82feb694e8b21655854df191 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-07 11:54:25 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-07 12:09:08 +0900 - - [ruby/openssl] Register global variables before assignment - - https://github.com/ruby/openssl/commit/98099d3796 - -commit e13575bb7938e9e5b6a79bfca1b3793123f479da - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-07 11:43:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-07 11:53:36 +0900 - - [Bug #19584] Register global variables before assignment - -commit 5f8ebcada099351acbc22db264e7cd3773c2bdc4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-07 11:21:08 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-07 11:21:08 +0900 - - [Bug #19584] Register global variable address before assignment - -commit fb822076d79339427648cb9eacf76528f827427e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-06 11:33:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-07 08:33:20 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/LineEndConcatenation - - https://github.com/rubygems/rubygems/commit/67ece7b8b6 - -commit bffadcd6d46ccfccade79ce0efb60ced8eac4483 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-07 02:35:25 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-07 02:35:25 +0900 - - Add guard to compaction test in WeakMap - - Some platforms don't support compaction, so we should skip this test. - -commit bccec7fb468ad977be75e7e4c2644b4ea845ab0c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-06 23:25:59 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-07 02:19:19 +0900 - - Fix crash in rb_gc_register_address - - [Bug #19584] - - Some C extensions pass a pointer to a global variable to - rb_gc_register_address. However, if a GC is triggered inside of - rb_gc_register_address, then the object could get swept since it does - not exist on the stack. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7670 - -commit 89bdf6e94cb36567478c509722fe98069402fb8e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-07 00:34:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-07 00:34:58 +0900 - - YJIT: Stack temp register allocation for arm64 (#7659) - - * YJIT: Stack temp register allocation for arm64 - - * Update a comment - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - * Update comments about assertion - - * Update a comment - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - --------- - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 2a34bcaa1023c5f0b41774d8153b9625a4233c04 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-03-02 20:51:53 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-04-06 19:07:16 +0900 - - Update VPATH for socket, & dependencies - - The socket extensions rubysocket.h pulls in the "private" include/gc.h, - which now depends on vm_core.h. vm_core.h pulls in id.h - - when tool/update-deps generates the dependencies for the makefiles, it - generates the line for id.h to be based on VPATH, which is configured in - the extconf.rb for each of the extensions. By default VPATH does not - include the actual source directory of the current Ruby so the - dependency fails to resolve and linking fails. - - We need to append the topdir and top_srcdir to VPATH to have the - dependancy picked up correctly (and I believe we need both of these to - cope with in-tree and out-of-tree builds). - - I copied this from the approach taken in - https://github.com/ruby/ruby/blob/master/ext/objspace/extconf.rb#L3 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7393 - -commit 026321c5b976c5e95731046b94555b1226198be4 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-18 00:51:16 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-04-06 19:07:16 +0900 - - [Feature #19474] Refactor NEWOBJ macros - - NEWOBJ_OF is now our canonical newobj macro. It takes an optional ec - - Notes: - Merged: https://github.com/ruby/ruby/pull/7393 - -commit 879cda98a4cdce91d736ea9ba81168effe090718 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-17 23:14:53 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-04-06 19:07:16 +0900 - - Remove dependancy of vm_core.h on shape.h - - so that now shape can happily include gc.h - - Notes: - Merged: https://github.com/ruby/ruby/pull/7393 - -commit d91a82850ac337c80807743bc0841369a8a1748c - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-17 22:32:51 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-04-06 19:07:16 +0900 - - Pull the shape tree out of the vm object - - Notes: - Merged: https://github.com/ruby/ruby/pull/7393 - -commit b0297feb1f487d466ad1186898b4e36209fcd59e - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-17 20:07:24 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-04-06 19:07:16 +0900 - - Remove newobj_of_cr - - We can just make newobj_of take a ractor - - Notes: - Merged: https://github.com/ruby/ruby/pull/7393 - -commit f269fae07e68117cd4ab42d889136ea37e6d3913 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-06 16:36:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 16:36:09 +0900 - - Revert "[ruby/syntax_suggest] Introduce binstubs to set RUBYOPT for development" - - This reverts commit d2eef4b7867578df302cfa9d7c97eebbef8d9ee4. - -commit 70371aa0713d5de190fcd7e4d42dbca6bfe1da60 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-06 16:25:05 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 16:30:00 +0900 - - Revert accidentally commit of wrong file - - Revert "[ruby/syntax_suggest] Remove unnecessary `--color` option" - - This reverts commit 588dd44d418d56dce3f2a388c4021d11f9aa4324. - -commit 6ca1f3eec4222924c7e23642a68b512105b7ef80 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-06 16:15:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 16:15:41 +0900 - - Load only SyntaxSuggest::VERSION for version check - -commit 7ab640d9dd27eefdec138a0cf611072a76cc6cba - Author: schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-03-18 06:07:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 15:49:26 +0900 - - v1.0.4 - -commit 8d72d6159c75f2ed40510d7721c6e5fbdb1976af - Author: schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-03-17 09:44:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 15:47:04 +0900 - - v1.0.3 - - Fix a CI error and add a test to ensure we're testing the current version: - - ``` - Run bundle exec rake test - bundler: failed to load command: rake (/home/runner/work/syntax_suggest/syntax_suggest/vendor/bundle/ruby/3.2.0/bin/rake) - /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/runtime.rb:309:in `check_for_activated_spec!': You have already activated syntax_suggest 1.0.2, but your Gemfile requires syntax_suggest 1.0.3. Since syntax_suggest is a default gem, you can either remove your dependency on it or try updating to a newer version of bundler that supports syntax_suggest as a default gem. (Gem::LoadError) - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/runtime.rb:25:in `block in setup' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/spec_set.rb:138:in `each' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/spec_set.rb:138:in `each' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/runtime.rb:24:in `map' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/runtime.rb:24:in `setup' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler.rb:151:in `setup' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/setup.rb:20:in `block in <top (required)>' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/ui/shell.rb:136:in `with_level' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/ui/shell.rb:88:in `silence' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/setup.rb:20:in `<top (required)>' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/cli/exec.rb:56:in `require_relative' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/cli/exec.rb:56:in `kernel_load' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/cli/exec.rb:23:in `run' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/cli.rb:483:in `exec' - from /opt/hostedtoolcache/Ruby/3.2.1/x64/lib/ruby/gems/3.2.0/gems/bundler-2.3.14/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run' - ``` - -commit d2eef4b7867578df302cfa9d7c97eebbef8d9ee4 - Author: schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-03-17 10:45:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 15:45:31 +0900 - - [ruby/syntax_suggest] Introduce binstubs to set RUBYOPT for development - - Because `syntax_suggest` is a default gem you can get conflicts when working on this project with Ruby 3.2+. To fix conflicts you can disable loading `syntax_suggest` as a default gem by using then environment variable `RUBYOPT` with the value `--disable=syntax_suggest`. The `RUBYOPT` environment variable works the same as if we had entered those flags directly in the ruby cli (i.e. `ruby --disable=syntax_suggest` is the same as `RUBYOPT="--disable=syntax_suggest" ruby`). It's needed because we don't always directly execute Ruby and RUBYOPT will be picked up when other commands load ruby (`rspec`, `rake`, or `bundle` etc.). - - There are some binstubs that already have this done for you. Instead of running `bundle exec rake` you can run `bin/rake`. Binstubs provided: - - - `bin/rake` - - `bin/rspec` - - https://github.com/ruby/syntax_suggest/commit/342093706d - -commit d511e6960f4b02731840d4bab381dec73e2c391f - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-03-17 08:52:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 15:45:30 +0900 - - [ruby/syntax_suggest] The annotation must end with a new line - - syntax_suggest did not work great when there is no new line at the end - of the input file. - - Input: - ``` - def foo - end - end # No newline at end of file - ``` - - Previous output: - ``` - $ ruby test.rb - test.rb: --> test.rb - Unmatched `end', missing keyword (`do', `def`, `if`, etc.) ? - > 1 def foo - > 2 end - > 3 end # No newline at end of filetest.rb:3: syntax error, unexpected `end' (SyntaxError) - end # No newline at end of file - ^~~ - ``` - - Note that "test.rb:3: ..." is appended to the last line of the - annotation. - - This change makes sure that the annotation ends with a new line. - - New output: - ``` - $ ruby test.rb - test.rb: --> test.rb - Unmatched `end', missing keyword (`do', `def`, `if`, etc.) ? - > 1 def foo - > 2 end - > 3 end # No newline at end of file - test.rb:3: syntax error, unexpected `end' (SyntaxError) - end # No newline at end of file - ^~~ - ``` - - https://github.com/ruby/syntax_suggest/commit/db4cf9147d - -commit 63ea6b0cf2b7fd27e22dc7b468fe65ee2c79b23a - Author: schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-03-10 05:13:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 15:45:29 +0900 - - [ruby/syntax_suggest] Rollback comment indentation behavior - - Originally I fixed https://github.com/ruby/syntax_suggest/pull/177 by making the process of comment removal indentation aware. The next commit is the more general fix and means we don't need to carry that additional logic/overhead. - - Also: Update syntax via linter - -commit 2acbcec056f54df9b4d98d4d15b1e9f612ac1432 - Author: schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-03-09 09:30:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 15:45:29 +0900 - - [ruby/syntax_suggest] Add comments and refactor AroundBlockScan methods - - https://github.com/ruby/syntax_suggest/commit/cecd12292c - -commit 5487ee4fe8b1311d42367969860468e48667cc87 - Author: schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-03-09 08:44:58 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 15:45:28 +0900 - - [ruby/syntax_suggest] Fix sibling bug to #177 - - While #177 is reported as being caused by a comment, the underlying behavior is a problem due to the newline that we generated (from a comment). The prior commit fixed that problem by preserving whitespace before the comment. That guarantees that a block will form there from the frontier before it will be expanded there via a "neighbors" method. Since empty lines are valid ruby code, it will be hidden and be safe. - - ## Problem setup - - This failure mode is not fixed by the prior commit, because the indentation is 0. To provide good results, we must make the algorithm less greedy. One heuristic/signal to follow is developer added newlines. If a developer puts a newline between code, it's more likely they're unrelated. For example: - - ``` - port = rand(1000...9999) - stub_request(:any, "localhost:#{port}") - - query = Cutlass::FunctionQuery.new( - port: port - ).call - - expect(WebMock).to have_requested(:post, "localhost:#{port}"). - with(body: "{}") - ``` - - This code is split into three chunks by the developer. Each are likely (but not guaranteed) to be intended to stand on their own (in terms of syntax). This behavior is good for scanning neighbors (same indent or higher) within a method, but bad for parsing neighbors across methods. - - ## Problem - - Code is expanded to capture all neighbors, and then it decreases indent level which allows it to capture surrounding scope (think moving from within the method to also capturing the `def/end` definition. Once the indentation level has been increased, we go back to scanning neighbors, but now neighbors also contain keywords. - - For example: - - ``` - 1 def bark - 2 - 3 end - 4 - 5 def sit - 6 end - ``` - - In this case if lines 4, 5, and 6 are in a block when it tries to expand neighbors it will expand up. If it stops after line 2 or 3 it may cause problems since there's a valid kw/end pair, but the block will be checked without it. - - TLDR; It's good to stop scanning code after hitting a newline when you're in a method...it causes a problem scanning code between methods when everything inside of one of the methods is an empty line. - - In this case it grabs the end on line 3 and since the problem was an extra end, the program now compiles correctly. It incorrectly assumes that the block it captured was causing the problem. - - ## Extra bit of context - - One other technical detail is that after we've decided to stop scanning code for a new neighbor block expansion, we look around the block and grab any empty newlines. Basically adding empty newlines before of after a code block do not affect the parsing of that block. - - ## The fix - - Since we know that this problem only happens when there's a newline inside of a method and we know this particular failure mode is due to having an invalid block (capturing an extra end, but not it's keyword) we have all the metadata we need to detect this scenario and correct it. - - We know that the next line above our block must be code or empty (since we grabbed extra newlines). Same for code below it. We can count all the keywords and ends in the block. If they are balanced, it's likely (but not guaranteed) we formed the block correctly. If they're imbalanced, look above or below (depending on the nature of the imbalance), check to see if adding that line would balance the count. - - This concept of balance and "leaning" comes from work in https://github.com/ruby/syntax_suggest/pull/152 and has proven useful, but not been formally introduced into the main branch. - - ## Outcome - - Adding this extra check introduced no regressions and fixed the test case. It might be possible there's a mirror or similar problem that we're not handling. That will come out in time. It might also be possible that this causes a worse case in some code not under test. That too would come out in time. - - One other possible concern to adding logic in this area (which is a hot codepath), is performance. This extra count check will be performed for every block. In general the two most helpful performance strategies I've found are reducing total number of blocks (therefore reducing overall N internal iterations) and making better matches (the parser to determine if a close block is valid or not is a major bottleneck. If we can split valid code into valid blocks, then it's only evaluated by the parser once, where as invalid code must be continuously re-checked by the parser until it becomes valid, or is determined to be the cause of the core problem. - - This extra logic should very rarely result in a change, but when it does it should tend to produce slightly larger blocks (by one line) and more accurate blocks. - - Informally it seems to have no impact on performance: - - `` - This branch: - DEBUG_DISPLAY=1 bundle exec rspec spec/ --format=failures 3.01s user 1.62s system 113% cpu 4.076 total - ``` - - ``` - On main: - DEBUG_DISPLAY=1 bundle exec rspec spec/ --format=failures 3.02s user 1.64s system 113% cpu 4.098 total - ``` - - https://github.com/ruby/syntax_suggest/commit/13739c6946 - -commit e5236471c3ce194199a6ceb70012eb2ca243407e - Author: schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-03-08 23:51:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 15:45:28 +0900 - - [ruby/syntax_suggest] Preserve whitespace in front of comments - - When removing comments I previously replaced them with a newline. This loses some context and may affect the order of the indent search which in turn affects the final result. By preserving whitespace in front of the comment, we preserve the "natural" indentation order of the line while also allowing the parser/lexer to see and join naturally consecutive (method chain) lines. - - close https://github.com/ruby/syntax_suggest/pull/177 - -commit 33cfd262fcfe65737b6d4cde416a24cd81406885 - Author: schneems <richard.schneeman+foo@gmail.com> - AuthorDate: 2023-03-08 08:49:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 15:45:27 +0900 - - [ruby/syntax_suggest] Handle alias already exists when debugging - - When `tmp/alias` already exists, I'm now getting phantom folders in the directory pointing at older aliases which is distracting/confusing. By checking and removing that alias before symlinking we can prevent this strange behavior (possibly caused by newer Mac OS?). - -commit 588dd44d418d56dce3f2a388c4021d11f9aa4324 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-08 22:52:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 15:45:27 +0900 - - [ruby/syntax_suggest] Remove unnecessary `--color` option - - It is enabled automatically if possible. Forcing this option makes - https://github.com/rspec/rspec-core/pull/3017 useless. - - https://github.com/ruby/syntax_suggest/commit/8e7141b472 - -commit 061f5f4374a20f1ea1234a1bc204862c5fda1fed - Author: Marc-Andre Lafortune <github@marc-andre.ca> - AuthorDate: 2023-04-06 06:12:43 +0900 - Commit: Victor Shepelev <zverok.offline@gmail.com> - CommitDate: 2023-04-06 15:24:38 +0900 - - Add missing test for Data.initialize - - Notes: - Merged: https://github.com/ruby/ruby/pull/7666 - -commit 69460791ccdacef30eebb72c7a976f986292f48d - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2019-09-11 22:33:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 13:07:16 +0900 - - [rubygems/rubygems] Improve comment explaining the neccessity of `write_default_spec` method. - - The intention is not obvious from the commit log and it might avoid - temptation to remove the method without further consideration. - - https://github.com/rubygems/rubygems/commit/8e17c50f64 - -commit f3d69bed626e3326959dd62dbcc9ac4510e42b2f - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-17 01:45:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 13:07:16 +0900 - - [rubygems/rubygems] Fix resolver hangs when dealing with an incomplete lockfile - - While working on locking multiple platforms by default, I got an - infinite resolution loop in one of our resolver specs. - - The culprit ended up being that when dealing with lockfile specs with - incomplete dependencies (spec appears in lockfile, but its dependencies - don't), those specs were not being properly expired and that tripped up - resolution. - - The issue for some reason only manifests when dealing with multiple - lockfile platforms, that's why it only manifested when working on - locking multiple platforms by default. - - https://github.com/rubygems/rubygems/commit/4ca72913bb - -commit c257380965bcf93c9bef330faa6762ed0be494b5 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-23 20:31:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 13:07:16 +0900 - - Revert "Refactor incomplete specs handling" - - This reverts commit 69580f8b72f41c58cae57d1ada4db909922b3891. - -commit 192a3a6bfb6b69d1673ffa918bc78184de871c65 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-23 20:31:07 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 13:07:16 +0900 - - [rubygems/rubygems] Revert "Reuse `SpecSet#materialize` logic" - - This reverts commit https://github.com/rubygems/rubygems/commit/a20585b4512d. - - https://github.com/rubygems/rubygems/commit/aa9102659e - -commit b5f243291742886a1280277c2ff954177b4f50a7 - Author: Vít Ondruch <vondruch@redhat.com> - AuthorDate: 2019-09-11 22:39:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-06 13:07:16 +0900 - - [rubygems/rubygems] Use TestCase#util_spec instead of custom code. - - https://github.com/rubygems/rubygems/commit/74d485ff1e - -commit 7b27ad9ad36dbfd2ec6571b0ed15fbc4aa65d460 - Author: Adam Hess <HParker@github.com> - AuthorDate: 2023-04-06 08:11:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-06 08:11:04 +0900 - - Add BIN as an entry in the glossary (#7667) - - I initially thought this macro is referencing binary, not basic instruction name - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 2f8e5c80e65a14b3a9298b6cae7ee7fc53890540 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-06 06:40:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-06 06:40:40 +0900 - - [ruby/irb] Drop Ruby 2.6 support - (https://github.com/ruby/irb/pull/555) - - * Remove all Ruby 2.6 support - - * Drop Ruby 2.6 specific testing conditions - - * Only run Ruby 2.7+ on CI - - * Bump Ruby requirement to 2.7+ - - https://github.com/ruby/irb/commit/3f714b616c - -commit 1587494b0b5f64a9976dcf0bd94dfe98123c2c27 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-06 05:19:31 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-06 05:19:31 +0900 - - YJIT: Add codegen for Integer methods (#7665) - - * YJIT: Add codegen for Integer methods - - * YJIT: Update dependencies - - * YJIT: Fix Integer#[] for argc=2 - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 52e571fa72debcd764765775bd1b76ee87e36d2d - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-04-05 12:55:43 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-06 01:57:32 +0900 - - Ensure ruby_xfree won't segfault if called after vm_destruct - - [Bug #19580] - - The real-world scenario motivating this change is libxml2's pthread - code which uses `pthread_key_create` to set up a destructor that is - called at thread exit to free thread-local storage. - - There is a small window of time -- after ruby_vm_destruct but before - the process exits -- in which a pthread may exit and the destructor is - called, leading to a segfault. - - Please note that this window of time may be relatively large if - `atexit` is being used. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7663 - -commit 533423ebe46ebfe3005198c12aa0d2c899c695ea - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-03 14:27:36 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-06 00:19:03 +0900 - - core_assertions.rb: Prefer CPU time clocks - - To prevent influence from other processes. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7661 - -commit f9eb2515a3221cced611b4de971b72a78a7a566f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-03 14:22:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-06 00:19:03 +0900 - - core_assertions.rb: Extract common code block - - Notes: - Merged: https://github.com/ruby/ruby/pull/7661 - -commit f07c756494b0e473ff8e4ece6f04c7ababe93b01 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-03 14:10:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-06 00:19:03 +0900 - - core_assertions.rb: Tweak timeout limit - - Increase the timeout limit when variance at rehearsal is small. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7661 - -commit 4b100f75d2047de4f525f748fe8901471e8318ed - Author: Daniel DeLorme <daniel@dan42.com> - AuthorDate: 2023-04-05 22:16:26 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-04-05 23:37:07 +0900 - - [DOC] Clarify behavior of abort() with no argument - - Since Ruby 2.7 it prints the message and backtrace of $! - - Fixes [Bug #19578] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7664 - -commit 615a1bc470587614129c8a7f352286cf9d1c0fc6 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-05 23:32:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-05 23:32:04 +0900 - - YJIT: Count the number of actually written bytes (#7658) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 3e1e09b2b7ee9a6b45d15d28997c1357eab53f14 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-04-05 05:28:35 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-04-05 22:49:31 +0900 - - YJIT: Smoke test on Rust 1.58.0 - - Since warnings might show up on older version but not newer ones. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7657 - -commit 8f734cf93ec1b937fec3eada2df205f9e93b3f33 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-04-05 05:25:37 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-04-05 22:49:31 +0900 - - YJIT: Eanble `unsafe_op_in_unsafe_fn` on crate::core - - Encourages commenting about soundness of `unsafe` usages. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7657 - -commit 929d55c3c7d312a21e5691f9c6793450e2c617d1 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-04-05 05:12:01 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-04-05 22:49:31 +0900 - - Revert "YJIT: Suppress unnecessary `unsafe` block (GH-7634)" - - This reverts commit 9e678cdbd054f78576a8f21b3f97cccc395ade22. - - Without the `unsafe` annotations, the SAFETY comments make less sense. - I want to keep the SAFETY comments. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7657 - -commit e003784fc8bfa527cf21c317741101a713c041c0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-05 17:06:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-05 18:50:29 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/RegexpLiteral - - https://github.com/rubygems/rubygems/commit/9264d83421 - -commit 65d27d3c0a1235f04ca90f94e29a7f2ddfd1b574 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-05 16:46:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-05 16:46:10 +0900 - - RJIT: Skip a class guard if known to be T_STRING - -commit 9bef39de74684343ef3a20269f1a37ee395c2057 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-05 16:38:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-05 16:38:38 +0900 - - RJIT: Handle include_all argument of respond_to? - -commit 66fe64b2699902041790400dfa94ca14f097f3b5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-05 15:55:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-05 15:55:19 +0900 - - RJIT: Remove unused variables - -commit 2ddf6079f17da874c12b4749057ee6b617cb3005 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-05 15:46:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-05 15:52:14 +0900 - - RJIT: Always use guard_two_fixnums - -commit 4e9c3b4518822036ee7d60b9bf7e77ee6753b725 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-05 15:36:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-05 15:42:14 +0900 - - RJIT: Eliminate known-result guards for blockarg - -commit 4f77d1cdb89c3650461552d98aa527dd7f48d5df - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-05 15:19:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-05 15:30:26 +0900 - - RJIT: Eliminate known-result branches - -commit 9a5d4cc80ba16f4817dd9b1311e3e6239732618a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-05 11:07:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-05 14:49:26 +0900 - - [rubygems/rubygems] Removed unused Gem::Deprecate from Gem::TestCase - - https://github.com/rubygems/rubygems/commit/d8a75a5f84 - -commit 8e37eb1d150a2a0c7fd6c274c8f4ac1c24940849 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-05 11:05:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-05 14:49:26 +0900 - - [rubygems/rubygems] Extract class method used by self.method - - https://github.com/rubygems/rubygems/commit/d900453ca2 - -commit 7f9a5a7562e25ee18d167d72a62826ee5ae1e726 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-05 10:54:36 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-05 14:49:26 +0900 - - [rubygems/rubygems] We don't use process_based_port and self.process_based_port - - https://github.com/rubygems/rubygems/commit/f1a20c4c69 - -commit 6d0caac4253acbb80fe6531c50d9f3520d2a4664 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-05 10:53:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-05 14:49:25 +0900 - - [rubygems/rubygems] We don't use self.make_command - - https://github.com/rubygems/rubygems/commit/241f376c32 - -commit a464951fc79271a87d09a13f8fd9965dda6e2e61 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-05 10:50:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-05 14:49:25 +0900 - - [rubygems/rubygems] Unify win_platform? to Gem.win_platform? - - https://github.com/rubygems/rubygems/commit/b18a4ef076 - -commit cbeea5f3e6a5b5112ff5973c02c934ed415e2dc7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-05 10:45:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-05 14:49:24 +0900 - - [rubygems/rubygems] Unify java_platform? to Gem.java_platform? - - https://github.com/rubygems/rubygems/commit/7f27ab32b8 - -commit bf8afe434f4fcaad4d69a038e7f92786b5a56723 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-05 10:24:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-05 14:49:24 +0900 - - [rubygems/rubygems] Removed self.mingw_windows?, It's not used rubygems - - https://github.com/rubygems/rubygems/commit/ba3c985701 - -commit 28d6c6d69b4e7028649a0dc42f06507e7cd47e39 - Author: lukeg <luke.gru@gmail.com> - AuthorDate: 2023-03-21 03:01:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-05 14:38:20 +0900 - - [rubygems/rubygems] add some test suites under the Gem namespace, so as not to collide - - To avoid collisions especially in ruby/ruby - - https://github.com/rubygems/rubygems/commit/e6b2359975 - -commit e06bebff5ef57dd4c32acb77001df230520c5449 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 16:49:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-05 14:13:25 +0900 - - RJIT: Propagate argument types on method calls - -commit 6d8875b5d7f8dc4a6435e6fd10c73a1b42541fab - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-05 14:05:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-05 14:05:45 +0900 - - RJIT: Fix mapping offsets in stack_swap - -commit 52ff2ce9da2958cd59d93a063b24345c4110c65c - Author: Étienne Barrié <etienne.barrie@gmail.com> - AuthorDate: 2023-03-24 23:29:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-05 08:59:12 +0900 - - Use `em_delete` in `key_delete` (#504) - - * Test existing behavior - - Typing Ctrl-D ends editing but typing <Del> does not. - - Also renamed a test that is not testing ed_delete_next_char but - key_delete. - - * Check if line empty first in em_delete - - By distributivity of AND over OR, we can factor out this condition. This - will make the next commit simpler. - - * Use em_delete in key_delete - - When the editing mode is emacs, use `em_delete` in `key_delete`. We need - to add a condition though to `em_delete`, because it implements both - `delete-char` and `end-of-file`. We only want the `end-of-file` behavior - is the key is really Ctrl-D. - - This matches the behavior of the <Del> key with readline, i.e. deleting - the next character if there is one, but not moving the cursor, while not - finishing the editing if there are no characters. - -commit bb927acd3bd3a5a5797587bc4201724235ed26b5 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-04-05 05:58:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-05 08:43:58 +0900 - - [ruby/optparse] Document requires needed for Date/DateTime/Time/URI/Shellwords support - - Fixes [Bug #19566] - - https://github.com/ruby/optparse/commit/fb91d97c10 - -commit 1da2e7fca35dc697d85dd91d2572ab58d08cd3bc - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-05 06:30:06 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-05 06:30:06 +0900 - - [Feature #19579] Remove !USE_RVARGC code (#7655) - - Remove !USE_RVARGC code - - [Feature #19579] - - The Variable Width Allocation feature was turned on by default in Ruby - 3.2. Since then, we haven't received bug reports or backports to the - non-Variable Width Allocation code paths, so we assume that nobody is - using it. We also don't plan on maintaining the non-Variable Width - Allocation code, so we are going to remove it. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 1190ec60cc3145c06cca6897b160b3e8ba2c7ecd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-05 06:01:41 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-05 06:02:04 +0900 - - Use a longer timeout for syntax_suggest - - for CI stability - -commit d26d3575cab676ade7d0257138a044e22b373e68 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-04-05 05:41:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-05 05:41:52 +0900 - - YJIT: add stats for ratio of versions per block (#7653) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 8525603c72e22c90aa423431684042af66d1d100 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-04-05 04:58:56 +0900 - Commit: Aaron Patterson <tenderlove@ruby-lang.org> - CommitDate: 2023-04-05 04:59:14 +0900 - - Revert "Fix transient heap mode" - - This reverts commit 87253d047ce35e7836b6f97edbb4f819879a3b25. - - Revert "Implement `Process.warmup`" - - This reverts commit ba6ccd871442f55080bffd53e33678c0726787d2. - -commit e5de0fe108f665c8df3d23494e2fff786f6d54a4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-05 03:08:59 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-05 03:09:09 +0900 - - Remove an unused counter - - I ended up not using it. - -commit 116c0f92ef0af466a2adc1052ebccaea4d5345f0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-05 03:07:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-05 03:07:57 +0900 - - Resurrect yjit-smoke-test before #7651 - -commit b7717fc390ce47c8ef24d2ed9fe25f188f28f60f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-05 02:58:11 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-05 02:58:11 +0900 - - YJIT: Stack temp register allocation (#7651) - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 87253d047ce35e7836b6f97edbb4f819879a3b25 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-04-05 01:49:26 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-04-05 02:49:08 +0900 - - Fix transient heap mode - - Make sure the transient heap is in the right mode when we finish warming - the heap. Also ensure the GC isn't allowed to run while we iterate and - mutate the heap. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7346 - -commit ba6ccd871442f55080bffd53e33678c0726787d2 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2022-10-19 23:56:37 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-04-05 02:49:08 +0900 - - Implement `Process.warmup` - - [Feature #18885] - - For now, the optimizations performed are: - - - Run a major GC - - Compact the heap - - Promote all surviving objects to oldgen - - Other optimizations may follow. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7346 - -commit a84c99468f26a9f79fec57926d561ed906505eac - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-04-04 22:27:45 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-04-05 00:12:07 +0900 - - Fix crash in Time on 32-bit systems - - [Bug #19575] - - struct vtm is packed causing it to have a size that is not aligned on - 32-bit systems. When allocating it on the stack, it will have unaligned - addresses which means that the fields won't be marked by the GC when - scanning the stack (since the GC only marks aligned addresses). This can - cause crashes when the fields are heap allocated objects like Bignums. - - This commit moves the flags in struct time_object into struct vtm for - space efficiency and removes the need for packing. - - This is an example of a crash: - - ruby(rb_print_backtrace+0xd) [0x56848945] ../src/vm_dump.c:785 - ruby(rb_vm_bugreport) ../src/vm_dump.c:1101 - ruby(rb_assert_failure+0x7a) [0x56671857] ../src/error.c:878 - ruby(vm_search_cc+0x0) [0x56666e47] ../src/vm_method.c:1366 - ruby(rb_vm_search_method_slowpath) ../src/vm_insnhelper.c:2090 - ruby(callable_method_entry+0x5) [0x568232d3] ../src/vm_method.c:1406 - ruby(rb_callable_method_entry) ../src/vm_method.c:1413 - ruby(gccct_method_search_slowpath) ../src/vm_eval.c:427 - ruby(gccct_method_search+0x20f) [0x568237ef] ../src/vm_eval.c:476 - ruby(opt_equality_by_mid_slowpath+0x2c) [0x5682388c] ../src/vm_insnhelper.c:2338 - ruby(rb_equal+0x37) [0x566fe577] ../src/object.c:133 - ruby(rb_big_eq+0x34) [0x56876ee4] ../src/bignum.c:5554 - ruby(rb_int_equal+0x14) [0x566f3ed4] ../src/numeric.c:4640 - ruby(rb_int_equal) ../src/numeric.c:4634 - ruby(vm_call0_cfunc_with_frame+0x6d) [0x568303c2] ../src/vm_eval.c:148 - ruby(vm_call0_cfunc) ../src/vm_eval.c:162 - ruby(vm_call0_body) ../src/vm_eval.c:208 - ruby(rb_funcallv_scope+0xd1) [0x56833971] ../src/vm_eval.c:85 - ruby(RB_TEST+0x0) [0x567e8488] ../src/time.c:78 - ruby(eq) ../src/time.c:78 - ruby(small_vtm_sub) ../src/time.c:1523 - ruby(timelocalw+0x23b) [0x567f3e9b] ../src/time.c:1593 - ruby(time_s_alloc+0x0) [0x567f536b] ../src/time.c:3698 - ruby(time_new_timew) ../src/time.c:2694 - ruby(time_s_mktime) ../src/time.c:3698 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7650 - -commit 06da0d1456f52a69ad19a0a8cc35e3359d2d144c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-04 12:12:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-04 21:20:43 +0900 - - [rubygems/rubygems] util/rubocop -A - - https://github.com/rubygems/rubygems/commit/8c9ea5d180 - -commit a881b33818b101ad097cd0158afda11b6c24f1fc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-04 12:03:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-04 21:20:43 +0900 - - [rubygems/rubygems] util/rubocop -A --only Performance/RegexpMatch - - https://github.com/rubygems/rubygems/commit/52ae4452c2 - -commit a78e0ca968115cbf57228cf2c026d2e21534dc7b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-04 16:09:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-04 21:13:13 +0900 - - [rubygems/rubygems] Don't copy and paste methods in helper methods - - https://github.com/rubygems/rubygems/commit/b87ac64343 - -commit 51b2f4c0f562ee57dca14820967556d730c2ac9e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-04 17:17:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-04 17:17:23 +0900 - - RJIT: Fix the argument of shift_stack - -commit 98f0e2c330a261a96e3a90ff4f5a8c671abdbec5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-04 16:40:31 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-04 16:41:58 +0900 - - RJIT: Fix the argument for defined - -commit 19506650efeb8b19cea3f72d3f95547c5cbc3659 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-04 14:52:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-04 16:35:29 +0900 - - RJIT: Add --rjit-verify-ctx option - -commit 2c560b976ed86730dfa305266fcc69033f6790cc - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-04 16:30:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-04 16:30:57 +0900 - - RJIT: Fix arguments to SPECIAL_CONST_P - -commit f3acaf312c2a0069acd279edc0ceafcc34ddfdc3 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-04-04 15:42:37 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-04-04 15:42:37 +0900 - - `rb_th_serial(th)` allows `th == NULL` - -commit 822f01b36c7f9bf3b9f36eba3a508844908b7902 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-04 10:43:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-04 15:08:04 +0900 - - [rubygems/rubygems] Disabled to test rustc with msys2 platform. - - https://github.com/rubygems/rubygems/actions/runs/4598776839/jobs/8123290246 - - https://github.com/rubygems/rubygems/commit/5c3b0a112e - -commit 6a4087702bb8ceecdc831fbe8ff230dc988e6e96 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-04 14:07:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-04 14:42:21 +0900 - - RJIT: Update type information on setlocal - -commit 6ab86e462624df5d7d0d7661f9511d05c0363224 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-04 13:22:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-04 13:26:40 +0900 - - RJIT: Fix arguments for shift_stack - -commit 1d529f382c4b855d22289990c4369ee68ddd3adc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-04 11:29:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-04 11:29:57 +0900 - - PID cache is never cleared where `fork` is not used - - Notes: - Merged: https://github.com/ruby/ruby/pull/7649 - -commit 05b7bbecc6cd40add807ee5c85dd282f0c19291c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-04 11:27:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-04 11:27:43 +0900 - - Suppress `-Wdiscarded-qualifiers` warning where `fchdir` is unusable - - Notes: - Merged: https://github.com/ruby/ruby/pull/7649 - -commit b2e848193aad70cffd972b15fcc6cbf6be843d94 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-04-04 03:39:30 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-04-04 07:57:51 +0900 - - fix deadlock on `Thread#join` - - because of 9720f5ac894566ade2aabcf9adea0a3235de1353 - - http://rubyci.s3.amazonaws.com/solaris11-sunc/ruby-master/log/20230403T130011Z.fail.html.gz - - ``` - 1) Failure: - TestThread#test_signal_at_join [/export/home/chkbuild/chkbuild-sunc/tmp/build/20230403T130011Z/ruby/test/ruby/test_thread.rb:1488]: - Exception raised: - <#<fatal:"No live threads left. Deadlock?\n1 threads, 1 sleeps current:0x00891288 main thread:0x00891288\n* #<Thread:0xfef89a18 sleep_forever>\n rb_thread_t:0x00891288 native:0x00000001 int:0\n \n">> - Backtrace: - -:30:in `join' - -:30:in `block (3 levels) in <main>' - -:21:in `times' - -:21:in `block (2 levels) in <main>'. - ``` - - The mechanism: - - * Main thread (M) calls `Thread#join` - * M: calls `sleep_forever()` - * M: set `th->status = THREAD_STOPPED_FOREVER` - * M: do `checkints` - * M: handle a trap handler with `th->status = THREAD_RUNNABLE` - * M: thread switch at the end of the trap handler - * Another thread (T) will process `Thread#kill` by M. - * T: `rb_threadptr_join_list_wakeup()` at the end of T tris to wakeup M, - but M's state is runnable because M is handling trap handler and - just ignore the waking up and terminate T$a - * T: switch to M. - * M: after the trap handler, reset `th->status = THREAD_STOPPED_FOREVER` - and check deadlock -> Deadlock because only M is living. - - To avoid such situation, add new sleep flags `SLEEP_ALLOW_SPURIOUS` - and `SLEEP_NO_CHECKINTS` to skip any check ints. - - BTW this is instentional to leave second `vm_check_ints_blocking()` - without checking `SLEEP_NO_CHECKINTS` because `SLEEP_ALLOW_SPURIOUS` - should be specified with `SLEEP_NO_CHECKINTS` and skipping this - checkints can skip any interrupts. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7647 - -commit 38209ffdca89a497572486034a4e9ed534607057 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-04 06:10:35 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-04-04 06:10:35 +0900 - - YJIT: Add codegen for Array#<< (#7645) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit ba4ff2552e9bca762f0953e5697438efebe22547 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-04 00:52:46 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-04 00:59:05 +0900 - - Avoid failing test_enable on warnings - - This fails on RubyCI due to RJIT warnings too often. It should be enough - to test RJIT feature in test_rjit_version. We only want warnings instead - of test failures when there are warnings, at least for this case. - -commit 3cb5e7558ddbaf9535a6937616fb9e8db13dbcbb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-04 00:44:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-04 00:44:16 +0900 - - Fix a test_rubyoptions failure - -commit 46e93ef53d66a73c1dbe317946dd4ac7d712bb1c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 16:49:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 16:49:10 +0900 - - RJIT: Propagate self's type information - -commit ca8102355ac98be37b7b424b5a1d880dd94b198d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 16:09:28 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 16:39:29 +0900 - - RJIT: Upgrade type on jit_guard_known_class - -commit 1d452c2cf853d8a95c8020164ee4ef268254b31a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 16:02:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 16:02:45 +0900 - - RJIT: Upgrade type to Fixnum after guard - -commit 0abe9d8b32ea9368576ee6dbabc4f19f556b9b08 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 15:53:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 15:54:08 +0900 - - RJIT: Upgrade type to String after guard - -commit f0b69eb14f9a678e4c3e4e41fef3bf2bda54dc5c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 15:48:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 15:49:55 +0900 - - RJIT: Upgrade type to Array after guard - -commit d876c008ecb823a042021bebdb6667ff0c8ff028 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 15:34:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 15:37:15 +0900 - - RJIT: Limit the number of versions per block - -commit 3bacc3877a8d61a2e66f6b9d874a60f3be0e7f53 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 15:22:53 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 15:24:14 +0900 - - RJIT: Find a best matching block version - -commit eb51248c4c673d6b3d62503f8f4c79d75a52edaa - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 14:52:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 15:11:18 +0900 - - RJIT: Upgrade type to UnknownHeap after guard - -commit be4e16bc1a97af8553b15a53fb79eb043abe02b6 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 15:07:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 15:07:58 +0900 - - RJIT: Update type information on setn insn - -commit 50285d2864e28842174a2994d830b623ac2025aa - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 15:05:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 15:06:30 +0900 - - RJIT: Swap type information on swap insn - -commit d546f8c5183d583b2455ef005b9276a22bab3b65 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 08:59:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 14:32:16 +0900 - - RJIT: Store type information in Context - -commit 6fb6d85aeed3ed12cf92ae2af009080609ee9a01 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-03 14:18:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-03 14:19:00 +0900 - - [ruby/fileutils] Bump up v1.7.1 - - https://github.com/ruby/fileutils/commit/7138d85156 - -commit 27f709aa3cdec00dadbc3a41c9974362060fdf66 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-03 12:43:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-03 12:43:11 +0900 - - Rename YAML::VERSION. It's conflict with Psych::VERSION - -commit b5c8c73f66c5c5c036715ccfc41e3761bcea1377 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-04-03 12:00:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-04-03 12:00:59 +0900 - - Fixed version detection paths in ruby repository - -commit 14f442a9584989805be8e40caa0de7758bf07532 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 13:06:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-03 11:45:42 +0900 - - [ruby/base64] Expose Base64::VERSION - - https://github.com/ruby/base64/commit/dda85a0839 - -commit ba4f01f0a03403bea72b129e5935f5a4b79b9402 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 14:19:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-03 11:45:18 +0900 - - [ruby/yaml] Expose YAML::VERSION - - https://github.com/ruby/yaml/commit/8776bc2634 - -commit 6dcd39997679914dad1c23f95adb3f7d84ec5942 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 14:17:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-03 11:41:44 +0900 - - [ruby/tsort] Expose TSort::VERSION - - https://github.com/ruby/tsort/commit/09f2275958 - -commit a70653ca7facbb2004562e5718fa51e7ade6b157 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-30 13:05:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-03 11:40:37 +0900 - - [ruby/find] Expose Find::VERSION - - https://github.com/ruby/find/commit/a24124a08a - -commit 2f1586f6f204bdd040ba7a14633983568199dbc0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-04-02 17:50:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-04-03 10:07:22 +0900 - - Check leaked global symbols by default - - Notes: - Merged: https://github.com/ruby/ruby/pull/7643 - -commit 8968b47ba8a6d1c66315b7ea042cac8b07f0d7c3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 08:46:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 08:50:54 +0900 - - RJIT: Refactor getlocal and setlocal - -commit 6002b12611c3cee921fc8aef76b55db4b2d0fbcd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 07:26:46 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 07:27:40 +0900 - - RJIT: Support entry with different PCs - -commit 4fc336127e54dde8a744acdb5157c17e7ae857d3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 06:44:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 06:47:23 +0900 - - RJIT: Support has_opt ISEQs - -commit ad2b719fc2c768aacd3a623da00b68fa62d7557b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 06:32:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 06:32:51 +0900 - - RJIT: C::FL_TEST_RAW returns RBOOL - -commit 57ee62792991f80f5df9e1db2f14141ff6345937 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 06:15:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 06:22:42 +0900 - - RJIT: Lazily guard block arg - - to simplify the implementation - -commit 66f8efc342bd36ae14090f14e7c2b9a0e30b9be3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 04:56:27 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 05:58:39 +0900 - - RJIT: Simplify cfunc implementation - -commit 284a0ff96c97be0c2413e3fb59a7874e4092c90b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 04:28:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 04:28:49 +0900 - - RJIT: Remove an unneeded branch - -commit 3fe134759cc4904c74306e0832c22fa518a5bea2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 04:23:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 04:23:23 +0900 - - Skip assert_linear_performance for RJIT - -commit bf7587748d793265060fc2708421eaeddea7e4c0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 03:07:50 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 03:42:16 +0900 - - RJIT: Simplify invokesuper implementation - -commit 5cc644b147f8809a9ab986c40dc8c3c3befb52a3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 03:01:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 03:01:23 +0900 - - RJIT: Group blockarg exit reasons - -commit cd1cd8030c0849fcba1ae7f251e53919703d8af7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 02:46:27 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 02:55:03 +0900 - - RJIT: Support splat args - -commit 6f2535deda1acbba7762639bd2681b84309432d5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 02:40:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 02:40:37 +0900 - - RJIT: Prefix a constant with C namespace - -commit 62188c8584e4c79694a56db7e72b4d3c2bf7a5dd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-03 02:27:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 02:27:17 +0900 - - RJIT: Update exit reasons - -commit 7778c292c4c13823208a70558d25424fef474de3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 16:03:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-03 02:26:22 +0900 - - RJIT: Support keyword arguments - -commit cd94bcdc46fc5d8f6bc0da23223c75335677d253 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-03-31 01:17:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-03 00:34:28 +0900 - - [ruby/irb] Don't check RUBY_ENGINE when deciding whether to accept kargs - - Ruby implementations like JRuby and TruffleRuby already indicate their - compatibility target with RUBY_VERSION. We don't need to exclude - them from accepting keyword arguments as long as they target 2.7+. - - https://github.com/ruby/irb/commit/bf20faa4e6 - - Co-authored-by: Kevin Menard <kevin@nirvdrum.com> - -commit f25791884c8efa5ea6598c82ae5015f5fcfb8ebb - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-02 23:11:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-02 23:11:12 +0900 - - [ruby/irb] Remove dead code (https://github.com/ruby/irb/pull/554) - - * Remove unused ATTR_TTY and ATTR_PLAIN constants - - They were added in https://github.com/ruby/irb/commit/d7d26b51bf47a52e4e2339e2ad509ace74f0e4c7 - - But the references were removed in https://github.com/ruby/irb/commit/1c76845cca59635bb0cf386ced721e34b25d7410 - - Co-authored-by: Alexandre Terrasa <alexandre.terrasa@shopify.com> - - * Remove unused MethodExtender module - - It was added in https://github.com/ruby/irb/commit/6cc5d718d7045952ef61d504d624f7e70ce828be - but it's not used anywhere. - - Co-authored-by: Alexandre Terrasa <alexandre.terrasa@shopify.com> - - * Remove unused IRB.irb_at_exit - - It's not used after https://github.com/ruby/irb/commit/aaf4eb4e9830ae71240ca5d2047c5e3ad20a4044 - - Co-authored-by: Alexandre Terrasa <alexandre.terrasa@shopify.com> - - * Remove unused InputCompletor.ignored_modules - - It was added in https://github.com/ruby/irb/commit/88311ce3c84251e6f420246cd14efc96e00888be - but the reference was removed in https://github.com/ruby/irb/commit/78c74d24254145a39c4d30168dbcd87dbbbc66dc - - * Remove unused TracerLoadError constant - - This constant was added in https://github.com/ruby/irb/commit/cb50fa3738121e4d829cb05b4bcb0d5fb43760c5 - but never referenced. - - --------- - - https://github.com/ruby/irb/commit/7de0234325 - - Co-authored-by: Alexandre Terrasa <alexandre.terrasa@shopify.com> - -commit 1b475fcd10b4f6fe6784c016e3cdeff724229b1d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 15:06:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 15:09:05 +0900 - - Remove an unneeded function copy - -commit 6c55c3eb7f20b4df685f263c6fd121883b5bf113 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 15:07:21 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 15:07:22 +0900 - - RJIT: Fix a leaked-globals failure - -commit a077b7e36b27462b9702251d6fb823d3a092a134 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 13:52:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 15:00:36 +0900 - - RJIT: Support rest args - -commit 87dc06ed242ab6524cc51404513a8b0dad9fe1e3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 14:39:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 14:39:16 +0900 - - RJIT: Comment a location for each block - -commit bf2617b8a679b5ef7eabfa3feb2ef2686d1291f0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 13:47:28 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 13:47:28 +0900 - - RJIT: Fix has_rest exit conditions - -commit ee52255f93b30c15031d2a6566fbe68c2b9a16c7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 13:42:28 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 13:42:34 +0900 - - RJIT: Return CantCompile early for arg0 splat - -commit 2ce5cfa2be927acfd20c2543e0580cbef715213d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 13:34:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 13:34:19 +0900 - - RJIT: Save PC on String#concat - -commit e45ed2da5046f7ee2a82f332d211ddbd7108fc22 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 13:23:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 13:30:42 +0900 - - RJIT: Rewind stack_size on CantCompile and side exits - - so that we can take an exit whenever we want. - - As a starter, this commit also pops blockarg earlier than some - CantCompile exits. - -commit 90cdc5b8ba5421bfd183c2bfba16c1fd3ca7e0f5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 13:13:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 13:13:15 +0900 - - RJIT: Let the caller of jit_push_frame handle stack_pop - - because we want to do this way earlier for other types of calls. - -commit 28db75af66f7b8cbbc040a91394b86282702f32c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 13:03:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 13:03:10 +0900 - - RJIT: Check stackoverflow earlier for ISEQ - -commit 249fe18e8f48d289e83aefbe9dc3de0b52b55357 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 09:24:06 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 09:24:45 +0900 - - RJIT: Remove unused counters - -commit f42cf3fd1ed6bb43822f85a90c1cda119e75a68d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 09:10:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 09:17:41 +0900 - - RJIT: Migrate invokeblock to jit_call_iseq - -commit cfea319772faeef1d3d0ff69916221c29b691ee0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 08:59:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 09:03:45 +0900 - - RJIT: Migrate bmethod to jit_call_iseq - -commit 0973b93e495bd39da5032747fbc5051bb226c1a9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-28 13:58:50 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 08:56:05 +0900 - - RJIT: Start moving away from VM-like ISEQ handling - -commit d71db90c6800bee0716673a0c6d5bc356c04e9cb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 07:12:50 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 07:13:08 +0900 - - Fix a test in typeprof - - Revert "Skip typeprof for now" - - This reverts commit bdbf663cef31e2194bf87ae5c11dfe5525316ca8. - -commit bdbf663cef31e2194bf87ae5c11dfe5525316ca8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 03:04:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 03:04:53 +0900 - - Skip typeprof for now - - It started failing probably because ISEQ removed an unused field. - I'll have a look at fixing it on the typeprof side, but let me skip it - until it's fixed. - -commit df1b007fbd64363067539ff7e89aff6368d605ab - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 02:21:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 02:22:47 +0900 - - Remove unused VM_CALL_BLOCKISEQ flag - -commit 175538e433badf179d712f5ead659f29f5d11654 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-02 02:17:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-02 02:17:59 +0900 - - Improve explanation of FCALL and VCALL - -commit 4ac8d1172483634bb24183b8ad2aaa03435b17a3 - Author: Kazuki Tsujimoto <kazuki@callcc.net> - AuthorDate: 2023-04-01 16:28:05 +0900 - Commit: Kazuki Tsujimoto <kazuki@callcc.net> - CommitDate: 2023-04-01 16:35:24 +0900 - - `*` in an array pattern should not be parsed as nil in ripper - - After 6c0925ba7017efde6091e2ec4f1a6be268166696, it was impossible - to distinguish between the presence or absence of `*`. - - # Before the commit - Ripper.sexp('0 in []')[1][0][2][1] #=> [:aryptn, nil, nil, nil, nil] - Ripper.sexp('0 in [*]')[1][0][2][1] #=> [:aryptn, nil, nil, [:var_field, nil], nil] - - # After the commit - Ripper.sexp('0 in []')[1][0][2][1] #=> [:aryptn, nil, nil, nil, nil] - Ripper.sexp('0 in [*]')[1][0][2][1] #=> [:aryptn, nil, nil, nil, nil] - - This commit reverts it. - -commit 3a238eff88440f450a7871fc82e49bfb1ab336e5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-01 16:23:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-01 16:23:35 +0900 - - gdb: Fix a command example - - It was actually harder to type `cfp + 1`. `cfp 1` also works and is more - useful. - -commit a3074c1256f210cdd9eb21d636b231e8e64ee496 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-01 16:19:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-01 16:19:43 +0900 - - gdb: Fix specval - - Somehow my gdb stopped recognizing VM_BLOCK_HANDLER_NONE (macro) today. - Just changing it to a safer code. - -commit 1da77539da4bf6151baac656f48f00eff544a448 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-01 16:19:27 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-01 16:19:27 +0900 - - gdb: Don't dump params and locals for C frames - -commit 9720f5ac894566ade2aabcf9adea0a3235de1353 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-31 19:35:52 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-04-01 09:48:37 +0900 - - use `sleep_forever()` on `thread_join_sleep()` - - because it does same thing. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7642 - -commit 23892d95f5fec8950ca3f9686a630c87e02cf201 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-04-01 06:54:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-04-01 07:02:58 +0900 - - [ruby/irb] Drop unnecessary pends for truffleruby - - https://github.com/ruby/irb/commit/2517039812 - -commit a9b6b25de53b6cb324666f0114789c5f48f877db - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-04-01 01:13:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-04-01 01:13:37 +0900 - - gdb: Visualize register positions on the left - -commit 9e678cdbd054f78576a8f21b3f97cccc395ade22 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-31 23:15:39 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-31 23:15:39 +0900 - - YJIT: Suppress unnecessary `unsafe` block (#7634) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 1d19776c7f4daf30f7dae3ffb9c762ccd3669176 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-31 19:26:06 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-31 19:26:47 +0900 - - cosmetic change - - reorder `sleep_forever()` and so on. - -commit 185f39df7916670afb2f89896d1324a5a107f480 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-31 19:20:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-31 19:20:40 +0900 - - gdb: Always show actual values in cfp - -commit 0f368bfb7b82148cd8d2795820e5bb60d542dc33 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-31 19:05:29 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-31 19:05:30 +0900 - - gdb: Show params and locals in cfp - -commit 98347c251a9c73eba51ffe50519e18334320ac91 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-31 18:54:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-31 18:54:56 +0900 - - gdb: Dump env data in cfp command - -commit f803bcfc872b31faeb1b894e315175e410024cd5 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-31 17:57:25 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-31 18:50:10 +0900 - - pass `th` to `thread_sched_to_waiting()` - - for future extension - - Notes: - Merged: https://github.com/ruby/ruby/pull/7639 - -commit 4c0f82eb5b13e436a93497eaf23d965efa35a39e - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-31 18:15:04 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-31 18:15:04 +0900 - - remove "\n" for `RUBY_DEBUG_LOG()` - - because `RUBY_DEBUG_LOG()` add "\n" at the end of message. - -commit ad7362db074e3dfe7c5d62b42edbef87c25eb24c - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-31 17:42:03 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-31 18:10:00 +0900 - - rename `rb_thread_t::locking_native_thread` - - to `rb_thread_t::has_dedicated_nt` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7638 - -commit 95dafb53cde279c32cfcab9e42ea63e31ea5f861 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-31 17:33:17 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-31 18:08:34 +0900 - - relax assertion - - `ec` can be NULL in future. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7637 - -commit 369bdff9ca0d50e845b9623ec2d3e3f14e079248 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-31 17:33:05 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-31 18:08:34 +0900 - - add debug log to `rb_ractor_thread_switch` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7637 - -commit fdfd50d006b80c459537a0c8e5dcc7d409cb7789 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-31 17:12:46 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-31 18:08:21 +0900 - - reorder `thread_pthread.c` functions - - Notes: - Merged: https://github.com/ruby/ruby/pull/7635 - -commit 66755164aa91ae0ec2712ab159d8acd8fa646574 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-31 17:18:02 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-31 17:27:56 +0900 - - add `RUBY_DEBUG_LOG` fo `each_machine_stack_value` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7636 - -commit a57270a8488dc7faaeb9fd62a2c4368a8cb703bf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-31 16:52:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-31 16:52:47 +0900 - - Expand tabs in .gdbinit - -commit 9f426491ca5250084174d2a16855cce041ca1cee - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-31 15:57:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-31 16:20:40 +0900 - - Put misc/gdb.py [experimental] - - This works like: - - ``` - (gdb) cfp - CFP (count=3, addr=0x7ffff73fef50): - $1 = {pc = 0x555556bf7818, sp = 0x7ffff72ff078, iseq = 0x7ffff2603270, self = 140737344619296, ep = 0x7ffff72ff058, block_code = 0x0, - __bp__ = 0x7ffff72ff060, jit_return = 0x555558c2b000} - - Stack (size=3): - [0] FIXNUM: 1 - [1] T_STRING: "" bytesize:0 (embed) encoding:1 coderange:7bit $2 = (struct RString *) 0x7ffff249ea80 - [2] [PROMOTED] T_OBJECT: $3 = {flags = 21474844769, klass = 140737344040416} - $4 = {0x24, 0x24, 0x24} - - (gdb) cfp + 1 - CFP (count=3, addr=0x7ffff73fef90): - $5 = {pc = 0x5555567a78f8, sp = 0x7ffff72ff040, iseq = 0x7ffff26032d0, self = 140737344619296, ep = 0x7ffff72ff038, block_code = 0x0, - __bp__ = 0x7ffff72ff040, jit_return = 0x555558c2b000} - - Stack (size=0): - ``` - -commit f500df097f7f191b54d82dd6cace7ede718ce624 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-31 15:58:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-31 15:58:09 +0900 - - Fix ivar dump for RVARGC in .gdbinit - - It was crashing with: - No symbol "ROBJECT_EMBED_LEN_MAX" in current context. - -commit fbc6661a725f0aa594b55bbce1d861928a3373fc - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-31 14:23:37 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-31 14:23:37 +0900 - - Revert "dump `RUBY_DEBUG_LOG` logs into `/dev/null`" - - This reverts commit 83667008b925c32b3ab70fb6ec70f7398e960d1e. - - because not stable yet. - -commit bc0a7a641b6d0d3ff979cfa11e25683f8fa59ebd - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-31 12:47:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-31 12:47:56 +0900 - - [ruby/net-http] typofix - - https://github.com/ruby/net-http/commit/4d31bde125 - -commit eedcd696a57521a18963d58487db8057a374a67a - Author: U.Nakamura <usa@ruby-lang.org> - AuthorDate: 2023-03-30 21:41:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-31 12:22:41 +0900 - - [ruby/net-http] Fix previous commit - - https://github.com/ruby/net-http/commit/1b276e2654 - -commit d8b8294c28a09278de357c26b291abf1b9f3cc5d - Author: U.Nakamura <usa@ruby-lang.org> - AuthorDate: 2023-03-30 20:10:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-31 12:22:40 +0900 - - [ruby/net-http] Limit header length - - https://github.com/ruby/net-http/commit/c245f7f9c8 - -commit 2093e4c2db1e19991e601bf5191eddb4652de35d - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-31 03:52:58 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-31 11:28:18 +0900 - - `nt->serial` for `RUBY_DEBUG_LOG` - - Show native thread's serial on `RUBY_DEBUG_LOG`. - `nt->serial` is also stored into `ruby_nt_serial` if the compiler - supports `RB_THREAD_LOCAL_SPECIFIER`. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7630 - -commit 83667008b925c32b3ab70fb6ec70f7398e960d1e - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-31 04:11:15 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-31 11:28:02 +0900 - - dump `RUBY_DEBUG_LOG` logs into `/dev/null` - - to test debug printing. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7631 - -commit bccdc041665032b819fab1c04ed4dbdfeeeb366b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-31 11:11:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-31 11:11:45 +0900 - - Check if `Bundler::EnvironmentPreserver` is defined - - Only `Bundler` might be defined. `EnvironmentPreserver` and its - `BUNDLER_PREFIX` would be defined together in the same file. - -commit 5116e8bdf83865f829834d678906fe719d193976 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-31 10:06:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-31 10:14:34 +0900 - - [ruby/rdoc] Read generated files in binary mode - - So that fixes crash with "invalid byte sequence in US-ASCII" on - ci.rvm.jp and some RubyCIs. - - https://github.com/ruby/rdoc/commit/4b416644f0 - -commit cd65e4adcab7d04b84a8cc296bca41e3a15a0a91 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-03-29 00:52:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-31 10:14:34 +0900 - - [ruby/rdoc] Use `File.binread` - - https://github.com/ruby/rdoc/commit/987c609df9 - -commit 3488eda41d42bf910b7c485c178faf5e82f0c27c - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-03-30 19:26:29 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-03-31 09:38:34 +0900 - - Fix gc_verify_internal_consistency error for pattern_matching in ripper - - `gc_verify_internal_consistency` reports "found internal inconsistency" - for "test_pattern_matching.rb". - - http://ci.rvm.jp/results/trunk-gc-asserts@ruby-sp2-docker/4501173 - - Ruby's parser manages objects by two different ways. - - 1. For parser - - * markable node holds objects - * call `RB_OBJ_WRITTEN` with `p->ast` as parent - * `mark_ast_value` marks objects - - 2. For ripper - - * unmarkable node, NODE_RIPPER/NODE_CDECL, holds objects - * call `rb_ast_add_mark_object`. This function calls `rb_hash_aset` then - `RB_OBJ_WRITTEN` is called with `mark_hash` as parent - * `mark_hash` marks objects - - However in current pattern_matching implementation - - * markable node holds objects - * call `rb_ast_add_mark_object` - - This commit fix it to be #2. - - This was inconsistency however always `mark_hash` is - made young by `rb_ast_add_mark_object` call then objects - are not collected. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7627 - -commit a8782c454ce3590ecad3ec5da4a54347a7326683 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-03-30 23:20:23 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-03-31 07:01:26 +0900 - - YJIT: Test more kw and rest cases and change exit name - - Notes: - Merged: https://github.com/ruby/ruby/pull/7628 - -commit 9a617c067f3cffbf0bfd4e2f4b0634adb9d50bc4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-31 06:15:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-31 06:15:59 +0900 - - YJIT: Generate side exits as late as possible (#7612) - - * YJIT: Generate side exits late as possible - - * YJIT: s/for_stack_size/with_stack_size/ - - * YJIT: s/get_counter/exit_counter/ - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 339295dd7cd6f1dea25a9f2c94081e12a5d50ff0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-31 01:16:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-31 01:16:44 +0900 - - Fix missing receiver [ci sip] - -commit 648870b5c577239b3274b0b48c82fb74910dfabf - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-03-30 20:48:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-30 20:48:55 +0900 - - Support `IO#pread` / `IO#pwrite` using fiber scheduler. (#7594) - - * Skip test if non-blocking file IO is not supported. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 6f122965cf8704f019445faead58040e9be2effb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-30 17:12:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-30 19:47:36 +0900 - - [Bug #19547] Add token for unescaped backslash - - This token is exposed only when `RubyVM::AbstractSyntaxTree` with - `keep_tokens` option. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7622 - -commit cbfd02998597f652940def034e490c2428baef09 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-30 14:32:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-30 19:44:39 +0900 - - [ruby/time] Make RFC2822 regexp linear - - https://hackerone.com/reports/1485501 - - https://github.com/ruby/time/commit/51034bda4c - -commit aa3885501f89e4927a72ccc1f90ff9cbc4140e17 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-11-29 16:22:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-30 19:44:38 +0900 - - [ruby/time] Fix quadratic backtracking on invalid time - - https://hackerone.com/reports/1485501 - - https://github.com/ruby/time/commit/2444456fc1 - -commit 623027bf0b5ea8924bb0a680f8e1ddde5116a5df - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-11-29 16:22:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-30 19:44:37 +0900 - - [ruby/time] Test for quadratic backtracking on invalid time - - https://hackerone.com/reports/1485501 - - https://github.com/ruby/time/commit/b30b7bc6e6 - -commit f5b824c745782d02b9420f8626f633e3de748d73 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-30 02:41:45 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-30 14:56:37 +0900 - - show debug log for `ractor_terminal_interrupt_all` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7616 - -commit 30b43f4f1a37641edc0b146b8a648686a65a3aef - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-30 02:38:08 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-30 14:56:37 +0900 - - `rb_ractor_thread_list()` only for current ractor - - so that no need to lock the ractor. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7616 - -commit 94e41822679ebd269564ad10d366596e1514d4ef - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-30 02:50:51 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-30 14:56:23 +0900 - - `rb_current_ractor_raw(b)` - - `rb_current_ractor()` expects it has valid `ec` and `r`. - `rb_current_ractor_raw()` with a parameter `false` allows to return - NULL if `ec` is not available. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7617 - -commit ba72849a3f5d2369821dfecbb5bf60b9a0e7cd4e - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-30 03:15:14 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-30 14:56:10 +0900 - - cosmetic change - - Notes: - Merged: https://github.com/ruby/ruby/pull/7618 - -commit f89c34823423f5e1fb69f1896e956a8a61b8c54a - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-30 03:20:44 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-30 14:55:25 +0900 - - enable GH actions on `USE_RUBY_DEBUG_LOG=1` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7619 - -commit 1b064227671fe780044406f163b117ef85f2f8b9 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-30 06:57:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-30 06:57:52 +0900 - - YJIT: Leave cfp->pc uninitialized for VM_FRAME_MAGIC_CFUNC - - C function frames don't need to use the VM-specific pc field to run - properly. When pushing a control frame from output code, save one - instruction by leaving the field uninitialized. - - Fix-up rb_vm_svar_lep(), which is used while setting local variables via - Regexp#=~. Use cfp->iseq as a secondary signal so it can stop assuming - that all CFUNC frames always have zero pc's. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7620 - - Merged-By: XrXr - -commit a1a4d77472475fc9ee4c16cce7b79f6f492c91c3 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-29 08:00:18 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-03-30 03:53:49 +0900 - - YJIT: code_gc(): Assert self is inline to avoid other_cb() - - The derived `&mut` from `other_cb()` overlapped with the parameter - `ocb`. - - Use `cfg!()` instead of `#[cfg...]` to avoid unused warnings. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7611 - -commit cdededf24dff06842fe8401af93cf6d8c304de13 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-29 06:38:06 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-03-30 03:53:49 +0900 - - YJIT: Take VM lock in RubyVM::YJIT.code_gc - - Code GC needs synchronization. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7611 - -commit 93b6997103b34750b2d84df07e09586fe1de0649 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-29 06:21:40 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-03-30 03:53:49 +0900 - - YJIT: Fix overlapping &mut in Assembler::code_gc() - - Making overlapping `&mut`s triggers Undefined Bahavior. This function - previously had them through `cb` and `ocb` aliasing with `self` or live - references in the caller. - - To fix the overlap, take `ocb` as a parameter and don't use `get_inline_cb()` - in the body of the function. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7611 - -commit a8c6ba23a6a95272edd6179737d4f98d7b2cdf6e - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-03-30 01:31:41 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-30 01:31:41 +0900 - - YJIT: Rest and keyword (non-supplying) (#7608) - - * YJIT: Rest and keyword (non-supplying) - - * Update yjit/src/codegen.rs - - --------- - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit b168141c7888a5237249b13d630f2a56a66f53f9 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-03-29 22:51:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-29 22:51:27 +0900 - - [ruby/reline] Drop Dialog#scrollbar_pos as we can store it in a - local variable - (https://github.com/ruby/reline/pull/529) - - https://github.com/ruby/reline/commit/d0139975fd - - Co-authored-by: tomoya ishida <tomoyapenguin@gmail.com> - -commit 02ecdf85c5896e8da9abe4765147e995396377a5 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-03-29 19:20:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-29 19:20:29 +0900 - - [ruby/reline] Drop Unicode.take_range's optional arg as it's never - used - (https://github.com/ruby/reline/pull/528) - - https://github.com/ruby/reline/commit/428fed4a6a - -commit 3155b76eb4d8a689207270e859fb2c0a6e17465a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-29 17:32:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-29 18:36:17 +0900 - - Added ~\scoop\shims to PATH - - Notes: - Merged: https://github.com/ruby/ruby/pull/7614 - -commit 54ddf58a29e7484327d1559b2fd621e8f97e390e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-29 17:22:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-29 18:36:17 +0900 - - Don't need to specify YACC name for scoop bison - - Notes: - Merged: https://github.com/ruby/ruby/pull/7614 - -commit a807fa6f9b3a1dab9275df4e197b4c9f581253ef - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-29 16:48:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-29 18:36:17 +0900 - - Use scoop instead of Chocolatey - - chocolatey often returns 503 status. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7614 - -commit 9a1f6975c54e72a0a30e3fa598e072c44ef093e5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-29 15:48:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-29 16:44:31 +0900 - - RJIT: Propagate a set of args as a CallingInfo - -commit f8f15e247d12ed7d709accc485704ae0c7866a51 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-03-29 16:00:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-29 16:00:50 +0900 - - Update bundled gems list at 2023-03-29 - -commit e26908dc4b6604cfe3c89f4cdc75dab67dff7d03 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-03-29 15:54:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-29 15:54:08 +0900 - - [ruby/reline] Improve OSC sequence regexp. OSC sequence can end with - ST(ESC\) and it should not to include \a and \e inside. - (https://github.com/ruby/reline/pull/527) - - https://github.com/ruby/reline/commit/a88052adec - -commit 8c8d0680161c9671e68303ee2b27ccbea4bd293a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-29 12:46:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-29 13:00:22 +0900 - - [ruby/win32ole] Skip test failure with mswin platform - - https://github.com/ruby/win32ole/actions/runs/4507614838/jobs/7935550685?pr=18 - - https://github.com/ruby/win32ole/commit/39ae6c2bc7 - -commit f241a8de56e5c5829dc9fd9cc290c58a93a7441a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-29 09:52:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-29 09:52:33 +0900 - - [ruby/uri] Increase rehearsals - -commit 39a34694a0e33e18b4ac6e43cb8042e2d818ecd4 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-03-29 04:21:19 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-29 04:21:19 +0900 - - YJIT: Add `--yjit-pause` and `RubyVM::YJIT.resume` (#7609) - - * YJIT: Add --yjit-pause and RubyVM::YJIT.resume - - This allows booting YJIT in a suspended state. We chose to add a new - command line option as opposed to simply allowing YJIT.resume to work - without any command line option because it allows for combining with - YJIT tuning command line options. It also simpifies implementation. - - Paired with Kokubun and Maxime. - - * Update yjit.rb - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - --------- - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 2f8a598dc598b4faaab5d8fd4740811d52fece96 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-29 03:40:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-29 03:40:48 +0900 - - YJIT: Stop using the starting_context pattern (#7610) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 2488b4dd0d21fa38ddf801772e8aada2564178dc - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2023-03-29 00:47:10 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2023-03-29 00:47:37 +0900 - - gem related automation must run only on master - -commit 1e9a218ade3af90c18f42e3fea08e2fcea81222a - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-03-28 21:49:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-28 21:49:49 +0900 - - [ruby/reline] Expand the scanned array to later case statement more - straightforward - (https://github.com/ruby/reline/pull/526) - - * Improve test coverage on Unicode.take_range - - * Add test for Unicode.calculate_width - - * Expand the scanned array to later case statement more straightforward - -commit 417b1a36447cb2c650de55b433ba623541fb8bb3 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-28 02:55:43 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-28 21:20:06 +0900 - - Fix memory leak for iclass - - [Bug #19550] - - If !RCLASS_EXT_EMBEDDED (e.g. 32 bit systems) then the rb_classext_t is - allocated throug malloc so it must be freed. - - The issue can be seen in the following script: - - ``` - 20.times do - 100_000.times do - mod = Module.new - Class.new do - include mod - end - end - - # Output the Resident Set Size (memory usage, in KB) of the current Ruby process - puts `ps -o rss= -p #{$$}` - end - ``` - - Before this fix, the max RSS is 280MB, while after this change, it's - 30MB. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7597 - -commit 6ce6b4d1e7a6f6f20b232e8fc744c303bfd87098 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2023-03-28 21:01:44 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2023-03-28 21:01:59 +0900 - - Use merge_group - -commit c86ccccbd75061f4af0893a03951400227ed76e3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-28 17:58:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-28 18:02:50 +0900 - - Revert "RBS: Pathname#taint and Pathname#untaint are removed" - - This reverts commit 46132e78b7438389bf49a860a0cd8957f685dcb3, in favor - of 298cb57c115e789c021962c758eb734c2d8ee1f6. - -commit 6b05f125bb721ee7f2c91b7744475f947d3a8295 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-27 15:41:56 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-28 17:17:51 +0900 - - Skip commits only for tools - - Get rid of accidents like 67feb782f947046f65951303893713052a19a546. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7601 - -commit 98b409cb9ce2c93c8df7e0f0713e1e771c84c047 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-28 00:51:13 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-28 17:17:51 +0900 - - Set FILTER_BRANCH_SQUELCH_WARNING only in child environment - - Notes: - Merged: https://github.com/ruby/ruby/pull/7601 - -commit f6adc5be94a9f70a5b9897b81dabdeb49b573393 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-28 00:41:08 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-28 17:17:51 +0900 - - Check if Bundler is defined - - Notes: - Merged: https://github.com/ruby/ruby/pull/7601 - -commit 040fab3782fe787423f050ff6e68d9da4f1a5974 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-28 11:20:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-28 17:14:34 +0900 - - Ripper: Add keyword options to `assert_parse_files` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7602 - -commit 9891797a277eb61f56fcde71cc78a6196d3886be - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2023-03-28 14:25:31 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2023-03-28 16:57:55 +0900 - - Use 3 way merge for merger.rb - - Since --3way insists --index, git diff needs to compare with HEAD. - -commit d766d5346b5bf624c4666c813c7bb25485e826d7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-28 13:09:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-28 16:26:46 +0900 - - [rubygems/rubygems] Partly reverted - https://github.com/rubygems/rubygems/pull/6541 - - https://github.com/rubygems/rubygems/commit/21e07a04a1 - -commit 80be2e6c9ae419a69440c545f1338498a6bac939 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-28 11:02:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-28 15:27:58 +0900 - - Use URI-0.12.1 - -commit 1cbb5011274399527c26eb3c6dd98c7947140f83 - Author: Josef Šimánek <josef.simanek@gmail.com> - AuthorDate: 2023-03-25 04:41:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-28 15:27:35 +0900 - - Onboard Rubocop Naming/MemoizedInstanceVariableName rule to RubyGems. - -commit cd4b4ac73763b6d5e0c8f296af90a6cfdd77fd1c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-27 12:06:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-28 15:25:45 +0900 - - [rubygems/rubygems] Use double-quotes instead of single-quotes in warnings - - https://github.com/rubygems/rubygems/commit/c7f1cb9941 - -commit 9cfd8330ca875a60c057f97eafb151682dcc581b - Author: Josef Šimánek <josef.simanek@gmail.com> - AuthorDate: 2023-03-25 05:00:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-28 15:25:44 +0900 - - [rubygems/rubygems] Onboard Rubocop Naming/MemoizedInstanceVariableName rule to Bundler. - - https://github.com/rubygems/rubygems/commit/d768be0c65 - -commit 4d4743f7e35ea9d97cde10c9ca6fc35ac568bdb1 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-25 00:25:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-28 15:25:42 +0900 - - [rubygems/rubygems] Fix installing plugins in frozen mode - - Plugins don't use a lockfile, so ignore frozen related settings. - - https://github.com/rubygems/rubygems/commit/f17a3bb81f - -commit 674c960513b6c77aa4d6e35034441f90fe16a9da - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-17 01:45:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-28 15:25:42 +0900 - - [rubygems/rubygems] Fix incorrect removal of "ruby" platform from lockfile - - When dependencies have changed, we'll be re-resolving, and we can't - really know whether the resolution will be valid or invalid for the Ruby - platform, so skip the removal in that case. - - The fix worked, but made some other specs fail, and surfaced that the - `@dependencies_changed` attribute was actually being incorrect set when - explicitly unlocking. Fixed that with an early return. - - https://github.com/rubygems/rubygems/commit/20d8f5e5d9 - -commit ed868f9a71707d5f51caddbf345e0fde8c940c42 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-24 04:33:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-28 15:25:41 +0900 - - [rubygems/rubygems] Fix unnecessary downgrade of top level dependency when unlocking - - Bundler is very conservative by default, trying to preserve versions - from the lockfile as possible, and never downgrading them. However, when - it runs into a resolution error, it still tries to find a valid - resolution. - - This fallback behavior was too "brute-force" though, completely - unrestricting any gem found in the resolution conflict, and that could - lead to direct dependencies being downgraded in some edge cases. - - Instead, unlock things a bit more carefully: - - * First try unlocking fully pinned indirect dependencies, but leave a - lower bound requirement in place to prevent downgrades. - * Then try unlocking any fully pinned dependency, also leaving a lower - bound requirement in place. - * Finally completely unrestrict dependencies if nothing else worked. - - https://github.com/rubygems/rubygems/commit/7f55ed8302 - -commit eaddd386ecf3cf7efb0857e07dbcd66776dd4954 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-24 04:29:24 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-28 15:25:40 +0900 - - [rubygems/rubygems] Also set min locked requirements when not unlocking - - https://github.com/rubygems/rubygems/commit/3561ac23d6 - -commit 298cb57c115e789c021962c758eb734c2d8ee1f6 - Author: Masataka Pocke Kuwabara <kuwabara@pocke.me> - AuthorDate: 2023-03-28 14:01:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-28 14:01:07 +0900 - - Update rbs's commit hash to avoid test failure on pathname (#7596) - - Notes: - Merged-By: pocke <p.ck.t22@gmail.com> - -commit 7600e6bc19cd65ebbe328b2df0c8cb3d084240ea - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-28 13:55:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-28 13:56:39 +0900 - - RJIT: Optimize definedivar using shapes - -commit 120d8d0ae2d6db4756f6d10ebff5626814cd3d25 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-24 16:44:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-28 11:12:22 +0900 - - [ruby/uri] Bump version to 0.12.1 - - https://github.com/ruby/uri/commit/5c4f7d04bf - -commit 23f4904f4e8aa1f7ace5f50cd14b950567dca58c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-01-10 01:12:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-28 11:12:22 +0900 - - [ruby/uri] Fix quadratic backtracking on invalid URI - - https://hackerone.com/reports/1444501 - - https://github.com/ruby/uri/commit/2f9585de17 - -commit 9c687c65ee177f0bb160dbcb090bfcc5f59620f1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-01-10 01:12:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-28 11:12:21 +0900 - - [ruby/uri] Test for quadratic backtracking on invalid URI - - https://hackerone.com/reports/1444501 - - https://github.com/ruby/uri/commit/54abaa739b - -commit 708c4903e1a41decd39f3ac95f786f15d942982d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-28 09:29:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-28 10:51:41 +0900 - - RBS: Pathname#taint and Pathname#untaint are removed - - Notes: - Merged: https://github.com/ruby/ruby/pull/7598 - -commit 67f37b010a6bcaab90255f3899a504346dbfac63 - Author: Michael Siegfried <michaeldsiegfried@gmail.com> - AuthorDate: 2023-03-24 13:55:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-28 10:18:50 +0900 - - Consider prereleases regardless of whether locked - - Prereleases are NOT considered even when the dependency specification - includes a prerelease segment, if the dependency is not locked. To me - that doesn't make sense, because I could create a Gemfile with say gem - "rails", ">= 7.0.0.beta1" and I'd expect prereleases considered there - even if there's no lock file yet. - - Co-authored-by: David Rodríguez <deivid.rodriguez@riseup.net> - -commit b31bd8b8531a7af294a056ce7b1e9c132fa9bcad - Author: Michael Siegfried <michaeldsiegfried@gmail.com> - AuthorDate: 2023-03-24 13:46:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-28 10:18:49 +0900 - - [rubygems/rubygems] Rewrite GemVersionPromoter specs - - Add tests for pre, move more of the setup into a helper method, and - restructure tests. - - There seem to be five considerations for these tests (level, pre, strict, - locked, and whether the current version is a prerelease version, though - the last one overlaps with pre and didn't seem to behave how I expected - under test). Rather than write out the 16 (/32 if the last consideration - is real) combinations, I wrote most with independent tests for each - value. The existing combined tests were maintained (level vs strict) - because these seem the most interrelated. - - https://github.com/rubygems/rubygems/commit/74c23a91b2 - -commit ec14b381c13bf672249999213b22c69888a1763d - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-03-28 00:14:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-28 00:14:56 +0900 - - [ruby/reline] Bump version to 0.3.3 - (https://github.com/ruby/reline/pull/525) - - https://github.com/ruby/reline/commit/8ce176271f - -commit 8f569d41cba4379b8d50d24fdf8c43f43bc3f1b8 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-03-27 22:54:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-27 22:57:16 +0900 - - [ruby/reline] Fix cursor position overrun - (https://github.com/ruby/reline/pull/515) - - * Fix cursor position overrun - - * Remove unnecessary local variable - - Co-authored-by: Stan Lo <stan001212@gmail.com> - - --------- - - https://github.com/ruby/reline/commit/d4ad9b96c8 - - Co-authored-by: Stan Lo <stan001212@gmail.com> - -commit a2ff9423a1ecc4f2831a69f82a60f00c4a3f81a9 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-27 22:40:24 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-27 22:40:24 +0900 - - Allow user defined SIZE_POOL_COUNT - - We shouldn't overwrite the value of SIZE_POOL_COUNT if the user has - specified one. - -commit 36254c5ddf1b1b16fe5f1705227713ee7529b2f5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-27 11:50:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-27 18:47:20 +0900 - - [rubygems/rubygems] Use append_cflags instead of directly append for CFLAGS - - https://github.com/rubygems/rubygems/commit/61ec0c8389 - -commit 3eea85963b35ae17d22030d8dbed1820f1d4a6a5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-16 17:23:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-27 17:45:43 +0900 - - Use gemspec that keeps original dependencies - - Notes: - Merged: https://github.com/ruby/ruby/pull/7321 - -commit 9b7a7e9cef2daa3aec4aeb55205aab9da2db4eb6 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-27 11:42:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-27 16:21:52 +0900 - - [ruby/pathname] Remove taint/untaint methods because they should be removed since Ruby 3.2 released. - - Fixes https://github.com/ruby/pathname/pull/28 - - https://github.com/ruby/pathname/commit/c52fd3a835 - -commit cc8a48a496e4466d50f14473216786bba1e9fc93 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-27 12:28:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-27 12:28:11 +0900 - - Revert an accidentally sync. - - Revert "[ruby/open3] Removed to load jit_support.rb" - - This reverts commit 67feb782f947046f65951303893713052a19a546. - -commit 67feb782f947046f65951303893713052a19a546 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-14 12:29:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-27 12:24:48 +0900 - - [ruby/open3] Removed to load jit_support.rb - - It's removed at https://github.com/ruby/open3/commit/4445b9e2a2dd - - https://github.com/ruby/open3/commit/41b180deab - -commit 3352e76441b9c62704004df065a1a7e7784496a4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-27 11:20:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-27 11:25:17 +0900 - - RJIT: Implement leaf builtin call - -commit ff44e32f929d089fb3a9ce33bc4c7e59f2e0e588 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-27 10:18:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-27 10:32:01 +0900 - - RJIT: Store caller sp after stack overflow check - - and share some code between ISEQ and C calls. - -commit dc270fc6320829c8a5dd8be801702e26806fcf27 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-27 09:41:05 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-27 10:02:25 +0900 - - RJIT: Implement attr_writer - -commit ac458f6bc3c520c9f23364c85bfb033acda907a6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-26 23:10:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-26 23:10:50 +0900 - - Historical timezones of Lisbon in tzdata are unstable - -commit d51529244ff5b10fa280c559d2d21383f5a5f842 - Author: Kazuki Tsujimoto <kazuki@callcc.net> - AuthorDate: 2023-03-26 18:09:43 +0900 - Commit: Kazuki Tsujimoto <kazuki@callcc.net> - CommitDate: 2023-03-26 18:57:34 +0900 - - [Bug #19175] p_kw without a sub pattern should be `assignable' - -commit 6c0925ba7017efde6091e2ec4f1a6be268166696 - Author: Kazuki Tsujimoto <kazuki@callcc.net> - AuthorDate: 2023-03-26 15:33:43 +0900 - Commit: Kazuki Tsujimoto <kazuki@callcc.net> - CommitDate: 2023-03-26 18:56:21 +0900 - - [Bug #19175] p_rest should be `assignable' - - It should also check for duplicate names. - -commit 2f916812a9b818b432ee7c299e021ec62d4727fb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-26 15:23:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-26 15:23:11 +0900 - - Skip test_europe_lisbon on macOS - - until we figure out why it's failing. - -commit ddb77dd11e5030b9d7dbf1f3e93e5e4cad1268b3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-26 14:13:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-26 14:14:07 +0900 - - RJIT: Put a guard for splat w/ var-arg cfunc - -commit a624a5d709e6ee76cbda63b09fe1f99ae6c0e9be - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-26 13:57:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-26 13:57:04 +0900 - - RJIT: Scope down send_iseq_complex_has_block exit - -commit 1396b83153d395c4c672846749d7ec53b80d3d2a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-26 13:43:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-26 13:43:15 +0900 - - RJIT: Fix jit_array_ptr - - array_reg was clobbered before being used by heap_ptr_opnd. - heap_ptr_opnd should be loaded before array_reg is clobbered. - -commit 60ca800d4fc410ea9d49ef24dfb80577d4183f15 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-03-26 00:01:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-26 00:01:35 +0900 - - [ruby/reline] Fix split_by_width to retain color sequences - (https://github.com/ruby/reline/pull/490) - - * Fix split_by_width to retain color sequences - - * Add OSC escape sequence testcase of Reline::Unicode.split_by_width - -commit 9bc2dbd33cd25281fe14d01bbe5b460176db1010 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-25 17:07:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-25 17:17:05 +0900 - - RJIT: Support optional params on splat - -commit 85a55d3e75fd98e7a0462ad289630d64ff31da84 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-25 16:59:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-25 16:59:47 +0900 - - RJIT: Remove send_iseq_complex_splat exit - -commit 314c7dd6d1ef99c90b851fb5f5585ca449d3715a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-25 16:52:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-25 16:52:07 +0900 - - RJIT: Support splat for cfunc - -commit 1dd65f7c55d146c9ea968385c9a733bdc47f024a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-22 14:55:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-25 16:31:11 +0900 - - RJIT: Initial support of splat - -commit 466aa8010fb49f9ec6c78ea1de4e8ca0965f4fdf - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-03-25 14:36:27 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-25 14:36:27 +0900 - - Fix incorrect usage of `rb_fiber_scheduler_io_(p)(read|write)`. (#7593) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 276f4be96df08becfc59ef253025c2e5f19718fa - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-03-24 22:30:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-25 09:31:46 +0900 - - [rubygems/rubygems] Generate native gems with `-fvisibility=hidden` - - I recently ran into very nasty issues with dynamic symbols clashing between - two native gems. - - I believe the overwhelming majority of native gems don't want to export - their symbols, so hidding them by default would make sense to me. - - https://github.com/rubygems/rubygems/commit/449624aa54 - -commit c08fe408722d28daebaa62f0b820147b0d66986f - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-03-25 08:16:32 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-03-25 08:16:32 +0900 - - Fix Dir.for_fd call-seq - -commit 09295ea796900fb7b05d29e93364090e21598566 - Author: Kasumi Hanazuki <kasumi@rollingapple.net> - AuthorDate: 2023-03-25 08:12:23 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-25 08:12:23 +0900 - - IO::Buffer#resize: Free internal buffer if new size is zero (#7569) - - `#resize(0)` on an IO::Buffer with internal buffer allocated will - result in calling `realloc(data->base, 0)`. The behavior of `realloc` - with size = 0 is implementation-defined (glibc frees the object - and returns NULL, while BSDs return an inaccessible object). And - thus such usage is deprecated in standard C (upcoming C23 will make it - UB). - - To avoid this problem, just `free`s the memory when the new size is zero. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 59c3fac6c4d803019095eebb92b0d2862450ded6 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-03-25 06:01:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-25 06:01:59 +0900 - - YJIT: Rest and block_arg support (#7584) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 27b1a2992f7bebd9db0b0779cc7fe9b9faf5dca4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-24 18:07:02 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-03-25 05:52:55 +0900 - - Adjust SHAPE_BUFFER_SIZE with shape_id_t - - On platforms where `shape_id_t` is 16-bits, 0x80000 is out of range of - this type. - - ``` - ../src/shape.c: In function ‘shape_alloc’: - ../src/shape.c:129:18: warning: comparison is always false due to limited range of data type [-Wtype-limits] - 129 | if (shape_id == MAX_SHAPE_ID) { - | ^~ - ``` - -commit 6c60006de5cfd75f10a1b4a3d822e2de41d22db6 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-02-11 03:33:53 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-03-25 04:29:00 +0900 - - Raise ArgumentError if IO.read is provided negative offset - - Fixes [Bug #19380] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7289 - -commit 836e9a192ba4fdc56a2d3d94f5840869f77fd3bf - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-02-10 06:34:37 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-03-25 03:18:57 +0900 - - Add Dir.for_fd - - This returns a Dir instance for the given directory file descriptor. - If fdopendir is not supported, this raises NotImplementedError. - - Implements [Feature #19347] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7135 - -commit 3be65f63c79492908e898d8d7281035445a2b9a1 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-02-10 05:45:52 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-03-25 03:18:57 +0900 - - Add Dir#chdir - - This uses Dir.fchdir if supported, or Dir.chdir otherwise. - - Implements [Feature #19347] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7135 - -commit 466ca7ae205126c7cac83735db887d69e293f816 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-01-17 06:29:43 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-03-25 03:18:57 +0900 - - Add Dir.fchdir - - This is useful for passing directory file descriptors over UNIX - sockets or to child processes to avoid TOCTOU vulnerabilities. - - The implementation follows the Dir.chdir code. - - This will raise NotImplementedError on platforms not supporting - both fchdir and dirfd. - - Implements [Feature #19347] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7135 - -commit 5d6579bd9129cfbd62702fb42b249338807a34a2 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2022-11-10 02:59:25 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-03-25 02:55:13 +0900 - - Change Hash#compact to keep default values and compare_by_identity flag - - The documentation states it returns a copy of self with nil value - entries removed. However, the previous behavior was creating a - plain new hash with non-nil values copied into it. This change - aligns the behavior with the documentation. - - Fixes [Bug #19113] - - Notes: - Merged: https://github.com/ruby/ruby/pull/6702 - -commit 1b13db25d8ed0f328acc4e86668f8ad7deae7221 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2022-11-10 02:37:04 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-03-25 02:55:13 +0900 - - Copy compare_by_identity flag for empty hashes in Hash.ruby2_keywords_hash - - This was already copied for non-empty hashes. As Hash.ruby2_keywords_hash - copies default values, it should also copy the compare_by_identity flag. - - Partially Fixes [Bug #19113] - - Notes: - Merged: https://github.com/ruby/ruby/pull/6702 - -commit d3197def882b47e7c57cdddfe8d62f62fef9d3f7 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2022-11-10 02:23:45 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-03-25 02:55:13 +0900 - - Do not copy compare_by_identity flag for non-empty hashes in Hash.[] - - It wasn't copied for empty hashes, and Hash.[] doesn't copy the - default value, so copying the compare_by_identity flag does not - make sense. - - Partially Fixes [Bug #19113] - - Notes: - Merged: https://github.com/ruby/ruby/pull/6702 - -commit 35e9b5348d91eff13d2bdc487003f46a19586d42 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-25 01:36:06 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-25 01:36:06 +0900 - - YJIT: Constify EC to avoid an `as` pointer cast (#7591) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 7149f5763ea121b71ad0763cd8554bc663d8eedd - Author: MSP-Greg <Greg.mpls@gmail.com> - AuthorDate: 2023-03-24 00:44:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-24 22:00:53 +0900 - - [rubygems/rubygems] remove test skips/pends on mswin platform - - https://github.com/rubygems/rubygems/commit/1d52eff8bf - -commit 2759cf46f28b1f5ba52f6b7686fd23cb8d792ede - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-24 15:22:57 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-24 15:41:37 +0900 - - Write keyword arguments directly - - `assert_normal_exit` uses keyword arguments since 2013, commit - 05dd6b194cc29961a7cecfd5c3852f06dd56a871. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7589 - -commit 3e7d1cbceb2b8757a4c07431c8a3a97354506dfd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-24 00:36:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-24 14:22:02 +0900 - - Cache pid itself instead of converted VALUE - - Notes: - Merged: https://github.com/ruby/ruby/pull/7585 - -commit df21e7ebabc661a789be5c2f49cfb4e4b67913b7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-24 13:31:32 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-24 13:31:32 +0900 - - Added sync tools for test libraries like core_assertions.rb to default gems repositories - -commit b4e438d8aabaf4bba2b27f374c787543fae07c58 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-24 05:42:49 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-24 05:42:49 +0900 - - YJIT: Save PC on rb_str_concat (#7586) - - [Bug #19483] - - Co-authored-by: Alan Wu <alansi.xingwu@shopify.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 8286544dc5518f59bd607f6b6f8870fd22b3bac7 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-03-24 02:11:46 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-24 02:11:46 +0900 - - YJIT: Use starting context for status === CantCompile (#7583) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit ed4dc1c33de945401999078bac836dc882aa8ba2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-24 01:46:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-24 01:46:59 +0900 - - Fix ENABLE_MULTIARCH - - This macro is used in `ruby_init_loadpath()`, but was removed - mistakenly at 31f4b2d86bfbc753cec9be376719acc4b120e944. - -commit e950781880784de843aaad8cb4e38c78f96683b2 - Author: Ole Friis Østergaard <olefriis@gmail.com> - AuthorDate: 2023-03-24 00:04:30 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-24 00:04:30 +0900 - - Use shape information in YJIT's definedivar implementation (#7579) - - * Use shape information in YJIT's definedivar implementation - - * Handle complex shape for definedivar - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit b738cb01b66c7b80364f9044b64097d690e49fc7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-23 21:51:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-23 23:31:46 +0900 - - Suppress -Wsign-compare warning - -commit 310af50c3b320f7dac7c6b1e165f29c7a3d5db4b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-23 20:43:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-23 20:45:58 +0900 - - [ruby/time] Update required ruby version - - `Regexp#match?` which is introduced at ruby 2.4 is used since https://github.com/ruby/time/pull/1852. - - https://github.com/ruby/time/commit/b0a965dcaa - -commit 3563e1383fe4ce13168cd3b9f4d5222d69d00061 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-03-03 16:40:00 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-03-23 18:08:19 +0900 - - thread_pthread.c: Use a `fork_gen` to protect against fork instead of getpid() - - [Feature #19443] - - Until recently most libc would cache `getpid()` so this was a cheap check to make. - - However as of glibc version 2.25 the PID cache is removed and calls to getpid() always - invoke the actual system call which significantly degrades the performance of existing applications. - - The reason glibc removed the cache is that some libraries were bypassing fork(2) - by issuing system calls themselves, causing stale cache issues. - - That isn't a concern for Ruby as bypassing MRI's primitive for forking would - render the VM unusable, so we can safely cache the PID. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7434 - -commit a9146bd81e8a9085cfa920ee485deb43b3a2a776 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-16 23:47:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Don't suggest `--full-index` on API Response mismatch errors - - I've never seen this error in real life, and if it was happening, I - think it's either some server side issue that would need to be fixed or - some transient issue. We should move away from the full index, since - it's slow, so let's stop recommending it. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit c3fa6679e64eb08a68723d3c757ae6dd14384e21 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-16 23:46:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Don't suggest retrying with `--full-index` on gemspec errors - - We're actually already using the full index here, so it makes no sense - to suggest retrying the same thing. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 164dc580084b10d46f1c44de5c36d907b0f6a385 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-16 23:44:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Fix logging the fallback to the full index on GemspecError's - - The debug message suggests retrying using `--full-index`, but the retry - is happening automatically. Just log that we are falling back to the - full index, like we do with other errors. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 069640d3558022913ef164e2b73ef477b8f89a79 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-03-17 01:31:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Avoid intermediate array in TarHeader#calculate_checksum - - String#sum(0) sums the character bytes without a modulo. - Follow-up of #6476 based on comment from @nobu. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit a9fd1860dd30fff3b6e5ad0d65801f8188019325 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-17 23:42:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Fix flaky when making materialized specs uniq - - Sometimes we'll have an heterogenous array of specs which include - `Gem::Specification` objects, which don't define `#identifier`. Let's - use `#full_name` consistently. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 6ad6ae680a0f92cfa91c727701eb67150ffd4a27 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-17 18:04:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Skip test_gem_with_platform_and_platform_dependencies only ruby/ruby repository - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 1b408e659a5d754415a760edc483517dce0e2631 - Author: なつき <i@ntk.me> - AuthorDate: 2023-03-18 01:48:52 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Refactor and fix usage of Gem.ruby - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 22d037f4ccd6d04cd1ee9aa7dd6f0e6019b5df2b - Author: なつき <i@ntk.me> - AuthorDate: 2023-03-18 01:16:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Move duplicated logic to parent class - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit e46d473396401f8f320b4a5b8f638630ab42fa4c - Author: なつき <i@ntk.me> - AuthorDate: 2023-03-17 10:09:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Make sure native extensions are loaded correctly in ext_conf builder - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit f8ecf145cee5a2af4cf48a2c0b6bf600886b8b96 - Author: なつき <i@ntk.me> - AuthorDate: 2023-03-16 12:52:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Make sure native extensions are loaded correctly in rake builder - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit a757e21bc0ab1a9595ddad38e92f3941caf84d98 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-17 04:15:52 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Reuse `SpecSet#materialize` logic - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit ebebc90ec297c945cdf94c90f8db85dd7ddbcb7b - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-17 04:11:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Refactor incomplete specs handling - - Recent bugs fixed made me realize we were relying on state too much - here. We only need to keep incomplete specs to be able to expire them - and retry resolution without them locked. If we use a separate class, we - can do that more transparently and handle them just like we handle - "missing specs". - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 8e6bbc032c1bde617a45e418af697831df471083 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-17 02:37:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Don't remove RUBY platform when healing a lockfile with missing specs - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 4e7c39f98ceaf5160d9a97b7d2405623f972773a - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-17 21:39:20 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - Don't remove RUBY platform when healing a lockfile with missing specs - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit acf12b6dfdd94ce1da55eaf2dfacc75135385c2a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 14:18:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - util/rubocop -A --only Style/AsciiComments - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit f24a86d83f07f214e97aa98da190cda55092805f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-17 18:36:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - util/rubocop -A --only Layout/EmptyLineAfterMagicComment - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 4dd418f87783ba982a1ef7211bc675ed64bcb447 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-17 18:33:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - util/rubocop -A --only Style/FrozenStringLiteralComment - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 50a03035ee79947a8327fec4f4de121c5a6b6eb5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 12:13:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - util/rubocop -A --only Lint/NonLocalExitFromIterator - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 2e3cd1dc3e30f4725b18032b85a36f208c9528bc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-23 10:16:17 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] Enabled Style/RedundantReturn cop - - https://github.com/rubygems/rubygems/commit/05cc97bdf8 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 19e9c4004b9d137ad48757f3f4c2d92257e6c2c4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 14:54:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/BinaryOperatorWithIdenticalOperands - - Many of class of RubyGems have original <=> methods. We should ignore - these cops for testing. - - https://github.com/rubygems/rubygems/commit/0a8645dc3b - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit a3670249fa96f9d6d9d630e43f4edaafdd55e7af - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 14:35:56 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/Void - - https://github.com/rubygems/rubygems/commit/9d25906e44 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 048230ded3d0ed217bff5e7ac5e4e4972dd08312 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 13:54:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/RequireParentheses - - https://github.com/rubygems/rubygems/commit/ee6814afbc - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 0eef33e113e61f0d6efcf47f93602bd9d68f68d2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 13:26:37 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/Next - - https://github.com/rubygems/rubygems/commit/e5868e92f7 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit bec069b0cae3934bb2caee3aad7fbf587ab95937 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 13:17:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/MultilineMemoization - - https://github.com/rubygems/rubygems/commit/c1f6e4a97b - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 8a364b8512b84530cadfe9f27557fa0306ad9856 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 13:14:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/MultilineTernaryOperator - - https://github.com/rubygems/rubygems/commit/be853dfe3b - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 5efadf81393f3395837fede8f078ac97e485e4a5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 12:55:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/ShadowingOuterLocalVariable - - https://github.com/rubygems/rubygems/commit/82ed77178d - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 8260698e74e6601e6183334471467f9d60dbd75e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 12:48:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/UnreachableCode - - https://github.com/rubygems/rubygems/commit/f06047f52a - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 01be518eba03e4133a93cbd5dec79678ae430bfc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 12:47:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/UnderscorePrefixedVariableName - - https://github.com/rubygems/rubygems/commit/6dc4bc3a5b - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit ec131071b958b2f86e9c043fa65b51f21e2ed72c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 12:29:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/ReturnInVoidContext - - https://github.com/rubygems/rubygems/commit/021823a331 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 1a600126126e2f531377646e929280c756e69929 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 12:25:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/RescueException - - https://github.com/rubygems/rubygems/commit/e8a5db50af - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 25ed2e7415ded52837e3ade1b43efe1def9493d2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 12:10:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/EmptyExpression - - Thread.report_on_exception is always defined after Ruby 2.4 or later. - - https://github.com/rubygems/rubygems/commit/274da54f38 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit 7e3612585da4ffa8440d1120043f7dca00c32624 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 12:08:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-23 17:18:49 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/DuplicateCaseCondition - - https://github.com/rubygems/rubygems/commit/df2b192e47 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7582 - -commit db7c38634e8e9d1017210759f99f772a88f576c4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-23 01:13:23 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-23 14:49:41 +0900 - - core_assertions.rb: Raise `Timeout::Error` explicitly - - So that `assert_raise` inside the block works. - -commit 0112a5b3423ddb2ddf46c4392f23f9b75128568e - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-10 01:33:00 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-23 14:03:12 +0900 - - `Array#first` and `Array#last` in Ruby - - Notes: - Merged: https://github.com/ruby/ruby/pull/7486 - -commit c9fd81b860b5ec193ba57c73c740955937452497 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-10 01:30:30 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-23 14:03:12 +0900 - - `vm_call_single_noarg_inline_builtin` - - If the iseq only contains `opt_invokebuiltin_delegate_leave` insn and - the builtin-function (bf) is inline-able, the caller doesn't need to - build a method frame. - - `vm_call_single_noarg_inline_builtin` is fast path for such cases. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7486 - -commit e5a5e43c36443e06756aba6de95c94b41b910a82 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-17 16:00:34 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-23 14:03:12 +0900 - - should not restore builtin_inline_index - - `builtin_inline_index` is restored because THEN clause on - `Primitive.mandatory_only?` was compiled twice. - - However, f29c9d6d36 skips to compile THEN clause so we don't - need to restore `builtin_inline_index`. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7486 - -commit 3210130993f09d66fa1f21be114cad532fe1974f - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-23 05:36:47 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-23 06:25:18 +0900 - - Suppress a compiler warning on GCC in process.c - - rb_pid_t is 32 bits on some platforms, which will cause a warning on GCC - due to POSFIXABLE always returning true. - - include/ruby/internal/arithmetic/fixnum.h:43:31: warning: comparison is always true due to limited range of data type [-Wtype-limits] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7580 - -commit 348412c7fa0230925c3b1ffc94e64367273da42d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-21 18:57:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-23 06:21:08 +0900 - - [rubygems/rubygems] Use indented heredoc - - https://github.com/rubygems/rubygems/commit/085d2776d8 - -commit 7c307e0379e3c6c07d821b863fefbdfdfc84c4f1 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-03-14 07:07:09 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-03-23 04:50:42 +0900 - - Lazily allocate id tables for children - - This patch lazily allocates id tables for shape children. If a shape - has only one single child, it tags the child with a bit. When we read - children, if the id table has the bit set, we know it's a single child. - If we need to add more children, then we create a new table and evacuate - the child to the new table. - - Co-Authored-By: Matt Valentine-House <matt@eightbitraptor.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7512 - -commit 0519741702a016e3e44554bb906de0d18c719ead - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-03-10 08:58:22 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-03-23 04:50:42 +0900 - - pull child allocation in to a different function - - Notes: - Merged: https://github.com/ruby/ruby/pull/7512 - -commit 999ccb2b6b244e8a128ce8ff32665f83e2da535f - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-03-23 00:47:29 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-03-23 04:50:42 +0900 - - combine allocation functions - - Notes: - Merged: https://github.com/ruby/ruby/pull/7512 - -commit e055c0c7162d7d240c93227397cf3eca01ca86e7 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-03-10 08:50:58 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-03-23 04:50:42 +0900 - - Make shape functions static - - These functions don't need to be in the header file, we can declare them - as static. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7512 - -commit 1a9e2d20e2c66933f8eb891a1ee85fae6015fcf1 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-03-18 03:39:35 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-03-23 00:46:12 +0900 - - Fix shape allocation limits - - We can only allocate enough shapes to fit in the shape buffer. - MAX_SHAPE_ID was based on the theoretical maximum number of shapes we - could have, not on the amount of memory we can actually consume. This - commit changes the MAX_SHAPE_ID to be based on the amount of memory - we're allowed to consume. - - Co-Authored-By: Jemma Issroff <jemmaissroff@gmail.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7556 - -commit e340eb2106544dffe909104df1ff61236f70f280 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-22 23:07:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-22 23:07:26 +0900 - - core_assertions.rb: Fix backward compatibility with pre 2.7 - -commit 27916db08cd446214b4d84b5aca7fcdf3147e2ef - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-22 22:35:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-22 22:35:58 +0900 - - [DOC] Update comment of assert_pattern_list - - `pattern_list` may contain string since d903e7672637. - -commit aa5d1957121bf6321f560754f316c553f60dcaae - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-18 10:26:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-22 20:17:26 +0900 - - [rubygems/rubygems] @orig_RUBY_ENGINE is always provided now - - https://github.com/rubygems/rubygems/commit/c5e8ad4823 - -commit 169786950038e9092ad6971c9a08e77fd439b014 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 17:11:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-22 20:17:26 +0900 - - [rubygems/rubygems] Fix test failure with missing RUBY_REVISION constants - - https://github.com/rubygems/rubygems/commit/c5b80945c6 - -commit 372585029787014f71f262a149d68ff1ae50e17b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 16:38:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-22 20:17:25 +0900 - - [rubygems/rubygems] ditto: RUBY_ENGINE_VERSION - - https://github.com/rubygems/rubygems/commit/dc82ebeac6 - -commit 3dc4bc313fc7b1aa731b473ac6a7634000b71e9c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 15:09:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-22 20:17:25 +0900 - - [rubygems/rubygems] RUBY_REVISION is also provided by supported platforms - - https://github.com/rubygems/rubygems/commit/71a237aeec - -commit ea1dcb3e239bb980bf1fef70ee0ac8315bdb1e01 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 15:05:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-22 20:17:24 +0900 - - [rubygems/rubygems] RUBY_DESCRIPTION is always provided by supported platforms - - https://github.com/rubygems/rubygems/commit/8a7028bc7e - -commit 92f78b0e0b4bcb9b8768fe61d4a18ddae254eead - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 15:04:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-22 20:17:24 +0900 - - [rubygems/rubygems] Fixup - https://github.com/rubygems/rubygems/pull/6486 - - https://github.com/rubygems/rubygems/commit/ad50221acf - -commit 09bda4ceb592801d1729a2e7b4aea164dc855f6d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-22 17:58:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-22 18:53:12 +0900 - - core_assertions.rb: Refine `assert_linear_performance` - - * Calculate each timeout from the ratio of each factor to the first - factor. - -commit 6cc8eb4daadbbc0cf3b6be4bed48f7d5a476f557 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-22 18:42:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-22 18:53:11 +0900 - - Should not reach end of non-void function - -commit 8c00b130a4dd0914a311f3ef96d1311d99992ea5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 18:07:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-22 18:07:40 +0900 - - Fixup 43d20596b8fefadc309348448352bf13615129c6 - -commit 464a264cd42abecf4cfaa425ece42515e6c08509 - Author: Justin Searls <searls@gmail.com> - AuthorDate: 2023-03-20 21:52:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-22 17:32:03 +0900 - - [rubygems/rubygems] Remove reference to `pry` gem from generated `bin/console` file - - This is just a suggestion, but since recent versions of Ruby have shipped with a `binding.irb` that provides almost all of the features that `pry` pioneered, it may be time to remove this suggestion in the name of simplicity and not confusing newer developers who aren't familiar with what to use. - -commit 43d20596b8fefadc309348448352bf13615129c6 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 16:32:23 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-22 16:32:23 +0900 - - Relax timeout limit for FreeBSD - - * http://rubyci.s3.amazonaws.com/freebsd12/ruby-master/log/20230322T063002Z.fail.html.gz - * http://rubyci.s3.amazonaws.com/freebsd13/ruby-master/log/20230322T063002Z.fail.html.gz - -commit 8d1109c03bacc952b6218af2e4ae9b74c9855273 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-22 16:10:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-22 16:10:06 +0900 - - Added assertion values for Amazon Linux 2023 - -commit cb4580945424f91072fcf799e9eb6a6dbbd82d30 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-22 14:28:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-22 14:28:39 +0900 - - RJIT: Update binding - -commit 7947920ee7b64b82365ba174756fc7162469ba67 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-22 14:12:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-22 14:12:43 +0900 - - RJIT: Follow a recent CALLER_SETUP_ARG change - -commit 38946209a7361ca8cab15df7e9d28ea7746eb4f2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-21 16:12:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-22 14:01:55 +0900 - - RJIT: Split has_rest_or_post exit reasons - -commit 08eaf7c5fab7b43f5ff1bbfd4ce1696a30ed802c - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-22 07:16:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-22 07:16:33 +0900 - - YJIT: Fix deadlock in tests due to pipe capacity - - Previously, when there is enough stats that the child process fills up - the pipe capacity, the child process would block, with the parent - process waiting forever as no one is reading to clear up the pipe. The - test timed out in these situations. - - Use a separate thread in the parent to read from the pipe to unblock the - child in these situation. EnvUtil also does this for handling stdout and - stderr. - - I had the test suite deadlock on a Linux VM. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7578 - - Merged-By: XrXr - -commit aa54082d70d06bf2dd0d535bb06287b80bb2727f - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-22 03:24:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-22 03:24:17 +0900 - - YJIT: Fix large ISeq rejection (#7576) - - We crashed in some edge cases due to the recent change to not compile - encoded iseqs that are larger than `u16::MAX`. - - - Match the C signature of rb_yjit_constant_ic_update() and clamp down - to `IseqIdx` size - - Return failure instead of panicking with `unwrap()` in codegen when - the iseq is too large - - Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - Co-authored-by: Noah Gibbs <noah.gibbs@shopify.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 5de26bc0319d8b0de315cb90e68345a816673fa6 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-03-22 01:57:26 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-22 01:57:26 +0900 - - YJIT: Fix incorrect exit in splat (#7575) - - So by itself, this shouldn't have been a correctness issue, but we - also pop the stack for block_args. Doing stack manipulation like that - and then side-exiting causes issues. So, while this fixes the - immediate failure, we have a bigger issue with block_args popping and - then exiting that we need to deal with. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit f62fa5128301f07352b215ef118fa5264800ad0b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-21 19:00:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-22 00:05:29 +0900 - - [ruby/erb] [DOC] Use indented heredoc - - https://github.com/ruby/erb/commit/8ba8bb7acf - -commit 30e7561d1d21844bd6fc7a2ced12cd08cf3ea5ea - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-21 23:51:35 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-21 23:51:35 +0900 - - Revert "YJIT: Rest and block_arg support (#7557)" - - This reverts commit 5d0a1ffafa61da04dbda38a5cb5565bcb8032a78. - - This commit is causing sequel in yjit-bench to raise with this stack trace: - - ``` - sequel-5.64.0/lib/sequel/dataset/sql.rb:266:in `literal': wrong argument type Array (expected Proc) (TypeError) - from sequel-5.64.0/lib/sequel/database/misc.rb:269:in `literal' - from sequel-5.64.0/lib/sequel/adapters/shared/sqlite.rb:314:in `column_definition_default_sql' - from sequel-5.64.0/lib/sequel/database/schema_methods.rb:564:in `block in column_definition_sql' - from sequel-5.64.0/lib/sequel/database/schema_methods.rb:564:in `each' - from sequel-5.64.0/lib/sequel/database/schema_methods.rb:564:in `column_definition_sql' - from sequel-5.64.0/lib/sequel/database/schema_methods.rb:634:in `block in column_list_sql' - from sequel-5.64.0/lib/sequel/database/schema_methods.rb:634:in `map' - from sequel-5.64.0/lib/sequel/database/schema_methods.rb:634:in `column_list_sql' - from sequel-5.64.0/lib/sequel/database/schema_methods.rb:753:in `create_table_sql' - from sequel-5.64.0/lib/sequel/adapters/shared/sqlite.rb:348:in `create_table_sql' - from sequel-5.64.0/lib/sequel/database/schema_methods.rb:702:in `create_table_from_generator' - from sequel-5.64.0/lib/sequel/database/schema_methods.rb:203:in `create_table' - from benchmarks/sequel/benchmark.rb:19:in `<main>' - ``` - -commit f67f0d72688679267c4040c5f6aa8c493067704a - Author: Phillip Hellewell <sshock@users.noreply.github.com> - AuthorDate: 2023-03-21 23:48:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-21 23:48:32 +0900 - - [ruby/reline] Add key bindings for PgUp and PgDn - (https://github.com/ruby/reline/pull/509) - - * Add key bindings for PgUp, PgDn - - * Match behavior of readline 8.2 - - In the latest readline (8.2), page-up and page-down are bound to - history-search-backward and history-search-forward by default. - - We would like reline to have the same default behavior. - -commit 9b85ff01a15a559775cb1df5e32401c9fcc37682 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-21 18:59:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-21 22:59:09 +0900 - - Use indented heredoc - -commit 9aaf2b752685f9e11b28fbe647289f12d75d9f5e - Author: drew-wells <58978640+drew-wells@users.noreply.github.com> - AuthorDate: 2023-03-21 19:10:19 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-21 19:10:19 +0900 - - Update dln.c to fix error output from `dln_open()` - - `libruby_name` gets trashed by `dlclose(handle)`, so output the - "linked to incompatible ... " error before calling `dlclose(handle)`. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7552 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit c44367265daccc504e6ee35eb2ae5712563246c3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-21 16:10:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-21 16:10:14 +0900 - - RJIT: Fix invokesuper - -commit 54dbd8bea8a79bfcdefa471c1717c6cd28022f33 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-03-18 03:29:04 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-03-21 05:54:18 +0900 - - Use an st table for "too complex" objects - - st tables will maintain insertion order so we can marshal dump / load - objects with instance variables in the same order they were set on that - particular instance - - [ruby-core:112926] [Bug #19535] - - Co-Authored-By: Jemma Issroff <jemmaissroff@gmail.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7560 - -commit 51834ff2ec4fba7fa4d62b04365c1c9c5b6700f1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-21 05:03:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-21 05:03:22 +0900 - - YJIT: Make dev_nodebug closer to dev (#7570) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 27ecf3261ed117fdba1987dbb146e2164ed821e9 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-03-21 04:40:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-21 04:40:55 +0900 - - Update yjit.md - - Document `make yjit-smoke-test` - -commit 44f444478afad954f046d8345cafb3842708a4ca - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-03-20 23:16:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-20 23:16:22 +0900 - - YJIT: tag output type as UnknownHeap in `toregexp` (#7562) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 758e4db551e7e80a65b610cc73fcb61e74ec5a0c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-20 18:08:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-20 18:08:05 +0900 - - Mark cached pid if necessary - -commit 1aa255504414d74977130f9086ee35e149cd22e2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-20 17:28:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-20 17:28:24 +0900 - - Fix the macro for condition - -commit 1db8951d3a8be6a756c9d3d3b87231997b301985 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-17 03:36:31 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-03-20 17:21:23 +0900 - - Cache `Process.pid` - - [Feature #19443] - - It's not uncommon for database client and similar network libraries - to protect themselves from Process.fork by regularly checking Process.pid - - Until recently most libc would cache `getpid()` so this was a cheap - check to make. - - However as of glibc version 2.25 the PID cache is removed and calls to - `getpid()` always invoke the actual system call which significantly degrades - the performance of existing applications. - - The reason glibc removed the cache is that some libraries were bypassing - `fork(2)` by issuing system calls themselves, causing stale cache issues. - - That isn't a concern for Ruby as bypassing MRI's primitive for forking - would render the VM unusable, so we can safely cache the PID. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7326 - -commit 70ea58bd5ba42b26ff39f51079af0efa422ac036 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-20 13:18:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 15:58:14 +0900 - - RJIT: Break up RJIT send_iseq_complex exit reasons - -commit 59b86da82c7e175b1a479c82bffe32d6fe394ecb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-20 15:19:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 15:32:07 +0900 - - RJIT: Implement ifunc invokeblock - -commit 47f7ec1c9f9e409ddea0c763b79c4fc9b71da84b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-20 15:11:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 15:14:13 +0900 - - RJIT: Support invokeblock arity mismatches - -commit e3dc25acae03f052e6e8a56868481b9fc2f733ea - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-20 13:49:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 13:52:25 +0900 - - RJIT: Fix ISeq invokeblock - -commit 7aeb9e20b90bf16d25fcc76c619bf971f4c47ec5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-20 13:20:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 13:20:28 +0900 - - RJIT: Disable ISeq invokeblock for now - - since basictest is broken - -commit 7f696b8859e91725262b7dc731078baf8fa95d56 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-20 13:02:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 13:02:21 +0900 - - Remove a warning in bootstraptest/runner.rb - - ../bootstraptest/runner.rb:121: warning: assigned but unused variable - e - -commit 2d8ecfcc9a1cf65104bd0f61542a969dc3bd2317 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-13 14:27:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 12:56:37 +0900 - - RJIT: Implement invokeblock with ISeq - -commit 80890e681a67cdb88953fe6e4840cb257af90171 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-20 12:15:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-20 12:49:58 +0900 - - Disable `-w` on bundler and bundled gems tests - -commit 4f350dbfdd84abbf8cda3974d5d9d79bd0f71f33 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-20 12:27:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 12:27:57 +0900 - - RJIT: Remove an unneeded variable - -commit c6466691be5949cb9840003644ff1362e7cb35b5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-20 11:36:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-20 11:36:46 +0900 - - Enable `-w` option at test - -commit 615f42fd61392dbe40f5232138566313b02a14df - Author: Soutaro Matsumoto <matsumoto@soutaro.com> - AuthorDate: 2023-03-20 10:39:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-20 10:39:17 +0900 - - Add explanation to rbs_skip_tests (#7525) - - Notes: - Merged-By: soutaro <matsumoto@soutaro.com> - -commit 2f29044de48ed3f468c09ea3c5c214791370037f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-20 06:15:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 06:15:45 +0900 - - RJIT: Optimize Kernel#block_given? - -commit 83ad1cac811b144b0016fdbfc9d83c11fd190349 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-20 05:46:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 06:04:58 +0900 - - RJIT: Optimize Kernel#respond_to? - -commit 95c4ced39eb0d25925724456b222a56206b633db - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-20 05:41:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 05:41:04 +0900 - - RJIT: Optimize Array#empty? - -commit cd5a8d01605e2235fe6deaa4f60c212ffaeb4d04 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-20 05:36:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 05:36:26 +0900 - - RJIT: Optimize String#+@ - -commit 2121282753b9faee1ce6f93d6c75b105ad040af0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 15:49:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-20 05:25:41 +0900 - - RJIT: Optimize String#<< - -commit bcd0aa896fe84610cef8dc873239738001283538 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-19 21:57:22 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-19 21:57:22 +0900 - - Fix -Wclobbered warning from gcc 12 - - A variable modified in `EXEC_TAG` block should be `volatile`. - - ``` - ractor.c: In function 'ractor_try_yield': - ractor.c:1251:97: warning: argument 'obj' might be clobbered by 'longjmp' or 'vfork' [-Wclobbered] - 1251 | ractor_try_yield(rb_execution_context_t *ec, rb_ractor_t *cr, struct rb_ractor_queue *ts, VALUE obj, VALUE move, bool exc, bool is_will) - | ~~~~~~^~~ - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7568 - -commit e7342e76dfd26237c604e42f9a59a1eaa578c94e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-15 14:35:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-19 18:10:55 +0900 - - [Bug #19485] [DOC] Mention tabs in indentation of heredoc identifier - - Co-Authored-By: sawa (Tsuyoshi Sawada) <sawadatsuyoshi@gmail.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7526 - -commit 9654a28cc5bbf55e200806a0c62c6e17b1635e1c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 16:06:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 16:06:03 +0900 - - RJIT: Drop duplicated obj_is_kind_of - -commit c4e2718763e1ab2d00f43b0797b4852b5ccf28c8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 15:42:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 15:42:58 +0900 - - RJIT: Workaround USE_RVARGC=0 CI - -commit 32e0c97dfaa7973032e6ab93260be8eb4ad1458a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 15:33:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 15:35:42 +0900 - - RJIT: Optimize String#bytesize - -commit 106cca5111981ce30bb6f4534ff72e8c09ace162 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 15:24:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 15:24:57 +0900 - - RJIT: Optimize String#empty? - -commit ca9355e173043bf2b403640bd88c48ac0d0d59ed - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 15:13:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 15:13:25 +0900 - - RJIT: Optimize Kernel#instance_of? - -commit 824cf889698ec95dd02c126eab5b402adeef36e2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 14:57:31 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 14:59:46 +0900 - - RJIT: Optimize Kernel#is_a? - -commit cc9330f8c0fac9952572a590cb70eb8e63921056 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 14:13:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 14:32:27 +0900 - - RJIT: Reorder opt_case_dispatch branches - -commit d07d1c71622ad8fca1d8f88c865efcdd93c4e894 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 14:03:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 14:03:45 +0900 - - RJIT: Upgrade Ubuntu on CI - - to upgrade libcapstone on CI - -commit 71bcab45191358c3da20559102ede8477bc0a4a1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 13:49:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 13:49:46 +0900 - - RJIT: Implement setclassvariable - -commit 8510f33cc1d7f6b5148d596cfea3fbf734661cd8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 13:42:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 13:42:20 +0900 - - RJIT: Implement intern - -commit 4a8de3fa8872ed43b33f1ae81ae4767f4334283a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 13:39:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 13:39:24 +0900 - - RJIT: Fix toregexp - -commit 9c2792c3d3933d7afeca9c46be9954057d06c5eb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 13:37:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 13:37:49 +0900 - - RJIT: Implement toregexp - -commit d189f8d870aee69e43697415a4840a4d9cdf5a62 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 13:27:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 13:28:55 +0900 - - RJIT: Prefix rjit_options with rb_ - -commit 4e440d6990a1095149a83662f1238d31047c1032 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 13:26:08 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 13:26:09 +0900 - - RJIT: Install libcapstone-dev on CI - - for test_assembler.rb to work - -commit 2eefd71e0f0fe7ab4c4584fc29902034102c5c4a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 13:24:28 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 13:24:31 +0900 - - RJIT: Implement newrange - -commit 81e19b7d9988ced02c80a19ef2ec0f3b7cd8c456 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 13:20:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 13:20:58 +0900 - - RJIT: Implement getglobal - -commit 9f8e914943f812a5036d92648386169079daf51b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-19 13:14:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-19 13:15:22 +0900 - - RJIT: Implement checkkeyword - -commit 67dd52d59cde0d2f1ebb3e299b605ed239b59f5b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-19 01:35:21 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-19 01:35:21 +0900 - - [Bug #19539] Match heredoc identifier from end of line - - Not to ignore leading spaces in indented heredoc identifier. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7566 - -commit e8e7ff1333b9b32d72a1d8f789a186d58c811420 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-03-18 23:37:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-18 23:37:10 +0900 - - [ruby/reline] Fix: line longer than terminal width breaks rendering - (https://github.com/ruby/reline/pull/516) - - https://github.com/ruby/reline/commit/ae5f9b87ab - -commit cb22d78354e201ca74eba68a8b4edefb593e6754 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-17 23:12:37 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-18 22:07:05 +0900 - - Fix frozen status loss when moving objects - - [Bug #19536] - - When objects are moved between size pools, their frozen status is lost - in the shape. This will cause the frozen check to be bypassed when there - is an inline cache. For example, the following script should raise a - FrozenError, but doesn't on Ruby 3.2 and master. - - class A - def add_ivars - @a = @b = @c = @d = 1 - end - - def set_a - @a = 10 - end - end - - a = A.new - a.add_ivars - a.freeze - - b = A.new - b.add_ivars - b.set_a # Set the inline cache in set_a - - GC.verify_compaction_references(expand_heap: true, toward: :empty) - - a.set_a - - Notes: - Merged: https://github.com/ruby/ruby/pull/7553 - -commit dc28ccbb6dd0921a75ed21e9d5a6c6c05a0deecf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-18 16:00:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-18 16:00:18 +0900 - - RJIT: Implement getspecial insn - -commit 93e05aaa74365d24960595832b5b01a050fd6f80 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-18 15:34:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-18 15:46:56 +0900 - - RJIT: Implement putspecialobject insn - -commit 2c8f2871a8aeff592369a993b1d69557160cfa61 - Author: Josef Haider <4835525+djoooooe@users.noreply.github.com> - AuthorDate: 2023-03-18 15:43:54 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-18 15:43:54 +0900 - - Fix handling of 6-byte codepoints in left_adjust_char_head in CESU-8 encoding - - Notes: - Merged: https://github.com/ruby/ruby/pull/7510 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 45a17013aae5ed050b0d425a2dab7cd4547ff359 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-18 15:27:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-18 15:27:16 +0900 - - RJIT: Implement throw insn - -commit 39cd74d2a0c36a76422d3648f076a48fc032d960 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-18 15:17:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-18 15:17:26 +0900 - - RJIT: Use RJIT_STATS on --enable-rjit=dev - - RUBY_DEBUG is too slow. - -commit 644c9985256e8bf52d8ec362dcebe4a437e7fd51 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-18 14:31:41 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-18 14:31:41 +0900 - - RJIT: Support --rjit-stats on release build as well - -commit b9f411b3a855f13b3ab9f5b0fa9845a078e1bc93 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-18 05:43:04 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-03-18 06:32:06 +0900 - - YJIT: Simplify using the BITS associated constant - - All the integer types have it. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7563 - -commit 6ba07df4908d4d9d01ece339219e3b9e07ad1bce - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-03-18 05:16:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-18 05:16:34 +0900 - - YJIT: make type info more specific in gen_fixnum_cmp and gen_opt_mod (#7555) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 7fc796f92af6ddb26df8f1258d3a864a8c6e388d - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-18 05:16:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-18 05:16:17 +0900 - - YJIT: Delete --yjit-global-constant-state (#7559) - - It was useful for evaluating 6068da8937d7e4358943f95e7450dae7179a7763 - but I think we should remove it now to make the logic around - invalidation more straight forward. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 2a26a5e677de61cdba04fc8df63c00d3c3e612a9 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-18 04:07:22 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-03-18 05:15:58 +0900 - - YJIT: Add and use Branch::assert_layout() - - This assert would've caught a bug I wrote while developing - ruby/ruby#7443 so I figured it would be good to commit it - as it could be helpful in the future. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7558 - -commit 5d0a1ffafa61da04dbda38a5cb5565bcb8032a78 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-03-18 05:11:30 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-18 05:11:30 +0900 - - YJIT: Rest and block_arg support (#7557) - - * YJIT: Rest and block_arg support - - * Update bootstraptest/test_yjit.rb - - --------- - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 5897a6f6866e25d90140b2afd17bfdc95b695964 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-03-17 07:27:24 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-03-18 04:20:40 +0900 - - Update Makefile dependencies - - Notes: - Merged: https://github.com/ruby/ruby/pull/7153 - -commit 4f5e29f93028053c14eeea948e01fbd44a889473 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-03-17 07:27:12 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-03-18 04:20:40 +0900 - - Document the declarative marking api - - Notes: - Merged: https://github.com/ruby/ruby/pull/7153 - -commit 22b349294b923990eba299bcf17aa6b1543df700 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-03-17 07:26:34 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-03-18 04:20:40 +0900 - - Implement declarative references for enumerator - - Notes: - Merged: https://github.com/ruby/ruby/pull/7153 - -commit 405966e239d9c443f987e7e8f2cec460ffa2da38 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-03-17 07:26:08 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-03-18 04:20:40 +0900 - - Implement declarative references for dir_data_type - - Notes: - Merged: https://github.com/ruby/ruby/pull/7153 - -commit 7142328a94c85cc5f23630396f248b32133f87ab - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-03-17 07:23:17 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-03-18 04:20:40 +0900 - - [Feature #19406] Allow declarative definition of references - - When using rb_data_type_struct to wrap a C struct, that C struct can - contain VALUE references to other Ruby objects. - - If this is the case then one must also define dmark and optionally - dcompact callbacks in order to allow these objects to be correctly - handled by the GC. This is suboptimal as it requires GC related logic to - be implemented by extension developers. This can be a cause of subtle - bugs when references are not marked of updated correctly inside these - callbacks. - - This commit provides an alternative approach, useful in the simple case - where the C struct contains VALUE members (ie. there isn't any - conditional logic, or data structure manipulation required to traverse - these references). - - In this case references can be defined using a declarative syntax - as a list of edges (or, pointers to references). - - A flag can be set on the rb_data_type_struct to notify the GC that - declarative references are being used, and a list of those references - can be assigned to the dmark pointer instead of a function callback, on - the rb_data_type_struct. - - Macros are also provided for simple declaration of the reference list, - and building edges. - - To avoid having to also find space in the struct to define a length for - the references list, I've chosed to always terminate the references list - with RUBY_REF_END - defined as UINTPTR_MAX. My assumption is that no - single struct will ever be large enough that UINTPTR_MAX is actually a - valid reference. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7153 - -commit 9fd94d6a0cc7626c8abfc9ba05d6f156927ee8f7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-18 03:53:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-18 03:53:17 +0900 - - YJIT: Support entry for multiple PCs per ISEQ (GH-7535) - - Notes: - Merged: https://github.com/ruby/ruby/pull/7535 - - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 3592b24cdc07ed89eecb39161f21fe721a89a5de - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-03-16 17:52:22 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-03-18 02:50:08 +0900 - - ObjectSpace::WeakMap: clean inverse reference when an entry is re-assigned - - [Bug #19531] - - ```ruby - wmap[1] = "A" - wmap[1] = "B" - ``` - - In the example above, we need to remove the `"A" => 1` inverse reference - so that when `"A"` is GCed the `1` key isn't deleted. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7540 - -commit ccd2dbc4c15ffb5bde0141a98ec02603c1597243 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-17 15:53:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-18 02:41:02 +0900 - - core_assertions.rb: Relax `assert_linear_performance` - - * Use an `Enumerable` as factors, instead of three arguments. - - * Include `assert_operator` time in rehearsal time. - - * Round up max expected time. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7554 - -commit 10e4fa3a0f05f72733d132794cedd08906b40196 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-17 04:39:27 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-18 01:30:24 +0900 - - YJIT: Use raw pointers and shared references over `Rc<RefCell<_>>` - - `Rc` and `RefCell` both incur runtime space costs. - In addition, `RefCell` has given us some headaches with the - non obvious borrow panics it likes to throw out. The latest - one started with 7fd53eeb46db261bbc20025cdab70096245a5cbe - and is yet to be resolved. - - Since we already rely on the GC to properly reclaim memory for `Block` - and `Branch`, we might as well stop paying the overhead of `Rc` and - `RefCell`. The `RefCell` panics go away with this change, too. - - On 25 iterations of `railsbench` with a stats build I got - `yjit_alloc_size: 8,386,129 => 7,348,637`, with the new memory size 87.6% - of the status quo. This makes the metadata and machine code size roughly - line up one-to-one. - - The general idea here is to use `&` shared references with - [interior mutability][1] with `Cell`, which doesn't take any extra - space. The `noalias` requirement that `&mut` imposes is way too hard to - meet and verify. Imagine replacing places where we would've gotten - `BorrowError` from `RefCell` with Rust/LLVM miscompiling us due to aliasing - violations. With shared references, we don't have to think about subtle - cases like the GC _sometimes_ calling the mark callback while codegen - has an aliasing reference in a stack frame below. We mostly only need to - worry about liveness, with which the GC already helps. - - There is now a clean split between blocks and branches that are not yet - fully constructed and ones that are "in-service", so to speak. Working - with `PendingBranch` and `JITState` don't really involve `unsafe` stuff. - This change allows `Branch` and `Block` to not have as many optional - fields as many of them are only optional during compilation. Fields that - change post-compilation are wrapped in `Cell` to facilitate mutation - through shared references. - - I do some `unsafe` dances here. I've included just a couple tests to run - with Miri (`cargo +nightly miri test miri`). We can add more Miri tests - if desired. - - [1]: https://doc.rust-lang.org/std/cell/struct.UnsafeCell.html - - Notes: - Merged: https://github.com/ruby/ruby/pull/7443 - -commit c62cf60d187fbe74da97f79148789cdd1bfa0332 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-18 01:06:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-18 01:06:52 +0900 - - Skip a flaky test that might not work - -commit 418cf344fb5f6a69c47039e63b1b7db2a0cd66e3 - Author: lukeg <luke.gru@gmail.com> - AuthorDate: 2023-03-16 01:38:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-18 00:19:40 +0900 - - [ruby/irb] Fix 2 minor issues in test suite - - * undefine Kernel#irb_original_require in without_rdoc method - * Don't rescue all LoadErrors/NameErrors in test_rendering.rb, just - the one for require 'yamatanooroti' - - https://github.com/ruby/irb/commit/52b79806ea - -commit a206ee670969ce213ec0da4d1d5b65d24259efd4 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-17 04:13:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-18 00:12:45 +0900 - - Assume that FL_FINALIZE is in finalizer_table - - If the flag FL_FINALIZE is set, then it's guaranteed to be in the - finalizer_table, so we can directly assume that without checking. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7545 - -commit 11f299fab749bd2e0c5e49ca4db8c9c84b8e5970 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-03-17 23:29:42 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-17 23:29:42 +0900 - - YJIT: skip intermediate arrays in print_sorted_exit_counts (#7547) - - Early total_exits condition. - Replace Array#sort_by/first(how_many) with Array#max_by(how_many). - Replace Array#map/max with Array#max_by, match print_counters style for longest_name_length. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit c65d7b4bea170ffe4811534ab33b231f7f57d69f - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-10 01:34:17 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - When running `bundle lock --update <name>`, checkout locked revision of unrelated git sources directly - - Since Bundler 2.4, we will try to checkout any branch specified in the - Gemfile, while until Bundler 2.3 we would directly checkout the locked - revision. - - This should not make any difference in most situations, but in some edge - cases, like if the branch specified in the `Gemfile` has been renamed, - but the locked revision still exist, it causes an error now while before - it would update the lockfile without issues. - - I debated which behavior was best, since I was not sure. But my - conclusion is that if the situation does not require expiring the - lockfile source in favor of the Gemfile source, we should use the locked - revision directly and proceed happily. So I restored Bundler 2.3 - behavior. - - I think this is consistent with how yanked gems are handled, for example. - - Of course, if explicitly updating the git source itself, or all gems, we - will still get any errors like missing branches related to the git source. - -commit 0b9e51c4294ff938ef8c244f2ca502ec6c230a63 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-08 02:05:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - Don´t consider platform specific candidates when `force_ruby_platform` set - - This was working fine for direct dependencies using - `force_ruby_platform` explicitly through Gemfile, but not for indirect - dependencies. In general, indirect dependencies do not have this - property set, but in truffleruby this is different and the default value - is to have it set. - -commit 12f0be14e2df3450b464c934f82c7b17a1678bd4 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-03 21:34:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - Don't ignore pre-releases when there's only one candidate - - This should be a very rare edge case, however, it does happen when using - a .dev version of Bundler because in that case, that's the only version - that the resolver considers, and it should not be ignored. - - We could've special cased this specifically for Bundler, but I think it - does make sense for every gem. - -commit ddc4fd5644ae40e6b817fc534f0de0f9c867e7b7 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-01-18 04:53:52 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - Normalize git sources - - Just like gem sources, a "style-only" change, like adding a trailing - slash, should not expire them. - -commit 7800d4eeb5cfcd367a596044c183c547642066e2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:58:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - util/rubocop -A --only Style/MultipleComparison - -commit f8fe151ca99233e7d133e2952f9b989c5290c825 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:52:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - util/rubocop -A --only Style/TernaryParentheses - -commit 31c572f4fade8d061b151bd70dfca0b79da664e3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:32:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - util/rubocop -A --only Style/SymbolArray - -commit 1ca67f13cd2ebb643fc924246cc790f14b26480d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:12:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - util/rubocop -A --only Style/RedundantSelf - -commit 5211900d37573a82c1bdf7cb2354937cc4022ae1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 12:57:49 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - util/rubocop -A --only Style/SymbolProc - -commit b304cf324aed40977665ddcfcec7cc992feb949b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 12:21:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - util/rubocop -A --only Layout/ParameterAlignment - -commit 03736159484cb7f9eeaaed3737beec924a175679 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 11:57:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - util/rubocop -A --only Layout/SpaceInsideArrayLiteralBrackets - -commit 3e1f767cd599bbabb27043f98082996f81eb9929 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 11:24:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - util/rubocop -A --only Layout/DotPosition - -commit b6d3c06936e5aaf94d72f22f0ecca5468146f07f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 10:27:57 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - util/rubocop -A --only Performance/Casecmp - -commit 866831d8e9713cbf1b2bcc710a6da81f2b748855 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 14:16:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/Semicolon - - https://github.com/rubygems/rubygems/commit/97f062be05 - -commit ab644ae497a649a2f2c65d35757a19dc38518d3d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 14:11:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/CharacterLiteral - - https://github.com/rubygems/rubygems/commit/aa058ff6b8 - -commit 72d09a568f9f50ce7c41ef2999d272f77a207a8c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 14:10:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/RedundantBegin - - https://github.com/rubygems/rubygems/commit/b595d3cf0f - -commit a532e9dc37bb7ff2fb36966327f71a74163d9616 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 14:07:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/RedundantSortBy - - https://github.com/rubygems/rubygems/commit/3e4f5dc008 - -commit 2db767382527485339a36eea1f0e581c9dca2cfb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 14:06:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/DoubleNegation - - https://github.com/rubygems/rubygems/commit/01c2b5542f - -commit be4cc74e26d463358c121820fb6f918b9b8de92d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 14:05:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/IfUnlessModifierOfIfUnless - - https://github.com/rubygems/rubygems/commit/97e0af2518 - -commit ee7475734fa7717512f26c9c0bcf7500e7456539 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 14:01:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/BarePercentLiterals - - https://github.com/rubygems/rubygems/commit/02d8147243 - -commit bf69d1fc5d73aab8e0b69e0389ab5131f3d40223 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:55:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/OrAssignment - - https://github.com/rubygems/rubygems/commit/965fc82cfd - -commit f4b073ef7ad959c43b7d14acad2df49a5d056874 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:53:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/UnlessElse - - https://github.com/rubygems/rubygems/commit/184c03270c - -commit 4868cfcf1d8480ae13dc5e84c0e66dd44b950a89 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:50:31 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/IdenticalConditionalBranches - - https://github.com/rubygems/rubygems/commit/64f437a428 - -commit 6ad269dc39ab6bdf7ef195a048fa10b642374826 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:47:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/RescueStandardError - - https://github.com/rubygems/rubygems/commit/80b57da926 - -commit 70164eec0f48a691dd039f55ac897036aa32e5cf - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:48:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/RescueModifier - - https://github.com/rubygems/rubygems/commit/b490379eab - -commit fef0313ec79beab2383e30062803a0f21b198b21 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:45:57 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/PreferredHashMethods - - https://github.com/rubygems/rubygems/commit/ae3bdc0e85 - -commit 38664ede7ed6bf79c663706c8a02bb38b47d4eb2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:45:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/NonNilCheck - - https://github.com/rubygems/rubygems/commit/2b056b25c3 - -commit 4cd8a46f459c7813237501409b1a1c379128d1d3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:45:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/ParenthesesAroundCondition - - https://github.com/rubygems/rubygems/commit/c766a65885 - -commit 7b8a24ad08a0bafd0ef2f991080d72c6acf34a85 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:44:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/EmptyCaseCondition - - https://github.com/rubygems/rubygems/commit/dae8fc70a4 - -commit 3fe5909ef1c7a2da95fc3777773be831433017ea - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:43:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/SelfAssignment - - https://github.com/rubygems/rubygems/commit/7c1168c623 - -commit f86296fa0aae4eb94666828798f1cf6f8cfaebf7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:41:32 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/EmptyElse - - https://github.com/rubygems/rubygems/commit/04227104ac - -commit 4ab23df2c4540578e77c79a8aaf06178362edb76 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:40:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/RedundantParentheses - - https://github.com/rubygems/rubygems/commit/295691d4dc - -commit b8914a9d5de581c96abeac9290e5d505a570d00b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:39:24 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/StabbyLambdaParentheses - - https://github.com/rubygems/rubygems/commit/23ce9793e5 - -commit d8c5fa963fbf34d10599fff571f87c36410dab13 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:38:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/YodaCondition - - https://github.com/rubygems/rubygems/commit/3594945391 - -commit 66bd2c1a1cea53dec4cf2d9e625ac01d3418863e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:36:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/CommentAnnotation - - https://github.com/rubygems/rubygems/commit/4e77a1d1d5 - -commit 52ea7afa5f33d1a586866e0f12ede3b4a2a083e8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:35:34 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/NegatedIf - - https://github.com/rubygems/rubygems/commit/aa95ee27a2 - -commit 9ab860f9afd6033d5fbf1cadd90c6e3aea396ee4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:32:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/ColonMethodCall - - https://github.com/rubygems/rubygems/commit/823113f39e - -commit bd57322bfeddc73082f71d9cd21f2ba1bcd0d039 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:30:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/DefWithParentheses - - https://github.com/rubygems/rubygems/commit/91391ceedf - -commit 03b82d1865db32da8d69e91881675d9d6153872f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:28:31 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/SingleLineMethods - - https://github.com/rubygems/rubygems/commit/fa2e835ed2 - -commit d2cebb4e31b95b2bd02e5dec1c990c28f0f83bf4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:10:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/NumericLiterals - - https://github.com/rubygems/rubygems/commit/860669b08a - -commit 712d6e675b6abc97fa1f2adde49f2d6e48d4d93f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:09:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/RedundantInterpolation - - https://github.com/rubygems/rubygems/commit/add44e56eb - -commit 0b632b9cddef76514635ad460d40b3a8d346602f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:08:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/ClassCheck - - https://github.com/rubygems/rubygems/commit/1c3356a872 - -commit 567db6064baf572e3510c0322ec536ad84c81d57 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:08:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/NestedParenthesizedCalls - - https://github.com/rubygems/rubygems/commit/a875fdb535 - -commit 3d4c3f9e4ffc31e652b1bfab4d78f8b27d5b8126 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:07:05 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/ParallelAssignment - - https://github.com/rubygems/rubygems/commit/5c88c77873 - -commit 4bb5ce8188c7623106d124d3398c6b73bfa8ecd4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 13:00:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/StringLiteralsInInterpolation - - https://github.com/rubygems/rubygems/commit/cb554f6eb7 - -commit 83f9aa8f02c9fdcf8d22f0859c4f4fb3ad30bb42 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 12:55:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Style/Alias - - https://github.com/rubygems/rubygems/commit/fba6e94de9 - -commit f4d1f660d0c60072813fa46b0e704561ff8e20fe - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 12:23:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/SpaceInsideRangeLiteral - - https://github.com/rubygems/rubygems/commit/426dd97a31 - -commit ae81ff0c9b120d1d2ee4b0d1400cf1358c81f86f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 12:22:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/MultilineBlockLayout - - https://github.com/rubygems/rubygems/commit/9aa6101942 - -commit 9a1269eaaa4b50e0d9e95041a76090e7c6f09313 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 12:22:17 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/MultilineArrayBraceLayout - - https://github.com/rubygems/rubygems/commit/f4f45ab27e - -commit 26d660434325db8779b95edc6012866fe9f2403b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 12:17:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/MultilineMethodCallBraceLayout - - https://github.com/rubygems/rubygems/commit/acb0548bf6 - -commit 41f304d5bf84ba3e5d8c4a2e8da9a019bf8ca230 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 12:11:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/SpaceInsideStringInterpolation - - https://github.com/rubygems/rubygems/commit/a06f8ae3bb - -commit ce21ce6f235fd754937e72c7ac1885cf7284a1a5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 12:07:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/FirstArgumentIndentation - - https://github.com/rubygems/rubygems/commit/0542726fd3 - -commit 3233b1fe3f8f3ed47d24a934a8d7c4cf6e446cf5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 12:06:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/SpaceInLambdaLiteral - - https://github.com/rubygems/rubygems/commit/e76088b699 - -commit f8daae91c4dd1906a36df03a78d97caa11c8353d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 12:01:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/SpaceBeforeSemicolon - - https://github.com/rubygems/rubygems/commit/c92c6d8e85 - -commit 4b285e5c6fe690c89ce71e9d68d87976ef2d65e1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 12:00:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/AssignmentIndentation - - https://github.com/rubygems/rubygems/commit/8e64298989 - -commit 9ffd73523db3c80237bd26099c9e11f9f6e3a444 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 11:58:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/EmptyLinesAroundExceptionHandlingKeywords - - https://github.com/rubygems/rubygems/commit/ad1fe68d97 - -commit 583fbc627c2ad69457e37fc909f7aaf889d53483 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 11:49:24 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/EmptyLinesAroundModuleBody - - https://github.com/rubygems/rubygems/commit/48c88466b7 - -commit c480a0c46a5fc9479bf6e3aa5bd1d2177878fad1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 11:48:53 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/LeadingCommentSpace - - https://github.com/rubygems/rubygems/commit/4d680320e3 - -commit d9f92511adbad1d7841bac0999eec026d966e95e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 11:48:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/SpaceInsidePercentLiteralDelimiters - - https://github.com/rubygems/rubygems/commit/c6de27fc6d - -commit 85fd33c5264c149704419762855baaf3336c7a76 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 11:46:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/SpaceInsideArrayPercentLiteral - - https://github.com/rubygems/rubygems/commit/75abd2e504 - -commit dab1d0ed20c1c6cd0cd04d9bd5ea9902d2e9cade - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 11:43:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/EmptyLineBetweenDefs - - https://github.com/rubygems/rubygems/commit/00117e69cc - -commit 7c1d590a8a1ed2c805a760ace02bedd94f962994 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 11:26:53 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/SpaceBeforeComma - - https://github.com/rubygems/rubygems/commit/4a5b70b508 - -commit 23150e02742ac98a6b7c0b34a4342f614e60a378 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 11:34:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Layout/MultilineHashBraceLayout - - https://github.com/rubygems/rubygems/commit/bf33d106d0 - -commit ab2278eb348ee5f1f5a2434925737de62e1ff0fd - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 10:50:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/UselessAccessModifier - - https://github.com/rubygems/rubygems/commit/5070f90987 - -commit eb80f51c6d9bcb7b450a59beec5cc188d6cfab01 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 10:47:37 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/RedundantStringCoercion - - https://github.com/rubygems/rubygems/commit/58e4885493 - -commit 05208c3875a12a188e14328ffbd5b2eb21824f24 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 10:46:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Lint/UnusedBlockArgument - - https://github.com/rubygems/rubygems/commit/d8efd919db - -commit 7ab4ede4f5ec23d9eac6868176d99ad63df46978 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 10:35:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Performance/TimesMap - - https://github.com/rubygems/rubygems/commit/976a351f8b - -commit 139f0927f54d9d48bb1911717c3e5bf7bd268171 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 10:33:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Performance/DoubleStartEndWith - - https://github.com/rubygems/rubygems/commit/893da27e7c - -commit 65752b61e7ae84ecd4fdd0f5c5e065ab4a25c3e7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 10:32:05 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -A --only Performance/Count - - https://github.com/rubygems/rubygems/commit/46d5d6d1d3 - -commit 2eb99350f45d70b9f269457b41150b9a468ffc7e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 10:52:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Removed rubocop:disable detected by Lint/RedundantCopDisableDirective - - https://github.com/rubygems/rubygems/commit/07b0da6c24 - -commit 2dddac0475ee76e89e6999e0a563310e08325a2d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 08:59:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] util/rubocop -a test/rubygems/helper.rb and styling - - https://github.com/rubygems/rubygems/commit/fe331736d4 - -commit fe1b0661cb473da7a49d6180cf9b10f80df0fb78 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 08:57:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Removed RUBY_PATCHLEVEL and modify condition for ruby_version - - https://github.com/rubygems/rubygems/commit/b420e287a3 - -commit b09973a995620b17dfa98fbedc9d83da7f1dea78 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-16 08:53:26 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Also removed condition of RUBY_PATCHLEVEL - - https://github.com/rubygems/rubygems/commit/16f381be4b - -commit 8e40d1e153e8ee79da18b3691f5543e55c2f7dba - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-15 16:30:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] RUBY_PATCHLEVEL was provided after Ruby 1.8.5 - - https://github.com/rubygems/rubygems/commit/7750d5c460 - -commit a47c54131d25350341fb4ed52eab16ed478be1ba - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-15 00:10:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Remove ensure part in require - - I've seen this error sometimes but never found it helpful, since the - culprit has never been thread/monitor related, so it just adds noise. - - Right now I'm seeing an issue in CI where we seem to be crashing during - ensure and showing a weird backtrace: - - ``` - #<Thread:0x000055821d7a73b8 /home/runner/work/rubygems/rubygems/lib/rubygems/request_set.rb:167 run> terminated with exception (report_on_exception is true): - /home/runner/work/rubygems/rubygems/lib/rubygems/platform.rb:141:in `==': undefined local variable or method `to_a' for false:FalseClass (NameError) - Did you mean? to_s - from /home/runner/work/rubygems/rubygems/lib/rubygems/core_ext/kernel_require.rb:168:in `!=' - from /home/runner/work/rubygems/rubygems/lib/rubygems/core_ext/kernel_require.rb:168:in `require' - from /home/runner/work/rubygems/rubygems/lib/rubygems.rb:441:in `block in ensure_subdirectories' - from /home/runner/work/rubygems/rubygems/lib/rubygems.rb:437:in `each' - from /home/runner/work/rubygems/rubygems/lib/rubygems.rb:437:in `ensure_subdirectories' - from /home/runner/work/rubygems/rubygems/lib/rubygems.rb:413:in `ensure_gem_subdirectories' - from /home/runner/work/rubygems/rubygems/lib/rubygems/resolver/specification.rb:110:in `download' - from /home/runner/work/rubygems/rubygems/lib/rubygems/request_set.rb:173:in `block (2 levels) in install' - ``` - - Let's get this out of the picture in case that helps clarify the - culprit. - - https://github.com/rubygems/rubygems/commit/87ce40b70e - -commit dd0f0a5e6eb10bfa0641a3ce5d4e6374df493adb - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-14 23:27:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Fix `gem uninstall` with `--install-dir` - - https://github.com/rubygems/rubygems/commit/ac23687353 - -commit 123bedd295b584369955461ff452ca1ec005e7dd - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-14 23:13:12 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Extract some common logic to a test helper - - https://github.com/rubygems/rubygems/commit/ef4741b7cb - -commit 5733828734918536fb0cff8e75edb23e4fbae3f2 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-14 21:28:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Fix `rake check_manifest` when `rake` is `--user-installed`'d - - Otherwise we get - - ``` - ✗ rake TEST=test/rubygems/test_project_sanity.rb - Loaded suite /Users/deivid/.gem/ruby/3.2.0/gems/rake-13.0.6/lib/rake/rake_test_loader - Started - E - ============================================================================================================================================================================================================ - Error: test_manifest_is_up_to_date(TestProjectSanity): - RuntimeError: There was an error running `rake check_manifest`: /Users/deivid/.asdf/installs/ruby/3.2.1/lib/ruby/site_ruby/3.2.0/rubygems.rb:263:in `find_spec_for_exe': can't find gem rake (>= 0.a) with executable rake (Gem::GemNotFoundException) - from /Users/deivid/.asdf/installs/ruby/3.2.1/lib/ruby/site_ruby/3.2.0/rubygems.rb:282:in `activate_bin_path' - from /Users/deivid/.asdf/installs/ruby/3.2.1/bin/rake:25:in `<main>' - /Users/deivid/Code/rubygems/rubygems/test/rubygems/test_project_sanity.rb:27:in `test_manifest_is_up_to_date' - 24: - 25: raise "Expected Manifest.txt to be up to date, but it's not. Run `rake update_manifest` to sync it." - 26: else - => 27: raise "There was an error running `rake check_manifest`: #{out}" - 28: end - 29: end - 30: end - ============================================================================================================================================================================================================ - . - Finished in 0.188192 seconds. - ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ - 2 tests, 1 assertions, 0 failures, 1 errors, 0 pendings, 0 omissions, 0 notifications - 50% passed - ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ - 10.63 tests/s, 5.31 assertions/s - rake aborted! - ``` - - https://github.com/rubygems/rubygems/commit/29829933a6 - -commit 37c2e903e89b9e2d7f1dc771da4143d9f041ef8f - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-14 21:27:52 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Show error when `rake check_manifest` fails for unknown reason - - https://github.com/rubygems/rubygems/commit/98de85c11e - -commit 8371c0eac4432069ad16da081d36970b07ab7b09 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-14 02:56:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Fix incorrect error message when multiple platforms are locked - - https://github.com/rubygems/rubygems/commit/24d2bf9cb2 - -commit d5121992dc50112e0ebae84b993a957fdcdcff45 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-14 02:57:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Remove unnecessary `specific_local_platform` test helper - - https://github.com/rubygems/rubygems/commit/86b574824d - -commit 2d8b55fcd2cf816f4548ca7be48ba74b2cb0e05e - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2022-07-09 20:11:28 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Simplify `lockfile_platforms` helper - - To make it easier to change the default platforms that get locked later. - - https://github.com/rubygems/rubygems/commit/255c4012ec - -commit 9492efbe714e97abc5c656fca13a6602199a1ba8 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2022-07-09 01:59:22 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Remove unnecessary `local` helper - - https://github.com/rubygems/rubygems/commit/27ed6870ce - -commit 8a8ade7e5e46a74848c03a1481bc3c3d22b3e49e - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2022-04-28 04:05:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Use more common linux platform for specs - - https://github.com/rubygems/rubygems/commit/3841a58095 - -commit f22765f53535e03be3a00e1319d5591d8939a381 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2022-04-28 04:03:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 18:50:55 +0900 - - [rubygems/rubygems] Use splatted args to `lockfile_platforms_for` - - Nicer :) - - https://github.com/rubygems/rubygems/commit/c0ab2893c3 - -commit f29c9d6d36ebeb3e768a514cbfa00cd2ab35fcbc - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-16 19:45:37 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-17 09:50:41 +0900 - - compile branch body if needed - - ```ruby - if true - THEN - else - ELSE - end - ``` - - On this case, ELSE is not needed so that only compile THEN part. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7541 - -commit d2c6dca8f4a9fb3e6b9748758ee9eb75fa18622a - Author: lukeg <luke.gru@gmail.com> - AuthorDate: 2023-03-14 07:13:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-17 08:46:37 +0900 - - Fix small issues concerning namespacing in test-all suite - - * Fix temporary methods on Object leaking across test cases. - * Remove temporary classes/modules leaking across test cases. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7513 - -commit 5825d7d4a1a53ba84909a01679f4dfab63fa9739 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-03-17 06:40:36 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-17 06:40:36 +0900 - - YJIT: Remove exit for rest and send combo (#7546) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 473009d7cbafc4a94be53694b5934167072068e6 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-03-17 06:24:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-17 06:24:08 +0900 - - YJIT: add stats to keep track of when branch direction is known (#7544) - - This measures the impact of changes made by @jhawthorn last year. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 617c9b4656d4eda67b845c102fc13b02dc76a439 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-03-17 05:13:19 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-03-17 06:16:56 +0900 - - Rename opes to operands on RubyVM::BaseInstruction - - Notes: - Merged: https://github.com/ruby/ruby/pull/7523 - -commit 8dbddd5bf8a2f36b0cd32d97f7f7fa383bbc5b64 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-03-17 05:08:13 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-03-17 06:16:56 +0900 - - Rename opes to operands - - Co-authored-by: Aaron Patterson <aaron.patterson@gmail.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7523 - -commit d454a590ccdcf50d681aeb0aacfe2a0e424481b1 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-03-15 10:19:21 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-03-17 06:16:56 +0900 - - Re-add RJIT::Instruction#opes - - Notes: - Merged: https://github.com/ruby/ruby/pull/7523 - -commit 182f4f0d1c88771e688ad37e571282c67c1dbf19 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-17 03:05:54 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-17 03:05:54 +0900 - - Fix a bindgen CI failure - -commit ed18093200f94e964a0ad1c91272b3266364198b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-17 02:48:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-17 02:48:17 +0900 - - Fix the JIT-unsupported case - -commit 9947574b9cad74fbf04fa44d49647c591590c511 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-17 02:41:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-17 02:42:17 +0900 - - Refactor jit_func_t and jit_exec - - I closed https://github.com/ruby/ruby/pull/7543, but part of the diff - seems useful regardless, so I extracted it. - -commit a8e7fee80129b0ba360c2671582117c8e18a6464 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-17 01:22:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-17 01:22:42 +0900 - - Revert "core_assertions.rb: Refine `assert_linear_performance`" - - This reverts commit cae4342dd559e34c1ce6219593f77f0ad80286da. - - This is failing a lot of CIs and nobody is actively looking into fixing - it. Let me revert this until we have a solution to it. - -commit 2f81bb793fd217374054ee78cb5cd595cfacf9fe - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-16 03:19:22 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-03-16 23:46:30 +0900 - - Add thread and ractor counts to bug reports - - This is useful for crash triaging. It also helps to hint extension - developers about the misuse of `rb_thread_call_without_gvl()`. - - Example: - - $ ./miniruby -e 'Ractor.new{Ractor.receive}; - Thread.new{sleep}; Process.kill:SEGV,Process.pid' - <snip> - -- Threading information --------------------------------------------------- - Total ractor count: 2 - Ruby thread count for this ractor: 2 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7532 - -commit e0cf80d666d4b5df3229f030a16d10d21323508e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-16 06:40:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-16 23:00:02 +0900 - - Fix incorrect size of WeakMap buffer - - In wmap_final_func, j is the number of elements + 1 (since j also - includes the length at the 0th index), so we should resize the buffer - to size j and the new length is j - 1. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7536 - -commit 671ddb1eee1334e3b5cc209ec4c981ae2d0ba9dc - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-03-16 22:59:41 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-16 22:59:41 +0900 - - [DOC] Enhanced RDoc for TrueClass (#7521) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 89f7acba3c17e80aeaf71a618819e2b245a78d5c - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-03-16 03:37:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-16 21:55:01 +0900 - - [rubygems/rubygems] Improve TarTestCase#calc_checksum - - https://github.com/rubygems/rubygems/commit/97add0d1d7 - -commit 364364c3bd1067f37e4ce4e275b2c8c97984588f - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-03-14 11:04:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-16 21:55:01 +0900 - - [rubygems/rubygems] Improve TarHeader#calculate_checksum - - String#unpack("C*") is equivalent to String#bytes and Array#inject {|a,b| a + b } is equivalent to Array#sum. - This is a minor enhancement in terms of speed and readability. - -commit cae4342dd559e34c1ce6219593f77f0ad80286da - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-16 17:19:01 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-16 18:51:02 +0900 - - core_assertions.rb: Refine `assert_linear_performance` - - * Use an `Enumerable` as factors, instead of three arguments. - -commit 5cffa69c1babb80be17d2544a430dce0f2c22b4e - Author: Kazuhiro NISHIYAMA <zn@mbf.nifty.com> - AuthorDate: 2023-03-16 18:37:19 +0900 - Commit: Kazuhiro NISHIYAMA <zn@mbf.nifty.com> - CommitDate: 2023-03-16 18:37:19 +0900 - - [DOC] Add missing escape - - Before: - ``` - * + corresponds to $+, which contains last capture group. - ``` - - After: - ``` - * \+ corresponds to $+, which contains last capture group. - ``` - -commit 90d3bbb52bbc4159285cf4437290fc982259ebf0 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-16 01:33:50 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-03-16 18:32:08 +0900 - - [Feature #19442] Remove GC_ENABLE_INCREMENTAL_MARK - - Ruby doesn't compile when this is disabled, and it's not tested on CI. - We should remove it. - - Co-Authored-By: Peter Zhu <peter@peterzhu.ca> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7313 - -commit b3a271665b6d45fe21e775e1c523a040caa509a9 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-16 01:10:15 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-03-16 18:32:08 +0900 - - [Feature #19442] Remove USE_RINCGC flag - - Ruby doesn't compile when this is set to 0. Let's remove it. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7313 - -commit 0b303c683007598a31f2cda3d512d981b278f8bd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-15 20:34:21 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-16 17:17:46 +0900 - - [ruby/openssl] Relax error message check for OpenSSL 3.1 - - A tentative measures fo https://github.com/ruby/openssl/issues/606. - - With OpenSSL 3.1.0, the error message at connection using "self-signed - certificate" seems to return `SSL_R_TLSV1_ALERT_UNKNOWN_CA` instead of - `SSL_R_CERTIFICATE_VERIFY_FAILED`. - - https://github.com/ruby/openssl/commit/fc4629d246 - -commit f3b129241c2f12c2db8382be67fa304d4034c9ba - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-15 18:07:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-16 10:59:12 +0900 - - [rubygems/rubygems] Applied Layout/SpaceAroundOperators cop - - https://github.com/rubygems/rubygems/commit/3139587be9 - -commit 760b8b7d2413670808499eb972abe61400fe6b46 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-15 18:06:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-16 10:59:11 +0900 - - [rubygems/rubygems] Change enforce style with Layout/CaseIndentation on rubygems - - https://github.com/rubygems/rubygems/commit/d4938259c4 - -commit 61831806030612c3a8577d88945b478262ee88f7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-16 08:27:36 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-16 08:27:36 +0900 - - YJIT: Eliminate unnecessary mov for trampolines (#7537) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit ca10274fe34abad64dcbb20569aa5899bbf4c585 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-16 08:07:49 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-16 08:07:49 +0900 - - YJIT: Use assert_disasm! in an A64 test to avoid unused warning - - I kept getting unused warnings for this macro on A64 macOS. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7533 - - Merged-By: XrXr - -commit 9a735c776b5413377a921949494f42d1e15851ba - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-03-16 06:55:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-16 06:55:29 +0900 - - YJIT: use u16 for insn_idx instead of u32 (#7534) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 4ae9c34a4e00d148f206affb3a65926bf3fe230f - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-03-08 19:45:59 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-03-16 06:26:26 +0900 - - Move RB_VM_SAVE_MACHINE_CONTEXT to internal/thread.h - - Notes: - Merged: https://github.com/ruby/ruby/pull/7465 - -commit 60b8c7d9fd2e2cb82dae7189a66335b3bec9005f - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-03-08 03:41:04 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-03-16 06:26:26 +0900 - - Rename RB_GC_SAVE_MACHINE_CONTEXT -> RB_VM_SAVE_MACHINE_CONTEXT - - Notes: - Merged: https://github.com/ruby/ruby/pull/7465 - -commit 5791aa6263f730e3b2c8d4a4fb7a054539cf6135 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-03-08 03:13:46 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-03-16 06:26:26 +0900 - - Move RB_GC_SAVE_MACHINE_CONTEXT to vm_core.h - - Notes: - Merged: https://github.com/ruby/ruby/pull/7465 - -commit de174681f7db3cc84ee8c55cafe89bb85a77e945 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-16 02:43:49 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-03-16 04:45:20 +0900 - - YJIT: Assert that we have the VM lock while marking - - Somewhat important because having the lock is a key part of the - soundness reasoning for the `unsafe` usage here. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7530 - -commit f613c18912f4bf5492a8dc02ab5e3661f4ae907c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-16 01:53:46 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-16 01:53:49 +0900 - - Partially revert GH-7511 - - to see if it stabilizes Cirrus CI. - -commit 77c8daa2d40dd58eeb3785ce17dea2ee38f308d1 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-03-15 23:55:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-15 23:55:07 +0900 - - Make EC required on JIT state (#7520) - - * Make EC required on JIT state - - Lets make EC required on the JITState object so we don't need to - `unwrap` it. - - * Minor nitpicks - - --------- - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 56b38fdd69d56e8ff2ae9032fa55f2eda8bb5d63 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-15 15:38:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-15 20:21:22 +0900 - - [rubygems/rubygems] Use OpenSSL::Digest instead of digest stdlib - - https://github.com/rubygems/rubygems/commit/69aa007679 - -commit a90302adec7d56b56020273291c64a06e1c5174a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-15 15:27:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-15 20:21:21 +0900 - - [rubygems/rubygems] Added OpenSSL namespace explicitly - - https://github.com/rubygems/rubygems/commit/bf4382e7a7 - -commit b528ecc164b0b4975f61d626d3bc60d9555d3d18 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-15 15:10:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-15 20:21:21 +0900 - - [rubygems/rubygems] OpenSSL::Digest is always provided after Ruby 2.4 - - https://github.com/rubygems/rubygems/commit/4f2f2ad412 - -commit 09041a6ee8aadf8d87cc57d8546f134861bbcb8f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-15 18:19:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-15 18:19:31 +0900 - - core_assertions.rb: Refine `assert_linear_performance` - - * Add `rehearsal` keyword argument - * Stop repeating with the same factor - -commit ca437aeb395e77125fcd2ab9bc83bbcd3e357610 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-03-14 18:12:32 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-03-15 18:12:59 +0900 - - rb_ary_sum: don't enter fast path if initial isn't a native numeric type. - - [Bug #19530] - - If the initial value isn't one of the special cased types, we directly - jump to the slow path. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7519 - -commit 6462c1a042fec4017f7e3bf2c13ec6a29efd23d6 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-14 03:42:47 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-15 18:05:13 +0900 - - `Hash#dup` for kwsplat arguments - - On `f(*a, **kw)` method calls, a rest keyword parameter is identically - same Hash object is passed and it should make `#dup`ed Hahs. - - fix https://bugs.ruby-lang.org/issues/19526 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7507 - -commit 7fd53eeb46db261bbc20025cdab70096245a5cbe - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-03-15 15:48:27 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-15 15:48:27 +0900 - - Remove SIGCHLD `waidpid`. (#7527) - - * Remove `waitpid_lock` and related code. - - * Remove un-necessary test. - - * Remove `rb_thread_sleep_interruptible` dead code. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit ce47ee00ae295b31dc023afb935a60ecc39a1f4b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-27 11:21:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-15 13:59:11 +0900 - - Fix indirect counter increment - - `*pcnt++` just dereferences `pcnt` then increments the local variable, - but has no side effect. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7496 - -commit 04a2550928c3e0122e976fcf87c56f59b8a071ff - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-13 19:24:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-15 12:35:55 +0900 - - [rubygems/rubygems] Don't use full_required_path and extension_dir under the bundler - - https://github.com/rubygems/rubygems/commit/72169288ff - -commit 31137dc67fe60565a6023664a8e6e4ad35a362ad - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-13 19:09:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-15 12:35:54 +0900 - - [rubygems/rubygems] Removed test for - https://github.com/rubygems/rubygems/pull/6444, I have no idea to - migrate this test to bundler example - yet - - https://github.com/rubygems/rubygems/commit/0d869019bf - -commit 55a0fbfaf855da513e7c8e1234e9edfd51693efa - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-13 18:13:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-15 12:35:54 +0900 - - [rubygems/rubygems] Move build artifact detection logic for root gemspec to bundler from Gem::Specification. - - Gem::Specification#missing_extension? is heavily called from RubyGems. - We should reduce extra method call from this place. - - https://github.com/rubygems/rubygems/commit/e24e59d44d - -commit 3dc8cde70078ccb38f5f4b0818ad5eecded01bd5 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-15 12:18:11 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-15 12:18:11 +0900 - - Fix crash during compaction - - [Bug #19529] - - The fix for [Bug #19529] in commit 548086b contained a bug that crashes - on the following script: - - ``` - wm = ObjectSpace::WeakMap.new - obj = Object.new - 100.times do - wm[Object.new] = obj - GC.start - end - GC.compact - ``` - -commit 70ba3102129dbaf6c943d1ed042103e0238842f4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-15 07:38:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-15 07:38:58 +0900 - - YJIT: Introduce no_gc attribute (#7511) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 868f03cce1a2d7a4df9b03b8338e3af4c69041d0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-15 06:00:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-15 06:01:53 +0900 - - Remove unused jit_enable_p flag - - This was used only by MJIT. - -commit 76f2031884a7857649490f2ef8bcda534bd69c0c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-15 02:26:05 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-15 02:26:05 +0900 - - YJIT: Allow testing assembler with disasm (#7470) - - * YJIT: Allow testing assembler with disasm - - * YJIT: Drop new dependencies - - * YJIT: Avoid address manipulation - - * YJIT: Introduce assert_disasm! macro - - * YJIT: Update the comment about assert_disasm - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 548086b34e3dd125edabf5dc1e46b891fad3ea9c - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-03-14 17:12:55 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-03-15 00:49:23 +0900 - - ObjectSpace::WeakMap: fix compaction support - - [Bug #19529] - - `rb_gc_update_tbl_refs` can't be used on `w->obj2wmap` because it's - not a `VALUE -> VALUE` table, but a `VALUE -> VALUE *` table, so - we need some dedicated iterator. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7518 - -commit ac65ce16e904695ba45888d3fba641d12caf733a - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-03-14 16:07:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-14 16:07:59 +0900 - - Revert SIGCHLD changes to diagnose CI failures. (#7517) - - * Revert "Remove special handling of `SIGCHLD`. (#7482)" - - This reverts commit 44a0711eab7fbc71ac2c8ff489d8c53e97a8fe75. - - * Revert "Remove prototypes for functions that are no longer used. (#7497)" - - This reverts commit 4dce12bead3bfd91fd80b5e7195f7f540ffffacb. - - * Revert "Remove SIGCHLD `waidpid`. (#7476)" - - This reverts commit 1658e7d96696a656d9bd0a0c84c82cde86914ba2. - - * Fix change to rjit variable name. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit b27793835b858b442a7c2c39b442ab688504d3fc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-14 12:52:52 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-14 13:58:50 +0900 - - Try to use https://github.com/ruby/rbs/pull/1273 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7516 - -commit 278b639b7794f7c5a5287dded119d5bc02ec73d2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-14 13:41:28 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-14 13:49:38 +0900 - - Disable RJIT_FORCE_ENABLE CI for now - - Somehow btest-ruby is running miniruby. Not sure why. - https://github.com/ruby/ruby/actions/runs/4412043427/jobs/7731124729#step:16:402 - - For RJIT's experimental purposes, having just one CI is enough. I'd like - to focus on keeping .github/workflows/rjit.yml green. - -commit 4ad171bb255003be688bbe8c72183943a6c7c2ae - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-14 12:53:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-14 12:54:00 +0900 - - Remove an unused VM option - - This seems to be used nowhere today. - -commit c58759f4948747e90134ad314fbd94cdf1c2d93b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-14 12:29:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-14 12:51:58 +0900 - - Removed to load jit_support.rb - - It's removed at 4445b9e2a2dda207a2b3698c042342dd794b1b35 - -commit d8344559b224a701caa80a2f72e0798ded80bcd7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-14 12:40:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-14 12:42:19 +0900 - - RJIT: Simplify how Capstone is used in tests - -commit 4e6c9567411eba4095f293472365999fe8064e72 - Author: pkubaj <pkubaj@FreeBSD.org> - AuthorDate: 2022-04-28 23:33:19 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-03-14 10:42:42 +0900 - - Use __builtin_ppc_get_timebase on POWER with clang - - Notes: - Merged: https://github.com/ruby/ruby/pull/5856 - -commit 56dbf83a853507a954470d43024778fa63d3dd1d - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-03-13 22:07:25 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-03-13 22:07:25 +0900 - - Prevent a warning: assigned but unused variable - - ... which made a test fail - - http://rubyci.s3.amazonaws.com/debian10/ruby-master/log/20230313T213003Z.fail.html.gz - - ``` - 1) Failure: - TestRubyOptions#test_enable [/home/chkbuild/chkbuild/tmp/build/20230313T213003Z/ruby/test/ruby/test_rubyoptions.rb:176]: - pid 1208 exit 0 - | /home/chkbuild/chkbuild/tmp/build/20230313T213003Z/ruby/lib/ruby_vm/rjit/insn_compiler.rb:1257: warning: assigned but unused variable - argc - | /home/chkbuild/chkbuild/tmp/build/20230313T213003Z/ruby/lib/ruby_vm/rjit/insn_compiler.rb:1258: warning: assigned but unused variable - flags - . - - 1. [2/2] Assertion for "stderr" - | <[]> expected but was - | <["/home/chkbuild/chkbuild/tmp/build/20230313T213003Z/ruby/lib/ruby_vm/rjit/insn_compiler.rb:1257: warning: assigned but unused variable - argc", - | "/home/chkbuild/chkbuild/tmp/build/20230313T213003Z/ruby/lib/ruby_vm/rjit/insn_compiler.rb:1258: warning: assigned but unused variable - flags"]>. - ``` - -commit 4976b1a049b6e63987b2828121860d75f6136fb9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-14 07:32:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-14 07:33:01 +0900 - - Fork rbs to fix test failures - - https://github.com/ruby/rbs/pull/1274 - -commit c7822b8dbb79766c0cdaab1c355d97b0aa6bef71 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-14 05:32:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-14 05:32:45 +0900 - - YJIT: Merge add/sub/and/or/xor and mov on x86_64 (#7492) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 309ff928f5470697d6def63c5dd45255d2a09e1d - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-03-14 03:11:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-14 03:11:58 +0900 - - [ruby/irb] Replace METHOD_IS_A with === - (https://github.com/ruby/irb/pull/542) - - https://github.com/ruby/irb/commit/edd6c30e16 - -commit 1a8a24a6332afee5020f1a3d79e625b9f3a7e3c7 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-03-14 01:55:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-14 01:55:59 +0900 - - [DOC] Enhanced RDoc for NilClass (#7500) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 45127c84d992dc0224c59be341e6c652de7edd21 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-03-14 00:12:23 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-14 00:12:23 +0900 - - YJIT: Handle rest+splat where non-splat < required (#7499) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 1095baed34dca15b9d8c6c54ea2f89bbaf67fb52 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-03-13 23:31:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-13 23:31:37 +0900 - - [ruby/irb] Support inspecting BasicObject - (https://github.com/ruby/irb/pull/541) - - https://github.com/ruby/irb/commit/1dc2a406a3 - -commit 8c6b349805e2f17a57576b8dfad31e5681d6b0e9 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-13 11:40:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-13 18:54:04 +0900 - - [rubygems/rubygems] Removed `Gem.datadir`. - - https://github.com/rubygems/rubygems/pull/2216 is imcomplete to remove this method. - - https://github.com/rubygems/rubygems/commit/34ef915d12 - -commit dddc542e9b61b292d80a96d0d0efbbf58719e3be - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-03-13 18:31:13 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-13 18:31:13 +0900 - - [Bug #19476]: correct cache index computation for repetition (#7457) - - Notes: - Merged-By: makenowjust <make.just.on@gmail.com> - -commit 1e73bdbfc49b47ab5f45506f2a2a70660ee0e6e2 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-03-13 16:02:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-13 16:02:11 +0900 - - Update bundled gems list at 2023-03-13 - -commit e10218862a3eb96d39992d889b2cdd403ee7e6ed - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-13 15:50:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-13 15:56:21 +0900 - - Add btest-bruby target - - btest can't be used for testing RJIT because RJIT doesn't work on - miniruby. However, btest-ruby is not necessarily useful for testing RJIT - because both the runner could crash as well as the target. - - TBH I'm not sure why we want to use RUNRUBY instead of BOOTSTRAPRUBY on - btest-ruby. However, to achieve what I want to do while keeping the - current behavior, I'm just introducing a new target. - -commit e22c4e8877677ff90805e4a4dcbdef80f4220136 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2023-03-13 15:46:41 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-13 15:46:41 +0900 - - [Bug #19467] correct cache points and counting failure on `OP_ANYCHAR_STAR_PEEK_NEXT` (#7454) - - Notes: - Merged-By: makenowjust <make.just.on@gmail.com> - -commit ed269c81aa68ba87e9da2fe4c0c2227ea0689eca - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-13 14:27:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-13 15:38:11 +0900 - - RJIT: Count invokeblock exit types - -commit da9c84f859db292ab1127f7ca9b7741fff06557b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-13 14:15:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-13 14:15:58 +0900 - - RJIT: Rename a side exit counter - -commit d27b5948414efd9cd7a041b11744c9aab9222d05 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-13 14:09:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-13 14:09:05 +0900 - - RJIT: Fix a typo - - and import a missing function - -commit 330086d3f6d0f05ef6ccdf1e512c19e94e7104f3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-13 14:07:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-13 14:07:02 +0900 - - RJIT: Implement definedivar - -commit 3938efa70f5e1f69d588c2b7552335176180cbbb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-13 13:30:41 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-13 14:01:38 +0900 - - RJIT: Fix block param proxy on send - - peek_at_stack was doubly accounting for C::VM_CALL_ARGS_BLOCKARG, which - made that case always side-exit and hide this bug. - - When a block handler is block param proxy, you have to set LEP's specval - as next specval instead of block param proxy itself. - -commit a23f64221e9b006fef74544ffbbca5d09115f807 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-13 13:14:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-13 13:14:43 +0900 - - RJIT: Fix block finding logic - - like YJIT does - -commit e28f83703ac880f62e9be8a4e8481aae74096cf9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-13 12:49:44 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-13 12:49:44 +0900 - - RJIT: Update dependencies - -commit 07d3af22d034be006e144160d021352b1eaeb762 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-13 12:41:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-13 12:41:07 +0900 - - RJIT: Fix -Wshorten-64-to-32 - -commit 9cd5441d28002768d9f492140757652548b86727 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-13 05:55:39 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-13 07:15:08 +0900 - - RJIT: Implement --rjit-trace-exits - -commit bbd9221e46649cc0d620efe4542bb93ff89fcb47 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-13 05:31:00 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-13 05:31:15 +0900 - - RJIT: Give up freezing InsnCompiler - - for memoization - -commit 7ce4b716bdb5bcfc8b30ffcd034ce7aded1f72b9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-12 18:50:39 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-12 18:50:39 +0900 - - Add test for linear performance - - Notes: - Merged: https://github.com/ruby/ruby/pull/7506 - -commit 781222a8bc61597a72d6f64b15734a5fae38146a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-12 18:40:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-12 18:40:41 +0900 - - core_assertions.rb: Consider backward compatibilities - - This file is copied to default gems, which might support older - versions. - -commit c9db9c8abd1f1191efbfd2e332010f0ae2e53c9c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 16:52:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 16:52:49 +0900 - - Revert "Update ruby/action-slack v3.1.1 (#7505)" - - This reverts commit 2570374bc8779a923f3bc42fe1731eefbb743edf. - - Revert "Bump ruby/action-slack from 3.0.0 to 3.1.0" - - This reverts commit 39511b8b2304f41efe5b09ac87a0fb32931653f0. - - Neither v3.1.0 nor v3.1.1 seems working correctly. - -commit d50d13649943a0bec6a0a9eb0eb597eddb143a07 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 16:51:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 16:51:16 +0900 - - Investigate which test hangs on MinGW - - https://github.com/ruby/ruby/actions/runs/4396158119/jobs/7698424613 - -commit 3efe4639eca9b0bd5b3a2332c17595597bfd7f29 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 16:47:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 16:47:11 +0900 - - RJIT: Handle Mod 10 for CMP r/m64, r64 - -commit 9c220bf5e14821093b2f8dc8d7c7d5619b424f11 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 15:46:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 16:35:58 +0900 - - RJIT: Use lambda constants to match operands - -commit 8835f9d3bf1d6aba64c0f3ad504c4ea6d3b86e7d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 15:30:53 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 15:30:54 +0900 - - RJIT: Define QwordPtr for in-clause readability - -commit 9501283dea70c94a2df8fbb83c589a0dfcda273f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 15:24:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 15:25:00 +0900 - - RJIT: Leave it to NoMatchingPatternError - - instead of manually implementing NotImplementedError - -commit 846fc356cb91cbfbd9cf9699ed1174b21b072dd8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 15:13:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 15:17:06 +0900 - - RJIT: Use case-in for exhaustive matches - -commit fe34db5a1bc7053ec737ac5d197fa22d54f64b12 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 14:54:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 15:04:30 +0900 - - RJIT: Migrate SIZET values to RJIT::C constants - -commit 50c5f94ed71707030f03ef1ce699367f021e0aa3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 14:31:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 14:48:28 +0900 - - RJIT: Introduce constants under RubyVM::RJIT::C - -commit 58f7e8b7f83babeefb39d1a919d43de237c36c8a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 14:10:44 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 14:26:40 +0900 - - RJIT: Automate function pointer imports - -commit 47a6cfca720729d1ae3af534521cbe2a2f93cd50 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 14:02:06 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 14:26:40 +0900 - - RJIT: Use as the largest type as possible - - to just import stuff easily - -commit 2570374bc8779a923f3bc42fe1731eefbb743edf - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-12 14:00:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-12 14:00:00 +0900 - - Update ruby/action-slack v3.1.1 (#7505) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit e4caf59cc112d3fca6bc1f8e912135f856061218 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 13:59:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 13:59:03 +0900 - - Move yjit_force_enabled? to JITSupport - - for consistency - -commit 4445b9e2a2dda207a2b3698c042342dd794b1b35 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 13:53:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 13:56:29 +0900 - - Remove unused methods from JITSupport - -commit 195e32977f181c8af9233a12cfc2c98e0f7957f6 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 13:51:48 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 13:51:49 +0900 - - Skip test_udp_server on s390x RHEL 7.1 - - It seems like it never succeeds on this CI. - -commit 46a3634bcf1df7b39320cab6b6324f35cd5dd073 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 13:46:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 13:47:08 +0900 - - RJIT: Use SIZET macros instead of original PTR ones - -commit c6bea54c70ca4deabba1b028b1dd0dbdc7c0680c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 13:41:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 13:42:28 +0900 - - RJIT: Drop unused USE_* macros support - -commit 2d0dc376c426a8ea01d36ef2832355b6198e1465 - Author: S-H-GAMELINKS <gamelinks007@gmail.com> - AuthorDate: 2023-03-11 10:38:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-12 10:08:18 +0900 - - Reuse CVAR_LOOKUP macro - - Notes: - Merged: https://github.com/ruby/ruby/pull/7503 - -commit 94da5f7c360b64e12c55fa0be266d9f48e66e937 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 07:25:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 07:25:12 +0900 - - Rename builtin attr :inline to :leaf - -commit 0c0c88d383a09fef18d8cf8a1457d1649a2cbd46 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-12 06:32:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-12 07:19:46 +0900 - - Support multiple attributes with Primitive.attr! - -commit 3a02c7818cb6cbcc70957dfc449ebf32f9dd9e0b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-11 16:40:57 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-11 16:40:57 +0900 - - Change the syntax of Primitive.attr! to Symbol (#7501) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit ac47b8df8f0a58d70eb35e95656d83da0c155aa0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-11 16:40:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-11 16:40:22 +0900 - - Bump the required BASERUBY version to 2.5 (#7504) - - [Misc #16671] - - I'd like to bump it to 2.7 to use pattern matching in - tool/mk_builtin_loader.rb. - - However, I experienced a few blockers. 2.5 seems like the closest - version that is easy enough to use on CIs, so let me bump the version to - it as an intermediate step for it. I want to use &. and <<~ in 2.3 too. - - Known blockers: - * AppVeyor Visual Studio 2015 doesn't have Ruby 2.7. You'd need to bump - the version to Visual Studio 2019. - * GitHub Actions windows-2019 doesn't have Ruby 2.7 either. You - can use ruby/setup-ruby, but configure doesn't seem to work with it. - * For ruby/ruby-ci-imaage, bionic doesn't have Ruby 2.7. I tried using - ruby-build to build Ruby 2.7 from package, but the build on its CI - seems to somehow loop forever when I do that. So I gave it up for now. - We might want to wait until bionic becomes EOL. - - Note: - * AppVeyor Visual Studio 2015 has Ruby <= 2.6.3 - https://www.appveyor.com/docs/windows-images-software/#ruby - * GitHub Actions windows-2019 uses Ruby 2.5.9 - https://github.com/actions/runner-images/blob/main/images/win/Windows2019-Readme.md - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 973cb64b1c74981aeed028601020bb4425cc7db3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-11 16:23:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-11 16:24:18 +0900 - - RJIT: Skip a flaky test_thread test for now - - and unskip a ractor test that was actually running - -commit f7b215af0ed5148d1946f1e9d817a0875db02ec6 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-10 11:14:55 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-11 13:44:44 +0900 - - [rubygems/rubygems] Added another case of extconf.rb - - https://github.com/rubygems/rubygems/commit/3d0fa3dee8 - -commit 9801ad47bd8dc73370c4c668ac716a6e31802637 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-10 11:12:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-11 13:44:44 +0900 - - [rubygems/rubygems] Added test for - https://github.com/rubygems/rubygems/pull/6444 - - https://github.com/rubygems/rubygems/commit/7d6ece5c92 - -commit 93e34fe42e81d72a3e45501bf3f200ca5e78442f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-11 07:09:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-11 07:57:37 +0900 - - RJIT: Write initial tests for Assembler - -commit 83f6eee76cbffbfd363e0bd9d633914e257d68e8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-11 07:14:38 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-11 07:14:38 +0900 - - YJIT: Bump SEND_MAX_DEPTH to 20 (#7469) - - * YJIT: Bump SEND_MAX_DEPTH to 20 - - * Fix a test failure - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 76808b1ee45db247ad2aad9cc950a3a3a6e888eb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-11 06:19:05 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-11 06:57:52 +0900 - - RJIT: Start testing Assembler - -commit 6440d159b31feb495cacb279b204cdb6b54e721f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-11 06:15:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-11 06:15:48 +0900 - - RJIT: Simplify RubyVM::RJIT::Instruction - -commit cdece5cf36ec5414ed55fb8d759d2ba20ff209c1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-11 06:08:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-11 06:11:01 +0900 - - RJIT: Remove unused code from headers - -commit c364e0745dae0371c542bff770038b210832700e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-11 04:55:48 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-11 06:04:45 +0900 - - RJIT: Introduce --rjit-exec-mem-size - -commit 9bb43978759ca86ba09d9ca6cf24506621f5bcbe - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-03-11 00:40:54 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-03-11 05:15:20 +0900 - - Mark weak maps as write barrier protected - - For both we mark the lambda finalizer. - - ObjectSpace::WeakMap doesn't mark any other reference, so we can just add the flag. - - ObjectSpace::WeakKeyMap only ever add new refs in `wkmap_aset`, so we can just trigger the write barrier there. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7498 - -commit 93f7106b626fe6fbe3aab77f2349c94b259a8edb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-11 04:42:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-11 04:42:23 +0900 - - RJIT: Remove unused methods in rjit_c.rb - -commit d5b7c8a9727ebca2e7d29dd44c44f8724c2667cb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-11 04:27:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-11 04:29:25 +0900 - - RJIT: Always enable --rjit-dump-disasm - -commit d0b8bdb3927dd7bfa1ae9195fc254e48bc52fc9f - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-10 04:59:00 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-11 03:13:34 +0900 - - Remove duplicate code in gc_marks_finish - - There is an identical block a few lines down that does the exact same - thing. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7488 - -commit ac5f983f7d2695696693e88aa9c00b5cf2b46c37 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-11 03:07:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-11 03:07:52 +0900 - - RJIT: Break up and enable test_version (#7495) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 365fed6369cf490f44878322fcaeddf9dfcb02f5 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-03-11 01:50:43 +0900 - Commit: Aaron Patterson <tenderlove@ruby-lang.org> - CommitDate: 2023-03-11 01:50:43 +0900 - - Revert "Allow classes and modules to become too complex" - - This reverts commit 69465df4242f3b2d8e55fbe18d7c45b47b40a626. - -commit f98a7fd28d6eedfb80e5d7d1a92d67aa3dc4783f - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-07 04:45:02 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-10 23:32:10 +0900 - - Move WeakMap and WeakKeyMap code to weakmap.c - - These classes don't belong in gc.c as they're not actually part of the - GC. This commit refactors the code by moving all the code into a - weakmap.c file. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7451 - -commit dd47ce10dbfca9292e88bbbd3d7f37e3ea503034 - Author: Ian Ker-Seymer <hello@ianks.com> - AuthorDate: 2023-02-07 04:19:18 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-10 20:50:06 +0900 - - [rubygems/rubygems] Use `RbSys::ExtensionTask` when creating new rust gems - - https://github.com/rubygems/rubygems/commit/125f9fece9 - -commit 4dce12bead3bfd91fd80b5e7195f7f540ffffacb - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-03-10 19:38:09 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-10 19:38:09 +0900 - - Remove prototypes for functions that are no longer used. (#7497) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 3c35c13aaa137085e5c70d48598d0973d5a7649a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-10 15:43:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-10 15:43:53 +0900 - - RJIT: Resurrect --rjit-pause and RJIT.resume - -commit e07e9f8491d9ab8b22d2bdf6a8aeba834dac7eef - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-10 15:31:50 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-10 15:31:51 +0900 - - RJIT: Do nothing on jit_cont_free - - if cont is NULL. - -commit 4afe9c09a0cd4688198a5f6f147e5896913200df - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-10 15:14:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-10 15:15:16 +0900 - - RJIT: Use imemo_type_p instead - - which seems safer. It seems like imemo_type can cause SEGV. - -commit 35fd79ac3713478c8114a498d3536c05ad832063 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-10 14:55:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-10 14:55:14 +0900 - - RJIT: Lazily compile global ocb - -commit 5e27d82dd0d25b5df907203112955eeb0d764b02 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-10 10:26:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-10 14:16:52 +0900 - - [rubygems/rubygems] rubocop -a test/rubygems/test_gem.rb - - https://github.com/rubygems/rubygems/commit/4d20ed7e32 - -commit f1c9f89ff89ea044c2fda11b9684309c6c31f64c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-10 10:06:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-10 14:16:52 +0900 - - [rubygems/rubygems] Disable side-effect of GEM_HOME configuration - - https://github.com/rubygems/rubygems/commit/c43328ab03 - -commit fade612d187a41beb13d5213a9d41a6eda76bd8c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-10 07:59:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-10 12:51:17 +0900 - - [rubygems/rubygems] Removed needless option - - https://github.com/rubygems/rubygems/commit/4489361a21 - -commit 15739c66b713a695b0dfc1e4c1bf01b7d2a04426 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-08 18:23:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-10 12:51:16 +0900 - - [rubygems/rubygems] Added only missing extensions option into pristine command - - https://github.com/rubygems/rubygems/commit/cfd0e615d7 - -commit 86d38b452005a9168eb2b5eaffd5fb3465313436 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-03-10 12:40:05 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-10 12:40:05 +0900 - - Accept `sleep(nil)` as sleep forever. (#7484) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit a7bc000eaa65edd067cd1e4e2ef0041dfdc28b63 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-10 12:03:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-10 12:03:31 +0900 - - Revert and refine tests for uninitialized queue - - `Queue` and `SizedQueue` still check array members. Only the test of - `ConditionVariable` is useless. - -commit 0a466e30726a259907bb6f73557faa22d89545ee - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-10 11:54:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-10 11:54:59 +0900 - - Remove stale tests - - These tests were added at a198bb3929a4562a12b4aa245a297c7d3695149f, - when these classes were `Struct`s. Since these classes have been - rewritten, these tests no longer make sense. - -commit 69465df4242f3b2d8e55fbe18d7c45b47b40a626 - Author: HParker <HParker@github.com> - AuthorDate: 2023-02-18 01:15:03 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-03-10 08:34:49 +0900 - - Allow classes and modules to become too complex - - This makes the behavior of classes and modules when there are too many instance variables match the behavior of objects with too many instance variables. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7349 - -commit 65a95b82593683ba2e566fe1d14b086b80874c92 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-03-10 08:26:21 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-10 08:26:21 +0900 - - YJIT: upgrade type in `guard_object_is_string` (#7489) - - * YJIT: upgrade type in guard_object_is_string - - Also make logic more in line with other guard_xxx methods - - * Update yjit/src/core.rs - - * Revert changes to Type::upgrade() - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 9546c70e090106280046a81385fca083d5d449a1 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-03-08 04:59:48 +0900 - Commit: Matt Valentine-House <matt@eightbitraptor.com> - CommitDate: 2023-03-10 06:14:01 +0900 - - Remove unused forward decl of rb_thread_struct - - Notes: - Merged: https://github.com/ruby/ruby/pull/7467 - -commit 487142928aec557fce21bb191afa0169f4479fbd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-10 04:58:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-10 04:58:40 +0900 - - YJIT: Merge x86_merge into x86_split (#7487) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 1347d707cad8307b91df7e03e5347231ffafe40f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-10 02:34:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-10 02:34:04 +0900 - - Ignore parse.y expand tabs commit - - [Misc #19523] - -commit c5e9af9c9d890578182a21e7b71b50334cd5579e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-10 02:31:46 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-10 02:32:11 +0900 - - Expand tabs in parse.y - - I used the same script as https://github.com/ruby/ruby/pull/6094 but - for a .y file. - -commit 74f44dae9696dfc570abaefc106a2515e3770ef1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-10 02:29:06 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-10 02:29:08 +0900 - - Another fix for 262254dc7d - - Koichi might want to adjust his editor configuration. - -commit 3938b79ef9bbc6f77eb6f5f7af2ff67a30cd1f1e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-10 02:15:05 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-10 02:15:21 +0900 - - Revert an unneeded diff in 262254dc7d - -commit 262254dc7dd9b503ca01ab701eb5cdd96bce4c4d - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-10 00:34:38 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-10 00:37:11 +0900 - - rename `defined_ivar` to `definedivar` - - because non-opt instructions should contain `_` char. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7485 - -commit 22d8e95ffe60f9a1267f362bc919c99f03affcae - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-10 00:19:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-10 00:19:59 +0900 - - YJIT: Optimize `cmp REG, 0` into `test REG, REG` (#7471) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 3926ad578c312ddd2ff5221b96ef077b9e24e612 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-09 15:42:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-09 22:37:06 +0900 - - [rubygems/rubygems] Drop to support Psych 3.0 bundled at Ruby 2.5 - - https://github.com/rubygems/rubygems/commit/a6650c2c96 - -commit 44a0711eab7fbc71ac2c8ff489d8c53e97a8fe75 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-03-09 17:48:50 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-09 17:48:50 +0900 - - Remove special handling of `SIGCHLD`. (#7482) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 7bd7aee02e303de27d2cddfc5ef47e612d6782cb - Author: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com> - AuthorDate: 2022-01-08 13:21:46 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-03-09 17:46:14 +0900 - - Fix interpreter crash caused by RUBY_INTERNAL_EVENT_NEWOBJ + Ractors - - When a Ractor is created whilst a tracepoint for - RUBY_INTERNAL_EVENT_NEWOBJ is active, the interpreter crashes. This is - because during the early setup of the Ractor, the stdio objects are - created, which allocates Ruby objects, which fires the tracepoint. - However, the tracepoint machinery tries to dereference the control frame - (ec->cfp->pc), which isn't set up yet and so crashes with a null pointer - dereference. - - Fix this by not firing GC tracepoints if cfp isn't yet set up. - - Notes: - Merged: https://github.com/ruby/ruby/pull/5990 - -commit 1a0d3ec4b9bfca2c06abc2909dd1dd15308943fb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-09 16:37:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-09 16:38:02 +0900 - - RJIT: Make functions in rjit_c.c static - - They don't need to be global. - -commit 4be224eaf59a736a62064546f14d52e00300a46b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-09 16:25:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-09 16:31:06 +0900 - - RJIT: Reorganize rjit.c - - Reordering functions for readability, adding stats whenever possible. - -commit f5909ac6d962acf1eb2736a66316c74693e63a2f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-09 16:14:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-09 16:24:38 +0900 - - RJIT: Stop allowing leaked globals rjit_* - -commit a0918a4a80226700ee7c8ea27b30b87f86e5a25d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-09 16:12:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-09 16:12:51 +0900 - - RJIT: Get rid of verbose logging - -commit 7d7b67a4721c6b7abed5d1a186d0acf45e1934cc - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-09 16:07:30 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-09 16:07:30 +0900 - - RJIT: Clean up the declaration mess - -commit cf08a85b852870c7dac5936552ed3a217a758ae7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-09 00:58:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-09 15:19:56 +0900 - - [rubygems/rubygems] Ensure that `TempIO` is closed - - https://github.com/rubygems/rubygems/commit/dc7b9db514 - -commit 96d1acfdf6c6b42f2029f44d5b5920961d6efa92 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-11-30 14:01:54 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-09 13:54:50 +0900 - - [Bug #19161] Check for TLS usability - - On all platforms using GCC, even other than darwin. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7481 - -commit 2ecdefab7d0f9293f2aaf047bb9c02a612d19a5a - Author: lukeg <luke.gru@gmail.com> - AuthorDate: 2023-03-09 02:29:39 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-09 13:18:07 +0900 - - Make sure TestDefaultGems#test_validate_gemspec runs even when Dir.pwd != srcdir - - For instance, when running tests in build directory like: - - $ make test-all TESTOPTS="../ruby/test" - - Notes: - Merged: https://github.com/ruby/ruby/pull/7478 - -commit 1658e7d96696a656d9bd0a0c84c82cde86914ba2 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-03-09 12:05:47 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-09 12:05:47 +0900 - - Remove SIGCHLD `waidpid`. (#7476) - - * Remove `waitpid_lock` and related code. - - * Remove un-necessary test. - - * Remove `rb_thread_sleep_interruptible` dead code. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit ea8b5e7359cf88ce02f30d6ac4beb6e4cb6dcb78 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-08 13:20:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-09 08:23:45 +0900 - - [rubygems/rubygems] rubocop -a lib/rubygems/specification.rb - - https://github.com/rubygems/rubygems/commit/85d60e9886 - -commit cb3f1f6de8bd2e128168fde43aa28c2441818469 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-08 13:11:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-09 08:23:45 +0900 - - [rubygems/rubygems] Detect extension files under full_required_paths - - When we use this methods with local gemspec, we don't handle - build status of extension correctly. So We need to find extension - files in require_paths. - - Example with ruby/erb repository: - - ``` - $ bundle exec irb - Ignoring erb-4.0.2 because its extensions are not built. Try: gem pristine erb --version 4.0.2 - >> - ``` - - https://github.com/rubygems/rubygems/commit/f90e43cf3f - -commit 309dd50a01203ac107c12e5a962e6aa6add75529 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-09 06:13:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-09 06:13:23 +0900 - - Fix node search in bindgen - - This is to fix a weird bindgen behavior on Matt's branch: - https://github.com/ruby/ruby/pull/7393 - -commit cc54e1cf48a232b19e2a69302403bdaa4433cb7a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-09 05:00:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-09 05:00:14 +0900 - - Fix ruby_testoptions on RubyCI - - http://rubyci.s3.amazonaws.com/osx1200arm-no-yjit/ruby-master/log/20230308T185004Z.fail.html.gz - -commit 2f19c5b7e080f75c3373c5b1671b4d4cfab6d334 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-03-09 04:47:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-09 04:47:49 +0900 - - [ruby/net-http] Enhanced RDoc for Net::HTTP - (https://github.com/ruby/net-http/pull/130) - - https://github.com/ruby/net-http/commit/698e18cfc1 - -commit 4667a3a665c40d9ea7f2be6417d1537deb208c52 - Author: Ole Friis Østergaard <olefriis@gmail.com> - AuthorDate: 2023-03-01 22:49:39 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-03-09 02:34:31 +0900 - - Add defined_ivar as YJIT instruction as well - - This works much like the existing `defined` implementation, - but calls out to rb_ivar_defined instead of the more general - rb_vm_defined. - - Other difference to the existing `defined` implementation is - that this new instruction has to take the same operands as - the CRuby `defined_ivar` instruction. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7433 - -commit 1a3f8e1c9f6ce4b1cd7236fdcdd17a8719654320 - Author: Ole Friis Østergaard <olefriis@gmail.com> - AuthorDate: 2023-02-28 21:44:57 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-03-09 02:34:31 +0900 - - Add defined_ivar instruction - - This is a variation of the `defined` instruction, for use when we - are checking for an instance variable. Splitting this out as a - separate instruction lets us skip some checks, and it also allows - us to use an instance variable cache, letting shape analysis - speed up the operation further. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7433 - -commit dc1e6573f2a1e3f85dd35c2acc26b647bd44e3b7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-09 00:49:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-09 00:49:11 +0900 - - Fix commit miss - -commit 611a64250a2406ee0bc864ef3d4b565036865911 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-08 20:40:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-08 22:57:06 +0900 - - Disable color mode of test-syntax-suggest when on dumb terminal - - The compliation-mode of Emacs sets TERM to "dumb" and does not support - coloring. - -commit e1bd45624c85e8a80991bda20801f50967ac77a1 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-07 23:50:30 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-08 22:47:18 +0900 - - Fix crash when allocating classes with newobj hook - - We need to zero out the whole slot when running the newobj hook for a - newly allocated class because the slot could be filled with garbage, - which would cause a crash if a GC runs inside of the newobj hook. - - For example, the following script crashes: - - ``` - require "objspace" - - GC.stress = true - - ObjectSpace.trace_object_allocations { - 100.times do - Class.new - end - } - ``` - - [Bug #19482] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7464 - -commit bead4bce3b4544cb61b3c05c11204a377e20cdfa - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-08 17:39:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-08 20:07:46 +0900 - - Constify local static variables in yyparse - - Notes: - Merged: https://github.com/ruby/ruby/pull/7477 - -commit 116320402109c9b6de66bc71ed02ef4d12c38dc0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-08 16:51:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-08 17:48:43 +0900 - - code style - - Notes: - Merged: https://github.com/ruby/ruby/pull/7475 - -commit 59905883c42625d039f40306598646853f2cc794 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-08 16:46:57 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-08 17:48:43 +0900 - - BundledGem.dummy_spec needs to checkout revision after cloning repository. - - The current BundledGem.dummy_spec always called from master branch. - It caused to CI faiulres like - http://rubyci.s3.amazonaws.com/ubuntu/ruby-master/log/20230305T001003Z.fail.html.gz - - Notes: - Merged: https://github.com/ruby/ruby/pull/7475 - -commit 0c9733ea86de7860e598db74d61cf42d9eeb4daf - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-08 15:51:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-08 17:48:43 +0900 - - Added missing dependency for rubygems - - Notes: - Merged: https://github.com/ruby/ruby/pull/7475 - -commit a7cee4da9729f82058fd6b369ce5b396223d4aa7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-08 15:50:22 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-08 17:48:43 +0900 - - Added debug info to gemspec version check - - Notes: - Merged: https://github.com/ruby/ruby/pull/7475 - -commit c25738762ab56bfd2edb4fedb5fc6bed88c03d61 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-08 15:45:58 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-08 17:48:43 +0900 - - Check bundled_gems version and gemspec version strictly - - Notes: - Merged: https://github.com/ruby/ruby/pull/7475 - -commit 9ad19069f9d10dcab33bcee8502d587020bad2a4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 16:44:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-08 16:59:50 +0900 - - Remove obsoleted functions in rjit.c - -commit 4bf037bebdc37671ca292dc8f500e1bede077163 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 16:30:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-08 16:31:39 +0900 - - Update documentation about RJIT - -commit e93e780f3d37705a26a9160c60cc92255c1ff60a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 16:14:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-08 16:16:24 +0900 - - Remove MJIT's builtin function compiler - -commit b67f07fa2c5b7fe9a08563bbc8084401b2ec68c4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 16:08:48 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-08 16:08:57 +0900 - - Get rid of MJIT's special fork - -commit 43de2365a5f024118ac5213ef101a23cc8a764e6 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 16:06:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-08 16:06:01 +0900 - - Fix a typo - -commit 9df1f58e018a0c7fd4d9268d9aeb71b277c653db - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 15:55:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-08 15:58:11 +0900 - - Link libcapstone no matter what cargo does - - libcapstone used to break when it's linked from C and Rust at the same - time, but it doesn't seem to happen anymore. Maybe it's related to - recent symbol hygiene changes. Thank you if that's the case. - - This commit allows you to make both --enable-rjit=dev and - --enable-yjit=dev work in the same binary. - -commit 6d91df08b53d0b17fa8cd949a3c6b42164c46c8d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 15:43:37 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-08 15:43:37 +0900 - - Allow enabling YJIT and RJIT independently (#7474) - - We used to require MJIT is supported when YJIT is supported. However, - now that RJIT dropped some platforms that YJIT supports, it no longer - makes sense. We should be able to enable only YJIT, and vice versa. - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 0bf4cd8e1c3178345a63ce5b9d80d02781d93497 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 14:21:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-08 14:21:19 +0900 - - Actually stop supporting those options - -commit 1d39d2d334f2472a1694ff861ad8c27cefea819b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 14:16:05 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-08 14:19:04 +0900 - - Update options available in RJIT - -commit 677c3228d09eaeaa57ad18396f52841f31411b6a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-08 12:16:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-08 13:59:21 +0900 - - Check loading built-in binaries - - Notes: - Merged: https://github.com/ruby/ruby/pull/7473 - -commit 5889cbd7de4d7e9d8d340ae553f994e231ecc8ef - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-08 12:14:34 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-08 13:59:21 +0900 - - Constify function tables - - Notes: - Merged: https://github.com/ruby/ruby/pull/7473 - -commit ae2dbdf11e48f01f1c9d29903fae536af6add2a5 - Author: Sampat Badhe <sampatbadhe@gmail.com> - AuthorDate: 2023-03-08 12:26:26 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-08 12:26:26 +0900 - - [DOC] Fix broken link Data#deconstruct_keys - - Notes: - Merged: https://github.com/ruby/ruby/pull/7463 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit ec05ba7ca30436768f50afabddb4642e8060dace - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 10:51:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-08 10:51:38 +0900 - - Give more time to MinGW to run make test - - 10 minutes were not enough. - https://github.com/ruby/ruby/actions/runs/4360048989/jobs/7622532445 - -commit 3e731cd945134da5f55cbd34f5cd8c9086a8c27a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 07:08:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-08 07:59:37 +0900 - - YJIT: Add comments to peek and x86_merge - - Notes: - Merged: https://github.com/ruby/ruby/pull/7453 - -commit 7f557d02c343d25a07036e4170367897ed14c3b9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 10:33:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-08 07:59:37 +0900 - - YJIT: Merge lea and mov on x86_64 when possible - - Notes: - Merged: https://github.com/ruby/ruby/pull/7453 - -commit c5296d9396bee7fd18468b6af727996f6c9f614f - Author: Julie Haehn <jhaehn@gmail.com> - AuthorDate: 2022-11-30 13:49:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-08 07:36:36 +0900 - - [rubygems/rubygems] Respect --no-install option for git: sources - - Currently, the --no-install option to `bundle package` is totally - ignored for git sources. This can have very strange effects if you have: - - - a git-sourced gem, - - with native extensions, - - whose extconf.rb script depends on another gem, - - which is installed from Rubygems in the gemfile. - - In that circumstance, `bundle package --no-install --all` will download - the Rubygems dependencies to `vendor/cache` but NOT install them. It - will also check out the git gems to `vendor/cache` (good), and attempt - to build their native extensions (bad!). - - The native extension build will fail because the extconf.rb script crashes, - since the dependency it needs is missing. - - I implemented a fix for this in `source/git.rb`, since this is analogous - to what's happening in `source/rubygems.rb`. I do admit though the whole - thing is a little strange though - an "install" method that.... proceeds - to look at a global flag to not install anything. - - Add test to confirm cache respects the --no-install flag - - https://github.com/rubygems/rubygems/commit/5a77d1c397 - - Co-authored-by: KJ Tsanaktsidis <kj@kjtsanaktsidis.id.au> - -commit 56df6d5f9d986a7959eb9cac27e21bc2ed505319 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-03-08 07:03:43 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-08 07:03:43 +0900 - - YJIT: Handle splat+rest for args pass greater than required (#7468) - - For example: - - ```ruby - def my_func(x, y, *rest) - p [x, y, rest] - end - - my_func(1, 2, 3, *[4, 5]) - ``` - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 33edcc112081f96856d52e73253d73c97a5c4a3c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 06:10:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-08 06:10:07 +0900 - - YJIT: Protect strings from GC on String#<< (#7466) - - Fix https://github.com/Shopify/yjit/issues/310 - - [Bug #19483] - - Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - Co-authored-by: Jimmy Miller <jimmy.miller@shopify.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 85a1738ab37b3348fc0b924804ca4b209f34fbf7 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-02-17 11:03:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-08 05:21:43 +0900 - - [rubygems/rubygems] Add TarReader::Entry#seek to seek within the tar file entry - - TarReader#each previously implemented a partial version of seek. - This code moved to Entry#seek for use from TarReader#each. - - Entry#close now returns nil instead of true, like IO#close. - - Closing an Entry now seeks to the end of the Entry, seeking past - any remaining zero byte tar file padding and moving the io to the - correcty position to read the next file in the archive. - - Uses seek for Entry#rewind and #pos=, fixing the tar->gzip->tar nested - rewind that would break previous to this change. - - Add Entry.open that behaves more like File.open. - - https://github.com/rubygems/rubygems/commit/f5149565d5 - -commit 719a7726d17f0800b8f8ef42f3f48e7558d5a444 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-03-08 02:29:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-08 02:29:59 +0900 - - YJIT: Handle special case of splat and rest lining up (#7422) - - If you have a method that takes rest arguments and a splat call that - happens to line up perfectly with that rest, you can just dupe the - array rather than move anything around. We still have to dupe, because - people could have a custom to_a method or something like that which - means it is hard to guarantee we have exclusive access to that array. - - Example: - - ```ruby - def foo(a, b, *rest) - end - - foo(1, 2, *[3, 4]) - ``` - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit a6de8b0d2dea18b03374d27901f31be407523baa - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-08 00:21:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-08 00:21:22 +0900 - - YJIT: Bump SEND_MAX_DEPTH to 10 (#7452) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit c78138abd3ccbc80b259430a78dfb6c0f65c6f5c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-04 04:19:55 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-07 22:28:03 +0900 - - Add function rb_data_free - - This commit adds a function rb_data_free used by obj_free and - rb_objspace_call_finalizer to free T_DATA objects. This change also - means that RUBY_TYPED_FREE_IMMEDIATELY objects can be freed immediately - in rb_objspace_call_finalizer rather than being created into a zombie. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7438 - -commit 638f68b2fe16e7c765ab9bf7a927b95ff187b3d3 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-03-07 10:13:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-07 20:48:41 +0900 - - [rubygems/rubygems] Avoid calling String#dup in Gem::Version#marshal_dump - - Might potentially save a second every time RubyGems.org creates a specs index - - https://github.com/rubygems/rubygems/commit/d6e4d50f8d - -commit dc33d32f12689dc5f29ba7bf7bb0c870647ca776 - Author: Josef Šimánek <josef.simanek@gmail.com> - AuthorDate: 2023-02-28 13:38:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-07 16:52:28 +0900 - - Use proper memoized var name for Gem.state_home. - -commit 93f0749a64ae4511bd38358dee238140489526b5 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-03 20:15:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-07 16:51:36 +0900 - - [rubygems/rubygems] Fix gemspec file filter - - Explicitly match directory separator to not match files in repo root - accidentally. - - https://github.com/rubygems/rubygems/commit/b936805ea9 - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -commit 72591eb73f589f135d7c1c1e07a98d3820001213 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-03 03:11:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-07 16:51:36 +0900 - - [rubygems/rubygems] Better suggestion when `bundler/setup` fails due to missing gems - - If the original `BUNDLE_GEMFILE` is different from the default, then the - suggestion wouldn't work as is. - - Before: - - ``` - $ util/rubocop - Could not find rubocop-1.30.1 in locally installed gems - Run `bundle install` to install missing gems. - - $ rubygems git:(better-cmd-suggestion) ✗ bundle install - Could not locate Gemfile - ``` - - After: - - ``` - $ util/rubocop - Could not find rubocop-1.30.1 in locally installed gems - Run `bundle install --gemfile /path/to/rubygems/bundler/tool/bundler/lint_gems.rb` to install missing gems. - - $ bundle install --gemfile /path/to/rubygems/bundler/tool/bundler/lint_gems.rb - Fetching gem metadata from https://rubygems.org/......... - Using ast 2.4.2 - Using bundler 2.4.7 - Using parser 3.1.2.0 - Using rainbow 3.1.1 - Using parallel 1.22.1 - Using regexp_parser 2.5.0 - Using rubocop-ast 1.18.0 - Using rexml 3.2.5 - Using ruby-progressbar 1.11.0 - Using unicode-display_width 2.1.0 - Fetching rubocop 1.30.1 - Installing rubocop 1.30.1 - Using rubocop-performance 1.14.2 - Bundle complete! 2 Gemfile dependencies, 12 gems now installed. - Use `bundle info [gemname]` to see where a bundled gem is installed. - - $ util/rubocop - Inspecting 345 files - ......................................................................................................................................................................................................................................................................................................................................................... - - 345 files inspected, no offenses detected - ``` - - https://github.com/rubygems/rubygems/commit/bf1320d805 - -commit 5d790264ea753d06de7a131387863d24199790fb - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-02 22:30:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-07 16:51:35 +0900 - - [rubygems/rubygems] Remove hardcoded master branch references - - Let RubyGems use the default branch defined by each repo. - - https://github.com/rubygems/rubygems/commit/54bd3e9ebd - -commit bd0f2c79586fc8d59ab8d8368ee8c7fd80749b75 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-02 22:07:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-07 16:51:34 +0900 - - [rubygems/rubygems] Let git source use default cloned repo branch - - https://github.com/rubygems/rubygems/commit/d8af770379 - -commit 589c2b1fb217f9ec2598f2305cb31c882b446a68 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 16:43:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 16:44:01 +0900 - - Regenerate RJIT bindgen - - Notes: - Merged: https://github.com/ruby/ruby/pull/7462 - -commit 23ec248e48f696ae986e2b19cd572ece02a5ba55 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 16:17:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 16:44:01 +0900 - - s/mjit/rjit/ - - Notes: - Merged: https://github.com/ruby/ruby/pull/7462 - -commit 2e875549a934fa04b7939810fa0d8a2762702aaa - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 16:15:30 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 16:44:01 +0900 - - s/MJIT/RJIT/ - - Notes: - Merged: https://github.com/ruby/ruby/pull/7462 - -commit eaccdc1941304d6273397b21c25213174d892185 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 15:35:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 16:44:01 +0900 - - Rename MJIT filenames to RJIT - - Notes: - Merged: https://github.com/ruby/ruby/pull/7462 - -commit 854546fcc468fc6a49588bdbf6df77aa185493a1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 16:24:05 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 16:24:05 +0900 - - MJIT is no longer slower on Rails - -commit 2c4b2053ca1884f058982fd46f2576bd887920b6 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-03-07 16:23:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-07 16:23:00 +0900 - - Correctly clean up `keeping_mutexes` before resuming any other threads. (#7460) - - It's possible (but very rare) to have a race condition between setting - `mutex->fiber = NULL` and `thread_mutex_remove(th, mutex)` which results - in the following bug: - - ``` - [BUG] invalid keeping_mutexes: Attempt to unlock a mutex which is not locked - ``` - - Fixes <https://bugs.ruby-lang.org/issues/19480>. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 011c08b643757b2369f28fcae190ad1e98623789 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 16:04:27 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 16:05:50 +0900 - - Remove obsoleted mjit_sp_inc.inc.erb - -commit fd4a397e88f61b4261dd54dae77571ec5951ec94 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-03-07 16:01:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-07 16:01:48 +0900 - - Update bundled gems list at 2023-03-07 - -commit b2130d5f5d5cf01f371275ec92bbed56f93a7770 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 15:53:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 15:53:38 +0900 - - Remove obsoleted tool/mjit_tabs.rb - -commit 072fc7671a2e1d203b8e006c5cd9d629b0315fa8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 15:43:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 15:43:32 +0900 - - Remove obsoleted tool/mjit_archflag.sh - -commit 7abe47b85a9db7393e8176ee5f0507c549da59bf - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-03-07 15:38:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-07 15:38:58 +0900 - - Improve robustness of `io_wait` implementation. (#7456) - - - Restore correct handling of `duration`. - - Don't delete from `@readable` or `@writable` unless it was added. - - A little more documentation. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 66c4dc15925bbcb1c31214a17a43d24d19890087 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 15:36:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 15:36:57 +0900 - - Remove MJIT-specific benchmarks - -commit 2702d615f55f676aa8ddc8051907e2c201654e03 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 15:31:29 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 15:31:43 +0900 - - Remove obsoleted mjit_config.h - -commit 290e26c729a083f4461d2497099d9e7eee814228 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 15:03:39 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 15:29:35 +0900 - - Remove obsoleted MJIT_HEADER macro - - Notes: - Merged: https://github.com/ruby/ruby/pull/7461 - -commit 7fb36a0054436369aa2868490e2d102d8e75929c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 15:02:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 15:29:35 +0900 - - Remove obsoleted MJIT_STATIC macro - - Notes: - Merged: https://github.com/ruby/ruby/pull/7461 - -commit f68580890faef54a8000e3d9b79341dbd17c115e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 15:14:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 15:14:44 +0900 - - Stop building mjit_build_dir.so - -commit 50a709fb9e07f523c8a0649d3039161b77f300ad - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 14:56:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 14:59:23 +0900 - - Resurrect symbols used by ObjectSpace - - Notes: - Merged: https://github.com/ruby/ruby/pull/7459 - -commit 233ddfac541749a0da80ea27913dc1ef4ea700bb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 14:34:31 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 14:59:23 +0900 - - Stop exporting symbols for MJIT - - Notes: - Merged: https://github.com/ruby/ruby/pull/7459 - -commit 31f4b2d86bfbc753cec9be376719acc4b120e944 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 14:41:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-07 14:41:48 +0900 - - Drop obsoleted MJIT header (#7458) - - RJIT doesn't need this. - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 09b4236f17dfad945e85edb5c57ab4cd81065915 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 14:19:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 14:19:19 +0900 - - Add a Slack notification for MJIT CI - -commit 56ebeba436f7030694eea336fabad2d0d2a73871 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-03-07 11:47:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-07 11:47:15 +0900 - - [ruby/irb] Bump version to 1.6.3 - (https://github.com/ruby/irb/pull/537) - - https://github.com/ruby/irb/commit/110e4a3219 - -commit 030f39822ac9d6d7dcdb639e099b320d3517c19c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-07 10:34:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-07 10:35:20 +0900 - - [ruby/net-http] Re-apply - https://github.com/ruby/net-http/commit/d22ca54904de after - testing - - https://github.com/ruby/net-http/commit/7ac7401a9c - -commit 6df8a53055cfa5af02cb5572b3655806e6ed3d5f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 06:36:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 06:37:01 +0900 - - Fix YJIT stats for RUBY_DEBUG builds - -commit b116b2bcf68d68f51743acd16592d430289aa431 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-07 06:20:53 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-07 06:20:54 +0900 - - Fix a compilation warning on Mac - - ../mjit_c.rb:493:17: warning: implicit conversion loses integer precision: 'ID' (aka 'unsigned long') to 'unsigned int' [-Wshorten-64-to-32] - return UINT2NUM(vm_ci_mid((CALL_INFO)NUM2PTR(_ci_addr))); - ~~~~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -commit a1758fbd7fe7406601b0eb1617752db59b83586a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-04 06:23:43 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-06 23:09:03 +0900 - - Crash when malloc during GC - - This feature was introduced in commit 2ccf6e5, but I realized that - using rb_warn is a bad idea because it allocates objects, which causes - a different crash ("object allocation during garbage collection phase"). - We should just hard crash here instead. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7441 - -commit 755c379d877c66916d20840f07738d6050da3ca2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-06 22:22:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-06 22:26:36 +0900 - - [ruby/net-http] Exclude git related files - - https://github.com/ruby/net-http/commit/2767df580d - -commit c8c3431b0a5995d58f97c511ffa0a39e0f19c75e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-06 16:03:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-06 22:26:34 +0900 - - [ruby/net-http] Read in binary mode to get rid of invalid byte sequence - - https://github.com/ruby/net-http/commit/38de3d17a7 - -commit fd0a5659cadb49f1640b20896cd750decdbbd701 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-06 15:46:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-06 22:26:34 +0900 - - [ruby/net-http] Test building packages - - Also revert commit https://github.com/ruby/net-http/commit/d22ca54904de "Replaced - non-ascii charactor. It fails version detection at `net-http.gemspec`." - - https://github.com/ruby/net-http/commit/fbeb247d93 - -commit 704dd25812f34228a28f37c37757a675ad078a2b - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-06 17:29:39 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-03-06 21:10:42 +0900 - - TestThreadInstrumentation: emit the EXIT event sooner - - ``` - 1) Failure: - TestThreadInstrumentation#test_thread_instrumentation [/tmp/ruby/src/trunk-repeat20-asserts/test/-ext-/thread/test_instrumentation_api.rb:33]: - Call counters[4]: [3, 4, 4, 4, 0]. - Expected 0 to be > 0. - ``` - - We fire the EXIT hook after the call to `thread_sched_to_dead` which - mean another thread might be running before the `EXIT` hook have been - executed. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7249 - -commit 22d944c8b76be04dc437100c46626db5fe9dd7f0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 15:09:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Avoid crashing at a random ISEQ access - - [Feature #19420] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit d6814fa24f403c9152ab9727782d45f9f5f2c446 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 14:35:41 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Fix a BytePtr check of test - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit d51b4d4c3efe1e4f19d64173c994b535a128f42d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 13:51:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Add Mod 10 to test r/m64, imm32 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 7573854c9f47eb71fa1ad836de2c0eba44a965c1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 07:39:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Add Mod 10 to cmp r/m64, imm8 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit a1ad5a21652b460906f04bcd1be278aa831404ff - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 07:34:46 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Omit test_version for Cirrus for now - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit d6fde0e6db33ff281660a4222ae183a27d6a73ea - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 07:15:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Change default call threshold to 30 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 1c267d0723a076d7e22e7b8f7c3360d200a239c3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 07:15:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Workaround USE_MJIT warnings - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 823309debc57e3f0a13f089fff821c100f779e21 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 07:08:46 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Remove unused variables - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit ef7f56c734ddc3715d3dc50c45b72237596e9464 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 07:00:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Resurrect CI for MJIT - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit a7d01656b1fb453d2dc46fe785a1ba656e4130d4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 06:59:08 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Rely on YJIT's switch for now - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit a085df268d6a4e34da6232ed6842ef43875f3ba3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 06:56:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Update dependencies - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit ed5770878ad621fb033ed140206cf05a533ec4e2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 06:44:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Remove duplicated declarations - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 91f1dc532cfd063b561a056c4c434956488d8505 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 06:41:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Remove an obsoleted test - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit f0218303e050377da8f4b21a6a2a0bc4c3118cb6 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 16:53:21 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize String#getbyte - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 31babc5ceaa8601075c344399a3bab59bb3dd1dd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 16:44:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize Module#=== - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 85c616967473589990d4003523c5dab47ac187cf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 16:20:54 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement struct aref - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 35faa33b65b14d7f3b25b48cf0ad135e8ce33807 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 15:42:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement bmethod - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 26cb5d416f9f966fb7856e936d7081d7c091558f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 15:22:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement alias - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit bd0d0d3b387b4ed87dde8a13a62c83eb9aafdb3a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 15:13:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Reset chain_depth in more places - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 4a124dc1de42600f979e5af53c6444645da2a5fa - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 14:35:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement optimized call - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit c2fe6fa0d0b00aedc006af26ea4903c79e6d24a8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 14:26:46 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Chain-guard blockarg - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 2c25f0daaed7171e68bae31f692c72a5175978c0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 14:13:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement proxy blockarg - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit c17f200500fb0b33c11c0f4eaef97eca3399fdf4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 06:39:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement nil blockarg - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit c587666f68bc3cd21d8dde9b759ef19574c50ca3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 17:01:30 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize Thread.current - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 9ee724408c1da10c7323c07405d5e01182aeb0bd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 16:55:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize #nil? - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 9556b6368f93f60b2e46d2a6e030321413a9d8d0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 16:51:31 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize String#to_s - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 8049f3c9c7af2487716c088ddee28495263761b3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 16:36:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize BasicObject#== - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit cc646d3262955b10907d984d4de72c1b23cf0c89 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 16:00:30 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement getblockparam - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 6b38d1ce7bfb37e3891eaa2155c906889c6ef28e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 15:54:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement concatarray - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 481615418a26568c3972daefaed7d583815e7191 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 15:49:31 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement getconstant - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit f2ef352ee0bfa65cef8242740ab7ba5a831d1934 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 15:45:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement opt_str_freeze - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 89f8e20aa410fa0728b638a92adca114a71706c0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 15:42:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement branchnil - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit a1b23954093ef8e840736f78b02659a383fe4ade - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 15:30:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Check for classes consistently - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 6b2c3ff813a78559ab2e88495db593a54b47e995 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 15:21:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement concatstrings - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit f85393514cfeadf27129c5607c257368041dd544 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 15:17:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement anytostring - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 43d1a7afd44e6016a8638e4801da8ddc137b0654 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 15:14:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement cref on opt_getconstant_path - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 46a14b65fbeca6bc27e43da4248726b289f1157a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 15:03:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement objtostring - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 9fa127416a24312ce2f356c3317f6ff2520977b5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 14:50:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement protected - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 3b38fe028035a024095dedffb4c8a1efc4f320ce - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 14:41:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement getclassvariable - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 7456b10c33ef984a685d174d7ff4ed418001923f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 14:29:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement getblockparamproxy - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit f81c7a674751681d77d84110ffdb9c609b602cea - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 14:10:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Initial support for opt_case_dispatch - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 366c3c76446108ae442e1918c15219b0fef3fb8d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 13:59:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Support non-T_OBJECTs in getivar - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 49f336f468659af722d473f3e3073a4e97719f76 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 16:44:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement new ivars on setivar - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 6d59cac4ad8944a725762165d470953dd534528b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 16:28:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize Integer#[] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 34f2ab1f3c389e7d802128706008db2d8445fc3f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 16:21:28 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize Integer#/ - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit d38069264918e7d0c5aff223414ba45dced92c66 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 16:15:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize Array#<< - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit e4f49236c09240aa9ddbbd6a870119a99e3c78eb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 16:00:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize BasicObject#!= - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 2ecf77ce205d9732c8c1fcfbf031835c4d53ebbd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 15:52:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize Integer#=== - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 92efd0569a1da349f8bc7f8214e3a780fd0c575a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 15:43:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize Integer#* - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit db4a8afa5e55591aa1e167ffde5924fc8f1f4807 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 15:23:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize BasicObject#! - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit e8a36eb4f6f30f5d96960a4cc4025d020018f37b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 14:14:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Optimize setivar for known ivar index - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 357007626ce77cd3cdb9e44568c1794e515792f6 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-02 16:38:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement opt_newarray_min - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 42adcd5743d68b96391c96d7b23e3890606afb1a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-02 16:29:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Increase max depth for chain guards - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 487d4aa970d910c8f521ea97ae78e3ffc119cad3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-02 16:23:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement known class guard for flonum - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 3034553e8dc1e78b96ad283ab57c70e674f54d6e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-02 16:15:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Add more GC guards - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit d7888e462698f89d90e7baf3a0014d63e9aaad2d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-02 15:21:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement opt_pc - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 706f6272d9340f54b30bd9c83c97c5c22d2e894d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-02 15:06:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Guard against GC of random ISEQs - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 7dcdffebc8da9319bc2a0a2e0d9e90fdc140d79c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-02 14:32:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Invalidate blocks on global constant changes - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit b5fbc9f59f760f5faaca82c5b2bc869a6f38ade5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-01 16:22:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement ISEQ block_handler - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit fb08b0e748549959cd6eeaa7f4bc1babd9125557 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-01 15:50:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Start implementing send - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 8b84c68d77f4697cc647860c168c2b85b8f6e84d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-01 15:45:59 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement defined - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 536d8cc51b065315ff463594b5135abb5f1340da - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-01 15:27:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Fix invokesuper for railsbench - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 33213542f241709727475a386a3fa189d426b52d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-25 07:48:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement invokesuper - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 5576da7900162234c8e114b72401a8e0681c7c61 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-25 07:38:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Re-compile MJIT entry on constant IC update - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 15cea7fd0d729a7646707e386d2e2b43d52f0421 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-21 17:32:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement newhash - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 4d85f21ee806910db4661a4112c556618ee14a99 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-21 17:22:50 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement swap - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 8d29b0635bd87cb8e0521cb0ffdc617382e3cccb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-21 17:19:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement putstring - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 32e6f15bebf120635d575986fdded1a3943395d0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-25 06:52:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Store MJIT blocks on each ISEQ - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 63d96ccbcd21653ac1e5afd96dbd72bc78900de0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-25 06:19:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Invalidate everything on GC.compact - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 44c4a2d80d72f1261cfe41ca04ac8e9b826793ca - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-21 17:16:05 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement splatarray - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit a666079404cbd74315743471998d8e35e11f8eef - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-21 17:11:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement topn - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 4106487ae8983e8afadef2a56018635645d2b9bb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-21 17:02:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement newarray - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 3a97d547257b304d48e6c8a1268e882f9a549d80 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-21 16:57:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement adjuststack - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 993c43e4294cf445e0422f56f1b2d3ac53aa5e84 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-20 16:35:48 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Change a branch stub shape only when needed - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit bef63f445b85bcfea5e76a724ee3b03be35a82cf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-20 16:05:29 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Skip invalidation for trace_ insns - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit feb60f6f5107561f2e83e3f53b1db52d2b201708 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-19 07:45:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Invalidate blocks on constant IC updates - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 2cc4f506bac0748277b41a4a5eb6f0ec41dd7344 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-17 15:29:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement optimized send - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 2603d7a0b7b0e698bed8910a8ad5edefe236de77 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-18 13:57:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Remove unneeded ci references - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit a4bf1c661b47840f49ab1081f37fe677f7de09cd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-16 17:11:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement opt_invokebuiltin_delegate - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 7b78fd0df216002303f8b44a701866be1c9db2f9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-16 16:43:53 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Count optimized method types - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit ecc86f79ca57ae65a425d50ec64c1cf2cdd6431b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-16 16:13:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement opt_aset - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit d120394df30a3dd1878f183966489c100755e4b4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-16 14:26:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement duparray and expandarray - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit e078a4a9649240bbac2119891e4bd6c0a4952551 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-15 16:48:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Count opt_getconstant_path exit reasons - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 4271927d619469faa7f82e8899b8c185961137f3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-15 16:44:44 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Side-exit on cfunc with -2 argc - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 4d97f9319c23dc051ac9cdc8fa3279265da304da - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-15 16:18:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Initial support of opt_getconstant_path - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit a9ef36866a391ddb1cc7005919d80f1a1ab9b5f2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-15 15:52:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement dupn and setn - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit c3ca9448bf62461d84ea333ac83649c5e1b77c6b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-15 15:24:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement all getlocal/setlocal insns - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 3774fe4e912afc97649207fdfd17aa8b44903152 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-14 16:57:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement opt_eq and opt_neq - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit b5c5052839b126d479add428c0c227157a96a90c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-14 16:32:48 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Format numbers with delimiters - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit bc50b0475a64dbae293c29bf3e6b72ba12424c99 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-14 16:05:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement opt_and and opt_or - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 67cc53214cdb5900ccc75e195d8e9c85dea519f9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-14 15:50:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement setlocal_WC_0 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit ba491598cc83f0382040cc6198bc7e114a192462 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-14 15:36:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement opt_mod - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 73a5b3d5d2cc696ee5a993723a804696118d171f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-14 15:23:22 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement Array#[] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 51d36c7b34c898c19dff578e665fa0bf1a3cff01 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-14 14:48:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement opt_le, opt_ge, and opt_gt - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 1b0fbd137fb4fa07e1a67fcf75302a80afac0c50 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-14 00:30:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement branchif - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 9bce848b4cde9f0868dee290dfe4249421164252 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-13 17:00:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Side-exit earlier on interrupts - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 11bd040b8900ea2e55c1188ceb59dd5694be8336 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 16:36:48 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Fix a typo in jit_chain_guard - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit 39b787448126d9c6363bb5d8ce5e82ffef6a1c22 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 15:07:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 16:28:59 +0900 - - Implement variadic C func calls - - Notes: - Merged: https://github.com/ruby/ruby/pull/7448 - -commit cacf2f3709a570560085e6a95c3a78e8fb8cc0f5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 14:54:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Set 0 to cfp->pc on C func send - -commit 9e42f315741b8e1be38540ea3d115ef0fc72cd51 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 14:06:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Do not compile C calls when C tracing is enabled - -commit 20e55be47ccf1ba89d6ca061f45625f1bd8e8578 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 10:45:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Re-enable cfunc send - -commit 14acf9b0a3c5c06cd8a1bf60c929b25c6e7fee66 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 10:41:59 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Decode trace insns properly - -commit b30392f8ab16b10074a7362f187850e6898a20bb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 10:22:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Disable TracePoint during MJIT compilation - -commit 1892ec5738b70ef13593417b6ec20858a94cec47 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 09:04:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Lazily invalidate cme for safety - -commit 1bdc23f35b31625cf570f6e8bc85b8289d783a71 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 07:41:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Redo compilation of all ISEQs after invalidation - -commit b379ccf755b8f30d3b029f124e2870dcd4a87dab - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 08:23:57 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Handle RangeError in iseq_lineno - -commit 1fa519fdae39928fefa7845db9fa17aa8bafe21e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 08:22:05 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Handle failures on branch_stub_hit - -commit aba530e23b463c3a682ab9bc233568c684d1fe81 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 04:43:53 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Implement invalidation after cfunc - -commit 494989e87e5095a2789c110972c0a1a43f544601 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-10 09:25:06 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Partially implement send of cfunc - -commit e8c13e55fb84ae55299f4d97cd3f9042e07dc4cf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-10 15:06:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Delay CFP motion a little - -commit b2447b644d10f05f4dac578fd1fd7ab8bb9a609e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-10 15:02:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Use fewer comments on frame push - -commit b05dbe785efedc5e6bf31b59406bb006ab40efe4 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-10 14:59:27 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Delay SP motion a little - -commit 9f805530e21f635566fd4800d833f0ed6ccf49ce - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-10 14:49:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Adjust the interface of jit_push_frame - -commit bdf98237fa929e1f43d3e355060e9e4577546842 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-10 09:06:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Support more types in jit_guard_known_class - -commit 2c87cf8013e1e2dcd2e6a312531ad46fbc92cee7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-10 07:38:41 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Implement stackoverflow check - -commit ac7b2f0d177312f4d2da52c00b66221802f16595 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 10:54:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Check interrupts on jump and branchunless - -commit 091c2ee1acd65bcc17801be6a08dba6b8843ac55 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 10:42:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Implement jump - -commit 557bd8640203efd9056927fbdcfdcfe9e3270235 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 10:38:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Re-enable opt_aref with Hash - -commit 6bc8e4a279f953148e17b23b25f0db8d3d37fcbb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 10:37:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Fix the operand for branchunless - -commit 98a3b40d5517d0d7444597f49287830b8ec2f041 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 10:33:27 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Implement pop - -commit dcdffb1aa009252fb7ad240c262d6232a053e29e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 10:27:21 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Initial support for setivar - -commit eac44ec212cad8c534292447bdf2fd5b795dcf97 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 10:17:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Implement dup - -commit 50bd7326c1a09c9c28f5483299c3f199ac8da7b5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 09:55:50 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Skip Hash on opt_aref for now - -commit ecae1cd74e2f60f07399df8bf2023967bd605abf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 07:36:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:35 +0900 - - Implement attr_reader - -commit e6354d5e9b6c054faa4590a1ba4aebec4004e6ff - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 07:17:15 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:41:18 +0900 - - Deal with too slow test - -commit fa9a0cb970ced2ead175392bfde89a952e710dd0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 07:24:10 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Count unsupported method types - -commit 64074ca4dfa7cc12e5966e6e763b2794bd97aecc - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 07:19:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Refactor recv_opnd - -commit 365cda16b5029a152076d96e349c7eb611a08ccf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 04:51:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Delegate opt insns to opt_send as much as possible - -commit 8d099ff699fb475f9fa2bc3abf19c3700c4f37f0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 04:10:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement opt_aref for Hash - -commit a458923fe5f47d753f13c5fa4c7f74517f54c145 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-08 18:48:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement jit_guard_known_class - -commit 2cd6406d67017f0927cfe6409e20900c9bbe2a6f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 03:24:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Save PC and SP on entry exit - -commit 6be4e065eb2ff2bb25cd88de4f41fac20e693f37 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-09 02:30:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Support SP motion in all insns - -commit d332c6ee126870aa3413de8d96e493b527559181 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-08 18:17:39 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement getlocal_WC_1 - -commit e92edfc7f02edfbc9bedddc5b4e162c00ac141b8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-08 17:47:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement jit_chain_guard - -commit 0a400f38e8005c280a84bab38b64eeeec99a6316 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-08 16:40:05 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement nop - -commit 3ed7fa76e0dad293bf7d1b7a6672aa0f1589e0b2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-08 16:32:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement counted exits - -commit d11f960fb0243f2285f7f476c8b0fd244bbbdfc5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-08 16:25:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement non-embedded ivars - -commit 5a1cee1d965301b05e9d2d85b0ee39ef3c6757f7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-08 07:42:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement getivar - -commit a026bcedc87a2f502befbd7476a997a9fe030203 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-08 06:03:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Allow reusing existing blocks - -commit d415f1e3178625fa90ab908dcc5636b7e2e21c16 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-08 04:55:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Get rid of BlockStub - -commit 47e2ea3a800dae6ac4d427ad9524a7d61dd992ee - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-08 04:51:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Refactor callee with BranchStub - -commit d88b59be92eeeeaddf5b15c57b807a4e3908b12b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-08 04:36:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Refactor jit_return with BranchStub - -commit 6c1b1fa1f52f7c79b98a6b86f4f1f03f069dd36b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-07 17:17:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Refactor BranchStub - -commit 4bb4479165209af59efae2dd3248873eecc3d4f5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-07 17:00:09 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Add compiled_block_count - -commit 5c638c97bb8e46b558b41b17b988722bb9432196 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-07 08:44:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement opt_plus - -commit 439f8a0f146fe45c3cecc5e5d6e50d86fa23e29d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-07 08:07:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Support passing arguments - -commit e731ced2717ed151369b2d6635452ffdf0c96e43 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-04 15:42:13 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement method call - -commit fa0b9c1c97ba1ab03e2675ce96bceda9ef046127 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-08 14:24:30 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Initial implementation of send - -commit d09c723975a4386d283ca914a7369340fd07d925 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-08 14:24:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Just write bytes normally - -commit f4cf737af8a863e4e232232503c40b0769b742e2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-08 07:26:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Support Mod 10 mov - -commit 9ef04f56367453d9c3a374bb4dfda2b64ba57924 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-08 07:06:38 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement opt_minus - -commit ee6d627b434c4bc977c059a0e1d885800de90b63 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-08 06:54:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement putobject 0/1 - -commit 850303ded65e2a949732a6a7d037079d610d22a6 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-08 06:39:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement putself - -commit 62d36dd1277bdfeac609f89bc64589e8856421b8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-08 06:21:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement branch stub - -commit eddec7bc209d721e99a8cd5ceaafd0f2ab270cc3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-04 17:32:58 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Support release build - -commit 1f69ba1d8413abe20e95f74761ba267f0e35c649 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-04 17:12:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Use the actual sp_offset - -commit ee80b2be20ae8a5102ac478f2b0fc0cf8786eaa3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-04 16:51:37 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Fix broken stats - -commit a8dec34961d7734ad975e44efa8aae361a1c4f5a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-03 15:53:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement initial opt_lt - -commit 21696ad81ec40cf9cd146836dc8c945f1e485774 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-03 07:11:06 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Partly implement BOP assumption - -commit 00c659d246784fe98114136bc3eb4d7f02cb071c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-03 06:30:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Move the insn dispatch table to InsnCompiler - -commit 4b6c7381808110e725d3bc08f3fbdbb13c44128f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-02 16:13:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Rewrite the stub if it's the last code - -commit c3d99d0f12e2b494e16a5c61134ca312a3a6e3a5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-01 06:41:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement defer_compilation - -commit 2b8d1c93ea4d44fba5997901fc4a50b9436bc8b5 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-01 07:14:53 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Support extended registers - - and move argument registers to a couple of them. - -commit d7dba4c51066eb706987356ad6b862a0b60b1aeb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-31 16:42:00 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Colorize outlined code - -commit 36cec59f0a54b817ae6b3836fb0e97e342b999ce - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-31 15:16:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement ocb - -commit 7abff797b434ead0653c89f5429490bd0f716f88 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-31 15:05:53 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Use the term "compile" in different places - -commit c51baf9404373c8cb37a1fb887c50c0216576186 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-31 14:34:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Carve out CodeBlock - -commit 28290d519860a7dce138e4c5684f72b0215180e9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-31 14:27:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Try carving out ExitCompiler - -commit 7a19aad8c355c1f476712afa3024a71e630f43dc - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-29 07:43:04 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement putobject - -commit 9352f94a1b7874a254f124ec8e719151d2b02946 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-29 06:50:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement getlocal_WC_0 - -commit 4eb6f1dbb9062097c65077eda7945f791c7e4464 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-29 06:16:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Put nil on an appropriate index - -commit e9535a439b1c6717154a79b86d698cb81c3a7d70 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-29 06:16:02 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Split branches for mov src and dst - -commit 5760f7fd3c977b610ed3c8281eb2533b0fde2cbe - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-28 16:57:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Skip compiling at_exit without --mjit-stats - -commit e4a824f7695a8de9afb90978ccda038b7d280372 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-28 16:04:53 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Fix broken rebase - -commit 9f8f1afba2572ead6ce5a8ca456cb9cabf094c98 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-27 15:46:40 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement --mjit-stats - -commit 5ab8cf3f0d01ea8bf11bb03b865669a68d56a35a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-27 15:33:00 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Skip a failing shape test - -commit 4fe5efbf7f784803f8ac48824f350b6dc91d644c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-27 15:06:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement asm comments - -commit 652d63789f5fd37865c5000712236a214ced9fbf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-27 14:37:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Fix TracePoint tests - -commit 3b398513bea65bb0237bb8b7a383ba2874bb0b84 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-27 07:09:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Check interrupts on leave - -commit 114f8d3e330735fda394c58d7a373913f9ccb93b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-24 17:11:59 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Disable MJIT on a couple of conditions - -commit 43f579afb404be4c1c6dfd98e1936a2ede917e7f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-24 10:39:44 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Fix a critical mistake around GC - -commit 25ae82b83e36f96d18d1ba29431676329b7307d8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-24 10:39:34 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Skip supporting has_opt for now - -commit d46cc2c1047d3811386ff4f95ec0a877cc40172a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-24 10:15:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Remove <main> specialization - -commit 5db2ef5e1480fe15299ea39fe062376e50e35b47 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-24 09:23:21 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Define constants for magic registers - -commit 783f730773b50a18be5abd2766ff64d4cb917136 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-24 08:56:05 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Lock VM during compilation - -commit 23a58105eeff3c0a4ba34d51c822c6d10e95c24b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-24 07:46:39 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement callee-saved registers - -commit 71595a37bac2b8d3dacfd22114f1d596416260f2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-24 07:17:32 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Consider stack_size on side exits - -commit bee5af407d194672d4971e70b0d232698c071f6d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-24 07:02:23 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Rename InsnCompiler to Codegen - - because I'm not gonna limit this to insns anymore. - -commit b99d62bf92b929858975dc7eb9c079b15ac84c9d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-24 03:43:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement initial side exit - -commit e750e1e3ee81105cbc59a45cf016e51a1c42932c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-21 16:48:12 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Fix build without libcapstone - -commit dfa19a16586b0760d1644170a5096ec6bf4831fd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-21 16:38:00 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Properly return a value from the stack as well - -commit 145c937f3f9600166de7c4c3aceb724d8218cfeb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-21 14:54:54 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Compile putnil properly - -commit 8deb0438c48c7c140a1aec1eef055d972aff7507 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-21 14:53:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Remove debugging code - -commit e60fc8c2ff2fb707d983154518741f3b3fbc3128 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-19 17:09:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Encode add insn properly - -commit 396d5754519e044658c107138d949bef006e8a12 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-19 16:45:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement mov encoding properly - -commit 2700d35b7ba0543c36cf9a07e0459483a1272ea6 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-18 15:00:16 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Split responsibilities differently - -commit d9c2eb6f4288e5a0b03222854b4ad62c2047cd2b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-18 06:39:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Move modules around - -commit 6fc336fedcbf58cceedd272ecf1ac2f725662f73 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-16 15:20:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Compile a real return value - -commit 3fa4d41460f67791d08d9bec2f8add9dd15f0f07 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-14 17:12:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement --mjit-dump-disasm - -commit fd04e1b4dbbb0dae130f3de79d69ca94ecdf883e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-12 14:42:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Implement a no-op JIT compiler - -commit baa120ee8008a30c11066daa30cb03fcedc2e02f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-12 14:32:24 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Prepare a JIT buffer - -commit 9c2f61201786d13c08d25aafe6f150dd50819145 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-12 14:16:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Prepare for compiling an ISEQ - -commit 40ffc1e0f424156ef6eb7687cd620994007895f2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 06:09:54 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Drop existing MJIT tests - -commit 3d19db4f8b2b1f768f9737c72c77341ab2fc3330 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-11 17:00:14 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Use call-threshold 1 for now - -commit 251f976235430effddf82cb08ac0e389ddd36a74 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-11 16:55:33 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Prepare rb_mjit_compile hook - -commit 3c093fe391914dcfc10c69971164a66cb71c6bd3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-11 16:39:21 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Move important functions - -commit c263ce9c80a2acdd64270cf5d246c19c58947d18 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-11 16:35:30 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Remove more code - -commit 5d819b9a151711f5af1e9333c6685c18c6a5a431 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-11 16:16:19 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 15:11:20 +0900 - - Clean up the current MJIT implementation - -commit e87d0882910001ef3b0c2ccd43bf00cee8c34a0c - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-01-13 17:52:59 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-06 15:03:06 +0900 - - Change bytecode of `f(*a, **kw)` - - `f(*a, **kw)` is compiled to `f([*a, kw])` but it makes an dummy - array, so change it to pass two arguments `a` and `kw` with calling - flags. - - ``` - ruby 3.2.0 (2022-12-29 revision a7d467a792) [x86_64-linux] - Calculating ------------------------------------- - foo() 15.354M (± 4.2%) i/s - 77.295M in 5.043650s - dele() 13.439M (± 3.9%) i/s - 67.109M in 5.001974s - dele(*) 6.265M (± 4.5%) i/s - 31.730M in 5.075649s - dele(*a) 6.286M (± 3.3%) i/s - 31.719M in 5.051516s - dele(*a, **kw) 1.926M (± 4.5%) i/s - 9.753M in 5.076487s - dele(*, **) 1.927M (± 4.2%) i/s - 9.710M in 5.048224s - dele(...) 5.871M (± 3.9%) i/s - 29.471M in 5.028023s - forwardable 4.969M (± 4.1%) i/s - 25.233M in 5.087498s - - ruby 3.3.0dev (2023-01-13T01:28:00Z master 7e8802fa5b) [x86_64-linux] - Calculating ------------------------------------- - foo() 16.354M (± 4.7%) i/s - 81.799M in 5.014561s - dele() 14.256M (± 3.5%) i/s - 71.656M in 5.032883s - dele(*) 6.701M (± 3.8%) i/s - 33.948M in 5.074938s - dele(*a) 6.681M (± 3.3%) i/s - 33.578M in 5.031720s - dele(*a, **kw) 4.200M (± 4.4%) i/s - 21.258M in 5.072583s - dele(*, **) 4.197M (± 5.3%) i/s - 21.322M in 5.096684s - dele(...) 6.039M (± 6.8%) i/s - 30.355M in 5.052662s - forwardable 4.788M (± 3.2%) i/s - 24.033M in 5.024875s - ``` - -commit 0463c5806ac63bbd082f4abb1e3ceeae6ffc39ce - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-03-06 14:52:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-06 14:52:46 +0900 - - [ruby/irb] Improve method completion for string and regexp that - includes word break characters - (https://github.com/ruby/irb/pull/523) - - * Improve method completion for string and regexp that includes word break characters - - * Remove completion-test's assert_not_include because candidates no longer include every possible methods - - * Add comment about string's method completion regexp - - Co-authored-by: Stan Lo <stan001212@gmail.com> - - * Add comment about regexp's method completion regexp - - Co-authored-by: Stan Lo <stan001212@gmail.com> - - --------- - - https://github.com/ruby/irb/commit/aa8128c533 - - Co-authored-by: Stan Lo <stan001212@gmail.com> - -commit 62e2b61607c04ff0d2543f0515b2171a24e66b4e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-06 14:49:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-06 14:50:53 +0900 - - Replaced non-ascii charactor. It fails version detection at `net-http.gemspec`. - - ># Returns the X509 certificate chain for the session<E2><80><99>s socket peer. - -commit 760fe0a78a4129bdc6ba66fb3ac0c63b160ab9f0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 14:26:59 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 14:27:05 +0900 - - Disable test-spec as well for annocheck - - https://github.com/ruby/ruby/actions/runs/4340193212/jobs/7578505652 - -commit 5d35b4b0e1e511981db062f7c8f803931d06e1cb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 14:11:59 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-06 14:12:00 +0900 - - Skip test-all for annocheck - - It started to fail since totally unrelated changes. It suddenly gets - killed by SIGTERM only on this environment: - https://github.com/ruby/ruby/actions/runs/4340112185/jobs/7578344307 - - For now, we have no idea how to fix this, so let me skip this until we - figure it out. - -commit f5b6b3dba7b32dcd1f15c150dd78dce6c0d92b1e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-06 14:10:31 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-06 14:10:31 +0900 - - Split a workflow for annocheck (#7450) - - It's not really about different compilers. It seems confusing to have - this in compilers.yml. - - This change only forks the entire workflow and modifies only matrix - entries. - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit a5310e609d76ee71e0ff39d5145609853586206e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-03 16:02:02 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-06 13:57:17 +0900 - - [DOC] Fix options of `Regexp#initialize` - - `Integer#|` is bit-wise OR operator, not logical OR. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7435 - -commit 8ee604b9d4daa46a1571221dcd9ceab824ac372d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-03 15:52:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-06 13:57:17 +0900 - - `rb_scan_args` never fills optional arguments with `Qundef` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7435 - -commit 883871d722374b11b0bdd293a027609e8b891ba9 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-05 02:42:38 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-06 13:30:54 +0900 - - add a test for Ractor - - Ractor should take care method cache invalidation. - Added test will miss method cache on each method call. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7445 - -commit f70b46dbc70a2367525e7124f50d924d06261888 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-06 13:01:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-06 13:01:54 +0900 - - More debug for 75829f4d37d31658aeebd9799b513e35fea805e0 - -commit 75829f4d37d31658aeebd9799b513e35fea805e0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-06 12:43:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-06 12:45:05 +0900 - - Added debug message for http://rubyci.s3.amazonaws.com/freebsd12/ruby-master/log/20230306T023004Z.fail.html.gz#dist - -commit 5ad81e6627679b542a4cc2b2469dd5706f5abd52 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-06 10:42:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-06 10:42:50 +0900 - - Revert "Update bundled gems list at 2023-03-06" - - This reverts commit 84150e6901ad0599d7bcbab34aed2f20235959ff. - -commit 38831ae290ac421e48083ab8f134467eefc13676 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-06 10:27:29 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-06 10:42:36 +0900 - - Introduce `UPDATE_BUNDLED_GEMS_ALL` option for auto update for bundled_gems file - - We used `url` field for testing via git clone. Because `Gem::Specification#homepage` or - `Gem::Specification#metadata` could assign non-git url. Unfotunately, We should specify - clone URL for testing. - -commit 84150e6901ad0599d7bcbab34aed2f20235959ff - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-03-06 09:49:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-06 09:49:09 +0900 - - Update bundled gems list at 2023-03-06 - -commit 848b55ad8f7dfac2550d96c216162e40c3e9337d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-06 09:34:52 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-06 09:34:54 +0900 - - minitest moved minitest org from seattlerb now - -commit 0c9a2ce6e0732aa78dc07068ffb7b606ac340035 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-03 18:19:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-06 08:52:28 +0900 - - [rubygems/rubygems] Build default gems same as fresh installtion. - - Current implementation tried to build installation artifact. But default gems - didn't provide normal gem files. So, It's always build failure. - - https://github.com/ruby/bigdecimal/actions/runs/4269574995/jobs/7432842788 - - ERROR: Error installing pkg/bigdecimal-3.1.4.gem: - ERROR: Failed to build gem native extension. - - No such file or directory @ dir_s_mkdir - /Users/runner/.rubies/ruby-head/lib/ruby/gems/3.3.0+0/gems/bigdecimal-3.1.4/ext/bigdecimal/.gem.20230225-2301-2mul99 - - Gem files will remain installed in /Users/runner/.rubies/ruby-head/lib/ruby/gems/3.3.0+0/gems/bigdecimal-3.1.4 for inspection. - Results logged to /Users/runner/.rubies/ruby-head/lib/ruby/gems/3.3.0+0/extensions/x86_64-darwin-19/3.3.0+0/bigdecimal-3.1.4/gem_make.out - - https://github.com/rubygems/rubygems/commit/2157aa8ec8 - -commit bab809d98f2a0a8a23efd62df750beccbf1b35d9 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-03 16:30:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-06 08:52:28 +0900 - - [rubygems/rubygems] Introduce Gem::Specification.find_by_full_name for finding conbination of name and version for gemspec - - https://github.com/rubygems/rubygems/commit/0430551215 - -commit fc5482d0889f174f39395048352e7a2a88b133ec - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-03-06 06:00:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-06 06:00:34 +0900 - - Expose the address of MJIT Pointers (#7446) - - This way we can manually dereference pointers with Fiddle - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 1b4c1492c1704407f86af2882efebc047b9c2d26 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-03-06 04:06:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-06 04:06:37 +0900 - - [ruby/net-http] [DOC] What's Here for Net:HTTP - (https://github.com/ruby/net-http/pull/128) - - https://github.com/ruby/net-http/commit/39e70f0f9b - -commit 477fc776fdf03cbc69f0cd2c6fde6cac58b757f0 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 15:35:50 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-05 15:35:50 +0900 - - Just use the latest minitest - -commit 17ef1c8164ea37574d928e9487232f27b5a5998d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 15:34:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-05 15:34:58 +0900 - - Revert "Workaround minitest's version issue" - - This reverts commit a3abe3fd6d59a3624a193028a0d3b6b9e90b0260. - -commit a3abe3fd6d59a3624a193028a0d3b6b9e90b0260 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-05 15:29:20 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-05 15:29:20 +0900 - - Workaround minitest's version issue - - Every RubyCI is broken because minitest has a newer version. - http://rubyci.s3.amazonaws.com/ubuntu/ruby-master/log/20230305T061003Z.fail.html.gz - -commit 191e4ae33f5160bdd6f313e752a4eb719c3707b2 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-03-05 00:34:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-05 00:34:49 +0900 - - [ruby/irb] Drop chained methods' completion support - (https://github.com/ruby/irb/pull/529) - - Consider completion for this example: `foo.bar.b` - - Without type information, it is hard to know the return value of the `bar` - method, so the current implementation interates through `ObjectSpace` to - get all possible candidates for the second method. - - In small projects, the performance and accuracy are acceptable. But in - bigger projects, the performance is unacceptable and the accuracy is mostly - poor. - - So this commit drops the support for chained methods' completion. - -commit 6f81e38d1d77931e46aee0cb054c9cb3a82f3f3b - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-03-04 14:55:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-04 14:56:00 +0900 - - [ruby/reline] Fix completion with multiline - (https://github.com/ruby/reline/pull/513) - - https://github.com/ruby/reline/commit/d76c482c5f - -commit 4782bb352eaedf934d204ea76956a26d07ec9bcf - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 13:33:26 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-04 13:39:38 +0900 - - Another attempt to skip test_ractor on ci.rvm.jp - - This reverts commit 8d31a60f47fb053bcfe0c744a89bd666dae48539. - -commit 8d31a60f47fb053bcfe0c744a89bd666dae48539 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 10:03:25 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-04 10:03:26 +0900 - - Fix a YJIT enablement check - - This should be enough for `make test` and `make btest-ruby` while it - doesn't work for `make btest`. - -commit 4d59d01621aff771f669cf82648eeec84e3f720f - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-03-04 08:02:52 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-04 08:02:52 +0900 - - YJIT: fix CI issue reported by Koichi caused by small stack patch (#7442) - - Includes small reproduction produced by Kokubun. - - http://ci.rvm.jp/results/trunk-yjit@ruby-sp2-docker - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 62c2082f1f726cb90d8c332fbedbecf41d5d82ec - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-01 04:59:33 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-04 06:12:03 +0900 - - [Bug #19469] Fix crash when resizing generic iv list - - The following script can sometimes trigger a crash: - - ```ruby - GC.stress = true - - class Array - def foo(bool) - if bool - @a = 1 - @b = 2 - @c = 1 - else - @c = 1 - end - end - end - - obj = [] - obj.foo(true) - - obj2 = [] - obj2.foo(false) - - obj3 = [] - obj3.foo(true) - ``` - - This is because vm_setivar_default calls rb_ensure_generic_iv_list_size - to resize the iv list. However, the call to gen_ivtbl_resize reallocs - the iv list, and then inserts into the generic iv table. If the - st_insert triggers a GC then the old iv list will be read during - marking, causing a use-after-free bug. - - Co-Authored-By: Jemma Issroff <jemmaissroff@gmail.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7407 - -commit 0700d0fd1c77b4fddf803dea3c10be654df600ff - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-03-01 04:39:19 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-03-04 06:12:03 +0900 - - Fix indentation in vm_setivar_default - - Notes: - Merged: https://github.com/ruby/ruby/pull/7407 - -commit 8c8548b17509113b705e353e6dbf00c3bcee84f1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-04 05:48:14 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-04 05:48:14 +0900 - - YJIT: Fix a cargo test warning on x86_64 (#7428) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 8e13e705f9053ae2162ce51168e17e715a8ebcdd - Author: Kevin Menard <kevin.menard@shopify.com> - AuthorDate: 2023-03-04 00:25:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-04 00:25:29 +0900 - - [ruby/irb] Remove no longer necessary TruffleRuby test exclusions. - (https://github.com/ruby/irb/pull/527) - - https://github.com/ruby/irb/commit/8473d0bc0f - - Co-authored-by: Stan Lo <stan.lo@shopify.com> - -commit d78ae78fd76e556e281a743c75bea4c0bb81ed8c - Author: Rômulo Ceccon <romuloceccon@gmail.com> - AuthorDate: 2023-03-03 22:38:49 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-03-03 23:32:25 +0900 - - rb_str_modify_expand: clear the string coderange - - [Bug #19468] - - b0b9f7201acab05c2a3ad92c3043a1f01df3e17f errornously stopped - clearing the coderange. - - Since `rb_str_modify` clears it, `rb_str_modify_expand` - should too. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7437 - -commit b49053a6be3cc449678609f62048b7aed3a1f839 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-03-03 22:41:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-03 22:41:21 +0900 - - [ruby/irb] Avoid slow symbol completion when completion target is an - empty symbol - (https://github.com/ruby/irb/pull/534) - - https://github.com/ruby/irb/commit/35697f3ef3 - -commit a2b776a9b7f5fc039025a8b92bfbdf3ab0968ce1 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-03-03 19:18:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-03 19:18:51 +0900 - - [ruby/irb] Fix prompt test not to change STDIO.external_encoding - (https://github.com/ruby/irb/pull/535) - - https://github.com/ruby/irb/commit/09f16259db - -commit f1fe4a4a99f8ef182b18d90b66f572497a0d41e9 - Author: Johnny Shields <johnny.shields@gmail.com> - AuthorDate: 2023-02-18 23:00:42 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-03 18:50:30 +0900 - - [rubygems/rubygems] Update current_ruby.rb - - https://github.com/rubygems/rubygems/commit/8755ca959e - -commit 79ede4ae9911fdb180406b1a8adc7ee02e187a50 - Author: johnnyshields <johnny.shields@gmail.com> - AuthorDate: 2023-02-18 22:46:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-03 18:50:29 +0900 - - [rubygems/rubygems] Alias CurrentRuby#mswin?, mswin64?, mingw?, x64_mingw? to #windows?. (This is done instead of logging a deprecation warning.) - - https://github.com/rubygems/rubygems/commit/b9fcc7c0ab - -commit 6b46057e5c9524e11c004a541bb17a5871767d44 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-03 15:30:02 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-03 15:30:02 +0900 - - Expand the test directory to real path - - When the test source directory path contains symbolic links, that - directory might be placed earlier in the result of - `IRB::InputCompletor.retrieve_gem_and_system_load_path`, than other - directories in the source tree that are expanded to the real path. In - that case, the test file in "csv" under the test directory of csv gem - instead of the library path will be the first candidate, in - `TestIRB::TestCompletion#test_complete_require_library_name_first`. - - ``` - <"'csv"> expected but was - <"'csv/helper">. - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7432 - -commit 680bd9027f8cb7977bbc216609db2f4e3cf199a8 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-03 11:07:36 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-03 15:27:37 +0900 - - [Bug #19471] `Regexp.compile` should handle keyword arguments - - As well as `Regexp.new`, it should pass keyword arguments to the - `Regexp#initialize` method. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7431 - -commit 103a65316c103253059ca4c49359dc7eb0043a4d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-03 13:46:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-03 13:46:04 +0900 - - Regenerate parsers with racc-1.6.2 - -commit 90b74d8c65037a04c07a8e8ce852a55257151236 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-03 02:24:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-03 13:43:59 +0900 - - [rubygems/rubygems] Fix warning about ambiguous `/` - - ``` - /path/to/rubygems/test/rubygems/test_gem_commands_exec_command.rb:745: warning: ambiguity between regexp and two divisions: wrap regexp in parentheses or add a space after `/' operator - ``` - - https://github.com/rubygems/rubygems/commit/e6a538b5c8 - -commit 7fea848568741439c2ff25db4e03a607046b4ed8 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-03 02:23:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-03 13:43:59 +0900 - - [rubygems/rubygems] Fix warnings about unused variable - - ``` - /path/to/rubygems/test/rubygems/test_gem_commands_exec_command.rb:180: warning: assigned but unused variable - platforms - ``` - - https://github.com/rubygems/rubygems/commit/7e022cb5e3 - -commit b6d914c7228e09a37d879125917bcab179fa88c1 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-03 02:22:56 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-03 13:43:58 +0900 - - [rubygems/rubygems] Fix warning about ambiguous `*` - - ``` - /path/to/rubygems/test/rubygems/test_gem_commands_exec_command.rb:42: warning: `*' interpreted as argument prefix - ``` - - https://github.com/rubygems/rubygems/commit/0806ebf4e0 - -commit bd17bea6c5105133d8ba9c0e8ae6c89506a15823 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-03 11:34:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-03 11:44:35 +0900 - - [ruby/irb] Fix warnings because of `@context.main.delete` - - If the main object of the context has `#delete` method, the following - warning is printed. - - ``` - irb: warn: can't alias delete from irb_delete. - ``` - - https://github.com/ruby/irb/commit/00b39be61f - -commit 941d36d195691949afe2ce464b0d0aa20208e637 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-03 03:24:59 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-03 10:19:37 +0900 - - fix timing bug - - passing will and closing notification can conflict and - `Ractor::Selector#empty?` can return wrong answer. - This patch fix it. - - ``` - s = Ractor::Selector.new - s.add Ractor.new{10} - s.add Ractor.new{20} - r, v = s.wait - vs = [] - vs << v - r, v = s.wait - vs << v - [*vs.sort, s.empty?] - #=> "[10, 20, false]" (expected "[10, 20, true]") - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7420 - -commit ddd3c92bf6555de8fc89fe81ed3d00d2f4a88275 - Author: Ezra-Shimon Rosenfeld <ezrashimon@hey.com> - AuthorDate: 2023-03-02 07:08:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-03 09:40:40 +0900 - - [DOC] Add missing word to documentation_guide.md - - Notes: - Merged: https://github.com/ruby/ruby/pull/7414 - -commit 490efd673292ef00f2ad9129b894f117a3425040 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 08:05:39 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-03 08:05:44 +0900 - - Increase timeout for MinGW make test - - Apparently it's too short for MinGW - https://github.com/ruby/ruby/actions/runs/4317938324/jobs/7535630842 - -commit 7b9aeaffcb5b3850771a1d7b257a71a750d9359a - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-03-03 07:30:31 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-03 07:30:31 +0900 - - YJIT: shrink stack_size/sp_offet to u8/i8 (#7426) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 34026afd0434fc482b2a6419ec6aeece07dcf52f - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-03-03 06:21:05 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-03 06:21:05 +0900 - - YJIT: Delete stale `frozen_bytes` related code (#7423) - - The code and comments in there have been disabled by comments for a long - time. The issues that the counter used to solve are now solved more - comprehensively by "runningness" [tracking][1] introduced by Code GC - and [delayed deallocation][2]. - - Having a single counter doesn't fit our current model where code pages - that could be touched or not are interleaved, anyway. - - Just delete the code. - - [1]: e7c71c6c9271b0c29f210769159090e17128e740 - [2]: a0b0365e905e1ac51998ace7e6fc723406a2f157 - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit a9f4e5cc6099f2b2f6202e5ac252edddc07492f8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 06:16:09 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-03 06:16:09 +0900 - - YJIT: Fix default call threshold in help (#7424) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 446708409809e4164420f7ae842f0b97928fa3dd - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-03-03 02:17:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-03 06:13:12 +0900 - - [rubygems/rubygems] Enable `Layout/DefEndAlignment` - - https://github.com/rubygems/rubygems/commit/4403613fae - -commit 02ee8cb06a73d55fff141cc93432c4f0f452c642 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 05:13:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-03 05:13:59 +0900 - - Increase timeout for ruby/debug tests (#7421) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 98235834fa75ad86b920eee33480a087568c054e - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 02:58:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-03 02:58:06 +0900 - - Investigate missing ./autogen.sh - - https://github.com/ruby/ruby/actions/runs/4316772946/jobs/7532986318 - -commit 533c8c0c44d064eff90f8c26407a9e0fac4baa43 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 02:46:55 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-03 02:47:07 +0900 - - Re-skip an unstable Ractor test - - https://github.com/ruby/ruby/actions/runs/4316423442/jobs/7532190115 - http://ci.rvm.jp/results/trunk-yjit@ruby-sp2-docker/4466770 - -commit fac92cd05077e5f6ff9d955cc834df23b0f6a72b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-03 02:10:49 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-03 02:11:24 +0900 - - Revert "Revert "Re-enable test_ractor for YJIT"" - - This reverts commit 9792d9e40f790e6deb18ead56a8befc9d5c4bc51. - - Ractor implementation has been rewritten. Let's see if it works now. - -commit 573522bd8481db8d0cb042810b95bd573bd5fb23 - Author: Orien Madgwick <497874+orien@users.noreply.github.com> - AuthorDate: 2023-02-05 11:58:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-03 02:05:04 +0900 - - [rubygems/rubygems] Simplify the gem package file filter in the gemspec template - - The regular expression is difficult to understand at a glance. - Let's replace it with a much simpler string comparison. - - https://github.com/rubygems/rubygems/commit/a3745aa03f - -commit ce476cdfb7d6ffbff3d6f179da22f16d18d2f12a - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-03-03 00:57:19 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-03 00:57:19 +0900 - - YJIT: Fix cfunc splat - - Follow-up for cb8a040b7906c09d9d3ac3d3fe853f633005024f. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7418 - - Merged-By: XrXr - -commit 5875fce6ce678c444456cc7eed6f28ef000dac24 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-02 18:27:44 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-03 00:08:02 +0900 - - `Ractor::Selector#empty?` - - It returns the waiting set is empty or not. - - Also add Ractor::Selector's tests. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7417 - -commit 5f3c7ac19674b822c72e09e40cfb58fc71ac501e - Author: Tony Hsu <tonyc.t.hsu@gmail.com> - AuthorDate: 2023-02-27 21:02:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-02 23:43:27 +0900 - - [rubygems/rubygems] Replace lockfile with `.locked` - - https://github.com/rubygems/rubygems/commit/203f3e3802 - -commit 556439613aa6a0d05a9884a305ae43f48cd2c5f0 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-03-02 22:53:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-02 22:53:44 +0900 - - [ruby/irb] Handle long inspect and control character in prompt - string - (https://github.com/ruby/irb/pull/528) - - * Handle long inspect and control characters in prompt string - - * Add constants for prompt truncate length, omission and replace pattern - - * Simply compare string instead of regexp in prompt truncation test - -commit da6ac30d1e505bd15b8c118816a9990b5cb072a7 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-03-02 22:48:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-02 22:49:03 +0900 - - [ruby/irb] Specify metadata to provide richer information on - rubygems.org - (https://github.com/ruby/irb/pull/532) - - https://github.com/ruby/irb/commit/f01c2a6ac1 - -commit 72811deaa8be9101e2be7533118f136cef78dbb4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-03-02 19:18:13 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-03-02 19:18:13 +0900 - - MSWin: Use MESSAGE_BEGIN/MESSAGE_END instead of bare `echo` - - To strip enclosing double quotes. - -commit 14355dde831b4988eee2f9a63defc30d29116fb8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-03-02 16:59:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-02 16:59:50 +0900 - - Use https://www.ruby-lang.org/en/downloads/releases/ for download the old versions of Ruby packages - -commit 04cfb26bd394b8e92f24f18799f5e9fc96b2ea69 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2022-12-29 01:08:12 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-03-02 16:42:47 +0900 - - Remove support for the Regexp.new 3rd argument - - This was deprecated in Ruby 3.2. - - Fixes [Bug #18797] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7039 - -commit 6207a3f588ae0d0f7eb6303f7cccbe19f37ba6d1 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-02 15:30:27 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-02 16:14:49 +0900 - - Enable flaky ractor test - - I hope a4421bd73c286253311c2cdf8c78ed258f8cff44 will solve the issue... - - Notes: - Merged: https://github.com/ruby/ruby/pull/7416 - -commit a4421bd73c286253311c2cdf8c78ed258f8cff44 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-02-24 18:46:17 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-02 14:31:54 +0900 - - Rewrite Ractor synchronization mechanism - - This patch rewrites Ractor synchronization mechanism, send/receive - and take/yield. - - * API - * Ractor::Selector is introduced for lightweight waiting - for many ractors. - * Data structure - * remove `struct rb_ractor_waiting_list` and use - `struct rb_ractor_queue takers_queue` to manage takers. - * remove `rb_ractor_t::yield_atexit` and use - `rb_ractor_t::sync::will_basket::type` to check the will. - * add `rb_ractor_basket::p.take` to represent a taking ractor. - * Synchronization protocol - * For the Ractor local GC, `take` can not make a copy object - directly so ask to generate the copy from the yielding ractor. - * The following steps shows what `r1.take` does on `r0`. - * step1: (r0) register `r0` into `r1`'s takers. - * step2: (r0) check `r1`'s status and wakeup r0 if `r1` is waiting - for yielding a value. - * step3: (r0) sleep until `r1` wakes up `r0`. - * The following steps shows what `Ractor.yield(v)` on `r1`. - * step1: (r1) check first takers of `r1` and if there is (`r0`), - make a copy object of `v` and pass it to `r0` and - wakes up `r0`. - * step2: (r1) if there is no taker ractors, sleep until - another ractor try to take. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7371 - -commit 1abec43b5d3290ef2229ceb64014ed91410a6381 - Author: Soutaro Matsumoto <matsumoto@soutaro.com> - AuthorDate: 2023-03-02 12:59:04 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-02 12:59:04 +0900 - - Fix rbs (#7415) - - * Update RBS to skip validation task - * Revert TEST_BUNDLED_GEMS_ALLOW_FAILURES - - Notes: - Merged-By: soutaro <matsumoto@soutaro.com> - -commit d2d521b274f6fb5630b64365c6f1af0dbbc0719f - Author: Ellen Marie Dash <me@duckie.co> - AuthorDate: 2023-03-01 09:29:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-02 09:50:58 +0900 - - [rubygems/rubygems] Regenerate lockfile if spec list is invalid/empty. - - https://github.com/rubygems/rubygems/commit/d2c56315e2 - -commit 35457ebb8f31fd34b89e8214a33e933f69c8021b - Author: Alexander Popov <alex.wayfer@gmail.com> - AuthorDate: 2023-03-02 01:18:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-02 08:42:50 +0900 - - [ruby/uri] Replace RubyDoc.info links with Ruby.GitHub.io - - As requested. - - https://github.com/ruby/uri/commit/c272f205f9 - -commit bc668d75f622a65e32def0672b200e52e87c274a - Author: Alexander Popov <alex.wayfer@gmail.com> - AuthorDate: 2023-02-26 09:40:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-02 08:42:49 +0900 - - [ruby/uri] Take out GitHub link for gemspec metadata - - https://github.com/ruby/uri/commit/ca4638a4b3 - -commit 8a5110b66482098451d4bf31fad414591002fe90 - Author: Alexander Popov <alex.wayfer@gmail.com> - AuthorDate: 2023-02-26 09:38:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-02 08:42:48 +0900 - - [ruby/uri] Populate gemspec metadata object - - https://github.com/ruby/uri/commit/31748915d0 - -commit 93a54a3c30b615a08605b266e0673231c79e19f5 - Author: Alexander Popov <alex.wayfer@gmail.com> - AuthorDate: 2023-02-26 09:37:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-02 08:42:47 +0900 - - [ruby/uri] Sort gemspec `metadata` object alphabetical - - https://github.com/ruby/uri/commit/1e9420b57c - -commit 932c0e77ee8aceeb9f4e42dcc30836466bb06b08 - Author: Alexander Popov <alex.wayfer@gmail.com> - AuthorDate: 2023-02-26 09:36:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-02 08:42:47 +0900 - - [ruby/uri] Remake `metadata` object in `gemspec` into one assignment - - https://github.com/ruby/uri/commit/19a19ccde6 - -commit 57e6d664506c58b8f13ca61a0f8c5fbb3889c253 - Author: Alexander Popov <alex.wayfer@gmail.com> - AuthorDate: 2023-02-26 09:35:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-02 08:42:46 +0900 - - [ruby/uri] Add documentation link into gemspec - - https://github.com/ruby/uri/commit/19ced145f4 - -commit cb8a040b7906c09d9d3ac3d3fe853f633005024f - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-03-02 06:33:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-02 06:33:16 +0900 - - YJIT: Properly deal with cfunc splat when no args needed (#7413) - - Related to: - https://github.com/ruby/ruby/pull/7377 - - Previously it was believed that there was a problem with a combination - of cfuncs + splat + send, but it turns out the same issue happened - without send. For example `Integer.sqrt(1, *[])`. The issue was - happened not because of send, but because of setting the wrong argc - when we don't need to splat any args. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit a80906a7147c6e67e5f6c15c2e414126b019b8d6 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-02 06:06:30 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-03-02 06:07:40 +0900 - - Allow failing rbs failures for now - - will wait until soutaro fixes it. - - The problem of bundled gems is that you can't really revert it as long - as you have scheduled "update bundled_gems". - -commit 27c2572dbdf171ec0b4a107b573feff38399c018 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-03-02 05:09:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-02 05:09:25 +0900 - - YJIT: reject large stacks so we can use i8/u8 stack_size and stack_offset (#7412) - - * Reject large stacks so we can use i8/u8 stack_size and stack_offset - - * Add rejection test for iseq too long as well - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 559dfea7fbaff6793098af1e314878a401d3985c - Author: Soutaro Matsumoto <matsumoto@soutaro.com> - AuthorDate: 2023-03-02 03:02:19 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-02 03:02:19 +0900 - - Test with unreleased RBS (#7411) - - * Use RBS 3.0.1 - - 3.0.2 cannot run test on Ruby CI. Waiting for the next release... - - * Use unreleased version of RBS - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 5e607cfa4ca580f0f4f96cd454a3d01e5d9cee9d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-02 02:15:36 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-02 02:15:36 +0900 - - YJIT: Use a boxed slice for outgoing branches and cme dependencies (#7409) - - YJIT: Use a boxed slice for outgoing branches - - and cme dependencies - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 0d415a322f5dd7158efcbc6c3226266e312620c7 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-03-01 17:07:50 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-03-01 17:18:43 +0900 - - Enable DEBUG_LOG feature on USE_RUBY_DEBUG_LOG - - `ruby_set_debug_option` is needed for `RUBY_DEBUG_LOG` feature - so it should be called when `USE_RUBY_DEBUG_LOG` is true. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7410 - -commit 40e5ee64f08c5a264b95dc2d35d5d3cbcbf858a0 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-28 18:04:53 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-03-01 16:56:56 +0900 - - Implement Write Barrier for `autoload_table_type` - - It's just a decorated st_table, so we call `RB_OBJ_WRITTEN` after - inserting to it. - - We also call `RB_OBJ_WRITTEN` on delete for completeness even though - it's a noop. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7402 - -commit ee83274f36cdbf1ad12c611273de1042a0f24441 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-03-01 16:02:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-01 16:02:27 +0900 - - Update bundled gems list at 2023-03-01 - -commit 47f8bf50e1410223731e2b442ad5a6b9ea1106b5 - Author: Lars Kanis <lars@greiz-reinsdorf.de> - AuthorDate: 2022-03-12 21:06:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-03-01 16:02:11 +0900 - - [DOC] Clarify IO#autoclose impact on #close - - Mention that autoclose changes the behavior of explicit close in addition to implicit close at IO finalization. - - Notes: - Merged: https://github.com/ruby/ruby/pull/5647 - -commit 62b3bcba5ee422d7431f90567636155358234288 - Author: Daniel Colson <danieljamescolson@gmail.com> - AuthorDate: 2023-02-22 06:27:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-03-01 11:50:40 +0900 - - [rubygems/rubygems] Auto-heal on corrupted lockfile with missing deps - - Following up on https://github.com/rubygems/rubygems/pull/6355, which - turned a crash into a nicer error message, this commit auto-heals the - corrupt lockfile instead. - - In this particular case (a corrupt Gemfile.lock with missing - dependencies) the LazySpecification will not have accurate dependency - information, we have to materialize the SpecSet to determine there are - missing dependencies. We've already got a way to handle this, via - `SpecSet#incomplete_specs`, but it wasn't quite working for this case - because we'd get to `@incomplete_specs += lookup[name]` and - `lookup[name]` would be empty for the dependency. - - With this commit we catch it a bit earlier, marking the parent spec - containing the missing dependency as incomplete. - - https://github.com/rubygems/rubygems/commit/486ecb8f20 - -commit c43fbe4ebd2b519601f0b90ca98fa096799d3846 - Author: John Bampton <jbampton@users.noreply.github.com> - AuthorDate: 2023-03-01 03:05:30 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-01 03:05:30 +0900 - - Fix spelling (#7405) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 966adfb79982436e552a7a65b8124b0a579e40c3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-01 03:04:28 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-01 03:04:28 +0900 - - YJIT: Compress BranchGenFn and BranchShape (#7401) - - * YJIT: Compress BranchGenFn and BranchShape - - * YJIT: Derive Debug for Branch - - * YJIT: Capitalize BranchGenFn names - - Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - Co-authored-by: Alan Wu <alansi.xingwu@shopify.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 67ad831b5f6fd7a637adf3a385af3df8d8ad519b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-03-01 03:03:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-03-01 03:03:24 +0900 - - YJIT: Use a boxed slice for gc_obj_offsets (#7397) - - * YJIT: Use a boxed slice for gc_obj_offsets - - * YJIT: Stop using Option - - * YJIT: s/add_counter/incr_counter_by/ - - Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 3766cbce135e14ad9b7ce072e41279c7f1ae4d0f - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-28 19:34:24 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-03-01 02:09:00 +0900 - - Update Rust bindgen - - Notes: - Merged: https://github.com/ruby/ruby/pull/7310 - -commit 5e4b80177ef7e6abbe90849037b688c004568170 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-13 23:51:45 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-03-01 02:09:00 +0900 - - Update the depend files - - Notes: - Merged: https://github.com/ruby/ruby/pull/7310 - -commit 460f399c5a08267beadd5e840b856ae5fac1e56a - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-13 22:28:50 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-03-01 02:09:00 +0900 - - Merge internal/rgengc.h and internal/gc.h - - Notes: - Merged: https://github.com/ruby/ruby/pull/7310 - -commit de66b60f33106892e714198de6e7432c25a602dd - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-02-28 06:38:40 +0900 - Commit: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - CommitDate: 2023-03-01 01:57:41 +0900 - - YJIT: add defer_empty_count stat - - Count how often we defer from a block that is empty - - Notes: - Merged: https://github.com/ruby/ruby/pull/7396 - -commit 9ddd73060bb64ef6da38f77fc032ac852636de99 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-02-28 23:36:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-28 23:36:12 +0900 - - [ruby/irb] Display and prioritise instance methods in `ls - <module/class>` - (https://github.com/ruby/irb/pull/496) - - https://github.com/ruby/irb/commit/e3d21f9329 - -commit 2d6097a0f588527a6b23679fc1503c361c068200 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-27 15:32:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-28 21:54:37 +0900 - - [rubygems/rubygems] Fix method redefinition warning in gem exec specs - - https://github.com/rubygems/rubygems/commit/f177990d4c - -commit cf18f0b868de01666cbef6a117ac1642f4e0aa08 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-27 23:46:44 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-28 17:27:55 +0900 - - Implement Write Barrier for `autoload_data` - - It's not uncommon for libraries to add thing into - autoload that won't necessarily be loaded. - - This can cause hundreds or thousands of entries to be - left over in the autoload table, so it's best not to - mark them on every minor. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7392 - -commit cd1991281e2cfde5b5415612d4cc1c878748513a - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-02-28 16:01:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-28 16:01:59 +0900 - - Update bundled gems list at 2023-02-28 - -commit 9cc0ac22f7c9f37aa7fadfe5606ce2feed260d2d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-28 14:10:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-28 14:29:57 +0900 - - Update lib/net/http/status.rb - -commit 66b89b069d3cc8296696f98a5040106b63b0ab06 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-28 12:37:01 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-28 12:44:13 +0900 - - Also ignore dismissed CodeQL alerts at tests and URI library - -commit 71dae78b89e8c6c78ef47c7ac95b30a09613b261 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-02-03 21:22:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-28 12:07:10 +0900 - - [ruby/stringio] Implement write barrier on StringIO - - It only has a single reference set in 3 places which - makes it fairly easy to implement. - - https://github.com/ruby/stringio/commit/009896b973 - -commit ad679ec9e59c78fb9f6c53625cf14173c3644698 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-28 11:31:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-28 12:05:57 +0900 - - Ignore rb/overly-large-range on URI - - Notes: - Merged: https://github.com/ruby/ruby/pull/7399 - -commit c21260e3ffc46c45ea71be0d5be0c3a11948927c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-28 11:28:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-28 12:05:57 +0900 - - Enable only master branch for CodeQL push trigger - - Notes: - Merged: https://github.com/ruby/ruby/pull/7399 - -commit 9ff09d695cf95e70c5c431421f850a30fe5610f1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-28 11:27:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-28 12:05:57 +0900 - - Run CodeQL each PRs again - - Notes: - Merged: https://github.com/ruby/ruby/pull/7399 - -commit 7a9fb3262cffb76c4a080408e0f2bd1dc8f659ab - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-28 10:44:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-28 11:48:19 +0900 - - Do not upload sarif file as artifact - - Notes: - Merged: https://github.com/ruby/ruby/pull/7398 - -commit fbbe2850192b119dd5c3a822369af7ad78cd4885 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-28 10:30:20 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-28 11:48:19 +0900 - - Do not OSS scorecards check each push - - Notes: - Merged: https://github.com/ruby/ruby/pull/7398 - -commit d2c38aa8231c39d641ab8619d05f2f2883fb5dd8 - Author: lukeg <luke.gru@gmail.com> - AuthorDate: 2023-02-27 04:45:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-28 11:04:32 +0900 - - A file was missing in test/excludes for TestArraySubclass - - Notes: - Merged: https://github.com/ruby/ruby/pull/7385 - -commit 97b53d1a4ad77bbe0402ad1e77901346cc489624 - Author: Sébastien Helleu <flashcode@flashtux.org> - AuthorDate: 2023-01-08 02:19:47 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-02-28 10:27:37 +0900 - - Remove "unused parameter" warnings on include of ruby.h - - These warnings are displayed when compiling with flag "-Wunused-parameter" (or - with "-Wall -Wextra"). - - Notes: - Merged: https://github.com/ruby/ruby/pull/7085 - -commit ba55706fb6b98a01f17909bf5830b66aa68f8fc4 - Author: lukeg <luke.gru@gmail.com> - AuthorDate: 2023-02-27 07:20:52 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-28 06:34:27 +0900 - - fix test/rubygems/test_gem_package_task.rb when in -j mode - - This test skipped sometimes due to failure to load 'rake/packagetask'. - This is due to manipulation of $LOAD_PATH by other rubygems tests. If - rake is loaded before any rubygems tests run, then it works fine. - - To reproduce the skipping behavior: - $ make test-all TESTOPTS="-j6 --test-order=sorted test/rubygems/test_*.rb" - - Notes: - Merged: https://github.com/ruby/ruby/pull/7394 - -commit 283c71eeffc02da6928d7a14f42a0d38d00f592d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-28 05:53:03 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-28 05:53:04 +0900 - - Skip a spec failing on master - - https://github.com/ruby/ruby/actions/runs/4286361460/jobs/7466545010 - http://ci.rvm.jp/results/trunk_gcc9@ruby-sp2-docker/4462424 - http://ci.rvm.jp/results/trunk_clang_13@ruby-sp2-docker/4462422 - -commit 18b4def471bb901d0baa4a1307185484cb05815f - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-02-28 05:02:44 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-02-28 05:02:44 +0900 - - Update to ruby/spec@e7dc804 - -commit de60139053fa7c561858c5c5556d61c82f361dd9 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-02-28 05:02:42 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-02-28 05:02:42 +0900 - - Update to ruby/mspec@dc2eb26 - -commit f38c6552f9f27169fbf4c0f3c25d34b8c2c28c9b - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-17 07:37:59 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-02-28 03:11:56 +0900 - - Remove intern/gc.h from Make deps - - Notes: - Merged: https://github.com/ruby/ruby/pull/7330 - -commit 98e4bdf3e7f60346460cc75858df5f60288e396d - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-17 01:11:36 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-02-28 03:11:56 +0900 - - Update YJIT-bindgen - - Notes: - Merged: https://github.com/ruby/ruby/pull/7330 - -commit ae5e62ee9070057767d7ae7d4494dd9e1c7fc70e - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-16 22:20:03 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-02-28 03:11:56 +0900 - - Merge internal/intern/gc.h into internal/gc.h - - Notes: - Merged: https://github.com/ruby/ruby/pull/7330 - -commit 2f7270c68150d9f49b48c8ff995f4f343d216cee - Author: John Bampton <jbampton@users.noreply.github.com> - AuthorDate: 2023-02-28 02:56:06 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-28 02:56:06 +0900 - - Fix spelling (#7389) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 526111290b2e01e798f436dfe4acc3bf10c6bbd1 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-28 02:24:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-28 02:24:45 +0900 - - Revert "reuse open(2) from rb_file_load_ok on POSIX-like system" - - This reverts commit 35136e1e9c232ad7a03407b992b2e86b6df43f63. - - test-spec has been failing since this revision. - - .github/workflows/compilers.yml:82 - https://github.com/ruby/ruby/actions/runs/4276884159/jobs/7445299562 - - ``` - env: - # Minimal flags to pass the check. - default_cc: 'gcc-11 -fcf-protection -Wa,--generate-missing-build-notes=yes' - optflags: '-O2' - LDFLAGS: '-Wl,-z,now' - # FIXME: Drop skipping options - # https://bugs.ruby-lang.org/issues/18061 - # https://sourceware.org/annobin/annobin.html/Test-pie.html - TEST_ANNOCHECK_OPTS: "--skip-pie --skip-gaps" - ``` - - Failure: - - ``` - 1) - An exception occurred during: Kernel#require (file extensions) does not load a C-extension file if a complex-extensioned .rb file is already loaded - /__w/ruby/ruby/src/spec/ruby/core/kernel/shared/require.rb:317 - Kernel#require (file extensions) does not load a C-extension file if a complex-extensioned .rb file is already loaded ERROR - LeakError: Leaked file descriptor: 8 : #<File:/__w/ruby/ruby/src/spec/ruby/fixtures/code/load_fixture.ext.rb> - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_spec.rb:5:in `<top (required)>' - - 2) - An exception occurred during: Kernel#require ($LOADED_FEATURES) stores an absolute path - /__w/ruby/ruby/src/spec/ruby/core/kernel/shared/require.rb:330 - Kernel#require ($LOADED_FEATURES) stores an absolute path ERROR - LeakError: Closed file descriptor: 8 - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_spec.rb:5:in `<top (required)>' - - 3) - An exception occurred during: Kernel#require ($LOADED_FEATURES) does not load a non-canonical path for a file already loaded - /__w/ruby/ruby/src/spec/ruby/core/kernel/shared/require.rb:535 - Kernel#require ($LOADED_FEATURES) does not load a non-canonical path for a file already loaded ERROR - LeakError: Leaked file descriptor: 8 : #<File:/__w/ruby/ruby/src/spec/ruby/fixtures/code/load_fixture.rb> - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_spec.rb:5:in `<top (required)>' - - 4) - An exception occurred during: Kernel#require ($LOADED_FEATURES) does not load a ../ relative path for a file already loaded - /__w/ruby/ruby/src/spec/ruby/core/kernel/shared/require.rb:551 - Kernel#require ($LOADED_FEATURES) does not load a ../ relative path for a file already loaded ERROR - LeakError: Leaked file descriptor: 9 : #<File:../code/load_fixture.rb> - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_spec.rb:5:in `<top (required)>' - - 5) - An exception occurred during: Kernel#require ($LOADED_FEATURES) complex, enumerator, rational, thread, ruby2_keywords are already required - /__w/ruby/ruby/src/spec/ruby/core/kernel/shared/require.rb:563 - Kernel#require ($LOADED_FEATURES) complex, enumerator, rational, thread, ruby2_keywords are already required ERROR - LeakError: Closed file descriptor: 8 - Closed file descriptor: 9 - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_spec.rb:5:in `<top (required)>' - - 6) - An exception occurred during: Kernel.require (file extensions) does not load a C-extension file if a complex-extensioned .rb file is already loaded - /__w/ruby/ruby/src/spec/ruby/core/kernel/shared/require.rb:317 - Kernel.require (file extensions) does not load a C-extension file if a complex-extensioned .rb file is already loaded ERROR - LeakError: Leaked file descriptor: 8 : #<File:/__w/ruby/ruby/src/spec/ruby/fixtures/code/load_fixture.ext.rb> - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_spec.rb:23:in `<top (required)>' - - 7) - An exception occurred during: Kernel.require ($LOADED_FEATURES) stores an absolute path - /__w/ruby/ruby/src/spec/ruby/core/kernel/shared/require.rb:330 - Kernel.require ($LOADED_FEATURES) stores an absolute path ERROR - LeakError: Closed file descriptor: 8 - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_spec.rb:23:in `<top (required)>' - - 8) - An exception occurred during: Kernel.require ($LOADED_FEATURES) does not load a non-canonical path for a file already loaded - /__w/ruby/ruby/src/spec/ruby/core/kernel/shared/require.rb:535 - Kernel.require ($LOADED_FEATURES) does not load a non-canonical path for a file already loaded ERROR - LeakError: Leaked file descriptor: 8 : #<File:/__w/ruby/ruby/src/spec/ruby/fixtures/code/load_fixture.rb> - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_spec.rb:23:in `<top (required)>' - - 9) - An exception occurred during: Kernel.require ($LOADED_FEATURES) does not load a ../ relative path for a file already loaded - /__w/ruby/ruby/src/spec/ruby/core/kernel/shared/require.rb:551 - Kernel.require ($LOADED_FEATURES) does not load a ../ relative path for a file already loaded ERROR - LeakError: Leaked file descriptor: 9 : #<File:../code/load_fixture.rb> - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_spec.rb:23:in `<top (required)>' - - 10) - An exception occurred during: Kernel.require ($LOADED_FEATURES) complex, enumerator, rational, thread, ruby2_keywords are already required - /__w/ruby/ruby/src/spec/ruby/core/kernel/shared/require.rb:563 - Kernel.require ($LOADED_FEATURES) complex, enumerator, rational, thread, ruby2_keywords are already required ERROR - LeakError: Closed file descriptor: 8 - Closed file descriptor: 9 - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_spec.rb:23:in `<top (required)>' - - 11) - An exception occurred during: Kernel#require_relative with a relative path (file extensions) does not load a C-extension file if a complex-extensioned .rb file is already loaded - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_relative_spec.rb:197 - Kernel#require_relative with a relative path (file extensions) does not load a C-extension file if a complex-extensioned .rb file is already loaded ERROR - LeakError: Leaked file descriptor: 8 : #<File:/__w/ruby/ruby/src/spec/ruby/fixtures/code/load_fixture.ext.rb> - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_relative_spec.rb:4:in `<top (required)>' - - 12) - An exception occurred during: Kernel#require_relative with a relative path ($LOADED_FEATURES) stores an absolute path - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_relative_spec.rb:205 - Kernel#require_relative with a relative path ($LOADED_FEATURES) stores an absolute path ERROR - LeakError: Closed file descriptor: 8 - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_relative_spec.rb:4:in `<top (required)>' - - 13) - An exception occurred during: Kernel#require_relative with an absolute path (file extensions) does not load a C-extension file if a complex-extensioned .rb file is already loaded - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_relative_spec.rb:399 - Kernel#require_relative with an absolute path (file extensions) does not load a C-extension file if a complex-extensioned .rb file is already loaded ERROR - LeakError: Leaked file descriptor: 8 : #<File:/__w/ruby/ruby/src/spec/ruby/fixtures/code/load_fixture.ext.rb> - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_relative_spec.rb:277:in `<top (required)>' - - 14) - An exception occurred during: Kernel#require_relative with an absolute path ($LOAD_FEATURES) stores an absolute path - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_relative_spec.rb:407 - Kernel#require_relative with an absolute path ($LOAD_FEATURES) stores an absolute path ERROR - LeakError: Closed file descriptor: 8 - /__w/ruby/ruby/src/spec/ruby/core/kernel/require_relative_spec.rb:277:in `<top (required)>' - ``` - -commit 0eb634ae73cb327ede833b72492f912792a4a9d5 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-25 07:22:48 +0900 - Commit: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - CommitDate: 2023-02-28 01:12:22 +0900 - - YJIT: Detect and reject `send(:alias_for_send, :foo)` - - Previously, YJIT failed to put the stack into the correct shape when - `BasicObject#send` calls an alias method for the send method itself. - This can manifest as strange `NoMethodError`s in the final non-send - receiver, as [seen][1] with the kt-paperclip gem. I also found a case - where it makes YJIT fail the stack size assertion while compiling - `leave`. - - YJIT's `BasicObject#__send__` implementation already rejects sends to - `send`, but didn't detect sends to aliases of `send`. Adjust the - detection and reject these cases. - - Fixes [Bug #19464] - - [1]: https://github.com/Shopify/yjit/issues/306 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7377 - -commit 55a24f9b08ac2217accb720e29232d56aed2e5a4 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-25 08:42:53 +0900 - Commit: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - CommitDate: 2023-02-28 01:12:22 +0900 - - YJIT: Reject __send__ with splat to cfunc for now - - `make test-spec` revealed this issue after applying an unrelated bug - fix. A crashing case is included, though I suspect there are other - scenarios where it misbehaves. Don't compile for now. - - Note that this is *not* an issue on the 3.2.x series; it has - `send_args_splat_non_iseq` which already rejects all splats to cfuncs, - including sends with splats. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7377 - -commit ea830ab29d856bd0bf7bd4f1edffaff6ba4816ef - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-02-28 00:23:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-28 00:23:31 +0900 - - [ruby/irb] Add a comment about Rails' patch on - Workspace#filter_backtrace - (https://github.com/ruby/irb/pull/526) - - * Add a comment about Rails' patch on Workspace#filter_backtrace - - * Update lib/irb/workspace.rb - - Co-authored-by: Sorah Fukumori <sora134@gmail.com> - - --------- - - https://github.com/ruby/irb/commit/9443d911fc - - Co-authored-by: Sorah Fukumori <sora134@gmail.com> - -commit 0aa50a03b1ea8d37069ae57c469f43860abbcf05 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-02-27 20:07:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-27 20:07:19 +0900 - - [ruby/irb] Provide more useful message when - `IRB::Inspector#inspect_value` errors - (https://github.com/ruby/irb/pull/511) - - **Before** - - ``` - irb(main):001:0> c = Cat.new "foo" - (Object doesn't support #inspect) - => - ``` - - **After** - - ``` - irb(main):001:0> c = Cat.new "foo" - An error occurred when inspecting the object: #<NoMethodError: undefined method `is_a?' for foo:Cat - - if obj.is_a?(String) - ^^^^^^> - Result of Kernel#inspect: #<Cat:0x0000000109090d80 @name="foo"> - => - ``` - -commit 4f611df3f7f61fbdf83b02121dd1edea0b7c68ec - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-02-27 19:21:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-27 19:21:30 +0900 - - [ruby/reline] Fix wrong indent number in prompt. whole_lines has - duplicated line. - (https://github.com/ruby/reline/pull/460) - - * whole_lines should consider prev_line_index, and must not duplicate last_line - - * Add test for lines passed to dynamic prompt proc - - * Refactor whole_lines parameters used in test helper - - * Remove whole_line's arguments - -commit 2cbe1f3ebc15e5adf5ea68b9371a16a2d26724b3 - Author: StepSecurity Bot <bot@stepsecurity.io> - AuthorDate: 2023-02-27 19:06:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-27 19:09:36 +0900 - - [StepSecurity] ci: Harden GitHub Actions - - Signed-off-by: StepSecurity Bot <bot@stepsecurity.io> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7390 - -commit 10a80d9dc44146f910fb01240a818aa5809e6516 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-27 18:12:58 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-27 18:49:18 +0900 - - Ignore test case for Kernel and IO methods - - Notes: - Merged: https://github.com/ruby/ruby/pull/7387 - -commit db0a4c8923e0e084c7d757d132a83fc9c8431633 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-27 16:38:32 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-27 18:49:18 +0900 - - Prefer to use File.foreach instead of IO.foreach - - Notes: - Merged: https://github.com/ruby/ruby/pull/7387 - -commit d063ed12afcb56d919863d6efb4bfa92741c1555 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-27 16:28:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-27 18:49:18 +0900 - - Prefer to use File.binwrite instead of IO.binwrite - - Notes: - Merged: https://github.com/ruby/ruby/pull/7387 - -commit 6dfdc7b28e220dfce4168731e9350af65484832a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-27 16:28:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-27 18:49:18 +0900 - - Prefer to use File.binread instead of IO.binread - - Notes: - Merged: https://github.com/ruby/ruby/pull/7387 - -commit d3d8cd304fb3bc20d519b119628a191575b1642a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-27 15:44:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-27 18:49:18 +0900 - - Prefer to use File.readlines instead of IO.readlines - - Notes: - Merged: https://github.com/ruby/ruby/pull/7387 - -commit ae4d8e99f15733d6c87b9578e5f63a99b2030bb0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-27 17:36:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-27 17:57:58 +0900 - - Rename job and workflow names - - Notes: - Merged: https://github.com/ruby/ruby/pull/7388 - -commit f21f51915ece8b7f2d6d8316917e2188469ed53e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-27 17:34:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-27 17:57:58 +0900 - - Use matrix strategies each language - - Notes: - Merged: https://github.com/ruby/ruby/pull/7388 - -commit b5a1c57c98bd10c59f5993700d792557aa8e0475 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-27 17:13:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-27 17:57:58 +0900 - - Merge codeql-config into codeql-analysis - - Notes: - Merged: https://github.com/ruby/ruby/pull/7388 - -commit 92ed8e6f3f561ea25c411f94d6469497e9cb9204 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-02-27 17:43:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-27 17:44:02 +0900 - - [ruby/reline] Fix the cause of test_yamatanooroti randomly failing - (https://github.com/ruby/reline/pull/474) - - * Add repeated input-delete test that fails on HEAD - - * Use raw mode while readmultiline - -commit 494c274b82d267ace9878202a65fb100cb5f62f7 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-02-27 16:01:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-27 16:01:23 +0900 - - Update bundled gems list at 2023-02-27 - -commit cc8329e8bc487aad825ba1e7948a714d77c2c6ac - Author: Sven Schwyn <sven.schwyn@bitcetera.com> - AuthorDate: 2023-02-22 19:37:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-27 11:29:06 +0900 - - [ruby/tempfile] Fix inconsistency in doc of Tempfile.create - - https://github.com/ruby/tempfile/commit/3f96b2ed29 - -commit b6704201a3ef6a7f07da8d4ca82499710a3eea10 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-02-26 00:06:24 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-02-27 11:20:42 +0900 - - Add all-ruby-quine as a sample code - - This sample code works on all release versions of Ruby, from Ruby 0.49. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7380 - -commit 2535b1819f910f0e12bf609c72e45f7230a060c9 - Author: Adam Daniels <adam@mediadrive.ca> - AuthorDate: 2023-02-27 04:23:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-27 09:26:17 +0900 - - Symbol#end_with? accepts Strings only - - Regular expressions are not supported (same as String#end_with?). - - Notes: - Merged: https://github.com/ruby/ruby/pull/7384 - -commit 35136e1e9c232ad7a03407b992b2e86b6df43f63 - Author: Eric Wong <normal@ruby-lang.org> - AuthorDate: 2023-02-25 03:05:36 +0900 - Commit: Eric Wong <normal@ruby-lang.org> - CommitDate: 2023-02-27 05:39:41 +0900 - - reuse open(2) from rb_file_load_ok on POSIX-like system - - When loading Ruby source files, we can save the result of - successful opens as open(2)/openat(2) are a fairly expensive - syscalls. This also avoids a time-of-check-to-time-of-use - (TOCTTOU) problem. - - This reduces open(2) syscalls during `require'; but should be - most apparent when users have a small $LOAD_PATH. Users with - large $LOAD_PATH will benefit less since there'll be more - open(2) failures due to ENOENT. - - With `strace -c -e openat ruby -e exit' under Linux, this - results in a ~14% reduction of openat(2) syscalls - (glibc uses openat(2) to implement open(2)). - - % time seconds usecs/call calls errors syscall - ------ ----------- ----------- --------- --------- ---------------- - 0.00 0.000000 0 296 110 openat - 0.00 0.000000 0 254 110 openat - - Additionally, the introduction of `struct ruby_file_load_state' - may make future optimizations more apparent. - - This change cannot benefit binary (.so) loading since the - dlopen(3) API requires a filename and I'm not aware of an - alternative that takes a pre-existing FD. In typical - situations, Ruby source files outnumber the mount of .so - files. - -commit 6e6992e5db49a238baf290d9b9b521f6b6be5a19 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-26 22:37:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-26 22:37:15 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for Net::HTTP - (https://github.com/ruby/net-http/pull/127) - - https://github.com/ruby/net-http/commit/07b2b88ef5 - -commit c8bafc3b01c67cee1b0fd6ef8a2842c172f79ab0 - Author: Ben Hamilton <benhamilton@google.com> - AuthorDate: 2023-02-25 02:08:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-26 22:17:24 +0900 - - Fix autoconf RUBY_STACK_GROW_DIRECTION on ARM devices - - Notes: - Merged: https://github.com/ruby/ruby/pull/7373 - -commit 672b81b090fb346b71f1c8e87a51a7c33f239df4 - Author: ima1zumi <52617472+ima1zumi@users.noreply.github.com> - AuthorDate: 2023-02-26 01:50:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-26 01:50:33 +0900 - - [ruby/irb] Remove unused Struct - (https://github.com/ruby/irb/pull/522) - - https://github.com/ruby/irb/commit/97dae166ae - -commit d0031db9b3d7c951ae786f47a6c41de8f3afb2eb - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-02-25 19:04:10 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-25 19:04:10 +0900 - - Prefer RB_NUM2LONG for string length. (#7379) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit d3ee9e590caa2177abd9b1a52b30ff63aaa68c8f - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-02-20 07:27:41 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-25 17:38:19 +0900 - - [ruby/stringio] Remove (newly unneeded) remarks about aliases - - https://github.com/ruby/stringio/commit/60bb320477 - -commit f94e83faa04d99a6deac49b8c0a14c585aeea59a - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-02-25 15:27:11 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-25 15:27:11 +0900 - - Assigning `nil` to fiber storage deletes the association. (#7378) - - Also avoid allocations when looking up `Fiber#storage` if not needed. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 57bc3f2f462df8e945ddfa5f9a8de45c1b0f0a86 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-02-25 14:40:26 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-25 14:40:26 +0900 - - Add `IO::Buffer.string` for efficient string creation. (#7364) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 132934b82baad97107fe754d60f9a68a1db7ecda - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-25 06:18:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-25 06:18:53 +0900 - - YJIT: Generate Block::entry_exit with block entry PC - - Previously, when Block::entry_exit is requested from any instruction - that is not the first one in the block, we generated the exit with an - incorrect PC. We should always be using the PC for the entry of the - block for Block::entry_exit. - - It was a simple typo. The bug was [introduced][1] while we were - refactoring to use the current backend. Later, we had a chance to spot - this issue while [preparing][2] to enable unused variable warnings, but - didn't spot the issue. - - Fixes [Bug #19463] - - [1]: 27fcab995e6dde19deb91dc6e291bdb72100af68 - [2]: 31461c7e0eab4963ccc8649ea8ebf27979132c0c - - Notes: - Merged: https://github.com/ruby/ruby/pull/7374 - - Merged-By: XrXr - -commit 3e098224077e8c43a1d8c2070b26ffdfda422780 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-24 23:20:14 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-25 04:10:09 +0900 - - Fix incorrect line numbers in GC hook - - If the previous instruction is not a leaf instruction, then the PC was - incremented before the instruction was ran (meaning the currently - executing instruction is actually the previous instruction), so we - should not increment the PC otherwise we will calculate the source - line for the next instruction. - - This bug can be reproduced in the following script: - - ``` - require "objspace" - - ObjectSpace.trace_object_allocations_start - a = - - 1.0 / 0.0 - p [ObjectSpace.allocation_sourceline(a), ObjectSpace.allocation_sourcefile(a)] - ``` - - Which outputs: [4, "test.rb"] - - This is incorrect because the object was allocated on line 10 and not - line 4. The behaviour is correct when we use a leaf instruction (e.g. - if we replaced `1.0 / 0.0` with `"hello"`), then the output is: - [10, "test.rb"]. - - [Bug #19456] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7357 - -commit d2631c427ee723f6136ac1e08dd3c9c5b04c6725 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-24 22:48:26 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-25 04:10:09 +0900 - - Fix RubyVM::CExpr#inspect - - @__LINE__ can be nil which causes the inspect method to fail. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7357 - -commit 05f016cdad84481c084543c6fa8b32205c19431f - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-25 04:09:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-25 04:09:06 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for Net::HTTP - (https://github.com/ruby/net-http/pull/126) - - https://github.com/ruby/net-http/commit/4700d0660b - -commit f471f46184c1faffe29e8a5df36407fbd5fbce8d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-24 23:03:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-24 23:03:59 +0900 - - YJIT: Use enum for expressing type diff (#7370) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit d8d152e68105b657d089faae437a34b0ed9e1418 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-24 23:01:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-24 23:01:53 +0900 - - YJIT: Compress TempMapping (#7368) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 07403de5a8a2d5239a15520513efcb3a5041580f - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-02-24 22:34:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-24 22:34:40 +0900 - - [ruby/irb] Cleanup completion tests - (https://github.com/ruby/irb/pull/520) - - * Remove redundant completion test - - The test case was introduced to guard an old implementation, which relied - on `Module#name`. Commit: - - https://github.com/ruby/irb/commit/8827d182746396dbf4499c2c1c8c0e9bf8375b7c - - However, the current implementation has avoided calling `Module#name` - completely, so the test case is no longer necessary. Commit: - - https://github.com/ruby/irb/commit/88311ce3c84251e6f420246cd14efc96e00888be - - * Remove unnecessary pend - -commit 5d5ff6e5eda887b39691db4db58ac1c2c3a1f8d9 - Author: Akinori MUSHA <knu@idaemons.org> - AuthorDate: 2023-02-24 17:37:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-24 20:48:08 +0900 - - [ruby/set] Set#merge does not take keyword arguments as a Hash - - https://github.com/ruby/set/commit/ca1c9532a9 - -commit 454ac4cbb22fdae44a75cef1412693e4fb526630 - Author: Akinori MUSHA <knu@idaemons.org> - AuthorDate: 2023-02-24 15:58:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-24 20:48:07 +0900 - - [ruby/set] Set#merge takes many enumerable objects like Hash#merge! does - - https://github.com/ruby/set/commit/becaca994d - -commit aff41a36693c0274633914afb2cfbdb8169c1cbd - Author: Kaíque Kandy Koga <kaiquekandykoga@gmail.com> - AuthorDate: 2022-06-02 09:19:56 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-24 19:44:36 +0900 - - Add information about runirb in make help - - Notes: - Merged: https://github.com/ruby/ruby/pull/5971 - -commit 1fdaa0666086529b3aae2d509a2e71c4247c3a12 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-24 03:13:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-24 03:13:13 +0900 - - Fix a warning on typedef - - ../gc.c:13317:1: warning: ‘typedef’ is not at beginning of declaration [-Wold-style-declaration] - 13317 | } typedef weakkeymap_entry_t; - | ^ - -commit b9f9440e95ba701ec341ea665a964128ec5c171a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-24 03:07:51 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-24 03:08:26 +0900 - - YJIT: Trivial fixes in codegen.rs - -commit 5444dde7389a557f3fad982b492dcb6c2d3496b7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-24 03:03:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-24 03:03:34 +0900 - - YJIT: Skip type checks on splat args and expandarray if possible (#7363) - - YJIT: Skip type checks on splat args and expandarray - - if possible - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 7c47c2617a091e2a7abaeff329fdef47d1f3f3f5 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-24 01:51:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-24 01:51:58 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for Net::HTTP - (https://github.com/ruby/net-http/pull/125) - - https://github.com/ruby/net-http/commit/2ea20380fc - -commit 2a5354e59324cb296a423c73ec15ff9191086964 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2022-02-18 20:54:42 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-24 00:01:57 +0900 - - Implement ObjectSpace::WeakKeyMap basic allocator - - [Feature #18498] - - Notes: - Merged: https://github.com/ruby/ruby/pull/5570 - -commit 9406245dbcaa324ce9ff0aae0f28b64beacc0836 - Author: Mercedes Bernard <mercedesrbernard@gmail.com> - AuthorDate: 2023-02-17 05:52:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-23 17:50:06 +0900 - - [rubygems/rubygems] lint fix again - - https://github.com/rubygems/rubygems/commit/118d28ad27 - -commit 3d766122c8106fb6fbb0667be3dd0c99d620ef89 - Author: Mercedes Bernard <mercedesrbernard@gmail.com> - AuthorDate: 2023-02-17 05:00:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-23 17:50:05 +0900 - - [rubygems/rubygems] lint fix - - https://github.com/rubygems/rubygems/commit/de3b69f1a7 - -commit 10a393c25dff1d7abe656644674e2fb69a06ea66 - Author: Mercedes Bernard <mercedesrbernard@gmail.com> - AuthorDate: 2023-02-17 04:46:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-23 17:50:05 +0900 - - [rubygems/rubygems] add safe_load_marshal for gem::version and gem::spec - - https://github.com/rubygems/rubygems/commit/2ea2ead1b3 - -commit e965133f56c2c7dca23d4172249aea056e2a449a - Author: Mercedes Bernard <mercedesrbernard@gmail.com> - AuthorDate: 2023-02-17 04:44:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-23 17:50:04 +0900 - - [rubygems/rubygems] test Bundler::Fetcher that error raised when attempting load unexpected class - - https://github.com/rubygems/rubygems/commit/795e796a9e - -commit 68995c21bed067c068e84ffc16181aee1c2f4fc9 - Author: Mercedes Bernard <mercedesrbernard@gmail.com> - AuthorDate: 2023-02-17 04:44:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-23 17:50:04 +0900 - - [rubygems/rubygems] test rubygems_integration that error raised when attempting load unexpected class - - https://github.com/rubygems/rubygems/commit/9798718b3b - -commit ffc202738b02d781fe2cf7542806d11a4eb47035 - Author: Mercedes Bernard <mercedesrbernard@gmail.com> - AuthorDate: 2023-02-17 03:10:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-23 17:50:03 +0900 - - [rubygems/rubygems] add test for private load_marshal method - - https://github.com/rubygems/rubygems/commit/3a772125b8 - -commit 583137fe5697c0d7119a11caa61c343683dc81e5 - Author: Mercedes Bernard <mercedesrbernard@gmail.com> - AuthorDate: 2023-02-16 06:07:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-23 17:50:03 +0900 - - [rubygems/rubygems] make Bundler.load_marshal private - - https://github.com/rubygems/rubygems/commit/4909d071d2 - -commit d5994eb4362d7aba01c36b1b3a1ec3e7462d70d5 - Author: Mercedes Bernard <mercedesrbernard@gmail.com> - AuthorDate: 2023-02-16 04:27:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-23 17:50:02 +0900 - - [rubygems/rubygems] safe marshal gem specs when inflating - - https://github.com/rubygems/rubygems/commit/5c5d0c5350 - -commit 3d5ec8401f9b7736402a091deb10dc124c4540f4 - Author: Mercedes Bernard <mercedesrbernard@gmail.com> - AuthorDate: 2023-02-16 04:07:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-23 17:50:02 +0900 - - [rubygems/rubygems] safe marshal gem versions when fetching Marshal.specs.4.8.gz - - https://github.com/rubygems/rubygems/commit/23880353c1 - -commit 3b567eb491e460e00a66fdea8054eeb083b5dafd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-23 14:40:13 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-23 14:40:13 +0900 - - [Bug #19459] Remove unnecessary always-true checks (#7362) - - `length` is a required argument for `IO::Buffer#read` and - `IO::Buffer#write` methods, and `argc` is already checked with - `rb_check_arity`. Also fix the call-seq of `IO::Buffer#read`. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit da0e6b99c7bae9b1e4644fa8b053d3ed4d67be3f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-22 16:45:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-23 11:25:56 +0900 - - Move `dump_machine_register` definitions - - Notes: - Merged: https://github.com/ruby/ruby/pull/7361 - -commit e9e4e1cb46a1595a83127dd90091bc0951c7d4a9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-23 06:22:41 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-23 06:22:41 +0900 - - YJIT: Introduce Opnd::Stack (#7352) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 29ec8e151bf27c546a4c40d91c039e8d78f8d9c2 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-23 06:07:21 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-23 06:09:05 +0900 - - Make GC faster when RGENGC_CHECK_MODE >= 2 - - We shouldn't run gc_verify_internal_consistency after every GC step - when RGENGC_CHECK_MODE >= 2, only when GC has finished. Running it - on every GC step makes it too slow. - -commit 220cdbeea52c4681fb0ba52d24e5b28a0b877e0f - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-23 04:26:28 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-23 04:26:28 +0900 - - [lldb] Add a print_flags command (#7358) - - Notes: - Merged-By: peterzhu2118 <peter@peterzhu.ca> - -commit 4edb2a29f67957fc7027eaad0c08e8003cfde609 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-22 22:58:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 22:58:36 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for Net:HTTP - (https://github.com/ruby/net-http/pull/124) - - https://github.com/ruby/net-http/commit/aaf26b21d6 - -commit b112ae9971ea63b9f0ba3df049ac4c3bea89bf66 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-22 22:14:26 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-22 22:14:26 +0900 - - Skip failing test on MSWin - -commit 6232e1b9c05fea04450398d1601672af28d3e395 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-22 09:50:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:21 +0900 - - [rubygems/rubygems] Skip extension test on jruby - - https://github.com/rubygems/rubygems/commit/38ee82c297 - -commit 151ae9790fa815950846b2f701772d772907dda7 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-22 09:48:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:20 +0900 - - [rubygems/rubygems] Better teardown - - https://github.com/rubygems/rubygems/commit/5fa0ebf09b - -commit a17b1b19b151c82319c244f3955101a4c9bffc0f - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-22 06:06:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:20 +0900 - - [rubygems/rubygems] Always join with a string - - Gem.path_separator can also be a regexp... - - https://github.com/rubygems/rubygems/commit/7e6e56a5f3 - -commit 0ca3a095be988c6382e92240118384a8028a5c6d - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-21 21:52:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:19 +0900 - - [rubygems/rubygems] Only update env if var exists - - Will save on an error if it would be nil from an exception happening during that line - - https://github.com/rubygems/rubygems/commit/d6797a04e9 - -commit 616a7e1f6c789e5844b4fca9e84fe85656ecc62a - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-15 03:29:16 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:19 +0900 - - [rubygems/rubygems] Nil out Gem.configuration after tests - - https://github.com/rubygems/rubygems/commit/3135ad91d4 - -commit ae5deb1ebc5b9cdd1e137e7b78c89e55348dd2ba - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-15 03:28:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:19 +0900 - - [rubygems/rubygems] Use assert_raise instead of assert_raises - - For ruby-core compat - - https://github.com/rubygems/rubygems/commit/c8f85c91a8 - -commit 931db2120844760a1c1c5c5d6253b558f8034124 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-15 03:11:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:18 +0900 - - [rubygems/rubygems] Add tests covering pre-releases for gem exec - - https://github.com/rubygems/rubygems/commit/f6877c29b9 - -commit 80bfa1b30af7aae60e96f17e86f3a2c5a566ee12 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-14 11:46:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:18 +0900 - - [rubygems/rubygems] Fix resetting env in gem exec, and make sure it is set for gem exec gem - - https://github.com/rubygems/rubygems/commit/13a6dd4992 - -commit 2dd96983505285bf58845d1687a9a6d6c0af959b - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-14 11:39:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:17 +0900 - - [rubygems/rubygems] Allow gem exec gem - - https://github.com/rubygems/rubygems/commit/a767f7b9be - -commit 47d4f73ee755a0ae7b26eb2e35b820202e008763 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-14 10:22:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:17 +0900 - - [rubygems/rubygems] Remove platform option for gem exec - - Also fix native extensions that load dependencies - - https://github.com/rubygems/rubygems/commit/a06f9870c7 - -commit 612ebd10c061fefd6e4f1f736a95188bd6ae5146 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-13 12:19:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:16 +0900 - - [rubygems/rubygems] Ensure dependencies are updated by default when running gem exec - - https://github.com/rubygems/rubygems/commit/664f3e1e5f - -commit 3f0f9a7942a90f4dd6069e6074ea6211fe5d0bc5 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-02-06 15:08:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:16 +0900 - - [rubygems/rubygems] Add gem exec description - - https://github.com/rubygems/rubygems/commit/dac1609fd5 - -commit d81be0609b382dac877137c2d388289aec7d3107 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-01-26 11:49:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:16 +0900 - - [rubygems/rubygems] Add specs for gem exec - - https://github.com/rubygems/rubygems/commit/3078e5834e - -commit cbe14cc8e6ff7da4ec6d2a3ea9de139cb6dcedbf - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-01-26 10:08:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 17:42:15 +0900 - - [rubygems/rubygems] Add gem exec command - - https://github.com/rubygems/rubygems/commit/ca69a317f3 - -commit 693e4dec236e14432df97010082917a3a48745cb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-22 10:57:51 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-22 14:40:13 +0900 - - Prohibit GIT after setting readonly - -commit 65ef20d2a792066542ffdd29298fd4df90e89271 - Author: 小MAO钓鱼 <657757743@qq.com> - AuthorDate: 2023-02-22 13:11:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-22 13:11:33 +0900 - - Add support for LoongArch (#7343) - - * vm_dump.c: Dump machine registers on loongarch64 Linux. - - * coroutines: Support for native loongarch64 coroutines. - - --------- - - Co-authored-by: zangruochen <zangruochen@loongson.cn> - - Notes: - Merged-By: nurse <naruse@airemix.jp> - -commit d025ff29c4f34e7eb1c2f779faa5c6a939b2afe0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-22 10:10:11 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-22 10:23:06 +0900 - - Clone bundled gem sources only if GIT is available - -commit ac5a949c2a973d2f715bc38dd30f8a2539e64c29 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-22 10:05:09 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-22 10:23:05 +0900 - - Refine exception messages when git failed - -commit 015bf5c461bbd2702e426e87bbea202358d5b2ba - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-22 10:20:20 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-22 10:20:20 +0900 - - Removed accidentally commits with ruby/readline-ext - - Partly reverted 1ddda4c0d7d2b83658ab149e36e088961ca0b2dc - -commit fc59b587156e7ab80b6d5c8cd6708041c6da0dc8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-22 10:13:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 10:18:26 +0900 - - [ruby/readline-ext] test_readline.rb only needs EnvUtil - - https://github.com/ruby/readline-ext/commit/9245965ecd - -commit 088919065e7142870650ec2ecbf304e3eab5eb27 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-22 09:58:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 10:18:25 +0900 - - [ruby/readline-ext] Omit some tests with macOS platform - - https://github.com/ruby/readline-ext/commit/efe2be6e4c - -commit 1ddda4c0d7d2b83658ab149e36e088961ca0b2dc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-22 09:44:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 10:18:25 +0900 - - [ruby/readline-ext] Import EnvUtils and related test libraries - - https://github.com/ruby/readline-ext/commit/f034697a48 - -commit ae9e1aee59b0db1e61aa0473556165f9fd719cde - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-02-18 05:04:51 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-02-22 06:59:54 +0900 - - Call rb_ivar_set instead of exiting for many ivars - - Previously, when we have a lot of ivars defined, we would exit via - `jit_chain_guard` for megamorphic ivars. Now if we have more than the - max depth of ivars we can call `rb_ivar_set` instead of exiting. - - Using the following script: - - ```ruby - class A - def initialize - @a = 1 - end - - def a - @a - end - end - - N = 30 - N.times do |i| - eval <<-eorb - class A#{i} < A - def initialize - @a#{i} = 1 - super - end - end - eorb - end - - klasses = N.times.map { Object.const_get(:"A#{_1}") } - - 1000.times do - klasses.each do |k| - k.new.a - end - end - ``` - - Exits before this change show exits for `setinstancevariable`: - - ``` - ***YJIT: Printing YJIT statistics on exit*** - method call exit reasons: - klass_megamorphic: 24,975 (100.0%) - invokeblock exit reasons: - (all relevant counters are zero) - invokesuper exit reasons: - (all relevant counters are zero) - leave exit reasons: - interp_return: 26,948 (100.0%) - se_interrupt: 1 ( 0.0%) - getblockparamproxy exit reasons: - (all relevant counters are zero) - getinstancevariable exit reasons: - megamorphic: 13,986 (100.0%) - setinstancevariable exit reasons: - megamorphic: 19,980 (100.0%) - opt_aref exit reasons: - (all relevant counters are zero) - expandarray exit reasons: - (all relevant counters are zero) - opt_getinlinecache exit reasons: - (all relevant counters are zero) - invalidation reasons: - (all relevant counters are zero) - num_send: 155,823 - num_send_known_class: 0 ( 0.0%) - num_send_polymorphic: 119,880 (76.9%) - bindings_allocations: 0 - bindings_set: 0 - compiled_iseq_count: 36 - compiled_block_count: 158 - compiled_branch_count: 240 - block_next_count: 10 - defer_count: 70 - freed_iseq_count: 0 - invalidation_count: 0 - constant_state_bumps: 0 - inline_code_size: 29,216 - outlined_code_size: 27,948 - freed_code_size: 0 - code_region_size: 65,536 - live_context_size: 8,322 - live_context_count: 219 - live_page_count: 4 - freed_page_count: 0 - code_gc_count: 0 - num_gc_obj_refs: 130 - object_shape_count: 295 - side_exit_count: 58,942 - total_exit_count: 85,890 - yjit_insns_count: 1,023,581 - avg_len_in_yjit: 11.2 - Top-4 most frequent exit ops (100.0% of exits): - opt_send_without_block: 24,975 (42.4%) - setinstancevariable: 19,980 (33.9%) - getinstancevariable: 13,986 (23.7%) - leave: 1 ( 0.0%) - ``` - - Exits after this change show we have no exits for `setinstancevariable`. - - ``` - ***YJIT: Printing YJIT statistics on exit*** - method call exit reasons: - klass_megamorphic: 24,975 (100.0%) - invokeblock exit reasons: - (all relevant counters are zero) - invokesuper exit reasons: - (all relevant counters are zero) - leave exit reasons: - interp_return: 60,912 (100.0%) - se_interrupt: 3 ( 0.0%) - getblockparamproxy exit reasons: - (all relevant counters are zero) - getinstancevariable exit reasons: - (all relevant counters are zero) - setinstancevariable exit reasons: - (all relevant counters are zero) - opt_aref exit reasons: - (all relevant counters are zero) - expandarray exit reasons: - (all relevant counters are zero) - opt_getinlinecache exit reasons: - (all relevant counters are zero) - invalidation reasons: - (all relevant counters are zero) - num_send: 155,823 - num_send_known_class: 0 ( 0.0%) - num_send_polymorphic: 119,880 (76.9%) - bindings_allocations: 0 - bindings_set: 0 - compiled_iseq_count: 36 - compiled_block_count: 179 - compiled_branch_count: 240 - block_next_count: 11 - defer_count: 70 - freed_iseq_count: 0 - invalidation_count: 0 - constant_state_bumps: 0 - inline_code_size: 31,032 - outlined_code_size: 29,708 - freed_code_size: 0 - code_region_size: 65,536 - live_context_size: 8,360 - live_context_count: 220 - live_page_count: 4 - freed_page_count: 0 - code_gc_count: 0 - num_gc_obj_refs: 130 - object_shape_count: 295 - side_exit_count: 24,978 - total_exit_count: 85,890 - yjit_insns_count: 1,076,966 - avg_len_in_yjit: 12.2 - Top-2 most frequent exit ops (100.0% of exits): - opt_send_without_block: 24,975 (100.0%) - leave: 3 ( 0.0%) - ``` - - Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7335 - -commit 9f8056a7dd13168a7d1f81380435a6a2e21c44d3 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-22 06:41:23 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-22 06:41:23 +0900 - - YJIT: Fastpath for Module#=== (#7351) - - Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - Co-authored-by: Jimmy Miller <jimmy.miller@shopify.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 0353277b20efffa748af3ae5926528381ba7ba7c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-22 06:10:10 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-22 06:10:10 +0900 - - YJIT: Avoid checking symbol ID twice on send (#7350) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 50e77b6a9c0ebbb1c5f2a9b075b7afb2fbe19fb4 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-02-22 04:38:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 04:38:09 +0900 - - [ruby/irb] Improve RubyLex's tests - (https://github.com/ruby/irb/pull/484) - - * Improve assert_indenting helper - - Instead of putting assertions inside the `auto_indent` block, we - can just make `auto_indent` return the calculated space count, and use - it for assertion outside of the `auto_indent` block call. - - This simplifies the setup code and makes the intention easier to - understand. - - * Introduce assert_row_indenting helper - - 1. Helper users shouldn't need to write 2 assertions for the current and - the next line's indentation. - 2. With this new approach, we can generate clearer error message for - both cases: - - When the current line's space count doesn't match - - ``` - Incorrect spaces calculation for line: - - ``` - > def each_top_level_statement - ``` - - All lines: - - ``` - def each_top_level_statement - ``` - - <0> expected but was - <nil> - ``` - - When the next line's space count doesn't match - - ``` - Incorrect spaces calculation for line after the current line: - - ``` - def each_top_level_statement - > - ``` - - All lines: - - ``` - def each_top_level_statement - ``` - - <3> expected but was - <2> - ``` - - * Replace assert_indenting with assert_row_indenting - -commit 5baef075067cff551c8b3b00c86714b8c98acc65 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-02-22 03:21:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-22 03:21:25 +0900 - - YJIT: Fix clippy issues and remove unused params (#7348) - - * YJIT: Fix clippy issues and remove unused params - - * Remove an unnecessary whitespace - - --------- - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit d579f47558eaa27a989c94996bf71b6cc1047ff2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-22 03:00:39 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-22 03:00:39 +0900 - - Bump SHAPE_MAX_NUM_IVS to 80 (#7344) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 37b6d988404a280da4a5d7f9f181d0565f7e91fc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-21 23:24:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-22 02:07:59 +0900 - - Use `Gem::Package#build` instead of the class method for old baseruby - - Notes: - Merged: https://github.com/ruby/ruby/pull/7347 - -commit 289080e4d86c70f8231a74a78892b2db65a86e9a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-21 20:30:08 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-22 02:07:59 +0900 - - Clone and create dummy gemspec in sequential build - - Notes: - Merged: https://github.com/ruby/ruby/pull/7347 - -commit 241c4cfdd47c3f5df0738bb636d3f3954101de49 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-21 18:17:02 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-22 02:07:59 +0900 - - Move dummy gemspec file creation for extract-gems-sequential - - Notes: - Merged: https://github.com/ruby/ruby/pull/7347 - -commit 0a9efe8701c43f80ad8b23d89d6b34d13d9d9ade - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-21 17:09:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-22 02:07:59 +0900 - - Use git directories instead of gemspec files as dependency - - Minitest repository does not commit its gemspec file. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7347 - -commit 3c01342e19b31e21030deff5705b9427dca691ae - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-17 08:11:07 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-22 00:57:28 +0900 - - Fix detection of compiler_wd in tool/update-deps - - Notes: - Merged: https://github.com/ruby/ruby/pull/7331 - -commit a26a0af074a1f81223bb80b2f41c1b2c10ed7300 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-22 00:37:18 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-22 00:39:56 +0900 - - Use `BigDecimal::VERSION` instead of `RUBY_VERSION` - -commit 0cde887eb9fd47b9857c9e4a7fbafc581fe51f60 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-21 22:36:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-22 00:35:40 +0900 - - [ruby/bigdecimal] Bump up to 3.1.4 - - ruby/bigdecimal#187 has changed a behavior and ruby/spec also needed a - follow up at https://github.com/ruby/ruby/commit/0d8ef62fc293. - However, because bigdecimal is a separate gem and can be updated in - older versions of ruby, `RUBY_VERSION` is not appropriate for this - guard. That means it needs bumped up `BigDecimal::VERSION`. - - https://github.com/ruby/bigdecimal/commit/3a2a7a9353 - -commit 7b768e43354391098929adf97a593fae79d5fc2e - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-02-21 22:16:45 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-21 23:24:13 +0900 - - [ruby/bigdecimal] Move RB_GC_GUARD() at the end, like in BigMath_s_exp() - - https://github.com/ruby/bigdecimal/commit/b66ef9fbb5 - -commit 5077cc2be68a29339748b50b2346285f545392ea - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-02-21 22:12:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-21 23:24:12 +0900 - - [ruby/bigdecimal] Avoid RB_GC_GUARD(a) = b in bigdecimal - - * This is not supported on TruffleRuby, which requires the value to be - set before RB_GC_GUARD() is called. - * See https://github.com/oracle/truffleruby/pull/2879 - - https://github.com/ruby/bigdecimal/commit/7b2957922f - -commit 93ac7405b80cc61930d73da04441fa09af1851e1 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-15 05:55:25 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-21 22:05:31 +0900 - - Add marking and sweeping time to GC.stat - - There is a `time` key in GC.stat that gives us the total time spent in - GC. However, we don't know what proportion of the time is spent between - marking and sweeping. This makes it difficult to tune the GC as we're - not sure where to focus our efforts on. - - This PR adds keys `marking_time` and `sweeping_time` to GC.stat for the - time spent marking and sweeping, in milliseconds. - - [Feature #19437] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7304 - -commit d7c1ca48bf7754a23bfe1559422736029b4787a0 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-15 05:50:45 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-21 22:05:31 +0900 - - Refactor to separate marking and sweeping phases - - This commit separates the marking and sweeping phases so that marking - functions do not directly call sweeping functions. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7304 - -commit d2520b7b76759118071a16e6bca22726a5de9fb4 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-16 20:18:27 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-21 21:57:04 +0900 - - Marshal.load: restore instance variables on Regexp - - [Bug #19439] - - The instance variables were restore on the Regexp source, - not the regexp itself. - - Unfortunately we have a bit of a chicken and egg problem. - - The source holds the encoding, and the encoding need to be set on - the source to be able to instantiate the Regexp. - - So the instance variables have to be read on the `source`. - To correct this we transfert the instance variables after - instantiating the Regexp. - - The only way to avoid this would be to read the instance variable - twice and rewind. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7323 - -commit b572f2436c70bef75126fe4e30910af75056f5f0 - Author: Charles Oliver Nutter <headius@headius.com> - AuthorDate: 2023-02-09 01:02:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:50:49 +0900 - - [ruby/openssl] Stub gemspec for JRuby - - JRuby has its own implementation of the `openssl` library in - jruby-openssl. The simplest way for us to allow users to set - openssl as a gem dependency is to ship a stub gem that just - depends on jruby-openssl. This patch adds that to the gemspec. - Additional work may be required to fit this stub gem into the test - and release process. - - See #20 for more details. - - https://github.com/ruby/openssl/commit/74ccaa5e18 - -commit bc101f0fc1772e85ee074fe78a6b672dc5f175c5 - Author: Étienne Barrié <etienne.barrie@gmail.com> - AuthorDate: 2023-02-07 21:29:31 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:32:14 +0900 - - [ruby/rdoc] Fix RDoc::Parser::Ruby not being documented - - The calls to require prevent the class from being documented. - - https://github.com/ruby/rdoc/commit/76283fc42e - -commit 4c7726516c2b3b54cd0a78a214f005881fc68aba - Author: Charles Oliver Nutter <headius@headius.com> - AuthorDate: 2023-02-09 22:47:59 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:31:39 +0900 - - [ruby/strscan] Mask out this test on JRuby/Windows - - See https://github.com/jruby/jruby/issues/7644 for the root issue, - which will require fixes to JRuby's regular expression engine, - JOni. - - https://github.com/ruby/strscan/commit/29a65abff2 - -commit 76a4cdfb0253532a9bfe08d39c07f783ded71e20 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-02-09 07:51:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:31:38 +0900 - - [ruby/strscan] test: Run test more with fixed anchor mode - (https://github.com/ruby/strscan/pull/60) - - fix https://github.com/ruby/strscan/pull/56 - -commit 260bc7cdfa8e7b718f24977e18f15a98d795acb0 - Author: OKURA Masafumi <masafumi.o1988@gmail.com> - AuthorDate: 2023-02-09 05:46:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:31:38 +0900 - - [ruby/strscan] Add test case to `test_string` - (https://github.com/ruby/strscan/pull/58) - - `string` returns the original string after `scan` is called. Current - test doesn't check this behavior and now it's covered. - -commit 18e840ac6084715e1ccd4c84153d213583279691 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-02-08 09:33:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:31:36 +0900 - - [ruby/strscan] Bump version - - https://github.com/ruby/strscan/commit/681cde0f27 - -commit a44f5ab089ca208cdd96fc2c7597f1c17b27c235 - Author: OKURA Masafumi <masafumi.o1988@gmail.com> - AuthorDate: 2023-01-30 12:07:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:31:35 +0900 - - [ruby/strscan] Mention return value of `rest?` in the doc - (https://github.com/ruby/strscan/pull/49) - - The doc of `rest?` was unclear about return value. This commit adds the - return value to the doc. - -commit a350ef9f7a27b1338137f9753fe1517d9d0ea3b3 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2023-02-12 14:39:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:31:29 +0900 - - [ruby/csv] test: use mailing list ID instead of unavailable URL - - https://github.com/ruby/csv/commit/04862ccf87 - -commit 2ac1efc0f32e9d5dfb3b606ce0b0bcc83a355aa0 - Author: Vivek Bharath Akupatni <apatniv@gmail.com> - AuthorDate: 2023-02-12 14:35:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:31:29 +0900 - - [ruby/csv] Use https links instead of http - (https://github.com/ruby/csv/pull/274) - - https://github.com/ruby/csv/commit/e2a06929a8 - -commit 1a05d988d391d744d49c0143b90e46397ab29765 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2023-01-28 05:48:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:31:28 +0900 - - [ruby/csv] Remove unused @double_quote_character from Parser - (https://github.com/ruby/csv/pull/273) - - https://github.com/ruby/csv/commit/e5622c53ae - -commit 38fa8eb4cbdc3c470a1ff5521a5ee6932356c6b1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-21 18:53:57 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:28:12 +0900 - - Merge rubygems/bundler master - - Pick from https://github.com/rubygems/rubygems/commit/e9304aed7e43308b99e70c2f7b92028315fee8a5 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7345 - -commit a47e1328e662b5c095b560b842687ed1901fd7b1 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-02-16 05:25:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:28:12 +0900 - - [rubygems/rubygems] Give a better message when Gemfile branch does not exist - - https://github.com/rubygems/rubygems/commit/cb4fc41cbc - - Notes: - Merged: https://github.com/ruby/ruby/pull/7345 - -commit b5eb9ebd5d4eef4ef2c1a4d32b70c17807b834bb - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-02-10 06:11:58 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:28:12 +0900 - - [rubygems/rubygems] Fix crash in pub grub involving empty ranges - - https://github.com/rubygems/rubygems/commit/0f168516f7 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7345 - -commit 4064e3e7769d7cac03f817ede1c4a7d0f97b1ae0 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-02-08 10:55:46 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:28:12 +0900 - - [rubygems/rubygems] Update pub_grub - - * Replaces the wording of "is forbidden" with "cannot be used" - * Fixes the method signature of VersionRange::Empty#eql? - - https://github.com/rubygems/rubygems/commit/8c6b3f130b - - Co-authored-by: Daniel Colson <danieljamescolson@gmail.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7345 - -commit 80389915838fe235b5691391ba00e2733e31d93b - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-02-09 23:24:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:28:12 +0900 - - [rubygems/rubygems] Sync with pub_grub main branch - - We became a bit out of sync lately. - - https://github.com/rubygems/rubygems/commit/6161a2610a - - Notes: - Merged: https://github.com/ruby/ruby/pull/7345 - -commit e7bf85961d43e5679946abd3cd0de59278582309 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-02-09 05:03:35 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-21 19:28:12 +0900 - - [rubygems/rubygems] Restore better error message when locked ref does not exist - - https://github.com/rubygems/rubygems/commit/c8e024359f - - Notes: - Merged: https://github.com/ruby/ruby/pull/7345 - -commit 9b6d421ff44c7ca2810ccb1ed7f1d968c9afc395 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-19 18:36:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-21 19:26:53 +0900 - - [rubygems/rubygems] [DOC] Update the link to OpenSource.org - - The static list in alphabetical order seems no longer provided. - - https://github.com/rubygems/rubygems/commit/a37dff7736 - -commit d13879f862a98e718ba7ec40e8d43137efb97a8b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-19 18:45:06 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-21 18:50:02 +0900 - - [ruby/bigdecimal] Read version from bigdecimal.c - - The dependency of extconf.h on bigdecimal.gemspec does not make sense - as far as no rule is defined for it. Also, the relationship between - extension library and gemspec file is various in default gems, and - does not work well. - - https://github.com/ruby/bigdecimal/commit/7f99b28552 - -commit cb40432c74b9c5f785e8be53cbda981a64d47c72 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-21 18:40:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-21 18:40:03 +0900 - - Use `ERROR_ARGS_AT` - -commit 6384f7981c1d7cebc5a30640145fc07cce673f8d - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-02-21 13:46:11 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-02-21 13:46:11 +0900 - - Prevent "warning: ambiguity between regexp and two divisions" - - http://rubyci.s3.amazonaws.com/ubuntu/ruby-master/log/20230221T031004Z.log.html.gz - ``` - /home/chkbuild/chkbuild/tmp/build/20230221T031004Z/ruby/test/rubygems/test_gem_ext_cargo_builder.rb:90: warning: ambiguity between regexp and two divisions: wrap regexp in parentheses or add a space after `/' operator - ``` - -commit 899fad907c32b533bb73206d5e19204e526621ba - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-21 06:57:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-21 06:57:16 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for Net::HTTP - (https://github.com/ruby/net-http/pull/123) - - https://github.com/ruby/net-http/commit/220ff3f741 - -commit 0459eaec95a4daf2c019683785e6fca30eae15c2 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-21 01:38:00 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-21 03:04:04 +0900 - - compile.c: eliminate getinstancevariable -> pop sequences - - This case wasn't eliminated before because `getinstancevariable` - could emit a warning, but that's no longer the case since Ruby - 3.0. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7342 - -commit ecd0cdaf820af789f355f1a18c31d6adfe8aad94 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-21 02:06:09 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-21 02:06:09 +0900 - - YJIT: Fix assertion for partially mapped last pages (#7337) - - Follows up [Bug #19400] - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 7d5794bad56c0af15646ecfc12c2dc1a8b8c45d9 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-01-30 18:07:47 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-02-20 10:33:06 +0900 - - error.c: Use "undefined local variable or method `...' for main" - - ... for the toplevel. - - Notes: - Merged: https://github.com/ruby/ruby/pull/6950 - -commit 0e830e6373b334a806dddb57c13f233674bd0054 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-01-24 17:44:14 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-02-20 10:33:06 +0900 - - Update some ruby specs for the new message format of NoMethodError - - Notes: - Merged: https://github.com/ruby/ruby/pull/6950 - -commit 8f868a1a65383359e565ed0c874e0d2cba95b0ee - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-01-24 17:44:00 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-02-20 10:33:06 +0900 - - Update some tests for the new message format of NoMethodError - - Notes: - Merged: https://github.com/ruby/ruby/pull/6950 - -commit 1fd181b453a6a2dd16897473afa2f402c7dba8aa - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-01-24 17:40:57 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-02-20 10:33:06 +0900 - - error.c: Update the message format for NoMethodError - - * If the receiver is a Class, use "... for class <class name>". - * If the receiver is a Module, use "... for module <module name>". - * If the receiver is an extended object (i.e., has a singleton class), - use "... for <rb_any_to_s(receiver)>". - * Otherwise, use "... for an instance of <class name>". - - Examples: - - ``` - 42.time #=> undefined method `time' for an instance of Integer (NoMethodError) - - class Foo - privatee #=> undefined local variable or method 'privatee' for class Foo (NoMethodError) - end - - def (o=Object.new).foo - end - o.bar #=> undefined method `bar' for #<Object: 0xdeadbeef(any_to_s)> (NoMethodError) - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/6950 - -commit e7b8d32e166815f2e7edebf32aa178915d191b8c - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2022-12-16 07:31:27 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-02-20 10:33:06 +0900 - - Stop using receiver#inspect for "undefined method" errors - - ``` - 42.time #=> undefined method `time' for object Integer (NoMethodError) - - class Foo - privatee #=> undefined local variable or method 'privatee' for class Foo (NoMethodError) - end - - s = "" - def s.foo = nil - s.bar #=> undefined method `bar' for extended object String (NoMethodError) - ``` - - [Feature #18285] - - Notes: - Merged: https://github.com/ruby/ruby/pull/6950 - -commit 5c0298bf181921a8aa63cd250d67b294cfe90322 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-20 08:07:17 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-20 08:07:33 +0900 - - [ruby/pstore] Remove (newly unneeded) remarks about aliases - (https://github.com/ruby/pstore/pull/8) - - https://github.com/ruby/pstore/commit/01c4ccc7aa - -commit 5fb64f52302cf31fdee0723eddca2155437e37bd - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-20 07:50:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-20 07:50:41 +0900 - - [ruby/fileutils] Remove (newly unneeded) remarks about aliases - (https://github.com/ruby/fileutils/pull/108) - - https://github.com/ruby/fileutils/commit/bbe595cfa5 - -commit 924ab1b7fd0e38706eb1f92170788e3ed6c42217 - Author: Eric Wong <normal@ruby-lang.org> - AuthorDate: 2023-02-20 07:35:52 +0900 - Commit: Eric Wong <normal@ruby-lang.org> - CommitDate: 2023-02-20 07:39:28 +0900 - - test/readline/test_readline.rb: skip a test x86_64-linux-(x32|i[3-6]86) - - I run a 32-bit (x86) userspace on a 64-bit kernel to save memory - and this test fails for the same reason it does on pure 32-bit - platforms. - - Followup-to: 6cf7c0a48fb07a76 (test/readline/test_readline.rb: skip a test on i686-linux, 2021-11-09) - -commit 3b239d2480123046a59a75f1089ab58d192b9c57 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-02-20 05:16:04 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-02-20 07:26:34 +0900 - - Remove (newly unneeded) remarks about aliases - -commit 3d53827130e9f3792e80e9a947d5a0d604aa836b - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-20 07:24:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-20 07:24:39 +0900 - - [ruby/date] Removed (newly unneeded) alias remarks - (https://github.com/ruby/date/pull/88) - - https://github.com/ruby/date/commit/cfa7e9868b - -commit 976cc3852b00560e48fe89b9c5ab77761e1d8f3b - Author: zverok <zverok.offline@gmail.com> - AuthorDate: 2023-02-18 21:37:16 +0900 - Commit: Victor Shepelev <zverok.offline@gmail.com> - CommitDate: 2023-02-20 05:32:52 +0900 - - [DOC] Return *args to Enumerable method definitions - - Notes: - Merged: https://github.com/ruby/ruby/pull/7316 - -commit ce0f3de032ea0dffbfd20dfbfe33453f65ec5a7c - Author: zverok <zverok.offline@gmail.com> - AuthorDate: 2023-02-16 05:42:22 +0900 - Commit: Victor Shepelev <zverok.offline@gmail.com> - CommitDate: 2023-02-20 05:32:52 +0900 - - [DOC] Update pattern matching docs for 3.2 - - * Remove section about experimental status - * Add references to core objects that can deconstruct - - Notes: - Merged: https://github.com/ruby/ruby/pull/7316 - -commit 4f049e915d08697ee9fea5d2c885285d309a7654 - Author: zverok <zverok.offline@gmail.com> - AuthorDate: 2023-02-16 05:16:43 +0900 - Commit: Victor Shepelev <zverok.offline@gmail.com> - CommitDate: 2023-02-20 05:32:52 +0900 - - [DOC] Document IO::Timeout - - Notes: - Merged: https://github.com/ruby/ruby/pull/7316 - -commit e1b447a32304495e1379d154758130a8be530bfb - Author: zverok <zverok.offline@gmail.com> - AuthorDate: 2023-02-16 05:07:21 +0900 - Commit: Victor Shepelev <zverok.offline@gmail.com> - CommitDate: 2023-02-20 05:32:52 +0900 - - [DOC] Improve ObjectSpace#dump_XXX method docs - - * remove false call-seq (output from Ruby parsing is cleaner) - * explain output: argument in plain words - * change parameter name in docs of #dump_shapes (typo) - - Notes: - Merged: https://github.com/ruby/ruby/pull/7316 - -commit 0258e92e432fad42a73982835f1f3b1f2f4f0a51 - Author: zverok <zverok.offline@gmail.com> - AuthorDate: 2023-02-16 04:52:59 +0900 - Commit: Victor Shepelev <zverok.offline@gmail.com> - CommitDate: 2023-02-20 05:32:52 +0900 - - [DOC] Improve Kernel#binding docs - - * Add links to Binding class - * Make examples practical - * Extend possible usages description - - Notes: - Merged: https://github.com/ruby/ruby/pull/7316 - -commit 51bb5b23d499b02b670c9764fd1d51ef02d01c0a - Author: zverok <zverok.offline@gmail.com> - AuthorDate: 2023-02-16 04:38:23 +0900 - Commit: Victor Shepelev <zverok.offline@gmail.com> - CommitDate: 2023-02-20 05:32:52 +0900 - - [DOC] Small adjustment for String method docs - - * Hide freeze method (no useful docs, same as Object#freeze) - * Add dedup to call-seq of str_uminus - - Notes: - Merged: https://github.com/ruby/ruby/pull/7316 - -commit 0c0b9191ce96413258e8124bb4661ddae60cdf7a - Author: zverok <zverok.offline@gmail.com> - AuthorDate: 2023-02-16 04:30:58 +0900 - Commit: Victor Shepelev <zverok.offline@gmail.com> - CommitDate: 2023-02-20 05:32:52 +0900 - - [DOC] Update TracePoint#binding docs for 3.2 behavior - - Notes: - Merged: https://github.com/ruby/ruby/pull/7316 - -commit 01509f344a9ebc2f10950f261581c23395d0ab7c - Author: zverok <zverok.offline@gmail.com> - AuthorDate: 2023-02-16 04:28:06 +0900 - Commit: Victor Shepelev <zverok.offline@gmail.com> - CommitDate: 2023-02-20 05:32:52 +0900 - - [DOC] Restore Process module doc lost due to RDoc update - - Notes: - Merged: https://github.com/ruby/ruby/pull/7316 - -commit 59f7bf96d6d7655e94025f662ef995a90056949f - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-02-20 04:58:00 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-02-20 04:58:00 +0900 - - Mention when it is appropriate to document aliases in call-seq - -commit ea50765926b480122baa8b72e67fee144e072066 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-20 04:41:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-20 04:41:32 +0900 - - [DOC] Change to handling of aliases (#7340) - - Change to handling of aliases - - Notes: - Merged-By: BurdetteLamar <BurdetteLamar@Yahoo.com> - -commit 759d23584e8f0110e55c8c47db662b733e72e219 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-02-17 12:50:48 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-02-19 21:06:13 +0900 - - Create a dummy minitest.gemspec for a bundled gem - - To use the repository version of bundled gems, we need to build a gem by - "gem build", but the repository of minitest does not include - minitest.gemspec because it uses hoe. - - This change creats a dummy minitest.gemspec to pass the CI. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7339 - -commit 8eaa346620c1699ee1c80e4e48c9689b019f334d - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-02-17 12:30:06 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-02-19 21:06:13 +0900 - - No validation for bundled gems - - https://github.com/mame/ruby/actions/runs/4208869556/jobs/7305356097 - ``` - WARNING: open-ended dependency on irb (>= 1.5.0) is not recommended - if irb is semantically versioned, use: - add_runtime_dependency 'irb', '~> 1.5', '>= 1.5.0' - WARNING: open-ended dependency on reline (>= 0.3.1) is not recommended - if reline is semantically versioned, use: - add_runtime_dependency 'reline', '~> 0.3', '>= 0.3.1' - WARNING: See http://guides.rubygems.org/specification-reference/ for help - /usr/lib/ruby/2.7.0/rubygems/specification_policy.rb:418:in `error': specification has warnings (Gem::InvalidSpecificationException) - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7339 - -commit 8a59f75de7e1ee4c021a1cd79aa78f0c6cf78507 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-02-10 15:42:59 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-02-19 21:06:13 +0900 - - Use the development versions of minitest and debug gems - - This is a preparation for a new message format of NameError. - [Feature #18285] - - https://github.com/minitest/minitest/pull/942 - https://github.com/ruby/debug/pull/889 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7339 - -commit 29f88b9feadee1417010dc6cd4f8e49c8c19720a - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-02-18 20:16:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-19 19:29:56 +0900 - - [ruby/error_highlight] Support the new message format of NameError in Ruby 3.3 - - https://bugs.ruby-lang.org/issues/18285 - https://github.com/ruby/ruby/pull/6950 - - https://github.com/ruby/error_highlight/commit/a7c2da052e - -commit 4dc2cb3c1a6d1ee2456cdb0c78d6189b5686f013 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-02-19 16:10:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-19 16:10:47 +0900 - - [ruby/did_you_mean] Support the new message format of NameError in - Ruby 3.3 - (https://github.com/ruby/did_you_mean/pull/184) - - This change accepts the following change of the message of NameError in - a test. - - https://bugs.ruby-lang.org/issues/18285#note-37 - - ``` - old: undefined method `sizee' for #<File:...> - new: undefined method `sizee' for an instance of File - ``` - -commit cbac0fa4cb43c8ec35683e3ae848d5fb8143c757 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-02-18 20:34:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-18 20:34:28 +0900 - - [ruby/irb] Remove unused context argument from Worksapce#evaluate - (https://github.com/ruby/irb/pull/488) - - The context argument was introduced in this change: - - https://github.com/ruby/irb/commit/6806669d178f90f38b99c144bdfee06bdb93a229#diff-296327851fb7a2c307c2d0693b769f58c01aaf315972f290500d10081ee200a9 - - perhaps for potential usages. But after that it's never used. - -commit de7eb5e79ae9ff6425c51eb74d0e9c3f33f9edfe - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-18 14:49:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-18 14:49:21 +0900 - - clean_env of Bundler is deprecated. It's unbundled_env now - -commit c024cc05efa2b5206c4bb45066d3c8e19af7e0d9 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-02-18 06:40:01 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-18 06:40:01 +0900 - - YJIT: Consolidate jit methods in JITState impl (#7336) - - These jit_* methods don't jit code, but instead check things on the - JITState. We had other methods that did the same thing that were just - added on the impl JITState. For consistency I added these methods there. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 034d5ee43c426c8a767fbdc12a9f0fc0ce9af030 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-18 05:44:39 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-18 05:44:39 +0900 - - YJIT: Use rb_ivar_get at the end of ivar chains (#7334) - - * YJIT: Use rb_ivar_get at the end of ivar chains - - * Rename the counter to get_ivar_max_depth - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 0d8ef62fc293dc04110f36382a7e8bddec6aee15 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-18 03:53:07 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-18 03:53:08 +0900 - - BigDecimal changed #remainder's spec - - This test is no longer passing: - ``` - 1) - BigDecimal#remainder returns NaN if Infinity is involved FAILED - Expected Infinity.nan? - to be truthy but was false - /home/runner/work/ruby/ruby/src/spec/ruby/library/bigdecimal/remainder_spec.rb:58:in `block (2 levels) in <top (required)>' - /home/runner/work/ruby/ruby/src/spec/ruby/library/bigdecimal/remainder_spec.rb:4:in `<top (required)>' - ``` - - https://github.com/ruby/bigdecimal/pull/243 - -commit c3bae033eb9f2bb199dede052516ec923bcf10cc - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-02-18 03:10:16 +0900 - Commit: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - CommitDate: 2023-02-18 03:10:16 +0900 - - Add asm comment to YJIT's rb_str_empty_p - -commit becec0001c8eff1b763bed804e48a9ab71289fdd - Author: Charles Oliver Nutter <headius@headius.com> - AuthorDate: 2023-02-09 05:01:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-18 02:52:48 +0900 - - [ruby/bigdecimal] Stub out extension build on JRuby - - JRuby currently ships its own internal bigdecimal extension as - part of the core libraries. In order for users to be able to add - bigdecimal to their Gemfile or gem dependencies, we need to stub - out the C extension and just load the extension shipped with - JRuby. - - In the future we will try to move our BigDecimal implementation - into the gem, but for now this is the simplest way to make it - installable on JRuby. - - See #169 - - https://github.com/ruby/bigdecimal/commit/829956c643 - -commit 36e3d46d35b6a904533e58809369054b135c33d7 - Author: Maciej Rzasa <maciejrzasa@gmail.com> - AuthorDate: 2022-12-01 06:38:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-18 02:46:27 +0900 - - [ruby/bigdecimal] Handle correctly #remainder with infinity. Fixes - https://github.com/ruby/bigdecimal/pull/187 - - https://github.com/ruby/bigdecimal/commit/4b8572d452 - -commit 81dc3a1780319f4bc232af407edea60a35d251ed - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-15 04:40:05 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-17 23:49:45 +0900 - - Remove USE_RGENGC_LOGGING_WB_UNPROTECT - - This macro is broken when set to anything other than 0. And has had a - comment saying that it's broken for 3 years. - - This commit deletes it and the associated logging code. It's clearly - not being used. - - Co-Authored-By: Peter Zhu <peter@peterzhu.ca> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7312 - -commit dd28c55a7cd6780dad637b4d6a20507fbfc6af4a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-17 10:57:22 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-17 10:57:22 +0900 - - [Bug #19445] Fix keyword splat in enumerator - - Extracted arguments do not have keyword hash to splat. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7325 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit a4b7ec12298c78392797e5ba7704076550e4f100 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-17 07:41:52 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-02-17 08:50:42 +0900 - - YJIT: Fix false assumption that String#+@ => ::String - - Could return a subclass. - - [Bug #19444] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7328 - -commit c178926fbe879045fa711444a1fd9e906af23e3b - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-17 07:22:44 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-02-17 08:50:42 +0900 - - YJIT: jit_prepare_routine_call() for String#+@ missing - - We saw SEGVs due to this when running with StackProf, which needs a - correct PC for RUBY_INTERNAL_EVENT_NEWOBJ, the same event used for - ObjectSpace allocation tracing. - - [Bug #19444] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7328 - -commit a49bc73e1f33e8a0e40ff0c3fef6c6fe749f8179 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-17 06:52:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-17 06:52:10 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for Net::HTTP - (https://github.com/ruby/net-http/pull/122) - - https://github.com/ruby/net-http/commit/06f79cda87 - -commit 21f9c92c7144e3b1387aaecfba4fa2beba2d1d70 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-17 04:32:13 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-17 04:32:13 +0900 - - YJIT: Show Context stats on exit (#7327) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 8f22dc39f38f32bc3cde198c2b476899f6460c9c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-17 01:29:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-17 01:29:45 +0900 - - YJIT: Refactor getlocal and setlocal insns (#7320) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit b4c38f3c5960eb5f6376006e1a569b937a896a8c - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-02-17 01:25:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-17 01:25:48 +0900 - - YJIT: Initial support for rest args (#7311) - - * YJIT: Initial support for rest args - - * Update yjit/src/codegen.rs - - --------- - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 21543ac86ce0b730c1381588d7dc9eb0e32277c7 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-16 22:15:54 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-16 22:15:54 +0900 - - Fix compilation error when USE_RINCGC=0 - -commit 1a4b4cd7f8b53fc52191c1ddcf3f624a5e687c24 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-15 23:18:01 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-16 16:14:44 +0900 - - Move `attached_object` into `rb_classext_struct` - - Given that signleton classes don't have an allocator, - we can re-use these bytes to store the attached object - in `rb_classext_struct` without making it larger. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7309 - -commit 7e5df49539eeab4c73a948ed85c8e5d612991255 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-16 11:00:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-16 11:00:45 +0900 - - check-regexp only works with job name, not workflow name - -commit f736f50f38bfbe1dddf418444121997311e271a2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-16 10:16:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-16 10:16:58 +0900 - - Auto-merge feature for dependabot PRs (#7300) - - * Automerge for dependabot update - - * change update period with daily, we can merge it automatically when `make check` of Ubuntu was passed - - * Use rebase instead of merge commit - - * check all Ubuntu jobs - - Notes: - Merged-By: hsbt <hsbt@ruby-lang.org> - -commit 65b6411e9db31591ae2a4928acaa0bc2cc03c427 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-16 09:49:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-16 09:57:08 +0900 - - [ruby/timeout] bump up 0.3.2 - - https://github.com/ruby/timeout/commit/e1b2448101 - -commit b03b251aa4b4a7098721f3497f519f1b3e930f62 - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-02-16 06:40:16 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-02-16 08:43:46 +0900 - - Handle all non-object type objects - - Notes: - Merged: https://github.com/ruby/ruby/pull/7314 - -commit 0b4b2cd1ee161f2875375181e0978d7757e25c8a - Author: Haldun Bayhantopcu <haldun@github.com> - AuthorDate: 2023-02-16 05:13:54 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-02-16 08:43:46 +0900 - - Fix removing ivars from clases and modules. - - Co-authored-by: Adam Hess <hparker@github.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7314 - -commit 70d84a5f3deab5caaeb88134e9d90b1dca4a0462 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-02-16 03:26:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-16 04:25:05 +0900 - - [ruby/timeout] Simplify test - - https://github.com/ruby/timeout/commit/db017da726 - -commit 610375edfc2ed487dc5798278a5923154aec1c1f - Author: Rick Blommers <rick@blommersit.nl> - AuthorDate: 2023-02-12 23:23:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-16 04:25:05 +0900 - - [ruby/timeout] Don't move the timer_thread when it's enclosed - - Don't move the timer_thread to ThreadGroup::Default, when it's - created in an enclosed ThreadGroup. - Prevents the exception: "add" can't move from the enclosed thread group" - - https://github.com/ruby/timeout/commit/eb889d2c8b - -commit 8943b0d411519adeebd0d3dbf7cef337eed1ed02 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-02-16 04:05:42 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-16 04:05:42 +0900 - - YJIT: `Kernel#{is_a?,instance_of?}` fast paths (GH-7297) - - Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7297 - - Merged-By: XrXr - -commit ae2340c9d793e00000186a461a37596b09268370 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-02-15 07:41:23 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-02-16 01:47:26 +0900 - - Refactor / document instance variable debug counters - - This commit is refactoring and documenting the debug counters related to - instance variables. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7305 - -commit 847a0df058a4adb60266213cb8db7bb537c1d09e - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-16 00:00:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-16 00:00:34 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for Net::HTTP#get - (https://github.com/ruby/net-http/pull/121) - - https://github.com/ruby/net-http/commit/51b9af1eed - -commit 3a9d52466ac8b33754a9517c87cfe41cdaaa79bd - Author: HASUMI Hitoshi <hasumikin@gmail.com> - AuthorDate: 2023-02-15 23:53:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-15 23:53:33 +0900 - - [ruby/irb] Fix help-message (https://github.com/ruby/irb/pull/506) - - https://github.com/ruby/irb/commit/a55ace0791 - -commit 7413079dae81e46aefc948cd8872497567945791 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-15 18:42:52 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-15 23:24:22 +0900 - - Encapsulate RCLASS_ATTACHED_OBJECT - - Right now the attached object is stored as an instance variable - and all the call sites that either get or set it have to know how it's - stored. - - It's preferable to hide this implementation detail behind accessors - so that it is easier to change how it's stored. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7308 - -commit bac4d2eefa079168968841079727fe2289b6ab6e - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-15 18:07:06 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-15 18:47:22 +0900 - - Check !RCLASS_EXT_EMBEDDED instead of SIZE_POOL_COUNT == 1 - - It's much more self documenting and consistent - - Notes: - Merged: https://github.com/ruby/ruby/pull/7307 - -commit 1f936d654ac49dff1a6d55aa079aaf1ebba24042 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-02-15 14:49:13 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-02-15 15:42:51 +0900 - - `ractor_queue_enq/deq` doesn't need `rq` param - - `rq` is always `r`'s queue. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7306 - -commit 413120e58178a140e44e39ae79b7ec39f7ee0cbf - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-15 13:44:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-15 13:45:26 +0900 - - Do not use `objcopy` on macOS - - On macOS, it is not used to localize symbols in dynamic libraries - (libruby.dylib and libyjit.o). Instead, using `objcopy` which does - not support recent mach-O causes linker errors as bellow. - - ``` - linking shared-library libruby.3.3.dylib - error: cannot parse the debug map for 'libruby.3.3.dylib': Invalid data was encountered while parsing the file - linking ruby - ld: malformed mach-o: LC_*_DYLIB load command string extends beyond end of load command file './libruby.3.3.dylib' - clang: error: linker command failed with exit code 1 (use -v to see invocation) - ``` - -commit fba8f7783bea8f717c19094f01d513e846fd4247 - Author: TJ <4096void@gmail.com> - AuthorDate: 2023-02-15 12:46:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-15 12:46:16 +0900 - - [DOC] remove redundant paragraph at set.rb (#6472) - - remove redundant paragraph at set.rb - - Notes: - Merged-By: hsbt <hsbt@ruby-lang.org> - -commit 619af4fd6404168a368442941ec80e739aef2609 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-02-15 12:43:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-15 12:43:55 +0900 - - [DOC] Add an example of the splat operator with a non-array object (#7098) - - Notes: - Merged-By: hsbt <hsbt@ruby-lang.org> - -commit 3376eca80a9e23c295a4fe5fb9049c1ad27bb562 - Author: Eric Wong <normal@ruby-lang.org> - AuthorDate: 2023-02-15 12:19:14 +0900 - Commit: Eric Wong <normal@ruby-lang.org> - CommitDate: 2023-02-15 12:26:47 +0900 - - file.c: rb_file_load_ok: GC+retry on EMFILE/ENFILE/ENOMEM - - `require' should make a best effort to avoid failure on - recoverable resource exhaustion errors. - -commit 15ef2b2d7c6a7fb0d485d1e5a9b795a730ef7967 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-15 06:31:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-15 06:31:33 +0900 - - YJIT: Optimize != for Integers and Strings (#7301) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 6c5582815dcd02726354ff407b73aba25b036b74 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-15 05:54:50 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-15 05:54:50 +0900 - - YJIT: Check correct BOP on gen_fixnum_cmp (#7303) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 3c7d5ccdce5707d7964f01f974db505d5add590f - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-15 05:33:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-15 05:33:11 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for request headers - (https://github.com/ruby/net-http/pull/120) - - https://github.com/ruby/net-http/commit/b4eb8a7932 - -commit f4b0e8dc616b896fc8f8e29ae7be47fd7c7918a9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-15 04:58:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-15 04:58:34 +0900 - - YJIT: Pad more spaces to accommodate delimiters (#7302) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 55af69b15eff474b3820ee38242c83e7af5ee07f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-15 02:12:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-15 02:12:48 +0900 - - YJIT: Don't side-exit on too-complex shapes (#7298) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 538c3b9ab7be5e6c3630c7c2e78a7a0a0ee262c4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-14 19:26:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-14 19:26:41 +0900 - - Suppress -Wunused-but-set-variable warning - -commit ef9efcf0bf699f772fcc2e70f96f7db840e03fc0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-14 18:37:33 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-14 18:47:29 +0900 - - Check if objcopy works to localize symbol - - LLVM objcopy does not support localizing symbols option, e.g, - `--localize-symbol` and `--keep-global-symbol`, for MachO. - -commit 2490b2e1216f02aa896abdf121a28e50cac107c3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-04 01:31:56 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-14 15:18:21 +0900 - - Add utility macros `DECIMAL_SIZE_OF` and `DECIMAL_SIZE_OF_BYTES` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7299 - -commit 45f0e3a673964069a4c9c57ce8665cbc21ac267f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-26 23:04:46 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-14 12:02:07 +0900 - - [Bug #19259] `Data#with` should call `initialize` method - -commit dbe5b0dcfffbad5a0ce3af1570dbb6db70266275 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-14 09:58:44 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-14 09:58:46 +0900 - - YJIT: Fix a typo in a counter name - - I added `invokeblock_iseq_arg0_args_splat` counter but it wasn't used - because of a typo. - - Related to https://github.com/ruby/ruby/pull/7234 - -commit 86de48e9f69b665ba9ffb5bdc5a181a3adb1a7b8 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-13 23:51:59 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-02-14 01:42:58 +0900 - - Remove ibf_dumper's WB_PROTECTED status - - It doesn't have the right write barriers in place. For example, there is - - rb_mark_set(dump->global_buffer.obj_table); - - in the mark function, but there is no corresponding write barrier when - adding to the table in the - `ibf_dump_object() -> ibf_table_find_or_insert() -> st_insert()` code path. - - To insert write barrier correctly, we need to store the T_STRUCT VALUE - inside `struct ibf_dump`. Instead of doing that, let's just demote it - to WB unproected for correctness. These dumper object are ephemeral so - there is not a huge benefit for having them WB protected. - - Users of the bootsnap gem ran into crashes due to this issue: - https://github.com/Shopify/bootsnap/issues/436 - - Fixes [Bug #19419] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7296 - -commit 7ddcee5928d8a98337077d5a5ee61136ec84a993 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-10 18:31:30 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-14 01:08:21 +0900 - - Marshal.load: also freeze extended objects - - [Bug #19427] - - The `proc` wouldn't be called either, that fixes both. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7284 - -commit bc6e587e86a4a4a46af3b1c2fbe1ff3b399735a6 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-02-10 07:52:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-13 22:04:33 +0900 - - [ruby/net-http] Enhanced RDoc for Compression - - https://github.com/ruby/net-http/commit/cff88acd70 - -commit 9821f6d0e5957a680bb4ce39708ebc86e23d85d0 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-13 15:12:54 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-13 15:12:54 +0900 - - Override release date in Makefile if possible - -commit 849087ccb1e0f7ec2a3c018f9aeb6b462c971893 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-13 15:12:14 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-13 15:12:14 +0900 - - Apply zone offset to the last modified time - -commit f313514563853f1ee623135c2959df2b518ee755 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-02-13 05:27:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-13 05:27:32 +0900 - - [ruby/irb] Fix colorize backtick symbol - (https://github.com/ruby/irb/pull/508) - - https://github.com/ruby/irb/commit/dd7f25cd45 - - Co-authored-by: Stan Lo <stan001212@gmail.com> - -commit 6517d1a188cb0b9aff70f93df8630105dbb98ebc - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 09:57:56 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-11 09:57:56 +0900 - - [DOC] Move old ChangeLog files to doc/ChangeLog (#7293) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit d8facbabff91159b494d8a9e7d62c15c3d725c86 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 09:37:42 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-11 09:37:43 +0900 - - [DOC] Make the header levels consistent again - -commit 27fe4a1bc5a1205268d5354474c79556119e0c65 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-02-11 09:37:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-11 09:37:07 +0900 - - Fix minor issues in doc/maintainers.md (#7292) - - Use *unmaintained* instead of Ruby core team in 2 places, for - consistency with the rest of the document. - - Use h3 instead of h4 tags if nested directly under h2. - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit c06565390e00f427fdd99dc2f86b53675d2e5b70 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 09:33:56 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-11 09:34:55 +0900 - - [DOC] debug.rb is a bundled gem from 3.1 - -commit 0e7eac7b4821260621ca320c29ee36e9bfcd799a - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 09:30:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-11 09:30:47 +0900 - - [DOC] Add a link to [ruby-core:25764] - -commit 1189a5634c2f6e1780f404445e580a72581876a3 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 09:22:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-11 09:22:43 +0900 - - [DOC] Update a link to maintainers.rdoc - -commit f6d4f2bf6795f6fdee6805354cce06859b9fe36f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-11 09:21:34 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-11 09:21:34 +0900 - - Convert doc/maintainers.rdoc to .md (#7291) - - * [DOC] Convert maintainers.rdoc to .md - - with RDoc::Markup::ToMarkdown - - * [DOC] Format maintainers.md - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit a7e8eabeed54392588c7f01afe8be2e72d3c526d - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-02-11 06:05:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-11 06:05:16 +0900 - - YJIT: add counters for polymorphic send and send with known class (#7288) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 7ece23bf745306479f5a05d16ec64eb4460af2ba - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-10 21:08:39 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-11 01:53:20 +0900 - - Remove duplicate definitions - - These are defined in ruby/internal/config.h which is included in - this file already. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7285 - -commit dc715af53b9f7ef1404785f97842fa78ea2662d8 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-08 20:00:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-11 01:53:04 +0900 - - Tell VSCode to debug test.rb by default [ci-skip] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7271 - -commit 46298955e42600eeeffd53dd683961d5f725e253 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-10 22:32:46 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-11 00:12:22 +0900 - - Implement Write Barrier for RMatch objects - - They only have two references. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7286 - -commit be94808282e50d3ecaa1392ffc38c9ec89e3438b - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-02-10 16:02:20 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-02-10 17:55:25 +0900 - - use correct svar even if env is escaped - - This patch is follo-up of 0a82bfe. - Without this patch, if env is escaped (Proc'ed), strange svar - can be touched. - - This patch tracks escaped env and use it. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7282 - -commit 38ecf08ba16b7e8946ac414f4f8c7ee155b34083 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-10 14:46:52 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-10 14:46:52 +0900 - - [DOC] Fix the help messages for clean - -commit b9f90cafa1c09dd42bfae456ae08be9e826a7d11 - Author: Eric Wong <normal@ruby-lang.org> - AuthorDate: 2023-02-10 12:42:50 +0900 - Commit: Eric Wong <normal@ruby-lang.org> - CommitDate: 2023-02-10 12:50:31 +0900 - - st.c: spell `perturb' properly - - Otherwise, a reader may wonder who `Peter B.' is and why - a variable is named after them... - -commit 94aed6ece5517344760816e521ee5d62366dfafb - Author: Satadru Pramanik, DO, MPH, MEng <satadru@gmail.com> - AuthorDate: 2023-02-10 12:37:26 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-10 12:37:39 +0900 - - [ruby/fileutils] Add mkdir_p to FileUtils.install - (https://github.com/ruby/fileutils/pull/104) - - * Add mkdir_p to FileUtils.install - - * Adjust raise message. - - * adjust raise language - - * handle trailing slash in dest - - * simplify - - * Add tests - -commit 194520f80e1cdb71faa055d731450855a1ddb8d1 - Author: Mike Perham <mike@perham.net> - AuthorDate: 2023-02-10 10:08:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-10 10:08:49 +0900 - - [ruby/logger] Add Logger#with_level{...} for block-scoped log level. - (https://github.com/ruby/logger/pull/85) - - * Update lib/logger/severity.rb - - https://github.com/ruby/logger/commit/7aabb0b4aa - -commit b61edc5f5daf8fb664c9bcd7e51850176055d749 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-02-10 04:17:17 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-02-10 09:59:40 +0900 - - Add internals glossary - - I started a glossary to help new contributors navigate the internals of - CRuby, and I think we should maintain it in ruby/ruby - - Notes: - Merged: https://github.com/ruby/ruby/pull/7280 - -commit 07bf97e94f44b51df104c37fb2e93bd0d882db32 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-10 08:42:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-10 09:26:12 +0900 - - Enhancement github releases generator - - * Create GitHub Releases by itself - * Added help and usage message - * Decorate release body - -commit 2c8e4aa2a0ff7aa92b81b4ed6ea890bc03332c0c - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-02-10 07:04:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-10 07:04:45 +0900 - - YJIT: format numbers in stats printouts with comma separators (#7281) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 810aeb2d91f0e54fdc1d6a4fd9bf1dd51b2d3bde - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-02-10 05:14:26 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-10 05:14:26 +0900 - - YJIT: optimized codegen for `rb_ary_empty_p` (WIP) (#7242) - - * YJIT: add specialized implementation of rb_ary_empty_p() - - * Update yjit/src/codegen.rs - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - --------- - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit d620855101dffa01ee2bef3e78053636f4c88388 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-09 22:22:59 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-10 05:02:26 +0900 - - Rename rb_str_splice_{0,1} -> rb_str_update_{0,1} - - Notes: - Merged: https://github.com/ruby/ruby/pull/7278 - -commit 601b83dcfc7e14bab66cbe549a4f736f971a03ed - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-09 22:16:46 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-10 05:02:26 +0900 - - Remove alias macro rb_str_splice - - Notes: - Merged: https://github.com/ruby/ruby/pull/7278 - -commit b9e6580135d20cf3fff2e872b3e54c08e96468cb - Author: eileencodes <eileencodes@gmail.com> - AuthorDate: 2023-02-09 05:27:28 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-02-10 04:24:32 +0900 - - Copy cvar table on clone - - When a class with a class variable is cloned we need to also copy the - cvar cache table from the original table to the clone. I found this bug - while working on fixing [Bug #19379]. While this does not fix that bug - directly it is still a required change to fix another bug revealed by - the fix in https://github.com/ruby/ruby/pull/7265 - - This needs to be backported to 3.2.x and 3.1.x. - - Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7275 - -commit 0ddf29f4d170e90b895f4fbd313a716d770932b8 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-10 01:38:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-10 01:38:32 +0900 - - Remove unused preprocessor block - -commit 381bdee118532025b9397ea282d6f5ddb65996e0 - Author: Maple Ong <maple.ong@gusto.com> - AuthorDate: 2023-02-10 00:41:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-10 00:41:29 +0900 - - YJIT: Support invokesuper in a block (#7264) - - Support invokesuper in a block on YJIT - - invokesuper previously side exited when it is in a block. To make sure we're compiling the correct method in super, we now use the local environment pointer (LEP) to get the method, which will work in a block. - - Co-authored-by: John Hawthorn <john@hawthorn.email> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 0601ba6a1bf15e13ac931921861c90535ed29dde - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-10 00:38:31 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-10 00:38:31 +0900 - - YJIT: Add counter for megamorphic send (#7274) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit b78f871d838c168789648738e5c67b071beb8a19 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-10 00:34:19 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-10 00:34:19 +0900 - - YJIT: Use the system page size when the code page size is too small (#7267) - - Previously on ARM64 Linux systems that use 64 KiB pages - (`CONFIG_ARM64_64K_PAGES=y`), YJIT was panicking on boot due to a failed - assertion. - - The assertion was making sure that code GC can free the last code page - that YJIT manages without freeing unrelated memory. YJIT prefers picking - 16 KiB as the granularity at which to free code memory, but when the - system can only free at 64 KiB granularity, that is not possible. - - The fix is to use the system page size as the code page size when the - system page size is 64 KiB. Continue to use 16 KiB as the code page size - on common systems that use 16/4 KiB pages. - - Add asserts to code_gc() and free_page() about code GC's assumptions. - - Fixes [Bug #19400] - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 970e7cdec30d037c680ab8b36f8e4547159f3495 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-02-10 00:33:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-10 00:33:37 +0900 - - [ruby/irb] Make tests more compatible with TruffleRuby - (https://github.com/ruby/irb/pull/514) - - * Improve encoding error test case - - The test input IRB currently uses happen to hit a compatibility bug in - TruffleRuby, which has been documented in - https://github.com/oracle/truffleruby/issues/2848 - - Although it'll eventually be fixed, we can make the test case support TruffleRuby - now by tweaking it just a little bit. - - Co-authored-by: Kevin Menard <kevin@nirvdrum.com> - - * Remove redundant TruffleRuby omits/pends - - Co-authored-by: Kevin Menard <kevin@nirvdrum.com> - - * Use a different way to test warning emission - - The test case was added in https://github.com/ruby/irb/commit/d08ef68d2dfbf041d363f65686d78a937954513c - to verify that IRB emits Ruby warning as expected. - - But the subject it uses relies on CRuby's regexp engine, which isn't always - used in other language implementations, like TruffleRuby. That's why we - ended up skipping TruffleRuby in this test case. - - Since the test isn't about regexp itself, we can change the testing subject - and just remove the special condition for TruffleRuby. - - Co-authored-by: Kevin Menard <kevin@nirvdrum.com> - - --------- - - https://github.com/ruby/irb/commit/6fdf4f3e97 - - Co-authored-by: Kevin Menard <kevin@nirvdrum.com> - -commit 72aba64fff09a829bfaf41165d0075066f087185 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-02-08 20:56:53 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-10 00:32:29 +0900 - - Merge gc.h and internal/gc.h - - [Feature #19425] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7273 - -commit e2b6289bab16ff2e05e8ac7a8bc3a35bcc2c44ed - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-10 00:16:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-10 00:16:17 +0900 - - YJIT: Add counters for ivar exits (#7266) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit da4464b824857d7610f9865ceb452ce0ead49164 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-09 20:37:34 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-09 20:37:34 +0900 - - [Bug #19426] Fix endless `Range#step` with `#succ` method - - Notes: - Merged: https://github.com/ruby/ruby/pull/7277 - -commit 8edd350bda66a9ecb2c1043627679f2dc48d6f66 - Author: Daniel Colson <danieljamescolson@gmail.com> - AuthorDate: 2023-02-08 03:13:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-09 19:29:50 +0900 - - [rubygems/rubygems] Avoid crashing with a corrupted lockfile - - I did a bad thing (script that edits the Gemfile.lock directly) and - ended up with a Gemfile.lock that was completely missing some indirect - dependencies. While this is my fault and an error is reasonable, I - noticed that the error got progressively less friendly in recent - versions of bundler. - - Something similar came up in https://github.com/rubygems/rubygems/issues/6210, - and this commit would have helped with that case as well - (although we've already handled this a different way with #6219). - - Details: - --- - - Back on Bundler 2.2.23, a corrupt lockfile like this would cause a helpful error: - - ``` - Unable to find a spec satisfying minitest (>= 5.1) in the set. Perhaps the lockfile is corrupted? - ``` - - Bundler 2.3.26 gave a helpful warning: - - ``` - Warning: - Your lockfile was created by an old Bundler that left some things out. - Because of the missing DEPENDENCIES, we can only install gems one at a time, - instead of installing 16 at a time. - You can fix this by adding the missing gems to your Gemfile, running bundle - install, and then removing the gems from your Gemfile. - The missing gems are: - * minitest depended upon by activesupport - ``` - - But then continued on and crashed while trying to report the unmet - dependency: - - ``` - --- ERROR REPORT TEMPLATE ------------------------------------------------------- - - NoMethodError: undefined method `full_name' for nil:NilClass - lib/bundler/installer/parallel_installer.rb:127:in `block (2 levels) in check_for_unmet_dependencies' - - ... - ``` - - Bundler 2.4.0 and up crash as above when jobs=1, but crash - even harder when run in parallel: - - ``` - --- ERROR REPORT TEMPLATE ------------------------------------------------------- - - fatal: No live threads left. Deadlock? - 3 threads, 3 sleeps current:0x00007fa6b6704660 main thread:0x00007fa6b6704660 - * #<Thread:0x000000010833b130 sleep_forever> - rb_thread_t:0x00007fa6b6704660 native:0x0000000108985600 int:0 - - * #<Thread:0x0000000108dea630@Parallel Installer Worker #0 tmp/1/gems/system/gems/bundler-2.5.0.dev/lib/bundler/worker.rb:90 sleep_forever> - rb_thread_t:0x00007fa6b67f67c0 native:0x0000700009a62000 int:0 - - * #<Thread:0x0000000108dea4a0@Parallel Installer Worker #1 tmp/1/gems/system/gems/bundler-2.5.0.dev/lib/bundler/worker.rb:90 sleep_forever> - rb_thread_t:0x00007fa6b67f63c0 native:0x0000700009c65000 int:0 - - <internal:thread_sync>:18:in `pop' - tmp/1/gems/system/gems/bundler-2.5.0.dev/lib/bundler/worker.rb:42:in `deq' - - ... - ``` - - Changes - --- - - This commit fixes the confusing thread deadlock crash by detecting if - dependencies are missing such that we'll never be able to enqueue. When - that happens we treat it as a failure so the install can finish. - - That gets us back to the `NoMethodError`, which this commit fixes by - using a different warning in the case where no spec is found. - - https://github.com/rubygems/rubygems/commit/d73001a21d - -commit 0a8faab5c2c33926784950f3c5227382ac09d74b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-09 19:21:05 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-09 19:21:31 +0900 - - Avoid to duplicate entries that own redmine and github ids - -commit b49cd843110fd48486ab97085ab475a98780cb45 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-09 16:38:23 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-09 19:21:24 +0900 - - Remove `REG_LITERAL` flag - - All `Regexp` literals are frozen now. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7276 - -commit 5991af204c2b27d7d5343177e6ad247d5954a6c0 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-09 18:52:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-09 18:52:59 +0900 - - Added helper script for generate github releases - -commit 728d2f808e7baf92d9190b3b27161d2405236eb0 - Author: Daniel Colson <danieljamescolson@gmail.com> - AuthorDate: 2023-02-09 04:56:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-09 07:20:24 +0900 - - [rubygems/rubygems] Improve wording of unmet dependencies warning - - `trying to manually editing` doesn't seem quite grammatically - correct. We could change it to `trying to manually edit` (is that a - split infinitive?), but I don't think `trying to` adds much here so - I've removed it instead so `editing` is the verb. - - For the list of dependencies, the wording before this commit seemed to - reverse the dependency. "B, depended on A" sounds like B depends on A - (or did in the past but doesn't anymore?), but that's not correct. I - think there's a missing word: "B, depended on by A", but I find "B, - dependency of A" a bit nicer. - - https://github.com/rubygems/rubygems/commit/49a31257e3 - -commit 861d70e3839856fb27f488755752e06f9183efba - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-09 02:43:25 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-09 02:43:25 +0900 - - Rename iseq_mark_and_update to iseq_mark_and_move - - The new name is more consistent. - -commit 3a0f6ce1d31eefd8af01b50f3632a64d64e8f8c1 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-08 19:23:25 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-08 19:52:59 +0900 - - Use Thread.pass until thread.stop? to wait for thread to block - - [Bug #19415] - - It should be more reliable - - Notes: - Merged: https://github.com/ruby/ruby/pull/7270 - -commit 8ce2fb9bbbaea14737c84385b1573f743a30f773 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2023-02-07 07:30:42 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-08 17:50:00 +0900 - - Only emit circular dependency warning for owned thread shields - [Bug #19415] - - If multiple threads attemps to load the same file concurrently - it's not a circular dependency issue. - - So we check that the existing ThreadShield is owner by the current - fiber before warning about circular dependencies. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7257 - -commit 3ab34551450c7a3a3e1ae0b24bf6b78d26129dfa - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-03 17:46:14 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-08 17:26:07 +0900 - - Add RUBY_GC_HEAP_INIT_SIZE_%d_SLOTS to pre-init pools granularly - - The old RUBY_GC_HEAP_INIT_SLOTS isn't really usable anymore as - it initalize all the pools by the same factor, but it's unlikely - that pools will need similar sizes. - - In production our 40B pool is 5 to 6 times bigger than our 80B pool. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7235 - -commit 6e7990144f37850b9b3ec871956890e2aa29ad6d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-08 14:29:16 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-08 15:36:32 +0900 - - Removed svn feature from make-snapshot - - Notes: - Merged: https://github.com/ruby/ruby/pull/7269 - -commit a56d959ed5d99e602f2bb05bbeb46a1b1b146cd9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-08 12:21:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-08 12:35:27 +0900 - - Replace `PACKED_STRUCT` and `PACKED_STRUCT_UNALIGNED` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7268 - -commit fefe37f98dc347ed372597975a327f3c1425c556 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-06 21:56:04 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-08 12:35:27 +0900 - - Replace `PACKED_STRUCT` in include - - Notes: - Merged: https://github.com/ruby/ruby/pull/7268 - -commit 899ea35035c5bfb78fcdbc9fbfaafba24aee49c1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-06 20:50:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-08 12:34:13 +0900 - - Extract include/ruby/internal/attr/packed_struct.h - - Split `PACKED_STRUCT` and `PACKED_STRUCT_UNALIGNED` macros into the - macros bellow: - * `RBIMPL_ATTR_PACKED_STRUCT_BEGIN` - * `RBIMPL_ATTR_PACKED_STRUCT_END` - * `RBIMPL_ATTR_PACKED_STRUCT_UNALIGNED_BEGIN` - * `RBIMPL_ATTR_PACKED_STRUCT_UNALIGNED_END` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7268 - -commit 1e711439762f47be1d1770b058a2f0246f64eab9 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-08 03:24:59 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-08 06:33:12 +0900 - - Use more agressive RUBY_GC_HEAP_OLDOBJECT_LIMIT_FACTOR for GC tests - - Notes: - Merged: https://github.com/ruby/ruby/pull/7263 - -commit 4713b084da2e03451e3478ad63b148545db3f1a9 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2023-02-07 23:44:16 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-08 06:33:12 +0900 - - Revert "Revert "Consider DATA objects without a mark function as protected"" - - This reverts commit 6eae8e5f514db716e52ad06a2ac97e2cc3910d83. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7263 - -commit fd71a76f55b84e02ba8a3b560baf9b1f996dedd4 - Author: Daniel Colson <danieljamescolson@gmail.com> - AuthorDate: 2023-02-06 12:09:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-08 06:12:18 +0900 - - [rubygems/rubygems] Add Ruby 3.2 and 3.3 platforms to Gemfile DSL - - Along the same lines as https://github.com/rubygems/rubygems/pull/5469, - this adds support for Ruby 3.2 and 3.3 platforms: `:ruby_32`, `mri_32`, - etc. - - It also includes a spec that should help catch this earlier in the - future, failing if we don't support platforms for the version of Ruby - that is running the tests. - - https://github.com/rubygems/rubygems/commit/7cd19d824d - -commit 1c0127ed5e1aaf1386e2176e499d4cb25d171a21 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-04 04:23:00 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-08 06:03:08 +0900 - - Make Time objects WB protected - - Co-Authored-By: Jean Boussier <byroot@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7244 - -commit e9090eb64db703f27be6efbdd4f371822c96146c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-04 04:22:44 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-08 06:03:08 +0900 - - Remove unused code in time.c - - Co-Authored-By: Jean Boussier <byroot@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7244 - -commit 08c20947156c38840b9ed1121522ad147d50fa4d - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-02-08 04:30:47 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-08 04:30:47 +0900 - - Fix confusing " - -commit 779092508cc94f043abbd44cf73cefe1b440a558 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-02-08 04:27:53 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-08 04:27:53 +0900 - - Add Building the Tarball section in distribution docs - -commit 826067b0f970fe7d5514c908be5a30c308a836b5 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-02-08 04:22:14 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-08 04:22:14 +0900 - - Clarify section about getting the Ruby tarball - -commit 91b18dc88cd1d7737ceff13d3b2d250f63230177 - Author: John Hawthorn <john@hawthorn.email> - AuthorDate: 2023-02-07 02:41:36 +0900 - Commit: John Hawthorn <john@hawthorn.email> - CommitDate: 2023-02-08 04:16:50 +0900 - - Use write barriers for Backtrace objects - - Backtrace objects hold references to: - * iseqs - via the captured locations - * strary - a lazily allocated array of strings - * locary - a lazily allocated array of backtrace locations - - Co-authored-by: Adam Hess <HParker@github.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7253 - -commit 2c7fe9c0a6a2cea1243dcb30e684bf8c016f1192 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-02-08 00:40:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-08 01:01:04 +0900 - - [ruby/net-http] Enhanced RDoc for Net::HTTP - - https://github.com/ruby/net-http/commit/e65a3d9f11 - -commit a641f6422c97a72640dc295f6b1b3ec2b9da739e - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-07 23:53:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-07 23:53:38 +0900 - - [ruby/net-http] [DOC] Reorganize doc for proxy server - (https://github.com/ruby/net-http/pull/117) - - https://github.com/ruby/net-http/commit/f8b6b76cba - -commit 6eae8e5f514db716e52ad06a2ac97e2cc3910d83 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-02-07 23:21:40 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-07 23:22:06 +0900 - - Revert "Consider DATA objects without a mark function as protected" - - This reverts commit 6e4c242130965de1cf00703c99f8821b0bd19e5b. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7262 - -commit 046807102f043cac3717397eecaf87bdb11e9015 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-04 06:33:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-07 22:39:48 +0900 - - Use rb_gc_mark_and_move for method objects - - Notes: - Merged: https://github.com/ruby/ruby/pull/7245 - -commit df2e36aeebf0647853eccbe973d69587a5fb2cf6 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-04 06:25:34 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-07 22:39:48 +0900 - - Use rb_gc_mark_and_move for proc and binding - - Also makes VM_ENV_ENVVAL movable. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7245 - -commit 8fc69a0a7e15e82185c99e55ab4d886a0b0bee4a - Author: ima1zumi <mariimaizumi5@gmail.com> - AuthorDate: 2023-01-22 21:28:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-07 21:49:51 +0900 - - [ruby/reline] Add comment for unused constants - - FILENAME_COMPLETION_PROC and USERNAME_COMPLETION_PROC are not used by Reline. - However, they were added for compatibility with the rb-readline gem. - These constants have been retained and comments added. - - https://github.com/ruby/reline/commit/98fdbd3f18 - -commit 31d37e2406d1aa10265944e56807343f91da98fb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-07 21:36:58 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-07 21:38:24 +0900 - - Mentioned gmp at requirements - -commit a66bc448a40929207fcf6e97107d7183ec6350dd - Author: Charles Oliver Nutter <headius@headius.com> - AuthorDate: 2023-01-27 01:07:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-07 21:25:44 +0900 - - [ruby/psych] Bump version to 5.1 for release - - This version primarily updates the JRuby extension to use - SnakeYAML Engine, a newer version of the SnakeYAML library, which - also updates YAML support to 1.2. The JRuby extension now also - exposes settings for the parser. - - https://github.com/ruby/psych/commit/6f2b16b343 - -commit 60c924770d6f0ce05c04c8c0a60a9bf23c79d85f - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-07 07:18:34 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-07 19:48:57 +0900 - - Mark Encoding as Write Barrier protected - - It doesn't even have a mark function. - It's only about a hundred objects, but not reason - to scan them every time. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7254 - -commit 6e4c242130965de1cf00703c99f8821b0bd19e5b - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-07 07:27:12 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-07 19:48:49 +0900 - - Consider DATA objects without a mark function as protected - - It's not uncommon for simple binding to wrap structs without - any Ruby object references. Hence with no `mark` function. - - Might as well mark them as protected by a write barrier. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7255 - -commit 8623c81220541cb05e793e3e9aec8a561e2c57e2 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-07 17:29:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-07 17:29:19 +0900 - - Document default gems and bundled gems specifications - -commit 5ee39ea67f1e683322363129c82be83dea2432b1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-07 14:21:18 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-07 14:21:18 +0900 - - Added tarball instruction to building_ruby.md - -commit a719e3418eee1dd19ca861188579c2878cf4006a - Author: cjilbert504 <54157657+cjilbert504@users.noreply.github.com> - AuthorDate: 2023-01-27 13:54:50 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-07 08:09:38 +0900 - - [ruby/rdoc] Remove duplicate word in RDoc::MarkupReference - - The word "for" appeared twice in the same sentence in the margins section, and this PR removes the duplicate occurrence. - -commit 773d56b1c177aad59c1e35dbe5b9e68099219db2 - Author: zzak <zzakscott@gmail.com> - AuthorDate: 2023-02-06 13:57:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-07 08:09:06 +0900 - - [ruby/rdoc] Add test coverage for -C flag - - https://github.com/ruby/rdoc/commit/564be08f4b - -commit b171e997912f4980c6a948aa98a584d2554ec954 - Author: zzak <zzakscott@gmail.com> - AuthorDate: 2023-02-06 13:04:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-07 08:09:05 +0900 - - [ruby/rdoc] Actually execute RDoc document task for coverage - - https://github.com/ruby/rdoc/commit/7e70d41585 - -commit c19defd02665492de7147572714ebe692260c849 - Author: Jean byroot Boussier <jean.boussier+github@shopify.com> - AuthorDate: 2023-02-07 07:30:00 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-07 07:30:35 +0900 - - Revert "Only emit circular dependency warning for owned thread shields" - - This reverts commit fa49651e05a06512e18ccb2f54a7198c9ff579de. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7256 - -commit c30602e64ce437be86180590eee27b0b6ed83a16 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-07 06:12:20 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-07 06:12:20 +0900 - - YJIT: Support arg0 splat on invokeblock (#7234) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 675e296641468b7c4782e262705feffe58527606 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-07 04:50:06 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-07 04:50:06 +0900 - - Add .DELETE_ON_ERROR to Makefile - - This instructs make to delete target files if the recipe fails midway, like - when make itself is interrupted. This is mostly for development since it - protects against corrupt builds that need a `make clean` to repair. Release - builds normally don't fail mid-recipe. - - GNU make and BSD make support this. - - From GNU make's manual: - - > This is almost always what you want make to do, but it is not historical - > practice; so for compatibility, you must explicitly request it. - - See https://innolitics.com/articles/make-delete-on-error/ - - Notes: - Merged: https://github.com/ruby/ruby/pull/5745 - - Merged-By: XrXr - -commit fa49651e05a06512e18ccb2f54a7198c9ff579de - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-06 20:30:50 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-07 03:35:38 +0900 - - Only emit circular dependency warning for owned thread shields - - [Bug #19415] - - If multiple threads attemps to load the same file concurrently - it's not a circular dependency issue. - - So we check that the existing ThreadShield is owner by the current - fiber before warning about circular dependencies. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7252 - -commit 28da9909849dc02abe74de8170fe4036534361ba - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-01-27 01:42:17 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-02-07 01:40:51 +0900 - - Limit maximum number of IVs on a shape on T_OBJECTS - - Create SHAPE_MAX_NUM_IVS (currently 50) and limit all shapes of - T_OBJECTS to that number of IVs. When a shape with a T_OBJECT has more than 50 IVs, fall back to the - obj_too_complex shape which uses hash lookup for ivs. - - Note that a previous version of this commit - 78fcc9847a9db6d42c8c263154ec05903a370b6b was reverted in - 88f2b94065be3fcd6769a3f132cfee8ecfb663b8 because it did not account for - non-T_OBJECTS - - Notes: - Merged: https://github.com/ruby/ruby/pull/7188 - -commit cab8c11611d94adaa86d9ed8322dd372922f94bc - Author: Akira Matsuda <ronnie@dio.jp> - AuthorDate: 2023-02-04 15:29:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-07 01:19:46 +0900 - - [rubygems/rubygems] Properly exclude gemspec file itself from gem - - by comparing the file names with full path. - - Follows up https://github.com/rubygems/rubygems/commit/f444478eaccf - - https://github.com/rubygems/rubygems/commit/9637a82d2e - -commit 77bec15c937a98d4d863c4a857d5619b41e529f1 - Author: Akira Matsuda <ronnie@dio.jp> - AuthorDate: 2023-02-04 15:22:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-07 01:19:46 +0900 - - [rubygems/rubygems] Properly load the generated gemspec - - The previous code loads bundler's gemspec which does not include the generated - gemspec file, and thus the test was passing where it should indeed fail. - With this change, the test properly fails now. - - https://github.com/rubygems/rubygems/commit/2098ea0d75 - -commit 21dcf5d766befb46c5acffd174f507836e93504c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-07 00:29:41 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-07 00:29:41 +0900 - - YJIT: Check interrupts on frame pop (#7248) - - YJIT: Skip gen_check_ints on ISEQ send - - On the interpreter, vm_push_frame doesn't check interrupts. Only - vm_pop_frame does. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 91f353b1c3c81f101e0421f8a000f414aecad2dc - Author: tompng <tomoyapenguin@gmail.com> - AuthorDate: 2023-01-23 00:00:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-06 23:23:59 +0900 - - [ruby/reline] Fix line rendering when newline is added at the end of the buffer - - https://github.com/ruby/reline/commit/7d61b3df9a - -commit 440b9d2c6f5d405db086c14cc37b3d22b3586b5c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-06 16:19:39 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-06 16:19:39 +0900 - - Fixup 3dcc2b63160588ba313a120823e0723c89f9a09f - -commit 3dcc2b63160588ba313a120823e0723c89f9a09f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-06 16:16:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-06 16:16:45 +0900 - - Separate download section for using Git - -commit f9cd67cbd2da2b6f64865628568673901fa64bcc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-06 16:14:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-06 16:14:19 +0900 - - Mentioned cache.r-l.o - -commit b3fd1222c2401ef4177c2cdddd88b3e9a3e24d1f - Author: ccmywish <ccmywish@qq.com> - AuthorDate: 2023-02-05 20:33:38 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-06 14:20:34 +0900 - - [ruby/English] Replace HTML5 deprecated tag <tt> with <code> - - https://github.com/ruby/English/commit/3712fd6752 - -commit 8a29419b7fb723b3faf04b3d9a3cb0740213d946 - Author: Sorah Fukumori <her@sorah.jp> - AuthorDate: 2023-02-06 04:38:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-06 05:31:37 +0900 - - [ruby/reline] test_dumb_terminal: "ruby" command is not always available - - Fixes the same issue at https://github.com/ruby/ruby/pull/5417 - - `ruby` is not always available in certain build environments and - configure options (e.g. --program-suffix) - - This patch tries to choose an appropriate command line for spawning a - fresh Ruby process, based on EnvUtil implementation in ruby/ruby's test - suite. - - Plus when this library is directly mirrored into ruby/ruby, prefer EnvUtil - available there over the implementation in this library's test suite. - - https://github.com/ruby/reline/commit/278327d2e9 - -commit 8a474b344ea78fcf8a8ea3dac6c6efcf329c2fb9 - Author: cjilbert504 <54157657+cjilbert504@users.noreply.github.com> - AuthorDate: 2023-02-05 18:27:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-05 18:28:02 +0900 - - [ruby/rdoc] [DOC] Fix reference to proper list type RDoc::MarkupReference - - The "Lettered List" section referred to the previous "Numbered List" section, so this PR fixes that reference to point instead of lettered lists. - -commit 45a2f1c5c23f1c81afc7a999d6ae64e9f4fd3942 - Author: Sam Bostock <sam.bostock@shopify.com> - AuthorDate: 2023-02-04 08:12:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-05 10:37:36 +0900 - - [rubygems/rubygems] Replace "prior to" with "immediately after" - - Currently, the instructions and placeholder contradict each other. - - The commit that introduced this placeholder (42bc4715d920e836c8499883d) - makes it clear that the placeholder should be replaced AFTER publishing - (i.e. once the author successfully claims the gem name on Rubygems), so - the placeholder should match. - - https://github.com/rubygems/rubygems/commit/23e2dea828 - -commit 295fc59edafff0b29df2349189592c796e5ca63e - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-02-05 07:31:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-05 07:31:17 +0900 - - [ruby/irb] Add tests for workspaces commands - (https://github.com/ruby/irb/pull/512) - - https://github.com/ruby/irb/commit/874dbcad81 - -commit 3d20740881b592c03e27627967f7a98c4f49813d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-05 06:46:46 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-05 06:46:46 +0900 - - Remove unneeded repetitions - -commit 0a02c51a06a6eaae33d75931def04ea7bb36cf03 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-03 22:44:04 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-05 04:38:55 +0900 - - [rubygems/rubygems] Ensure that `TempIO` is closed - - https://github.com/rubygems/rubygems/commit/0cbb7b5370 - -commit e37bf46ed517c4cd74e818a1694185fb44feca72 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-03 22:29:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-05 04:38:55 +0900 - - [rubygems/rubygems] Fix Tempfile leaks - - https://github.com/rubygems/rubygems/commit/f95d1a87ce - -commit 6db79aefec27035583c5b236d98425748b428c49 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-05 03:06:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-05 03:06:06 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for Net::HTTP - (https://github.com/ruby/net-http/pull/116) - - https://github.com/ruby/net-http/commit/22c0d34002 - -commit da9ee7bcf361887a28a1dd6769a4f47261dea7aa - Author: zzak <zzakscott@gmail.com> - AuthorDate: 2023-02-03 09:02:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-04 08:41:06 +0900 - - [ruby/rdoc] Add newline before return - - https://github.com/ruby/rdoc/commit/6d609cb64c - - Co-authored-by: Olle Jonsson <olle.jonsson@gmail.com> - -commit e04d20bc482e39262a648e71193c1739b5a702fc - Author: zzak <zzakscott@gmail.com> - AuthorDate: 2023-02-01 12:22:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-04 08:41:06 +0900 - - [ruby/rdoc] Add rdoc:coverage default task - - https://github.com/ruby/rdoc/commit/157fbaf575 - -commit a8000d06cc718349192acbc8343ba849ba34a67f - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-03 20:59:44 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-04 07:31:23 +0900 - - Mark "method" objects as protected by write barrier - - All its reference are set with RB_OBJ_WRITE, so they - can be marked as WB protected. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7237 - -commit cc9d96b259f4aca151e532d53060091114b5e39b - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-04 00:21:33 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-04 07:31:08 +0900 - - Avoid using OBJ_WB_UNPROTECT - - Not that it makes a big difference here, but it's - just unecessary. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7241 - -commit 3fefe660f8e4595782f51f89277bb2054802f334 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-02-04 07:26:39 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-04 07:26:39 +0900 - - [DOC] Fix call-seq of Struct.new (#7246) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit e30cf60a191ab78d08930825598026e85e130648 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-02 23:43:38 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-04 04:59:00 +0900 - - Remove dead code in ar_copy - - All of the callers of ar_copy guarantee that hash2 has an ar table, - so we don't need the logic to handle the case when hash2 doesn't have - an ar table. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7230 - -commit f901b934fdb6adba8ac5f40ff835334f054e3e34 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-04 03:50:02 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-02-04 04:58:01 +0900 - - YJIT: Make Block::start_addr non-optional - - We set the block address as soon as we make the block, so there is no - point in making it `Option<CodePtr>`. No memory saving, unfortunately, - as `mem::size_of::<Block>() = 176` before and after this change. Still - a simplification for the logic, though. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7243 - -commit e50f102489fcd7ccb5bfca683bbdd430ed2fa20c - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-17 05:30:18 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-02-04 03:26:45 +0900 - - CI: Pass -O2 for annocheck - - Because `optflags` is pasted into the invocation line after `CC`, we were - building with -O1 unintentionally. You can see this in the configuration - summary: https://github.com/ruby/ruby/actions/runs/3933391169/jobs/6727044423#step:9:753 - - The check actually fails with -O2. To make it pass, upstream suggest - that we use the annocheck GCC plugin. Since it requires building from - source as the debian package for it isn't ready yet, punt on it for now - and use `--skip-gaps`. - - Co-authored-by: Jun Aruga <jaruga@redhat.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7132 - -commit c6b90e5e9cc9bad4156881b6ab227d0f8a04cf7a - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-03 21:15:26 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-04 03:10:42 +0900 - - Mark "mapping_buffer" as write barrier protected - - It doesn't have any reference so it can be marked as protected. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7238 - -commit 08c529be900b2bee13858faa5a27933dfe645abb - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-04 00:14:42 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-04 00:14:42 +0900 - - YJIT: Support ifunc on invokeblock (#7233) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 8e7d2cc2ab55339b946025f01f52b1795dab3e1a - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-03 23:20:44 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-03 23:58:44 +0900 - - Implement Write Barrier for Backtrace::Location - - It only has a single reference, set in a single place. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7240 - -commit fe5ce1ee418dacad6315f3f3a7dfc95d3315f836 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-02-03 21:25:20 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-02-03 23:37:01 +0900 - - Enable write barriers on File::Stat - - It holds no reference, so no changes needed. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7239 - -commit faa4c2279aa018a2bb9bc09107adf8a8fcf5fd3d - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-03 23:33:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-03 23:33:53 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for write_timeout - (https://github.com/ruby/net-http/pull/115) - - https://github.com/ruby/net-http/commit/6da39b0461 - -commit cbd5de4f88b889eb6bd40ddb073da57e7c7af10a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-03 16:47:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-03 16:49:31 +0900 - - [ruby/stringio] Development of 3.0.6 started. - - https://github.com/ruby/stringio/commit/a7561f447b - -commit 73674cac2bbb2616a182305f4719844c59816e21 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-02-03 06:54:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-03 06:54:16 +0900 - - YJIT: log the names of methods we call to in disasm (#7231) - - * YJIT: log the names of methods we call to in disasm - - * Assert that pointer is not null - - * Handle case where UTF8 conversion not possible - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 3b83b265f11965582d4b9b439eff8a501792ab68 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-03 04:02:36 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-02-03 05:16:09 +0900 - - YJIT: Crash with rb_bug() when panicking - - Helps with getting good bug reports in the wild. Intended to be - backported to the 3.2.x series. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7232 - -commit 5b34839b0f9d164552f8da41b6ced2db1d2af3be - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-03 04:43:30 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-03 04:43:50 +0900 - - Remove redundant else if statement in hash.c - - Hashes can only be ar or st, so the else if is redundant. - -commit 65ca14ea6e12d2e0bf2aff60538c8ca291c65fd3 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-02-01 09:12:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-03 02:17:34 +0900 - - [rubygems/rubygems] Fix TarReader::Entry#read/partial to match File#read and StringIO#read - - TarReader is used as an IO object, but doesn't behave the same as other - implementations. These fixes make `read` and `readpartial` conform to the - interface of StringIO and File. - - https://github.com/rubygems/rubygems/commit/bba32d7217 - -commit 0853703ec6484332ef0183ebd459a8c715d36a43 - Author: Martin Emde <martin.emde@gmail.com> - AuthorDate: 2023-02-01 08:43:01 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-03 02:17:33 +0900 - - [rubygems/rubygems] Test to show non-standard behavior of zero byte files in archive - - Added more tests for some of the other behavior as well. - Tests were missing for readpartial with a buffer, and reading - remaining bytes after a partial read, using StringIO as reference. - - https://github.com/rubygems/rubygems/commit/d600a657b1 - -commit 188688a53e7708d25ab80e14d05e70ffcf792e13 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-02 07:25:53 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-02-03 00:05:00 +0900 - - YJIT: ARM64: Fix long jumps to labels - - Previously, with Code GC, YJIT panicked while trying to emit a B.cond - instruction with an offset that is not encodable in 19 bits. This only - happens when the code in an assembler instance straddles two pages. - - To fix this, when we detect that a jump to a label can land on a - different page, we switch to a fresh new page and regenerate all the - code in the assembler there. We still assume that no one assembler has - so much code that it wouldn't fit inside a fresh new page. - - [Bug #19385] - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7227 - -commit 905e12a30ddc26ebcae5d3692687ee555b905f98 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-02 07:24:50 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-02-03 00:05:00 +0900 - - YJIT: ARM64: Move functions out of arm64_emit() - - Notes: - Merged: https://github.com/ruby/ruby/pull/7227 - -commit a690db390d68995311a77a5011298d81dca15233 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-02 07:21:11 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-02-03 00:05:00 +0900 - - YJIT: other_cb is None in tests - - Since the other cb is in CodegenGlobals, and we want Rust tests to be - self-contained. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7227 - -commit 81b7f86f474ca54d93a128a5e6cec5deb20cd30b - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-02 07:16:05 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-02-03 00:05:00 +0900 - - YJIT: Move CodegenGlobals::freed_pages into an Rc - - This allows for supplying a freed_pages vec in Rust tests. We need it so we - can test scenarios that occur after code GC. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7227 - -commit 84be7a40893e4bccf836835a9ace0ff8cf4f5cc8 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-02 00:18:34 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-02 23:17:20 +0900 - - Keep shared arrays WB protected - - Sharing an array will cause it to be WB unprotected due to the use - of `RARRAY_PTR`. We don't need to WB unprotect the array because we're - not writing to the buffer of the array. - - The following script demonstrates this issue: - - ``` - ary = [1] * 1000 - shared = ary[10..20] - puts ObjectSpace.dump(ary) - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7224 - -commit 3e5a77f1ae73f4a6bf7b2b868be674ab8c714c7a - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-02-02 06:19:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-02 23:16:59 +0900 - - [ruby/net-http] Remarks on inclusions - - https://github.com/ruby/net-http/commit/dfd060c583 - -commit 5a9e2f142d9debfb44d7d23f6821b810607d9d15 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-02-02 23:03:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-02 23:03:19 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for HTTPGenericRequest - (https://github.com/ruby/net-http/pull/113) - - https://github.com/ruby/net-http/commit/14c8405702 - -commit c35ebed895e1a3f7bced3db50ea0db8f284744e8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-02 17:20:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-02 18:11:06 +0900 - - Removed OS specific section because It's out of scope for us. - -commit 3474a62033cc13a6b407b519bb25db2fc950aa25 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-02 14:48:39 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-02 14:48:44 +0900 - - Mentioned scoop and vcpkg for windows build instruction - -commit 1c5bd01363fad5460768f3a9382687bb9e0992f8 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-02 14:47:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-02 14:47:45 +0900 - - Add a test for svar #7225 (#7228) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 4d82e94200c069b1c4195a0e68fe48963e44c975 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-02 14:11:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-02-02 14:12:08 +0900 - - Ignore rb_mjit_header.h.new and ripper.tmp.y - -commit 8087ba736e447c11296fadd9cf32bd46b1b14414 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-29 15:07:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-02 13:44:38 +0900 - - [ruby/stringio] bump up to 3.0.6 - - https://github.com/ruby/stringio/commit/325933500b - -commit fad48fefe19cc282a5b209944244a3713359b47f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-02 10:52:38 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-02 12:20:10 +0900 - - [Bug #19399] Parsing invalid heredoc inside block parameter - - Although this is of course invalid as Ruby code, allow to just parse - and tokenize. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7229 - -commit f499c81b01b5c4b7a2ce11d6467d793669d67695 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-22 01:06:21 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-02 11:22:16 +0900 - - [DOC] Merge README.win32 to doc/windows.md - - Notes: - Merged: https://github.com/ruby/ruby/pull/7170 - -commit 0a82bfe5e18ac86da72c27389db6eb8da156a0b5 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-02-02 09:13:19 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-02 09:13:19 +0900 - - use correct svar (#7225) - - * use correct svar - - Without this patch, svar location is used "nearest Ruby frame". - It is almost correct but it doesn't correct when the `each` method - is written in Ruby. - - ```ruby - class C - include Enumerable - def each - %w(bar baz).each{|e| yield e} - end - end - - C.new.grep(/(b.)/){|e| p [$1, e]} - ``` - - This patch fix this issue by traversing ifunc's cfp. - - Note that if cfp doesn't specify this Thread's cfp stack, reserved - svar location (`ec->root_svar`) is used. - - * make yjit-bindgen - - --------- - - Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 2675f2c864f462dbdee85d2187e0ac3379106eed - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-02-02 06:05:22 +0900 - Commit: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - CommitDate: 2023-02-02 06:05:22 +0900 - - Remove whitespace - -commit c6f84e918943a0bf8db6fee556fc53180d257510 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-01 23:08:57 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-02 03:23:55 +0900 - - [Bug #19398] Memory leak in WeakMap - - There's a memory leak in ObjectSpace::WeakMap due to not freeing - the `struct weakmap`. It can be seen in the following script: - - ``` - 100.times do - 10000.times do - ObjectSpace::WeakMap.new - end - - # Output the Resident Set Size (memory usage, in KB) of the current Ruby process - puts `ps -o rss= -p #{$$}` - end - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7223 - -commit 375f527ded72cd20374144dd605e0177945b9fae - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-02-01 18:24:21 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-02 01:44:55 +0900 - - [rubygems/rubygems] Introduce to specify deprecated version for rubygems_deprecate_command. - - We sometimes to remove minor command without bumping major version. This feature - helps this deprecation process. - - https://github.com/rubygems/rubygems/commit/41301cd2a8 - -commit aa222b56faa31397ad19fa06b5cfb4cdd52b3148 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-02 00:33:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-02 00:59:11 +0900 - - [ruby/bigdecimal] Make BigDecimal WB protected - - BigDecimal has no references, so it is WB protected. - - https://github.com/ruby/bigdecimal/commit/29c61c90e8 - -commit 269c5d408fd3ab83731b8eae0fbc13387eece306 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2023-02-01 22:49:19 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2023-02-01 22:49:54 +0900 - - fix to work with the case default issue is used - -commit 62146d3ceece27a2dc7e0e945d292a4d28e82beb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-01 22:45:45 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-01 22:45:45 +0900 - - Fix a typo - -commit 9445a14d313346dea3379495000b8f4637250479 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-01 22:42:12 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-01 22:42:12 +0900 - - Suppress an unused-function warning - -commit ee3176a27afd943247fb6e82e95e2d1efafa4c50 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-29 23:31:03 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-01 17:13:01 +0900 - - Reject VS2022 compiler versions with the known bugs - -commit 7b343d9c67517227843c3ac0802ac6412d547a0a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-02-01 00:23:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-02-01 16:17:12 +0900 - - Extract body rules from endless method definitions - - Notes: - Merged: https://github.com/ruby/ruby/pull/7222 - -commit 5694515460f075ef66b2e32499ac265b79982a03 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-01 08:02:44 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-01 08:02:44 +0900 - - Document BUNDLED_GEMS in make test - -commit 1148fab7ae4653f94384da5eb282e61217cf12f5 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-02-01 06:18:56 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-01 06:18:56 +0900 - - YJIT: Handle splat with opt more fully (#7209) - - * YJIT: Handle splat with opt more fully - - * Update yjit/src/codegen.rs - - --------- - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 3ebc80314cf1ce727dcc2ba4192ff5265d348206 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-02-01 02:05:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-02-01 06:01:04 +0900 - - [ruby/net-http] Redirection revision - - https://github.com/ruby/net-http/commit/9a4e2d3a2a - -commit 97740a525ec882a77df192f0d3dd8880fe3e1599 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-02-01 05:53:40 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-01 05:53:40 +0900 - - Update yjit.md - - Update some out of date information and mention how to check that YJIT is enabled. - -commit 9f9dca0c520eb3a2706aa1f6a042cf1fcc07233b - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-01 03:33:51 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-01 05:48:09 +0900 - - Remove rb_hash_ar_table_p - - It's dead code and duplicate of RHASH_AR_TABLE_P. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7211 - -commit 2296b877d800bfeafb59df7e60c7eddd8f0a2ae3 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-01 03:30:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-01 05:48:09 +0900 - - Remove rb_hash_st_table - - It's a duplicate of RHASH_ST_TABLE. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7211 - -commit 2866f951c5a2ba940d21ef7232143dd862a26c20 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-02-01 03:29:18 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-02-01 05:48:09 +0900 - - Remove rb_hash_ar_table - - It's dead code and duplicate of RHASH_AR_TABLE. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7211 - -commit e11067ebbfcf2c2422a5d00b50306782a9d86364 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-01 05:26:56 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-01 05:26:56 +0900 - - YJIT: Fix BorrowMutError on BOP invalidation (#7212) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit eac5ae22e26e741b465527ab65017fda8890b6bf - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-02-01 02:28:09 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-02-01 04:29:18 +0900 - - YJIT: Group unimplemented method types together - - Grouping these together helps with finding all of the unimplemented - method types. It was interleaved with some other match arm long and - short previously. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7210 - -commit 4ce642620f10ae18171b41e166aaad3944ef482a - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-02-01 02:18:41 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-01 02:18:41 +0900 - - Make sure RUBY_YJIT_ENABLE only enables YJIT for truthy values (#7208) - - * Make sure RUBY_YJIT_ENABLE only enables YJIT for truthy values - - Addresses bug reported in: https://github.com/Shopify/yjit/issues/309 - - * Update ruby.c - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - - --------- - - Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 74e52c2a1723320423a776187cdf6360b7f44281 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-01 02:15:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-02-01 02:15:05 +0900 - - Disable broken last_files_match_only for now - -commit c221a40201d6c674f168a33bfa1f1952bbfb6891 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-02-01 00:33:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-01 00:33:08 +0900 - - Update yjit.md - -commit 2a0bf269c96643fcac27bca63aff2371bbffabdd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-02-01 00:11:10 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-02-01 00:11:10 +0900 - - YJIT: Implement codegen for Kernel#block_given? (#7202) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 2181a66374d2c9d0508e5a2c9fbc3c533a2c7386 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-31 23:48:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-31 23:48:24 +0900 - - Test VM_CHECK_MODE on GitHub Actions (#7204) - - It's disabled in compilers.yml, but it's nice to test CHECK_CANAY - on GitHub Actions as well. - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit de724487f0820391e005f11e67ea132cffe3c9d3 - Author: Kunshan Wang <wks1986@gmail.com> - AuthorDate: 2022-10-27 18:47:47 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-31 23:24:26 +0900 - - Copying GC support for EXIVAR - - Instance variables held in gen_ivtbl are marked with rb_gc_mark. It - prevents the referenced objects from moving, which is bad for copying - garbage collectors. - - This commit allows those instance variables to be updated during - gc_update_object_references. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7206 - -commit d92289f6330c57b0fe970a654dbf33314bfd6203 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-01-31 23:18:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-31 23:18:50 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for Net::HTTP - (https://github.com/ruby/net-http/pull/110) - - https://github.com/ruby/net-http/commit/b098caa5e4 - -commit be81495c16a62979f78a91fe8ed34dbdc82e37db - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-31 19:42:01 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-31 19:42:01 +0900 - - Silence dozens of useless warnings from `nm` on macOS - -commit 337189598af28297402b57df5ed1104ed336c15c - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-31 16:39:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-31 16:39:33 +0900 - - Fix a broken matrix (#7207) - - $arch and $configure seem to be just ignored in #7205. - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 6d1077974f39f216c80217f4957f089f3aa2094f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-31 15:44:24 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-31 15:44:24 +0900 - - Use matrix.entry for the Ubuntu workflow (#7205) - - This seems easier to understand. - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 5b67c15cd837fb4ffeea1863c711a32522387213 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2022-12-27 15:22:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-31 13:14:06 +0900 - - [ruby/openssl] [DOC] Remove repeated example from Digest - - https://github.com/ruby/openssl/commit/5a36cc3cb2 - -commit fe7d4eed2511ff64f263d9f29cbf0dcbd4c3a026 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-31 10:57:38 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-31 13:14:05 +0900 - - Manually merged https://github.com/ruby/net-http/pull/106 - - Co-authored-by: Peter Zhu <peter@peterzhu.ca> - Co-authored-by: BurdetteLamar <burdettelamar@yahoo.com> - -commit 0ee819b71ddab62699ab8b0ae14685d45781d28a - Author: Charles Oliver Nutter <headius@headius.com> - AuthorDate: 2023-01-13 17:55:52 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-31 13:14:05 +0900 - - Initial move to SnakeYAML Engine - - See jruby/jruby#7570 for some of the justification for this move. We only - require the parser from SnakeYAML, but in the original form it is - encumbered with Java object serialization code that keeps getting - flagged as a CVE risk. We disagree with the assessment, at least - as it pertains to JRuby (we do not use the code in question) but - our inclusion of the library continues to get flagged by auditing - tools. - - This commit starts the process of moving to the successor library, - SnakeYAML Engine. The parser API is largely unchanged, except as - seen in this commit. No Java exceptions are thrown, but a number - of Psych tests fail (possibly due to Engine being YAML 1.2 only). - -commit 29133794a3b2aea1e3f3451cd3720176ce75ed1f - Author: Charles Oliver Nutter <headius@headius.com> - AuthorDate: 2023-01-19 02:32:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-31 13:14:05 +0900 - - [ruby/psych] Update for stricter 1.2 syntax - - This allows these tests to pass on SnakeYAML Engine -- which is a - 1.2-only YAML library -- while still passing on libyaml 1.1. - - https://github.com/ruby/psych/commit/f44269fc9b - -commit b0b61623ad890e723726b3213354634fcc5cdb71 - Author: NARUSE, Yui <naruse@airemix.jp> - AuthorDate: 2023-01-18 17:57:03 +0900 - Commit: NARUSE, Yui <naruse@airemix.jp> - CommitDate: 2023-01-31 10:53:57 +0900 - - Add quotes to backport field - -commit d3822c9a8aa91151bd040d5635b723ff80bc1886 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-31 09:35:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-31 10:49:08 +0900 - - Merge RubyGems/Bundler master. - - Pick from https://github.com/rubygems/rubygems/commit/5ace20dbecfeaf09fba5f616193f3cfcff70ba00 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7203 - -commit 4cbfd87e5a8464db42657ee0019f9bd78c15c05c - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-01-31 02:10:56 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-31 10:49:08 +0900 - - [rubygems/rubygems] Allow disabling RubyGems require decorations - - Currently Bundler needs to do cumbersome operations to revert custom - RubyGems require on a `bundler/setup` context. This causes issues when - third party gems also monkeypatch require, since Bundler will also undo - those decorations. - - This commit allows it to use the simpler approach of properly telling - RubyGems that it needs to default to built-in require without any extra - magic. - - https://github.com/rubygems/rubygems/commit/1df5009e14 - - Co-authored-by: Xavier Noria <fxn@hashref.com> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7203 - -commit 022acb9593c09a9e358215a80448b426ee366ac0 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-01-26 02:07:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-31 10:49:08 +0900 - - [rubygems/rubygems] Don't load Bundler from RubyGems tests - - https://github.com/rubygems/rubygems/commit/c2e4cb7b5e - - Notes: - Merged: https://github.com/ruby/ruby/pull/7203 - -commit 927141a555c0eb5ee23b3dc9412d07b53f25673e - Author: Mike Dalessio <mike.dalessio@gmail.com> - AuthorDate: 2023-01-29 06:05:57 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-31 10:49:08 +0900 - - [rubygems/rubygems] Add test for old lockfile with new ruby version - - Given an existing application using native gems (e.g., nokogiri) - And a lockfile generated with a stable ruby version - When we test the application against ruby-head and `bundle install` - Then bundler should fall back to the generic ruby platform gem - - Note that this test has been passing since 45931ac9 - - https://github.com/rubygems/rubygems/commit/0ecc6de378 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7203 - -commit 369ed03cd4915dd751b1c5dc1f8cae73bdc0702d - Author: Tim Bates <tbates@redarc.com.au> - AuthorDate: 2023-01-24 15:23:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-31 10:49:08 +0900 - - [rubygems/rubygems] Fix issue with extensions not compiling properly using inline gemfile - - https://github.com/rubygems/rubygems/commit/fa6e6ea95c - - Notes: - Merged: https://github.com/ruby/ruby/pull/7203 - -commit 70eedef32aa3e6f2a95fee7ce2582c247d274e90 - Author: Étienne Barrié <etienne.barrie@gmail.com> - AuthorDate: 2023-01-17 23:27:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-31 09:33:49 +0900 - - [ruby/reline] Splat is always an Array - - https://github.com/ruby/reline/commit/82095bd62b - -commit 0285aa87f1ab8f54301d3fb2a6c4a677ffb50843 - Author: Eric Wong <normal@ruby-lang.org> - AuthorDate: 2023-01-31 07:50:37 +0900 - Commit: Eric Wong <normal@ruby-lang.org> - CommitDate: 2023-01-31 08:43:15 +0900 - - file.c: add some endif labels where appropriate - - "Appropriate" for me being ifdefs which: - - 1) span enough lines to be hard-to-follow (I need big fonts to see) - - 2) nested within other ifdefs, or within large functions - (I have a short attention span) - - rb_file_expand_path_internal is the prime example of a large - function I struggle to understand due to the amount of - platform-specific ifdefs. Hopefully this helps others with poor - vision and/or short attention spans. - -commit 3a7367ccc319499127ead147e5a08f769e44208e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-10 21:19:58 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-31 06:33:16 +0900 - - mkconfig: Map `includedir` only for system ruby - - Only when installing to the system path on macOS, prepend '$(SDKROOT)' - and remap `includedir`. - Fix https://github.com/rbenv/ruby-build/discussions/2123 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7197 - -commit 344c16eba40457f937c6558299f52bc97d6f3ce7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-31 06:14:18 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-01-31 06:18:19 +0900 - - Avoid using a weird syntax for documentation - - Following up 465bd972ec2. - - If the actual implementation still resides in C, it should be - documented in C just like all other places. - -commit 006682d3915ce065687c3d54a0b1eb91439b28e9 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-31 06:12:06 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-01-31 06:12:34 +0900 - - Avoid leaving an uneeded comment - - 465bd972ec2 didn't need to leave the obsoleted code. - -commit 07d1b3ddc3995a4dee4eca10e8710253f7881405 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-01-31 05:54:09 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-31 05:54:09 +0900 - - YJIT: Add splat optimized_send (#7167) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit b32e1169c948f0e4cd63f2c75929516106942594 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-01-31 05:51:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-31 05:51:55 +0900 - - YJIT: Initial implementation of splat with optional params (#7166) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit c4cc3be195825e47a66c7b919454c520e49ea307 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-31 03:47:56 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-31 04:55:20 +0900 - - Remove dead code in shapes.c and shapes.h - - Notes: - Merged: https://github.com/ruby/ruby/pull/7200 - -commit 2e0f3b5546854c98174d4210c0e06c78c8294f98 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-31 04:16:33 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-31 04:16:33 +0900 - - YJIT: Fix BorrowMutError on GC.compact (#7176) - - YJIT: Fix BorrowMutError - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit bc0dc9d40e20cd3d0a1dd0b3fae061aae34d5a33 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-31 03:55:00 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-31 03:55:00 +0900 - - YJIT: Skip defer_compilation for fixnums if possible (#7168) - - * YJIT: Skip defer_compilation for fixnums if possible - - * YJIT: It should be Some(false) - - * YJIT: Define two_fixnums_on_stack on Context - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit e1ffafb2855e808fea05e150c28665bb365f1990 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-31 02:50:08 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-31 02:50:08 +0900 - - YJIT: Inline return address callback (#7198) - - This makes it so that the generator and the output code read in the same - order. I think it reads better this way. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit cb060062137ed73313cf6c175e968aabd7bfa243 - Author: Mat Sadler <mat@sourcetagsandcodes.com> - AuthorDate: 2023-01-28 12:59:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-31 02:39:48 +0900 - - [rubygems/rubygems] normalise manifest path from cargo on windows - - https://github.com/rubygems/rubygems/commit/23b5ca5fc4 - -commit c5a34f5b566a5d89dd5fa311e75f8cf30d5dbe66 - Author: Mat Sadler <mat@sourcetagsandcodes.com> - AuthorDate: 2023-01-27 13:32:05 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-31 02:39:48 +0900 - - [rubygems/rubygems] better error message if cargo metadata doesn't contain the package we expect - - https://github.com/rubygems/rubygems/commit/cb7e6d1577 - -commit b4defea362278a38a4f7c86a86c5c44fff173e8b - Author: Mat Sadler <mat@sourcetagsandcodes.com> - AuthorDate: 2023-01-23 15:46:22 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-31 02:39:47 +0900 - - [rubygems/rubygems] install rust extensions into expected directory nesting - - https://github.com/rubygems/rubygems/commit/85ea86d348 - -commit ca951f671920b64c8275ffccdc680848f60cbede - Author: Mat Sadler <mat@sourcetagsandcodes.com> - AuthorDate: 2023-01-23 14:16:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-31 02:39:47 +0900 - - [rubygems/rubygems] use cargo to get crate name - - the final copying of the extension into place has been slimmed - down, reflecting that it only needs to copy a single file, rather - than replicating the more involved process used for a C ext - - this also refactors #build so that #cargo_crate_name only needs - to be called once, and hopefully the build flow is easier to - understand - - https://github.com/rubygems/rubygems/commit/5a0d7f2e6c - -commit 00e1ee4a7eb9f1703ddaf15158fefe0f7b594839 - Author: Mat Sadler <mat@sourcetagsandcodes.com> - AuthorDate: 2023-01-23 15:44:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-31 02:39:46 +0900 - - [rubygems/rubygems] don't force Cargo.lock to be in gem root - - https://github.com/rubygems/rubygems/commit/371044c0ab - -commit 0c2b43462f96baac06f65f1f29b3b2269ea51435 - Author: Mat Sadler <mat@sourcetagsandcodes.com> - AuthorDate: 2023-01-23 15:43:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-31 02:39:46 +0900 - - [rubygems/rubygems] remove unused files in cargo builder test fixtures - - https://github.com/rubygems/rubygems/commit/233847513b - -commit eccfc978fd6f65332eb70c9a46fbb4d5110bbe0a - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-01-28 04:08:49 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-01-31 01:51:12 +0900 - - Fix parsing of regexps that toggle extended mode on/off inside regexp - - This was broken in ec3542229b29ec93062e9d90e877ea29d3c19472. That commit - didn't handle cases where extended mode was turned on/off inside the - regexp. There are two ways to turn extended mode on/off: - - ``` - /(?-x:#y)#z - /x =~ '#y' - - /(?-x)#y(?x)#z - /x =~ '#y' - ``` - - These can be nested inside the same regexp: - - ``` - /(?-x:(?x)#x - (?-x)#y)#z - /x =~ '#y' - ``` - - As you can probably imagine, this makes handling these regexps - somewhat complex. Due to the nesting inside portions of regexps, - the unassign_nonascii function needs to be recursive. In - recursive mode, it needs to track both opening and closing - parentheses, similar to how it already tracked opening and - closing brackets for character classes. - - When scanning the regexp and coming to `(?` not followed by `#`, - scan for options, and use `x` and `i` to determine whether to - turn on or off extended mode. For `:`, indicting only the - current regexp section should have the extended mode - switched, recurse with the extended mode set or unset. For `)`, - indicating the remainder of the regexp (or current regexp portion - if already recursing) should turn extended mode on or off, just - change the extended mode flag and keep scanning. - - While testing this, I noticed that `a`, `d`, and `u` are accepted - as options, in addition to `i`, `m`, and `x`, but I can't see - where those options are documented. I'm not sure whether or not - handling `a`, `d`, and `u` as options is a bug. - - Fixes [Bug #19379] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7192 - -commit 3f54d09a5b8b6e4fd734abc8911e170d5967b5b0 - Author: Jean Boussier <byroot@ruby-lang.org> - AuthorDate: 2023-01-30 19:03:50 +0900 - Commit: Jean Boussier <jean.boussier@gmail.com> - CommitDate: 2023-01-30 22:42:40 +0900 - - bignum.c: rb_int_parse_cstr handle `0` strings - - [Bug #19390] - - We shouldn't check the string length when skipping zeros, as the - string might only contains zero characters, resulting in an empty string. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7196 - -commit 4bc343b4365fb4d3755e2f3fa5ac63c16a8cb755 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-30 15:54:43 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-30 21:55:37 +0900 - - Extract check for RSTRING_SOCKLEN - - Notes: - Merged: https://github.com/ruby/ruby/pull/7195 - -commit b432867429d8a311b2c73230b5cdd4833b972337 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-30 16:55:14 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-30 16:55:14 +0900 - - Skip OpenSSL::TestHMAC#test_dup when running with RHEL9 - -commit 4ffef59bb1c83b0e552b3e50b6bb1c1a34673d1c - Author: Luke Gruber <luke.gru@gmail.com> - AuthorDate: 2023-01-29 10:01:49 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-29 10:01:49 +0900 - - [DOC] Make changes to docs in ractor.rb (#7180) - - * Make changes to docs in ractor.rb - - Mainly English changes to make things more clear, and to fix minor - non-idiomatic phrases. Also clarified difference between frozen and - shareable objects. - - * More minor changes to Ractor docs. - - Notes: - Merged-By: zzak <zzakscott@gmail.com> - -commit 8250b4679453c095eab2f60d9147ca2fe4da32c6 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2023-01-29 05:42:08 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-29 06:41:15 +0900 - - [ruby/net-http] Correct doc error - - https://github.com/ruby/net-http/commit/dc006d8419 - -commit 21dced8b01823a991829b66ffdc8ffc635965c76 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-28 21:59:54 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-28 22:00:08 +0900 - - [ruby/stringio] [Bug #19389] Fix chomping with longer separator - - https://github.com/ruby/stringio/commit/eb322a9716 - -commit 8429134d0d942f89fa022af38e065eb33c83523a - Author: Daniel Colson <danieljamescolson@gmail.com> - AuthorDate: 2023-01-27 10:39:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-28 06:06:39 +0900 - - [rubygems/rubygems] Don't warn on bundler binstubs --standalone --all - - Prior to this commit `bundle binstubs --standalone --all` would output a - warning about not being able to generate a standalone binstub for - bundler. - - This warning predates the `--all` option, and I don't think it makes - sense in this context. The warning makes good sense when explicitly - trying to generate a bundler standalone binstub with `bundle binstubs - bundler --standalone`, since that command won't do what the user might - have expected. But `--all` is not specifically asking for bundler, and - having it report each time that the bundler binstubs could not be - generated does not seem particularly helpful. The only way to make that - warning go away would be to stop using `--standalone --all`. - - This commit skips the warning when running with the `--all` option. - - https://github.com/rubygems/rubygems/commit/e6a72e19eb - -commit 7d4395cb690c4b6be41bc51b25a8a5cda6210a81 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-19 05:58:35 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-01-28 02:28:09 +0900 - - YJIT: Fix shared/static library symbol leaks - - Rust 1.58.0 unfortunately doesn't provide facilities to control symbol - visibility/presence, but we care about controlling the list of - symbols exported from libruby-static.a and libruby.so. - - This commit uses `ld -r` to make a single object out of rustc's - staticlib output, libyjit.a. This moves libyjit.a out of MAINLIBS and adds - libyjit.o into COMMONOBJS, which obviates the code for merging libyjit.a - into libruby-static.a. The odd appearance of libyjit.a in SOLIBS is also - gone. - - To filter out symbols we do not want to export on ELF platforms, we use - objcopy after the partial link. On darwin, we supply a symbol list to - the linker which takes care of hiding unprefixed symbols. - - [Bug #19255] - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7115 - -commit e7e48e8a667614c8264993c746ad84b92de997fd - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-13 07:07:00 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-01-28 02:28:09 +0900 - - configure: Keep OBJCOPY even when visibility options are available - - YJIT will need it to address symbol leakage issue. Fallback to `:` when - OBJCOPY is not available on the system. - - Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7115 - -commit 17c8bf2c63192036058b03a04edf7a8478e47833 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-13 08:38:00 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-01-28 02:28:09 +0900 - - configure: Don't use use LD=clang, ld takes different flags - - This was a difference from using a GNU toolchain previously. It wasn't a - problem because we don't invoke $(LD) in the Makefile currently. YJIT - will want to invoke LD, so needs this consistency. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7115 - -commit 47b66a5acd1511089ac9585371d93e1b5ea07232 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-25 22:01:10 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-27 20:07:06 +0900 - - [ruby/bigdecimal] Add truffleruby in CI - - https://github.com/ruby/bigdecimal/commit/5a25e26e08 - -commit 71256caf7fddfd2e109d433e68c6fbd77a16631c - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-01-26 12:20:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-27 11:31:41 +0900 - - [rubygems/rubygems] Update the list of SPDX licence identifiers - - https://github.com/rubygems/rubygems/commit/18a9b0dc7e - -commit 06e30df4083779df7981105167e908fc780454fd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-07 18:45:15 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-27 11:31:10 +0900 - - [ruby/syntax_suggest] Hide internal document and detail of `Kernel` monkey patching - - https://bugs.ruby-lang.org/issues/19285 - - https://github.com/ruby/syntax_suggest/commit/25ca82f8f9 - -commit f49bb1505b854253b4f993ca9b95836bde37feb5 - Author: Khem Raj <raj.khem@gmail.com> - AuthorDate: 2023-01-25 10:54:33 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-27 11:30:13 +0900 - - [ruby/fiddle] fiddle: Use C11 _Alignof to define ALIGN_OF when - possible - (https://github.com/ruby/fiddle/pull/120) - - WG14 N2350 made very clear that it is an UB having type definitions - within "offsetof" [1]. This patch enhances the implementation of macro - ALIGN_OF to use builtin "_Alignof" to avoid undefined behavior when - using std=c11 or newer - - clang 16+ has started to flag this [2] - - Fixes build when using -std >= gnu11 and using clang16+ - - Older compilers gcc < 4.9 or clang < 8 has buggy _Alignof even though it - may support C11, exclude those compiler versions - - [1] https://www.open-std.org/jtc1/sc22/wg14/www/docs/n2350.htm - [2] https://reviews.llvm.org/D133574 - - Signed-off-by: Khem Raj <raj.khem@gmail.com> - - https://github.com/ruby/fiddle/commit/ad6c9aa826 - -commit f4609b6bc442bebee7bad2ee8d4bef46b288b7ba - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2022-12-28 07:23:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-27 11:30:13 +0900 - - [ruby/fiddle] Fix comment formatting - - https://github.com/ruby/fiddle/commit/36b2432575 - -commit 1df7f359d1ce916b34d141e6fbc0f591a2bc8428 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2022-12-28 04:19:25 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-27 11:30:13 +0900 - - [ruby/fiddle] Update documentation - (https://github.com/ruby/fiddle/pull/119) - - The documentation for `Fiddle.dlwrap` and `Fiddle.dlunwrap` were not - very accurate and pretty confusing. This commit updates the - documentation so it's easier to understand what the methods do. - -commit 967dec5d619f2a416f94a623abd91d7d0ee99751 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-04 17:28:27 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-27 11:30:13 +0900 - - [ruby/openssl] Added CoreAssertions - - https://github.com/ruby/openssl/commit/520601e11d - - This commits swtich to use ruby/ruby's envutil.rb instead of - vendored in openssl repo. - -commit 5afc8301309ec660c94438d967eea1bf1235a67c - Author: Andrew Konchin <andry.konchin@gmail.com> - AuthorDate: 2023-01-04 02:24:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-27 11:30:13 +0900 - - [ruby/openssl] Do not require test file in a forked process in tests - - https://github.com/ruby/openssl/commit/ae784673d7 - -commit 1b06cd3f09183c14d15ceaada57e425e12a6f3b2 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-01-27 10:49:26 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-27 10:49:26 +0900 - - Pass through `line_offset` argument correctly (but it was always 0). (#7177) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 70829928cb67829d572e124de441013105e63aa9 - Author: Samuel Giddins <segiddins@segiddins.me> - AuthorDate: 2023-01-26 12:30:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-27 06:41:48 +0900 - - [rubygems/rubygems] Deprecate Gem::List - - It is unused, we will remove it in the next major version - - https://github.com/rubygems/rubygems/commit/c3f6c27d6d - -commit 88f2b94065be3fcd6769a3f132cfee8ecfb663b8 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-01-27 01:04:55 +0900 - Commit: Aaron Patterson <tenderlove@ruby-lang.org> - CommitDate: 2023-01-27 01:04:55 +0900 - - Revert "Limit maximum number of IVs on a shape" - - This reverts commit 78fcc9847a9db6d42c8c263154ec05903a370b6b. - -commit 6422fef90c30a9662392a918533851f9ca41405e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-25 16:09:40 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-26 16:31:08 +0900 - - Fix `target_cpu` at runtime - - Notes: - Merged: https://github.com/ruby/ruby/pull/7186 - -commit 9794e49c88b507e1bde102edc5df0add7b3135f3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-25 15:30:29 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-26 16:31:08 +0900 - - Link RUBYSPEC_CAPIEXT against the built library - - Notes: - Merged: https://github.com/ruby/ruby/pull/7186 - -commit 00ee1d128f55e8bc3a101680336754026575c839 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-25 13:20:39 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-26 16:31:08 +0900 - - Get rid of duplicate "--disable=gems" options - - Notes: - Merged: https://github.com/ruby/ruby/pull/7186 - -commit 545ade21a2e1ed303b8c7a0b804a3139d674ce82 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-26 14:13:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-26 15:32:29 +0900 - - Enable code-coverage result for test-spec - - Notes: - Merged: https://github.com/ruby/ruby/pull/7187 - -commit 2d9812713171097eb4a3f38e49d9be39d90da2f6 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-26 14:05:01 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-26 14:05:01 +0900 - - Filter spec directory for code coverage - -commit 6608d47bed660a3f5ea4c10ac6410747152db546 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-26 13:07:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-26 13:52:20 +0900 - - Enable code-coverage result for test-syntax-suggest - - Notes: - Merged: https://github.com/ruby/ruby/pull/7185 - -commit 069b6f88e245f380e1b0e8fba7137f6009441e07 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-26 11:16:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-26 13:52:20 +0900 - - Ignore all of tool directory from code coverage, It contains tool/test and etc. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7185 - -commit 8662d70a8b7a30e567358b0931dad61b2a1d4176 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-26 11:02:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-26 13:52:20 +0900 - - Ignore vendored libraries by rubygems from code coverage - - Notes: - Merged: https://github.com/ruby/ruby/pull/7185 - -commit 98e84f3f7a1fa69530c67ab9bc63271b812718ea - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-26 10:50:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-26 13:52:20 +0900 - - filter coverage result with vendored libraries and test code - - Notes: - Merged: https://github.com/ruby/ruby/pull/7185 - -commit eb2670e32df1bfd63167748f81f480a0dc4f0f72 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-26 10:17:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-26 13:27:52 +0900 - - [ruby/reline] Revert "correct Win32API capitalization for JRuby" - - This reverts commit https://github.com/ruby/reline/commit/d6e7c9e1d9af. - - https://github.com/ruby/reline/commit/c47a5b684c - -commit be6a347ace1926683890c7ef103767bc6d58fc11 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-20 23:18:56 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-26 12:50:39 +0900 - - Need gemspec files instead of cloned directories - - Notes: - Merged: https://github.com/ruby/ruby/pull/7146 - -commit 7eef4547b19c9a2dc2621755c4c0d45284ec6c25 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-20 18:13:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-26 12:50:39 +0900 - - Fixed clone name - - Notes: - Merged: https://github.com/ruby/ruby/pull/7146 - -commit 7a4f7fc14d8331f90177a8ba47fb682fecd684b1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-19 21:55:44 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-26 12:50:39 +0900 - - Use timestamp files to track test revision of bundled gems - - Notes: - Merged: https://github.com/ruby/ruby/pull/7146 - -commit 17f5631c6ea118b9ce0e8776dc50c7b1dcdaf596 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-18 20:36:31 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-26 12:50:39 +0900 - - [Bug #19340] Fix bundle gems with test revision - - Build temporary gem package from cloned repository if test revision is - set. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7146 - -commit 78fcc9847a9db6d42c8c263154ec05903a370b6b - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-01-26 03:45:32 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-01-26 04:48:28 +0900 - - Limit maximum number of IVs on a shape - - Create SHAPE_MAX_NUM_IVS (currently 50) and limit all shapes to that - number of IVs. When a shape has more than 50 IVs, fallback to the - obj_too_complex shape which uses hash lookup for ivs. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7183 - -commit 5e1e5af2e737bdc5537b4d2025d2ae8e57df3cdb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-25 16:45:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-25 16:47:05 +0900 - - Support simplecov-0.22.0. - - simplecov-0.22.0 no longer support pre-0.18 result format. result data needs - `lines` key for coverage data. - -commit e82cef17624556b995e2a3d6de4908deec6f11f8 - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2023-01-23 23:54:27 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-01-25 10:52:37 +0900 - - Remove not used argument from tokenize_ident - - This has not been used since 5e59be3eddd2ce28610ec8d1b42845cde0080833 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7179 - -commit 5eeebd68cf8089a02a3dd553664c60a224b7e521 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-21 05:45:31 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-25 03:34:21 +0900 - - Remove function ary_recycle_hash - - Freeing the memory of a Hash should be done by the garbage collector - and not by array functions. This could potentially leak memory if - ary_recycle_hash was not implemented properly. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7165 - -commit 5a73e131d7458b3ede3d0f5a4447989a43ee915b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-17 10:08:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-24 16:36:33 +0900 - - Add tests for variables in `END` block shared with the toplevel - - Notes: - Merged: https://github.com/ruby/ruby/pull/7136 - -commit fe733fb668d95ab6035943fccad87aafc63d486f - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-23 19:40:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-23 19:40:42 +0900 - - svn.ruby-lang.org is already EOL - -commit a22ed3e99dbb74003f20e175cd1956062e97f230 - Author: Yusuke Nakamura <yusuke1994525@gmail.com> - AuthorDate: 2023-01-18 20:40:09 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-23 17:06:15 +0900 - - Fix homepage url in gemspec - - GitHub Pages now hosted on *.github.io - -commit 4981206b494b1392df451ff4655126f0d7152fa7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-23 15:14:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-23 15:14:02 +0900 - - update-coverage needs to build ruby and all C-ext libraries - -commit d9fd0483510612c62b927b6db3da4682d03ea40a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-23 12:27:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-23 14:55:46 +0900 - - [rubygems/rubygems] blade is hosted under ruby-lang.org now - - https://github.com/rubygems/rubygems/commit/00fdef8a41 - -commit 5abb2ef1532e52f3e5fb63ea25e90a72c8e7d581 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-23 12:29:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-23 13:07:29 +0900 - - blade is hosted under ruby-lang.org now - -commit d8751c0aa7dae6180cee849c0750f58515c13cbe - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-23 12:26:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-23 12:41:54 +0900 - - [ruby/cgi] blade is hosted under ruby-lang.org now - - https://github.com/ruby/cgi/commit/826ba3140c - -commit 93bb415516dec2743c61a647532a061e0555501b - Author: Talal Al-Humaidi <77169738+Talhumaidi@users.noreply.github.com> - AuthorDate: 2023-01-23 11:48:44 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-23 11:48:44 +0900 - - [DOC] Change local method to local variable in assignment docs - - Notes: - Merged: https://github.com/ruby/ruby/pull/7173 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 8fded5f5d12be958ca803627a541e5a5d9323586 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-01-22 23:04:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-23 11:07:23 +0900 - - [ruby/psych] Fix RestrictedYAMLTree allowing the Symbol class should allow all symbols - - Ref: https://github.com/ruby/psych/pull/495 - - That's how it works for `safe_load`: - ```ruby - >> YAML.safe_load(':foo', permitted_classes: [Symbol]) - => :foo - ``` - - So `safe_dump` should mirror that. - - https://github.com/ruby/psych/commit/592a75a656 - -commit 20a85ab6119964d1ff129f9c6676fa2a7b2a2be4 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2023-01-22 18:53:02 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-22 18:53:02 +0900 - - Fix Integer#ceildiv to respect #coerce (#7118) - - Fixes [Bug #19343] - - Notes: - Merged-By: mrkn <mrkn@ruby-lang.org> - -commit f5ea43a2e61789357e9c4b374b4bc6756abeae17 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-01-22 09:49:13 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-22 09:49:13 +0900 - - More coverage tests & specs. (#7171) - - * Add spec for eval and line coverage. - - * Add test for main file coverage. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 2c93c554019ebdc394d3c51c6d925620d3005f84 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-01-22 06:51:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-22 06:51:59 +0900 - - Ensure main file has default coverage if required. (#7169) - - * Extract common code for coverage setup. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 3e7fdf29532333667271f01fff84c10ec80822e1 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-01-21 20:13:16 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-21 20:13:16 +0900 - - Windows build instructions documentation. (#6956) - - Windows build instructions. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 5cdf312d2cc7465fb7f5c36b01f868f059b69ac3 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-01-21 20:12:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-21 20:12:17 +0900 - - Add `doc/distribution.md` to help reduce some of the confusion. (#6856) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 06b62cbbdd560c6210d48a50ba99cfdc2f110dfe - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-01-21 03:57:23 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-01-21 07:11:05 +0900 - - Add `offsetof` so we can get the offset of members - - I want to get the offset of fields inside structs, but I don't want to - instantiate the struct. I need to embed the offsets inside machine - code, and I can't get the offsets without calling `new` on the struct. - - This commit adds an `offset` method so you can get the offset of a - member without instantiating anything. You can do: - - ```ruby - C.rb_control_frame_t.offsetof(:sp) #=> 8 - ``` - - I don't think this implementation is perfect, you can only get immediate - fields. But it is better than nothing! - - Notes: - Merged: https://github.com/ruby/ruby/pull/7163 - -commit 887d21613cb62f7e964474131dcdf73034f879af - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-21 06:07:03 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-21 06:07:03 +0900 - - YJIT: Avoid BorrowError on GC.compact (#7164) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 4e037075ae7bd858ee59833a39bb61a5bfefa98c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-21 05:56:44 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-21 05:58:17 +0900 - - Fix typo in RHASH_ST_CLEAR - - We should be setting as.st and not as.ar. - -commit ffd52412ab813854d134dbbc2b60f698fe536487 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2023-01-21 01:33:00 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-01-21 01:36:06 +0900 - - Document thread-safety issues with Hash default_proc - - Fixes [Bug #19237] - -commit 0457e43423b8ecf2653125a32dad5e272ce55e25 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-01-20 23:51:19 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-21 01:01:03 +0900 - - Remove unused struct member thgroup->group - - Notes: - Merged: https://github.com/ruby/ruby/pull/7162 - -commit 36fa4f13ca49033aaaa733ef764d1d936667400f - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-01-21 00:57:41 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-21 00:57:41 +0900 - - YJIT: get rid of unneeded `.into()` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7158 - - Merged-By: XrXr - -commit 15328302dc7154927ebbcec880c9ec200862a1cd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-20 23:04:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-21 00:30:34 +0900 - - In `UNALIGNED_MEMBER_PTR` cast through `void` pointer - - Suppress warnings shown even with `-Waddress-of-packed-member` - disabled in gcc 11. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7161 - -commit f0f2535c4daad91872c9f133f8812c421edf0dbb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-20 20:24:49 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-21 00:30:34 +0900 - - Add `queue_list` and `szqueue_list` macros - - Notes: - Merged: https://github.com/ruby/ruby/pull/7161 - -commit 056e7a0154fe4c71eca3726c878bb3da7e4138f8 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-20 04:47:17 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-20 22:51:39 +0900 - - Make all of the references of iseq movable - - Notes: - Merged: https://github.com/ruby/ruby/pull/7156 - -commit 76e3d853ab33d31ab9d5ae6f88b406841e8dbbf2 - Author: tompng <tomoyapenguin@gmail.com> - AuthorDate: 2022-09-03 04:42:23 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-20 22:40:16 +0900 - - [ruby/reline] Add autoindent test for indent after bracket and newline - - https://github.com/ruby/reline/commit/3f3da7d0e2 - -commit 4241b3cf2db3eb4a911de4485b60a4766237746b - Author: tompng <tomoyapenguin@gmail.com> - AuthorDate: 2022-08-03 15:25:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-20 22:40:15 +0900 - - [ruby/reline] accept new_indent > cursor_max - - https://github.com/ruby/reline/commit/61cc580da4 - -commit 0cc91871a81aeb3152fcb72b5a50bcee2f7d03b0 - Author: Josh Nichols <josh@technicalpickles.com> - AuthorDate: 2023-01-18 23:22:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-20 22:06:58 +0900 - - [rubygems/rubygems] Update bundle-exec man page for with_unbundled_env - - `with_clean_env` has been deprecated in `with_unbundled_env`. It already generates a deprecation warning when it uses, but this man page was still referring to it. - -commit 53cd5796c529c73704d33de0cc1f8d2d9130dd87 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-20 12:45:03 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-20 19:39:57 +0900 - - [rubygems/rubygems] Clean test output - - The output from the command is mixed in this test, even when - successful. - Use the output as a part of the message on failure instead. - - https://github.com/rubygems/rubygems/commit/960509a133 - -commit cce3960964784e57cba14762503c5fdd688e9919 - Author: Shugo Maeda <shugo@ruby-lang.org> - AuthorDate: 2023-01-20 16:09:58 +0900 - Commit: Shugo Maeda <shugo.maeda@gmail.com> - CommitDate: 2023-01-20 18:02:37 +0900 - - [Feature #19314] Add new arguments of String#bytesplice - - bytesplice(index, length, str, str_index, str_length) -> string - bytesplice(range, str, str_range) -> string - - In these forms, the content of +self+ is replaced by str.byteslice(str_index, str_length) or str.byteslice(str_range); however the substring of +str+ is not allocated as a new string. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7160 - -commit 845f6275b2b7d9ad24e45e3a0bfabeea25555bbc - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-20 17:53:04 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-20 17:54:34 +0900 - - OpenSSL, libyaml and zlib is always required to build. see test/test_extlibs.rb - -commit 231b09f195575633d61c47159f94f9a8eee718e8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-20 17:51:02 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-20 17:54:34 +0900 - - Added supported versions to OpenSSL and libyaml - -commit 1edef08ddadf0bd76122f830ef7953cda61c78aa - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-20 17:45:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-20 17:54:22 +0900 - - Added version policy of BASERUBY - - [Misc #16671] - -commit 6aa9c84500ceb9859a4b9bf08d296d3377988454 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-20 17:42:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-20 17:42:50 +0900 - - Separate dependencies section from quick start - -commit ea10dea6c7cb2347a12228151795b14e79d96391 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-20 17:38:29 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-20 17:38:29 +0900 - - fixed wrong version of baseruby - -commit a0626e11aaedd298d367f4eefde3cf590e8010be - Author: Soutaro Matsumoto <matsumoto@soutaro.com> - AuthorDate: 2023-01-20 17:13:56 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-20 17:13:56 +0900 - - Bundle RBS 2.8.4 (#7159) - - Notes: - Merged-By: soutaro <matsumoto@soutaro.com> - -commit d80a574a04ab594e8a8f1fdf9e4506295306026b - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-01-20 16:05:11 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-20 16:05:11 +0900 - - Update bundled gems list at 2023-01-20 - -commit f66804e6f78ed4cf81896d2256743a820b05939a - Author: lukeg <luke.gru@gmail.com> - AuthorDate: 2023-01-15 06:52:29 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-20 06:25:20 +0900 - - don't allow setting class variable on module that's frozen [Bug #19341] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7124 - -commit bf3940a306c5292324caa0b4756b90411cc3cdf1 - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-01-20 03:58:43 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-01-20 06:10:58 +0900 - - YJIT: Refactor side_exits - - Notes: - Merged: https://github.com/ruby/ruby/pull/7155 - -commit 5ce0c13f181d7b2d50637758894bcbc357b0ce65 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-20 05:02:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-20 05:02:25 +0900 - - YJIT: Remove duplicated information in BranchTarget (#7151) - - Note: On the new code of yjit/src/core.rs:2178, we no longer leave the state `.block=None` but `.address=Some...`, which might be important. - - We assume it's actually not needed and take a risk here to minimize heap allocations, but in case it turns out to be necessary, we could signal/resurrect that state by introducing a new BranchTarget (or BranchShape) variant dedicated to it. - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 401aa9ddd1091f5b517dce37cd002bc2c37f5ac1 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-01-20 03:58:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-20 03:58:40 +0900 - - [ruby/net-http] [DOC] Header doc - (https://github.com/ruby/net-http/pull/104) - - https://github.com/ruby/net-http/commit/3308362d9b - -commit 762a3d80f77db0f96d3e01ccd1cc7b3891f0cfcf - Author: Jimmy Miller <jimmy.miller@shopify.com> - AuthorDate: 2023-01-20 03:42:49 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-20 03:42:49 +0900 - - Implement splat for cfuncs. Split exit exit cases to better capture where we are exiting (#6929) - - YJIT: Implement splat for cfuncs. Split exit cases - - This also implements a new check for ruby2keywords as the last - argument of a splat. This does mean that we generate more code, but in - actual benchmarks where we gained speed from this (binarytrees) I - don't see any significant slow down. I did have to struggle here with - the register allocator to find code that didn't allocate too many - registers. It's a bit hard when everything is implicit. But I think I - got to the minimal amount of copying and stuff given our current - allocation strategy. - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 8872ebec6a3edc8327b5f348656c73a52bceda4a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-20 02:22:02 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-20 02:22:02 +0900 - - Fix compilation warnings in thread_sync.c - - Fixes the following compilation warnings: - - thread_sync.c:908:48: warning: taking address of packed member of `struct rb_queue` may result in an unaligned pointer value [-Waddress-of-packed-member] - - thread_sync.c:1181:48: warning: taking address of packed member of `struct rb_queue` may result in an unaligned pointer value [-Waddress-of-packed-member] - -commit 9af84c95d7349ec609789c2be9acb3aaa020bfeb - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-19 01:37:45 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-20 01:23:35 +0900 - - Combine code paths for marking cc - - This commit avoids a separate code path for marking and moving the - callcache of the iseq. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7140 - -commit 41bf2354e30fc585a61528560c291fd8ee77d107 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-18 01:21:21 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-20 01:23:35 +0900 - - Add rb_gc_mark_and_move and implement on iseq - - This commit adds rb_gc_mark_and_move which takes a pointer to an object - and marks it during marking phase and updates references during compaction. - This allows for marking and reference updating to be combined into a - single function, which reduces code duplication and prevents bugs if - marking and reference updating goes out of sync. - - This commit also implements rb_gc_mark_and_move on iseq as an example. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7140 - -commit 6f3aff3961a4c5ce87e05096a1a9dcf1055b7647 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-19 15:35:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-20 00:26:52 +0900 - - [Bug #19289] Retain `ruby_abi_version` function - - A few extension libraries, to hide all symbols except for necessary to - load, hardcode the symbols to be exported in symbol list files for - linker without even checking by `have_func`. As a workaround for such - libraries, retain `ruby_abi_version` symbol always even in released - versions for now. - -commit dcc676a86e5fd882a5ed2e5345898e645ccea946 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-19 00:26:46 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-19 23:47:21 +0900 - - ci in iseq can only be object or null - - It looks like rb_callinfo in iseq can only be either a Ruby object or - null, since it cannot be allocated on the stack. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7147 - -commit f7b72462aa27716370c6bea1f2c240983aca9a55 - Author: Shugo Maeda <shugo@ruby-lang.org> - AuthorDate: 2023-01-19 17:13:07 +0900 - Commit: Shugo Maeda <shugo@ruby-lang.org> - CommitDate: 2023-01-19 17:13:07 +0900 - - String#bytesplice should return self - - In Feature #19314, we concluded that the return value of String#bytesplice - should be changed from the source string to the receiver, because the source - string is useless and confusing when extra arguments are added. - - This change should be included in Ruby 3.2.1. - -commit 4b42392f8ef66890359f128f0c934601c55a014f - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-19 08:25:41 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-01-19 10:52:19 +0900 - - YJIT: Use .as_side_exit() for jumps to counted exits - - Fewer cycles running nops when these jumps are not taken. Fixing all - these so when they get copy pasted in the future we save on padding. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7150 - -commit 4cf1d9b3b3edd78a3b6a8d0c3d4a1a68f4db170f - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-19 10:23:11 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-19 10:23:11 +0900 - - YJIT: Set RUST_BACKTRACE=1 on YJIT GitHub Actions (#7152) - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit edd00697a88892b477b498b796d9f62f9ec84e28 - Author: Samuel Williams <samuel.williams@oriontransfer.co.nz> - AuthorDate: 2023-01-19 07:59:51 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-19 07:59:51 +0900 - - Test some missing coverage too. (#7041) - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit 308942920f4e200468673be03c646f0645a84263 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-01-19 06:03:43 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-19 06:03:58 +0900 - - [ruby/net-http] [DOC] Enhanced RDoc for set_form - (https://github.com/ruby/net-http/pull/103) - - https://github.com/ruby/net-http/commit/f6506ff889 - -commit 6bb576fe759e3ef86b2ea484313013c51c39f388 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-01-19 05:41:28 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-19 05:41:28 +0900 - - YJIT: implement codegen for `String#empty?` (#7148) - - YJIT: implement codegen for String#empty? - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 0fd5a664e743c2ea506a83c5abed145a0734e7e6 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-17 21:07:36 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-19 01:54:34 +0900 - - Remove macro RHASH_ITER_LEV - - The function rb_hash_iter_lev doesn't exist as it was removed. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7138 - -commit cd97976328204263c464cf6846e9bafe6424da15 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-01-19 01:08:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-19 01:08:55 +0900 - - Add stats so we can keep track of x86 rel32 vs register calls (#7142) - - * Add stats so we can keep track of x86 rel32 vs register calls - - To know if we get that "prime real estate" as Alan put it. - - * Fix bug pointed by Alan - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 8e53f09baaec292e399afba5631a83cefbd63fd8 - Author: tompng <tomoyapenguin@gmail.com> - AuthorDate: 2023-01-09 02:06:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-18 23:49:29 +0900 - - [ruby/reline] Add constant MINIMUM_SCROLLBAR_HEIGHT for scrollbar rendering when dialog content is very long - - https://github.com/ruby/reline/commit/d4c95f89ec - -commit 976d72a9f51e90e554c0a31aad1768cc2f39f0b4 - Author: tompng <tomoyapenguin@gmail.com> - AuthorDate: 2022-12-20 02:30:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-18 23:49:28 +0900 - - [ruby/reline] Add scrollbar scroll-to-bottom test and fix existing scrollbar rendeing test - - https://github.com/ruby/reline/commit/268e02b155 - -commit a712f2a2a0846ffbac50bfa8cd8a66a6007948db - Author: tompng <tomoyapenguin@gmail.com> - AuthorDate: 2022-10-24 04:57:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-18 23:49:28 +0900 - - [ruby/reline] Fix dialog scrollbar rendering position and disappearing bug - - https://github.com/ruby/reline/commit/e21b69ade4 - -commit 4fa7d3832427ad5133838bc97be7ab2e4e832f70 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-17 01:50:00 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-18 22:49:32 +0900 - - Don't redefine RB_OBJ_WRITE - - RB_OBJ_WRITE already exists in rgengc.h, so we shouldn't redefine it in - gc.h. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7131 - -commit e3336e092977473c2c406fbfeb12279ced42102b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-18 08:26:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-18 21:59:41 +0900 - - Define RUBY_VERSION_IS_3_3 macro in rubyspec.h - - Notes: - Merged: https://github.com/ruby/ruby/pull/7145 - -commit d275adde780a4af2a8ee0ffd2826942a170444d1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-17 15:51:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-18 20:19:08 +0900 - - Pin simplecov-0.20.0 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7137 - -commit 18d8333c30ff84252231524e10f5a45b795e90b3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-17 15:33:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-18 20:19:08 +0900 - - Switch to use gem version of simplecov, not git clone - - Notes: - Merged: https://github.com/ruby/ruby/pull/7137 - -commit ba45be3c43c65e172a8b9d2d8dbfa369f894e500 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-18 16:14:00 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-18 16:14:00 +0900 - - Supressing warnings messages like: - - Ignoring debug-1.7.1 because its extensions are not built. Try: gem pristine debug --version 1.7. - - Revert "Clear gem paths for each test" - - This reverts commit 6698b580ddad8cfa8c5c86df9328472820d3ee6a. - -commit 5fc97f34c60f2242e1a81c01e8152a78c7463801 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-18 15:26:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-01-18 15:26:45 +0900 - - benchmark_driver v0.16.3 - - Some chruby-related features and bug fixes. - -commit 7e97e2bae47483cd8252b387b61123d243c41e18 - Author: Soutaro Matsumoto <matsumoto@soutaro.com> - AuthorDate: 2023-01-18 14:31:55 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-18 14:31:55 +0900 - - Update RBS commit hash (#7143) - - Use a commit at the top of RBS 2.8.3, not 3.0.0.dev.N. - - Notes: - Merged-By: soutaro <matsumoto@soutaro.com> - -commit 2d7e63954956645a4a050c78df71c8f4a56851d8 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-01-18 14:28:13 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-18 14:28:18 +0900 - - [ruby/reline] multiline_repl do not need to depend on RubyLex - (https://github.com/ruby/reline/pull/502) - - * multiline_repl do not need to depend on RubyLex - - * Add auto indent test - -commit 46066d0b96473589038810ac3aa19a1e26fdb837 - Author: Kaíque Kandy Koga <kaiquekandykoga@gmail.com> - AuthorDate: 2023-01-18 14:25:11 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-18 14:25:11 +0900 - - Change ArgumentError message when Comparable#clamp receives min value higher than max value - - Notes: - Merged: https://github.com/ruby/ruby/pull/6802 - - Merged-By: jeremyevans <code@jeremyevans.net> - -commit 8a771efec21c9dacad5bb8bf14b81c9d5cf2786c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-18 13:46:39 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-18 13:53:12 +0900 - - [ruby/psych] Bump up 5.0.2 - - https://github.com/ruby/psych/commit/a170b8eb46 - -commit a9bcc058bb4cd954e8406c93debb876983627ca9 - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-01-18 06:21:13 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-18 06:21:13 +0900 - - Update yjit.md - -commit df6b72b8ff7af16a56fa48f3b4abb1d8850f4d1c - Author: Stan Lo <stan.lo@shopify.com> - AuthorDate: 2023-01-17 05:42:51 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-17 22:01:19 +0900 - - Avoid checking interrupt when loading iseq - - The interrupt check will unintentionally release the VM lock when loading an iseq. - And this will cause issues with the `debug` gem's - [`ObjectSpace.each_iseq` method](https://github.com/ruby/debug/blob/0fcfc28acae33ec1c08068fb7c33703cfa681fa7/ext/debug/iseq_collector.c#L61-L67), - which wraps iseqs with a wrapper and exposes their internal states when they're actually not ready to be used. - - And when that happens, errors like this would occur and kill the `debug` gem's thread: - - ``` - DEBUGGER: ReaderThreadError: uninitialized InstructionSequence - ┃ DEBUGGER: Disconnected. - ┃ ["/opt/rubies/ruby-3.2.0/lib/ruby/gems/3.2.0/gems/debug-1.7.1/lib/debug/breakpoint.rb:247:in `absolute_path'", - ┃ "/opt/rubies/ruby-3.2.0/lib/ruby/gems/3.2.0/gems/debug-1.7.1/lib/debug/breakpoint.rb:247:in `block in iterate_iseq'", - ┃ "/opt/rubies/ruby-3.2.0/lib/ruby/gems/3.2.0/gems/debug-1.7.1/lib/debug/breakpoint.rb:246:in `each_iseq'", - ... - ``` - - A way to reproduce the issue is to satisfy these conditions at the same time: - - 1. `debug` gem calling `ObjectSpace.each_iseq` (e.g. [activating a `LineBreakpoint`](https://github.com/ruby/debug/blob/0fcfc28acae33ec1c08068fb7c33703cfa681fa7/lib/debug/breakpoint.rb#L246)). - 2. A large amount of iseq being loaded from another thread (possibly through the `bootsnap` gem). - 3. 1 and 2 iterating through the same iseq(s) at the same time. - - Because this issue requires external dependencies and a rather complicated timing setup to reproduce, I wasn't able to write a test case for it. - But here's some pseudo code to help reproduce it: - - ```rb - require "debug/session" - - Thread.new do - 100.times do - ObjectSpace.each_iseq do |iseq| - iseq.absolute_path - end - end - end - - sleep 0.1 - - load_a_bunch_of_iseq - possibly_through_bootsnap - ``` - - [Bug #19348] - - Co-authored-by: Peter Zhu <peter@peterzhu.ca> - -commit ed6fbb79e19bf401db0e85447fee955fd10a25c7 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-16 23:32:37 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-17 18:51:15 +0900 - - Fix crash when defining ivars on special constants - - [Bug #19339] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7129 - -commit 492d37fbbd3613b7fb180eec5298603760811e3b - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-17 17:27:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-17 17:46:27 +0900 - - [ruby/psych] Bump up 5.0.2.pre1 for testing - - https://github.com/ruby/psych/commit/67ec299c68 - -commit dd510da89a169baf8a104796925431a14b0920f1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-17 17:11:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-17 17:26:22 +0900 - - [ruby/psych] configure of libyaml couldn't detect "arm64-apple-darwin22" for build host. - - checking whether make sets $(MAKE)... (cached) yes - checking build system type... arm-apple-darwin21.6.0 - checking host system type... Invalid configuration `arm64-apple-darwin21': machine `arm64-apple' not recognized - configure: error: /bin/sh /Users/hsbt/Downloads/yaml-0.2.5/config/config.sub arm64-apple-darwin21 failed - *** extconf.rb failed *** - - https://github.com/ruby/psych/commit/ad1502202c - -commit 01e28afd0ab6432482d68bd8098ba2540cfdcbd3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-17 16:56:57 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-17 16:56:57 +0900 - - test-syntax-suggest is now part of make check - -commit aad1563c1a90af9ff01668d3f909d6dcb5624d9a - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-17 16:50:19 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-17 16:50:19 +0900 - - Added make exam to help message - -commit da7818e6820d41e9946aa58b68a14389a4402bb8 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-17 16:48:44 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-17 16:48:44 +0900 - - Added test-syntax-suggest to help message - -commit ff3c1d9e13b3684237df8e9e530fc672d0aa57c3 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-17 14:31:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-17 14:31:36 +0900 - - SimpleCov is hosted under simplecov-ruby org now - -commit 14fe7a081a8260bbbfc7929a14ec4187faaa3c25 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-17 06:23:08 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-01-17 07:32:15 +0900 - - YJIT: Use ThinLTO for Rust parts in release mode - - This reduces the code size of libyjit.a by a lot. On darwin it went from - 23 MiB to 12 MiB for me. I chose ThinLTO over fat LTO for the relatively - fast build time; in case we need to debug release-build-only problems - it won't be painful. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7134 - -commit b5725959184d6306b2ede1f16c9dd3dff4b2740c - Author: Alan Wu <alanwu@ruby-lang.org> - AuthorDate: 2023-01-17 05:45:51 +0900 - Commit: Alan Wu <alanwu@ruby-lang.org> - CommitDate: 2023-01-17 05:45:51 +0900 - - addr2line.c: Silence GCC 11 false -Wmaybe-uninitialized warning - - No warnings from GCC 12. - -commit e22a1fbe18fe8039137382655ca131c614aa808d - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-17 04:25:39 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-17 04:25:39 +0900 - - addr2line.c: Don't special-case DWARF 5 parsing with GCC - - While trying to fix YJIT's symbol hygiene issue over at GH-7115, I found - that addr2line.c's DWARF 5 parsing is half-disabled when building with - GCC. Rust's output contains some DW_AT_rnglists_base records, which the - disabled code reads. Without DW_AT_rnglists_base, it crashes when - generating a backtrace. - - In common Ruby build configurations, GCC opts to only use - DW_FORM_sec_offset for the range lists, and so it doesn't generate - DW_AT_rnglists_base records, so consuming GCC's DWARF 5 while building - with GCC was not a problem. - - However, even when building with GCC, we might need to parse DWARF 5 - generated by other compilers at runtime. They could come from C - extensions built by Clang, or come from Rust extensions. This - can happen even when building without YJIT. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7123 - - Merged-By: XrXr - -commit 30bd2a32faf2d592d2df821c65431ca5f5cec736 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-01-17 02:02:23 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-17 02:02:23 +0900 - - [DOC] Correction to RDoc for Regexp.new (#7130) - - Correction to RDoc for Regexp.new - - Notes: - Merged-By: BurdetteLamar <BurdetteLamar@Yahoo.com> - -commit a2748c500d776fe0386271b4458fa3fd1c0dd56d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-16 19:44:40 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-16 19:44:40 +0900 - - [DOC] Update `String#encode` special case - - This behavior has been slightly extended with the addition of - `String#scrub`. - -commit 11f28f3268f9234b6310bc659de7e46dfc5c0706 - Author: Martin Dürst <duerst@it.aoyama.ac.jp> - AuthorDate: 2023-01-16 16:25:04 +0900 - Commit: Martin Dürst <duerst@it.aoyama.ac.jp> - CommitDate: 2023-01-16 16:30:15 +0900 - - [DOC] Explain that transcoding to the same encoding just copies. - - This is a reenstatement of the explanation in commit - 463633e4a934a00f869086a6ffbf84c6cb8ad630 to partially - address Bug #19342. - -commit 468ce1488d26ffc92c940324794dc9257f72b5d2 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-15 22:19:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-16 13:38:58 +0900 - - [DOC] Use RDoc inclusions in transcode.c - - Notes: - Merged: https://github.com/ruby/ruby/pull/7126 - -commit 4617b40f8b8383554bf1d30c0699298b357b2011 - Author: Rick Hull <rick.hull@gmail.com> - AuthorDate: 2023-01-16 05:11:08 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-16 08:00:03 +0900 - - fix typo in comments / autodoc - - replace _socktype_ with _type_ in the comments - - Notes: - Merged: https://github.com/ruby/ruby/pull/7127 - -commit 6698b580ddad8cfa8c5c86df9328472820d3ee6a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-14 23:56:07 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-15 23:57:43 +0900 - - Clear gem paths for each test - - So that rubygems can find the bundled rake. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7122 - -commit 088132fb3382ec90934f48d7ac8f18a6cc165fe3 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-15 16:08:17 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-15 17:21:59 +0900 - - Do not depend on `REVISION_H` - - Disable for now, since this seems causing infinite rebuilding. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7125 - -commit 71ce7e1825c5b8fe08dd96cd77c6a379afd34256 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-15 13:03:27 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-15 13:03:27 +0900 - - [Bug #19335] `Integer#remainder` should respect `#coerce` (#7120) - - Also `Numeric#remainder` should. - - Notes: - Merged-By: mrkn <mrkn@ruby-lang.org> - -commit 5b26f76ad9a4305f889ddb267c38a39a74ce62de - Author: HASUMI Hitoshi <hasumikin@gmail.com> - AuthorDate: 2023-01-14 18:19:37 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-14 18:19:41 +0900 - - [ruby/reline] Correspond to refactored RubyLex - (https://github.com/ruby/reline/pull/498) - - * Correspond to refactored RubyLex - - ref: https://github.com/ruby/irb/pull/503 - - * Fix test_yamatanooroti - -commit cb9b885e78bb87195d483df1afedf58d0bb81e41 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-01-11 05:43:33 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-14 18:19:09 +0900 - - [ruby/irb] Store context in RubyLex - - Some background for this refactor: - - 1. Through a RubyLex instance's lifetime, the context passed to its methods - should be the same. - Given that `Context` is only initialised in `Irb#initialize`, - this should be true. - - 2. When `RubyLex` is initialised, the context object should be accessible. - This is also true in all 3 of `RubyLex.new`'s invocations. - - With the above observations, we should be able to store the context in `RubyLex` - as an instance variable. And doing so will make `RubyLex`'s instance methods - easier to use and maintain. - - https://github.com/ruby/irb/commit/5c8d3df2df - -commit 2082ba7c69c1d38508bfa549df3f2980cf8d066d - Author: Charles Oliver Nutter <headius@headius.com> - AuthorDate: 2023-01-14 10:24:25 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-14 10:24:39 +0900 - - [ruby/psych] Remove deleted file from gemspec - - https://github.com/ruby/psych/commit/77861ff281 - -commit b4cdde468b90e76e99ba06260b1748d64c11c07b - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-14 04:35:15 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-01-14 05:32:28 +0900 - - YJIT: Use SIZEOF_VALUE_I32 instead of `... as i32` - - Shorter, and easier to parse without parentheses. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7121 - -commit 84b1f48891f36ae25365181d054a208438bfa1a9 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-14 04:22:11 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-01-14 05:32:28 +0900 - - YJIT: Factor out VALUE_BITS = (8 * SIZE_OF_VALUE as u8) - - Using a constant shows intention better and is less noisy. It always - took me a second to parse the long expression. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7121 - -commit 8a93e5d01bf8bc185426a62ebb675460592a609b - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-01-13 23:30:47 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-14 00:31:35 +0900 - - Use str_enc_copy_direct to improve performance - - str_enc_copy_direct copies the string encoding over without checking the - frozen status of the string. Because we know that we're safe here (we - only use this function when interpolating strings on the stack via a - concatstrings instruction) we can safely skip this check - - Notes: - Merged: https://github.com/ruby/ruby/pull/6965 - -commit 2605615fe6c540740ce921c181c1bc081c019e49 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-01-11 06:13:18 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-14 00:31:35 +0900 - - Benchmark String interpolation across size pools - - Notes: - Merged: https://github.com/ruby/ruby/pull/6965 - -commit bb5fddd0709e17360eef343b986cd5a61ea2598c - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2023-01-11 02:58:45 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-14 00:31:35 +0900 - - Remove MIN_PRE_ALLOC_SIZE from Strings. - - This optimisation is no longer helpful now that we use VWA to allocate - strings in larger size pools where they can be embedded. - - Notes: - Merged: https://github.com/ruby/ruby/pull/6965 - -commit fc7f8520337be9513d984f67c9ef98ef85d03d0f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-11 01:08:24 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-13 20:34:45 +0900 - - [DOC] Add gem lists to NEWS.md automatically - - Notes: - Merged: https://github.com/ruby/ruby/pull/7104 - -commit 447f8f7a3c663f6b78f8159a9a8f4f0b9d8c270f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-11 00:58:12 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-13 20:34:45 +0900 - - [DOC] Changed gem list style in NEWS.md - - Notes: - Merged: https://github.com/ruby/ruby/pull/7104 - -commit 3ecffae8e81b8c508b4b964643a1468718452054 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-11 00:55:10 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-13 20:34:08 +0900 - - [DOC] Extract tool/update-NEWS-gemlist.rb - - Notes: - Merged: https://github.com/ruby/ruby/pull/7104 - -commit 94d6d6d93fa40b5f8dcdda6aa0e4b300ee61085c - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-01-13 17:02:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-13 17:25:09 +0900 - - [ruby/error_highlight] Identify which node in `Foo::Bar::Baz` causes a NameError - - In Ruby 3.2 or later, a nested constant access like `Foo::Bar::Baz` is - compiled to one instruction by the optimization https://github.com/ruby/ruby/pull/6187 - - We try to spot which sub-node caues a NameError in question based on the - constant name. We will give up if the same constant name is accessed in - a nested access (`Foo::Foo`). - - Fixes https://github.com/ruby/error_highlight/pull/31 - - https://github.com/ruby/error_highlight/commit/0a4db7da0a - -commit 5b36fefc4e7d0bbaf714fd230c409193d544bcfc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-13 12:26:16 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-13 12:26:16 +0900 - - Skip time-related assertions on /dev/null - -commit 7e8802fa5bc08de3d210860a6fa10625a8586428 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-01-13 09:47:59 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-01-13 10:28:00 +0900 - - fix `unused variables` warning - - Now `ccs` is not needed there. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7117 - -commit eab7f4623fbf0488e828b75843d70c8e02dc8aa5 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-01-13 08:54:05 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-01-13 10:11:40 +0900 - - Return 0 if there is no CFP on the EC yet - - StackProf uses a signal handler to call `rb_profile_frames`. Signals - are delivered to threads randomly, and can be delivered after the thread - has been created but before the CFP has been established on the EC. - - This commit returns early if there is no CFP to use. - - Here is some info from the core files we are seeing. Here you can see - the CFP on the current EC is 0x0: - - ``` - (gdb) p ruby_current_ec - $20 = (struct rb_execution_context_struct *) 0x7f3481301b50 - (gdb) p ruby_current_ec->cfp - $21 = (rb_control_frame_t *) 0x0 - ``` - - Here is where VM_FRAME_CFRAME_P gets a 0x0 CFP: - - ``` - 6 VM_FRAME_CFRAME_P (cfp=0x0) at vm_core.h:1350 - 7 VM_FRAME_RUBYFRAME_P (cfp=<optimized out>) at vm_core.h:1350 - 8 rb_profile_frames (start=0, limit=2048, buff=0x7f3493809590, lines=0x7f349380d590) at vm_backtrace.c:1587 - ``` - - Down the stack we can see this is happening after thread creation: - - ``` - 19 0x00007f3495bf9420 in <signal handler called> () at /lib/x86_64-linux-gnu/libpthread.so.0 - 20 0x000055d531574e55 in thread_start_func_2 (th=<optimized out>, stack_start=<optimized out>) at thread.c:676 - 21 0x000055d531575b31 in thread_start_func_1 (th_ptr=<optimized out>) at thread_pthread.c:1170 - 22 0x00007f3495bed609 in start_thread (arg=<optimized out>) at pthread_create.c:477 - 23 0x00007f3495b12133 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95 - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7116 - -commit 2e7bceb34ea858649e1f975a934ce1894d1f06a6 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-01-12 23:56:29 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-01-13 09:30:29 +0900 - - Do not use VM stack for splat arg on cfunc - - On the cfunc methods, if a splat argument is given, all array elements - are expanded on the VM stack and it can cause SystemStackError. - The idea to avoid it is making a hidden array to contain all parameters - and use this array as an argv. - - This patch is reviesed version of https://github.com/ruby/ruby/pull/6816 - The main change is all changes are closed around calling cfunc logic. - - Fixes [Bug #4040] - - Co-authored-by: Jeremy Evans <code@jeremyevans.net> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7109 - -commit 537183cd2ac0163851277b46a2f21ea5914c11c0 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-13 03:30:06 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-01-13 05:18:18 +0900 - - Fix write barrier order for `klass` to `cme` edge - - Previously, the following crashes with - `CFLAGS=-DRGENGC_CHECK_MODE=2 -DRUBY_DEBUG=1 -fno-inline`: - - $ ./miniruby -e 'GC.stress = true; Marshal.dump({})' - - It crashes with a write barrier (WB) miss assertion on an edge from the - `Hash` class object to a newly allocated negative method entry. - - This is due to usages of vm_ccs_create() running the WB too early, - before the method entry is inserted into the cc table, so before the - reference edge is established. The insertion can trigger GC and promote - the class object, so running the WB after the insertion is necessary. - Move the insertion into vm_ccs_create() and run the WB after the - insertion. - - Discovered on CI: - http://ci.rvm.jp/results/trunk-asserts@ruby-sp2-docker/4391770 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7113 - -commit da7e5c7b776e8ebbbef97c15305fbad5d032242b - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-13 05:09:32 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-13 05:09:32 +0900 - - YJIT: Do not refer to an undefined constant (#7112) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 8d3ff663899211c9c0ca2a8cf7d994e7acd3f83e - Author: Ian Ker-Seymer <hello@ianks.com> - AuthorDate: 2023-01-13 00:14:17 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-13 00:14:17 +0900 - - Enable `clippy` checks for yjit in CI (#7093) - - * Add job to check clippy lints in CI - - * Address all remaining clippy lints - - * Check lints on arm64 as well - - * Apply latest clippy lints - - * Do not exit 0 on clippy warnings - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit bfc887f391fde6de9d088039509f6e3eaa40b3ca - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-12 04:25:34 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-12 23:06:15 +0900 - - Add str_enc_copy_direct - - This commit adds str_enc_copy_direct, which is like str_enc_copy but - does not check the frozen status of str1 and does not check the validity - of the encoding of str2. This makes certain string operations ~5% faster. - - ```ruby - puts(Benchmark.measure do - 100_000_000.times do - "a".downcase - end - end) - ``` - - Before this patch: - - ``` - 7.587598 0.040858 7.628456 ( 7.669022) - ``` - - After this patch: - - ``` - 7.133128 0.039809 7.172937 ( 7.183124) - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7106 - -commit 207f8d0027d679780d4f3962c305d36885feb652 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-01-12 20:49:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-12 20:49:16 +0900 - - [ruby/irb] Avoid calling private methods on the main object - (https://github.com/ruby/irb/pull/498) - - When the main object is frozen, `IRB` wraps a `SimpleDelegator` around it. - But because `SimpleDelegator` doesn't delegate private methods, methods like - `require_relative` or `const_get` would cause error, which are needed for - lazily loading commands. - - This commit works around this limitation by avoiding those private method calls - when setting up command execution. - -commit b7598b535e49d316110aa96542a74619ef60b030 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-12 17:46:42 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-12 19:33:23 +0900 - - Bump up typeprof-0.21.4 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7108 - -commit 633fde41527bb000cd714d4b1efb16ba7533abb5 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-12 16:05:50 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-12 19:33:23 +0900 - - Try to use https://github.com/ruby/rbs/pull/1207 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7108 - -commit 019c65828b430a9bc2a1c19d758b42e39e733f13 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-01-12 19:30:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-12 19:30:17 +0900 - - [ruby/irb] Remove redundant argument defaults from some RubyLex - methods - (https://github.com/ruby/irb/pull/502) - - * Remove unnecessary parameter defaults - - These methods are always called with tokens specified. So their default - `@tokens` value is never used and is misleading. - - * Remove unnecessary context default - - * Require tokens for `RubyLex#check_state` - -commit aa665958768a17287dfd7e4a9a23e957d23316b0 - Author: elfham <38372058+elfham@users.noreply.github.com> - AuthorDate: 2023-01-12 18:40:29 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-12 18:40:34 +0900 - - [ruby/reline] Update to Unicode 15.0.0 - (https://github.com/ruby/reline/pull/437) - - * Update to Unicode 14.0.0 - - * Update to Unicode 15.0.0 - -commit d4a3882c1c184e483d6a06f5e4417f01d30da88d - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-12 16:14:58 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-12 16:14:58 +0900 - - Assert possible hash functions in RHASH_ST_TABLE (#7107) - - Because of the function pointer, it's hard to figure out what hash - functions could be used in Hash objects when st_lookup is used. - - Having this assertion makes it easier to understand what - hash_stlike_lookup could possibly do. (AR uses only rb_any_hash) - - For example, this clarifies that hash_stlike_lookup never calls a #hash - method when a key is T_STRING or T_SYMBOL. - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit a8537eae2abf307ec22446d617900796741520a8 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-01-11 22:56:47 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-12 14:41:59 +0900 - - [ruby/mutex_m] Avoid anonymous eval - - It makes it hard to locate code when profiling etc. - - https://github.com/ruby/mutex_m/commit/8760ab19ec - -commit 0e21c9f57e4bcca4daab93d0645ee642e1f97675 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-12 14:32:19 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-12 14:38:31 +0900 - - [ruby/mutex_m] Drop to support Ruby 2.4 - - https://github.com/ruby/mutex_m/commit/9245b9a63a - -commit fe11bee507a6ffb2f46e5902a2435f44184cfa7c - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-12 10:46:54 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-12 10:46:54 +0900 - - Suppressing installation messages with test-bundler - - Ignoring the following messages: - - ``` - (snip) - -e 'load "spec/bundler/support/bundle.rb"' -- install --gemfile=tool/bundler/dev_gems.rb - Using rake 13.0.6 - Using bundler 2.5.0.dev - Using diff-lcs 1.5.0 - Using parallel 1.22.1 - Using parallel_tests 2.32.0 - Using power_assert 2.0.2 - Using rb_sys 0.9.52 - Using rspec-support 3.12.0 - Using rspec-core 3.12.0 - Using rspec-expectations 3.12.0 - Using rspec-mocks 3.12.1 - Using test-unit 3.5.5 - Using uri 0.12.0 - Using webrick 1.7.0 - Bundle complete! 11 Gemfile dependencies, 14 gems now installed. - Gems in the groups 'lint' and 'doc' were not installed. - Use `bundle info [gemname]` to see where a bundled gem is installed. - ``` - -commit 617b3f697d95c6e9aaf585e18a2d1c96b94cab99 - Author: 卜部昌平 <shyouhei@ruby-lang.org> - AuthorDate: 2023-01-11 17:26:17 +0900 - Commit: 卜部昌平 <shyouhei@ruby-lang.org> - CommitDate: 2023-01-12 10:15:58 +0900 - - enhance build matrix - - Notes: - Merged: https://github.com/ruby/ruby/pull/7101 - -commit 0abb4b6348f00b03736b198b26e58b08cefc3303 - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-01-12 09:14:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-12 09:14:53 +0900 - - [ruby/reline] Pass unmodifined lines(that does not include escape - sequence) to check_multiline_prompt - (https://github.com/ruby/reline/pull/458) - - * pass unmodified lines to check_multiline_prompt - - * Add test to check that output modified by output_modifier_proc is not passed to prompt_proc - -commit 048751dd73f45ba02c8be80092a38fd47e56a925 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-12 07:54:39 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-12 07:54:39 +0900 - - Generate parser-text.rb with bcdc058e50674aedb180eea91e0fdb15bcf529db - -commit bcdc058e50674aedb180eea91e0fdb15bcf529db - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-01-11 19:17:43 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-12 07:52:29 +0900 - - [ruby/racc] Get rid of anonymous eval calls - - Things declared in anonymous eval are always annoying to locate. - (profilers, etc) - - https://github.com/ruby/racc/commit/f304205256 - -commit 11e15b4d481608b3d494af4cf7e5eb67a4dd0d7c - Author: Masataka Pocke Kuwabara <kuwabara@pocke.me> - AuthorDate: 2021-09-13 19:00:53 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-12 07:52:25 +0900 - - [ruby/racc] Make racc Ractor compatible - - https://github.com/ruby/racc/commit/1948de9d1d - -commit 7e283c585e88a08c6eaa4d28ffb646270b598e6d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-11 13:54:09 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-12 07:29:10 +0900 - - [ruby/irb] Formatting to header styles - - https://github.com/ruby/irb/commit/cef125850d - -commit 128398e7cd060691d7e4075e7b1937f43204d1a1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-11 13:44:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-12 07:29:10 +0900 - - [ruby/irb] After Ruby 2.0, coding is always utf-8 - - https://github.com/ruby/irb/commit/7a94bc4135 - -commit c7bb8d67b73c89a9939a88c9c2105e2a31a08beb - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-11 13:42:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-12 07:29:09 +0900 - - [ruby/irb] Removed Release Version and Revisions for old VCS software - - https://github.com/ruby/irb/commit/07fae94862 - -commit c693dfd7ef686ccda9db18340bc426e1227e5b53 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-01-12 06:26:12 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-12 06:26:18 +0900 - - [ruby/irb] Drop unused arguments in `RubyLex` - (https://github.com/ruby/irb/pull/504) - - * Simplify `RubyLex#set_prompt` - - It's optional argument is never used by any caller. - - * Remove the optional `p` argument from `RubyLex#set_input` - - The argument is only used in a test case, which can be easily replaced by - a block argument. - -commit 36420068725e5b4b86b3481fa1f82b249a60d928 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-12 04:12:15 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-12 04:12:15 +0900 - - YJIT: Add a few asm comments (#7105) - - * YJIT: Add a few asm comments - - * YJIT: Clarify exiting insns - - * YJIT: Fix cargo test - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit ad5ab0c3eac0dea0503086a9166238483b510db6 - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-01-07 02:53:07 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-01-12 03:01:11 +0900 - - Remove unnecessary set of INVALID_SHAPE_ID in rb_callcache - - We don't use this value, so there's no need to set it. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7082 - -commit abff5f62037284024aaf469fc46a6e8de98fa1e3 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-11 23:23:03 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-12 01:06:58 +0900 - - Move classpath to rb_classext_t - - This commit moves the classpath (and tmp_classpath) from instance - variables to the rb_classext_t. This improves performance as we no - longer need to set an instance variable when assigning a classpath to - a class. - - I benchmarked with the following script: - - ```ruby - name = :MyClass - - puts(Benchmark.measure do - 10_000_000.times do |i| - Object.const_set(name, Class.new) - Object.send(:remove_const, name) - end - end) - ``` - - Before this patch: - - ``` - 5.440119 0.025264 5.465383 ( 5.467105) - ``` - - After this patch: - - ``` - 4.889646 0.028325 4.917971 ( 4.942678) - ``` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7096 - -commit d86833e717104b477c32e135a15fcbf380c6abb2 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-11 23:19:11 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-12 01:06:58 +0900 - - Make variation_count an unsigned char - - Since SHAPE_MAX_VARIATIONS is 8, it can easily fit inside an unsigned - char. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7096 - -commit a468213917b793c47d98e172b2f0a3853460c367 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-11 21:56:42 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-11 23:25:28 +0900 - - [DOC] Mention the conditional regexp - - Notes: - Merged: https://github.com/ruby/ruby/pull/7103 - -commit ac8cf010bc2cad78f4e2cf182c475effdb12b181 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-11 06:08:00 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-11 23:16:34 +0900 - - Remove check for RCLASS_EXT in variable.c - - A class/module should always have a RCLASS_EXT, so we shouldn't need to - check that it exists. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7095 - -commit 327cf5ec402eee6840bdd550276f7a04301e1780 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-11 20:36:16 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-01-11 21:41:41 +0900 - - Skip rbs Encoding#replicate test - - Notes: - Merged: https://github.com/ruby/ruby/pull/7079 - -commit 6abe20e87b74a5a672dc59f72fa1f550ceab430c - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-06 23:07:39 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-01-11 21:41:41 +0900 - - Remove Encoding#replicate - - Notes: - Merged: https://github.com/ruby/ruby/pull/7079 - -commit d831b1d5cef23593c94d80240b836fd2038aa685 - Author: Phillip Hellewell <sshock@gmail.com> - AuthorDate: 2023-01-11 05:26:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-11 20:38:51 +0900 - - [ruby/reline] Reset IOGate in test_reset - - https://github.com/ruby/reline/commit/331c1094ef - -commit 4222083cbd71c6b25d5c4ed3f4beb49e7d501fdf - Author: Phillip Hellewell <sshock@gmail.com> - AuthorDate: 2023-01-11 02:06:48 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-11 20:38:50 +0900 - - [ruby/reline] Change IOGate back to GeneralIO - - Staying with ANSI can cause side effects with other tests. - - https://github.com/ruby/reline/commit/ba36067802 - -commit b311c35bdbfec69a49aad31e3ba9accabd5e12c4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-11 18:29:55 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-11 20:00:21 +0900 - - Suppressing pending messages with RSpec - - Notes: - Merged: https://github.com/ruby/ruby/pull/7102 - -commit 3161fd437210588ef7ce41d614ab317de11d2ec1 - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-01-11 19:00:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-11 19:08:13 +0900 - - [ruby/psych] Get rid of anonymous eval calls - - Things declared in anonymous eval are always annoying to locate. - - https://github.com/ruby/psych/commit/38871ad4e5 - -commit e85ef212de98c817154ab62ae2d03508c512107e - Author: Jean Boussier <jean.boussier@gmail.com> - AuthorDate: 2023-01-11 18:08:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-11 18:26:08 +0900 - - [ruby/set] Avoid the `block or return` pattern to save Proc allocations - - Using the block param in a boolean context like this cause it to be - allocated. - - Using it with an `if` or `unless` was optimized in 3.2 - (https://github.com/ruby/ruby/pull/6286) but using it with `or` - or `and` wasn't. - - ```ruby - def foo(&block) - block or return 1 - end - - puts RubyVM::InstructionSequence.of(method(:foo)).disasm - == disasm: #<ISeq:foo@(irb):11 (11,0)-(13,3)> (catch: false) - local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: 0, kw: -1@-1, kwrest: -1]) - [ 1] block@0<Block> - 0000 getblockparam block@0, 0 ( 12)[LiCa] - 0003 dup - 0004 branchif 10 - 0006 pop - 0007 putobject_INT2FIX_1_ - 0008 leave [Re] - 0009 putnil - 0010 leave - ``` - - versus - - ``` - def foo(&block) - return 1 if block - end - - puts RubyVM::InstructionSequence.of(method(:foo)).disasm - == disasm: #<ISeq:foo@(irb):15 (15,0)-(17,3)> (catch: false) - local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: 0, kw: -1@-1, kwrest: -1]) - [ 1] block@0<Block> - 0000 getblockparamproxy block@0, 0 ( 16)[LiCa] - 0003 branchunless 7 - 0005 putobject_INT2FIX_1_ - 0006 leave ( 17)[Re] - 0007 putnil ( 16) - 0008 leave - ``` - - https://github.com/ruby/set/commit/e89da977d4 - -commit 8c2b6926d2c6ba0317fcccb08c8b6657d4f0730c - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2023-01-11 17:00:30 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2023-01-11 18:09:48 +0900 - - Skip unfixed assertion about objspace/dump_all - - ``` - {"address":"0x7f8c03e9fcf0", "type":"STRING", "shape_id":10, "slot_size":40, "class":"0x7f8c00dbed98", "frozen":true, "embedded":true, "fstring":true, "bytesize":5, "value":"TEST2", "encoding":"US-ASCII", "coderange":"7bit", "memsize":40, "flags":{"wb_protected":true}} - {"address":"0x7f8c03e9ffc0", "type":"STRING", "shape_id":0, "slot_size":40, "class":"0x7f8c00dbed98", "embedded":true, "bytesize":5, "value":"TEST2", "encoding":"US-ASCII", "coderange":"7bit", "memsize":40, "flags":{"wb_protected":true}} - {"address":"0x7f8c03e487c0", "type":"STRING", "shape_id":0, "slot_size":40, "class":"0x7f8c00dbed98", "embedded":true, "bytesize":5, "value":"TEST2", "encoding":"UTF-8", "coderange":"unknown", "file":"-", "line":4, "method":"dump_my_heap_please", "generation":1, "memsize":40, "flags":{"wb_protected":true}} - 1) Failure: - TestObjSpace#test_dump_all [/tmp/ruby/src/trunk-gc-asserts/test/objspace/test_objspace.rb:622]: - number of strings. - <2> expected but was - <3>. - ``` - - This failure only occurred on a ruby built with `DEFS=\"-DRGENGC_CHECK_MODE=2\""` - and only on a specific machine (Docker container) and difficult to reproduce, - so skip this failure to check other failures. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7100 - -commit 5bf7218b01375b635188795dc4494562c2a98ea6 - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-01-11 03:54:07 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-11 03:54:07 +0900 - - Differentiate T_ARRAY and array subclasses (#7091) - - * Differentiate T_ARRAY and array subclasses - - This commit teaches the YJIT context the difference between Arrays - (objects with type T_ARRAY and class rb_cArray) vs Array subclasses - (objects with type T_ARRAY but _not_ class rb_cArray). It uses this - information to reduce the number of guards emitted when using - `jit_guard_known_klass` with rb_cArray, notably opt_aref - - * Update yjit/src/core.rs - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit aeddc19340c7116d48fac3080553fbb823857d16 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-11 01:11:10 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-11 01:11:10 +0900 - - YJIT: Save PC and SP before calling leaf builtins (#7090) - - Previously, we did not update `cfp->sp` before calling the C function of - ISEQs marked with `Primitive.attr! "inline"` (leaf builtins). This - caused the GC to miss temporary values on the stack in case the function - allocates and triggers a GC run. Right now, there is only a few leaf - builtins in numeric.rb on Integer methods such as `Integer#~`. Since - these methods only allocate when operating on big numbers, we missed - this issue. - - Fix by saving PC and SP before calling the functions -- our usual - protocol for calling C functions that may allocate on the GC heap. - - [Bug #19316] - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 6a585dbd5a41d5a9e0a8e406fef133e89bafb832 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-11 01:00:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-11 01:00:25 +0900 - - YJIT: Fix a compilation warning with release build (#7092) - - warning: unused variable: `start_addr` - --> ../yjit/src/asm/mod.rs:359:39 - | - 359 | pub fn remove_comments(&mut self, start_addr: CodePtr, end_addr: CodePtr) { - | ^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_start_addr` - | - = note: `#[warn(unused_variables)]` on by default - - warning: unused variable: `end_addr` - --> ../yjit/src/asm/mod.rs:359:60 - | - 359 | pub fn remove_comments(&mut self, start_addr: CodePtr, end_addr: CodePtr) { - | - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 2861c8deafe5e513fc59048198cbe70359d0f16d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-10 05:39:23 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-10 22:59:38 +0900 - - Remove ARY_SET_SHARED - - We don't need ARY_SET_SHARED since we already have rb_ary_set_shared. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7089 - -commit 97f8f2c4703361624823ef76d6cfe804ba1e651b - Author: Phillip Hellewell <phillip.hellewell@mx.com> - AuthorDate: 2022-03-06 16:22:57 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-10 21:18:14 +0900 - - [ruby/reline] Add key binding for Delete - - https://github.com/ruby/reline/commit/603eacee22 - -commit 47ca75d38a0a16332bd1b40806b27763a433f630 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-10 20:39:58 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-01-10 20:39:58 +0900 - - Remove extra line which causes `make test-bundled-gems-fetch` to fail - -commit 6053624a831c560a1bb23e43317d3d5232f84f4f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-10 17:34:56 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-10 17:34:56 +0900 - - [DOC] Comments about fields in bundled_gems file - -commit a43f1d90c2b3aed232d5f4ef9dfe226401cf5d81 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-10 13:53:41 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-10 15:53:07 +0900 - - Merge RubyGems and Bundler master - - from https://github.com/rubygems/rubygems/commit/0635c1423db5d7c461d53bf0c3329bca75de7609 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7094 - -commit 89fb61f9a3276121da2826b93f131e52d6449859 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-10 13:39:31 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-10 13:39:31 +0900 - - Update LEGAL sections for pub_grub - -commit f2fc7519b720e731b03ba111448a1c481da237be - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-10 13:13:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-10 13:13:06 +0900 - - Removed vendored LICENSE file. - -commit 900230837b51f501856ac6af5ecbf4f1369f1ca6 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-10 13:07:36 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-10 13:07:36 +0900 - - Fixed a typo - -commit 2e0159c5f26e65b9bb6edc58c024bb551cc80024 - Author: David Rodríguez <deivid.rodriguez@riseup.net> - AuthorDate: 2023-01-08 02:57:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-10 12:58:28 +0900 - - [rubygems/rubygems] Fix resolver edge case - - Let it deal with legacy gems with equivalent version and different - dependencies. - - https://github.com/rubygems/rubygems/commit/b430babe97 - -commit 9792d9e40f790e6deb18ead56a8befc9d5c4bc51 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-10 10:43:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-01-10 10:43:47 +0900 - - Revert "Re-enable test_ractor for YJIT" - - This reverts commit 650a20a3e1205f47224a987676cdbad7d826d597. - - Now that 3.2.0 is released, let's disable flaky tests. Koichi said he'll - rework Ractor implementation for this, and it has not been done yet. - -commit df76c54fc251904c2eaf4cc9354ed8726336c289 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-10 09:45:11 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-01-10 09:45:50 +0900 - - Allow overriding a gdb command on `make gdb` - - With --enable-yjit, you see an annoying warning like this: - - warning: Missing auto-load script at offset 0 in section .debug_gdb_scripts - of file /home/k0kubun/src/github.com/ruby/ruby/.ruby/miniruby. - Use `info auto-load python-scripts [REGEXP]' to list them. - - Using `rust-gdb` instead fixes it. I use this like `make gdb GDB=rust-gdb`. - -commit 72eb33066fa9e7dacb7470cd140b219abe37667e - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-07 04:19:00 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-01-10 09:00:42 +0900 - - Fix off-by-one error in rb_vm_each_stack_value - - Applying the following patch to test/erb/test_erb.rb and running that - file will cause Ruby to crash on my machine (macOS 13.1 on M1 Pro): - - ``` - --- a/test/erb/test_erb.rb - +++ b/test/erb/test_erb.rb - @@ -7,6 +7,12 @@ - class TestERB < Test::Unit::TestCase - class MyError < RuntimeError ; end - - + def setup - + GC.auto_compact = true - + GC.stress = true - + GC.verify_compaction_references(expand_heap: true, toward: :empty) - + end - + - ``` - - It crashes with the following log: - - ``` - /Users/peter/src/ruby/lib/erb/compiler.rb:276: [BUG] Segmentation fault at 0x00000001083a8690 - ... - -- C level backtrace information ------------------------------------------- - ... - /Users/peter/src/ruby/build/ruby(rb_vm_each_stack_value+0xa8) [0x104cc3a44] ../vm.c:2737 - /Users/peter/src/ruby/build/ruby(rb_vm_each_stack_value+0xa8) [0x104cc3a44] ../vm.c:2737 - /Users/peter/src/ruby/build/ruby(check_stack_for_moved+0x2c) [0x104b272a4] ../gc.c:5512 - /Users/peter/src/ruby/build/ruby(gc_compact_finish) ../gc.c:5534 - /Users/peter/src/ruby/build/ruby(gc_sweep_compact) ../gc.c:8653 - /Users/peter/src/ruby/build/ruby(gc_sweep) ../gc.c:6196 - /Users/peter/src/ruby/build/ruby(has_sweeping_pages+0x0) [0x104b19c54] ../gc.c:9568 - /Users/peter/src/ruby/build/ruby(gc_rest) ../gc.c:9570 - ``` - - This crash happens because it's reading the VALUE at sp. But since - sp points to the top of the stack, it's reading the VALUE above the - top of the stack, which is causing this segfault. - - Fixes [Bug #19320] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7081 - -commit 0247ccddabd5305eeff09411c503125c31d4e0cd - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-10 07:29:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-01-10 07:29:18 +0900 - - Fix a warning in .gdbinit - - Warning: 'set logging on', an alias for the command 'set logging enabled', is deprecated. - Use 'set logging enabled on'. - -commit 40bf89872f1b5300040061e200468cac011dd67f - Author: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com> - AuthorDate: 2023-01-10 04:12:10 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-10 04:12:10 +0900 - - Update yjit.md - - Add Alan Wu's keynote & Maxime's talk to the list of YJIT-related talks :) - -commit a7fbdc35a2d4bce349445a7dbcdb67fddfda3857 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-10 01:29:41 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-10 01:29:41 +0900 - - YJIT: Remove old comments for regenerated branches (#7083) - - Notes: - Merged-By: maximecb <maximecb@ruby-lang.org> - -commit 9726736006b3f74635fd8af05814fe0908e2cf84 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-07 06:18:29 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-09 22:49:29 +0900 - - Set STR_SHARED_ROOT flag on root of string - - Notes: - Merged: https://github.com/ruby/ruby/pull/7071 - -commit 2ad081f79964b2312b6e45c8c98196f300f61937 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-06 23:14:30 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-09 22:49:29 +0900 - - Assert that resizing arrays will re-embed them - - Notes: - Merged: https://github.com/ruby/ruby/pull/7071 - -commit 682b45d489b29b297e8b3b2c1ba8f549ed50b77a - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-06 23:11:42 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-09 22:49:29 +0900 - - Assert that resizing objects will re-embed them - - Notes: - Merged: https://github.com/ruby/ruby/pull/7071 - -commit 3be2acfafd3b3c6168e2266c7c6561d143d7ae5c - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-06 23:09:18 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-09 22:49:29 +0900 - - Fix re-embedding of strings during compaction - - The reference updating code for strings is not re-embedding strings - because the code is incorrectly wrapped inside of a - `if (STR_SHARED_P(obj))` clause. Shared strings can't be re-embedded - so this ends up being a no-op. This means that strings can be moved to a - large size pool during compaction, but won't be re-embedded, which would - waste the space. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7071 - -commit 29dc9378d971a66ad3fcb21281aac23f0521afe5 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-09 18:32:32 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-09 21:44:15 +0900 - - mkmf.rb: Refine message from `pkg_config` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7088 - -commit 0d7bbfc9415aa066ea8c17b90dd06c5d47fed50b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-09 18:30:05 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-09 21:44:15 +0900 - - mkmf.rb: Prefer `caller_locations` over parsing `caller` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7088 - -commit 0a2bf5f1e256de7f030668c6130379cbd0d6d708 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-09 18:41:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-09 19:46:02 +0900 - - [ruby/zlib] Check for functions with arguments and the header - - With arguments, mkmf skips compilation check for the function as RHS. - - https://github.com/ruby/zlib/commit/9ed9d6d36e - -commit 9d078fe4778d6ba60e1daba0d7172d027a1e7f4d - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-09 18:53:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-09 18:58:43 +0900 - - [ruby/zlib] Fix the test broken in older versions - - https://github.com/ruby/zlib/commit/fc89ff9ef0 - -commit f6952a94ebd0e9d88c34784b8ab3dfb9673be538 - Author: Lars Kanis <lars@greiz-reinsdorf.de> - AuthorDate: 2023-01-09 17:19:30 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-09 18:39:08 +0900 - - [ruby/psych] Fix wrong package name of MSYS2/MINGW dependency - - There is no package called "libyaml-devel". "libyaml" is enough. - -commit 41a947e72aba3804c60a111e73e54d81150bbb6d - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-01-09 08:14:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-09 08:14:50 +0900 - - [ruby/uri] [DOC] Enhanced RDoc for URI - (https://github.com/ruby/uri/pull/55) - - https://github.com/ruby/uri/commit/89ab4f1407 - -commit 20b691d664389470fdd312c094c73ca8c9b35339 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-01-09 02:11:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-09 02:11:12 +0900 - - [ruby/uri] [DOC] Enhanced RDoc for URI.decode_www_form - (https://github.com/ruby/uri/pull/53) - - https://github.com/ruby/uri/commit/ce379e6125 - -commit 1cdf8ab07b24ebd16e93621957196e8b1d67f2ba - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-08 20:54:48 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-08 20:54:48 +0900 - - [Bug #19323] Raise `RangeError` instead of integer overflow - - Notes: - Merged: https://github.com/ruby/ruby/pull/7087 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit 89546dce21e1e85f4483a7f9d4049e5608803185 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-30 20:19:49 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-08 17:09:34 +0900 - - [rubygems/rubygems] [DOC] Remove internal document about `Kernel` monkey patch - - https://bugs.ruby-lang.org/issues/19285 - - https://github.com/rubygems/rubygems/commit/1e22219ed4 - -commit 55aa1a206c676c9e1c9163534cd7ca798c6d8353 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-05 11:52:14 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-08 17:09:34 +0900 - - [rubygems/rubygems] `LoadError#path` on the caught exception does not need to protect - - https://github.com/rubygems/rubygems/commit/a31f5d1a18 - -commit 1a1b653c9c7f83599cb6df0c0d4f0332f466c5f6 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-05 00:16:35 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-08 17:09:33 +0900 - - [rubygems/rubygems] Let RDoc parse the doc of `Kernel#require` - - Since RDoc does not parse string literals as documents, `eval` the - entire file instead of embedding in a here-document. - On the contrary, as `gem_original_require` alias is an implementation - detail but not for users, it should not be documented. - - https://github.com/rubygems/rubygems/commit/cad4cf16cf - -commit fd98169e00a050fab2e7f1a1cefcc92be4c8cb40 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-01-08 04:22:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-08 04:22:36 +0900 - - [ruby/uri] [DOC] Common rdoc (https://github.com/ruby/uri/pull/52) - - https://github.com/ruby/uri/commit/be8047028f - -commit 28cfc0c116b6c6e40bf3b391f026a51b3b208047 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-07 21:18:04 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-01-07 21:18:04 +0900 - - Only RangeError on CRuby for shift width >= 2**67 - - * It seems a better exception class too than NoMemoryError. - -commit 897cf122bf491ecf00d6374d944654bc85f8ed0f - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-07 21:13:03 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-01-07 21:13:03 +0900 - - Fix Integer#{<<,>>} specs with large shift width - - * The limit depends on the implementation and platform, it seems unavoidable. - * See https://bugs.ruby-lang.org/issues/18518#note-9 - -commit 651a098ea1526b363e85fd8d3f30e9783f6c5de1 - Author: Yuki Nishijima <yuki24@hey.com> - AuthorDate: 2023-01-07 17:46:44 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-07 17:47:05 +0900 - - [ruby/did_you_mean] Keep the deprecated API for another year in case this could break 'bundle install' - - https://github.com/ruby/did_you_mean/commit/0f4b0806b7 - -commit e537aa65c022fa3bb35b7b7b44a2ef7f72be20e9 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-03 23:42:41 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-07 17:02:49 +0900 - - [ruby/syntax_suggest] Run with the given ruby command - - Running the file with shebang has a few issues. - - * shebang is an OS dependent feature. Many modern UNIX-like OSes - support it, but not all, e.g., Windows. - * `env` command may not be in `/usr/bin`. - * "ruby" command may not be "ruby", when `--program-suffix` or other - configuration option is used. - - https://github.com/ruby/syntax_suggest/commit/2edf241055 - -commit 69a2687a27b1ad8a8a76ccd422e7d226c8ff5640 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-07 12:09:02 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-07 12:15:27 +0900 - - [ruby/bigdecimal] Fix format specifiers for `size_t` - - https://github.com/ruby/bigdecimal/commit/99db3c9754 - -commit 41fbcc519302f11835713498c211078bedfcb074 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-07 11:47:50 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-07 11:47:50 +0900 - - Fix format specifiers for pointer differences - -commit 00d58afb5d7f3cf3a553e1e8f75f31e4d8781fe7 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-07 04:49:59 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-07 04:49:59 +0900 - - YJIT: Make iseq_get_location consistent with iseq.c (#7074) - - * YJIT: Make iseq_get_location consistent with iseq.c - - * YJIT: Call it "YJIT entry point" - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Co-authored-by: Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 311ce9173330060ec805ef54887003dd1b447f15 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-07 04:49:45 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2023-01-07 04:49:45 +0900 - - YJIT: Colorize outlined code differently on --yjit-dump-disasm (#7073) - - * YJIT: Colorize outlined code differently - - on --yjit-dump-disasm - - * YJIT: Reduce the number of escape sequences - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit 66bc620963407dbfd6f4e532a61018905a490aeb - Author: Jemma Issroff <jemmaissroff@gmail.com> - AuthorDate: 2023-01-06 23:46:06 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-07 01:46:50 +0900 - - Remove unused function `rb_shape_flags_mask` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7078 - -commit d8ef0a98c670449b20436947f5ebbd327ed5ab0d - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-07 00:24:09 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-07 01:36:28 +0900 - - [Bug #19319] Fix crash in rb_str_casemap - - The following code crashes on my machine: - - ``` - GC.stress = true - - str = "testing testing testing" - - puts str.capitalize - ``` - - We need to ensure that the object `buffer_anchor` remains on the stack - so it does not get GC'd. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7080 - -commit 2b88dbc6f905a873da1aaead7aed8dcb1fcd3767 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-07 00:28:02 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-01-07 00:28:02 +0900 - - Add bug number - -commit ddbf7be94d8653f1b2b0325d3e65bc88e50623ec - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-01-06 23:20:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-06 23:20:38 +0900 - - [ruby/uri] [DOC] Enhanced RDoc for common methods - (https://github.com/ruby/uri/pull/50) - - https://github.com/ruby/uri/commit/7ff4fb372b - -commit cee5beab1d7bf6f99530957494ab9775696d42ce - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-06 20:26:11 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-01-06 21:13:07 +0900 - - [Bug #19312] Return end-of-input at `__END__` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7077 - -commit d9520bf2debaad471f68bd74001967eee3e6d51e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-06 19:04:59 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-06 20:00:53 +0900 - - [DOC] Mention `configure` options earlier, not after failure - - The command line arguments to `configure` are stored in `rbconfig.rb`. - Usually these are just useless but harmless after the installation, - however could affect unexpectedly when updating default gems. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7076 - -commit 42820a9807a89a0e0b572c67df7e838e24b1499a - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-06 19:03:25 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-06 20:00:53 +0900 - - [DOC] Specify `shell` format to shell commands - - Notes: - Merged: https://github.com/ruby/ruby/pull/7076 - -commit b94656147bc2048fd183bc0e0d1e5bb3d230a4b1 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-06 12:23:25 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-06 20:00:53 +0900 - - mkmf.rb: Refactor splitting configure_args and remove duplicate code - - Notes: - Merged: https://github.com/ruby/ruby/pull/7076 - -commit cd7e14da4ed7d96c4cfffa222f022f335a4e43cd - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-11-02 23:42:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-06 20:00:53 +0900 - - Pass options for extensions via `CONFIGURE_ARGS` - - Notes: - Merged: https://github.com/ruby/ruby/pull/7076 - -commit 1be669d06342b8cc304efeb8e3108967520afa61 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-01-06 16:02:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-06 16:02:20 +0900 - - Update bundled gems list at 2023-01-06 - -commit f877805a0c9dcb90635f4b3d100a4367bf346c4a - Author: dsisnero <dsisnero@users.noreply.github.com> - AuthorDate: 2022-12-16 09:18:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-06 15:33:08 +0900 - - [ruby/psych] Add msys2 dependencies for windows - - https://github.com/ruby/psych/commit/9a3816d903 - -commit 6c618cb78922b1666210c9289cd242f87186517f - Author: Aaron Patterson <tenderlove@ruby-lang.org> - AuthorDate: 2023-01-06 10:13:08 +0900 - Commit: Aaron Patterson <aaron.patterson@gmail.com> - CommitDate: 2023-01-06 10:49:30 +0900 - - Use a different name for megamorphic setivar exits - - We should differentiate between set and get for megamorphic exits. This - patch fixes the megamorphic exit name in gen_setinstancevariable so that - we can tell the difference between megamorphic get / set sites - - Notes: - Merged: https://github.com/ruby/ruby/pull/7072 - -commit 979dd02e2f0a70f3f30d47c6115780d8fac6147e - Author: yui-knk <spiketeika@gmail.com> - AuthorDate: 2022-12-26 17:45:44 +0900 - Commit: yui-knk <spiketeika@gmail.com> - CommitDate: 2023-01-06 09:22:09 +0900 - - Check if the argument is Thread::Backtrace::Location object - - [Bug #19262] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7029 - -commit 2056c0a7c680350cf92a134e355c03e1efb10549 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-06 00:55:44 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-06 06:00:36 +0900 - - Add embedded status to dumps of T_OBJECT - - This commit adds `"embedded":true` in ObjectSpace.dump for T_OBJECTs - that are embedded. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7068 - -commit 53938efd7b0ac868b177b3e748996a3aef4bccb6 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-06 05:07:29 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-01-06 05:07:29 +0900 - - Update to ruby/spec@5e48206 - -commit 29a5fcd60b3738378b66499636a10f96a0f2a474 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-06 04:14:59 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-06 04:55:14 +0900 - - Add RBIMPL_ATTR_NORETURN to unknown_directive - - Fixes a compiler warning about the function unknown_directive: - - pack.c:160:1: warning: function 'unknown_directive' could be declared with attribute 'noreturn' [-Wmissing-noreturn] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7070 - -commit ec14861f0d7a1e99d3e6667dee2f4c9cc426d5f3 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-06 04:23:57 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-01-06 04:23:57 +0900 - - Update to ruby/spec@7e680fa - -commit 273dca3aed7989120d57f80c789733d4bc870ffe - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-05 22:48:19 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-06 03:14:11 +0900 - - Fix undefined behavior in shape.c - - Under strict aliasing, writing to the memory location of a different - type is not allowed and will result in undefined behavior. This was - happening in shape.c due to `rb_id_table_lookup` writing to the memory - location of `VALUE *` that was casted from a `rb_shape_t **`. - - This was causing test failures when compiled with LTO. - - Fixes [Bug #19248] - - Co-Authored-By: Alan Wu <alanwu@ruby-lang.org> - - Notes: - Merged: https://github.com/ruby/ruby/pull/7067 - -commit bbf54ec334fe2edd7669a944d88d17efde49a412 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-06 03:05:29 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-01-06 03:05:29 +0900 - - Update to ruby/spec@9d69b95 - -commit cd5e6cc0ea48353c88d921b885b552dc76da255c - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-06 03:05:27 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-01-06 03:05:27 +0900 - - Update to ruby/mspec@fef9b81 - -commit 03dd37775afb40eef392ae2920d728235af302c8 - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2023-01-06 02:41:57 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2023-01-06 03:05:03 +0900 - - Raise an ArgumentError for unknown pack/unpack directive - - * [Bug #19150] - -commit 358f325bf8cd6fca3da1343e9606176cad2c70bd - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-05 23:24:32 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-05 23:24:32 +0900 - - [DOC] Fix formatting for GC.stat - -commit f9148d1580e43038d9d2319e59086d38c4aa9c47 - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-01-05 22:06:15 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-05 22:06:23 +0900 - - [ruby/irb] Group command test cases with class - (https://github.com/ruby/irb/pull/491) - - Currently, IRB has 35 test cases for 10 non-debugging commands, with the - rest 10 commands untested. So in the long-term, it could have around 70 - test cases for all existing commands. - - With this number of test cases, I think it's easier to manage them by grouping - them in classes (by command). - -commit 4959e01932cf6c4d3e5e90d3e0b4fa780f754fa6 - Author: Yusuke Endoh <mame@ruby-lang.org> - AuthorDate: 2023-01-05 05:11:50 +0900 - Commit: Yusuke Endoh <mame@ruby-lang.org> - CommitDate: 2023-01-05 18:26:35 +0900 - - common.mk: Do not invoke outdate-bundled-gems by default - - If baseruby is available (and its version is different from one being - built) when compiling ruby, tool/outdate-bundled-gems.rb (which is - invoked by `make install`) wrongly deletes debug.so and rbs_extension.so - in .bundle/extension/*. - - This leads to a broken installation of ruby which lacks the libraries, - which may make rubygems show the following warnings (in some additional - complex conditions): - - ``` - $ irb - Ignoring debug-1.7.1 because its extensions are not built. Try: gem pristine debug --version 1.7.1 - Ignoring rbs-2.8.2 because its extensions are not built. Try: gem pristine rbs --version 2.8.2 - irb(main):001:0> - ``` - - According to some committers, tool/outdate-bundled-gems.rb is introduced - for fixing a build issue, but the detail is not recorded. The issue - seems to occur only when debug gem or rbs gem is updated, so it is - difficult to fix the script so soon. - - Tentatively, this change stops invoking the script by default. - This should be backported to ruby_3_2. - - Fixes [Bug #19271] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7066 - -commit b496578758faa67490cf196b70e7cfbfd2ff7f3d - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-05 08:16:24 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-05 08:16:24 +0900 - - Skip Test::Unit::AutoRunner logic in ruby/ruby repository - -commit 1f2fef1f9ac03fb01a3150f953e2194e58e437ea - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-04 21:02:10 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-05 08:06:49 +0900 - - [ruby/openssl] Stop AutoRunner with test-unit - - https://github.com/ruby/openssl/commit/0d4cd8b9ca - -commit 837ef8911c638c3e2bdb6af710de7c1fac7b5f90 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-05 03:15:59 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-05 04:59:40 +0900 - - Fix crash in TracePoint c_call for removed method - - trace_arg->id is the ID of the original method of an aliased method. If - the original method is removed, then the lookup will fail. We should use - trace_arg->called_id instead, which is the ID of the aliased method. - - Fixes [Bug #19305] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7064 - -commit f7243d1afb726848fc5fa77dbb7c95eb78f6f610 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-01-05 04:58:59 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-05 04:59:05 +0900 - - [ruby/uri] [DOC] Common methods rdoc - (https://github.com/ruby/uri/pull/49) - - https://github.com/ruby/uri/commit/02dfc79366 - -commit b8a3f1bd456f92866c4a7bd83235f78c574784a8 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-04 00:59:47 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-04 23:10:58 +0900 - - Fix crash in tracing object allocations - - ObjectSpace.trace_object_allocations_start could crash since it adds a - TracePoint for when objects are freed. However, TracePoint could crash - since it modifies st tables while inside the GC that is trying to free - the object. This could cause a memory allocation to happen which would - crash if it triggers another GC. - - See a crash log: http://ci.rvm.jp/results/trunk@ruby-sp1/4373707 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7058 - -commit 3bcf92d8afb62a10dd4c700a4925d2ccac43f5a2 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2023-01-04 00:50:40 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-04 23:10:58 +0900 - - Allow malloc during gc when GC has been disabled - - We should allow malloc during GC when GC has been explicitly disabled - since garbage_collect_with_gvl won't do anything if GC has been disabled. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7058 - -commit 799d805e215e3bdcc2e9bbdb48638a129b50e8f4 - Author: yoka <jesse.ikonen@gmail.com> - AuthorDate: 2022-12-31 17:58:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-04 22:13:19 +0900 - - [rubygems/rubygems] Raise invalid option when bundle open --path is called without a value - - https://github.com/rubygems/rubygems/commit/c242311158 - -commit 87c17a141dc4491abf5282d164f2cba13ade18c4 - Author: yoka <jesse.ikonen@gmail.com> - AuthorDate: 2022-12-22 15:39:00 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-04 22:13:19 +0900 - - [rubygems/rubygems] Enhance bundle open with --path option - - https://github.com/rubygems/rubygems/commit/3bf8e59304 - -commit 3d6500ee6e3676979d5199dc7b5feab0d15235de - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2023-01-04 18:35:52 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-04 18:35:57 +0900 - - [ruby/irb] workspace.rb cleanup - (https://github.com/ruby/irb/pull/489) - - * Remove unnecessary Binding#source_location check - - `Binding#source_location` was added in 2.6, which is the minimum supported - version now. So this check is no longer necessary. - - * Remove unused IRB.delete_caller - - This method was added in the earliest version of IRB: - - https://github.com/ruby/irb/commit/f47808999d24865fba1929dea1a7011ff5a517d6 - - But it's not currently referenced by anything. We can verify this with a - org-wide search result: - - https://github.com/search?q=org%3Aruby+delete_caller&type=code - -commit e25c173c97e1e0e538aeb85734cabcbb59cd11ab - Author: Joel Anderson <joelanderson333@gmail.com> - AuthorDate: 2022-12-16 13:46:56 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-04 15:32:46 +0900 - - [ruby/reline] correct Win32API capitalization for JRuby - - JRuby 9.4.0.0 introduced a change in case sensitivity in require statements, - meaning that an inclusion of `win32api` loaded Win32API.rb. With this change, - the require statement needs to be updated to the correct capitalization of the - filename to avoid reline failures in newer versions of JRuby. - - https://github.com/ruby/reline/commit/d6e7c9e1d9 - -commit d57148e9e2fa83262f56484bb1f7c9c511c9dbc4 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2023-01-04 12:05:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2023-01-04 12:56:46 +0900 - - Pin octokit/request-action@v2.1.7 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7060 - -commit 43ff0c2c488c80aaf83b486d45bcd4a92ebe3848 - Author: Alan Wu <XrXr@users.noreply.github.com> - AuthorDate: 2023-01-04 05:07:33 +0900 - Commit: Alan Wu <XrXr@users.noreply.github.com> - CommitDate: 2023-01-04 06:17:50 +0900 - - YJIT: Fix `yield` into block with >=30 locals on ARM - - It's a register spill issue. Fix by moving the Qnil fill snippet to - after registers are released. - - [Bug #19299] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7059 - -commit 1bb0749c5ba4b730304ca0cf37701e654fa06759 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-04 00:06:54 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-04 01:18:24 +0900 - - [DOC] Move the internal document for `Init_class_hierarchy` - - It has hidden the document for `Object` class. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7057 - -commit 59cf9ebf4dc211cb9d71a484866895b3d927fbe6 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2023-01-04 00:33:31 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-04 00:33:45 +0900 - - [ruby/uri] [DOC] Enhanced RDoc for common methods - (https://github.com/ruby/uri/pull/48) - - https://github.com/ruby/uri/commit/2bfd848c26 - -commit 0dc989d031fb8c2b1e0d83e154455b612e3e4b96 - Author: Matt Valentine-House <matt@eightbitraptor.com> - AuthorDate: 2022-12-22 00:48:00 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2023-01-03 22:47:48 +0900 - - Fix Error in GC Compaction specs - - Previously if any of the tests that move objects between size pools - failed to move anything, then the call to stats.dig would return `nil` - which would then cause assert_operator to error. - - This should be a test Failure, rather than an Error so this commit uses - a default value of 0 if stats.dig fails to find a key. - - Also refactor object movement tests to use stats.dig, rather than :[] - - Notes: - Merged: https://github.com/ruby/ruby/pull/6978 - -commit 2bbf63dd867fe3d349b1758805ad4421f2d772ab - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2023-01-03 06:12:47 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2023-01-03 06:13:01 +0900 - - Remove lib/mjit/instruction.rb - - This was accidentally re-introduced in f6620037ba1477d2c337d7b511f094d6d0fbb69c. - - [Bug #19298] - -commit 34f8ca1714a91e4e051ef80f22df2d0e5e0acfae - Author: tomoya ishida <tomoyapenguin@gmail.com> - AuthorDate: 2023-01-03 04:25:07 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-03 04:25:11 +0900 - - [ruby/irb] Fix prompt and code mismatch - (https://github.com/ruby/irb/pull/386) - - * fix prompt and code mismatch - - * Add test for prompt and code mismatch bug - - https://github.com/ruby/irb/commit/a5765d8177 - - Co-authored-by: Stan Lo <stan001212@gmail.com> - -commit 5be0d42d2c4dc765230c76738289560f9ee37f09 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-02 23:23:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-02 23:29:19 +0900 - - [Bug #19296] Precheck bits of time components - -commit 291a4098cf649c027cb50c16b872455f26ad1dfb - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-02 23:17:27 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-02 23:17:27 +0900 - - Add missing assertion - -commit 3becc4a105bcf873fdc6e83c2a957f73718c5084 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-02 00:27:25 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-02 16:12:08 +0900 - - [Bug #19291] Rewind to the previous line - - When rewinding looking ahead after newline token, also reset the last - line string, the pointers to it, and the location, not only the line - number. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7054 - -commit 51021fc710f1fedcb750d6c4c8e4b5213b1e13e6 - Author: git[bot] <svn-admin@ruby-lang.org> - AuthorDate: 2023-01-02 16:04:24 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-02 16:04:24 +0900 - - Update bundled gems list at 2023-01-02 - -commit 0903a251796c2b4086804a94420c231c04e3cea1 - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2022-08-24 04:22:24 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2023-01-02 02:00:24 +0900 - - Make IO#set_encoding with binary external encoding use nil internal encoding - - This was already the behavior when a single `'external:internal'` - encoding specifier string was passed. This makes the behavior - consistent for the case where separate external and internal - encoding specifiers are provided. - - While here, fix the IO#set_encoding method documentation to - state that either the first or second argument can be a string - with an encoding name, and describe the behavior when the - external encoding is binary. - - Fixes [Bug #18899] - - Notes: - Merged: https://github.com/ruby/ruby/pull/6280 - -commit a4e9606da425a5f6bb5089b1037a3afd8cfa585b - Author: Mark Doliner <mark@kingant.net> - AuthorDate: 2023-01-01 00:00:53 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-02 00:04:43 +0900 - - [rubygems/rubygems] Remove stray word in bundle config man page. - - There was an extra word ("with") in this sentence. - - https://github.com/rubygems/rubygems/commit/ad3de5126c - -commit 44b7fd8d4fa842523813195dfb7255ce33fdf9ca - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2022-12-30 03:16:27 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2023-01-02 00:02:14 +0900 - - [ruby/net-http] Enhanced RDoc for HTTPHeader - - https://github.com/ruby/net-http/commit/6a282eccdd - -commit 542e984d82fa25098eb15398d716d907acc52b93 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-01 16:39:00 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-01 16:39:00 +0900 - - [Bug #19292] Re-initialize tm when wday or yday is not set - - Notes: - Merged: https://github.com/ruby/ruby/pull/7051 - -commit f527a0911d5ff0476152a3e3c9bcd2247ead5636 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2023-01-01 14:33:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2023-01-01 14:50:39 +0900 - - [DOC] [Bug #19290] fix formatting - -commit 0bb07e5ba40cdc45d55743dd1ebaadd7e7363e7f - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2022-12-31 00:31:50 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2022-12-31 00:31:50 +0900 - - Fix test when Ruby is verbose - - The test added in 90a80eb0 fails if Ruby is verbose, it outputs the - following line to stderr: - - RUBY_GC_HEAP_INIT_SLOTS=100 (default value: 10000) - -commit 90a80eb076429978e720e11fb17a3cbb96de3454 - Author: Peter Zhu <peter@peterzhu.ca> - AuthorDate: 2022-12-30 10:27:09 +0900 - Commit: Peter Zhu <peter@peterzhu.ca> - CommitDate: 2022-12-30 23:01:50 +0900 - - Fix integer underflow when using HEAP_INIT_SLOTS - - There is an integer underflow when the environment variable - RUBY_GC_HEAP_INIT_SLOTS is less than the number of slots currently - in the Ruby heap. - - [Bug #19284] - - Notes: - Merged: https://github.com/ruby/ruby/pull/7044 - -commit 36c4dda738bc865af681049209fb6a1eb1ae3f49 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-30 20:21:51 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2022-12-30 22:10:41 +0900 - - [rubygems/rubygems] Fix a typo - - https://github.com/rubygems/rubygems/commit/7c096a5df8 - -commit f430701b1bd4583ccea2bc9831febf1924949398 - Author: John Bampton <jbampton@users.noreply.github.com> - AuthorDate: 2022-12-29 22:20:39 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2022-12-29 22:20:39 +0900 - - [DOC] remove space from inside code span element - - Notes: - Merged: https://github.com/ruby/ruby/pull/7036 - - Merged-By: nobu <nobu@ruby-lang.org> - -commit b3d330c39ebbf27cefc2d83109dad9e0b3b0e94f - Author: Kevin Murphy <kevin-j-m@users.noreply.github.com> - AuthorDate: 2022-12-29 17:23:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2022-12-29 17:23:25 +0900 - - Coverage.supported? recognizes oneshot_lines mode (#7040) - - This adds oneshot_lines as a mode of coverage that is supported. - - Notes: - Merged-By: ioquatix <samuel@codeotaku.com> - -commit cada537040743cbe49aac6740816d648ca0d3fb6 - Author: Kouhei Yanagita <yanagi@shakenbu.org> - AuthorDate: 2022-12-28 21:51:33 +0900 - Commit: Victor Shepelev <zverok.offline@gmail.com> - CommitDate: 2022-12-29 01:43:05 +0900 - - [DOC] Fix call-seq for Data.define - - Notes: - Merged: https://github.com/ruby/ruby/pull/7038 - -commit b726d60c986bf951d13e7a2ab5f5e58f58657b03 - Author: TSUYUSATO Kitsune <make.just.on@gmail.com> - AuthorDate: 2022-12-28 20:03:25 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2022-12-28 20:03:25 +0900 - - Fix [Bug 19273], set correct value to `outer_repeat` on `OP_REPEAT` (#7035) - - Notes: - Merged-By: makenowjust <make.just.on@gmail.com> - -commit 393192160726d6b299ca1f66fad9414e4bf8109a - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2022-12-28 15:46:16 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2022-12-28 15:46:16 +0900 - - add debug print for the failure - - http://ci.rvm.jp/results/trunk-gc-asserts@ruby-sp2-docker/4364584 - - ``` - 1) Failure: - TestObjSpace#test_dump_all [/tmp/ruby/src/trunk-gc-asserts/test/objspace/test_objspace.rb:599]: - number of strings. - <2> expected but was - <3>. - ``` - -commit c6c7f5900f8664ec9cab0c300324f973aa911d9b - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-23 11:46:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-28 09:15:31 +0900 - - Test bundler and bundled gems by exam - - Notes: - Merged: https://github.com/ruby/ruby/pull/7009 - -commit 84a4f1b3b27864ea334ead4ea82a18e6d26c06dc - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-23 11:46:21 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-28 09:15:31 +0900 - - Order test-bundler-parallel dependency - - Notes: - Merged: https://github.com/ruby/ruby/pull/7009 - -commit ec7e082906d5c32c5e895137fd0d562fa237ca12 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2022-12-28 02:05:28 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2022-12-28 02:05:32 +0900 - - [ruby/irb] Refactor RubyLex#process_literal_type - (https://github.com/ruby/irb/pull/350) - - Simplify part of regex ``[_a-zA-Z0-9]`` with equivalent shorthand ``\w``. - Replace case-when with match ``$1`` or default value ``?"``, making intention more clear. - -commit 140c93e2dcdccc640a3be3ad6b5f7a7696587dbc - Author: Stan Lo <stan001212@gmail.com> - AuthorDate: 2022-12-28 01:43:40 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2022-12-28 01:43:44 +0900 - - [ruby/irb] Add dynamic prompt test case for quoted heredoc - (https://github.com/ruby/irb/pull/486) - - https://github.com/ruby/irb/commit/31cfbeacbb - -commit db19714b17e365d11ceb13e0d16c8cf3c837f38c - Author: Eric Wong <normal@ruby-lang.org> - AuthorDate: 2022-12-27 10:32:07 +0900 - Commit: Eric Wong <normal@ruby-lang.org> - CommitDate: 2022-12-27 10:32:07 +0900 - - load.c: remove unneeded rb_str_freeze calls - - rb_fstring already resizes and freezes the string, so there's no - need to use rb_str_freeze. - -commit c09f342d04c62c9a75c855bad92efe06ee698280 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2022-12-26 18:16:20 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2022-12-27 09:09:12 +0900 - - [ruby/irb] Fix wrong conf path with XDG_CONFIG_HOME. It should be under the HOME directory, not current directory - - https://github.com/ruby/irb/commit/33a5e55ffd - -commit 8f678d61a597fc2871031d7a38698f3dd63d8c29 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2022-12-25 00:55:32 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2022-12-27 07:17:18 +0900 - - [ruby/net-http] Adding links to references - - https://github.com/ruby/net-http/commit/1c8151aaf3 - -commit d5985049c7a0907f2f00388d29fc0f499adf09f2 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-27 06:10:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2022-12-27 06:10:37 +0900 - - Sync IRB master: tool/sync_default_gems.rb irb - - It looks like tool/sync_default_gems.rb is not capable of cherry-picking - commits from ruby/irb. I just executed `tool/sync_default_gems.rb irb` - to fix the sync status. - - I'm not sure if what's the cause. It could be related to some diff that - doesn't exist in ruby/ruby, or it might be related to non-linear history - due to merge commits. For next time, I'd like to at least exclude the - second possibility, so I disabled merge commits in ruby/irb. - -commit d01bcf378bf39e4a9da2fab85f5f589b218c3080 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-10-28 16:32:36 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2022-12-27 06:04:04 +0900 - - [ruby/irb] Suppress "switching inspect mode" messages - - https://github.com/ruby/irb/commit/565eeb3c19 - -commit 87988756d0ad0c494c7589d75a079207ce0747ee - Author: Stan Lo <stan.lo@shopify.com> - AuthorDate: 2022-10-26 23:44:01 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2022-12-27 06:04:04 +0900 - - [ruby/irb] Remove unnecessary warning check on help command - - It's not an intentional behavior of the command and it behaves - differently in different environments. So checking it actually brings - more problem than benefit. - - https://github.com/ruby/irb/commit/b3203bc784 - -commit 148eb05ec138acec8f1b527a81ec498811bc311d - Author: Stan Lo <stan.lo@shopify.com> - AuthorDate: 2022-10-26 04:43:45 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2022-12-27 06:04:03 +0900 - - [ruby/irb] Remove unnecessary test setup - - https://github.com/ruby/irb/commit/cc6e6d26b6 - -commit 8038bf239af09b34f7a33a66d638cde416ba2893 - Author: st0012 <stan001212@gmail.com> - AuthorDate: 2022-10-25 06:52:52 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2022-12-27 06:04:03 +0900 - - [ruby/irb] Add test for the help command - - https://github.com/ruby/irb/commit/9cacb5f352 - -commit 953d4c22edab50bdc6498e256d2d6400f8fcd78a - Author: tompng <tomoyapenguin@gmail.com> - AuthorDate: 2022-08-04 14:49:17 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2022-12-27 06:03:07 +0900 - - [ruby/irb] fix indent depth calculation after heredoc and embdoc - - https://github.com/ruby/irb/commit/b7973dd2d2 - -commit f20aac5c5980d7cb555db2d478d862328eca7620 - Author: tompng <tomoyapenguin@gmail.com> - AuthorDate: 2022-08-03 01:57:43 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2022-12-27 06:03:07 +0900 - - [ruby/irb] fix auto-indent after multiline string - - https://github.com/ruby/irb/commit/f65ec49684 - -commit f5a035daf9a399b62c05fbc90beb1bb42380d1f4 - Author: Gustavo Ribeiro <g2_ribeiro@hotmail.com> - AuthorDate: 2022-12-23 03:24:58 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2022-12-27 04:08:55 +0900 - - [rubygems/rubygems] deprecate gem build -C flag - - https://github.com/rubygems/rubygems/commit/fac241d4ef - -commit 08f6196bdac6b53df35caa5810839d28100d073c - Author: Gustavo Ribeiro <g2_ribeiro@hotmail.com> - AuthorDate: 2022-12-23 03:24:34 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2022-12-27 04:08:55 +0900 - - [rubygems/rubygems] add global flag (-C) to change execution directory - - https://github.com/rubygems/rubygems/commit/312fc36711 - -commit a968d783a3dbd3585b6285c5c9c9ef11bd36b6f4 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-27 00:01:46 +0900 - Commit: git[bot] <svn-admin@ruby-lang.org> - CommitDate: 2022-12-27 00:28:38 +0900 - - [ruby/irb] Test colors with enabling colors - - https://github.com/ruby/irb/commit/998b7a74fa - -commit d93d786338b3dca54595a6619f433607a834816a - Author: Benoit Daloze <eregontp@gmail.com> - AuthorDate: 2022-12-26 23:28:37 +0900 - Commit: Benoit Daloze <eregontp@gmail.com> - CommitDate: 2022-12-26 23:28:37 +0900 - - Try to fix RDoc markup for Enumerator - -commit c182d46d2477da9283661c8b4544d7da095835b4 - Author: Koichi Sasada <ko1@atdot.net> - AuthorDate: 2022-12-26 21:57:27 +0900 - Commit: Koichi Sasada <ko1@atdot.net> - CommitDate: 2022-12-26 23:06:35 +0900 - - check `NO_COLOR` envval - - Support `NO_COLOR` (https://no-color.org/) to make parsing output easy. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7030 - -commit 9f2378959e5c5b5c39c9993f1a84e5304ff113d6 - Author: Kenta Murata <mrkn@mrkn.jp> - AuthorDate: 2022-12-26 21:02:47 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2022-12-26 21:02:47 +0900 - - numeric.c: Fix round_half_even for specific values (#7023) - - Handle the integert and the float parts separately in round_half_even - to prevent error occursions in floating point calculation. - - Notes: - Merged-By: mrkn <mrkn@ruby-lang.org> - -commit bb60e4615f49a4dbc4f0eb776c8773feabb1a66f - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-26 17:59:51 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2022-12-26 20:29:56 +0900 - - [DOC] Un-capitalize headings - - Notes: - Merged: https://github.com/ruby/ruby/pull/7027 - -commit cb820bff33783a469dcb0f13aa42ab22e521557e - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-26 17:04:53 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2022-12-26 20:29:56 +0900 - - [DOC] Update extension.rdoc - - Refine the uses of word "Data", which were often ambiguous. Also, - that word now refers the new class unrelated to `T_DATA`. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7027 - -commit b37e9c77fe23f76501e5613276049ed8fc26ab6c - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-26 20:29:06 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2022-12-26 20:29:06 +0900 - - Suppress method redefinition warnings - -commit 5e54c57d83949818200bcec069455d713be681ff - Author: Marco Costa <marco.costa@datadoghq.com> - AuthorDate: 2022-12-24 07:00:47 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2022-12-26 17:40:11 +0900 - - [DOC] Surface existing MonitorMixin documentation - - Notes: - Merged: https://github.com/ruby/ruby/pull/7017 - -commit fc03ba50f1ff6c30f7c654f564b4dffbed0844ef - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-26 15:48:35 +0900 - Commit: Takashi Kokubun <takashikkbn@gmail.com> - CommitDate: 2022-12-26 15:48:36 +0900 - - MJIT: Fix JIT code for multiple values in a single case - - [Bug #19263] - -commit b7ad60a79440f65cf883d3ff9dbdde701666ef56 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2022-12-26 14:00:11 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 15:09:21 +0900 - - Merge RubyGems/Bundler master - - from https://github.com/rubygems/rubygems/commit/72fd3dd2096af16d797ad0cd8e0d2a8869e240b3 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7025 - -commit 10c9ce9d4c632d7c6232b53367b0496aef2ebb13 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2022-12-09 05:58:40 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 15:09:21 +0900 - - bump up to 3.0.5 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7025 - -commit 24c9adcaebf8ffaaf3f4eb68fe43f2ff23688543 - Author: Kazuki Yamaguchi <k@rhe.jp> - AuthorDate: 2022-12-24 02:02:13 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 15:09:21 +0900 - - [ruby/openssl] test/openssl/test_pkey.rb: allow failures in test_s_generate_parameters - - Commit https://github.com/ruby/openssl/commit/f2e2a5e5ed8e ("test/openssl/test_pkey.rb: allow failures in - test_s_generate_parameters", 2022-12-23) was completely bogus. The - problem in OpenSSL 3.0.0-3.0.5 is that errors from the callback are - sometimes silently suppressed. - - https://github.com/ruby/openssl/commit/ccc1594492 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7025 - -commit cea6951ecf31b1d4e93d102cc8f08822470d4d1a - Author: Junichi Ito <jit@sonicgarden.jp> - AuthorDate: 2022-11-29 08:07:47 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 15:09:21 +0900 - - [ruby/optparse] Add symbolize_names to getopts - - https://github.com/ruby/optparse/commit/3e63d878f8 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7025 - -commit 4c767c1354038804abd1c94e7f549ed4f95a3d31 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-22 19:57:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 15:09:21 +0900 - - [ruby/optparse] bump up to 0.4.0.pre.1 - - https://github.com/ruby/optparse/commit/73661899ad - - Notes: - Merged: https://github.com/ruby/ruby/pull/7025 - -commit 8c8645f57895d97f5f3da06759c10853ba705a22 - Author: Burdette Lamar <BurdetteLamar@Yahoo.com> - AuthorDate: 2022-12-22 23:19:45 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 15:09:21 +0900 - - [ruby/net-http] [DOC] Adding links to references - (https://github.com/ruby/net-http/pull/97) - - https://github.com/ruby/net-http/commit/768115167a - - Notes: - Merged: https://github.com/ruby/ruby/pull/7025 - -commit 35aba09e7f0d6b643c6446f44acdec654519ca64 - Author: BurdetteLamar <burdettelamar@yahoo.com> - AuthorDate: 2022-12-22 02:21:37 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 15:09:21 +0900 - - [ruby/net-http] Adding links to references - - https://github.com/ruby/net-http/commit/b85530e6b8 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7025 - -commit 50e58df0e365dccd0493a1c3cdd30930c685d1ab - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2022-12-08 11:52:51 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 15:09:21 +0900 - - [ruby/csv] Bump version - - https://github.com/ruby/csv/commit/8606ee83e0 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7025 - -commit 79ad0452146e6ceacc9387bc78d74a53f6a20767 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2022-12-08 14:22:37 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 15:09:21 +0900 - - [ruby/strscan] Bump version - - https://github.com/ruby/strscan/commit/3ada12613d - - Notes: - Merged: https://github.com/ruby/ruby/pull/7025 - -commit 8df574a492a70eb6161719c427deb55eb68c9c47 - Author: Mau Magnaguagno <maumagnaguagno@gmail.com> - AuthorDate: 2022-12-20 10:27:03 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 15:09:21 +0900 - - [ruby/fiddle] Prefer String#unpack1 in Fiddle::ValueUtil - (https://github.com/ruby/fiddle/pull/118) - - String#unpack1 is available since Ruby 2.4, and support for older than - Ruby 2.5 was dropped by #85. - Also simplified a common return statement. - - Notes: - Merged: https://github.com/ruby/ruby/pull/7025 - -commit 1dc8c18b7270ca172fe301bd7f1db93fae6ae575 - Author: Sutou Kouhei <kou@clear-code.com> - AuthorDate: 2022-12-08 12:07:30 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 15:09:21 +0900 - - [ruby/fiddle] Bump version - - https://github.com/ruby/fiddle/commit/3033266902 - - Notes: - Merged: https://github.com/ruby/ruby/pull/7025 - -commit cc25e81fb7f2e3dd7f16bc654bfd7389c0cd212e - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2022-12-26 13:26:06 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 15:09:21 +0900 - - Update generated version of racc on parser headers - - Notes: - Merged: https://github.com/ruby/ruby/pull/7025 - -commit 5df711844586312891bb466dbc72265490488d94 - Author: Nobuyoshi Nakada <nobu@ruby-lang.org> - AuthorDate: 2022-12-26 14:57:20 +0900 - Commit: Nobuyoshi Nakada <nobu@ruby-lang.org> - CommitDate: 2022-12-26 15:01:44 +0900 - - Skip insanely memory consuming tests - - These tests do not only consume hundreds GiB bytes memory, result in - `rb_bug` when `RUBY_DEBUG` is enabled. - -commit 509da028c2249cd386190f2856e91549cc9e6c23 - Author: Takashi Kokubun <takashikkbn@gmail.com> - AuthorDate: 2022-12-26 14:46:29 +0900 - Commit: GitHub <noreply@github.com> - CommitDate: 2022-12-26 14:46:29 +0900 - - Rewrite Kernel#loop in Ruby (#6983) - - * Rewrite Kernel#loop in Ruby - - * Use enum_for(:loop) { Float::INFINITY } - - Co-authored-by: Ufuk Kayserilioglu <ufuk@paralaus.com> - - * Limit the scope to rescue StopIteration - - Co-authored-by: Ufuk Kayserilioglu <ufuk@paralaus.com> - - Notes: - Merged-By: k0kubun <takashikkbn@gmail.com> - -commit a236661a62dc89173dcdd9e071365929db1201a7 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2022-12-26 13:52:48 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 13:52:48 +0900 - - Skip some examples for Ruby 3.3 - -commit 5ec94ff7400c812b4e662560271540bc5690d307 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2022-12-26 13:17:31 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 13:17:33 +0900 - - Generate parser-text.rb of racc when sync it - -commit 1066d42ca8d9e55b415ad4d6abbe0c514a5d4add - Author: Jeremy Evans <code@jeremyevans.net> - AuthorDate: 2022-12-26 12:14:13 +0900 - Commit: Jeremy Evans <code@jeremyevans.net> - CommitDate: 2022-12-26 12:14:13 +0900 - - Enable arm64 coroutine implementation on OpenBSD/arm64 - - Tested by another OpenBSD developer and confirmed to significantly - improve things. - -commit cd6c7613f31a371326d86de55af15918d6aa01f1 - Author: Hiroshi SHIBATA <hsbt@ruby-lang.org> - AuthorDate: 2022-12-26 12:06:32 +0900 - Commit: Hiroshi SHIBATA <hsbt@ruby-lang.org> - CommitDate: 2022-12-26 12:07:42 +0900 - - Apply the accidental commits again before Ruby 3.2. - - Reverts the following commits: - - eb8d4d7b5145849325985c00b810b8d75661d86e - edb83dc3a2c374e880e8eb488152872152790e92 - d40064d1846b5835dff81e3f168c0c3a6c85e814 - -commit 2a6dbf03a2630f858d918dd6fd49393632530d51 - Author: Yukihiro "Matz" Matsumoto <matz@ruby.or.jp> - AuthorDate: 2022-12-26 08:46:59 +0900 - Commit: Yukihiro "Matz" Matsumoto <matz@ruby.or.jp> - CommitDate: 2022-12-26 08:46:59 +0900 - - Development of 3.3.0 started. diff -Nru ruby3.3-3.3.8/bignum.c ruby3.3-3.3.13/bignum.c --- ruby3.3-3.3.8/bignum.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/bignum.c 2026-10-23 03:17:41.000000000 +0000 @@ -6333,7 +6333,7 @@ BDIGIT hibitsy; if (y == 0) return INT2FIX(0); - if (xn == 0) return hibitsx ? LONG2NUM(y) : 0; + if (xn == 0) return hibitsx ? LONG2NUM(y) : INT2FIX(0); hibitsy = 0 <= y ? 0 : BDIGMAX; xds = BDIGITS(x); #if SIZEOF_BDIGIT >= SIZEOF_LONG @@ -7008,7 +7008,7 @@ zn = mn; z = bignew(zn, 1); bary_powm_gmp(BDIGITS(z), zn, BDIGITS(x), xn, BDIGITS(y), yn, BDIGITS(m), mn); - if (nega_flg & BIGNUM_POSITIVE_P(z)) { + if (nega_flg && BIGNUM_POSITIVE_P(z) && !BIGZEROP(z)) { z = rb_big_minus(z, m); } RB_GC_GUARD(x); @@ -7036,7 +7036,7 @@ x = rb_int_modulo(x, m); } - if (nega_flg && rb_int_positive_p(tmp)) { + if (nega_flg && rb_int_positive_p(tmp) && !rb_int_zero_p(tmp)) { tmp = rb_int_minus(tmp, m); } return tmp; @@ -7148,6 +7148,11 @@ rb_raise(rb_eTypeError, "Integer#pow() 2nd argument not allowed unless all arguments are integers"); } + if (rb_int_zero_p(a) && !rb_int_zero_p(b)) { + /* shortcut; 0**x => 0 except for x == 0 */ + return INT2FIX(0); + } + if (rb_int_negative_p(m)) { m = rb_int_uminus(m); nega_flg = 1; diff -Nru ruby3.3-3.3.8/bootstraptest/test_fork.rb ruby3.3-3.3.13/bootstraptest/test_fork.rb --- ruby3.3-3.3.8/bootstraptest/test_fork.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/bootstraptest/test_fork.rb 2026-10-23 03:17:41.000000000 +0000 @@ -88,14 +88,19 @@ 10.times do pid = fork{ exit!(0) } - deadline = now + 1 - until Process.waitpid(pid, Process::WNOHANG) + deadline = now + 10 + while true + _, status = Process.waitpid2(pid, Process::WNOHANG) + break if status if now > deadline Process.kill(:KILL, pid) raise "failed" end sleep 0.001 end + unless status.success? + raise "child exited with status #{status}" + end rescue NotImplementedError end :ok diff -Nru ruby3.3-3.3.8/bootstraptest/test_ractor.rb ruby3.3-3.3.13/bootstraptest/test_ractor.rb --- ruby3.3-3.3.8/bootstraptest/test_ractor.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/bootstraptest/test_ractor.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1773,3 +1773,15 @@ } end # if !ENV['GITHUB_WORKFLOW'] + +# Using Symbol#to_proc inside ractors +# [Bug #21354] +assert_equal 'ok', %q{ + :inspect.to_proc + Ractor.new do + # It should not use this cached proc, it should create a new one. If it used + # the cached proc, we would get a ractor_confirm_belonging error here. + :inspect.to_proc + end.take + 'ok' +} diff -Nru ruby3.3-3.3.8/bootstraptest/test_yjit.rb ruby3.3-3.3.13/bootstraptest/test_yjit.rb --- ruby3.3-3.3.8/bootstraptest/test_yjit.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/bootstraptest/test_yjit.rb 2026-10-23 03:17:41.000000000 +0000 @@ -3491,6 +3491,74 @@ test } +# Bug #21257 (infinite jmp) +assert_equal 'ok', %q{ + Good = :ok + + def first + second + end + + def second + ::Good + end + + # Make `second` side exit on its first instruction + trace = TracePoint.new(:line) { } + trace.enable(target: method(:second)) + + first + # Recompile now that the constant cache is populated, so we get a fallthrough from `first` to `second` + # (this is need to reproduce with --yjit-call-threshold=1) + RubyVM::YJIT.code_gc if defined?(RubyVM::YJIT) + first + + # Trigger a constant cache miss in rb_vm_opt_getconstant_path (in `second`) next time it's called + module InvalidateConstantCache + Good = nil + end + + RubyVM::YJIT.simulate_oom! if defined?(RubyVM::YJIT) + + first + first +} + +assert_equal 'ok', %q{ + # Multiple incoming branches into second + Good = :ok + + def incoming_one + second + end + + def incoming_two + second + end + + def second + ::Good + end + + # Make `second` side exit on its first instruction + trace = TracePoint.new(:line) { } + trace.enable(target: method(:second)) + + incoming_one + # Recompile now that the constant cache is populated, so we get a fallthrough from `incoming_one` to `second` + # (this is need to reproduce with --yjit-call-threshold=1) + RubyVM::YJIT.code_gc if defined?(RubyVM::YJIT) + incoming_one + incoming_two + + # Trigger a constant cache miss in rb_vm_opt_getconstant_path (in `second`) next time it's called + module InvalidateConstantCache + Good = nil + end + + incoming_one +} + assert_equal 'ok', %q{ # Try to compile new method while OOM def foo @@ -4517,3 +4585,13 @@ new.foo end } + +# regression test for splat with &proc{} when the target has rest (Bug #21266) +assert_equal '[]', %q{ + def foo(args) = bar(*args, &proc { _1 }) + def bar(_, _, _, _, *rest) = yield rest + + GC.stress = true + foo([1,2,3,4]) + foo([1,2,3,4]) +} diff -Nru ruby3.3-3.3.8/common.mk ruby3.3-3.3.13/common.mk --- ruby3.3-3.3.8/common.mk 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/common.mk 2026-10-23 03:17:41.000000000 +0000 @@ -46,7 +46,7 @@ # GITPULLOPTIONS = --no-tags PRISM_SRCDIR = $(srcdir)/prism -INCFLAGS = -I. -I$(arch_hdrdir) -I$(hdrdir) -I$(srcdir) -I$(PRISM_SRCDIR) -I$(UNICODE_HDR_DIR) $(incflags) +INCFLAGS = -I. -I$(arch_hdrdir) -I$(ext_hdrdir) -I$(hdrdir) -I$(srcdir) -I$(PRISM_SRCDIR) -I$(UNICODE_HDR_DIR) $(incflags) GEM_HOME = GEM_PATH = @@ -835,6 +835,12 @@ -$(Q) $(RMDIR) $(PLATFORM_DIR) 2> $(NULL) || $(NULLCMD) RUBYSPEC_CAPIEXT = spec/ruby/optional/capi/ext +RUBYSPEC_CAPIEXT_SRCDIR = $(srcdir)/$(RUBYSPEC_CAPIEXT) +RUBYSPEC_CAPIEXT_DEPS = $(RUBYSPEC_CAPIEXT_SRCDIR)/rubyspec.h $(RUBY_H_INCLUDES) $(LIBRUBY) + +rubyspec-capiext: build-ext $(DOT_WAIT) +# make-dependent rules should be included after this and built after build-ext. + clean-spec: PHONY -$(Q) $(RM) $(RUBYSPEC_CAPIEXT)/*.$(OBJEXT) $(RUBYSPEC_CAPIEXT)/*.$(DLEXT) -$(Q) $(RMDIRS) $(RUBYSPEC_CAPIEXT) 2> $(NULL) || $(NULLCMD) @@ -1575,30 +1581,8 @@ test-bundled-gems-run: $(PREPARE_BUNDLED_GEMS) $(gnumake_recursive)$(Q) $(XRUBY) $(tooldir)/test-bundled-gems.rb $(BUNDLED_GEMS) -test-syntax-suggest-precheck: $(TEST_RUNNABLE)-test-syntax-suggest-precheck -no-test-syntax-suggest-precheck: -yes-test-syntax-suggest-precheck: main - -test-syntax-suggest-prepare: $(TEST_RUNNABLE)-test-syntax-suggest-prepare -no-test-syntax-suggest-prepare: no-test-syntax-suggest-precheck -yes-test-syntax-suggest-prepare: yes-test-syntax-suggest-precheck - $(ACTIONS_GROUP) - $(XRUBY) -C "$(srcdir)" bin/gem install --no-document \ - --install-dir .bundle --conservative "rspec:~> 3" - $(ACTIONS_ENDGROUP) -RSPECOPTS = -SYNTAX_SUGGEST_SPECS = -PREPARE_SYNTAX_SUGGEST = $(TEST_RUNNABLE)-test-syntax-suggest-prepare -test-syntax-suggest: $(TEST_RUNNABLE)-test-syntax-suggest -yes-test-syntax-suggest: $(PREPARE_SYNTAX_SUGGEST) - $(ACTIONS_GROUP) - $(XRUBY) -C $(srcdir) -Ispec/syntax_suggest:spec/lib .bundle/bin/rspec \ - --require rspec/expectations \ - --require spec_helper --require formatter_overrides --require spec_coverage \ - $(RSPECOPTS) spec/syntax_suggest/$(SYNTAX_SUGGEST_SPECS) - $(ACTIONS_ENDGROUP) -no-test-syntax-suggest: +test-syntax-suggest: check: $(DOT_WAIT) $(PREPARE_SYNTAX_SUGGEST) test-syntax-suggest @@ -7503,6 +7487,7 @@ goruby.$(OBJEXT): {$(VPATH)}internal/attr/noexcept.h goruby.$(OBJEXT): {$(VPATH)}internal/attr/noinline.h goruby.$(OBJEXT): {$(VPATH)}internal/attr/nonnull.h +goruby.$(OBJEXT): {$(VPATH)}internal/attr/nonstring.h goruby.$(OBJEXT): {$(VPATH)}internal/attr/noreturn.h goruby.$(OBJEXT): {$(VPATH)}internal/attr/packed_struct.h goruby.$(OBJEXT): {$(VPATH)}internal/attr/pure.h @@ -9523,6 +9508,7 @@ marshal.$(OBJEXT): {$(VPATH)}internal/attr/noexcept.h marshal.$(OBJEXT): {$(VPATH)}internal/attr/noinline.h marshal.$(OBJEXT): {$(VPATH)}internal/attr/nonnull.h +marshal.$(OBJEXT): {$(VPATH)}internal/attr/nonstring.h marshal.$(OBJEXT): {$(VPATH)}internal/attr/noreturn.h marshal.$(OBJEXT): {$(VPATH)}internal/attr/packed_struct.h marshal.$(OBJEXT): {$(VPATH)}internal/attr/pure.h @@ -10132,6 +10118,7 @@ miniinit.$(OBJEXT): {$(VPATH)}internal/attr/noexcept.h miniinit.$(OBJEXT): {$(VPATH)}internal/attr/noinline.h miniinit.$(OBJEXT): {$(VPATH)}internal/attr/nonnull.h +miniinit.$(OBJEXT): {$(VPATH)}internal/attr/nonstring.h miniinit.$(OBJEXT): {$(VPATH)}internal/attr/noreturn.h miniinit.$(OBJEXT): {$(VPATH)}internal/attr/packed_struct.h miniinit.$(OBJEXT): {$(VPATH)}internal/attr/pure.h @@ -12801,6 +12788,8 @@ proc.$(OBJEXT): {$(VPATH)}prism/version.h proc.$(OBJEXT): {$(VPATH)}prism_compile.h proc.$(OBJEXT): {$(VPATH)}proc.c +proc.$(OBJEXT): {$(VPATH)}ractor.h +proc.$(OBJEXT): {$(VPATH)}ractor_core.h proc.$(OBJEXT): {$(VPATH)}ruby_assert.h proc.$(OBJEXT): {$(VPATH)}ruby_atomic.h proc.$(OBJEXT): {$(VPATH)}rubyparser.h @@ -15849,6 +15838,7 @@ scheduler.$(OBJEXT): {$(VPATH)}constant.h scheduler.$(OBJEXT): {$(VPATH)}defines.h scheduler.$(OBJEXT): {$(VPATH)}encoding.h +scheduler.$(OBJEXT): {$(VPATH)}eval_intern.h scheduler.$(OBJEXT): {$(VPATH)}fiber/scheduler.h scheduler.$(OBJEXT): {$(VPATH)}id.h scheduler.$(OBJEXT): {$(VPATH)}id_table.h @@ -16467,6 +16457,7 @@ signal.$(OBJEXT): {$(VPATH)}internal/attr/noexcept.h signal.$(OBJEXT): {$(VPATH)}internal/attr/noinline.h signal.$(OBJEXT): {$(VPATH)}internal/attr/nonnull.h +signal.$(OBJEXT): {$(VPATH)}internal/attr/nonstring.h signal.$(OBJEXT): {$(VPATH)}internal/attr/noreturn.h signal.$(OBJEXT): {$(VPATH)}internal/attr/packed_struct.h signal.$(OBJEXT): {$(VPATH)}internal/attr/pure.h @@ -17226,6 +17217,7 @@ string.$(OBJEXT): {$(VPATH)}internal/attr/noexcept.h string.$(OBJEXT): {$(VPATH)}internal/attr/noinline.h string.$(OBJEXT): {$(VPATH)}internal/attr/nonnull.h +string.$(OBJEXT): {$(VPATH)}internal/attr/nonstring.h string.$(OBJEXT): {$(VPATH)}internal/attr/noreturn.h string.$(OBJEXT): {$(VPATH)}internal/attr/packed_struct.h string.$(OBJEXT): {$(VPATH)}internal/attr/pure.h @@ -17684,6 +17676,7 @@ symbol.$(OBJEXT): {$(VPATH)}internal/attr/noexcept.h symbol.$(OBJEXT): {$(VPATH)}internal/attr/noinline.h symbol.$(OBJEXT): {$(VPATH)}internal/attr/nonnull.h +symbol.$(OBJEXT): {$(VPATH)}internal/attr/nonstring.h symbol.$(OBJEXT): {$(VPATH)}internal/attr/noreturn.h symbol.$(OBJEXT): {$(VPATH)}internal/attr/packed_struct.h symbol.$(OBJEXT): {$(VPATH)}internal/attr/pure.h diff -Nru ruby3.3-3.3.8/compile.c ruby3.3-3.3.13/compile.c --- ruby3.3-3.3.8/compile.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/compile.c 2026-10-23 03:17:41.000000000 +0000 @@ -9783,7 +9783,7 @@ if (nd_fl_newline(node)) { int event = RUBY_EVENT_LINE; ISEQ_COMPILE_DATA(iseq)->last_line = line; - if (ISEQ_COVERAGE(iseq) && ISEQ_LINE_COVERAGE(iseq)) { + if (line > 0 && ISEQ_COVERAGE(iseq) && ISEQ_LINE_COVERAGE(iseq)) { event |= RUBY_EVENT_COVERAGE_LINE; } ADD_TRACE(ret, event); @@ -11825,6 +11825,9 @@ struct rb_call_data *cd_entries = load_body->call_data; int ic_index = 0; + load_body->iseq_encoded = code; + load_body->iseq_size = 0; + iseq_bits_t * mark_offset_bits; iseq_bits_t tmp[1] = {0}; @@ -11956,7 +11959,6 @@ } } - load_body->iseq_encoded = code; load_body->iseq_size = code_index; if (ISEQ_MBITS_BUFLEN(load_body->iseq_size) == 1) { @@ -12186,7 +12188,7 @@ } static struct iseq_catch_table * -ibf_load_catch_table(const struct ibf_load *load, ibf_offset_t catch_table_offset, unsigned int size) +ibf_load_catch_table(const struct ibf_load *load, ibf_offset_t catch_table_offset, unsigned int size, const rb_iseq_t *parent_iseq) { if (size) { struct iseq_catch_table *table = ruby_xmalloc(iseq_catch_table_bytes(size)); @@ -12203,7 +12205,8 @@ table->entries[i].cont = (unsigned int)ibf_load_small_value(load, &reading_pos); table->entries[i].sp = (unsigned int)ibf_load_small_value(load, &reading_pos); - table->entries[i].iseq = ibf_load_iseq(load, (const rb_iseq_t *)(VALUE)iseq_index); + rb_iseq_t *catch_iseq = (rb_iseq_t *)ibf_load_iseq(load, (const rb_iseq_t *)(VALUE)iseq_index); + RB_OBJ_WRITE(parent_iseq, UNALIGNED_MEMBER_PTR(&table->entries[i], iseq), catch_iseq); } return table; } @@ -12697,10 +12700,14 @@ load_body->insns_info.body = ibf_load_insns_info_body(load, insns_info_body_offset, insns_info_size); load_body->insns_info.positions = ibf_load_insns_info_positions(load, insns_info_positions_offset, insns_info_size); load_body->local_table = ibf_load_local_table(load, local_table_offset, local_table_size); - load_body->catch_table = ibf_load_catch_table(load, catch_table_offset, catch_table_size); - load_body->parent_iseq = ibf_load_iseq(load, (const rb_iseq_t *)(VALUE)parent_iseq_index); - load_body->local_iseq = ibf_load_iseq(load, (const rb_iseq_t *)(VALUE)local_iseq_index); - load_body->mandatory_only_iseq = ibf_load_iseq(load, (const rb_iseq_t *)(VALUE)mandatory_only_iseq_index); + load_body->catch_table = ibf_load_catch_table(load, catch_table_offset, catch_table_size, iseq); + const rb_iseq_t *parent_iseq = ibf_load_iseq(load, (const rb_iseq_t *)(VALUE)parent_iseq_index); + const rb_iseq_t *local_iseq = ibf_load_iseq(load, (const rb_iseq_t *)(VALUE)local_iseq_index); + const rb_iseq_t *mandatory_only_iseq = ibf_load_iseq(load, (const rb_iseq_t *)(VALUE)mandatory_only_iseq_index); + + RB_OBJ_WRITE(iseq, &load_body->parent_iseq, parent_iseq); + RB_OBJ_WRITE(iseq, &load_body->local_iseq, local_iseq); + RB_OBJ_WRITE(iseq, &load_body->mandatory_only_iseq, mandatory_only_iseq); ibf_load_code(load, iseq, bytecode_offset, bytecode_size, iseq_size); #if VM_INSN_INFO_TABLE_IMPL == 2 @@ -12923,8 +12930,10 @@ static VALUE ibf_load_object_float(const struct ibf_load *load, const struct ibf_object_header *header, ibf_offset_t offset) { - const double *dblp = IBF_OBJBODY(double, offset); - return DBL2NUM(*dblp); + double d; + /* Avoid unaligned VFP load on ARMv7; IBF payload may be unaligned (C99 6.3.2.3 p7). */ + memcpy(&d, IBF_OBJBODY(double, offset), sizeof(d)); + return DBL2NUM(d); } static void diff -Nru ruby3.3-3.3.8/configure ruby3.3-3.3.13/configure --- ruby3.3-3.3.8/configure 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/configure 2026-10-23 03:17:43.000000000 +0000 @@ -12889,8 +12889,6 @@ ac_cv_func_gmtime_r=yes rb_cv_large_fd_select=yes ac_cv_type_struct_timeval=yes - ac_cv_func_clock_gettime=yes - ac_cv_func_clock_getres=yes ac_cv_func_malloc_usable_size=no ac_cv_type_off_t=yes ac_cv_sizeof_off_t=8 @@ -28983,9 +28981,7 @@ #include <time.h> void -check(tm, y, m, d, h, s) - struct tm *tm; - int y, m, d, h, s; +check(struct tm *tm, int y, int m, int d, int h, int s) { if (!tm || tm->tm_year != y || @@ -29132,8 +29128,7 @@ #include <signal.h> void -sig_handler(dummy) - int dummy; +sig_handler(int dummy) { } @@ -32078,6 +32073,7 @@ then : LIBRUBY_DLDFLAGS="$LIBRUBY_DLDFLAGS "'-Wl,-unexported_symbol,_Init_*' + LIBRUBY_DLDFLAGS="$LIBRUBY_DLDFLAGS "'-Wl,-unexported_symbol,_InitVM_*' LIBRUBY_DLDFLAGS="$LIBRUBY_DLDFLAGS "'-Wl,-unexported_symbol,_ruby_static_id_*' LIBRUBY_DLDFLAGS="$LIBRUBY_DLDFLAGS "'-Wl,-unexported_symbol,*_threadptr_*' diff -Nru ruby3.3-3.3.8/configure.ac ruby3.3-3.3.13/configure.ac --- ruby3.3-3.3.8/configure.ac 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/configure.ac 2026-10-23 03:17:41.000000000 +0000 @@ -1210,8 +1210,6 @@ ac_cv_func_gmtime_r=yes rb_cv_large_fd_select=yes ac_cv_type_struct_timeval=yes - ac_cv_func_clock_gettime=yes - ac_cv_func_clock_getres=yes ac_cv_func_malloc_usable_size=no ac_cv_type_off_t=yes ac_cv_sizeof_off_t=8 @@ -2415,9 +2413,7 @@ #include <time.h> void -check(tm, y, m, d, h, s) - struct tm *tm; - int y, m, d, h, s; +check(struct tm *tm, int y, int m, int d, int h, int s) { if (!tm || tm->tm_year != y || @@ -2501,8 +2497,7 @@ #include <signal.h> void -sig_handler(dummy) - int dummy; +sig_handler(int dummy) { } @@ -3625,6 +3620,7 @@ LIBRUBY_DLDFLAGS="$LIBRUBY_DLDFLAGS "'-current_version $(RUBY_PROGRAM_VERSION)' AS_IF([test "$visibility_option" = ld], [ LIBRUBY_DLDFLAGS="$LIBRUBY_DLDFLAGS "'-Wl,-unexported_symbol,_Init_*' + LIBRUBY_DLDFLAGS="$LIBRUBY_DLDFLAGS "'-Wl,-unexported_symbol,_InitVM_*' LIBRUBY_DLDFLAGS="$LIBRUBY_DLDFLAGS "'-Wl,-unexported_symbol,_ruby_static_id_*' LIBRUBY_DLDFLAGS="$LIBRUBY_DLDFLAGS "'-Wl,-unexported_symbol,*_threadptr_*' ]) diff -Nru ruby3.3-3.3.8/cont.c ruby3.3-3.3.13/cont.c --- ruby3.3-3.3.8/cont.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/cont.c 2026-10-23 03:17:41.000000000 +0000 @@ -1518,6 +1518,51 @@ rb_raise(rb_eRuntimeError, "can't call across trace_func"); } +#if defined(__wasm__) && !defined(__EMSCRIPTEN__) + if (th->ec->tag != sec->tag) { + /* find the lowest common ancestor tag of the current EC and the saved EC */ + + struct rb_vm_tag *lowest_common_ancestor = NULL; + size_t num_tags = 0; + size_t num_saved_tags = 0; + for (struct rb_vm_tag *tag = th->ec->tag; tag != NULL; tag = tag->prev) { + ++num_tags; + } + for (struct rb_vm_tag *tag = sec->tag; tag != NULL; tag = tag->prev) { + ++num_saved_tags; + } + + size_t min_tags = num_tags <= num_saved_tags ? num_tags : num_saved_tags; + + struct rb_vm_tag *tag = th->ec->tag; + while (num_tags > min_tags) { + tag = tag->prev; + --num_tags; + } + + struct rb_vm_tag *saved_tag = sec->tag; + while (num_saved_tags > min_tags) { + saved_tag = saved_tag->prev; + --num_saved_tags; + } + + while (min_tags > 0) { + if (tag == saved_tag) { + lowest_common_ancestor = tag; + break; + } + tag = tag->prev; + saved_tag = saved_tag->prev; + --min_tags; + } + + /* free all the jump buffers between the current EC's tag and the lowest common ancestor tag */ + for (struct rb_vm_tag *tag = th->ec->tag; tag != lowest_common_ancestor; tag = tag->prev) { + rb_vm_tag_jmpbuf_deinit(&tag->buf); + } + } +#endif + /* copy vm stack */ #ifdef CAPTURE_JUST_VALID_VM_STACK MEMCPY(th->ec->vm_stack, diff -Nru ruby3.3-3.3.8/debian/changelog ruby3.3-3.3.13/debian/changelog --- ruby3.3-3.3.8/debian/changelog 2025-04-29 10:58:14.000000000 +0000 +++ ruby3.3-3.3.13/debian/changelog 2026-10-30 18:35:16.000000000 +0000 @@ -1,3 +1,55 @@ +ruby3.3 (3.3.13-0+deb13u1) trixie-security; urgency=medium + + * New upstream version 3.3.13. It contains the following security fixes: + - resolv: + + CVE-2025-24294: Fix denial of service caused by excessive CPU + consumption when parsing highly compressed DNS names. + + CVE-2026-80212: Fix unbounded memory consumption when processing + DNS responses containing unknown resource record types. + + CVE-2026-80213: Fix DNS hostname validation bypass caused by + incorrectly handling DNS label and name length limits. + - REXML: + + CVE-2025-58767: Fix denial of service when parsing XML documents + containing multiple XML declarations. + - uri: + + CVE-2025-61594: Fix credential leakage when combining URIs using + the '+' operator. + - zlib: + + CVE-2026-27820: Fix buffer overflow in Zlib::GzipReader. + - erb: + + CVE-2026-41316: Fix deserialization guard bypass allowing + arbitrary code execution through def_method, def_module and + def_class. + - net-imap: + + CVE-2026-42245: Fix denial of service caused by quadratic + processing of IMAP responses containing multiple string literals. + + CVE-2026-42246: Fix STARTTLS stripping vulnerability caused by + incorrect handling of IMAP server responses. + + CVE-2026-42256: Fix denial of service caused by excessive + iteration counts in SCRAM authentication. + + CVE-2026-42257: Fix IMAP command injection through unvalidated + raw command arguments. + + CVE-2026-42258: Fix IMAP command injection through unvalidated + Symbol arguments. + + CVE-2026-47240: Fix IMAP command injection through + non-synchronizing literals in raw arguments. + + CVE-2026-47241: Fix denial of service caused by incomplete + validation of raw IMAP command arguments. + + CVE-2026-47242: Fix IMAP command injection through unvalidated + arguments to the ID and ENABLE commands. + - Onigmo (regular expression engine): + + CVE-2026-89078: Fix a double-free vulnerability in regular + expression compilation. + + CVE-2026-93577: Fix an integer overflow vulnerability in + regular expression compilation. + + CVE-2026-97229: Fix an integer overflow vulnerability in + regular expression compilation. + + CVE-2026-110264: Fix an internal ID overflow vulnerability in + regular expression compilation. + * d/p/CVE-2025-27221_{1,2}.patch: removed, applied by upstream + + -- Lucas Kanashiro <kanashiro@debian.org> Fri, 30 Oct 2026 15:35:16 -0300 + ruby3.3 (3.3.8-2) unstable; urgency=medium [ Antonio Terceiro ] diff -Nru ruby3.3-3.3.8/debian/patches/CVE-2025-27221_1.patch ruby3.3-3.3.13/debian/patches/CVE-2025-27221_1.patch --- ruby3.3-3.3.8/debian/patches/CVE-2025-27221_1.patch 2025-04-29 10:58:14.000000000 +0000 +++ ruby3.3-3.3.13/debian/patches/CVE-2025-27221_1.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,49 +0,0 @@ -From: Hiroshi SHIBATA <hsbt@ruby-lang.org> -Date: Fri, 21 Feb 2025 16:29:36 +0900 -Subject: Truncate userinfo with URI#join, URI#merge and URI#+ - -[Debian notes] - -This is fixing the uri vendorized version in lib/bundler and -lib/rubygems. - -Origin: upstream, https://github.com/ruby/uri/commit/3675494839112b64d5f082a9068237b277e ---- - lib/bundler/vendor/uri/lib/uri/generic.rb | 6 +++++- - lib/rubygems/vendor/uri/lib/uri/generic.rb | 6 +++++- - 2 files changed, 10 insertions(+), 2 deletions(-) - -diff --git a/lib/bundler/vendor/uri/lib/uri/generic.rb b/lib/bundler/vendor/uri/lib/uri/generic.rb -index 762c425..30741ab 100644 ---- a/lib/bundler/vendor/uri/lib/uri/generic.rb -+++ b/lib/bundler/vendor/uri/lib/uri/generic.rb -@@ -1141,7 +1141,11 @@ module Bundler::URI - end - - # RFC2396, Section 5.2, 7) -- base.set_userinfo(rel.userinfo) if rel.userinfo -+ if rel.userinfo -+ base.set_userinfo(rel.userinfo) -+ else -+ base.set_userinfo(nil) -+ end - base.set_host(rel.host) if rel.host - base.set_port(rel.port) if rel.port - base.query = rel.query if rel.query -diff --git a/lib/rubygems/vendor/uri/lib/uri/generic.rb b/lib/rubygems/vendor/uri/lib/uri/generic.rb -index 72c52aa..1d05c05 100644 ---- a/lib/rubygems/vendor/uri/lib/uri/generic.rb -+++ b/lib/rubygems/vendor/uri/lib/uri/generic.rb -@@ -1141,7 +1141,11 @@ module Gem::URI - end - - # RFC2396, Section 5.2, 7) -- base.set_userinfo(rel.userinfo) if rel.userinfo -+ if rel.userinfo -+ base.set_userinfo(rel.userinfo) -+ else -+ base.set_userinfo(nil) -+ end - base.set_host(rel.host) if rel.host - base.set_port(rel.port) if rel.port - base.query = rel.query if rel.query diff -Nru ruby3.3-3.3.8/debian/patches/CVE-2025-27221_2.patch ruby3.3-3.3.13/debian/patches/CVE-2025-27221_2.patch --- ruby3.3-3.3.8/debian/patches/CVE-2025-27221_2.patch 2025-04-29 10:58:14.000000000 +0000 +++ ruby3.3-3.3.13/debian/patches/CVE-2025-27221_2.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,85 +0,0 @@ -From: Hiroshi SHIBATA <hsbt@ruby-lang.org> -Date: Fri, 21 Feb 2025 18:16:28 +0900 -Subject: Fix merger of URI with authority component - -https://hackerone.com/reports/2957667 - -Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org> - -[Debian notes] - -This is fixing the uri vendorized version in lib/bundler and -lib/rubygems. - -Origin: upstream, https://github.com/ruby/uri/commit/2789182478f42ccbb62197f952eb730e4f ---- - lib/bundler/vendor/uri/lib/uri/generic.rb | 19 +++++++------------ - lib/rubygems/vendor/uri/lib/uri/generic.rb | 19 +++++++------------ - 2 files changed, 14 insertions(+), 24 deletions(-) - -diff --git a/lib/bundler/vendor/uri/lib/uri/generic.rb b/lib/bundler/vendor/uri/lib/uri/generic.rb -index 30741ab..a6e5638 100644 ---- a/lib/bundler/vendor/uri/lib/uri/generic.rb -+++ b/lib/bundler/vendor/uri/lib/uri/generic.rb -@@ -1133,21 +1133,16 @@ module Bundler::URI - base.fragment=(nil) - - # RFC2396, Section 5.2, 4) -- if !authority -- base.set_path(merge_path(base.path, rel.path)) if base.path && rel.path -- else -- # RFC2396, Section 5.2, 4) -- base.set_path(rel.path) if rel.path -+ if authority -+ base.set_userinfo(rel.userinfo) -+ base.set_host(rel.host) -+ base.set_port(rel.port || base.default_port) -+ base.set_path(rel.path) -+ elsif base.path && rel.path -+ base.set_path(merge_path(base.path, rel.path)) - end - - # RFC2396, Section 5.2, 7) -- if rel.userinfo -- base.set_userinfo(rel.userinfo) -- else -- base.set_userinfo(nil) -- end -- base.set_host(rel.host) if rel.host -- base.set_port(rel.port) if rel.port - base.query = rel.query if rel.query - base.fragment=(rel.fragment) if rel.fragment - -diff --git a/lib/rubygems/vendor/uri/lib/uri/generic.rb b/lib/rubygems/vendor/uri/lib/uri/generic.rb -index 1d05c05..6169aa4 100644 ---- a/lib/rubygems/vendor/uri/lib/uri/generic.rb -+++ b/lib/rubygems/vendor/uri/lib/uri/generic.rb -@@ -1133,21 +1133,16 @@ module Gem::URI - base.fragment=(nil) - - # RFC2396, Section 5.2, 4) -- if !authority -- base.set_path(merge_path(base.path, rel.path)) if base.path && rel.path -- else -- # RFC2396, Section 5.2, 4) -- base.set_path(rel.path) if rel.path -+ if authority -+ base.set_userinfo(rel.userinfo) -+ base.set_host(rel.host) -+ base.set_port(rel.port || base.default_port) -+ base.set_path(rel.path) -+ elsif base.path && rel.path -+ base.set_path(merge_path(base.path, rel.path)) - end - - # RFC2396, Section 5.2, 7) -- if rel.userinfo -- base.set_userinfo(rel.userinfo) -- else -- base.set_userinfo(nil) -- end -- base.set_host(rel.host) if rel.host -- base.set_port(rel.port) if rel.port - base.query = rel.query if rel.query - base.fragment=(rel.fragment) if rel.fragment - diff -Nru ruby3.3-3.3.8/debian/patches/series ruby3.3-3.3.13/debian/patches/series --- ruby3.3-3.3.8/debian/patches/series 2025-04-29 10:58:14.000000000 +0000 +++ ruby3.3-3.3.13/debian/patches/series 2026-10-30 18:35:16.000000000 +0000 @@ -13,5 +13,3 @@ Deduplicate-results-from-getaddrinfo.patch test-test_bundled_ca-Skip-test-because-it-requires-i.patch Fix-test-dlopen-for-.so-filename-with-more-than-one-digit.patch -CVE-2025-27221_1.patch -CVE-2025-27221_2.patch diff -Nru ruby3.3-3.3.8/defs/gmake.mk ruby3.3-3.3.13/defs/gmake.mk --- ruby3.3-3.3.8/defs/gmake.mk 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/defs/gmake.mk 2026-10-23 03:17:41.000000000 +0000 @@ -500,7 +500,8 @@ # order-only-prerequisites doesn't work for $(RUBYSPEC_CAPIEXT) # because the same named directory exists in the source tree. -$(RUBYSPEC_CAPIEXT)/%.$(DLEXT): $(srcdir)/$(RUBYSPEC_CAPIEXT)/%.c $(srcdir)/$(RUBYSPEC_CAPIEXT)/rubyspec.h $(RUBY_H_INCLUDES) $(LIBRUBY) +$(RUBYSPEC_CAPIEXT)/%.$(DLEXT): $(srcdir)/$(RUBYSPEC_CAPIEXT)/%.c $(RUBYSPEC_CAPIEXT_DEPS) \ + | build-ext $(ECHO) building $@ $(Q) $(MAKEDIRS) $(@D) $(Q) $(DLDSHARED) -L. $(XDLDFLAGS) $(XLDFLAGS) $(LDFLAGS) $(INCFLAGS) $(CPPFLAGS) $(OUTFLAG)$@ $< $(LIBRUBYARG) diff -Nru ruby3.3-3.3.8/enc/depend ruby3.3-3.3.13/enc/depend --- ruby3.3-3.3.8/enc/depend 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/enc/depend 2026-10-23 03:17:41.000000000 +0000 @@ -6972,6 +6972,7 @@ enc/trans/iso2022.$(OBJEXT): internal/attr/noexcept.h enc/trans/iso2022.$(OBJEXT): internal/attr/noinline.h enc/trans/iso2022.$(OBJEXT): internal/attr/nonnull.h +enc/trans/iso2022.$(OBJEXT): internal/attr/nonstring.h enc/trans/iso2022.$(OBJEXT): internal/attr/noreturn.h enc/trans/iso2022.$(OBJEXT): internal/attr/packed_struct.h enc/trans/iso2022.$(OBJEXT): internal/attr/pure.h diff -Nru ruby3.3-3.3.8/enc/jis/props.h ruby3.3-3.3.13/enc/jis/props.h --- ruby3.3-3.3.8/enc/jis/props.h 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/enc/jis/props.h 2026-10-23 03:17:43.000000000 +0000 @@ -1,5 +1,5 @@ /* ANSI-C code produced by gperf version 3.1 */ -/* Command-line: gperf -k1,3 -7 -c -j1 -i1 -t -C -P -t --ignore-case -H onig_jis_property_hash -Q onig_jis_property_pool -N onig_jis_property enc/jis/props.kwd */ +/* Command-line: gperf -L ANSI-C -k1,3 -7 -c -j1 -i1 -t -C -P -t --ignore-case -H onig_jis_property_hash -Q onig_jis_property_pool -N onig_jis_property enc/jis/props.kwd */ #if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ @@ -28,7 +28,6 @@ #error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gperf@gnu.org>." #endif -#define gperf_offsetof(s, n) (short)offsetof(struct s##_t, s##_str##n) #line 1 "enc/jis/props.kwd" /* -*- c -*- */ #define GPERF_DOWNCASE 1 @@ -82,7 +81,7 @@ #ifndef GPERF_DOWNCASE #define GPERF_DOWNCASE 1 -static const unsigned char gperf_downcase[256] = +static unsigned char gperf_downcase[256] = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, @@ -180,19 +179,19 @@ { {-1}, {-1}, {-1}, {-1}, {-1}, #line 48 "enc/jis/props.kwd" - {gperf_offsetof(onig_jis_property_pool, 5), onigenc_jis_han}, + {(int)(size_t)&((struct onig_jis_property_pool_t *)0)->onig_jis_property_pool_str5, onigenc_jis_han}, {-1}, #line 49 "enc/jis/props.kwd" - {gperf_offsetof(onig_jis_property_pool, 7), onigenc_jis_latin}, + {(int)(size_t)&((struct onig_jis_property_pool_t *)0)->onig_jis_property_pool_str7, onigenc_jis_latin}, #line 50 "enc/jis/props.kwd" - {gperf_offsetof(onig_jis_property_pool, 8), onigenc_jis_greek}, + {(int)(size_t)&((struct onig_jis_property_pool_t *)0)->onig_jis_property_pool_str8, onigenc_jis_greek}, {-1}, #line 46 "enc/jis/props.kwd" - {gperf_offsetof(onig_jis_property_pool, 10), onigenc_jis_hiragana}, + {(int)(size_t)&((struct onig_jis_property_pool_t *)0)->onig_jis_property_pool_str10, onigenc_jis_hiragana}, #line 47 "enc/jis/props.kwd" - {gperf_offsetof(onig_jis_property_pool, 11), onigenc_jis_katakana}, + {(int)(size_t)&((struct onig_jis_property_pool_t *)0)->onig_jis_property_pool_str11, onigenc_jis_katakana}, #line 51 "enc/jis/props.kwd" - {gperf_offsetof(onig_jis_property_pool, 12), onigenc_jis_cyrillic} + {(int)(size_t)&((struct onig_jis_property_pool_t *)0)->onig_jis_property_pool_str12, onigenc_jis_cyrillic} }; if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) diff -Nru ruby3.3-3.3.8/enc/jis/props.h.blt ruby3.3-3.3.13/enc/jis/props.h.blt --- ruby3.3-3.3.8/enc/jis/props.h.blt 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/enc/jis/props.h.blt 2026-10-23 03:17:41.000000000 +0000 @@ -1,5 +1,5 @@ /* ANSI-C code produced by gperf version 3.1 */ -/* Command-line: gperf -k1,3 -7 -c -j1 -i1 -t -C -P -t --ignore-case -H onig_jis_property_hash -Q onig_jis_property_pool -N onig_jis_property enc/jis/props.kwd */ +/* Command-line: gperf -L ANSI-C -k1,3 -7 -c -j1 -i1 -t -C -P -t --ignore-case -H onig_jis_property_hash -Q onig_jis_property_pool -N onig_jis_property enc/jis/props.kwd */ #if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ @@ -28,7 +28,6 @@ #error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gperf@gnu.org>." #endif -#define gperf_offsetof(s, n) (short)offsetof(struct s##_t, s##_str##n) #line 1 "enc/jis/props.kwd" /* -*- c -*- */ #define GPERF_DOWNCASE 1 @@ -82,7 +81,7 @@ #ifndef GPERF_DOWNCASE #define GPERF_DOWNCASE 1 -static const unsigned char gperf_downcase[256] = +static unsigned char gperf_downcase[256] = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, @@ -180,19 +179,19 @@ { {-1}, {-1}, {-1}, {-1}, {-1}, #line 48 "enc/jis/props.kwd" - {gperf_offsetof(onig_jis_property_pool, 5), onigenc_jis_han}, + {(int)(size_t)&((struct onig_jis_property_pool_t *)0)->onig_jis_property_pool_str5, onigenc_jis_han}, {-1}, #line 49 "enc/jis/props.kwd" - {gperf_offsetof(onig_jis_property_pool, 7), onigenc_jis_latin}, + {(int)(size_t)&((struct onig_jis_property_pool_t *)0)->onig_jis_property_pool_str7, onigenc_jis_latin}, #line 50 "enc/jis/props.kwd" - {gperf_offsetof(onig_jis_property_pool, 8), onigenc_jis_greek}, + {(int)(size_t)&((struct onig_jis_property_pool_t *)0)->onig_jis_property_pool_str8, onigenc_jis_greek}, {-1}, #line 46 "enc/jis/props.kwd" - {gperf_offsetof(onig_jis_property_pool, 10), onigenc_jis_hiragana}, + {(int)(size_t)&((struct onig_jis_property_pool_t *)0)->onig_jis_property_pool_str10, onigenc_jis_hiragana}, #line 47 "enc/jis/props.kwd" - {gperf_offsetof(onig_jis_property_pool, 11), onigenc_jis_katakana}, + {(int)(size_t)&((struct onig_jis_property_pool_t *)0)->onig_jis_property_pool_str11, onigenc_jis_katakana}, #line 51 "enc/jis/props.kwd" - {gperf_offsetof(onig_jis_property_pool, 12), onigenc_jis_cyrillic} + {(int)(size_t)&((struct onig_jis_property_pool_t *)0)->onig_jis_property_pool_str12, onigenc_jis_cyrillic} }; if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) diff -Nru ruby3.3-3.3.8/enc/trans/iso2022.c ruby3.3-3.3.13/enc/trans/iso2022.c --- ruby3.3-3.3.8/enc/trans/iso2022.c 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/enc/trans/iso2022.c 2026-10-23 03:17:43.000000000 +0000 @@ -1,8 +1,9 @@ /* autogenerated. */ /* src="transcode-tblgen.rb", len=30823, checksum=59589 */ -/* src="iso2022.trans", len=15902, checksum=37507 */ +/* src="iso2022.trans", len=15968, checksum=43209 */ #include "transcode_data.h" +#include "ruby/internal/attr/nonstring.h" @@ -618,7 +619,7 @@ iso2022jp_encoder_reset_sequence_size, finish_iso2022jp_encoder }; -static const char *tbl0208 = +RBIMPL_ATTR_NONSTRING() static const char *tbl0208 = "\x21\x23\x21\x56\x21\x57\x21\x22\x21\x26\x25\x72\x25\x21\x25\x23" \ "\x25\x25\x25\x27\x25\x29\x25\x63\x25\x65\x25\x67\x25\x43\x21\x3C" \ "\x25\x22\x25\x24\x25\x26\x25\x28\x25\x2A\x25\x2B\x25\x2D\x25\x2F" \ diff -Nru ruby3.3-3.3.8/enc/trans/iso2022.trans ruby3.3-3.3.13/enc/trans/iso2022.trans --- ruby3.3-3.3.8/enc/trans/iso2022.trans 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/enc/trans/iso2022.trans 2026-10-23 03:17:41.000000000 +0000 @@ -1,4 +1,5 @@ #include "transcode_data.h" +#include "ruby/internal/attr/nonstring.h" <% map = { @@ -443,7 +444,7 @@ iso2022jp_encoder_reset_sequence_size, finish_iso2022jp_encoder }; -static const char *tbl0208 = +RBIMPL_ATTR_NONSTRING() static const char *tbl0208 = "\x21\x23\x21\x56\x21\x57\x21\x22\x21\x26\x25\x72\x25\x21\x25\x23" \ "\x25\x25\x25\x27\x25\x29\x25\x63\x25\x65\x25\x67\x25\x43\x21\x3C" \ "\x25\x22\x25\x24\x25\x26\x25\x28\x25\x2A\x25\x2B\x25\x2D\x25\x2F" \ diff -Nru ruby3.3-3.3.8/enc/unicode.c ruby3.3-3.3.13/enc/unicode.c --- ruby3.3-3.3.8/enc/unicode.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/enc/unicode.c 2026-10-23 03:17:41.000000000 +0000 @@ -682,15 +682,13 @@ *pp += codepoint_length; if (code <= 'z') { /* ASCII comes first */ - if (code >= 'a' && code <= 'z') { + if (code >= 'a' /*&& code <= 'z'*/) { if (flags & ONIGENC_CASE_UPCASE) { MODIFIED; if (flags & ONIGENC_CASE_FOLD_TURKISH_AZERI && code == 'i') code = I_WITH_DOT_ABOVE; - else { - code -= 'a'; - code += 'A'; - } + else + code -= 'a' - 'A'; } } else if (code >= 'A' && code <= 'Z') { diff -Nru ruby3.3-3.3.8/enumerator.c ruby3.3-3.3.13/enumerator.c --- ruby3.3-3.3.8/enumerator.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/enumerator.c 2026-10-23 03:17:41.000000000 +0000 @@ -18,6 +18,7 @@ #include <float.h> #endif +#include <limits.h> #include "id.h" #include "internal.h" #include "internal/class.h" @@ -3963,7 +3964,7 @@ ary = rb_ary_new_capa((n < len) ? n : len); while (n > 0 && i < end) { rb_ary_push(ary, LONG2FIX(i)); - if (i + unit < i) break; + if (i > LONG_MAX - unit) break; i += unit; --n; } @@ -3976,7 +3977,7 @@ ary = rb_ary_new_capa((n < len) ? n : len); while (n > 0 && i > end) { rb_ary_push(ary, LONG2FIX(i)); - if (i + unit > i) break; + if (i < LONG_MIN - unit) break; i += unit; --n; } diff -Nru ruby3.3-3.3.8/error.c ruby3.3-3.3.13/error.c --- ruby3.3-3.3.8/error.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/error.c 2026-10-23 03:17:41.000000000 +0000 @@ -1662,7 +1662,7 @@ VALUE highlight = check_highlight_keyword(opt, 0); - extern VALUE rb_decorate_message(const VALUE eclass, const VALUE emesg, int highlight); + extern VALUE rb_decorate_message(const VALUE eclass, VALUE emesg, int highlight); return rb_decorate_message(CLASS_OF(exc), rb_get_message(exc), RTEST(highlight)); } @@ -2321,7 +2321,7 @@ VALUE mesg = ptr->mesg; if (NIL_P(mesg)) return Qnil; else { - struct RString s_str, c_str, d_str; + struct RString s_str = {RBASIC_INIT}, c_str = {RBASIC_INIT}, d_str = {RBASIC_INIT}; VALUE c, s, d = 0, args[4], c2; int state = 0; rb_encoding *usascii = rb_usascii_encoding(); diff -Nru ruby3.3-3.3.8/eval_error.c ruby3.3-3.3.13/eval_error.c --- ruby3.3-3.3.8/eval_error.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/eval_error.c 2026-10-23 03:17:41.000000000 +0000 @@ -125,7 +125,7 @@ } VALUE -rb_decorate_message(const VALUE eclass, const VALUE emesg, int highlight) +rb_decorate_message(const VALUE eclass, VALUE emesg, int highlight) { const char *einfo = ""; long elen = 0; @@ -210,6 +210,8 @@ } } + RB_GC_GUARD(emesg); + return str; } diff -Nru ruby3.3-3.3.8/ext/-test-/string/fstring.c ruby3.3-3.3.13/ext/-test-/string/fstring.c --- ruby3.3-3.3.8/ext/-test-/string/fstring.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/-test-/string/fstring.c 2026-10-23 03:17:41.000000000 +0000 @@ -14,7 +14,7 @@ bug_s_fstring_fake_str(VALUE self) { static const char literal[] = "abcdefghijklmnopqrstuvwxyz"; - struct RString fake_str; + struct RString fake_str = {RBASIC_INIT}; return rb_fstring(rb_setup_fake_str(&fake_str, literal, sizeof(literal) - 1, 0)); } diff -Nru ruby3.3-3.3.8/ext/date/date_core.c ruby3.3-3.3.13/ext/date/date_core.c --- ruby3.3-3.3.8/ext/date/date_core.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/date/date_core.c 2026-10-23 03:17:41.000000000 +0000 @@ -6941,13 +6941,24 @@ static VALUE d_lite_hash(VALUE self) { - st_index_t v, h[4]; + st_index_t v, h[5]; + VALUE nth; get_d1(self); - h[0] = m_nth(dat); - h[1] = m_jd(dat); - h[2] = m_df(dat); - h[3] = m_sf(dat); + nth = m_nth(dat); + + if (FIXNUM_P(nth)) { + h[0] = 0; + h[1] = (st_index_t)nth; + } else { + h[0] = 1; + h[1] = (st_index_t)FIX2LONG(rb_hash(nth)); + } + + h[2] = m_jd(dat); + h[3] = m_df(dat); + h[4] = m_sf(dat); + v = rb_memhash(h, sizeof(h)); return ST2FIX(v); } diff -Nru ruby3.3-3.3.8/ext/date/prereq.mk ruby3.3-3.3.13/ext/date/prereq.mk --- ruby3.3-3.3.8/ext/date/prereq.mk 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/date/prereq.mk 2026-10-23 03:17:41.000000000 +0000 @@ -1,7 +1,7 @@ .SUFFIXES: .list .list.h: - gperf --ignore-case -C -c -P -p -j1 -i 1 -g -o -t -N $(*F) $< \ + gperf --ignore-case -L ANSI-C -C -c -P -p -j1 -i 1 -g -o -t -N $(*F) $< \ | sed -f $(top_srcdir)/tool/gperf.sed \ > $(@F) diff -Nru ruby3.3-3.3.8/ext/date/zonetab.h ruby3.3-3.3.13/ext/date/zonetab.h --- ruby3.3-3.3.8/ext/date/zonetab.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/date/zonetab.h 2026-10-23 03:17:41.000000000 +0000 @@ -1,5 +1,5 @@ /* ANSI-C code produced by gperf version 3.1 */ -/* Command-line: gperf --ignore-case -C -c -P -p -j1 -i 1 -g -o -t -N zonetab zonetab.list */ +/* Command-line: gperf --ignore-case -L ANSI-C -C -c -P -p -j1 -i 1 -g -o -t -N zonetab zonetab.list */ /* Computed positions: -k'1-4,9' */ #if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ @@ -29,7 +29,6 @@ #error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gperf@gnu.org>." #endif -#define gperf_offsetof(s, n) (short)offsetof(struct s##_t, s##_str##n) #line 1 "zonetab.list" struct zone { @@ -809,727 +808,727 @@ { {-1}, {-1}, #line 34 "zonetab.list" - {gperf_offsetof(stringpool, 2), -2*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str2, -2*3600}, #line 43 "zonetab.list" - {gperf_offsetof(stringpool, 3), -11*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str3, -11*3600}, #line 45 "zonetab.list" - {gperf_offsetof(stringpool, 4), 0*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str4, 0*3600}, #line 36 "zonetab.list" - {gperf_offsetof(stringpool, 5), -4*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str5, -4*3600}, {-1}, {-1}, #line 269 "zonetab.list" - {gperf_offsetof(stringpool, 8),21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str8,21600}, #line 268 "zonetab.list" - {gperf_offsetof(stringpool, 9),25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str9,25200}, #line 35 "zonetab.list" - {gperf_offsetof(stringpool, 10), -3*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str10, -3*3600}, {-1}, {-1}, #line 21 "zonetab.list" - {gperf_offsetof(stringpool, 13), 1*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str13, 1*3600}, #line 25 "zonetab.list" - {gperf_offsetof(stringpool, 14), 5*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str14, 5*3600}, #line 271 "zonetab.list" - {gperf_offsetof(stringpool, 15),-18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str15,-18000}, #line 279 "zonetab.list" - {gperf_offsetof(stringpool, 16),-10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str16,-10800}, #line 273 "zonetab.list" - {gperf_offsetof(stringpool, 17),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str17,43200}, #line 272 "zonetab.list" - {gperf_offsetof(stringpool, 18),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str18,43200}, #line 80 "zonetab.list" - {gperf_offsetof(stringpool, 19), 2*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str19, 2*3600}, #line 186 "zonetab.list" - {gperf_offsetof(stringpool, 20),36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str20,36000}, #line 88 "zonetab.list" - {gperf_offsetof(stringpool, 21), 3*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str21, 3*3600}, #line 87 "zonetab.list" - {gperf_offsetof(stringpool, 22), 3*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str22, 3*3600}, {-1}, #line 101 "zonetab.list" - {gperf_offsetof(stringpool, 24),-6*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str24,-6*3600}, #line 217 "zonetab.list" - {gperf_offsetof(stringpool, 25),-18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str25,-18000}, #line 19 "zonetab.list" - {gperf_offsetof(stringpool, 26), -8*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str26, -8*3600}, #line 133 "zonetab.list" - {gperf_offsetof(stringpool, 27), -18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str27, -18000}, #line 32 "zonetab.list" - {gperf_offsetof(stringpool, 28), 12*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str28, 12*3600}, #line 56 "zonetab.list" - {gperf_offsetof(stringpool, 29), -4*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str29, -4*3600}, #line 13 "zonetab.list" - {gperf_offsetof(stringpool, 30), -5*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str30, -5*3600}, #line 23 "zonetab.list" - {gperf_offsetof(stringpool, 31), 3*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str31, 3*3600}, #line 256 "zonetab.list" - {gperf_offsetof(stringpool, 32),23400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str32,23400}, #line 73 "zonetab.list" - {gperf_offsetof(stringpool, 33), 1*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str33, 1*3600}, {-1}, #line 82 "zonetab.list" - {gperf_offsetof(stringpool, 35), 2*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str35, 2*3600}, #line 71 "zonetab.list" - {gperf_offsetof(stringpool, 36), 1*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str36, 1*3600}, #line 24 "zonetab.list" - {gperf_offsetof(stringpool, 37), 4*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str37, 4*3600}, #line 79 "zonetab.list" - {gperf_offsetof(stringpool, 38), 2*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str38, 2*3600}, #line 65 "zonetab.list" - {gperf_offsetof(stringpool, 39),2*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str39,2*3600}, {-1}, #line 202 "zonetab.list" - {gperf_offsetof(stringpool, 41),28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str41,28800}, #line 252 "zonetab.list" - {gperf_offsetof(stringpool, 42),39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str42,39600}, #line 251 "zonetab.list" - {gperf_offsetof(stringpool, 43),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str43,43200}, #line 17 "zonetab.list" - {gperf_offsetof(stringpool, 44), -7*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str44, -7*3600}, #line 89 "zonetab.list" - {gperf_offsetof(stringpool, 45), 3*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str45, 3*3600}, #line 212 "zonetab.list" - {gperf_offsetof(stringpool, 46),-18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str46,-18000}, #line 15 "zonetab.list" - {gperf_offsetof(stringpool, 47), -6*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str47, -6*3600}, #line 192 "zonetab.list" - {gperf_offsetof(stringpool, 48),18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str48,18000}, #line 26 "zonetab.list" - {gperf_offsetof(stringpool, 49), 6*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str49, 6*3600}, {-1}, {-1}, #line 51 "zonetab.list" - {gperf_offsetof(stringpool, 52), -3*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str52, -3*3600}, #line 226 "zonetab.list" - {gperf_offsetof(stringpool, 53),-7200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str53,-7200}, #line 221 "zonetab.list" - {gperf_offsetof(stringpool, 54),10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str54,10800}, #line 22 "zonetab.list" - {gperf_offsetof(stringpool, 55), 2*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str55, 2*3600}, {-1}, #line 190 "zonetab.list" - {gperf_offsetof(stringpool, 57),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str57,43200}, #line 189 "zonetab.list" - {gperf_offsetof(stringpool, 58),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str58,43200}, #line 199 "zonetab.list" - {gperf_offsetof(stringpool, 59),28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str59,28800}, #line 29 "zonetab.list" - {gperf_offsetof(stringpool, 60), 9*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str60, 9*3600}, #line 276 "zonetab.list" - {gperf_offsetof(stringpool, 61),28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str61,28800}, #line 48 "zonetab.list" - {gperf_offsetof(stringpool, 62), -2*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str62, -2*3600}, #line 94 "zonetab.list" - {gperf_offsetof(stringpool, 63), 6*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str63, 6*3600}, #line 74 "zonetab.list" - {gperf_offsetof(stringpool, 64), 1*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str64, 1*3600}, #line 81 "zonetab.list" - {gperf_offsetof(stringpool, 65), 2*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str65, 2*3600}, #line 64 "zonetab.list" - {gperf_offsetof(stringpool, 66),-10*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str66,-10*3600}, #line 254 "zonetab.list" - {gperf_offsetof(stringpool, 67),18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str67,18000}, #line 92 "zonetab.list" - {gperf_offsetof(stringpool, 68), 5*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str68, 5*3600}, {-1}, #line 200 "zonetab.list" - {gperf_offsetof(stringpool, 70),-14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str70,-14400}, #line 70 "zonetab.list" - {gperf_offsetof(stringpool, 71), 1*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str71, 1*3600}, #line 281 "zonetab.list" - {gperf_offsetof(stringpool, 72),32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str72,32400}, {-1}, #line 280 "zonetab.list" - {gperf_offsetof(stringpool, 74),39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str74,39600}, #line 238 "zonetab.list" - {gperf_offsetof(stringpool, 75),21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str75,21600}, #line 93 "zonetab.list" - {gperf_offsetof(stringpool, 76), (5*3600+1800)}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str76, (5*3600+1800)}, #line 194 "zonetab.list" - {gperf_offsetof(stringpool, 77),28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str77,28800}, {-1}, #line 255 "zonetab.list" - {gperf_offsetof(stringpool, 79),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str79,43200}, #line 75 "zonetab.list" - {gperf_offsetof(stringpool, 80), 1*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str80, 1*3600}, #line 270 "zonetab.list" - {gperf_offsetof(stringpool, 81),18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str81,18000}, #line 83 "zonetab.list" - {gperf_offsetof(stringpool, 82), 2*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str82, 2*3600}, {-1}, #line 207 "zonetab.list" - {gperf_offsetof(stringpool, 84),36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str84,36000}, #line 278 "zonetab.list" - {gperf_offsetof(stringpool, 85),-7200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str85,-7200}, {-1}, {-1}, #line 126 "zonetab.list" - {gperf_offsetof(stringpool, 88), -21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str88, -21600}, #line 185 "zonetab.list" - {gperf_offsetof(stringpool, 89),39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str89,39600}, #line 183 "zonetab.list" - {gperf_offsetof(stringpool, 90),-18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str90,-18000}, #line 218 "zonetab.list" - {gperf_offsetof(stringpool, 91),-18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str91,-18000}, #line 182 "zonetab.list" - {gperf_offsetof(stringpool, 92),34200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str92,34200}, #line 103 "zonetab.list" - {gperf_offsetof(stringpool, 93),11*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str93,11*3600}, #line 53 "zonetab.list" - {gperf_offsetof(stringpool, 94), -3*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str94, -3*3600}, #line 208 "zonetab.list" - {gperf_offsetof(stringpool, 95),36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str95,36000}, #line 49 "zonetab.list" - {gperf_offsetof(stringpool, 96),-2*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str96,-2*3600}, #line 120 "zonetab.list" - {gperf_offsetof(stringpool, 97), 34200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str97, 34200}, {-1}, {-1}, #line 215 "zonetab.list" - {gperf_offsetof(stringpool, 100),25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str100,25200}, #line 242 "zonetab.list" - {gperf_offsetof(stringpool, 101),12600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str101,12600}, #line 241 "zonetab.list" - {gperf_offsetof(stringpool, 102),28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str102,28800}, #line 240 "zonetab.list" - {gperf_offsetof(stringpool, 103),32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str103,32400}, #line 86 "zonetab.list" - {gperf_offsetof(stringpool, 104), 3*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str104, 3*3600}, #line 33 "zonetab.list" - {gperf_offsetof(stringpool, 105), -1*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str105, -1*3600}, #line 201 "zonetab.list" - {gperf_offsetof(stringpool, 106),21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str106,21600}, #line 148 "zonetab.list" - {gperf_offsetof(stringpool, 107), -25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str107, -25200}, #line 96 "zonetab.list" - {gperf_offsetof(stringpool, 108), (6*3600+1800)}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str108, (6*3600+1800)}, #line 42 "zonetab.list" - {gperf_offsetof(stringpool, 109), -10*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str109, -10*3600}, #line 31 "zonetab.list" - {gperf_offsetof(stringpool, 110), 11*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str110, 11*3600}, #line 72 "zonetab.list" - {gperf_offsetof(stringpool, 111), 1*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str111, 1*3600}, {-1}, #line 90 "zonetab.list" - {gperf_offsetof(stringpool, 113), 4*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str113, 4*3600}, #line 47 "zonetab.list" - {gperf_offsetof(stringpool, 114), 0*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str114, 0*3600}, {-1}, #line 78 "zonetab.list" - {gperf_offsetof(stringpool, 116), 1*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str116, 1*3600}, #line 77 "zonetab.list" - {gperf_offsetof(stringpool, 117), 1*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str117, 1*3600}, {-1}, #line 95 "zonetab.list" - {gperf_offsetof(stringpool, 119), 2*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str119, 2*3600}, #line 313 "zonetab.list" - {gperf_offsetof(stringpool, 120),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str120,43200}, #line 55 "zonetab.list" - {gperf_offsetof(stringpool, 121), -(2*3600+1800)}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str121, -(2*3600+1800)}, #line 184 "zonetab.list" - {gperf_offsetof(stringpool, 122),31500}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str122,31500}, #line 204 "zonetab.list" - {gperf_offsetof(stringpool, 123),45900}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str123,45900}, #line 210 "zonetab.list" - {gperf_offsetof(stringpool, 124),-18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str124,-18000}, #line 198 "zonetab.list" - {gperf_offsetof(stringpool, 125),14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str125,14400}, #line 57 "zonetab.list" - {gperf_offsetof(stringpool, 126), -4*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str126, -4*3600}, #line 197 "zonetab.list" - {gperf_offsetof(stringpool, 127),18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str127,18000}, #line 54 "zonetab.list" - {gperf_offsetof(stringpool, 128),-3*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str128,-3*3600}, #line 253 "zonetab.list" - {gperf_offsetof(stringpool, 129),-30600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str129,-30600}, #line 91 "zonetab.list" - {gperf_offsetof(stringpool, 130), 4*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str130, 4*3600}, #line 99 "zonetab.list" - {gperf_offsetof(stringpool, 131), 9*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str131, 9*3600}, #line 122 "zonetab.list" - {gperf_offsetof(stringpool, 132), 21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str132, 21600}, #line 187 "zonetab.list" - {gperf_offsetof(stringpool, 133),16200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str133,16200}, #line 132 "zonetab.list" - {gperf_offsetof(stringpool, 134), -10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str134, -10800}, #line 121 "zonetab.list" - {gperf_offsetof(stringpool, 135), -21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str135, -21600}, {-1}, #line 236 "zonetab.list" - {gperf_offsetof(stringpool, 137),25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str137,25200}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 274 "zonetab.list" - {gperf_offsetof(stringpool, 143),36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str143,36000}, #line 266 "zonetab.list" - {gperf_offsetof(stringpool, 144),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str144,43200}, #line 146 "zonetab.list" - {gperf_offsetof(stringpool, 145), -21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str145, -21600}, #line 193 "zonetab.list" - {gperf_offsetof(stringpool, 146),32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str146,32400}, #line 220 "zonetab.list" - {gperf_offsetof(stringpool, 147),-3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str147,-3600}, #line 214 "zonetab.list" - {gperf_offsetof(stringpool, 148),25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str148,25200}, #line 219 "zonetab.list" - {gperf_offsetof(stringpool, 149),0}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str149,0}, #line 275 "zonetab.list" - {gperf_offsetof(stringpool, 150),46800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str150,46800}, #line 109 "zonetab.list" - {gperf_offsetof(stringpool, 151), -32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str151, -32400}, {-1}, {-1}, #line 68 "zonetab.list" - {gperf_offsetof(stringpool, 154), -11*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str154, -11*3600}, {-1}, {-1}, {-1}, #line 321 "zonetab.list" - {gperf_offsetof(stringpool, 158),0}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str158,0}, {-1}, #line 178 "zonetab.list" - {gperf_offsetof(stringpool, 160), 18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str160, 18000}, #line 181 "zonetab.list" - {gperf_offsetof(stringpool, 161),37800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str161,37800}, #line 265 "zonetab.list" - {gperf_offsetof(stringpool, 162),20700}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str162,20700}, #line 249 "zonetab.list" - {gperf_offsetof(stringpool, 163),37800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str163,37800}, #line 108 "zonetab.list" - {gperf_offsetof(stringpool, 164), 16200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str164, 16200}, {-1}, {-1}, #line 30 "zonetab.list" - {gperf_offsetof(stringpool, 167), 10*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str167, 10*3600}, {-1}, #line 27 "zonetab.list" - {gperf_offsetof(stringpool, 169), 7*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str169, 7*3600}, #line 239 "zonetab.list" - {gperf_offsetof(stringpool, 170),16200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str170,16200}, #line 206 "zonetab.list" - {gperf_offsetof(stringpool, 171),28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str171,28800}, #line 205 "zonetab.list" - {gperf_offsetof(stringpool, 172),32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str172,32400}, #line 12 "zonetab.list" - {gperf_offsetof(stringpool, 173), 0*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str173, 0*3600}, #line 229 "zonetab.list" - {gperf_offsetof(stringpool, 174),14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str174,14400}, #line 264 "zonetab.list" - {gperf_offsetof(stringpool, 175),25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str175,25200}, #line 263 "zonetab.list" - {gperf_offsetof(stringpool, 176),25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str176,25200}, #line 223 "zonetab.list" - {gperf_offsetof(stringpool, 177),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str177,43200}, #line 40 "zonetab.list" - {gperf_offsetof(stringpool, 178), -8*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str178, -8*3600}, #line 222 "zonetab.list" - {gperf_offsetof(stringpool, 179),46800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str179,46800}, {-1}, #line 282 "zonetab.list" - {gperf_offsetof(stringpool, 181),-10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str181,-10800}, #line 260 "zonetab.list" - {gperf_offsetof(stringpool, 182),39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str182,39600}, #line 100 "zonetab.list" - {gperf_offsetof(stringpool, 183), 9*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str183, 9*3600}, #line 244 "zonetab.list" - {gperf_offsetof(stringpool, 184),39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str184,39600}, #line 102 "zonetab.list" - {gperf_offsetof(stringpool, 185), 10*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str185, 10*3600}, #line 143 "zonetab.list" - {gperf_offsetof(stringpool, 186), 12600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str186, 12600}, #line 129 "zonetab.list" - {gperf_offsetof(stringpool, 187), 10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str187, 10800}, #line 98 "zonetab.list" - {gperf_offsetof(stringpool, 188), 8*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str188, 8*3600}, #line 39 "zonetab.list" - {gperf_offsetof(stringpool, 189), -7*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str189, -7*3600}, #line 130 "zonetab.list" - {gperf_offsetof(stringpool, 190), 36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str190, 36000}, #line 38 "zonetab.list" - {gperf_offsetof(stringpool, 191), -6*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str191, -6*3600}, #line 203 "zonetab.list" - {gperf_offsetof(stringpool, 192),49500}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str192,49500}, #line 298 "zonetab.list" - {gperf_offsetof(stringpool, 193),18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str193,18000}, #line 209 "zonetab.list" - {gperf_offsetof(stringpool, 194),-14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str194,-14400}, #line 191 "zonetab.list" - {gperf_offsetof(stringpool, 195),-43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str195,-43200}, {-1}, #line 259 "zonetab.list" - {gperf_offsetof(stringpool, 197),28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str197,28800}, #line 179 "zonetab.list" - {gperf_offsetof(stringpool, 198), 36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str198, 36000}, #line 257 "zonetab.list" - {gperf_offsetof(stringpool, 199),14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str199,14400}, #line 319 "zonetab.list" - {gperf_offsetof(stringpool, 200),32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str200,32400}, #line 84 "zonetab.list" - {gperf_offsetof(stringpool, 201), 2*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str201, 2*3600}, #line 286 "zonetab.list" - {gperf_offsetof(stringpool, 202),39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str202,39600}, #line 152 "zonetab.list" - {gperf_offsetof(stringpool, 203), 43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str203, 43200}, #line 300 "zonetab.list" - {gperf_offsetof(stringpool, 204),46800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str204,46800}, #line 127 "zonetab.list" - {gperf_offsetof(stringpool, 205), 28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str205, 28800}, #line 299 "zonetab.list" - {gperf_offsetof(stringpool, 206),50400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str206,50400}, #line 85 "zonetab.list" - {gperf_offsetof(stringpool, 207), -11*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str207, -11*3600}, {-1}, #line 142 "zonetab.list" - {gperf_offsetof(stringpool, 209), 19800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str209, 19800}, {-1}, #line 314 "zonetab.list" - {gperf_offsetof(stringpool, 211),-10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str211,-10800}, #line 288 "zonetab.list" - {gperf_offsetof(stringpool, 212),39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str212,39600}, {-1}, #line 196 "zonetab.list" - {gperf_offsetof(stringpool, 214),-3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str214,-3600}, #line 195 "zonetab.list" - {gperf_offsetof(stringpool, 215),0}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str215,0}, #line 293 "zonetab.list" - {gperf_offsetof(stringpool, 216),-36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str216,-36000}, #line 106 "zonetab.list" - {gperf_offsetof(stringpool, 217), 12*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str217, 12*3600}, #line 128 "zonetab.list" - {gperf_offsetof(stringpool, 218), -43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str218, -43200}, #line 105 "zonetab.list" - {gperf_offsetof(stringpool, 219),12*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str219,12*3600}, #line 170 "zonetab.list" - {gperf_offsetof(stringpool, 220), 32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str220, 32400}, #line 125 "zonetab.list" - {gperf_offsetof(stringpool, 221), 39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str221, 39600}, {-1}, #line 283 "zonetab.list" - {gperf_offsetof(stringpool, 223),21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str223,21600}, #line 113 "zonetab.list" - {gperf_offsetof(stringpool, 224), -14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str224, -14400}, #line 262 "zonetab.list" - {gperf_offsetof(stringpool, 225),39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str225,39600}, {-1}, #line 11 "zonetab.list" - {gperf_offsetof(stringpool, 227), 0*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str227, 0*3600}, #line 301 "zonetab.list" - {gperf_offsetof(stringpool, 228),10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str228,10800}, #line 315 "zonetab.list" - {gperf_offsetof(stringpool, 229),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str229,43200}, #line 291 "zonetab.list" - {gperf_offsetof(stringpool, 230),-10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str230,-10800}, #line 20 "zonetab.list" - {gperf_offsetof(stringpool, 231), -7*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str231, -7*3600}, #line 248 "zonetab.list" - {gperf_offsetof(stringpool, 232),39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str232,39600}, {-1}, #line 52 "zonetab.list" - {gperf_offsetof(stringpool, 234), -3*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str234, -3*3600}, #line 14 "zonetab.list" - {gperf_offsetof(stringpool, 235), -4*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str235, -4*3600}, {-1}, {-1}, #line 277 "zonetab.list" - {gperf_offsetof(stringpool, 238),18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str238,18000}, #line 188 "zonetab.list" - {gperf_offsetof(stringpool, 239),21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str239,21600}, #line 320 "zonetab.list" - {gperf_offsetof(stringpool, 240),28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str240,28800}, {-1}, #line 317 "zonetab.list" - {gperf_offsetof(stringpool, 242),-10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str242,-10800}, #line 60 "zonetab.list" - {gperf_offsetof(stringpool, 243),-9*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str243,-9*3600}, #line 316 "zonetab.list" - {gperf_offsetof(stringpool, 244),-7200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str244,-7200}, {-1}, #line 246 "zonetab.list" - {gperf_offsetof(stringpool, 246),25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str246,25200}, #line 245 "zonetab.list" - {gperf_offsetof(stringpool, 247),28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str247,28800}, #line 147 "zonetab.list" - {gperf_offsetof(stringpool, 248), -7200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str248, -7200}, #line 18 "zonetab.list" - {gperf_offsetof(stringpool, 249), -6*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str249, -6*3600}, #line 250 "zonetab.list" - {gperf_offsetof(stringpool, 250),50400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str250,50400}, #line 165 "zonetab.list" - {gperf_offsetof(stringpool, 251), 28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str251, 28800}, #line 16 "zonetab.list" - {gperf_offsetof(stringpool, 252), -5*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str252, -5*3600}, #line 76 "zonetab.list" - {gperf_offsetof(stringpool, 253), 1*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str253, 1*3600}, {-1}, #line 164 "zonetab.list" - {gperf_offsetof(stringpool, 255), 25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str255, 25200}, #line 41 "zonetab.list" - {gperf_offsetof(stringpool, 256), -9*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str256, -9*3600}, {-1}, #line 171 "zonetab.list" - {gperf_offsetof(stringpool, 258), 46800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str258, 46800}, #line 211 "zonetab.list" - {gperf_offsetof(stringpool, 259),-36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str259,-36000}, {-1}, #line 308 "zonetab.list" - {gperf_offsetof(stringpool, 261),-14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str261,-14400}, #line 119 "zonetab.list" - {gperf_offsetof(stringpool, 262), 14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str262, 14400}, #line 123 "zonetab.list" - {gperf_offsetof(stringpool, 263), 3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str263, 3600}, #line 28 "zonetab.list" - {gperf_offsetof(stringpool, 264), 8*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str264, 8*3600}, #line 124 "zonetab.list" - {gperf_offsetof(stringpool, 265), 3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str265, 3600}, #line 153 "zonetab.list" - {gperf_offsetof(stringpool, 266), -12600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str266, -12600}, #line 110 "zonetab.list" - {gperf_offsetof(stringpool, 267), 10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str267, 10800}, #line 289 "zonetab.list" - {gperf_offsetof(stringpool, 268),14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str268,14400}, #line 112 "zonetab.list" - {gperf_offsetof(stringpool, 269), 10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str269, 10800}, #line 111 "zonetab.list" - {gperf_offsetof(stringpool, 270), 14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str270, 14400}, #line 216 "zonetab.list" - {gperf_offsetof(stringpool, 271),36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str271,36000}, {-1}, #line 311 "zonetab.list" - {gperf_offsetof(stringpool, 273),21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str273,21600}, #line 66 "zonetab.list" - {gperf_offsetof(stringpool, 274),-10*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str274,-10*3600}, #line 151 "zonetab.list" - {gperf_offsetof(stringpool, 275), 20700}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str275, 20700}, #line 267 "zonetab.list" - {gperf_offsetof(stringpool, 276),-39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str276,-39600}, #line 225 "zonetab.list" - {gperf_offsetof(stringpool, 277),-14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str277,-14400}, {-1}, #line 224 "zonetab.list" - {gperf_offsetof(stringpool, 279),-10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str279,-10800}, #line 67 "zonetab.list" - {gperf_offsetof(stringpool, 280),-10*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str280,-10*3600}, #line 237 "zonetab.list" - {gperf_offsetof(stringpool, 281),10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str281,10800}, {-1}, {-1}, #line 297 "zonetab.list" - {gperf_offsetof(stringpool, 284),32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str284,32400}, #line 175 "zonetab.list" - {gperf_offsetof(stringpool, 285), 28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str285, 28800}, #line 134 "zonetab.list" - {gperf_offsetof(stringpool, 286), 7200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str286, 7200}, #line 149 "zonetab.list" - {gperf_offsetof(stringpool, 287), 23400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str287, 23400}, #line 107 "zonetab.list" - {gperf_offsetof(stringpool, 288),13*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str288,13*3600}, #line 230 "zonetab.list" - {gperf_offsetof(stringpool, 289),-10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str289,-10800}, #line 307 "zonetab.list" - {gperf_offsetof(stringpool, 290),18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str290,18000}, {-1}, {-1}, #line 155 "zonetab.list" - {gperf_offsetof(stringpool, 293), 25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str293, 25200}, #line 258 "zonetab.list" - {gperf_offsetof(stringpool, 294),18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str294,18000}, #line 227 "zonetab.list" - {gperf_offsetof(stringpool, 295),-21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str295,-21600}, #line 261 "zonetab.list" - {gperf_offsetof(stringpool, 296),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str296,43200}, #line 213 "zonetab.list" - {gperf_offsetof(stringpool, 297),-3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str297,-3600}, #line 154 "zonetab.list" - {gperf_offsetof(stringpool, 298), 28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str298, 28800}, {-1}, #line 243 "zonetab.list" - {gperf_offsetof(stringpool, 300),21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str300,21600}, #line 114 "zonetab.list" - {gperf_offsetof(stringpool, 301), 34200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str301, 34200}, #line 157 "zonetab.list" - {gperf_offsetof(stringpool, 302), -28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str302, -28800}, {-1}, #line 117 "zonetab.list" - {gperf_offsetof(stringpool, 304), -21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str304, -21600}, {-1}, #line 156 "zonetab.list" - {gperf_offsetof(stringpool, 306), -14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str306, -14400}, #line 116 "zonetab.list" - {gperf_offsetof(stringpool, 307), -3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str307, -3600}, #line 228 "zonetab.list" - {gperf_offsetof(stringpool, 308),-32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str308,-32400}, #line 294 "zonetab.list" - {gperf_offsetof(stringpool, 309),18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str309,18000}, #line 37 "zonetab.list" - {gperf_offsetof(stringpool, 310), -5*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str310, -5*3600}, #line 137 "zonetab.list" - {gperf_offsetof(stringpool, 311), 7200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str311, 7200}, #line 58 "zonetab.list" - {gperf_offsetof(stringpool, 312),-8*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str312,-8*3600}, #line 304 "zonetab.list" - {gperf_offsetof(stringpool, 313),28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str313,28800}, #line 303 "zonetab.list" - {gperf_offsetof(stringpool, 314),32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str314,32400}, #line 284 "zonetab.list" - {gperf_offsetof(stringpool, 315),14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str315,14400}, {-1}, #line 295 "zonetab.list" - {gperf_offsetof(stringpool, 317),18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str317,18000}, {-1}, #line 166 "zonetab.list" - {gperf_offsetof(stringpool, 319), 7200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str319, 7200}, {-1}, {-1}, {-1}, {-1}, #line 97 "zonetab.list" - {gperf_offsetof(stringpool, 324), 8*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str324, 8*3600}, {-1}, #line 50 "zonetab.list" - {gperf_offsetof(stringpool, 326), -(1*3600+1800)}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str326, -(1*3600+1800)}, #line 285 "zonetab.list" - {gperf_offsetof(stringpool, 327),-10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str327,-10800}, {-1}, {-1}, #line 287 "zonetab.list" - {gperf_offsetof(stringpool, 330),14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str330,14400}, {-1}, #line 169 "zonetab.list" - {gperf_offsetof(stringpool, 332), 36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str332, 36000}, {-1}, #line 235 "zonetab.list" - {gperf_offsetof(stringpool, 334),25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str334,25200}, #line 234 "zonetab.list" - {gperf_offsetof(stringpool, 335),28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str335,28800}, {-1}, {-1}, #line 232 "zonetab.list" - {gperf_offsetof(stringpool, 338),-14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str338,-14400}, {-1}, {-1}, {-1}, #line 44 "zonetab.list" - {gperf_offsetof(stringpool, 342), -12*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str342, -12*3600}, #line 61 "zonetab.list" - {gperf_offsetof(stringpool, 343),-9*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str343,-9*3600}, #line 162 "zonetab.list" - {gperf_offsetof(stringpool, 344), -14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str344, -14400}, #line 141 "zonetab.list" - {gperf_offsetof(stringpool, 345), -36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str345, -36000}, {-1}, #line 306 "zonetab.list" - {gperf_offsetof(stringpool, 347),-10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str347,-10800}, {-1}, #line 305 "zonetab.list" - {gperf_offsetof(stringpool, 349),-7200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str349,-7200}, #line 326 "zonetab.list" - {gperf_offsetof(stringpool, 350),18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str350,18000}, #line 325 "zonetab.list" - {gperf_offsetof(stringpool, 351),21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str351,21600}, #line 247 "zonetab.list" - {gperf_offsetof(stringpool, 352),14400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str352,14400}, #line 323 "zonetab.list" - {gperf_offsetof(stringpool, 353),32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str353,32400}, #line 322 "zonetab.list" - {gperf_offsetof(stringpool, 354),36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str354,36000}, {-1}, {-1}, {-1}, #line 63 "zonetab.list" - {gperf_offsetof(stringpool, 358), -9*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str358, -9*3600}, #line 144 "zonetab.list" - {gperf_offsetof(stringpool, 359), 7200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str359, 7200}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 167 "zonetab.list" - {gperf_offsetof(stringpool, 365), 21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str365, 21600}, {-1}, #line 180 "zonetab.list" - {gperf_offsetof(stringpool, 367), 32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str367, 32400}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 318 "zonetab.list" - {gperf_offsetof(stringpool, 375),25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str375,25200}, {-1}, #line 115 "zonetab.list" - {gperf_offsetof(stringpool, 377), 36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str377, 36000}, #line 231 "zonetab.list" - {gperf_offsetof(stringpool, 378),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str378,43200}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 173 "zonetab.list" - {gperf_offsetof(stringpool, 387), -25200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str387, -25200}, {-1}, {-1}, {-1}, #line 310 "zonetab.list" - {gperf_offsetof(stringpool, 391),36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str391,36000}, #line 309 "zonetab.list" - {gperf_offsetof(stringpool, 392),39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str392,39600}, {-1}, {-1}, #line 140 "zonetab.list" - {gperf_offsetof(stringpool, 395), 7200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str395, 7200}, {-1}, {-1}, #line 168 "zonetab.list" - {gperf_offsetof(stringpool, 398), 28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str398, 28800}, #line 290 "zonetab.list" - {gperf_offsetof(stringpool, 399),39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str399,39600}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 118 "zonetab.list" - {gperf_offsetof(stringpool, 408), -3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str408, -3600}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 296 "zonetab.list" - {gperf_offsetof(stringpool, 417),46800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str417,46800}, #line 163 "zonetab.list" - {gperf_offsetof(stringpool, 418), -39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str418, -39600}, {-1}, {-1}, #line 161 "zonetab.list" - {gperf_offsetof(stringpool, 421), -18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str421, -18000}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 312 "zonetab.list" - {gperf_offsetof(stringpool, 427),39600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str427,39600}, #line 69 "zonetab.list" - {gperf_offsetof(stringpool, 428),-12*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str428,-12*3600}, {-1}, {-1}, {-1}, #line 136 "zonetab.list" - {gperf_offsetof(stringpool, 432), 43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str432, 43200}, {-1}, {-1}, #line 46 "zonetab.list" - {gperf_offsetof(stringpool, 435), 0*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str435, 0*3600}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 145 "zonetab.list" - {gperf_offsetof(stringpool, 443), 32400}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str443, 32400}, {-1}, #line 131 "zonetab.list" - {gperf_offsetof(stringpool, 445), 7200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str445, 7200}, {-1}, {-1}, {-1}, #line 292 "zonetab.list" - {gperf_offsetof(stringpool, 449),10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str449,10800}, {-1}, {-1}, #line 150 "zonetab.list" - {gperf_offsetof(stringpool, 452), 21600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str452, 21600}, {-1}, {-1}, #line 302 "zonetab.list" - {gperf_offsetof(stringpool, 455),43200}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str455,43200}, {-1}, {-1}, #line 176 "zonetab.list" - {gperf_offsetof(stringpool, 458), 3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str458, 3600}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 135 "zonetab.list" - {gperf_offsetof(stringpool, 466), 18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str466, 18000}, {-1}, #line 174 "zonetab.list" - {gperf_offsetof(stringpool, 468), 36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str468, 36000}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 324 "zonetab.list" - {gperf_offsetof(stringpool, 476),36000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str476,36000}, #line 172 "zonetab.list" - {gperf_offsetof(stringpool, 477), -18000}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str477, -18000}, {-1}, {-1}, {-1}, {-1}, #line 160 "zonetab.list" - {gperf_offsetof(stringpool, 482), -10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str482, -10800}, {-1}, {-1}, #line 62 "zonetab.list" - {gperf_offsetof(stringpool, 485), -9*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str485, -9*3600}, #line 159 "zonetab.list" - {gperf_offsetof(stringpool, 486), 10800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str486, 10800}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 233 "zonetab.list" - {gperf_offsetof(stringpool, 492),28800}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str492,28800}, {-1}, {-1}, {-1}, {-1}, #line 158 "zonetab.list" - {gperf_offsetof(stringpool, 497), 3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str497, 3600}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 177 "zonetab.list" - {gperf_offsetof(stringpool, 540), 3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str540, 3600}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 59 "zonetab.list" - {gperf_offsetof(stringpool, 563), -8*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str563, -8*3600}, {-1}, {-1}, #line 104 "zonetab.list" - {gperf_offsetof(stringpool, 566),12*3600}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str566,12*3600}, #line 139 "zonetab.list" - {gperf_offsetof(stringpool, 567), 0}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str567, 0}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, @@ -1537,7 +1536,7 @@ {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 138 "zonetab.list" - {gperf_offsetof(stringpool, 619), -10800} + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str619, -10800} }; if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) diff -Nru ruby3.3-3.3.8/ext/etc/extconf.rb ruby3.3-3.3.13/ext/etc/extconf.rb --- ruby3.3-3.3.8/ext/etc/extconf.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/etc/extconf.rb 2026-10-23 03:17:41.000000000 +0000 @@ -58,7 +58,7 @@ # TODO: remove when dropping 2.7 support, as exported since 3.0 have_func('rb_deprecate_constant(Qnil, "None")') -have_func("rb_io_descriptor") +have_func("rb_io_descriptor", "ruby/io.h") $distcleanfiles << "constdefs.h" diff -Nru ruby3.3-3.3.8/ext/extmk.rb ruby3.3-3.3.13/ext/extmk.rb --- ruby3.3-3.3.8/ext/extmk.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/extmk.rb 2026-10-23 03:17:41.000000000 +0000 @@ -557,6 +557,7 @@ if $static and (target = args.first).include?("/") base = File.basename(target) $defs << "-DInit_#{base}=Init_#{target.tr('/', '_')}" + $defs << "-DInitVM_#{base}=InitVM_#{target.tr('/', '_')}" end return super end diff -Nru ruby3.3-3.3.8/ext/io/console/depend ruby3.3-3.3.13/ext/io/console/depend --- ruby3.3-3.3.8/ext/io/console/depend 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/io/console/depend 2026-10-23 03:17:41.000000000 +0000 @@ -184,7 +184,7 @@ -e 'n=$$F[1] and (n.strip!; /\AVK_/=~n) and' \ -e 'puts(%[#ifndef #{n}\n# define #{n} UNDEFINED_VK\n#endif])' \ $< && \ - gperf --ignore-case -E -C -P -p -j1 -i 1 -g -o -t -K ofs -N console_win32_vk -k* $< \ + gperf --ignore-case -L ANSI-C -E -C -P -p -j1 -i 1 -g -o -t -K ofs -N console_win32_vk -k* $< \ | sed -f $(top_srcdir)/tool/gperf.sed \ ) > $(@F) diff -Nru ruby3.3-3.3.8/ext/io/console/extconf.rb ruby3.3-3.3.13/ext/io/console/extconf.rb --- ruby3.3-3.3.8/ext/io/console/extconf.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/io/console/extconf.rb 2026-10-23 03:17:41.000000000 +0000 @@ -6,11 +6,11 @@ rescue end -have_func("rb_io_path") -have_func("rb_io_descriptor") -have_func("rb_io_get_write_io") -have_func("rb_io_closed_p") -have_func("rb_io_open_descriptor") +have_func("rb_io_path", "ruby/io.h") +have_func("rb_io_descriptor", "ruby/io.h") +have_func("rb_io_get_write_io", "ruby/io.h") +have_func("rb_io_closed_p", "ruby/io.h") +have_func("rb_io_open_descriptor", "ruby/io.h") ok = true if RUBY_ENGINE == "ruby" || RUBY_ENGINE == "truffleruby" hdr = nil diff -Nru ruby3.3-3.3.8/ext/io/console/win32_vk.inc ruby3.3-3.3.13/ext/io/console/win32_vk.inc --- ruby3.3-3.3.8/ext/io/console/win32_vk.inc 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/io/console/win32_vk.inc 2026-10-23 03:17:41.000000000 +0000 @@ -480,7 +480,7 @@ # define VK_OEM_CLEAR UNDEFINED_VK #endif /* ANSI-C code produced by gperf version 3.1 */ -/* Command-line: gperf --ignore-case -E -C -P -p -j1 -i 1 -g -o -t -K ofs -N console_win32_vk -k'*' win32_vk.list */ +/* Command-line: gperf --ignore-case -L ANSI-C -E -C -P -p -j1 -i 1 -g -o -t -K ofs -N console_win32_vk -k'*' win32_vk.list */ #if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ @@ -509,18 +509,17 @@ #error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gperf@gnu.org>." #endif -#define gperf_offsetof(s, n) (short)offsetof(struct s##_t, s##_str##n) #line 1 "win32_vk.list" struct vktable {short ofs; unsigned short vk;}; -static const struct vktable *console_win32_vk(/*const char *, unsigned int*/); +static const struct vktable *console_win32_vk(const char *, size_t); #line 5 "win32_vk.list" struct vktable; /* maximum key range = 245, duplicates = 0 */ #ifndef GPERF_DOWNCASE #define GPERF_DOWNCASE 1 -static unsigned char gperf_downcase[256] = +static const unsigned char gperf_downcase[256] = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, @@ -1007,368 +1006,368 @@ {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 40 "win32_vk.list" - {gperf_offsetof(stringpool, 12), VK_UP}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str12, VK_UP}, #line 52 "win32_vk.list" - {gperf_offsetof(stringpool, 13), VK_APPS}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str13, VK_APPS}, #line 159 "win32_vk.list" - {gperf_offsetof(stringpool, 14), VK_CRSEL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str14, VK_CRSEL}, #line 34 "win32_vk.list" - {gperf_offsetof(stringpool, 15), VK_SPACE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str15, VK_SPACE}, #line 95 "win32_vk.list" - {gperf_offsetof(stringpool, 16), VK_SCROLL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str16, VK_SCROLL}, #line 29 "win32_vk.list" - {gperf_offsetof(stringpool, 17), VK_ESCAPE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str17, VK_ESCAPE}, #line 9 "win32_vk.list" - {gperf_offsetof(stringpool, 18), VK_CANCEL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str18, VK_CANCEL}, #line 32 "win32_vk.list" - {gperf_offsetof(stringpool, 19), VK_ACCEPT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str19, VK_ACCEPT}, #line 66 "win32_vk.list" - {gperf_offsetof(stringpool, 20), VK_SEPARATOR}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str20, VK_SEPARATOR}, #line 43 "win32_vk.list" - {gperf_offsetof(stringpool, 21), VK_SELECT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str21, VK_SELECT}, #line 18 "win32_vk.list" - {gperf_offsetof(stringpool, 22), VK_CONTROL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str22, VK_CONTROL}, #line 166 "win32_vk.list" - {gperf_offsetof(stringpool, 23), VK_OEM_CLEAR}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str23, VK_OEM_CLEAR}, #line 145 "win32_vk.list" - {gperf_offsetof(stringpool, 24), VK_OEM_RESET}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str24, VK_OEM_RESET}, #line 155 "win32_vk.list" - {gperf_offsetof(stringpool, 25), VK_OEM_AUTO}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str25, VK_OEM_AUTO}, #line 151 "win32_vk.list" - {gperf_offsetof(stringpool, 26), VK_OEM_CUSEL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str26, VK_OEM_CUSEL}, {-1}, #line 22 "win32_vk.list" - {gperf_offsetof(stringpool, 28), VK_KANA}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str28, VK_KANA}, #line 127 "win32_vk.list" - {gperf_offsetof(stringpool, 29), VK_OEM_PLUS}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str29, VK_OEM_PLUS}, #line 35 "win32_vk.list" - {gperf_offsetof(stringpool, 30), VK_PRIOR}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str30, VK_PRIOR}, #line 152 "win32_vk.list" - {gperf_offsetof(stringpool, 31), VK_OEM_ATTN}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str31, VK_OEM_ATTN}, #line 20 "win32_vk.list" - {gperf_offsetof(stringpool, 32), VK_PAUSE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str32, VK_PAUSE}, #line 13 "win32_vk.list" - {gperf_offsetof(stringpool, 33), VK_BACK}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str33, VK_BACK}, #line 144 "win32_vk.list" - {gperf_offsetof(stringpool, 34), VK_PACKET}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str34, VK_PACKET}, #line 105 "win32_vk.list" - {gperf_offsetof(stringpool, 35), VK_RCONTROL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str35, VK_RCONTROL}, #line 104 "win32_vk.list" - {gperf_offsetof(stringpool, 36), VK_LCONTROL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str36, VK_LCONTROL}, #line 37 "win32_vk.list" - {gperf_offsetof(stringpool, 37), VK_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str37, VK_END}, #line 38 "win32_vk.list" - {gperf_offsetof(stringpool, 38), VK_HOME}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str38, VK_HOME}, #line 44 "win32_vk.list" - {gperf_offsetof(stringpool, 39), VK_PRINT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str39, VK_PRINT}, #line 94 "win32_vk.list" - {gperf_offsetof(stringpool, 40), VK_NUMLOCK}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str40, VK_NUMLOCK}, #line 39 "win32_vk.list" - {gperf_offsetof(stringpool, 41), VK_LEFT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str41, VK_LEFT}, #line 25 "win32_vk.list" - {gperf_offsetof(stringpool, 42), VK_JUNJA}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str42, VK_JUNJA}, #line 19 "win32_vk.list" - {gperf_offsetof(stringpool, 43), VK_MENU}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str43, VK_MENU}, #line 150 "win32_vk.list" - {gperf_offsetof(stringpool, 44), VK_OEM_WSCTRL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str44, VK_OEM_WSCTRL}, #line 156 "win32_vk.list" - {gperf_offsetof(stringpool, 45), VK_OEM_ENLW}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str45, VK_OEM_ENLW}, #line 36 "win32_vk.list" - {gperf_offsetof(stringpool, 46), VK_NEXT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str46, VK_NEXT}, #line 51 "win32_vk.list" - {gperf_offsetof(stringpool, 47), VK_RWIN}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str47, VK_RWIN}, #line 50 "win32_vk.list" - {gperf_offsetof(stringpool, 48), VK_LWIN}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str48, VK_LWIN}, #line 21 "win32_vk.list" - {gperf_offsetof(stringpool, 49), VK_CAPITAL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str49, VK_CAPITAL}, #line 49 "win32_vk.list" - {gperf_offsetof(stringpool, 50), VK_HELP}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str50, VK_HELP}, #line 164 "win32_vk.list" - {gperf_offsetof(stringpool, 51), VK_NONAME}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str51, VK_NONAME}, #line 8 "win32_vk.list" - {gperf_offsetof(stringpool, 52), VK_RBUTTON}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str52, VK_RBUTTON}, #line 7 "win32_vk.list" - {gperf_offsetof(stringpool, 53), VK_LBUTTON}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str53, VK_LBUTTON}, #line 96 "win32_vk.list" - {gperf_offsetof(stringpool, 54), VK_OEM_NEC_EQUAL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str54, VK_OEM_NEC_EQUAL}, {-1}, #line 47 "win32_vk.list" - {gperf_offsetof(stringpool, 56), VK_INSERT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str56, VK_INSERT}, #line 27 "win32_vk.list" - {gperf_offsetof(stringpool, 57), VK_HANJA}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str57, VK_HANJA}, {-1}, {-1}, #line 46 "win32_vk.list" - {gperf_offsetof(stringpool, 60), VK_SNAPSHOT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str60, VK_SNAPSHOT}, #line 158 "win32_vk.list" - {gperf_offsetof(stringpool, 61), VK_ATTN}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str61, VK_ATTN}, #line 14 "win32_vk.list" - {gperf_offsetof(stringpool, 62), VK_TAB}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str62, VK_TAB}, #line 157 "win32_vk.list" - {gperf_offsetof(stringpool, 63), VK_OEM_BACKTAB}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str63, VK_OEM_BACKTAB}, #line 143 "win32_vk.list" - {gperf_offsetof(stringpool, 64), VK_ICO_CLEAR}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str64, VK_ICO_CLEAR}, #line 30 "win32_vk.list" - {gperf_offsetof(stringpool, 65), VK_CONVERT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str65, VK_CONVERT}, #line 16 "win32_vk.list" - {gperf_offsetof(stringpool, 66), VK_RETURN}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str66, VK_RETURN}, #line 146 "win32_vk.list" - {gperf_offsetof(stringpool, 67), VK_OEM_JUMP}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str67, VK_OEM_JUMP}, {-1}, {-1}, {-1}, #line 111 "win32_vk.list" - {gperf_offsetof(stringpool, 71), VK_BROWSER_STOP}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str71, VK_BROWSER_STOP}, #line 26 "win32_vk.list" - {gperf_offsetof(stringpool, 72), VK_FINAL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str72, VK_FINAL}, #line 163 "win32_vk.list" - {gperf_offsetof(stringpool, 73), VK_ZOOM}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str73, VK_ZOOM}, #line 28 "win32_vk.list" - {gperf_offsetof(stringpool, 74), VK_KANJI}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str74, VK_KANJI}, #line 48 "win32_vk.list" - {gperf_offsetof(stringpool, 75), VK_DELETE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str75, VK_DELETE}, #line 128 "win32_vk.list" - {gperf_offsetof(stringpool, 76), VK_OEM_COMMA}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str76, VK_OEM_COMMA}, #line 67 "win32_vk.list" - {gperf_offsetof(stringpool, 77), VK_SUBTRACT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str77, VK_SUBTRACT}, {-1}, #line 10 "win32_vk.list" - {gperf_offsetof(stringpool, 79), VK_MBUTTON}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str79, VK_MBUTTON}, #line 78 "win32_vk.list" - {gperf_offsetof(stringpool, 80), VK_F9}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str80, VK_F9}, #line 17 "win32_vk.list" - {gperf_offsetof(stringpool, 81), VK_SHIFT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str81, VK_SHIFT}, #line 103 "win32_vk.list" - {gperf_offsetof(stringpool, 82), VK_RSHIFT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str82, VK_RSHIFT}, #line 102 "win32_vk.list" - {gperf_offsetof(stringpool, 83), VK_LSHIFT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str83, VK_LSHIFT}, #line 65 "win32_vk.list" - {gperf_offsetof(stringpool, 84), VK_ADD}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str84, VK_ADD}, #line 31 "win32_vk.list" - {gperf_offsetof(stringpool, 85), VK_NONCONVERT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str85, VK_NONCONVERT}, #line 160 "win32_vk.list" - {gperf_offsetof(stringpool, 86), VK_EXSEL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str86, VK_EXSEL}, #line 126 "win32_vk.list" - {gperf_offsetof(stringpool, 87), VK_OEM_1}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str87, VK_OEM_1}, #line 138 "win32_vk.list" - {gperf_offsetof(stringpool, 88), VK_OEM_AX}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str88, VK_OEM_AX}, #line 108 "win32_vk.list" - {gperf_offsetof(stringpool, 89), VK_BROWSER_BACK}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str89, VK_BROWSER_BACK}, #line 137 "win32_vk.list" - {gperf_offsetof(stringpool, 90), VK_OEM_8}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str90, VK_OEM_8}, #line 129 "win32_vk.list" - {gperf_offsetof(stringpool, 91), VK_OEM_MINUS}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str91, VK_OEM_MINUS}, #line 162 "win32_vk.list" - {gperf_offsetof(stringpool, 92), VK_PLAY}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str92, VK_PLAY}, #line 131 "win32_vk.list" - {gperf_offsetof(stringpool, 93), VK_OEM_2}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str93, VK_OEM_2}, #line 15 "win32_vk.list" - {gperf_offsetof(stringpool, 94), VK_CLEAR}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str94, VK_CLEAR}, #line 99 "win32_vk.list" - {gperf_offsetof(stringpool, 95), VK_OEM_FJ_TOUROKU}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str95, VK_OEM_FJ_TOUROKU}, #line 147 "win32_vk.list" - {gperf_offsetof(stringpool, 96), VK_OEM_PA1}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str96, VK_OEM_PA1}, #line 140 "win32_vk.list" - {gperf_offsetof(stringpool, 97), VK_ICO_HELP}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str97, VK_ICO_HELP}, #line 112 "win32_vk.list" - {gperf_offsetof(stringpool, 98), VK_BROWSER_SEARCH}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str98, VK_BROWSER_SEARCH}, #line 53 "win32_vk.list" - {gperf_offsetof(stringpool, 99), VK_SLEEP}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str99, VK_SLEEP}, {-1}, #line 70 "win32_vk.list" - {gperf_offsetof(stringpool, 101), VK_F1}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str101, VK_F1}, #line 148 "win32_vk.list" - {gperf_offsetof(stringpool, 102), VK_OEM_PA2}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str102, VK_OEM_PA2}, #line 154 "win32_vk.list" - {gperf_offsetof(stringpool, 103), VK_OEM_COPY}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str103, VK_OEM_COPY}, #line 77 "win32_vk.list" - {gperf_offsetof(stringpool, 104), VK_F8}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str104, VK_F8}, #line 88 "win32_vk.list" - {gperf_offsetof(stringpool, 105), VK_F19}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str105, VK_F19}, #line 41 "win32_vk.list" - {gperf_offsetof(stringpool, 106), VK_RIGHT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str106, VK_RIGHT}, #line 71 "win32_vk.list" - {gperf_offsetof(stringpool, 107), VK_F2}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str107, VK_F2}, #line 135 "win32_vk.list" - {gperf_offsetof(stringpool, 108), VK_OEM_6}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str108, VK_OEM_6}, #line 87 "win32_vk.list" - {gperf_offsetof(stringpool, 109), VK_F18}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str109, VK_F18}, {-1}, #line 117 "win32_vk.list" - {gperf_offsetof(stringpool, 111), VK_VOLUME_UP}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str111, VK_VOLUME_UP}, {-1}, {-1}, #line 120 "win32_vk.list" - {gperf_offsetof(stringpool, 114), VK_MEDIA_STOP}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str114, VK_MEDIA_STOP}, #line 130 "win32_vk.list" - {gperf_offsetof(stringpool, 115), VK_OEM_PERIOD}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str115, VK_OEM_PERIOD}, {-1}, #line 161 "win32_vk.list" - {gperf_offsetof(stringpool, 117), VK_EREOF}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str117, VK_EREOF}, {-1}, {-1}, {-1}, #line 114 "win32_vk.list" - {gperf_offsetof(stringpool, 121), VK_BROWSER_HOME}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str121, VK_BROWSER_HOME}, #line 75 "win32_vk.list" - {gperf_offsetof(stringpool, 122), VK_F6}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str122, VK_F6}, {-1}, #line 110 "win32_vk.list" - {gperf_offsetof(stringpool, 124), VK_BROWSER_REFRESH}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str124, VK_BROWSER_REFRESH}, {-1}, #line 165 "win32_vk.list" - {gperf_offsetof(stringpool, 126), VK_PA1}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str126, VK_PA1}, #line 142 "win32_vk.list" - {gperf_offsetof(stringpool, 127), VK_PROCESSKEY}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str127, VK_PROCESSKEY}, #line 68 "win32_vk.list" - {gperf_offsetof(stringpool, 128), VK_DECIMAL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str128, VK_DECIMAL}, #line 132 "win32_vk.list" - {gperf_offsetof(stringpool, 129), VK_OEM_3}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str129, VK_OEM_3}, #line 107 "win32_vk.list" - {gperf_offsetof(stringpool, 130), VK_RMENU}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str130, VK_RMENU}, #line 106 "win32_vk.list" - {gperf_offsetof(stringpool, 131), VK_LMENU}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str131, VK_LMENU}, #line 98 "win32_vk.list" - {gperf_offsetof(stringpool, 132), VK_OEM_FJ_MASSHOU}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str132, VK_OEM_FJ_MASSHOU}, #line 54 "win32_vk.list" - {gperf_offsetof(stringpool, 133), VK_NUMPAD0}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str133, VK_NUMPAD0}, #line 24 "win32_vk.list" - {gperf_offsetof(stringpool, 134), VK_HANGUL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str134, VK_HANGUL}, #line 63 "win32_vk.list" - {gperf_offsetof(stringpool, 135), VK_NUMPAD9}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str135, VK_NUMPAD9}, #line 23 "win32_vk.list" - {gperf_offsetof(stringpool, 136), VK_HANGEUL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str136, VK_HANGEUL}, #line 134 "win32_vk.list" - {gperf_offsetof(stringpool, 137), VK_OEM_5}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str137, VK_OEM_5}, #line 149 "win32_vk.list" - {gperf_offsetof(stringpool, 138), VK_OEM_PA3}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str138, VK_OEM_PA3}, #line 115 "win32_vk.list" - {gperf_offsetof(stringpool, 139), VK_VOLUME_MUTE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str139, VK_VOLUME_MUTE}, #line 133 "win32_vk.list" - {gperf_offsetof(stringpool, 140), VK_OEM_4}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str140, VK_OEM_4}, #line 122 "win32_vk.list" - {gperf_offsetof(stringpool, 141), VK_LAUNCH_MAIL}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str141, VK_LAUNCH_MAIL}, #line 97 "win32_vk.list" - {gperf_offsetof(stringpool, 142), VK_OEM_FJ_JISHO}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str142, VK_OEM_FJ_JISHO}, #line 72 "win32_vk.list" - {gperf_offsetof(stringpool, 143), VK_F3}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str143, VK_F3}, #line 101 "win32_vk.list" - {gperf_offsetof(stringpool, 144), VK_OEM_FJ_ROYA}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str144, VK_OEM_FJ_ROYA}, #line 100 "win32_vk.list" - {gperf_offsetof(stringpool, 145), VK_OEM_FJ_LOYA}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str145, VK_OEM_FJ_LOYA}, {-1}, #line 42 "win32_vk.list" - {gperf_offsetof(stringpool, 147), VK_DOWN}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str147, VK_DOWN}, {-1}, #line 153 "win32_vk.list" - {gperf_offsetof(stringpool, 149), VK_OEM_FINISH}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str149, VK_OEM_FINISH}, {-1}, #line 74 "win32_vk.list" - {gperf_offsetof(stringpool, 151), VK_F5}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str151, VK_F5}, {-1}, #line 136 "win32_vk.list" - {gperf_offsetof(stringpool, 153), VK_OEM_7}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str153, VK_OEM_7}, #line 73 "win32_vk.list" - {gperf_offsetof(stringpool, 154), VK_F4}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str154, VK_F4}, #line 86 "win32_vk.list" - {gperf_offsetof(stringpool, 155), VK_F17}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str155, VK_F17}, #line 55 "win32_vk.list" - {gperf_offsetof(stringpool, 156), VK_NUMPAD1}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str156, VK_NUMPAD1}, #line 141 "win32_vk.list" - {gperf_offsetof(stringpool, 157), VK_ICO_00}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str157, VK_ICO_00}, {-1}, #line 62 "win32_vk.list" - {gperf_offsetof(stringpool, 159), VK_NUMPAD8}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str159, VK_NUMPAD8}, {-1}, {-1}, #line 56 "win32_vk.list" - {gperf_offsetof(stringpool, 162), VK_NUMPAD2}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str162, VK_NUMPAD2}, {-1}, #line 124 "win32_vk.list" - {gperf_offsetof(stringpool, 164), VK_LAUNCH_APP1}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str164, VK_LAUNCH_APP1}, #line 109 "win32_vk.list" - {gperf_offsetof(stringpool, 165), VK_BROWSER_FORWARD}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str165, VK_BROWSER_FORWARD}, {-1}, #line 76 "win32_vk.list" - {gperf_offsetof(stringpool, 167), VK_F7}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str167, VK_F7}, {-1}, {-1}, #line 125 "win32_vk.list" - {gperf_offsetof(stringpool, 170), VK_LAUNCH_APP2}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str170, VK_LAUNCH_APP2}, #line 64 "win32_vk.list" - {gperf_offsetof(stringpool, 171), VK_MULTIPLY}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str171, VK_MULTIPLY}, {-1}, {-1}, #line 45 "win32_vk.list" - {gperf_offsetof(stringpool, 174), VK_EXECUTE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str174, VK_EXECUTE}, {-1}, #line 113 "win32_vk.list" - {gperf_offsetof(stringpool, 176), VK_BROWSER_FAVORITES}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str176, VK_BROWSER_FAVORITES}, #line 60 "win32_vk.list" - {gperf_offsetof(stringpool, 177), VK_NUMPAD6}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str177, VK_NUMPAD6}, {-1}, #line 85 "win32_vk.list" - {gperf_offsetof(stringpool, 179), VK_F16}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str179, VK_F16}, {-1}, {-1}, #line 79 "win32_vk.list" - {gperf_offsetof(stringpool, 182), VK_F10}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str182, VK_F10}, {-1}, {-1}, #line 116 "win32_vk.list" - {gperf_offsetof(stringpool, 185), VK_VOLUME_DOWN}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str185, VK_VOLUME_DOWN}, {-1}, {-1}, #line 89 "win32_vk.list" - {gperf_offsetof(stringpool, 188), VK_F20}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str188, VK_F20}, #line 119 "win32_vk.list" - {gperf_offsetof(stringpool, 189), VK_MEDIA_PREV_TRACK}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str189, VK_MEDIA_PREV_TRACK}, {-1}, #line 33 "win32_vk.list" - {gperf_offsetof(stringpool, 191), VK_MODECHANGE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str191, VK_MODECHANGE}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 83 "win32_vk.list" - {gperf_offsetof(stringpool, 197), VK_F14}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str197, VK_F14}, #line 57 "win32_vk.list" - {gperf_offsetof(stringpool, 198), VK_NUMPAD3}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str198, VK_NUMPAD3}, #line 11 "win32_vk.list" - {gperf_offsetof(stringpool, 199), VK_XBUTTON1}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str199, VK_XBUTTON1}, {-1}, {-1}, {-1}, #line 93 "win32_vk.list" - {gperf_offsetof(stringpool, 203), VK_F24}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str203, VK_F24}, {-1}, #line 12 "win32_vk.list" - {gperf_offsetof(stringpool, 205), VK_XBUTTON2}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str205, VK_XBUTTON2}, #line 59 "win32_vk.list" - {gperf_offsetof(stringpool, 206), VK_NUMPAD5}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str206, VK_NUMPAD5}, {-1}, {-1}, #line 58 "win32_vk.list" - {gperf_offsetof(stringpool, 209), VK_NUMPAD4}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str209, VK_NUMPAD4}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 121 "win32_vk.list" - {gperf_offsetof(stringpool, 215), VK_MEDIA_PLAY_PAUSE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str215, VK_MEDIA_PLAY_PAUSE}, {-1}, #line 123 "win32_vk.list" - {gperf_offsetof(stringpool, 217), VK_LAUNCH_MEDIA_SELECT}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str217, VK_LAUNCH_MEDIA_SELECT}, #line 80 "win32_vk.list" - {gperf_offsetof(stringpool, 218), VK_F11}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str218, VK_F11}, {-1}, #line 139 "win32_vk.list" - {gperf_offsetof(stringpool, 220), VK_OEM_102}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str220, VK_OEM_102}, #line 118 "win32_vk.list" - {gperf_offsetof(stringpool, 221), VK_MEDIA_NEXT_TRACK}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str221, VK_MEDIA_NEXT_TRACK}, #line 61 "win32_vk.list" - {gperf_offsetof(stringpool, 222), VK_NUMPAD7}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str222, VK_NUMPAD7}, {-1}, #line 90 "win32_vk.list" - {gperf_offsetof(stringpool, 224), VK_F21}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str224, VK_F21}, {-1}, #line 82 "win32_vk.list" - {gperf_offsetof(stringpool, 226), VK_F13}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str226, VK_F13}, {-1}, {-1}, #line 81 "win32_vk.list" - {gperf_offsetof(stringpool, 229), VK_F12}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str229, VK_F12}, {-1}, {-1}, #line 92 "win32_vk.list" - {gperf_offsetof(stringpool, 232), VK_F23}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str232, VK_F23}, {-1}, {-1}, #line 91 "win32_vk.list" - {gperf_offsetof(stringpool, 235), VK_F22}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str235, VK_F22}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 84 "win32_vk.list" - {gperf_offsetof(stringpool, 242), VK_F15}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str242, VK_F15}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 69 "win32_vk.list" - {gperf_offsetof(stringpool, 256), VK_DIVIDE} + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str256, VK_DIVIDE} }; if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) diff -Nru ruby3.3-3.3.8/ext/io/console/win32_vk.list ruby3.3-3.3.13/ext/io/console/win32_vk.list --- ruby3.3-3.3.8/ext/io/console/win32_vk.list 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/io/console/win32_vk.list 2026-10-23 03:17:41.000000000 +0000 @@ -1,6 +1,6 @@ %{ struct vktable {short ofs; unsigned short vk;}; -static const struct vktable *console_win32_vk(/*!ANSI{*/const char *, unsigned int/*}!ANSI*/); +static const struct vktable *console_win32_vk(const char *, size_t); %} struct vktable %% diff -Nru ruby3.3-3.3.8/ext/io/nonblock/extconf.rb ruby3.3-3.3.13/ext/io/nonblock/extconf.rb --- ruby3.3-3.3.8/ext/io/nonblock/extconf.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/io/nonblock/extconf.rb 2026-10-23 03:17:41.000000000 +0000 @@ -7,7 +7,7 @@ return end -have_func("rb_io_descriptor") +have_func("rb_io_descriptor", "ruby/io.h") hdr = %w"fcntl.h" if have_macro("O_NONBLOCK", hdr) and diff -Nru ruby3.3-3.3.8/ext/io/wait/extconf.rb ruby3.3-3.3.13/ext/io/wait/extconf.rb --- ruby3.3-3.3.8/ext/io/wait/extconf.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/io/wait/extconf.rb 2026-10-23 03:17:41.000000000 +0000 @@ -5,8 +5,8 @@ File.write("Makefile", dummy_makefile($srcdir).join("")) else target = "io/wait" - have_func("rb_io_wait") - have_func("rb_io_descriptor") + have_func("rb_io_wait", "ruby/io.h") + have_func("rb_io_descriptor", "ruby/io.h") unless macro_defined?("DOSISH", "#include <ruby.h>") have_header(ioctl_h = "sys/ioctl.h") or ioctl_h = nil fionread = %w[sys/ioctl.h sys/filio.h sys/socket.h].find do |h| diff -Nru ruby3.3-3.3.8/ext/io/wait/wait.c ruby3.3-3.3.13/ext/io/wait/wait.c --- ruby3.3-3.3.8/ext/io/wait/wait.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/io/wait/wait.c 2026-10-23 03:17:41.000000000 +0000 @@ -84,7 +84,7 @@ ioctl_arg n; GetOpenFile(io, fptr); - rb_io_check_readable(fptr); + rb_io_check_char_readable(fptr); len = rb_io_read_pending(fptr); if (len > 0) return INT2FIX(len); @@ -143,7 +143,7 @@ #endif GetOpenFile(io, fptr); - rb_io_check_readable(fptr); + rb_io_check_char_readable(fptr); if (rb_io_read_pending(fptr)) return Qtrue; #ifndef HAVE_RB_IO_WAIT @@ -178,7 +178,7 @@ #endif GetOpenFile(io, fptr); - rb_io_check_readable(fptr); + rb_io_check_char_readable(fptr); #ifndef HAVE_RB_IO_WAIT tv = get_timeout(argc, argv, &timerec); @@ -252,7 +252,7 @@ rb_io_t *fptr = NULL; RB_IO_POINTER(io, fptr); - rb_io_check_readable(fptr); + rb_io_check_char_readable(fptr); if (rb_io_read_pending(fptr)) return Qtrue; diff -Nru ruby3.3-3.3.8/ext/json/parser/extconf.rb ruby3.3-3.3.13/ext/json/parser/extconf.rb --- ruby3.3-3.3.8/ext/json/parser/extconf.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/json/parser/extconf.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1,8 +1,8 @@ # frozen_string_literal: false require 'mkmf' -have_func("rb_enc_raise", "ruby.h") -have_func("rb_enc_interned_str", "ruby.h") +have_func("rb_enc_raise", "ruby/encoding.h") +have_func("rb_enc_interned_str", "ruby/encoding.h") # checking if String#-@ (str_uminus) dedupes... ' begin diff -Nru ruby3.3-3.3.8/ext/openssl/History.md ruby3.3-3.3.13/ext/openssl/History.md --- ruby3.3-3.3.8/ext/openssl/History.md 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/History.md 2026-10-23 03:17:41.000000000 +0000 @@ -1,3 +1,31 @@ +Version 3.2.4 +============= + +Notable changes +--------------- + +* Add support for OpenSSL 4.0. + [[GitHub #1051]](https://github.com/ruby/openssl/pull/1051) + + +Version 3.2.3 +============= + +Merged changes in 3.1.3. + + +Version 3.2.2 +============= + +Merged changes in 3.1.2. + + +Version 3.2.1 +============= + +Merged changes in 3.0.3. + + Version 3.2.0 ============= @@ -38,6 +66,39 @@ [[GitHub #141]](https://github.com/ruby/openssl/pull/141) +Version 3.1.3 +============= + +Bug fixes +--------- + +* Fix missing NULL check for `EVP_PKEY_get0()` functions with OpenSSL 3.x. + [[GitHub #957]](https://github.com/ruby/openssl/pull/957) + + +Version 3.1.2 +============= + +Bug fixes +--------- + +* Fix crash when attempting to export an incomplete `OpenSSL::PKey::DSA` key. + [[GitHub #845]](https://github.com/ruby/openssl/issues/845) + [[GitHub #847]](https://github.com/ruby/openssl/pull/847) +* Remove the `OpenSSL::X509::V_FLAG_CRL_CHECK_ALL` flag from the default store + used by `OpenSSL::SSL::SSLContext#set_params`. It causes certificate + verification to fail with OpenSSL 3.6.0. It has no effect with any other + OpenSSL versions. + [[GitHub #949]](https://github.com/ruby/openssl/issues/949) + [[GitHub #950]](https://github.com/ruby/openssl/pull/950) + + +Version 3.1.1 +============= + +Merged changes in 3.0.3. + + Version 3.1.0 ============= @@ -74,6 +135,31 @@ LibreSSL 3.6 and Ed25519 support in LibreSSL 3.7. +Version 3.0.3 +============= + +Bug fixes +--------- + +* Fix a performance regression introduced in v2.1.3 on a buffered write to + `SSLSocket`. + [[GitHub #706]](https://github.com/ruby/openssl/pull/706) +* Fix `OpenSSL::PKCS7` to handle PKCS#7 structures without content. + [[GitHub #690]](https://github.com/ruby/openssl/pull/690) + [[GitHub #752]](https://github.com/ruby/openssl/pull/752) +* Fix `OpenSSL::ASN1::ObjectId#==` with OIDs without a known name. + [[GitHub #791]](https://github.com/ruby/openssl/issues/791) + [[GitHub #792]](https://github.com/ruby/openssl/pull/792) +* Fix `OpenSSL::X509::Certificate#crl_uris` to handle CDP with multiple CRL + URIs. + [[GitHub #775]](https://github.com/ruby/openssl/issues/775) + [[GitHub #776]](https://github.com/ruby/openssl/pull/776) +* Fix `OpenSSL::Cipher#update` to always make the output buffer `String` + independent. + [[Bug #20937]](https://bugs.ruby-lang.org/issues/20937) + [[GitHub #824]](https://github.com/ruby/openssl/pull/824) + + Version 3.0.2 ============= diff -Nru ruby3.3-3.3.8/ext/openssl/depend ruby3.3-3.3.13/ext/openssl/depend --- ruby3.3-3.3.8/ext/openssl/depend 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/depend 2026-10-23 03:17:41.000000000 +0000 @@ -1,6 +1,162 @@ # AUTOGENERATED DEPENDENCIES START openssl_missing.o: $(RUBY_EXTCONF_H) openssl_missing.o: $(arch_hdrdir)/ruby/config.h +openssl_missing.o: $(hdrdir)/ruby.h +openssl_missing.o: $(hdrdir)/ruby/assert.h +openssl_missing.o: $(hdrdir)/ruby/backward.h +openssl_missing.o: $(hdrdir)/ruby/backward/2/assume.h +openssl_missing.o: $(hdrdir)/ruby/backward/2/attributes.h +openssl_missing.o: $(hdrdir)/ruby/backward/2/bool.h +openssl_missing.o: $(hdrdir)/ruby/backward/2/inttypes.h +openssl_missing.o: $(hdrdir)/ruby/backward/2/limits.h +openssl_missing.o: $(hdrdir)/ruby/backward/2/long_long.h +openssl_missing.o: $(hdrdir)/ruby/backward/2/stdalign.h +openssl_missing.o: $(hdrdir)/ruby/backward/2/stdarg.h +openssl_missing.o: $(hdrdir)/ruby/defines.h +openssl_missing.o: $(hdrdir)/ruby/intern.h +openssl_missing.o: $(hdrdir)/ruby/internal/abi.h +openssl_missing.o: $(hdrdir)/ruby/internal/anyargs.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/char.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/double.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/fixnum.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/gid_t.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/int.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/intptr_t.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/long.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/long_long.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/mode_t.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/off_t.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/pid_t.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/short.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/size_t.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/st_data_t.h +openssl_missing.o: $(hdrdir)/ruby/internal/arithmetic/uid_t.h +openssl_missing.o: $(hdrdir)/ruby/internal/assume.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/alloc_size.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/artificial.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/cold.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/const.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/constexpr.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/deprecated.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/diagnose_if.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/enum_extensibility.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/error.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/flag_enum.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/forceinline.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/format.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/maybe_unused.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/noalias.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/nodiscard.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/noexcept.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/noinline.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/nonnull.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/noreturn.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/packed_struct.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/pure.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/restrict.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/returns_nonnull.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/warning.h +openssl_missing.o: $(hdrdir)/ruby/internal/attr/weakref.h +openssl_missing.o: $(hdrdir)/ruby/internal/cast.h +openssl_missing.o: $(hdrdir)/ruby/internal/compiler_is.h +openssl_missing.o: $(hdrdir)/ruby/internal/compiler_is/apple.h +openssl_missing.o: $(hdrdir)/ruby/internal/compiler_is/clang.h +openssl_missing.o: $(hdrdir)/ruby/internal/compiler_is/gcc.h +openssl_missing.o: $(hdrdir)/ruby/internal/compiler_is/intel.h +openssl_missing.o: $(hdrdir)/ruby/internal/compiler_is/msvc.h +openssl_missing.o: $(hdrdir)/ruby/internal/compiler_is/sunpro.h +openssl_missing.o: $(hdrdir)/ruby/internal/compiler_since.h +openssl_missing.o: $(hdrdir)/ruby/internal/config.h +openssl_missing.o: $(hdrdir)/ruby/internal/constant_p.h +openssl_missing.o: $(hdrdir)/ruby/internal/core.h +openssl_missing.o: $(hdrdir)/ruby/internal/core/rarray.h +openssl_missing.o: $(hdrdir)/ruby/internal/core/rbasic.h +openssl_missing.o: $(hdrdir)/ruby/internal/core/rbignum.h +openssl_missing.o: $(hdrdir)/ruby/internal/core/rclass.h +openssl_missing.o: $(hdrdir)/ruby/internal/core/rdata.h +openssl_missing.o: $(hdrdir)/ruby/internal/core/rfile.h +openssl_missing.o: $(hdrdir)/ruby/internal/core/rhash.h +openssl_missing.o: $(hdrdir)/ruby/internal/core/robject.h +openssl_missing.o: $(hdrdir)/ruby/internal/core/rregexp.h +openssl_missing.o: $(hdrdir)/ruby/internal/core/rstring.h +openssl_missing.o: $(hdrdir)/ruby/internal/core/rstruct.h +openssl_missing.o: $(hdrdir)/ruby/internal/core/rtypeddata.h +openssl_missing.o: $(hdrdir)/ruby/internal/ctype.h +openssl_missing.o: $(hdrdir)/ruby/internal/dllexport.h +openssl_missing.o: $(hdrdir)/ruby/internal/dosish.h +openssl_missing.o: $(hdrdir)/ruby/internal/error.h +openssl_missing.o: $(hdrdir)/ruby/internal/eval.h +openssl_missing.o: $(hdrdir)/ruby/internal/event.h +openssl_missing.o: $(hdrdir)/ruby/internal/fl_type.h +openssl_missing.o: $(hdrdir)/ruby/internal/gc.h +openssl_missing.o: $(hdrdir)/ruby/internal/glob.h +openssl_missing.o: $(hdrdir)/ruby/internal/globals.h +openssl_missing.o: $(hdrdir)/ruby/internal/has/attribute.h +openssl_missing.o: $(hdrdir)/ruby/internal/has/builtin.h +openssl_missing.o: $(hdrdir)/ruby/internal/has/c_attribute.h +openssl_missing.o: $(hdrdir)/ruby/internal/has/cpp_attribute.h +openssl_missing.o: $(hdrdir)/ruby/internal/has/declspec_attribute.h +openssl_missing.o: $(hdrdir)/ruby/internal/has/extension.h +openssl_missing.o: $(hdrdir)/ruby/internal/has/feature.h +openssl_missing.o: $(hdrdir)/ruby/internal/has/warning.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/array.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/bignum.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/class.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/compar.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/complex.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/cont.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/dir.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/enum.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/enumerator.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/error.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/eval.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/file.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/hash.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/io.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/load.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/marshal.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/numeric.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/object.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/parse.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/proc.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/process.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/random.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/range.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/rational.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/re.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/ruby.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/select.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/select/largesize.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/signal.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/sprintf.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/string.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/struct.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/thread.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/time.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/variable.h +openssl_missing.o: $(hdrdir)/ruby/internal/intern/vm.h +openssl_missing.o: $(hdrdir)/ruby/internal/interpreter.h +openssl_missing.o: $(hdrdir)/ruby/internal/iterator.h +openssl_missing.o: $(hdrdir)/ruby/internal/memory.h +openssl_missing.o: $(hdrdir)/ruby/internal/method.h +openssl_missing.o: $(hdrdir)/ruby/internal/module.h +openssl_missing.o: $(hdrdir)/ruby/internal/newobj.h +openssl_missing.o: $(hdrdir)/ruby/internal/scan_args.h +openssl_missing.o: $(hdrdir)/ruby/internal/special_consts.h +openssl_missing.o: $(hdrdir)/ruby/internal/static_assert.h +openssl_missing.o: $(hdrdir)/ruby/internal/stdalign.h +openssl_missing.o: $(hdrdir)/ruby/internal/stdbool.h +openssl_missing.o: $(hdrdir)/ruby/internal/symbol.h +openssl_missing.o: $(hdrdir)/ruby/internal/value.h +openssl_missing.o: $(hdrdir)/ruby/internal/value_type.h +openssl_missing.o: $(hdrdir)/ruby/internal/variable.h +openssl_missing.o: $(hdrdir)/ruby/internal/warning_push.h +openssl_missing.o: $(hdrdir)/ruby/internal/xmalloc.h +openssl_missing.o: $(hdrdir)/ruby/missing.h +openssl_missing.o: $(hdrdir)/ruby/ruby.h +openssl_missing.o: $(hdrdir)/ruby/st.h +openssl_missing.o: $(hdrdir)/ruby/subst.h openssl_missing.o: openssl_missing.c openssl_missing.o: openssl_missing.h ossl.o: $(RUBY_EXTCONF_H) diff -Nru ruby3.3-3.3.8/ext/openssl/extconf.rb ruby3.3-3.3.13/ext/openssl/extconf.rb --- ruby3.3-3.3.8/ext/openssl/extconf.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/extconf.rb 2026-10-23 03:17:41.000000000 +0000 @@ -13,14 +13,7 @@ require "mkmf" -ssl_dirs = nil -if defined?(::TruffleRuby) - # Always respect the openssl prefix chosen by truffle/openssl-prefix - require 'truffle/openssl-prefix' - ssl_dirs = dir_config("openssl", ENV["OPENSSL_PREFIX"]) -else - ssl_dirs = dir_config("openssl") -end +ssl_dirs = dir_config("openssl") dir_config_given = ssl_dirs.any? _, ssl_ldir = ssl_dirs @@ -193,6 +186,7 @@ have_func("TS_RESP_CTX_set_time_cb(NULL, NULL, NULL)", ts_h) have_func("EVP_PBE_scrypt(\"\", 0, (unsigned char *)\"\", 0, 0, 0, 0, 0, NULL, 0)", evp_h) have_func("SSL_CTX_set_post_handshake_auth(NULL, 0)", ssl_h) +have_func("ASN1_STRING_get0_data(NULL)", "openssl/asn1.h") # added in 1.1.1 have_func("EVP_PKEY_check(NULL)", evp_h) @@ -210,6 +204,9 @@ have_func("EVP_PKEY_eq(NULL, NULL)", evp_h) have_func("EVP_PKEY_dup(NULL)", evp_h) +# added in 4.0.0 +have_func("ASN1_BIT_STRING_set1(NULL, NULL, 0, 0)", "openssl/asn1.h") + Logging::message "=== Checking done. ===\n" # Append flags from environment variables. diff -Nru ruby3.3-3.3.8/ext/openssl/lib/openssl/buffering.rb ruby3.3-3.3.13/ext/openssl/lib/openssl/buffering.rb --- ruby3.3-3.3.8/ext/openssl/lib/openssl/buffering.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/lib/openssl/buffering.rb 2026-10-23 03:17:41.000000000 +0000 @@ -345,13 +345,18 @@ @wbuffer << s @wbuffer.force_encoding(Encoding::BINARY) @sync ||= false - if @sync or @wbuffer.size > BLOCK_SIZE - until @wbuffer.empty? - begin - nwrote = syswrite(@wbuffer) - rescue Errno::EAGAIN - retry + buffer_size = @wbuffer.size + if @sync or buffer_size > BLOCK_SIZE + nwrote = 0 + begin + while nwrote < buffer_size do + begin + nwrote += syswrite(@wbuffer[nwrote, buffer_size - nwrote]) + rescue Errno::EAGAIN + retry + end end + ensure @wbuffer[0, nwrote] = "" end end diff -Nru ruby3.3-3.3.8/ext/openssl/lib/openssl/ssl.rb ruby3.3-3.3.13/ext/openssl/lib/openssl/ssl.rb --- ruby3.3-3.3.8/ext/openssl/lib/openssl/ssl.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/lib/openssl/ssl.rb 2026-10-23 03:17:41.000000000 +0000 @@ -92,7 +92,6 @@ DEFAULT_CERT_STORE = OpenSSL::X509::Store.new # :nodoc: DEFAULT_CERT_STORE.set_default_paths - DEFAULT_CERT_STORE.flags = OpenSSL::X509::V_FLAG_CRL_CHECK_ALL # A callback invoked when DH parameters are required for ephemeral DH key # exchange. diff -Nru ruby3.3-3.3.8/ext/openssl/lib/openssl/version.rb ruby3.3-3.3.13/ext/openssl/lib/openssl/version.rb --- ruby3.3-3.3.8/ext/openssl/lib/openssl/version.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/lib/openssl/version.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1,5 +1,5 @@ # frozen_string_literal: true module OpenSSL - VERSION = "3.2.0" + VERSION = "3.2.4" end diff -Nru ruby3.3-3.3.8/ext/openssl/lib/openssl/x509.rb ruby3.3-3.3.13/ext/openssl/lib/openssl/x509.rb --- ruby3.3-3.3.8/ext/openssl/lib/openssl/x509.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/lib/openssl/x509.rb 2026-10-23 03:17:41.000000000 +0000 @@ -122,8 +122,8 @@ include Helpers # Get the distributionPoint fullName URI from the certificate's CRL - # distribution points extension, as described in RFC5280 Section - # 4.2.1.13 + # distribution points extension, as described in RFC 5280 Section + # 4.2.1.13. # # Returns an array of strings or nil or raises ASN1::ASN1Error. def crl_uris @@ -135,19 +135,19 @@ raise ASN1::ASN1Error, "invalid extension" end - crl_uris = cdp_asn1.map do |crl_distribution_point| + crl_uris = cdp_asn1.flat_map do |crl_distribution_point| distribution_point = crl_distribution_point.value.find do |v| v.tag_class == :CONTEXT_SPECIFIC && v.tag == 0 end full_name = distribution_point&.value&.find do |v| v.tag_class == :CONTEXT_SPECIFIC && v.tag == 0 end - full_name&.value&.find do |v| + full_name&.value&.select do |v| v.tag_class == :CONTEXT_SPECIFIC && v.tag == 6 # uniformResourceIdentifier end end - crl_uris&.map(&:value) + crl_uris.empty? ? nil : crl_uris.map(&:value) end end diff -Nru ruby3.3-3.3.8/ext/openssl/openssl.gemspec ruby3.3-3.3.13/ext/openssl/openssl.gemspec --- ruby3.3-3.3.8/ext/openssl/openssl.gemspec 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/openssl.gemspec 2026-10-23 03:17:41.000000000 +0000 @@ -1,6 +1,6 @@ Gem::Specification.new do |spec| spec.name = "openssl" - spec.version = "3.2.0" + spec.version = "3.2.4" spec.authors = ["Martin Bosslet", "SHIBATA Hiroshi", "Zachary Scott", "Kazuki Yamaguchi"] spec.email = ["ruby-core@ruby-lang.org"] spec.summary = %q{SSL/TLS and general-purpose cryptography for Ruby} diff -Nru ruby3.3-3.3.8/ext/openssl/openssl_missing.c ruby3.3-3.3.13/ext/openssl/openssl_missing.c --- ruby3.3-3.3.8/ext/openssl/openssl_missing.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/openssl_missing.c 2026-10-23 03:17:41.000000000 +0000 @@ -8,6 +8,7 @@ * (See the file 'LICENCE'.) */ #include RUBY_EXTCONF_H +#include <ruby.h> #include <string.h> /* memcpy() */ #include <openssl/x509_vfy.h> diff -Nru ruby3.3-3.3.8/ext/openssl/openssl_missing.h ruby3.3-3.3.13/ext/openssl/openssl_missing.h --- ruby3.3-3.3.8/ext/openssl/openssl_missing.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/openssl_missing.h 2026-10-23 03:17:41.000000000 +0000 @@ -210,6 +210,10 @@ } while (0) #endif +#if !defined(HAVE_ASN1_STRING_GET0_DATA) +# define ASN1_STRING_get0_data(x) ((x)->data) +#endif + /* added in 3.0.0 */ #if !defined(HAVE_TS_VERIFY_CTX_SET_CERTS) # define TS_VERIFY_CTX_set_certs(ctx, crts) TS_VERIFY_CTS_set_certs(ctx, crts) @@ -235,4 +239,27 @@ # define EVP_PKEY_eq(a, b) EVP_PKEY_cmp(a, b) #endif +/* added in 4.0.0 */ +#ifndef HAVE_ASN1_BIT_STRING_SET1 +static inline int +ASN1_BIT_STRING_set1(ASN1_BIT_STRING *bitstr, const uint8_t *data, + size_t length, int unused_bits) +{ + if (length > INT_MAX || !ASN1_STRING_set(bitstr, data, (int)length)) + return 0; + bitstr->flags &= ~(ASN1_STRING_FLAG_BITS_LEFT | 0x07); + bitstr->flags |= ASN1_STRING_FLAG_BITS_LEFT | unused_bits; + return 1; +} + +static inline int +ASN1_BIT_STRING_get_length(const ASN1_BIT_STRING *bitstr, size_t *length, + int *unused_bits) +{ + *length = bitstr->length; + *unused_bits = bitstr->flags & 0x07; + return 1; +} +#endif + #endif /* _OSSL_OPENSSL_MISSING_H_ */ diff -Nru ruby3.3-3.3.8/ext/openssl/ossl.c ruby3.3-3.3.13/ext/openssl/ossl.c --- ruby3.3-3.3.8/ext/openssl/ossl.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl.c 2026-10-23 03:17:41.000000000 +0000 @@ -136,7 +136,7 @@ } void -ossl_bin2hex(unsigned char *in, char *out, size_t inlen) +ossl_bin2hex(const unsigned char *in, char *out, size_t inlen) { const char *hex = "0123456789abcdef"; size_t i; diff -Nru ruby3.3-3.3.8/ext/openssl/ossl.h ruby3.3-3.3.13/ext/openssl/ossl.h --- ruby3.3-3.3.8/ext/openssl/ossl.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl.h 2026-10-23 03:17:41.000000000 +0000 @@ -64,6 +64,7 @@ #if OSSL_OPENSSL_PREREQ(3, 0, 0) # define OSSL_USE_PROVIDER +# include <openssl/provider.h> #endif /* @@ -119,7 +120,7 @@ * Convert binary string to hex string. The caller is responsible for * ensuring out has (2 * len) bytes of capacity. */ -void ossl_bin2hex(unsigned char *in, char *out, size_t len); +void ossl_bin2hex(const unsigned char *in, char *out, size_t len); /* * Our default PEM callback diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_asn1.c ruby3.3-3.3.13/ext/openssl/ossl_asn1.c --- ruby3.3-3.3.8/ext/openssl/ossl_asn1.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_asn1.c 2026-10-23 03:17:41.000000000 +0000 @@ -17,17 +17,18 @@ * DATE conversion */ VALUE -asn1time_to_time(const ASN1_TIME *time) +asn1time_to_time(const ASN1_TIME *time_) { + ASN1_TIME *time = (ASN1_TIME *)time_; // const cast for OpenSSL 1.0.2 struct tm tm; VALUE argv[6]; int count; memset(&tm, 0, sizeof(struct tm)); - switch (time->type) { + switch (ASN1_STRING_type(time)) { case V_ASN1_UTCTIME: - count = sscanf((const char *)time->data, "%2d%2d%2d%2d%2d%2dZ", + count = sscanf((const char *)ASN1_STRING_get0_data(time), "%2d%2d%2d%2d%2d%2dZ", &tm.tm_year, &tm.tm_mon, &tm.tm_mday, &tm.tm_hour, &tm.tm_min, &tm.tm_sec); @@ -35,7 +36,7 @@ tm.tm_sec = 0; } else if (count != 6) { ossl_raise(rb_eTypeError, "bad UTCTIME format: \"%s\"", - time->data); + ASN1_STRING_get0_data(time)); } if (tm.tm_year < 69) { tm.tm_year += 2000; @@ -44,7 +45,7 @@ } break; case V_ASN1_GENERALIZEDTIME: - count = sscanf((const char *)time->data, "%4d%2d%2d%2d%2d%2dZ", + count = sscanf((const char *)ASN1_STRING_get0_data(time), "%4d%2d%2d%2d%2d%2dZ", &tm.tm_year, &tm.tm_mon, &tm.tm_mday, &tm.tm_hour, &tm.tm_min, &tm.tm_sec); if (count == 5) { @@ -52,7 +53,7 @@ } else if (count != 6) { ossl_raise(rb_eTypeError, "bad GENERALIZEDTIME format: \"%s\"", - time->data); + ASN1_STRING_get0_data(time)); } break; default: @@ -97,7 +98,8 @@ VALUE asn1str_to_str(const ASN1_STRING *str) { - return rb_str_new((const char *)str->data, str->length); + return rb_str_new((const char *)ASN1_STRING_get0_data(str), + ASN1_STRING_length(str)); } /* @@ -112,9 +114,9 @@ if (!ai) { ossl_raise(rb_eTypeError, "ASN1_INTEGER is NULL!"); } - if (ai->type == V_ASN1_ENUMERATED) - /* const_cast: workaround for old OpenSSL */ - bn = ASN1_ENUMERATED_to_BN((ASN1_ENUMERATED *)ai, NULL); + if (ASN1_STRING_type((ASN1_STRING *)ai) == V_ASN1_ENUMERATED) + /* const_cast: workaround for old OpenSSL */ + bn = ASN1_ENUMERATED_to_BN((ASN1_ENUMERATED *)ai, NULL); else bn = ASN1_INTEGER_to_BN(ai, NULL); @@ -210,7 +212,7 @@ } static ASN1_BIT_STRING* -obj_to_asn1bstr(VALUE obj, long unused_bits) +obj_to_asn1bstr(VALUE obj, int unused_bits) { ASN1_BIT_STRING *bstr; @@ -218,11 +220,11 @@ ossl_raise(eASN1Error, "unused_bits for a bitstring value must be in "\ "the range 0 to 7"); StringValue(obj); - if(!(bstr = ASN1_BIT_STRING_new())) - ossl_raise(eASN1Error, NULL); - ASN1_BIT_STRING_set(bstr, (unsigned char *)RSTRING_PTR(obj), RSTRING_LENINT(obj)); - bstr->flags &= ~(ASN1_STRING_FLAG_BITS_LEFT|0x07); /* clear */ - bstr->flags |= ASN1_STRING_FLAG_BITS_LEFT | unused_bits; + if (!(bstr = ASN1_BIT_STRING_new())) + ossl_raise(eASN1Error, "ASN1_BIT_STRING_new"); + if (!ASN1_BIT_STRING_set1(bstr, (uint8_t *)RSTRING_PTR(obj), + RSTRING_LEN(obj), unused_bits)) + ossl_raise(eASN1Error, "ASN1_BIT_STRING_set1"); return bstr; } @@ -346,22 +348,25 @@ } static VALUE -decode_bstr(unsigned char* der, long length, long *unused_bits) +decode_bstr(unsigned char* der, long length, int *unused_bits) { ASN1_BIT_STRING *bstr; const unsigned char *p; - long len; + size_t len; VALUE ret; + int state; p = der; - if(!(bstr = d2i_ASN1_BIT_STRING(NULL, &p, length))) - ossl_raise(eASN1Error, NULL); - len = bstr->length; - *unused_bits = 0; - if(bstr->flags & ASN1_STRING_FLAG_BITS_LEFT) - *unused_bits = bstr->flags & 0x07; - ret = rb_str_new((const char *)bstr->data, len); + if (!(bstr = d2i_ASN1_BIT_STRING(NULL, &p, length))) + ossl_raise(eASN1Error, "d2i_ASN1_BIT_STRING"); + if (!ASN1_BIT_STRING_get_length(bstr, &len, unused_bits)) { + ASN1_BIT_STRING_free(bstr); + ossl_raise(eASN1Error, "ASN1_BIT_STRING_get_length"); + } + ret = ossl_str_new((const char *)ASN1_STRING_get0_data(bstr), len, &state); ASN1_BIT_STRING_free(bstr); + if (state) + rb_jump_tag(state); return ret; } @@ -746,7 +751,7 @@ { VALUE value, asn1data; unsigned char *p; - long flag = 0; + int flag = 0; p = *pp; @@ -793,18 +798,18 @@ *num_read = hlen + length; if (tc == sym_UNIVERSAL && - tag < ossl_asn1_info_size && ossl_asn1_info[tag].klass) { - VALUE klass = *ossl_asn1_info[tag].klass; - VALUE args[4]; - args[0] = value; - args[1] = INT2NUM(tag); - args[2] = Qnil; - args[3] = tc; - asn1data = rb_obj_alloc(klass); - ossl_asn1_initialize(4, args, asn1data); - if(tag == V_ASN1_BIT_STRING){ - rb_ivar_set(asn1data, sivUNUSED_BITS, LONG2NUM(flag)); - } + tag < ossl_asn1_info_size && ossl_asn1_info[tag].klass) { + VALUE klass = *ossl_asn1_info[tag].klass; + VALUE args[4]; + args[0] = value; + args[1] = INT2NUM(tag); + args[2] = Qnil; + args[3] = tc; + asn1data = rb_obj_alloc(klass); + ossl_asn1_initialize(4, args, asn1data); + if(tag == V_ASN1_BIT_STRING){ + rb_ivar_set(asn1data, sivUNUSED_BITS, INT2NUM(flag)); + } } else { asn1data = rb_obj_alloc(cASN1Data); @@ -1298,30 +1303,6 @@ return ret; } -/* - * call-seq: - * oid == other_oid => true or false - * - * Returns +true+ if _other_oid_ is the same as _oid_ - */ -static VALUE -ossl_asn1obj_eq(VALUE self, VALUE other) -{ - VALUE valSelf, valOther; - int nidSelf, nidOther; - - valSelf = ossl_asn1_get_value(self); - valOther = ossl_asn1_get_value(other); - - if ((nidSelf = OBJ_txt2nid(StringValueCStr(valSelf))) == NID_undef) - ossl_raise(eASN1Error, "OBJ_txt2nid"); - - if ((nidOther = OBJ_txt2nid(StringValueCStr(valOther))) == NID_undef) - ossl_raise(eASN1Error, "OBJ_txt2nid"); - - return nidSelf == nidOther ? Qtrue : Qfalse; -} - static VALUE asn1obj_get_oid_i(VALUE vobj) { @@ -1366,6 +1347,25 @@ return str; } +/* + * call-seq: + * oid == other_oid => true or false + * + * Returns +true+ if _other_oid_ is the same as _oid_. + */ +static VALUE +ossl_asn1obj_eq(VALUE self, VALUE other) +{ + VALUE oid1, oid2; + + if (!rb_obj_is_kind_of(other, cASN1ObjectId)) + return Qfalse; + + oid1 = ossl_asn1obj_get_oid(self); + oid2 = ossl_asn1obj_get_oid(other); + return rb_str_equal(oid1, oid2); +} + #define OSSL_ASN1_IMPL_FACTORY_METHOD(klass) \ static VALUE ossl_asn1_##klass(int argc, VALUE *argv, VALUE self)\ { return rb_funcall3(cASN1##klass, rb_intern("new"), argc, argv); } diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_cipher.c ruby3.3-3.3.13/ext/openssl/ossl_cipher.c --- ruby3.3-3.3.8/ext/openssl/ossl_cipher.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_cipher.c 2026-10-23 03:17:41.000000000 +0000 @@ -386,22 +386,37 @@ in = (unsigned char *)RSTRING_PTR(data); in_len = RSTRING_LEN(data); GetCipher(self, ctx); - out_len = in_len+EVP_CIPHER_CTX_block_size(ctx); - if (out_len <= 0) { + + /* + * As of OpenSSL 3.2, there is no reliable way to determine the required + * output buffer size for arbitrary cipher modes. + * https://github.com/openssl/openssl/issues/22628 + * + * in_len+block_size is usually sufficient, but AES key wrap with padding + * ciphers require in_len+15 even though they have a block size of 8 bytes. + * + * Using EVP_MAX_BLOCK_LENGTH (32) as a safe upper bound for ciphers + * currently implemented in OpenSSL, but this can change in the future. + */ + if (in_len > LONG_MAX - EVP_MAX_BLOCK_LENGTH) { ossl_raise(rb_eRangeError, "data too big to make output buffer: %ld bytes", in_len); } + out_len = in_len + EVP_MAX_BLOCK_LENGTH; if (NIL_P(str)) { str = rb_str_new(0, out_len); } else { StringValue(str); - rb_str_resize(str, out_len); + if ((long)rb_str_capacity(str) >= out_len) + rb_str_modify(str); + else + rb_str_modify_expand(str, out_len - RSTRING_LEN(str)); } if (!ossl_cipher_update_long(ctx, (unsigned char *)RSTRING_PTR(str), &out_len, in, in_len)) ossl_raise(eCipherError, NULL); - assert(out_len < RSTRING_LEN(str)); + assert(out_len <= RSTRING_LEN(str)); rb_str_set_len(str, out_len); return str; diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_digest.c ruby3.3-3.3.13/ext/openssl/ossl_digest.c --- ruby3.3-3.3.8/ext/openssl/ossl_digest.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_digest.c 2026-10-23 03:17:41.000000000 +0000 @@ -232,6 +232,7 @@ str = rb_str_new(NULL, out_len); } else { StringValue(str); + rb_str_modify(str); rb_str_resize(str, out_len); } diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_ns_spki.c ruby3.3-3.3.13/ext/openssl/ossl_ns_spki.c --- ruby3.3-3.3.8/ext/openssl/ossl_ns_spki.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_ns_spki.c 2026-10-23 03:17:41.000000000 +0000 @@ -230,13 +230,12 @@ NETSCAPE_SPKI *spki; GetSPKI(self, spki); - if (spki->spkac->challenge->length <= 0) { - OSSL_Debug("Challenge.length <= 0?"); - return rb_str_new(0, 0); + if (ASN1_STRING_length(spki->spkac->challenge) <= 0) { + OSSL_Debug("Challenge.length <= 0?"); + return rb_str_new(0, 0); } - return rb_str_new((const char *)spki->spkac->challenge->data, - spki->spkac->challenge->length); + return asn1str_to_str(spki->spkac->challenge); } /* diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_ocsp.c ruby3.3-3.3.13/ext/openssl/ossl_ocsp.c --- ruby3.3-3.3.8/ext/openssl/ossl_ocsp.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_ocsp.c 2026-10-23 03:17:41.000000000 +0000 @@ -900,7 +900,6 @@ OCSP_CERTID *cid; ASN1_TIME *revtime, *thisupd, *nextupd; int status, reason; - X509_EXTENSION *x509ext; VALUE ret, ary, ext; int count, ext_count, i, j; @@ -927,7 +926,7 @@ ext = rb_ary_new(); ext_count = OCSP_SINGLERESP_get_ext_count(single); for(j = 0; j < ext_count; j++){ - x509ext = OCSP_SINGLERESP_get_ext(single, j); + const X509_EXTENSION *x509ext = OCSP_SINGLERESP_get_ext(single, j); rb_ary_push(ext, ossl_x509ext_new(x509ext)); } rb_ary_push(ary, ext); @@ -1358,7 +1357,6 @@ ossl_ocspsres_get_extensions(VALUE self) { OCSP_SINGLERESP *sres; - X509_EXTENSION *ext; int count, i; VALUE ary; @@ -1367,7 +1365,7 @@ count = OCSP_SINGLERESP_get_ext_count(sres); ary = rb_ary_new2(count); for (i = 0; i < count; i++) { - ext = OCSP_SINGLERESP_get_ext(sres, i); + const X509_EXTENSION *ext = OCSP_SINGLERESP_get_ext(sres, i); rb_ary_push(ary, ossl_x509ext_new(ext)); /* will dup */ } @@ -1565,8 +1563,9 @@ GetOCSPCertId(self, id); OCSP_id_get0_info(&name_hash, NULL, NULL, NULL, id); - ret = rb_str_new(NULL, name_hash->length * 2); - ossl_bin2hex(name_hash->data, RSTRING_PTR(ret), name_hash->length); + ret = rb_str_new(NULL, ASN1_STRING_length(name_hash) * 2); + ossl_bin2hex(ASN1_STRING_get0_data(name_hash), RSTRING_PTR(ret), + ASN1_STRING_length(name_hash)); return ret; } @@ -1588,8 +1587,9 @@ GetOCSPCertId(self, id); OCSP_id_get0_info(NULL, NULL, &key_hash, NULL, id); - ret = rb_str_new(NULL, key_hash->length * 2); - ossl_bin2hex(key_hash->data, RSTRING_PTR(ret), key_hash->length); + ret = rb_str_new(NULL, ASN1_STRING_length(key_hash) * 2); + ossl_bin2hex(ASN1_STRING_get0_data(key_hash), RSTRING_PTR(ret), + ASN1_STRING_length(key_hash)); return ret; } diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_pkcs7.c ruby3.3-3.3.13/ext/openssl/ossl_pkcs7.c --- ruby3.3-3.3.8/ext/openssl/ossl_pkcs7.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_pkcs7.c 2026-10-23 03:17:41.000000000 +0000 @@ -165,7 +165,13 @@ out = NULL; pkcs7 = SMIME_read_PKCS7(in, &out); BIO_free(in); - if(!pkcs7) ossl_raise(ePKCS7Error, NULL); + if (!pkcs7) + ossl_raise(ePKCS7Error, "Could not parse the PKCS7"); + if (!pkcs7->d.ptr) { + PKCS7_free(pkcs7); + ossl_raise(ePKCS7Error, "No content in PKCS7"); + } + data = out ? ossl_membio2str(out) : Qnil; SetPKCS7(ret, pkcs7); ossl_pkcs7_set_data(ret, data); @@ -346,6 +352,10 @@ BIO_free(in); if (!p7) ossl_raise(rb_eArgError, "Could not parse the PKCS7"); + if (!p7->d.ptr) { + PKCS7_free(p7); + ossl_raise(rb_eArgError, "No content in PKCS7"); + } RTYPEDDATA_DATA(self) = p7; PKCS7_free(p7_orig); @@ -922,7 +932,7 @@ ossl_pkcs7si_get_signed_time(VALUE self) { PKCS7_SIGNER_INFO *p7si; - ASN1_TYPE *asn1obj; + const ASN1_TYPE *asn1obj; GetPKCS7si(self, p7si); diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_pkey.c ruby3.3-3.3.13/ext/openssl/ossl_pkey.c --- ruby3.3-3.3.8/ext/openssl/ossl_pkey.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_pkey.c 2026-10-23 03:17:41.000000000 +0000 @@ -636,6 +636,30 @@ #endif #ifdef HAVE_EVP_PKEY_NEW_RAW_PRIVATE_KEY + +#ifndef OSSL_USE_PROVIDER +static int +lookup_pkey_type(VALUE type) +{ + const EVP_PKEY_ASN1_METHOD *ameth; + int pkey_id; + + StringValue(type); + /* + * XXX: EVP_PKEY_asn1_find_str() looks up a PEM type string. Should we use + * OBJ_txt2nid() instead (and then somehow check if the NID is an acceptable + * EVP_PKEY type)? + * It is probably fine, though, since it can handle all algorithms that + * support raw keys in 1.1.1: { X25519, X448, ED25519, ED448, HMAC }. + */ + ameth = EVP_PKEY_asn1_find_str(NULL, RSTRING_PTR(type), RSTRING_LENINT(type)); + if (!ameth) + ossl_raise(ePKeyError, "algorithm %"PRIsVALUE" not found", type); + EVP_PKEY_asn1_get0_info(&pkey_id, NULL, NULL, NULL, NULL, ameth); + return pkey_id; +} +#endif + /* * call-seq: * OpenSSL::PKey.new_raw_private_key(algo, string) -> PKey @@ -647,22 +671,23 @@ ossl_pkey_new_raw_private_key(VALUE self, VALUE type, VALUE key) { EVP_PKEY *pkey; - const EVP_PKEY_ASN1_METHOD *ameth; - int pkey_id; size_t keylen; - StringValue(type); StringValue(key); - ameth = EVP_PKEY_asn1_find_str(NULL, RSTRING_PTR(type), RSTRING_LENINT(type)); - if (!ameth) - ossl_raise(ePKeyError, "algorithm %"PRIsVALUE" not found", type); - EVP_PKEY_asn1_get0_info(&pkey_id, NULL, NULL, NULL, NULL, ameth); - keylen = RSTRING_LEN(key); +#ifdef OSSL_USE_PROVIDER + pkey = EVP_PKEY_new_raw_private_key_ex(NULL, StringValueCStr(type), NULL, + (unsigned char *)RSTRING_PTR(key), + keylen); + if (!pkey) + ossl_raise(ePKeyError, "EVP_PKEY_new_raw_private_key_ex"); +#else + int pkey_id = lookup_pkey_type(type); pkey = EVP_PKEY_new_raw_private_key(pkey_id, NULL, (unsigned char *)RSTRING_PTR(key), keylen); if (!pkey) ossl_raise(ePKeyError, "EVP_PKEY_new_raw_private_key"); +#endif return ossl_pkey_new(pkey); } @@ -680,22 +705,23 @@ ossl_pkey_new_raw_public_key(VALUE self, VALUE type, VALUE key) { EVP_PKEY *pkey; - const EVP_PKEY_ASN1_METHOD *ameth; - int pkey_id; size_t keylen; - StringValue(type); StringValue(key); - ameth = EVP_PKEY_asn1_find_str(NULL, RSTRING_PTR(type), RSTRING_LENINT(type)); - if (!ameth) - ossl_raise(ePKeyError, "algorithm %"PRIsVALUE" not found", type); - EVP_PKEY_asn1_get0_info(&pkey_id, NULL, NULL, NULL, NULL, ameth); - keylen = RSTRING_LEN(key); +#ifdef OSSL_USE_PROVIDER + pkey = EVP_PKEY_new_raw_public_key_ex(NULL, StringValueCStr(type), NULL, + (unsigned char *)RSTRING_PTR(key), + keylen); + if (!pkey) + ossl_raise(ePKeyError, "EVP_PKEY_new_raw_public_key_ex"); +#else + int pkey_id = lookup_pkey_type(type); pkey = EVP_PKEY_new_raw_public_key(pkey_id, NULL, (unsigned char *)RSTRING_PTR(key), keylen); if (!pkey) ossl_raise(ePKeyError, "EVP_PKEY_new_raw_public_key"); +#endif return ossl_pkey_new(pkey); } @@ -715,6 +741,10 @@ GetPKey(self, pkey); nid = EVP_PKEY_id(pkey); +#ifdef OSSL_USE_PROVIDER + if (nid == EVP_PKEY_KEYMGMT) + ossl_raise(ePKeyError, "EVP_PKEY_id"); +#endif return rb_str_new_cstr(OBJ_nid2sn(nid)); } @@ -728,13 +758,23 @@ ossl_pkey_inspect(VALUE self) { EVP_PKEY *pkey; - int nid; GetPKey(self, pkey); - nid = EVP_PKEY_id(pkey); - return rb_sprintf("#<%"PRIsVALUE":%p oid=%s>", - rb_class_name(CLASS_OF(self)), (void *)self, - OBJ_nid2sn(nid)); + VALUE str = rb_sprintf("#<%"PRIsVALUE":%p", + rb_obj_class(self), (void *)self); + int nid = EVP_PKEY_id(pkey); +#ifdef OSSL_USE_PROVIDER + if (nid != EVP_PKEY_KEYMGMT) +#endif + rb_str_catf(str, " oid=%s", OBJ_nid2sn(nid)); +#ifdef OSSL_USE_PROVIDER + rb_str_catf(str, " type_name=%s", EVP_PKEY_get0_type_name(pkey)); + const OSSL_PROVIDER *prov = EVP_PKEY_get0_provider(pkey); + if (prov) + rb_str_catf(str, " provider=%s", OSSL_PROVIDER_get0_name(prov)); +#endif + rb_str_catf(str, ">"); + return str; } /* @@ -937,6 +977,7 @@ BIO *bio; GetPKey(self, pkey); + ossl_pkey_check_public_key(pkey); bio = BIO_new(BIO_s_mem()); if (!bio) ossl_raise(ePKeyError, "BIO_new"); diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_pkey_dh.c ruby3.3-3.3.13/ext/openssl/ossl_pkey_dh.c --- ruby3.3-3.3.8/ext/openssl/ossl_pkey_dh.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_pkey_dh.c 2026-10-23 03:17:41.000000000 +0000 @@ -21,6 +21,8 @@ EVP_PKEY *_pkey; \ GetPKeyDH((obj), _pkey); \ (dh) = EVP_PKEY_get0_DH(_pkey); \ + if ((dh) == NULL) \ + ossl_raise(eDHError, "failed to get DH from EVP_PKEY"); \ } while (0) /* diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_pkey_dsa.c ruby3.3-3.3.13/ext/openssl/ossl_pkey_dsa.c --- ruby3.3-3.3.8/ext/openssl/ossl_pkey_dsa.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_pkey_dsa.c 2026-10-23 03:17:41.000000000 +0000 @@ -21,6 +21,8 @@ EVP_PKEY *_pkey; \ GetPKeyDSA((obj), _pkey); \ (dsa) = EVP_PKEY_get0_DSA(_pkey); \ + if ((dsa) == NULL) \ + ossl_raise(eDSAError, "failed to get DSA from EVP_PKEY"); \ } while (0) static inline int diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_pkey_ec.c ruby3.3-3.3.13/ext/openssl/ossl_pkey_ec.c --- ruby3.3-3.3.8/ext/openssl/ossl_pkey_ec.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_pkey_ec.c 2026-10-23 03:17:41.000000000 +0000 @@ -22,6 +22,8 @@ EVP_PKEY *_pkey; \ GetPKeyEC(obj, _pkey); \ (key) = EVP_PKEY_get0_EC_KEY(_pkey); \ + if ((key) == NULL) \ + ossl_raise(eECError, "failed to get EC_KEY from EVP_PKEY"); \ } while (0) #define GetECGroup(obj, group) do { \ diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_pkey_rsa.c ruby3.3-3.3.13/ext/openssl/ossl_pkey_rsa.c --- ruby3.3-3.3.8/ext/openssl/ossl_pkey_rsa.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_pkey_rsa.c 2026-10-23 03:17:41.000000000 +0000 @@ -21,6 +21,8 @@ EVP_PKEY *_pkey; \ GetPKeyRSA((obj), _pkey); \ (rsa) = EVP_PKEY_get0_RSA(_pkey); \ + if ((rsa) == NULL) \ + ossl_raise(eRSAError, "failed to get RSA from EVP_PKEY"); \ } while (0) static inline int diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_provider.c ruby3.3-3.3.13/ext/openssl/ossl_provider.c --- ruby3.3-3.3.8/ext/openssl/ossl_provider.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_provider.c 2026-10-23 03:17:41.000000000 +0000 @@ -5,8 +5,6 @@ #include "ossl.h" #ifdef OSSL_USE_PROVIDER -# include <openssl/provider.h> - #define NewProvider(klass) \ TypedData_Wrap_Struct((klass), &ossl_provider_type, 0) #define SetProvider(obj, provider) do { \ diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_ts.c ruby3.3-3.3.13/ext/openssl/ossl_ts.c --- ruby3.3-3.3.8/ext/openssl/ossl_ts.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_ts.c 2026-10-23 03:17:41.000000000 +0000 @@ -288,7 +288,7 @@ mi = TS_REQ_get_msg_imprint(req); hashed_msg = TS_MSG_IMPRINT_get_msg(mi); - ret = rb_str_new((const char *)hashed_msg->data, hashed_msg->length); + ret = asn1str_to_str(hashed_msg); return ret; } @@ -497,7 +497,7 @@ ossl_raise(eTimestampError, "Message imprint missing algorithm"); hashed_msg = TS_MSG_IMPRINT_get_msg(mi); - if (!hashed_msg->length) + if (!ASN1_STRING_length(hashed_msg)) ossl_raise(eTimestampError, "Message imprint missing hashed message"); return asn1_to_der((void *)req, (int (*)(void *, unsigned char **))i2d_TS_REQ); @@ -730,7 +730,7 @@ TS_RESP *resp; PKCS7 *p7; PKCS7_SIGNER_INFO *ts_info; - X509 *cert; + const X509 *cert; GetTSResponse(self, resp); if (!(p7 = TS_RESP_get_token(resp))) @@ -974,7 +974,7 @@ GetTSTokenInfo(self, info); mi = TS_TST_INFO_get_msg_imprint(info); hashed_msg = TS_MSG_IMPRINT_get_msg(mi); - ret = rb_str_new((const char *)hashed_msg->data, hashed_msg->length); + ret = asn1str_to_str(hashed_msg); return ret; } diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_x509.h ruby3.3-3.3.13/ext/openssl/ossl_x509.h --- ruby3.3-3.3.8/ext/openssl/ossl_x509.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_x509.h 2026-10-23 03:17:41.000000000 +0000 @@ -30,7 +30,7 @@ extern VALUE cX509Attr; extern VALUE eX509AttrError; -VALUE ossl_x509attr_new(X509_ATTRIBUTE *); +VALUE ossl_x509attr_new(const X509_ATTRIBUTE *); X509_ATTRIBUTE *GetX509AttrPtr(VALUE); void Init_ossl_x509attr(void); @@ -40,7 +40,7 @@ extern VALUE cX509Cert; extern VALUE eX509CertError; -VALUE ossl_x509_new(X509 *); +VALUE ossl_x509_new(const X509 *); X509 *GetX509CertPtr(VALUE); X509 *DupX509CertPtr(VALUE); void Init_ossl_x509cert(void); @@ -51,7 +51,7 @@ extern VALUE cX509CRL; extern VALUE eX509CRLError; -VALUE ossl_x509crl_new(X509_CRL *); +VALUE ossl_x509crl_new(const X509_CRL *); X509_CRL *GetX509CRLPtr(VALUE); void Init_ossl_x509crl(void); @@ -62,7 +62,7 @@ extern VALUE cX509ExtFactory; extern VALUE eX509ExtError; -VALUE ossl_x509ext_new(X509_EXTENSION *); +VALUE ossl_x509ext_new(const X509_EXTENSION *); X509_EXTENSION *GetX509ExtPtr(VALUE); void Init_ossl_x509ext(void); @@ -72,7 +72,7 @@ extern VALUE cX509Name; extern VALUE eX509NameError; -VALUE ossl_x509name_new(X509_NAME *); +VALUE ossl_x509name_new(const X509_NAME *); X509_NAME *GetX509NamePtr(VALUE); void Init_ossl_x509name(void); @@ -91,7 +91,7 @@ extern VALUE cX509Rev; extern VALUE eX509RevError; -VALUE ossl_x509revoked_new(X509_REVOKED *); +VALUE ossl_x509revoked_new(const X509_REVOKED *); X509_REVOKED *DupX509RevokedPtr(VALUE); void Init_ossl_x509revoked(void); diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_x509attr.c ruby3.3-3.3.13/ext/openssl/ossl_x509attr.c --- ruby3.3-3.3.8/ext/openssl/ossl_x509attr.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_x509attr.c 2026-10-23 03:17:41.000000000 +0000 @@ -48,7 +48,7 @@ * Public */ VALUE -ossl_x509attr_new(X509_ATTRIBUTE *attr) +ossl_x509attr_new(const X509_ATTRIBUTE *attr) { X509_ATTRIBUTE *new; VALUE obj; @@ -57,7 +57,8 @@ if (!attr) { new = X509_ATTRIBUTE_new(); } else { - new = X509_ATTRIBUTE_dup(attr); + /* OpenSSL 1.1.1 takes a non-const pointer */ + new = X509_ATTRIBUTE_dup((X509_ATTRIBUTE *)attr); } if (!new) { ossl_raise(eX509AttrError, NULL); @@ -174,7 +175,7 @@ ossl_x509attr_get_oid(VALUE self) { X509_ATTRIBUTE *attr; - ASN1_OBJECT *oid; + const ASN1_OBJECT *oid; BIO *out; VALUE ret; int nid; @@ -186,7 +187,7 @@ else{ if (!(out = BIO_new(BIO_s_mem()))) ossl_raise(eX509AttrError, NULL); - i2a_ASN1_OBJECT(out, oid); + i2a_ASN1_OBJECT(out, (ASN1_OBJECT *)oid); ret = ossl_membio2str(out); } @@ -214,7 +215,7 @@ GetX509Attr(self, attr); if (X509_ATTRIBUTE_count(attr)) { /* populated, reset first */ - ASN1_OBJECT *obj = X509_ATTRIBUTE_get0_object(attr); + const ASN1_OBJECT *obj = X509_ATTRIBUTE_get0_object(attr); X509_ATTRIBUTE *new_attr = X509_ATTRIBUTE_create_by_OBJ(NULL, obj, 0, NULL, -1); if (!new_attr) ossl_raise(eX509AttrError, NULL); @@ -256,7 +257,7 @@ count = X509_ATTRIBUTE_count(attr); for (i = 0; i < count; i++) - sk_ASN1_TYPE_push(sk, X509_ATTRIBUTE_get0_type(attr, i)); + sk_ASN1_TYPE_push(sk, (ASN1_TYPE *)X509_ATTRIBUTE_get0_type(attr, i)); if ((len = i2d_ASN1_SET_ANY(sk, NULL)) <= 0) { sk_ASN1_TYPE_free(sk); diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_x509cert.c ruby3.3-3.3.13/ext/openssl/ossl_x509cert.c --- ruby3.3-3.3.8/ext/openssl/ossl_x509cert.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_x509cert.c 2026-10-23 03:17:41.000000000 +0000 @@ -48,7 +48,7 @@ * Public */ VALUE -ossl_x509_new(X509 *x509) +ossl_x509_new(const X509 *x509) { X509 *new; VALUE obj; @@ -57,7 +57,8 @@ if (!x509) { new = X509_new(); } else { - new = X509_dup(x509); + /* OpenSSL 1.1.1 takes a non-const pointer */ + new = X509_dup((X509 *)x509); } if (!new) { ossl_raise(eX509CertError, NULL); @@ -351,7 +352,7 @@ ossl_x509_get_subject(VALUE self) { X509 *x509; - X509_NAME *name; + const X509_NAME *name; GetX509(self, x509); if (!(name = X509_get_subject_name(x509))) { /* NO DUP - don't free! */ @@ -386,7 +387,7 @@ ossl_x509_get_issuer(VALUE self) { X509 *x509; - X509_NAME *name; + const X509_NAME *name; GetX509(self, x509); if(!(name = X509_get_issuer_name(x509))) { /* NO DUP - don't free! */ @@ -608,7 +609,6 @@ { X509 *x509; int count, i; - X509_EXTENSION *ext; VALUE ary; GetX509(self, x509); @@ -618,7 +618,7 @@ } ary = rb_ary_new2(count); for (i=0; i<count; i++) { - ext = X509_get_ext(x509, i); /* NO DUP - don't free! */ + const X509_EXTENSION *ext = X509_get_ext(x509, i); rb_ary_push(ary, ossl_x509ext_new(ext)); } diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_x509crl.c ruby3.3-3.3.13/ext/openssl/ossl_x509crl.c --- ruby3.3-3.3.8/ext/openssl/ossl_x509crl.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_x509crl.c 2026-10-23 03:17:41.000000000 +0000 @@ -58,13 +58,14 @@ } VALUE -ossl_x509crl_new(X509_CRL *crl) +ossl_x509crl_new(const X509_CRL *crl) { X509_CRL *tmp; VALUE obj; obj = NewX509CRL(cX509CRL); - tmp = crl ? X509_CRL_dup(crl) : X509_CRL_new(); + /* OpenSSL 1.1.1 takes a non-const pointer */ + tmp = crl ? X509_CRL_dup((X509_CRL *)crl) : X509_CRL_new(); if(!tmp) ossl_raise(eX509CRLError, NULL); SetX509CRL(obj, tmp); @@ -274,7 +275,7 @@ { X509_CRL *crl; int i, num; - X509_REVOKED *rev; + const X509_REVOKED *rev; VALUE ary, revoked; GetX509CRL(self, crl); @@ -440,7 +441,6 @@ { X509_CRL *crl; int count, i; - X509_EXTENSION *ext; VALUE ary; GetX509CRL(self, crl); @@ -451,7 +451,7 @@ } ary = rb_ary_new2(count); for (i=0; i<count; i++) { - ext = X509_CRL_get_ext(crl, i); /* NO DUP - don't free! */ + const X509_EXTENSION *ext = X509_CRL_get_ext(crl, i); rb_ary_push(ary, ossl_x509ext_new(ext)); } diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_x509ext.c ruby3.3-3.3.13/ext/openssl/ossl_x509ext.c --- ruby3.3-3.3.8/ext/openssl/ossl_x509ext.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_x509ext.c 2026-10-23 03:17:41.000000000 +0000 @@ -62,7 +62,7 @@ * Public */ VALUE -ossl_x509ext_new(X509_EXTENSION *ext) +ossl_x509ext_new(const X509_EXTENSION *ext) { X509_EXTENSION *new; VALUE obj; @@ -71,7 +71,8 @@ if (!ext) { new = X509_EXTENSION_new(); } else { - new = X509_EXTENSION_dup(ext); + /* OpenSSL 1.1.1 takes a non-const pointer */ + new = X509_EXTENSION_dup((X509_EXTENSION *)ext); } if (!new) { ossl_raise(eX509ExtError, NULL); @@ -346,12 +347,20 @@ GetX509Ext(self, ext); data = ossl_to_der_if_possible(data); StringValue(data); - asn1s = X509_EXTENSION_get_data(ext); + asn1s = ASN1_OCTET_STRING_new(); + if (!asn1s) + ossl_raise(eX509ExtError, "ASN1_OCTET_STRING_new"); if (!ASN1_OCTET_STRING_set(asn1s, (unsigned char *)RSTRING_PTR(data), - RSTRING_LENINT(data))) { - ossl_raise(eX509ExtError, "ASN1_OCTET_STRING_set"); + RSTRING_LENINT(data))) { + ASN1_OCTET_STRING_free(asn1s); + ossl_raise(eX509ExtError, "ASN1_OCTET_STRING_set"); } + if (!X509_EXTENSION_set_data(ext, asn1s)) { + ASN1_OCTET_STRING_free(asn1s); + ossl_raise(eX509ExtError, "X509_EXTENSION_set_data"); + } + ASN1_OCTET_STRING_free(asn1s); return data; } @@ -371,7 +380,7 @@ ossl_x509ext_get_oid(VALUE obj) { X509_EXTENSION *ext; - ASN1_OBJECT *extobj; + const ASN1_OBJECT *extobj; BIO *out; VALUE ret; int nid; @@ -383,7 +392,7 @@ else{ if (!(out = BIO_new(BIO_s_mem()))) ossl_raise(eX509ExtError, NULL); - i2a_ASN1_OBJECT(out, extobj); + i2a_ASN1_OBJECT(out, (ASN1_OBJECT *)extobj); ret = ossl_membio2str(out); } @@ -411,13 +420,13 @@ ossl_x509ext_get_value_der(VALUE obj) { X509_EXTENSION *ext; - ASN1_OCTET_STRING *value; + const ASN1_OCTET_STRING *value; GetX509Ext(obj, ext); if ((value = X509_EXTENSION_get_data(ext)) == NULL) ossl_raise(eX509ExtError, NULL); - return rb_str_new((const char *)value->data, value->length); + return asn1str_to_str(value); } static VALUE diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_x509name.c ruby3.3-3.3.13/ext/openssl/ossl_x509name.c --- ruby3.3-3.3.8/ext/openssl/ossl_x509name.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_x509name.c 2026-10-23 03:17:41.000000000 +0000 @@ -53,7 +53,7 @@ * Public */ VALUE -ossl_x509name_new(X509_NAME *name) +ossl_x509name_new(const X509_NAME *name) { X509_NAME *new; VALUE obj; @@ -62,7 +62,8 @@ if (!name) { new = X509_NAME_new(); } else { - new = X509_NAME_dup(name); + /* OpenSSL 1.1.1 takes a non-const pointer */ + new = X509_NAME_dup((X509_NAME *)name); } if (!new) { ossl_raise(eX509NameError, NULL); @@ -360,7 +361,7 @@ } ret = rb_ary_new2(entries); for (i=0; i<entries; i++) { - if (!(entry = X509_NAME_get_entry(name, i))) { + if (!(entry = (X509_NAME_ENTRY *)X509_NAME_get_entry(name, i))) { ossl_raise(eX509NameError, NULL); } if (!i2t_ASN1_OBJECT(long_name, sizeof(long_name), @@ -374,8 +375,9 @@ short_name = OBJ_nid2sn(nid); vname = rb_str_new2(short_name); /*do not free*/ } - value = X509_NAME_ENTRY_get_data(entry); - ary = rb_ary_new3(3, vname, asn1str_to_str(value), INT2NUM(value->type)); + value = (ASN1_STRING *)X509_NAME_ENTRY_get_data(entry); + ary = rb_ary_new3(3, vname, asn1str_to_str(value), + INT2NUM(ASN1_STRING_type(value))); rb_ary_push(ret, ary); } return ret; diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_x509req.c ruby3.3-3.3.13/ext/openssl/ossl_x509req.c --- ruby3.3-3.3.8/ext/openssl/ossl_x509req.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_x509req.c 2026-10-23 03:17:41.000000000 +0000 @@ -230,7 +230,7 @@ ossl_x509req_get_subject(VALUE self) { X509_REQ *req; - X509_NAME *name; + const X509_NAME *name; GetX509Req(self, req); if (!(name = X509_REQ_get_subject_name(req))) { /* NO DUP - don't free */ @@ -348,7 +348,7 @@ { X509_REQ *req; int count, i; - X509_ATTRIBUTE *attr; + const X509_ATTRIBUTE *attr; VALUE ary; GetX509Req(self, req); diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_x509revoked.c ruby3.3-3.3.13/ext/openssl/ossl_x509revoked.c --- ruby3.3-3.3.8/ext/openssl/ossl_x509revoked.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_x509revoked.c 2026-10-23 03:17:41.000000000 +0000 @@ -48,7 +48,7 @@ * PUBLIC */ VALUE -ossl_x509revoked_new(X509_REVOKED *rev) +ossl_x509revoked_new(const X509_REVOKED *rev) { X509_REVOKED *new; VALUE obj; @@ -57,7 +57,8 @@ if (!rev) { new = X509_REVOKED_new(); } else { - new = X509_REVOKED_dup(rev); + /* OpenSSL 1.1.1 takes a non-const pointer */ + new = X509_REVOKED_dup((X509_REVOKED *)rev); } if (!new) { ossl_raise(eX509RevError, NULL); @@ -189,7 +190,7 @@ { X509_REVOKED *rev; int count, i; - X509_EXTENSION *ext; + const X509_EXTENSION *ext; VALUE ary; GetX509Rev(self, rev); diff -Nru ruby3.3-3.3.8/ext/openssl/ossl_x509store.c ruby3.3-3.3.13/ext/openssl/ossl_x509store.c --- ruby3.3-3.3.8/ext/openssl/ossl_x509store.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/openssl/ossl_x509store.c 2026-10-23 03:17:41.000000000 +0000 @@ -521,10 +521,8 @@ ossl_x509stctx_free(void *ptr) { X509_STORE_CTX *ctx = ptr; - if (X509_STORE_CTX_get0_untrusted(ctx)) - sk_X509_pop_free(X509_STORE_CTX_get0_untrusted(ctx), X509_free); - if (X509_STORE_CTX_get0_cert(ctx)) - X509_free(X509_STORE_CTX_get0_cert(ctx)); + sk_X509_pop_free(X509_STORE_CTX_get0_untrusted(ctx), X509_free); + X509_free((X509 *)X509_STORE_CTX_get0_cert(ctx)); X509_STORE_CTX_free(ctx); } @@ -765,7 +763,7 @@ ossl_x509stctx_get_curr_crl(VALUE self) { X509_STORE_CTX *ctx; - X509_CRL *crl; + const X509_CRL *crl; GetX509StCtx(self, ctx); crl = X509_STORE_CTX_get0_current_crl(ctx); diff -Nru ruby3.3-3.3.8/ext/socket/rubysocket.h ruby3.3-3.3.13/ext/socket/rubysocket.h --- ruby3.3-3.3.8/ext/socket/rubysocket.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/socket/rubysocket.h 2026-10-23 03:17:41.000000000 +0000 @@ -290,8 +290,8 @@ #ifdef SOCKS extern VALUE rb_cSOCKSSocket; # ifndef SOCKS5 -void SOCKSinit(); -int Rconnect(); +void SOCKSinit(char *); +int Rconnect(int, const struct sockaddr *, socklen_t); # endif #endif diff -Nru ruby3.3-3.3.8/ext/socket/unixsocket.c ruby3.3-3.3.13/ext/socket/unixsocket.c --- ruby3.3-3.3.8/ext/socket/unixsocket.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/socket/unixsocket.c 2026-10-23 03:17:41.000000000 +0000 @@ -43,11 +43,12 @@ } } #endif + path = rb_get_path(path); #ifdef _WIN32 /* UNIXSocket requires UTF-8 per spec. */ path = rb_str_export_to_enc(path, rb_utf8_encoding()); #endif - return rb_get_path(path); + return path; } VALUE diff -Nru ruby3.3-3.3.8/ext/strscan/extconf.rb ruby3.3-3.3.13/ext/strscan/extconf.rb --- ruby3.3-3.3.8/ext/strscan/extconf.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/strscan/extconf.rb 2026-10-23 03:17:41.000000000 +0000 @@ -2,8 +2,8 @@ require 'mkmf' if RUBY_ENGINE == 'ruby' $INCFLAGS << " -I$(top_srcdir)" if $extmk - have_func("onig_region_memsize", "ruby.h") - have_func("rb_reg_onig_match", "ruby.h") + have_func("onig_region_memsize(NULL)") + have_func("rb_reg_onig_match", "ruby/re.h") create_makefile 'strscan' else File.write('Makefile', dummy_makefile("").join) diff -Nru ruby3.3-3.3.8/ext/zlib/zlib.c ruby3.3-3.3.13/ext/zlib/zlib.c --- ruby3.3-3.3.8/ext/zlib/zlib.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/zlib/zlib.c 2026-10-23 03:17:41.000000000 +0000 @@ -25,7 +25,7 @@ # define VALGRIND_MAKE_MEM_UNDEFINED(p, n) 0 #endif -#define RUBY_ZLIB_VERSION "3.1.1" +#define RUBY_ZLIB_VERSION "3.1.2" #ifndef RB_PASS_CALLED_KEYWORDS # define rb_class_new_instance_kw(argc, argv, klass, kw_splat) rb_class_new_instance(argc, argv, klass) @@ -851,9 +851,7 @@ char *bufptr; long filled; - if (NIL_P(z->buf) || (long)rb_str_capacity(z->buf) <= ZSTREAM_BUF_FILLED(z)) { - zstream_expand_buffer_into(z, len); - } + zstream_expand_buffer_into(z, len); RSTRING_GETMEM(z->buf, bufptr, filled); memmove(bufptr + len, bufptr, filled); diff -Nru ruby3.3-3.3.8/ext/zlib/zlib.gemspec ruby3.3-3.3.13/ext/zlib/zlib.gemspec --- ruby3.3-3.3.8/ext/zlib/zlib.gemspec 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ext/zlib/zlib.gemspec 2026-10-23 03:17:41.000000000 +0000 @@ -22,7 +22,7 @@ spec.homepage = "https://github.com/ruby/zlib" spec.licenses = ["Ruby", "BSD-2-Clause"] - spec.files = ["LICENSE.txt", "README.md", "ext/zlib/extconf.rb", "ext/zlib/zlib.c", "zlib.gemspec"] + spec.files = ["COPYING", "BSDL", "README.md", "ext/zlib/extconf.rb", "ext/zlib/zlib.c", "zlib.gemspec"] spec.bindir = "exe" spec.executables = [] spec.require_paths = ["lib"] diff -Nru ruby3.3-3.3.8/file.c ruby3.3-3.3.13/file.c --- ruby3.3-3.3.8/file.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/file.c 2026-10-23 03:17:41.000000000 +0000 @@ -4837,8 +4837,11 @@ break; } } - if (p == name) - return rb_usascii_str_new2("."); + if (p == name) { + dirname = rb_str_new(".", 1); + rb_enc_copy(dirname, fname); + return dirname; + } #ifdef DOSISH_DRIVE_LETTER if (has_drive_letter(name) && isdirsep(*(name + 2))) { const char *top = skiproot(name + 2, end, enc); diff -Nru ruby3.3-3.3.8/gems/bundled_gems ruby3.3-3.3.13/gems/bundled_gems --- ruby3.3-3.3.8/gems/bundled_gems 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/gems/bundled_gems 2026-10-23 03:17:41.000000000 +0000 @@ -9,10 +9,10 @@ power_assert 2.0.3 https://github.com/ruby/power_assert rake 13.1.0 https://github.com/ruby/rake test-unit 3.6.1 https://github.com/test-unit/test-unit -rexml 3.3.9 https://github.com/ruby/rexml +rexml 3.4.4 https://github.com/ruby/rexml rss 0.3.1 https://github.com/ruby/rss net-ftp 0.3.4 https://github.com/ruby/net-ftp -net-imap 0.4.19 https://github.com/ruby/net-imap +net-imap 0.4.25 https://github.com/ruby/net-imap net-pop 0.1.2 https://github.com/ruby/net-pop net-smtp 0.5.1 https://github.com/ruby/net-smtp matrix 0.4.2 https://github.com/ruby/matrix diff -Nru ruby3.3-3.3.8/golf_prelude.c ruby3.3-3.3.13/golf_prelude.c --- ruby3.3-3.3.8/golf_prelude.c 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/golf_prelude.c 2026-10-23 03:17:43.000000000 +0000 @@ -7,6 +7,7 @@ #include "internal/ruby_parser.h" #include "internal/warnings.h" #include "iseq.h" +#include "ruby/internal/attr/nonstring.h" #include "ruby/ruby.h" #include "vm_core.h" @@ -17,12 +18,12 @@ static const char prelude_name0[] = "<internal:golf_prelude>"; static const struct { - char L0[462]; /* 1..18 */ - char L18[485]; /* 19..34 */ - char L34[505]; /* 35..59 */ - char L59[487]; /* 60..96 */ - char L96[493]; /* 97..116 */ - char L116[222]; /* 117..131 */ + RBIMPL_ATTR_NONSTRING() char L0[462]; /* 1..18 */ + RBIMPL_ATTR_NONSTRING() char L18[485]; /* 19..34 */ + RBIMPL_ATTR_NONSTRING() char L34[505]; /* 35..59 */ + RBIMPL_ATTR_NONSTRING() char L59[487]; /* 60..96 */ + RBIMPL_ATTR_NONSTRING() char L96[493]; /* 97..116 */ + RBIMPL_ATTR_NONSTRING() char L116[222]; /* 117..131 */ } prelude_code0 = { #line 1 "golf_prelude.rb" "class Object\n" @@ -165,7 +166,7 @@ " end\n" " end\n" "end\n" -#line 169 "golf_prelude.c" +#line 170 "golf_prelude.c" }; COMPILER_WARNING_POP diff -Nru ruby3.3-3.3.8/hash.c ruby3.3-3.3.13/hash.c --- ruby3.3-3.3.8/hash.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/hash.c 2026-10-23 03:17:41.000000000 +0000 @@ -860,7 +860,7 @@ if (replace) { VALUE key = pair->key; VALUE val = pair->val; - retval = (*replace)(&key, &val, arg, TRUE); + (*replace)(&key, &val, arg, TRUE); // TODO: pair should be same as pair before. ar_table_pair *pair = RHASH_AR_TABLE_REF(hash, i); @@ -931,7 +931,7 @@ if (pair->key == never) break; ret = ar_find_entry_hint(hash, hint, key); if (ret == RHASH_AR_TABLE_MAX_BOUND) { - retval = (*func)(0, 0, arg, 1); + (*func)(0, 0, arg, 1); return 2; } } @@ -1391,6 +1391,7 @@ return 0; } +/* This does not manage iteration level */ int rb_hash_stlike_foreach(VALUE hash, st_foreach_callback_func *func, st_data_t arg) { @@ -1402,6 +1403,7 @@ } } +/* This does not manage iteration level */ int rb_hash_stlike_foreach_with_replace(VALUE hash, st_foreach_check_callback_func *func, st_update_callback_func *replace, st_data_t arg) { @@ -1708,14 +1710,14 @@ .func = func, .hash = hash, .key = key, - .value = (VALUE)optional_arg, + .value = 0 }; int ret = rb_hash_stlike_update(hash, key, tbl_update_modify, (st_data_t)&arg); /* write barrier */ RB_OBJ_WRITTEN(hash, Qundef, arg.key); - RB_OBJ_WRITTEN(hash, Qundef, arg.value); + if (arg.value) RB_OBJ_WRITTEN(hash, Qundef, arg.value); return ret; } @@ -3326,6 +3328,20 @@ return ST_CONTINUE; } +static VALUE +transform_values_call(VALUE hash) +{ + rb_hash_stlike_foreach_with_replace(hash, transform_values_foreach_func, transform_values_foreach_replace, hash); + return hash; +} + +static void +transform_values(VALUE hash) +{ + hash_iter_lev_inc(hash); + rb_ensure(transform_values_call, hash, hash_foreach_ensure, hash); +} + /* * call-seq: * hash.transform_values {|value| ... } -> new_hash @@ -3356,7 +3372,7 @@ SET_DEFAULT(result, Qnil); if (!RHASH_EMPTY_P(hash)) { - rb_hash_stlike_foreach_with_replace(result, transform_values_foreach_func, transform_values_foreach_replace, result); + transform_values(result); compact_after_delete(result); } @@ -3385,7 +3401,7 @@ rb_hash_modify_check(hash); if (!RHASH_TABLE_EMPTY_P(hash)) { - rb_hash_stlike_foreach_with_replace(hash, transform_values_foreach_func, transform_values_foreach_replace, hash); + transform_values(hash); } return hash; @@ -3896,30 +3912,70 @@ return ST_CONTINUE; } +struct update_call_args { + VALUE hash, newvalue, *argv; + int argc; + bool block_given; + bool iterating; +}; + static int rb_hash_update_block_callback(st_data_t *key, st_data_t *value, struct update_arg *arg, int existing) { - st_data_t newvalue = arg->arg; + VALUE k = (VALUE)*key, v = (VALUE)*value; + struct update_call_args *ua = (void *)arg->arg; + VALUE newvalue = ua->newvalue, hash = arg->hash; if (existing) { - newvalue = (st_data_t)rb_yield_values(3, (VALUE)*key, (VALUE)*value, (VALUE)newvalue); + hash_iter_lev_inc(hash); + ua->iterating = true; + newvalue = rb_yield_values(3, k, v, newvalue); + hash_iter_lev_dec(hash); + ua->iterating = false; } - else if (RHASH_STRING_KEY_P(arg->hash, *key) && !RB_OBJ_FROZEN(*key)) { - *key = rb_hash_key_str(*key); + else if (RHASH_STRING_KEY_P(hash, k) && !RB_OBJ_FROZEN(k)) { + *key = (st_data_t)rb_hash_key_str(k); } - *value = newvalue; + *value = (st_data_t)newvalue; return ST_CONTINUE; } NOINSERT_UPDATE_CALLBACK(rb_hash_update_block_callback) static int -rb_hash_update_block_i(VALUE key, VALUE value, VALUE hash) +rb_hash_update_block_i(VALUE key, VALUE value, VALUE args) { - RHASH_UPDATE(hash, key, rb_hash_update_block_callback, value); + struct update_call_args *ua = (void *)args; + ua->newvalue = value; + RHASH_UPDATE(ua->hash, key, rb_hash_update_block_callback, args); return ST_CONTINUE; } +static VALUE +rb_hash_update_call(VALUE args) +{ + struct update_call_args *arg = (void *)args; + + for (int i = 0; i < arg->argc; i++){ + VALUE hash = to_hash(arg->argv[i]); + if (arg->block_given) { + rb_hash_foreach(hash, rb_hash_update_block_i, args); + } + else { + rb_hash_foreach(hash, rb_hash_update_i, arg->hash); + } + } + return arg->hash; +} + +static VALUE +rb_hash_update_ensure(VALUE args) +{ + struct update_call_args *ua = (void *)args; + if (ua->iterating) hash_iter_lev_dec(ua->hash); + return Qnil; +} + /* * call-seq: * hash.merge! -> self @@ -3971,20 +4027,17 @@ static VALUE rb_hash_update(int argc, VALUE *argv, VALUE self) { - int i; - bool block_given = rb_block_given_p(); + struct update_call_args args = { + .hash = self, + .argv = argv, + .argc = argc, + .block_given = rb_block_given_p(), + .iterating = false, + }; + VALUE arg = (VALUE)&args; rb_hash_modify(self); - for (i = 0; i < argc; i++){ - VALUE hash = to_hash(argv[i]); - if (block_given) { - rb_hash_foreach(hash, rb_hash_update_block_i, self); - } - else { - rb_hash_foreach(hash, rb_hash_update_i, self); - } - } - return self; + return rb_ensure(rb_hash_update_call, arg, rb_hash_update_ensure, arg); } struct update_func_arg { @@ -6199,7 +6252,7 @@ while (*env) { const char *p = *env; - char *s = strchr(p, '='); + const char *s = strchr(p, '='); if (s++) { long len = strlen(s); if (RSTRING_LEN(obj) == len && strncmp(s, RSTRING_PTR(obj), len) == 0) { @@ -6422,7 +6475,7 @@ char **env = GET_ENVIRON(environ); if (*env) { const char *p = *env; - char *s = strchr(p, '='); + const char *s = strchr(p, '='); if (s) { key = env_str_new(p, s-p); VALUE val = env_str_new2(getenv(RSTRING_PTR(key))); diff -Nru ruby3.3-3.3.8/id.c ruby3.3-3.3.13/id.c --- ruby3.3-3.3.8/id.c 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/id.c 2026-10-23 03:17:43.000000000 +0000 @@ -34,7 +34,8 @@ static const struct { unsigned short token; - const char name[3], term; + RBIMPL_ATTR_NONSTRING() const char name[3]; + const char term; } op_tbl[] = { {tDOT2, ".."}, {tDOT3, "..."}, diff -Nru ruby3.3-3.3.8/include/ruby/internal/anyargs.h ruby3.3-3.3.13/include/ruby/internal/anyargs.h --- ruby3.3-3.3.8/include/ruby/internal/anyargs.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/include/ruby/internal/anyargs.h 2026-10-23 03:17:41.000000000 +0000 @@ -84,12 +84,15 @@ #elif defined(_WIN32) || defined(__CYGWIN__) # /* Skip due to [Bug #16134] */ +# define RBIMPL_CAST_FN_PTR 1 #elif ! RBIMPL_HAS_ATTRIBUTE(transparent_union) # /* :TODO: improve here, please find a way to support. */ +# define RBIMPL_CAST_FN_PTR 1 #elif ! defined(HAVE_VA_ARGS_MACRO) # /* :TODO: improve here, please find a way to support. */ +# define RBIMPL_CAST_FN_PTR 1 #else # /** @cond INTERNAL_MACRO */ @@ -348,6 +351,25 @@ #endif /* __cplusplus */ +#if defined(RBIMPL_CAST_FN_PTR) && !defined(__cplusplus) +/* In C23, K&R style prototypes are gone and so `void foo(ANYARGS)` became + * equivalent to `void foo(void)` unlike in earlier versions. This is a problem + * for rb_define_* functions since that makes all valid functions one can pass + * trip -Wincompatible-pointer-types, which we treat as errors. This is mostly + * not a problem for the __builtin_choose_expr path, but outside of that we + * need to add a cast for compatibility. + */ +#define rb_define_method(klass, mid, func, arity) rb_define_method((klass), (mid), (VALUE (*)(ANYARGS))(func), (arity)) +#define rb_define_method_id(klass, mid, func, arity) rb_define_method_id((klass), (mid), (VALUE (*)(ANYARGS))(func), (arity)) +#define rb_define_singleton_method(obj, mid, func, arity) rb_define_singleton_method((obj), (mid), (VALUE (*)(ANYARGS))(func), (arity)) +#define rb_define_protected_method(klass, mid, func, arity) rb_define_protected_method((klass), (mid), (VALUE (*)(ANYARGS))(func), (arity)) +#define rb_define_private_method(klass, mid, func, arity) rb_define_private_method((klass), (mid), (VALUE (*)(ANYARGS))(func), (arity)) +#define rb_define_module_function(mod, mid, func, arity) rb_define_module_function((mod), (mid), (VALUE (*)(ANYARGS))(func), (arity)) +#define rb_define_global_function(mid, func, arity) rb_define_global_function((mid), (VALUE (*)(ANYARGS))(func), (arity)) + +#undef RBIMPL_CAST_FN_PTR +#endif /* defined(RBIMPL_CAST_FN_PTR) && !defined(__cplusplus) */ + /** * This macro is to properly cast a function parameter of *_define_method * family. It has been around since 1.x era so you can maximise backwards diff -Nru ruby3.3-3.3.8/include/ruby/internal/attr/nonstring.h ruby3.3-3.3.13/include/ruby/internal/attr/nonstring.h --- ruby3.3-3.3.8/include/ruby/internal/attr/nonstring.h 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/include/ruby/internal/attr/nonstring.h 2026-10-23 03:17:41.000000000 +0000 @@ -0,0 +1,40 @@ +#ifndef RBIMPL_ATTR_NONSTRING_H /*-*-C++-*-vi:se ft=cpp:*/ +#define RBIMPL_ATTR_NONSTRING_H +/** + * @file + * @author Ruby developers <ruby-core@ruby-lang.org> + * @copyright This file is a part of the programming language Ruby. + * Permission is hereby granted, to either redistribute and/or + * modify this file, provided that the conditions mentioned in the + * file COPYING are met. Consult the file for details. + * @warning Symbols prefixed with either `RBIMPL` or `rbimpl` are + * implementation details. Don't take them as canon. They could + * rapidly appear then vanish. The name (path) of this header file + * is also an implementation detail. Do not expect it to persist + * at the place it is now. Developers are free to move it anywhere + * anytime at will. + * @note To ruby-core: remember that this header can be possibly + * recursively included from extension libraries written in C++. + * Do not expect for instance `__VA_ARGS__` is always available. + * We assume C99 for ruby itself but we don't assume languages of + * extension libraries. They could be written in C++98. + * @brief Defines #RBIMPL_ATTR_NONSTRING. + */ +#include "ruby/internal/has/attribute.h" + +/** Wraps (or simulates) `__attribute__((nonstring))` */ +#if RBIMPL_HAS_ATTRIBUTE(nonstring) +# define RBIMPL_ATTR_NONSTRING() __attribute__((nonstring)) +# if RBIMPL_COMPILER_SINCE(GCC, 15, 0, 0) +# define RBIMPL_ATTR_NONSTRING_ARRAY() RBIMPL_ATTR_NONSTRING() +# elif RBIMPL_COMPILER_SINCE(Clang, 21, 0, 0) +# define RBIMPL_ATTR_NONSTRING_ARRAY() RBIMPL_ATTR_NONSTRING() +# else +# define RBIMPL_ATTR_NONSTRING_ARRAY() /* void */ +# endif +#else +# define RBIMPL_ATTR_NONSTRING() /* void */ +# define RBIMPL_ATTR_NONSTRING_ARRAY() /* void */ +#endif + +#endif /* RBIMPL_ATTR_NONSTRING_H */ diff -Nru ruby3.3-3.3.8/include/ruby/internal/core/rbasic.h ruby3.3-3.3.13/include/ruby/internal/core/rbasic.h --- ruby3.3-3.3.8/include/ruby/internal/core/rbasic.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/include/ruby/internal/core/rbasic.h 2026-10-23 03:17:41.000000000 +0000 @@ -104,6 +104,9 @@ klass(RBIMPL_VALUE_NULL) { } +# define RBASIC_INIT RBasic() +#else +# define RBASIC_INIT {RBIMPL_VALUE_NULL} #endif }; diff -Nru ruby3.3-3.3.8/include/ruby/internal/core/rstring.h ruby3.3-3.3.13/include/ruby/internal/core/rstring.h --- ruby3.3-3.3.8/include/ruby/internal/core/rstring.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/include/ruby/internal/core/rstring.h 2026-10-23 03:17:41.000000000 +0000 @@ -369,41 +369,6 @@ return RSTRING(str)->len; } -RBIMPL_WARNING_PUSH() -#if RBIMPL_COMPILER_IS(Intel) -RBIMPL_WARNING_IGNORED(413) -#endif - -RBIMPL_ATTR_PURE_UNLESS_DEBUG() -RBIMPL_ATTR_ARTIFICIAL() -/** - * @private - * - * "Expands" an embedded string into an ordinal one. This is a function that - * returns aggregated type. The returned struct always has its `as.heap.len` - * an `as.heap.ptr` fields set appropriately. - * - * This is an implementation detail that 3rd parties should never bother. - */ -static inline struct RString -rbimpl_rstring_getmem(VALUE str) -{ - RBIMPL_ASSERT_TYPE(str, RUBY_T_STRING); - - if (RB_FL_ANY_RAW(str, RSTRING_NOEMBED)) { - return *RSTRING(str); - } - else { - /* Expecting compilers to optimize this on-stack struct away. */ - struct RString retval; - retval.len = RSTRING_LEN(str); - retval.as.heap.ptr = RSTRING(str)->as.embed.ary; - return retval; - } -} - -RBIMPL_WARNING_POP() - RBIMPL_ATTR_ARTIFICIAL() /** * Queries the contents pointer of the string. @@ -415,7 +380,9 @@ static inline char * RSTRING_PTR(VALUE str) { - char *ptr = rbimpl_rstring_getmem(str).as.heap.ptr; + char *ptr = RB_FL_TEST_RAW(str, RSTRING_NOEMBED) ? + RSTRING(str)->as.heap.ptr : + RSTRING(str)->as.embed.ary; if (RUBY_DEBUG && RB_UNLIKELY(! ptr)) { /* :BEWARE: @shyouhei thinks that currently, there are rooms for this @@ -441,14 +408,17 @@ static inline char * RSTRING_END(VALUE str) { - struct RString buf = rbimpl_rstring_getmem(str); + char *ptr = RB_FL_TEST_RAW(str, RSTRING_NOEMBED) ? + RSTRING(str)->as.heap.ptr : + RSTRING(str)->as.embed.ary; + long len = RSTRING_LEN(str); - if (RUBY_DEBUG && RB_UNLIKELY(! buf.as.heap.ptr)) { + if (RUBY_DEBUG && RB_UNLIKELY(!ptr)) { /* Ditto. */ rb_debug_rstring_null_ptr("RSTRING_END"); } - return &buf.as.heap.ptr[buf.len]; + return &ptr[len]; } RBIMPL_ATTR_ARTIFICIAL() @@ -477,16 +447,7 @@ * @param ptrvar Variable where its contents is stored. * @param lenvar Variable where its length is stored. */ -#ifdef HAVE_STMT_AND_DECL_IN_EXPR -# define RSTRING_GETMEM(str, ptrvar, lenvar) \ - __extension__ ({ \ - struct RString rbimpl_str = rbimpl_rstring_getmem(str); \ - (ptrvar) = rbimpl_str.as.heap.ptr; \ - (lenvar) = rbimpl_str.len; \ - }) -#else # define RSTRING_GETMEM(str, ptrvar, lenvar) \ ((ptrvar) = RSTRING_PTR(str), \ (lenvar) = RSTRING_LEN(str)) -#endif /* HAVE_STMT_AND_DECL_IN_EXPR */ #endif /* RBIMPL_RSTRING_H */ diff -Nru ruby3.3-3.3.8/include/ruby/internal/stdbool.h ruby3.3-3.3.13/include/ruby/internal/stdbool.h --- ruby3.3-3.3.8/include/ruby/internal/stdbool.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/include/ruby/internal/stdbool.h 2026-10-23 03:17:41.000000000 +0000 @@ -35,17 +35,9 @@ # define __bool_true_false_are_defined # endif -#elif defined(HAVE_STDBOOL_H) -# /* Take stdbool.h definition. */ +#else +# /* Take stdbool.h definition. It exists since GCC 3.0 and VS 2015. */ # include <stdbool.h> - -#elif !defined(HAVE__BOOL) -typedef unsigned char _Bool; -# /* See also http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2229.htm */ -# define bool _Bool -# define true ((_Bool)+1) -# define false ((_Bool)+0) -# define __bool_true_false_are_defined #endif #endif /* RBIMPL_STDBOOL_H */ diff -Nru ruby3.3-3.3.8/include/ruby/onigmo.h ruby3.3-3.3.13/include/ruby/onigmo.h --- ruby3.3-3.3.8/include/ruby/onigmo.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/include/ruby/onigmo.h 2026-10-23 03:17:41.000000000 +0000 @@ -687,6 +687,9 @@ #define ONIGERR_NEVER_ENDING_RECURSION -221 #define ONIGERR_GROUP_NUMBER_OVER_FOR_CAPTURE_HISTORY -222 #define ONIGERR_INVALID_CHAR_PROPERTY_NAME -223 +#define ONIGERR_TOO_MANY_RANGE_REPEAT -224 +#define ONIGERR_TOO_MANY_NULL_CHECK -225 +#define ONIGERR_TOO_BIG_COMPILED_PROGRAM -226 #define ONIGERR_INVALID_CODE_POINT_VALUE -400 #define ONIGERR_INVALID_WIDE_CHAR_VALUE -400 #define ONIGERR_TOO_BIG_WIDE_CHAR_VALUE -401 diff -Nru ruby3.3-3.3.8/include/ruby/win32.h ruby3.3-3.3.13/include/ruby/win32.h --- ruby3.3-3.3.8/include/ruby/win32.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/include/ruby/win32.h 2026-10-23 03:17:41.000000000 +0000 @@ -125,8 +125,15 @@ #define O_SHARE_DELETE 0x20000000 /* for rb_w32_open(), rb_w32_wopen() */ typedef int clockid_t; +#if defined(__MINGW32__) +#undef CLOCK_PROCESS_CPUTIME_ID +#undef CLOCK_THREAD_CPUTIME_ID +#undef CLOCK_REALTIME_COARSE +#endif +#if defined(HAVE_CLOCK_GETTIME) && !defined(CLOCK_REALTIME) #define CLOCK_REALTIME 0 #define CLOCK_MONOTONIC 1 +#endif #undef utime #undef lseek diff -Nru ruby3.3-3.3.8/io.c ruby3.3-3.3.13/io.c --- ruby3.3-3.3.8/io.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/io.c 2026-10-23 03:17:41.000000000 +0000 @@ -106,6 +106,10 @@ # include <copyfile.h> #endif +#if defined __APPLE__ +# include <AvailabilityMacros.h> +#endif + #include "ruby/internal/stdbool.h" #include "ccan/list/list.h" #include "dln.h" @@ -221,6 +225,39 @@ int8_t init_p, next_p, binmode; }; + +#if defined(__APPLE__) && \ + (!defined(MAC_OS_VERSION_27_0) || (MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_VERSION_27_0)) + +# if __has_attribute(availability) && __has_warning("-Wunguarded-availability-new") + +RBIMPL_WARNING_PUSH() +RBIMPL_WARNING_IGNORED(-Wunguarded-availability-new) + +# ifdef HAVE_DUP3 +static inline int (*rb_dup3(void))(int, int, int) {return &dup3;} +# define dup3 rb_dup3() +# endif + +# ifdef HAVE_PIPE2 +static inline int (*rb_pipe2(void))(int [2], int) {return &pipe2;} +# define pipe2 rb_pipe2() +# endif + +RBIMPL_WARNING_POP() + +# else /* __API_AVAILABLE macro does nothing on gcc */ + +# ifdef HAVE_DUP3 +__attribute__((weak)) int dup3(int, int, int); +# endif +# ifdef HAVE_PIPE2 +__attribute__((weak)) int pipe2(int [2], int); +# endif + +# endif +#endif /* __APPLE__ && < MAC_OS_X_VERSION_27_0 */ + static rb_atomic_t max_file_descriptor = NOFILE; void rb_update_max_fd(int fd) @@ -360,23 +397,28 @@ } else { #if defined(HAVE_DUP3) && defined(O_CLOEXEC) - static int try_dup3 = 1; - if (2 < newfd && try_dup3) { +# if defined(__APPLE__) +# define try_dup3 (dup3 != NULL) +# define abandon_dup3() true +# else + static bool try_dup3 = true; +# define abandon_dup3() (errno != ENOSYS || !!(try_dup3 = false)) +# endif + if (newfd <= 2) { + /* pass stdin, stdout and stderr to children */ + } + else if (try_dup3) { ret = dup3(oldfd, newfd, O_CLOEXEC); + /* dup3 is available since: + * - Linux 2.6.27, glibc 2.9 + * - macOS 27.0 + */ if (ret != -1) return ret; - /* dup3 is available since Linux 2.6.27, glibc 2.9. */ - if (errno == ENOSYS) { - try_dup3 = 0; - ret = dup2(oldfd, newfd); - } + if (abandon_dup3()) return ret; } - else { - ret = dup2(oldfd, newfd); - } -#else - ret = dup2(oldfd, newfd); #endif + ret = dup2(oldfd, newfd); if (ret < 0) return ret; } rb_maygvl_fd_fix_cloexec(ret); @@ -401,16 +443,25 @@ return 0; } -int -rb_cloexec_pipe(int descriptors[2]) +static inline int +cloexec_pipe(int descriptors[2], int flags, bool force_cloexec) { + int result = -1; #ifdef HAVE_PIPE2 - int result = pipe2(descriptors, O_CLOEXEC | O_NONBLOCK); -#else - int result = pipe(descriptors); +# if defined(__APPLE__) +# define try_pipe2 (pipe2 != NULL) +# define abandon_pipe2() true +# else + static bool try_pipe2 = true; +# define abandon_pipe2() (errno != ENOSYS || !!(try_pipe2 = false)) +# endif + if (try_pipe2) { + result = pipe2(descriptors, O_CLOEXEC | flags); + if (result == 0) return result; + if (abandon_pipe2()) return result; + } #endif - - if (result < 0) + if (result < 0 && (result = pipe(descriptors)) < 0) return result; #ifdef __CYGWIN__ @@ -422,7 +473,9 @@ } #endif -#ifndef HAVE_PIPE2 + if (!force_cloexec) return result; + + /* no pipe2 or fallenback to dup */ rb_maygvl_fd_fix_cloexec(descriptors[0]); rb_maygvl_fd_fix_cloexec(descriptors[1]); @@ -430,12 +483,17 @@ rb_fd_set_nonblock(descriptors[0]); rb_fd_set_nonblock(descriptors[1]); #endif -#endif return result; } int +rb_cloexec_pipe(int descriptors[2]) +{ + return cloexec_pipe(descriptors, O_NONBLOCK, true); +} + +int rb_cloexec_fcntl_dupfd(int fd, int minfd) { int ret; @@ -8051,9 +8109,8 @@ int write_pair[2]; # endif - int result = rb_cloexec_pipe(write_pair); *pid = -1; - if (result == 0) { + if (cloexec_pipe(write_pair, 0, false) == 0) { # ifdef HAVE_WORKING_FORK pw.argv = argv; int status; @@ -9744,7 +9801,7 @@ rb_io_t *fptr; RB_IO_POINTER(io, fptr); - rb_io_check_readable(fptr); + rb_io_check_char_readable(fptr); if (rb_io_read_pending(fptr)) return Qtrue; @@ -9791,7 +9848,7 @@ rb_io_t *fptr = NULL; RB_IO_POINTER(io, fptr); - rb_io_check_readable(fptr); + rb_io_check_char_readable(fptr); if (rb_io_read_pending(fptr)) return Qtrue; diff -Nru ruby3.3-3.3.8/iseq.c ruby3.3-3.3.13/iseq.c --- ruby3.3-3.3.8/iseq.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/iseq.c 2026-10-23 03:17:41.000000000 +0000 @@ -3484,7 +3484,7 @@ const void * const *table = rb_vm_get_insns_address_table(); #define INSN_CODE(insn) ((VALUE)table[insn]) #else -#define INSN_CODE(insn) (insn) +#define INSN_CODE(insn) ((VALUE)(insn)) #endif st_data_t insn; encoded_insn_data = st_init_numtable_with_size(VM_INSTRUCTION_SIZE / 2); diff -Nru ruby3.3-3.3.8/lex.c ruby3.3-3.3.13/lex.c --- ruby3.3-3.3.8/lex.c 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/lex.c 2026-10-23 03:17:43.000000000 +0000 @@ -1,5 +1,5 @@ /* ANSI-C code produced by gperf version 3.1 */ -/* Command-line: gperf -C -P -p -j1 -i 1 -g -o -t -N rb_reserved_word -k'1,3,$' defs/keywords */ +/* Command-line: gperf -C -L ANSI-C -P -p -j1 -i 1 -g -o -t -N rb_reserved_word -k'1,3,$' defs/keywords */ #if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ @@ -28,7 +28,6 @@ #error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gperf@gnu.org>." #endif -#define gperf_offsetof(s, n) (short)offsetof(struct s##_t, s##_str##n) #line 1 "defs/keywords" struct kwtable {short name, id[2], state;}; @@ -196,88 +195,88 @@ { {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 19 "defs/keywords" - {gperf_offsetof(stringpool, 8), {keyword_break, keyword_break}, EXPR_MID}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str8, {keyword_break, keyword_break}, EXPR_MID}, #line 25 "defs/keywords" - {gperf_offsetof(stringpool, 9), {keyword_else, keyword_else}, EXPR_BEG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str9, {keyword_else, keyword_else}, EXPR_BEG}, #line 35 "defs/keywords" - {gperf_offsetof(stringpool, 10), {keyword_nil, keyword_nil}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str10, {keyword_nil, keyword_nil}, EXPR_END}, #line 28 "defs/keywords" - {gperf_offsetof(stringpool, 11), {keyword_ensure, keyword_ensure}, EXPR_BEG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str11, {keyword_ensure, keyword_ensure}, EXPR_BEG}, #line 27 "defs/keywords" - {gperf_offsetof(stringpool, 12), {keyword_end, keyword_end}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str12, {keyword_end, keyword_end}, EXPR_END}, #line 44 "defs/keywords" - {gperf_offsetof(stringpool, 13), {keyword_then, keyword_then}, EXPR_BEG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str13, {keyword_then, keyword_then}, EXPR_BEG}, #line 36 "defs/keywords" - {gperf_offsetof(stringpool, 14), {keyword_not, keyword_not}, EXPR_ARG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str14, {keyword_not, keyword_not}, EXPR_ARG}, #line 29 "defs/keywords" - {gperf_offsetof(stringpool, 15), {keyword_false, keyword_false}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str15, {keyword_false, keyword_false}, EXPR_END}, #line 42 "defs/keywords" - {gperf_offsetof(stringpool, 16), {keyword_self, keyword_self}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str16, {keyword_self, keyword_self}, EXPR_END}, #line 26 "defs/keywords" - {gperf_offsetof(stringpool, 17), {keyword_elsif, keyword_elsif}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str17, {keyword_elsif, keyword_elsif}, EXPR_VALUE}, #line 39 "defs/keywords" - {gperf_offsetof(stringpool, 18), {keyword_rescue, modifier_rescue}, EXPR_MID}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str18, {keyword_rescue, modifier_rescue}, EXPR_MID}, #line 45 "defs/keywords" - {gperf_offsetof(stringpool, 19), {keyword_true, keyword_true}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str19, {keyword_true, keyword_true}, EXPR_END}, #line 48 "defs/keywords" - {gperf_offsetof(stringpool, 20), {keyword_until, modifier_until}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str20, {keyword_until, modifier_until}, EXPR_VALUE}, #line 47 "defs/keywords" - {gperf_offsetof(stringpool, 21), {keyword_unless, modifier_unless}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str21, {keyword_unless, modifier_unless}, EXPR_VALUE}, #line 41 "defs/keywords" - {gperf_offsetof(stringpool, 22), {keyword_return, keyword_return}, EXPR_MID}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str22, {keyword_return, keyword_return}, EXPR_MID}, #line 22 "defs/keywords" - {gperf_offsetof(stringpool, 23), {keyword_def, keyword_def}, EXPR_FNAME}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str23, {keyword_def, keyword_def}, EXPR_FNAME}, #line 17 "defs/keywords" - {gperf_offsetof(stringpool, 24), {keyword_and, keyword_and}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str24, {keyword_and, keyword_and}, EXPR_VALUE}, #line 24 "defs/keywords" - {gperf_offsetof(stringpool, 25), {keyword_do, keyword_do}, EXPR_BEG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str25, {keyword_do, keyword_do}, EXPR_BEG}, #line 51 "defs/keywords" - {gperf_offsetof(stringpool, 26), {keyword_yield, keyword_yield}, EXPR_ARG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str26, {keyword_yield, keyword_yield}, EXPR_ARG}, #line 30 "defs/keywords" - {gperf_offsetof(stringpool, 27), {keyword_for, keyword_for}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str27, {keyword_for, keyword_for}, EXPR_VALUE}, #line 46 "defs/keywords" - {gperf_offsetof(stringpool, 28), {keyword_undef, keyword_undef}, EXPR_FNAME|EXPR_FITEM}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str28, {keyword_undef, keyword_undef}, EXPR_FNAME|EXPR_FITEM}, #line 37 "defs/keywords" - {gperf_offsetof(stringpool, 29), {keyword_or, keyword_or}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str29, {keyword_or, keyword_or}, EXPR_VALUE}, #line 32 "defs/keywords" - {gperf_offsetof(stringpool, 30), {keyword_in, keyword_in}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str30, {keyword_in, keyword_in}, EXPR_VALUE}, #line 49 "defs/keywords" - {gperf_offsetof(stringpool, 31), {keyword_when, keyword_when}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str31, {keyword_when, keyword_when}, EXPR_VALUE}, #line 40 "defs/keywords" - {gperf_offsetof(stringpool, 32), {keyword_retry, keyword_retry}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str32, {keyword_retry, keyword_retry}, EXPR_END}, #line 31 "defs/keywords" - {gperf_offsetof(stringpool, 33), {keyword_if, modifier_if}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str33, {keyword_if, modifier_if}, EXPR_VALUE}, #line 20 "defs/keywords" - {gperf_offsetof(stringpool, 34), {keyword_case, keyword_case}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str34, {keyword_case, keyword_case}, EXPR_VALUE}, #line 38 "defs/keywords" - {gperf_offsetof(stringpool, 35), {keyword_redo, keyword_redo}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str35, {keyword_redo, keyword_redo}, EXPR_END}, #line 34 "defs/keywords" - {gperf_offsetof(stringpool, 36), {keyword_next, keyword_next}, EXPR_MID}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str36, {keyword_next, keyword_next}, EXPR_MID}, #line 43 "defs/keywords" - {gperf_offsetof(stringpool, 37), {keyword_super, keyword_super}, EXPR_ARG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str37, {keyword_super, keyword_super}, EXPR_ARG}, #line 33 "defs/keywords" - {gperf_offsetof(stringpool, 38), {keyword_module, keyword_module}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str38, {keyword_module, keyword_module}, EXPR_VALUE}, #line 18 "defs/keywords" - {gperf_offsetof(stringpool, 39), {keyword_begin, keyword_begin}, EXPR_BEG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str39, {keyword_begin, keyword_begin}, EXPR_BEG}, #line 12 "defs/keywords" - {gperf_offsetof(stringpool, 40), {keyword__LINE__, keyword__LINE__}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str40, {keyword__LINE__, keyword__LINE__}, EXPR_END}, #line 13 "defs/keywords" - {gperf_offsetof(stringpool, 41), {keyword__FILE__, keyword__FILE__}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str41, {keyword__FILE__, keyword__FILE__}, EXPR_END}, #line 11 "defs/keywords" - {gperf_offsetof(stringpool, 42), {keyword__ENCODING__, keyword__ENCODING__}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str42, {keyword__ENCODING__, keyword__ENCODING__}, EXPR_END}, #line 15 "defs/keywords" - {gperf_offsetof(stringpool, 43), {keyword_END, keyword_END}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str43, {keyword_END, keyword_END}, EXPR_END}, #line 16 "defs/keywords" - {gperf_offsetof(stringpool, 44), {keyword_alias, keyword_alias}, EXPR_FNAME|EXPR_FITEM}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str44, {keyword_alias, keyword_alias}, EXPR_FNAME|EXPR_FITEM}, #line 14 "defs/keywords" - {gperf_offsetof(stringpool, 45), {keyword_BEGIN, keyword_BEGIN}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str45, {keyword_BEGIN, keyword_BEGIN}, EXPR_END}, #line 23 "defs/keywords" - {gperf_offsetof(stringpool, 46), {keyword_defined, keyword_defined}, EXPR_ARG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str46, {keyword_defined, keyword_defined}, EXPR_ARG}, #line 21 "defs/keywords" - {gperf_offsetof(stringpool, 47), {keyword_class, keyword_class}, EXPR_CLASS}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str47, {keyword_class, keyword_class}, EXPR_CLASS}, {-1}, {-1}, #line 50 "defs/keywords" - {gperf_offsetof(stringpool, 50), {keyword_while, modifier_while}, EXPR_VALUE} + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str50, {keyword_while, modifier_while}, EXPR_VALUE} }; if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) diff -Nru ruby3.3-3.3.8/lex.c.blt ruby3.3-3.3.13/lex.c.blt --- ruby3.3-3.3.8/lex.c.blt 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lex.c.blt 2026-10-23 03:17:41.000000000 +0000 @@ -1,5 +1,5 @@ /* ANSI-C code produced by gperf version 3.1 */ -/* Command-line: gperf -C -P -p -j1 -i 1 -g -o -t -N rb_reserved_word -k'1,3,$' defs/keywords */ +/* Command-line: gperf -C -L ANSI-C -P -p -j1 -i 1 -g -o -t -N rb_reserved_word -k'1,3,$' defs/keywords */ #if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ @@ -28,7 +28,6 @@ #error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gperf@gnu.org>." #endif -#define gperf_offsetof(s, n) (short)offsetof(struct s##_t, s##_str##n) #line 1 "defs/keywords" struct kwtable {short name, id[2], state;}; @@ -196,88 +195,88 @@ { {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, #line 19 "defs/keywords" - {gperf_offsetof(stringpool, 8), {keyword_break, keyword_break}, EXPR_MID}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str8, {keyword_break, keyword_break}, EXPR_MID}, #line 25 "defs/keywords" - {gperf_offsetof(stringpool, 9), {keyword_else, keyword_else}, EXPR_BEG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str9, {keyword_else, keyword_else}, EXPR_BEG}, #line 35 "defs/keywords" - {gperf_offsetof(stringpool, 10), {keyword_nil, keyword_nil}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str10, {keyword_nil, keyword_nil}, EXPR_END}, #line 28 "defs/keywords" - {gperf_offsetof(stringpool, 11), {keyword_ensure, keyword_ensure}, EXPR_BEG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str11, {keyword_ensure, keyword_ensure}, EXPR_BEG}, #line 27 "defs/keywords" - {gperf_offsetof(stringpool, 12), {keyword_end, keyword_end}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str12, {keyword_end, keyword_end}, EXPR_END}, #line 44 "defs/keywords" - {gperf_offsetof(stringpool, 13), {keyword_then, keyword_then}, EXPR_BEG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str13, {keyword_then, keyword_then}, EXPR_BEG}, #line 36 "defs/keywords" - {gperf_offsetof(stringpool, 14), {keyword_not, keyword_not}, EXPR_ARG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str14, {keyword_not, keyword_not}, EXPR_ARG}, #line 29 "defs/keywords" - {gperf_offsetof(stringpool, 15), {keyword_false, keyword_false}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str15, {keyword_false, keyword_false}, EXPR_END}, #line 42 "defs/keywords" - {gperf_offsetof(stringpool, 16), {keyword_self, keyword_self}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str16, {keyword_self, keyword_self}, EXPR_END}, #line 26 "defs/keywords" - {gperf_offsetof(stringpool, 17), {keyword_elsif, keyword_elsif}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str17, {keyword_elsif, keyword_elsif}, EXPR_VALUE}, #line 39 "defs/keywords" - {gperf_offsetof(stringpool, 18), {keyword_rescue, modifier_rescue}, EXPR_MID}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str18, {keyword_rescue, modifier_rescue}, EXPR_MID}, #line 45 "defs/keywords" - {gperf_offsetof(stringpool, 19), {keyword_true, keyword_true}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str19, {keyword_true, keyword_true}, EXPR_END}, #line 48 "defs/keywords" - {gperf_offsetof(stringpool, 20), {keyword_until, modifier_until}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str20, {keyword_until, modifier_until}, EXPR_VALUE}, #line 47 "defs/keywords" - {gperf_offsetof(stringpool, 21), {keyword_unless, modifier_unless}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str21, {keyword_unless, modifier_unless}, EXPR_VALUE}, #line 41 "defs/keywords" - {gperf_offsetof(stringpool, 22), {keyword_return, keyword_return}, EXPR_MID}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str22, {keyword_return, keyword_return}, EXPR_MID}, #line 22 "defs/keywords" - {gperf_offsetof(stringpool, 23), {keyword_def, keyword_def}, EXPR_FNAME}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str23, {keyword_def, keyword_def}, EXPR_FNAME}, #line 17 "defs/keywords" - {gperf_offsetof(stringpool, 24), {keyword_and, keyword_and}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str24, {keyword_and, keyword_and}, EXPR_VALUE}, #line 24 "defs/keywords" - {gperf_offsetof(stringpool, 25), {keyword_do, keyword_do}, EXPR_BEG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str25, {keyword_do, keyword_do}, EXPR_BEG}, #line 51 "defs/keywords" - {gperf_offsetof(stringpool, 26), {keyword_yield, keyword_yield}, EXPR_ARG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str26, {keyword_yield, keyword_yield}, EXPR_ARG}, #line 30 "defs/keywords" - {gperf_offsetof(stringpool, 27), {keyword_for, keyword_for}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str27, {keyword_for, keyword_for}, EXPR_VALUE}, #line 46 "defs/keywords" - {gperf_offsetof(stringpool, 28), {keyword_undef, keyword_undef}, EXPR_FNAME|EXPR_FITEM}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str28, {keyword_undef, keyword_undef}, EXPR_FNAME|EXPR_FITEM}, #line 37 "defs/keywords" - {gperf_offsetof(stringpool, 29), {keyword_or, keyword_or}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str29, {keyword_or, keyword_or}, EXPR_VALUE}, #line 32 "defs/keywords" - {gperf_offsetof(stringpool, 30), {keyword_in, keyword_in}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str30, {keyword_in, keyword_in}, EXPR_VALUE}, #line 49 "defs/keywords" - {gperf_offsetof(stringpool, 31), {keyword_when, keyword_when}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str31, {keyword_when, keyword_when}, EXPR_VALUE}, #line 40 "defs/keywords" - {gperf_offsetof(stringpool, 32), {keyword_retry, keyword_retry}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str32, {keyword_retry, keyword_retry}, EXPR_END}, #line 31 "defs/keywords" - {gperf_offsetof(stringpool, 33), {keyword_if, modifier_if}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str33, {keyword_if, modifier_if}, EXPR_VALUE}, #line 20 "defs/keywords" - {gperf_offsetof(stringpool, 34), {keyword_case, keyword_case}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str34, {keyword_case, keyword_case}, EXPR_VALUE}, #line 38 "defs/keywords" - {gperf_offsetof(stringpool, 35), {keyword_redo, keyword_redo}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str35, {keyword_redo, keyword_redo}, EXPR_END}, #line 34 "defs/keywords" - {gperf_offsetof(stringpool, 36), {keyword_next, keyword_next}, EXPR_MID}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str36, {keyword_next, keyword_next}, EXPR_MID}, #line 43 "defs/keywords" - {gperf_offsetof(stringpool, 37), {keyword_super, keyword_super}, EXPR_ARG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str37, {keyword_super, keyword_super}, EXPR_ARG}, #line 33 "defs/keywords" - {gperf_offsetof(stringpool, 38), {keyword_module, keyword_module}, EXPR_VALUE}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str38, {keyword_module, keyword_module}, EXPR_VALUE}, #line 18 "defs/keywords" - {gperf_offsetof(stringpool, 39), {keyword_begin, keyword_begin}, EXPR_BEG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str39, {keyword_begin, keyword_begin}, EXPR_BEG}, #line 12 "defs/keywords" - {gperf_offsetof(stringpool, 40), {keyword__LINE__, keyword__LINE__}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str40, {keyword__LINE__, keyword__LINE__}, EXPR_END}, #line 13 "defs/keywords" - {gperf_offsetof(stringpool, 41), {keyword__FILE__, keyword__FILE__}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str41, {keyword__FILE__, keyword__FILE__}, EXPR_END}, #line 11 "defs/keywords" - {gperf_offsetof(stringpool, 42), {keyword__ENCODING__, keyword__ENCODING__}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str42, {keyword__ENCODING__, keyword__ENCODING__}, EXPR_END}, #line 15 "defs/keywords" - {gperf_offsetof(stringpool, 43), {keyword_END, keyword_END}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str43, {keyword_END, keyword_END}, EXPR_END}, #line 16 "defs/keywords" - {gperf_offsetof(stringpool, 44), {keyword_alias, keyword_alias}, EXPR_FNAME|EXPR_FITEM}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str44, {keyword_alias, keyword_alias}, EXPR_FNAME|EXPR_FITEM}, #line 14 "defs/keywords" - {gperf_offsetof(stringpool, 45), {keyword_BEGIN, keyword_BEGIN}, EXPR_END}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str45, {keyword_BEGIN, keyword_BEGIN}, EXPR_END}, #line 23 "defs/keywords" - {gperf_offsetof(stringpool, 46), {keyword_defined, keyword_defined}, EXPR_ARG}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str46, {keyword_defined, keyword_defined}, EXPR_ARG}, #line 21 "defs/keywords" - {gperf_offsetof(stringpool, 47), {keyword_class, keyword_class}, EXPR_CLASS}, + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str47, {keyword_class, keyword_class}, EXPR_CLASS}, {-1}, {-1}, #line 50 "defs/keywords" - {gperf_offsetof(stringpool, 50), {keyword_while, modifier_while}, EXPR_VALUE} + {(int)(size_t)&((struct stringpool_t *)0)->stringpool_str50, {keyword_while, modifier_while}, EXPR_VALUE} }; if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) diff -Nru ruby3.3-3.3.8/lib/bundler/vendor/uri/lib/uri/generic.rb ruby3.3-3.3.13/lib/bundler/vendor/uri/lib/uri/generic.rb --- ruby3.3-3.3.8/lib/bundler/vendor/uri/lib/uri/generic.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/bundler/vendor/uri/lib/uri/generic.rb 2026-10-23 03:17:41.000000000 +0000 @@ -186,18 +186,18 @@ if arg_check self.scheme = scheme - self.userinfo = userinfo self.hostname = host self.port = port + self.userinfo = userinfo self.path = path self.query = query self.opaque = opaque self.fragment = fragment else self.set_scheme(scheme) - self.set_userinfo(userinfo) self.set_host(host) self.set_port(port) + self.set_userinfo(userinfo) self.set_path(path) self.query = query self.set_opaque(opaque) @@ -511,7 +511,7 @@ user, password = split_userinfo(user) end @user = user - @password = password if password + @password = password [@user, @password] end @@ -522,7 +522,7 @@ # See also Bundler::URI::Generic.user=. # def set_user(v) - set_userinfo(v, @password) + set_userinfo(v, nil) v end protected :set_user @@ -615,6 +615,13 @@ end protected :set_host + # Protected setter for the authority info (+user+, +password+, +host+ + # and +port+). If +port+ is +nil+, +default_port+ will be set. + # + protected def set_authority(user, password, host, port = nil) + @user, @password, @host, @port = user, password, host, port || self.default_port + end + # # == Args # @@ -639,6 +646,7 @@ def host=(v) check_host(v) set_host(v) + set_userinfo(nil) v end @@ -729,6 +737,7 @@ def port=(v) check_port(v) set_port(v) + set_userinfo(nil) port end @@ -1121,7 +1130,7 @@ base = self.dup - authority = rel.userinfo || rel.host || rel.port + authority = rel.authority # RFC2396, Section 5.2, 2) if (rel.path.nil? || rel.path.empty?) && !authority && !rel.query @@ -1133,17 +1142,14 @@ base.fragment=(nil) # RFC2396, Section 5.2, 4) - if !authority - base.set_path(merge_path(base.path, rel.path)) if base.path && rel.path - else - # RFC2396, Section 5.2, 4) - base.set_path(rel.path) if rel.path + if authority + base.set_authority(*authority) + base.set_path(rel.path) + elsif base.path && rel.path + base.set_path(merge_path(base.path, rel.path)) end # RFC2396, Section 5.2, 7) - base.set_userinfo(rel.userinfo) if rel.userinfo - base.set_host(rel.host) if rel.host - base.set_port(rel.port) if rel.port base.query = rel.query if rel.query base.fragment=(rel.fragment) if rel.fragment diff -Nru ruby3.3-3.3.8/lib/bundler/vendor/uri/lib/uri/version.rb ruby3.3-3.3.13/lib/bundler/vendor/uri/lib/uri/version.rb --- ruby3.3-3.3.8/lib/bundler/vendor/uri/lib/uri/version.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/bundler/vendor/uri/lib/uri/version.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1,6 +1,6 @@ module Bundler::URI # :stopdoc: - VERSION_CODE = '001301'.freeze + VERSION_CODE = '001303'.freeze VERSION = VERSION_CODE.scan(/../).collect{|n| n.to_i}.join('.').freeze # :startdoc: end diff -Nru ruby3.3-3.3.8/lib/erb/version.rb ruby3.3-3.3.13/lib/erb/version.rb --- ruby3.3-3.3.8/lib/erb/version.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/erb/version.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1,5 +1,5 @@ # frozen_string_literal: true class ERB - VERSION = '4.0.3' + VERSION = '4.0.3.1' private_constant :VERSION end diff -Nru ruby3.3-3.3.8/lib/erb.rb ruby3.3-3.3.13/lib/erb.rb --- ruby3.3-3.3.8/lib/erb.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/erb.rb 2026-10-23 03:17:41.000000000 +0000 @@ -463,6 +463,9 @@ # erb.def_method(MyClass, 'render(arg1, arg2)', filename) # print MyClass.new.render('foo', 123) def def_method(mod, methodname, fname='(ERB)') + unless @_init.equal?(self.class.singleton_class) + raise ArgumentError, "not initialized" + end src = self.src.sub(/^(?!#|$)/) {"def #{methodname}\n"} << "\nend\n" mod.module_eval do eval(src, binding, fname, -1) diff -Nru ruby3.3-3.3.8/lib/mkmf.rb ruby3.3-3.3.13/lib/mkmf.rb --- ruby3.3-3.3.8/lib/mkmf.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/mkmf.rb 2026-10-23 03:17:41.000000000 +0000 @@ -2465,7 +2465,7 @@ dest = "#{dir}/#{File.basename(f)}" mfile.print("do-install-rb#{sfx}: #{dest}\n") mfile.print("#{dest}: #{f} #{timestamp_file(dir, target_prefix)}\n") - mfile.print("\t$(Q) $(#{$extout ? 'COPY' : 'INSTALL_DATA'}) #{f} $(@D)\n") + mfile.print("\t$(Q) $(#{$extout ? 'COPY' : 'INSTALL_DATA'}) #{f} $@\n") if defined?($installed_list) and !$extout mfile.print("\t@echo #{dest}>>$(INSTALLED_LIST)\n") end diff -Nru ruby3.3-3.3.8/lib/pstore.rb ruby3.3-3.3.13/lib/pstore.rb --- ruby3.3-3.3.8/lib/pstore.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/pstore.rb 2026-10-23 03:17:41.000000000 +0000 @@ -326,11 +326,14 @@ # end # class PStore - VERSION = "0.1.3" + # :stopdoc: + VERSION = "0.2.1" RDWR_ACCESS = {mode: IO::RDWR | IO::CREAT | IO::BINARY, encoding: Encoding::ASCII_8BIT}.freeze RD_ACCESS = {mode: IO::RDONLY | IO::BINARY, encoding: Encoding::ASCII_8BIT}.freeze WR_ACCESS = {mode: IO::WRONLY | IO::CREAT | IO::TRUNC | IO::BINARY, encoding: Encoding::ASCII_8BIT}.freeze + private_constant :RDWR_ACCESS, :RD_ACCESS, :WR_ACCESS + # :startdoc: # The error type thrown by all PStore methods. class Error < StandardError @@ -437,7 +440,7 @@ in_transaction unless @table.key? key if default == PStore::Error - raise PStore::Error, format("undefined key `%s'", key) + raise PStore::Error, format("undefined key '%s'", key) else return default end @@ -591,6 +594,8 @@ end private + # :stopdoc: + # Constant for relieving Ruby's garbage collector. CHECKSUM_ALGO = %w[SHA512 SHA384 SHA256 SHA1 RMD160 MD5].each do |algo| begin @@ -602,6 +607,10 @@ EMPTY_MARSHAL_DATA = Marshal.dump({}) EMPTY_MARSHAL_CHECKSUM = CHECKSUM_ALGO.digest(EMPTY_MARSHAL_DATA) + EMPTY_MARSHAL_DATA.freeze + EMPTY_MARSHAL_CHECKSUM.freeze + private_constant :CHECKSUM_ALGO, :EMPTY_STRING, :EMPTY_MARSHAL_DATA, :EMPTY_MARSHAL_CHECKSUM + # # Open the specified filename (either in read-only mode or in # read-write mode) and lock it for reading or writing. @@ -664,20 +673,16 @@ end end - def on_windows? - is_windows = RUBY_PLATFORM =~ /mswin|mingw|bccwin|wince/ - self.class.__send__(:define_method, :on_windows?) do - is_windows - end - is_windows - end + ON_WINDOWS = true & (/mswin|mingw|bccwin|wince/ =~ RUBY_PLATFORM) # :nodoc: + private_constant :ON_WINDOWS def save_data(original_checksum, original_file_size, file) new_data = dump(@table) if new_data.bytesize != original_file_size || CHECKSUM_ALGO.digest(new_data) != original_checksum - if @ultra_safe && !on_windows? - # Windows doesn't support atomic file renames. + if @ultra_safe && !ON_WINDOWS + # Once a file is locked, Windows does not guarantee that the + # lock will be released until the file is closed. save_data_with_atomic_file_rename_strategy(new_data, file) else save_data_with_fast_strategy(new_data, file) diff -Nru ruby3.3-3.3.8/lib/resolv.rb ruby3.3-3.3.13/lib/resolv.rb --- ruby3.3-3.3.8/lib/resolv.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/resolv.rb 2026-10-23 03:17:41.000000000 +0000 @@ -37,7 +37,7 @@ class Resolv - VERSION = "0.3.0" + VERSION = "0.3.2" ## # Looks up the first IP address for +name+. @@ -1219,6 +1219,13 @@ class Str # :nodoc: def initialize(string) + # A label is limited to 63 octets. [RFC 1035 2.3.4] Checking it here + # makes it an invariant of the object: every label, however it was + # built, fits in its length octet and cannot wrap it. Callers turn + # this into the error their own contract promises. + if string.bytesize > 63 + raise ArgumentError, "DNS label is too long (#{string.bytesize} bytes, max 63): #{string.inspect}" + end @string = string # case insensivity of DNS labels doesn't apply non-ASCII characters. [RFC 4343] # This assumes @string is given in ASCII compatible encoding. @@ -1264,7 +1271,26 @@ when Name return arg when String - return Name.new(Label.split(arg), /\.\z/ =~ arg ? true : false) + # A hostname is runtime data rather than a programming mistake, so + # both size limits surface as ResolvError to stay rescuable alongside + # the rest of name resolution. The type check below is a caller + # mistake and keeps raising ArgumentError. + begin + labels = Label.split(arg) + rescue ArgumentError => e + raise ResolvError.new(e.message) + end + # Label::Str enforces the per-label limit. Only the total is knowable + # here, and it counts the encoded form, so size starts at 1 for the + # root label's terminating zero octet. [RFC 1035 2.3.4, 3.1] + size = 1 + labels.each do |label| + size += 1 + label.string.bytesize + if size > 255 + raise ResolvError.new("DNS name is too long (#{size} octets, max 255): #{arg.inspect}") + end + end + return Name.new(labels, /\.\z/ =~ arg ? true : false) else raise ArgumentError.new("cannot interpret as DNS name: #{arg.inspect}") end @@ -1386,12 +1412,24 @@ @rd == other.rd && @ra == other.ra && @rcode == other.rcode && - @question == other.question && + question_equal?(other.question) && @answer == other.answer && @authority == other.authority && @additional == other.additional end + # A question holds the resource class itself, and decoding creates a fresh + # class for each unknown type, so the classes cannot be compared by + # identity alone. + private def question_equal?(other_question) # :nodoc: + return false unless @question.length == other_question.length + @question.zip(other_question) {|(name, typeclass), (o_name, o_typeclass)| + return false unless name == o_name && + Resource::Generic.type_class_equal?(typeclass, o_typeclass) + } + return true + end + def add_question(name, typeclass) @question << [Name.create(name), typeclass] end @@ -1498,8 +1536,15 @@ end def put_string(d) - self.put_pack("C", d.length) - @data << d + s = d.to_s + # A character-string is prefixed by a single length octet, so it can + # hold at most 255 octets. [RFC 1035 3.3] Reject anything longer to + # avoid silently truncating the length to its low 8 bits (mod 256). + if s.bytesize > 255 + raise ArgumentError, "character-string is too long (#{s.bytesize} bytes, max 255): #{s.inspect}" + end + self.put_pack("C", s.bytesize) + @data << s end def put_string_list(ds) @@ -1529,7 +1574,17 @@ end def put_label(d) - self.put_string(d.to_s) + s = d.to_s + # Label::Str applies this limit when a label is built, so what is left + # for here is a raw string handed straight to put_labels. The two ways + # an over-long label goes wrong differ: 64 to 255 octets write a length + # octet in the reserved or compression pointer range, and 256 or more + # wrap it mod 256. Either way the encoded name stops being the name the + # caller asked for. [RFC 1035 2.3.4, 4.1.4] + if s.bytesize > 63 + raise ArgumentError, "DNS label is too long (#{s.bytesize} bytes, max 63): #{s.inspect}" + end + self.put_string(s) end end @@ -1655,6 +1710,9 @@ prev_index = @index save_index = nil d = [] + # size counts the encoded form, so it starts at 1 for the root + # label's terminating zero octet. [RFC 1035 3.1] + size = 1 while true raise DecodeError.new("limit exceeded") if @limit <= @index case @data.getbyte(@index) @@ -1675,13 +1733,21 @@ end @index = idx else - d << self.get_label + l = self.get_label + d << l + size += 1 + l.string.bytesize + raise DecodeError.new("name label data exceed 255 octets") if size > 255 end end end def get_label return Label::Str.new(self.get_string) + rescue ArgumentError => e + # A length octet of 64..191 is reserved rather than a label length, + # but this decoder used to read it as one. [RFC 1035 4.1.4] Report it + # the way the rest of a malformed message is reported. + raise DecodeError.new(e.message) end def get_question @@ -1870,8 +1936,9 @@ key_name = :"key#{key_number}" c.const_set(:KeyName, key_name) c.const_set(:KeyNumber, key_number) - self.const_set(:"Key#{key_number}", c) - ClassHash[key_name] = ClassHash[key_number] = c + # Not registered in a constant or in ClassHash. ClassHash creates a + # class for every unknown SvcParamKey, so registering them + # permanently would let a malicious response exhaust memory. return c end end @@ -2169,12 +2236,28 @@ return self.new(msg.get_bytes) end + # create makes a fresh class for each decoded resource, so the type and + # class values have to be compared instead of the class itself. + def self.type_class_equal?(klass, other) # :nodoc: + return true if klass.equal?(other) + Generic > klass && Generic > other && + klass::TypeValue == other::TypeValue && + klass::ClassValue == other::ClassValue + end + + def ==(other) # :nodoc: + return other.is_a?(Generic) && + Generic.type_class_equal?(self.class, other.class) && + @data == other.data + end + def self.create(type_value, class_value) # :nodoc: c = Class.new(Generic) c.const_set(:TypeValue, type_value) c.const_set(:ClassValue, class_value) - Generic.const_set("Type#{type_value}_Class#{class_value}", c) - ClassHash[[type_value, class_value]] = c + # Not registered in a constant or in ClassHash. get_class creates a + # class for every unknown (type, class) pair, so registering them + # permanently would let a malicious response exhaust memory. return c end end diff -Nru ruby3.3-3.3.8/lib/rubygems/vendor/uri/lib/uri/generic.rb ruby3.3-3.3.13/lib/rubygems/vendor/uri/lib/uri/generic.rb --- ruby3.3-3.3.8/lib/rubygems/vendor/uri/lib/uri/generic.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/rubygems/vendor/uri/lib/uri/generic.rb 2026-10-23 03:17:41.000000000 +0000 @@ -186,18 +186,18 @@ if arg_check self.scheme = scheme - self.userinfo = userinfo self.hostname = host self.port = port + self.userinfo = userinfo self.path = path self.query = query self.opaque = opaque self.fragment = fragment else self.set_scheme(scheme) - self.set_userinfo(userinfo) self.set_host(host) self.set_port(port) + self.set_userinfo(userinfo) self.set_path(path) self.query = query self.set_opaque(opaque) @@ -511,7 +511,7 @@ user, password = split_userinfo(user) end @user = user - @password = password if password + @password = password [@user, @password] end @@ -522,7 +522,7 @@ # See also Gem::URI::Generic.user=. # def set_user(v) - set_userinfo(v, @password) + set_userinfo(v, nil) v end protected :set_user @@ -574,6 +574,12 @@ @password end + # Returns the authority info (array of user, password, host and + # port), if any is set. Or returns +nil+. + def authority + return @user, @password, @host, @port if @user || @password || @host || @port + end + # Returns the user component after Gem::URI decoding. def decoded_user Gem::URI.decode_uri_component(@user) if @user @@ -615,6 +621,13 @@ end protected :set_host + # Protected setter for the authority info (+user+, +password+, +host+ + # and +port+). If +port+ is +nil+, +default_port+ will be set. + # + protected def set_authority(user, password, host, port = nil) + @user, @password, @host, @port = user, password, host, port || self.default_port + end + # # == Args # @@ -639,6 +652,7 @@ def host=(v) check_host(v) set_host(v) + set_userinfo(nil) v end @@ -729,6 +743,7 @@ def port=(v) check_port(v) set_port(v) + set_userinfo(nil) port end @@ -1121,7 +1136,7 @@ base = self.dup - authority = rel.userinfo || rel.host || rel.port + authority = rel.authority # RFC2396, Section 5.2, 2) if (rel.path.nil? || rel.path.empty?) && !authority && !rel.query @@ -1133,17 +1148,14 @@ base.fragment=(nil) # RFC2396, Section 5.2, 4) - if !authority - base.set_path(merge_path(base.path, rel.path)) if base.path && rel.path - else - # RFC2396, Section 5.2, 4) - base.set_path(rel.path) if rel.path + if authority + base.set_authority(*authority) + base.set_path(rel.path) + elsif base.path && rel.path + base.set_path(merge_path(base.path, rel.path)) end # RFC2396, Section 5.2, 7) - base.set_userinfo(rel.userinfo) if rel.userinfo - base.set_host(rel.host) if rel.host - base.set_port(rel.port) if rel.port base.query = rel.query if rel.query base.fragment=(rel.fragment) if rel.fragment diff -Nru ruby3.3-3.3.8/lib/rubygems/vendor/uri/lib/uri/version.rb ruby3.3-3.3.13/lib/rubygems/vendor/uri/lib/uri/version.rb --- ruby3.3-3.3.8/lib/rubygems/vendor/uri/lib/uri/version.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/rubygems/vendor/uri/lib/uri/version.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1,6 +1,6 @@ module Gem::URI # :stopdoc: - VERSION_CODE = '001301'.freeze + VERSION_CODE = '001303'.freeze VERSION = VERSION_CODE.scan(/../).collect{|n| n.to_i}.join('.').freeze # :startdoc: end diff -Nru ruby3.3-3.3.8/lib/syntax_suggest/api.rb ruby3.3-3.3.13/lib/syntax_suggest/api.rb --- ruby3.3-3.3.8/lib/syntax_suggest/api.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/syntax_suggest/api.rb 2026-10-23 03:17:41.000000000 +0000 @@ -146,11 +146,7 @@ def self.valid_without?(without_lines:, code_lines:) lines = code_lines - Array(without_lines).flatten - if lines.empty? - true - else - valid?(lines) - end + lines.empty? || valid?(lines) end # SyntaxSuggest.invalid? [Private] @@ -227,6 +223,7 @@ require_relative "code_line" require_relative "code_block" require_relative "block_expand" +require_relative "mini_stringio" require_relative "priority_queue" require_relative "unvisited_lines" require_relative "around_block_scan" diff -Nru ruby3.3-3.3.8/lib/syntax_suggest/capture_code_context.rb ruby3.3-3.3.13/lib/syntax_suggest/capture_code_context.rb --- ruby3.3-3.3.8/lib/syntax_suggest/capture_code_context.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/syntax_suggest/capture_code_context.rb 2026-10-23 03:17:41.000000000 +0000 @@ -15,7 +15,7 @@ # # 1. Sanitize/format input source # 2. Search for invalid blocks - # 3. Format invalid blocks into something meaninful + # 3. Format invalid blocks into something meaningful # # This class handles the third part. # diff -Nru ruby3.3-3.3.8/lib/syntax_suggest/clean_document.rb ruby3.3-3.3.13/lib/syntax_suggest/clean_document.rb --- ruby3.3-3.3.8/lib/syntax_suggest/clean_document.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/syntax_suggest/clean_document.rb 2026-10-23 03:17:41.000000000 +0000 @@ -10,7 +10,7 @@ # # 1. Sanitize/format input source # 2. Search for invalid blocks - # 3. Format invalid blocks into something meaninful + # 3. Format invalid blocks into something meaningful # # This class handles the first part. # diff -Nru ruby3.3-3.3.8/lib/syntax_suggest/code_frontier.rb ruby3.3-3.3.13/lib/syntax_suggest/code_frontier.rb --- ruby3.3-3.3.8/lib/syntax_suggest/code_frontier.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/syntax_suggest/code_frontier.rb 2026-10-23 03:17:41.000000000 +0000 @@ -8,7 +8,7 @@ # # 1. Sanitize/format input source # 2. Search for invalid blocks - # 3. Format invalid blocks into something meaninful + # 3. Format invalid blocks into something meaningful # # The Code frontier is a critical part of the second step # diff -Nru ruby3.3-3.3.8/lib/syntax_suggest/code_line.rb ruby3.3-3.3.13/lib/syntax_suggest/code_line.rb --- ruby3.3-3.3.8/lib/syntax_suggest/code_line.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/syntax_suggest/code_line.rb 2026-10-23 03:17:41.000000000 +0000 @@ -180,18 +180,17 @@ # EOM # expect(lines.first.trailing_slash?).to eq(true) # - if SyntaxSuggest.use_prism_parser? - def trailing_slash? - last = @lex.last - last&.type == :on_tstring_end - end - else - def trailing_slash? - last = @lex.last - return false unless last - return false unless last.type == :on_sp + def trailing_slash? + last = @lex.last + # Older versions of prism diverged slightly from Ripper in compatibility mode + case last&.type + when :on_sp last.token == TRAILING_SLASH + when :on_tstring_end + true + else + false end end diff -Nru ruby3.3-3.3.8/lib/syntax_suggest/core_ext.rb ruby3.3-3.3.13/lib/syntax_suggest/core_ext.rb --- ruby3.3-3.3.8/lib/syntax_suggest/core_ext.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/syntax_suggest/core_ext.rb 2026-10-23 03:17:41.000000000 +0000 @@ -3,24 +3,6 @@ # Ruby 3.2+ has a cleaner way to hook into Ruby that doesn't use `require` if SyntaxError.method_defined?(:detailed_message) module SyntaxSuggest - # Mini String IO [Private] - # - # Acts like a StringIO with reduced API, but without having to require that - # class. - class MiniStringIO - def initialize(isatty: $stderr.isatty) - @string = +"" - @isatty = isatty - end - - attr_reader :isatty - def puts(value = $/, **) - @string << value - end - - attr_reader :string - end - # SyntaxSuggest.module_for_detailed_message [Private] # # Used to monkeypatch SyntaxError via Module.prepend diff -Nru ruby3.3-3.3.8/lib/syntax_suggest/mini_stringio.rb ruby3.3-3.3.13/lib/syntax_suggest/mini_stringio.rb --- ruby3.3-3.3.8/lib/syntax_suggest/mini_stringio.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/lib/syntax_suggest/mini_stringio.rb 2026-10-23 03:17:41.000000000 +0000 @@ -0,0 +1,30 @@ +# frozen_string_literal: true + +module SyntaxSuggest + # Mini String IO [Private] + # + # Acts like a StringIO with reduced API, but without having to require that + # class. + # + # The original codebase emitted directly to $stderr, but now SyntaxError#detailed_message + # needs a string output. To accomplish that we kept the original print infrastructure in place and + # added this class to accumulate the print output into a string. + class MiniStringIO + EMPTY_ARG = Object.new + + def initialize(isatty: $stderr.isatty) + @string = +"" + @isatty = isatty + end + + attr_reader :isatty + def puts(value = EMPTY_ARG, **) + if !value.equal?(EMPTY_ARG) + @string << value + end + @string << $/ + end + + attr_reader :string + end +end diff -Nru ruby3.3-3.3.8/lib/syntax_suggest/version.rb ruby3.3-3.3.13/lib/syntax_suggest/version.rb --- ruby3.3-3.3.8/lib/syntax_suggest/version.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/syntax_suggest/version.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1,5 +1,5 @@ # frozen_string_literal: true module SyntaxSuggest - VERSION = "2.0.1" + VERSION = "2.0.3" end diff -Nru ruby3.3-3.3.8/lib/unicode_normalize/normalize.rb ruby3.3-3.3.13/lib/unicode_normalize/normalize.rb --- ruby3.3-3.3.8/lib/unicode_normalize/normalize.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/unicode_normalize/normalize.rb 2026-10-23 03:17:41.000000000 +0000 @@ -82,16 +82,22 @@ ## Canonical Ordering def self.canonical_ordering_one(string) - sorting = string.each_char.collect { |c| [c, CLASS_TABLE[c]] } - (sorting.length-2).downto(0) do |i| # almost, but not exactly bubble sort - (0..i).each do |j| - later_class = sorting[j+1].last - if 0<later_class and later_class<sorting[j].last - sorting[j], sorting[j+1] = sorting[j+1], sorting[j] - end + result = '' + unordered = [] + chars = string.chars + n = chars.size + chars.each_with_index do |char, i| + ccc = CLASS_TABLE[char] + if ccc == 0 + unordered.sort!.each {|i| result << chars[i % n] } + unordered.clear + result << char + else + unordered << ccc * n + i end end - return sorting.collect(&:first).join('') + unordered.sort!.each {|i| result << chars[i % n] } + result end ## Normalization Forms for Patterns (not whole Strings) diff -Nru ruby3.3-3.3.8/lib/uri/generic.rb ruby3.3-3.3.13/lib/uri/generic.rb --- ruby3.3-3.3.8/lib/uri/generic.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/uri/generic.rb 2026-10-23 03:17:41.000000000 +0000 @@ -186,18 +186,18 @@ if arg_check self.scheme = scheme - self.userinfo = userinfo self.hostname = host self.port = port + self.userinfo = userinfo self.path = path self.query = query self.opaque = opaque self.fragment = fragment else self.set_scheme(scheme) - self.set_userinfo(userinfo) self.set_host(host) self.set_port(port) + self.set_userinfo(userinfo) self.set_path(path) self.query = query self.set_opaque(opaque) @@ -511,7 +511,7 @@ user, password = split_userinfo(user) end @user = user - @password = password if password + @password = password [@user, @password] end @@ -522,7 +522,7 @@ # See also URI::Generic.user=. # def set_user(v) - set_userinfo(v, @password) + set_userinfo(v, nil) v end protected :set_user @@ -574,6 +574,12 @@ @password end + # Returns the authority info (array of user, password, host and + # port), if any is set. Or returns +nil+. + def authority + return @user, @password, @host, @port if @user || @password || @host || @port + end + # Returns the user component after URI decoding. def decoded_user URI.decode_uri_component(@user) if @user @@ -615,6 +621,13 @@ end protected :set_host + # Protected setter for the authority info (+user+, +password+, +host+ + # and +port+). If +port+ is +nil+, +default_port+ will be set. + # + protected def set_authority(user, password, host, port = nil) + @user, @password, @host, @port = user, password, host, port || self.default_port + end + # # == Args # @@ -639,6 +652,7 @@ def host=(v) check_host(v) set_host(v) + set_userinfo(nil) v end @@ -729,6 +743,7 @@ def port=(v) check_port(v) set_port(v) + set_userinfo(nil) port end @@ -1121,7 +1136,7 @@ base = self.dup - authority = rel.userinfo || rel.host || rel.port + authority = rel.authority # RFC2396, Section 5.2, 2) if (rel.path.nil? || rel.path.empty?) && !authority && !rel.query @@ -1134,9 +1149,7 @@ # RFC2396, Section 5.2, 4) if authority - base.set_userinfo(rel.userinfo) - base.set_host(rel.host) - base.set_port(rel.port || base.default_port) + base.set_authority(*authority) base.set_path(rel.path) elsif base.path && rel.path base.set_path(merge_path(base.path, rel.path)) diff -Nru ruby3.3-3.3.8/lib/uri/version.rb ruby3.3-3.3.13/lib/uri/version.rb --- ruby3.3-3.3.8/lib/uri/version.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/lib/uri/version.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1,6 +1,6 @@ module URI # :stopdoc: - VERSION_CODE = '001302'.freeze + VERSION_CODE = '001303'.freeze VERSION = VERSION_CODE.scan(/../).collect{|n| n.to_i}.join('.').freeze # :startdoc: end diff -Nru ruby3.3-3.3.8/libexec/syntax_suggest ruby3.3-3.3.13/libexec/syntax_suggest --- ruby3.3-3.3.8/libexec/syntax_suggest 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/libexec/syntax_suggest 2026-10-23 03:17:41.000000000 +0000 @@ -1,6 +1,11 @@ #!/usr/bin/env ruby -require "syntax_suggest/api" +begin + require_relative "../lib/syntax_suggest/api" +rescue LoadError + # for default gems + require "syntax_suggest/api" +end SyntaxSuggest::Cli.new( argv: ARGV diff -Nru ruby3.3-3.3.8/load.c ruby3.3-3.3.13/load.c --- ruby3.3-3.3.8/load.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/load.c 2026-10-23 03:17:41.000000000 +0000 @@ -283,7 +283,7 @@ if (pos >= 0) { long *ptr = rb_darray_data_ptr(feature_indexes); long len = rb_darray_size(feature_indexes); - MEMMOVE(ptr + pos, ptr + pos + 1, long, len - pos - 1); + MEMMOVE(ptr + pos + 1, ptr + pos, long, len - pos - 1); ptr[pos] = FIX2LONG(offset); } } @@ -395,6 +395,11 @@ rb_hash_clear(realpaths); rb_hash_clear(realpath_map); features = vm->loaded_features; + + /* We have to make a copy of features here because the StringValue call + * below could call a Ruby method, which could modify $LOADED_FEATURES + * and cause it to be corrupt. */ + features = rb_ary_resurrect(features); for (i = 0; i < RARRAY_LEN(features); i++) { VALUE entry, as_str; as_str = entry = rb_ary_entry(features, i); @@ -404,6 +409,10 @@ rb_ary_store(features, i, as_str); features_index_add(vm, as_str, INT2FIX(i)); } + /* The user modified $LOADED_FEATURES, so we should restore the changes. */ + if (!rb_ary_shared_with_p(features, vm->loaded_features)) { + rb_ary_replace(vm->loaded_features, features); + } reset_loaded_features_snapshot(vm); features = rb_ary_dup(vm->loaded_features_snapshot); @@ -1359,7 +1368,7 @@ int ruby_require_internal(const char *fname, unsigned int len) { - struct RString fake; + struct RString fake = {RBASIC_INIT}; VALUE str = rb_setup_fake_str(&fake, fname, len, 0); rb_execution_context_t *ec = GET_EC(); int result = require_internal(ec, str, 0, RTEST(ruby_verbose)); @@ -1393,7 +1402,7 @@ VALUE rb_require(const char *fname) { - struct RString fake; + struct RString fake = {RBASIC_INIT}; VALUE str = rb_setup_fake_str(&fake, fname, strlen(fname), 0); return rb_require_string_internal(str, true); } @@ -1552,7 +1561,7 @@ VALUE handle; VALUE resolved; VALUE path; - char *ext; + const char *ext; VALUE fname_str = rb_str_new_cstr(fname); resolved = rb_resolve_feature_path((VALUE)NULL, fname_str); diff -Nru ruby3.3-3.3.8/marshal.c ruby3.3-3.3.13/marshal.c --- ruby3.3-3.3.8/marshal.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/marshal.c 2026-10-23 03:17:41.000000000 +0000 @@ -40,6 +40,7 @@ #include "ruby/util.h" #include "builtin.h" #include "shape.h" +#include "ruby/internal/attr/nonstring.h" #define BITSPERSHORT (2*CHAR_BIT) #define SHORTMASK ((1<<BITSPERSHORT)-1) @@ -474,6 +475,31 @@ } } + +static VALUE +w_encivar(VALUE str, struct dump_arg *arg) +{ + VALUE encname = encoding_name(str, arg); + if (NIL_P(encname) || + is_ascii_string(str)) { + return Qnil; + } + w_byte(TYPE_IVAR, arg); + return encname; +} + +static void +w_encname(VALUE encname, struct dump_arg *arg) +{ + if (!NIL_P(encname)) { + struct dump_call_arg c_arg; + c_arg.limit = 1; + c_arg.arg = arg; + w_long(1L, arg); + w_encoding(encname, &c_arg); + } +} + static void w_symbol(VALUE sym, struct dump_arg *arg) { @@ -490,24 +516,11 @@ if (!sym) { rb_raise(rb_eTypeError, "can't dump anonymous ID %"PRIdVALUE, sym); } - encname = encoding_name(sym, arg); - if (NIL_P(encname) || - is_ascii_string(sym)) { - encname = Qnil; - } - else { - w_byte(TYPE_IVAR, arg); - } + encname = w_encivar(sym, arg); w_byte(TYPE_SYMBOL, arg); w_bytes(RSTRING_PTR(sym), RSTRING_LEN(sym), arg); st_add_direct(arg->symbols, orig_sym, arg->symbols->num_entries); - if (!NIL_P(encname)) { - struct dump_call_arg c_arg; - c_arg.limit = 1; - c_arg.arg = arg; - w_long(1L, arg); - w_encoding(encname, &c_arg); - } + w_encname(encname, arg); } } @@ -964,19 +977,23 @@ if (FL_TEST(obj, FL_SINGLETON)) { rb_raise(rb_eTypeError, "singleton class can't be dumped"); } - w_byte(TYPE_CLASS, arg); { VALUE path = class2path(obj); + VALUE encname = w_encivar(path, arg); + w_byte(TYPE_CLASS, arg); w_bytes(RSTRING_PTR(path), RSTRING_LEN(path), arg); + w_encname(encname, arg); RB_GC_GUARD(path); } break; case T_MODULE: - w_byte(TYPE_MODULE, arg); { VALUE path = class2path(obj); + VALUE encname = w_encivar(path, arg); + w_byte(TYPE_MODULE, arg); w_bytes(RSTRING_PTR(path), RSTRING_LEN(path), arg); + w_encname(encname, arg); RB_GC_GUARD(path); } break; @@ -1182,7 +1199,7 @@ * * anonymous Class/Module. * * objects which are related to system (ex: Dir, File::Stat, IO, File, Socket * and so on) - * * an instance of MatchData, Data, Method, UnboundMethod, Proc, Thread, + * * an instance of MatchData, Method, UnboundMethod, Proc, Thread, * ThreadGroup, Continuation * * objects which define singleton methods */ @@ -1421,7 +1438,7 @@ ruby_marshal_read_long(const char **buf, long len) { long x; - struct RString src; + struct RString src = {RBASIC_INIT}; struct load_arg arg; memset(&arg, 0, sizeof(arg)); arg.src = rb_setup_fake_str(&src, *buf, len, 0); @@ -1525,7 +1542,7 @@ static int sym2encidx(VALUE sym, VALUE val) { - static const char name_encoding[8] = "encoding"; + RBIMPL_ATTR_NONSTRING() static const char name_encoding[8] = "encoding"; const char *p; long l; if (rb_enc_get_index(sym) != ENCINDEX_US_ASCII) return -1; @@ -1713,6 +1730,34 @@ return v; } +static int +r_ivar_encoding(VALUE obj, struct load_arg *arg, VALUE sym, VALUE val) +{ + int idx = sym2encidx(sym, val); + if (idx >= 0) { + if (rb_enc_capable(obj)) { + rb_enc_associate_index(obj, idx); + } + else { + rb_raise(rb_eArgError, "%"PRIsVALUE" is not enc_capable", obj); + } + return TRUE; + } + return FALSE; +} + +static long +r_encname(VALUE obj, struct load_arg *arg) +{ + long len = r_long(arg); + if (len > 0) { + VALUE sym = r_symbol(arg); + VALUE val = r_object(arg); + len -= r_ivar_encoding(obj, arg, sym, val); + } + return len; +} + static void r_ivar(VALUE obj, int *has_encoding, struct load_arg *arg) { @@ -1723,14 +1768,7 @@ do { VALUE sym = r_symbol(arg); VALUE val = r_object(arg); - int idx = sym2encidx(sym, val); - if (idx >= 0) { - if (rb_enc_capable(obj)) { - rb_enc_associate_index(obj, idx); - } - else { - rb_raise(rb_eArgError, "%"PRIsVALUE" is not enc_capable", obj); - } + if (r_ivar_encoding(obj, arg, sym, val)) { if (has_encoding) *has_encoding = TRUE; } else if (symname_equal_lit(sym, name_s_ruby2_keywords_flag)) { @@ -1842,6 +1880,9 @@ } v = (VALUE)link; if (!st_lookup(arg->partial_objects, (st_data_t)v, &link)) { + if (arg->freeze && RB_TYPE_P(v, T_STRING)) { + v = rb_str_to_interned_str(v); + } v = r_post_proc(v, arg); } break; @@ -2256,6 +2297,7 @@ { VALUE str = r_bytes(arg); + if (ivp && *ivp > 0) *ivp = r_encname(str, arg) > 0; v = path2class(str); prohibit_ivar("class", str); v = r_entry(v, arg); @@ -2267,6 +2309,7 @@ { VALUE str = r_bytes(arg); + if (ivp && *ivp > 0) *ivp = r_encname(str, arg) > 0; v = path2module(str); prohibit_ivar("module", str); v = r_entry(v, arg); diff -Nru ruby3.3-3.3.8/miniprelude.c ruby3.3-3.3.13/miniprelude.c --- ruby3.3-3.3.8/miniprelude.c 2025-04-09 09:23:06.000000000 +0000 +++ ruby3.3-3.3.13/miniprelude.c 2026-10-23 03:17:43.000000000 +0000 @@ -7,6 +7,7 @@ #include "internal/ruby_parser.h" #include "internal/warnings.h" #include "iseq.h" +#include "ruby/internal/attr/nonstring.h" #include "ruby/ruby.h" #include "vm_core.h" @@ -17,11 +18,11 @@ static const char prelude_name0[] = "<internal:ast>"; static const struct { - char L0[508]; /* 1..88 */ - char L88[498]; /* 89..148 */ - char L148[491]; /* 149..191 */ - char L191[465]; /* 192..266 */ - char L266[242]; /* 267..277 */ + RBIMPL_ATTR_NONSTRING() char L0[508]; /* 1..88 */ + RBIMPL_ATTR_NONSTRING() char L88[498]; /* 89..148 */ + RBIMPL_ATTR_NONSTRING() char L148[491]; /* 149..191 */ + RBIMPL_ATTR_NONSTRING() char L191[465]; /* 192..266 */ + RBIMPL_ATTR_NONSTRING() char L266[242]; /* 267..277 */ } prelude_code0 = { #line 1 "ast.rb" ""/* for ast.c */ @@ -308,13 +309,13 @@ " end\n" " end\n" "end\n" -#line 312 "miniprelude.c" +#line 313 "miniprelude.c" }; static const char prelude_name1[] = "<internal:dir>"; static const struct { - char L0[508]; /* 1..266 */ - char L266[466]; /* 267..506 */ + RBIMPL_ATTR_NONSTRING() char L0[508]; /* 1..266 */ + RBIMPL_ATTR_NONSTRING() char L266[466]; /* 267..506 */ } prelude_code1 = { #line 1 "dir.rb" ""/* An object of class \\Dir represents a directory in the underlying file system. */ @@ -824,16 +825,16 @@ " end\n" " alias fnmatch? fnmatch\n" "end if false\n" -#line 828 "miniprelude.c" +#line 829 "miniprelude.c" }; static const char prelude_name2[] = "<internal:gc>"; static const struct { - char L0[498]; /* 1..76 */ - char L76[507]; /* 77..253 */ - char L253[506]; /* 254..299 */ - char L299[476]; /* 300..330 */ - char L330[39]; /* 331..333 */ + RBIMPL_ATTR_NONSTRING() char L0[498]; /* 1..76 */ + RBIMPL_ATTR_NONSTRING() char L76[507]; /* 77..253 */ + RBIMPL_ATTR_NONSTRING() char L253[506]; /* 254..299 */ + RBIMPL_ATTR_NONSTRING() char L299[476]; /* 300..330 */ + RBIMPL_ATTR_NONSTRING() char L330[39]; /* 331..333 */ } prelude_code2 = { #line 1 "gc.rb" ""/* for gc.c */ @@ -1176,16 +1177,16 @@ #line 331 "gc.rb" " module_function :garbage_collect\n" "end\n" -#line 1180 "miniprelude.c" +#line 1181 "miniprelude.c" }; static const char prelude_name3[] = "<internal:numeric>"; static const struct { - char L0[507]; /* 1..101 */ - char L101[508]; /* 102..200 */ - char L200[503]; /* 201..284 */ - char L284[507]; /* 285..357 */ - char L357[216]; /* 358..373 */ + RBIMPL_ATTR_NONSTRING() char L0[507]; /* 1..101 */ + RBIMPL_ATTR_NONSTRING() char L101[508]; /* 102..200 */ + RBIMPL_ATTR_NONSTRING() char L200[503]; /* 201..284 */ + RBIMPL_ATTR_NONSTRING() char L284[507]; /* 285..357 */ + RBIMPL_ATTR_NONSTRING() char L357[216]; /* 358..373 */ } prelude_code3 = { #line 1 "numeric.rb" "class Numeric\n" @@ -1568,12 +1569,12 @@ " end\n" "\n" "end\n" -#line 1572 "miniprelude.c" +#line 1573 "miniprelude.c" }; static const char prelude_name4[] = "<internal:io>"; static const struct { - char L0[449]; /* 1..137 */ + RBIMPL_ATTR_NONSTRING() char L0[449]; /* 1..137 */ } prelude_code4 = { #line 1 "io.rb" "class IO\n" @@ -1712,12 +1713,12 @@ " Primitive.io_readline(sep, limit, chomp)\n" " end\n" "end\n" -#line 1716 "miniprelude.c" +#line 1717 "miniprelude.c" }; static const char prelude_name5[] = "<internal:marshal>"; static const struct { - char L0[202]; /* 1..41 */ + RBIMPL_ATTR_NONSTRING() char L0[202]; /* 1..41 */ } prelude_code5 = { #line 1 "marshal.rb" "module Marshal\n" @@ -1760,13 +1761,13 @@ " alias restore load\n" " end\n" "end\n" -#line 1764 "miniprelude.c" +#line 1765 "miniprelude.c" }; static const char prelude_name6[] = "<internal:rjit>"; static const struct { - char L0[498]; /* 1..31 */ - char L31[197]; /* 32..42 */ + RBIMPL_ATTR_NONSTRING() char L0[498]; /* 1..31 */ + RBIMPL_ATTR_NONSTRING() char L31[197]; /* 32..42 */ } prelude_code6 = { #line 1 "rjit.rb" "module RubyVM::RJIT\n" @@ -1812,213 +1813,213 @@ " require 'ruby_vm/rjit/hooks'\n" " require 'ruby_vm/rjit/stats'\n" "end\n" -#line 1816 "miniprelude.c" +#line 1817 "miniprelude.c" }; static const char prelude_name7[] = "<internal:rjit_c>"; static const struct { - char L0[470]; /* 1..24 */ - char L24[506]; /* 25..45 */ - char L45[504]; /* 46..62 */ - char L62[499]; /* 63..78 */ - char L78[473]; /* 79..95 */ - char L95[480]; /* 96..109 */ - char L109[488]; /* 110..124 */ - char L124[478]; /* 125..144 */ - char L144[499]; /* 145..160 */ - char L160[474]; /* 161..175 */ - char L175[475]; /* 176..189 */ - char L189[470]; /* 190..201 */ - char L201[502]; /* 202..215 */ - char L215[499]; /* 216..232 */ - char L232[495]; /* 233..248 */ - char L248[488]; /* 249..271 */ - char L271[502]; /* 272..294 */ - char L294[413]; /* 295..311 */ - char L311[420]; /* 312..322 */ - char L322[503]; /* 323..343 */ - char L343[486]; /* 344..354 */ - char L354[456]; /* 355..362 */ - char L362[507]; /* 363..369 */ - char L369[488]; /* 370..375 */ - char L375[406]; /* 376..379 */ - char L379[445]; /* 380..384 */ - char L384[472]; /* 385..390 */ - char L390[454]; /* 391..396 */ - char L396[503]; /* 397..403 */ - char L403[483]; /* 404..410 */ - char L410[501]; /* 411..417 */ - char L417[460]; /* 418..423 */ - char L423[476]; /* 424..429 */ - char L429[498]; /* 430..435 */ - char L435[445]; /* 436..440 */ - char L440[502]; /* 441..446 */ - char L446[449]; /* 447..451 */ - char L451[508]; /* 452..468 */ - char L468[506]; /* 469..495 */ - char L495[493]; /* 496..518 */ - char L518[476]; /* 519..539 */ - char L539[508]; /* 540..559 */ - char L559[470]; /* 560..579 */ - char L579[455]; /* 580..599 */ - char L599[478]; /* 600..619 */ - char L619[473]; /* 620..639 */ - char L639[476]; /* 640..659 */ - char L659[507]; /* 660..679 */ - char L679[463]; /* 680..699 */ - char L699[487]; /* 700..719 */ - char L719[490]; /* 720..738 */ - char L738[499]; /* 739..758 */ - char L758[446]; /* 759..775 */ - char L775[471]; /* 776..795 */ - char L795[485]; /* 796..812 */ - char L812[430]; /* 813..819 */ - char L819[467]; /* 820..833 */ - char L833[492]; /* 834..844 */ - char L844[463]; /* 845..850 */ - char L850[477]; /* 851..861 */ - char L861[489]; /* 862..868 */ - char L868[493]; /* 869..880 */ - char L880[400]; /* 881..887 */ - char L887[504]; /* 888..900 */ - char L900[508]; /* 901..908 */ - char L908[408]; /* 909..912 */ - char L912[500]; /* 913..920 */ - char L920[457]; /* 921..928 */ - char L928[507]; /* 929..934 */ - char L934[496]; /* 935..950 */ - char L950[456]; /* 951..963 */ - char L963[379]; /* 964..966 */ - char L966[413]; /* 967..974 */ - char L974[461]; /* 975..982 */ - char L982[419]; /* 983..985 */ - char L985[446]; /* 986..993 */ - char L993[419]; /* 994..996 */ - char L996[459]; /* 997..1005 */ - char L1005[478]; /* 1006..1011 */ - char L1011[442]; /* 1012..1022 */ - char L1022[486]; /* 1023..1027 */ - char L1027[395]; /* 1028..1035 */ - char L1035[429]; /* 1036..1043 */ - char L1043[465]; /* 1044..1050 */ - char L1050[391]; /* 1051..1058 */ - char L1058[493]; /* 1059..1062 */ - char L1062[447]; /* 1063..1070 */ - char L1070[458]; /* 1071..1074 */ - char L1074[474]; /* 1075..1082 */ - char L1082[432]; /* 1083..1085 */ - char L1085[423]; /* 1086..1088 */ - char L1088[474]; /* 1089..1091 */ - char L1091[438]; /* 1092..1094 */ - char L1094[438]; /* 1095..1097 */ - char L1097[408]; /* 1098..1100 */ - char L1100[435]; /* 1101..1104 */ - char L1104[453]; /* 1105..1111 */ - char L1111[496]; /* 1112..1119 */ - char L1119[497]; /* 1120..1126 */ - char L1126[439]; /* 1127..1134 */ - char L1134[373]; /* 1135..1137 */ - char L1137[420]; /* 1138..1140 */ - char L1140[426]; /* 1141..1143 */ - char L1143[498]; /* 1144..1147 */ - char L1147[443]; /* 1148..1150 */ - char L1150[490]; /* 1151..1154 */ - char L1154[472]; /* 1155..1158 */ - char L1158[382]; /* 1159..1161 */ - char L1161[437]; /* 1162..1164 */ - char L1164[427]; /* 1165..1167 */ - char L1167[476]; /* 1168..1172 */ - char L1172[446]; /* 1173..1176 */ - char L1176[491]; /* 1177..1184 */ - char L1184[452]; /* 1185..1188 */ - char L1188[505]; /* 1189..1196 */ - char L1196[487]; /* 1197..1200 */ - char L1200[490]; /* 1201..1208 */ - char L1208[446]; /* 1209..1213 */ - char L1213[378]; /* 1214..1218 */ - char L1218[421]; /* 1219..1223 */ - char L1223[473]; /* 1224..1239 */ - char L1239[484]; /* 1240..1248 */ - char L1248[468]; /* 1249..1256 */ - char L1256[491]; /* 1257..1263 */ - char L1263[481]; /* 1264..1272 */ - char L1272[472]; /* 1273..1281 */ - char L1281[452]; /* 1282..1289 */ - char L1289[494]; /* 1290..1293 */ - char L1293[418]; /* 1294..1301 */ - char L1301[429]; /* 1302..1309 */ - char L1309[467]; /* 1310..1325 */ - char L1325[508]; /* 1326..1330 */ - char L1330[420]; /* 1331..1334 */ - char L1334[418]; /* 1335..1342 */ - char L1342[476]; /* 1343..1345 */ - char L1345[358]; /* 1346..1347 */ - char L1347[358]; /* 1348..1349 */ - char L1349[350]; /* 1350..1351 */ - char L1351[484]; /* 1352..1354 */ - char L1354[466]; /* 1355..1357 */ - char L1357[484]; /* 1358..1360 */ - char L1360[434]; /* 1361..1363 */ - char L1363[432]; /* 1364..1366 */ - char L1366[450]; /* 1367..1369 */ - char L1369[502]; /* 1370..1372 */ - char L1372[462]; /* 1373..1375 */ - char L1375[470]; /* 1376..1378 */ - char L1378[486]; /* 1379..1381 */ - char L1381[332]; /* 1382..1383 */ - char L1383[374]; /* 1384..1385 */ - char L1385[492]; /* 1386..1388 */ - char L1388[488]; /* 1389..1391 */ - char L1391[500]; /* 1392..1394 */ - char L1394[352]; /* 1395..1396 */ - char L1396[340]; /* 1397..1398 */ - char L1398[374]; /* 1399..1400 */ - char L1400[504]; /* 1401..1403 */ - char L1403[498]; /* 1404..1406 */ - char L1406[484]; /* 1407..1409 */ - char L1409[470]; /* 1410..1412 */ - char L1412[366]; /* 1413..1414 */ - char L1414[386]; /* 1415..1416 */ - char L1416[348]; /* 1417..1418 */ - char L1418[344]; /* 1419..1420 */ - char L1420[358]; /* 1421..1422 */ - char L1422[346]; /* 1423..1424 */ - char L1424[494]; /* 1425..1427 */ - char L1427[468]; /* 1428..1430 */ - char L1430[504]; /* 1431..1433 */ - char L1433[342]; /* 1434..1435 */ - char L1435[352]; /* 1436..1437 */ - char L1437[364]; /* 1438..1439 */ - char L1439[478]; /* 1440..1442 */ - char L1442[488]; /* 1443..1445 */ - char L1445[476]; /* 1446..1448 */ - char L1448[486]; /* 1449..1451 */ - char L1451[464]; /* 1452..1454 */ - char L1454[476]; /* 1455..1457 */ - char L1457[336]; /* 1458..1459 */ - char L1459[364]; /* 1460..1461 */ - char L1461[506]; /* 1462..1464 */ - char L1464[445]; /* 1465..1476 */ - char L1476[493]; /* 1477..1480 */ - char L1480[474]; /* 1481..1492 */ - char L1492[469]; /* 1493..1496 */ - char L1496[493]; /* 1497..1500 */ - char L1500[475]; /* 1501..1504 */ - char L1504[455]; /* 1505..1507 */ - char L1507[494]; /* 1508..1511 */ - char L1511[375]; /* 1512..1514 */ - char L1514[455]; /* 1515..1519 */ - char L1519[486]; /* 1520..1524 */ - char L1524[437]; /* 1525..1529 */ - char L1529[479]; /* 1530..1533 */ - char L1533[346]; /* 1534..1536 */ - char L1536[477]; /* 1537..1546 */ - char L1546[499]; /* 1547..1570 */ - char L1570[506]; /* 1571..1601 */ - char L1601[483]; /* 1602..1629 */ - char L1629[505]; /* 1630..1659 */ - char L1659[480]; /* 1660..1686 */ - char L1686[146]; /* 1687..1696 */ + RBIMPL_ATTR_NONSTRING() char L0[470]; /* 1..24 */ + RBIMPL_ATTR_NONSTRING() char L24[506]; /* 25..45 */ + RBIMPL_ATTR_NONSTRING() char L45[504]; /* 46..62 */ + RBIMPL_ATTR_NONSTRING() char L62[499]; /* 63..78 */ + RBIMPL_ATTR_NONSTRING() char L78[473]; /* 79..95 */ + RBIMPL_ATTR_NONSTRING() char L95[480]; /* 96..109 */ + RBIMPL_ATTR_NONSTRING() char L109[488]; /* 110..124 */ + RBIMPL_ATTR_NONSTRING() char L124[478]; /* 125..144 */ + RBIMPL_ATTR_NONSTRING() char L144[499]; /* 145..160 */ + RBIMPL_ATTR_NONSTRING() char L160[474]; /* 161..175 */ + RBIMPL_ATTR_NONSTRING() char L175[475]; /* 176..189 */ + RBIMPL_ATTR_NONSTRING() char L189[470]; /* 190..201 */ + RBIMPL_ATTR_NONSTRING() char L201[502]; /* 202..215 */ + RBIMPL_ATTR_NONSTRING() char L215[499]; /* 216..232 */ + RBIMPL_ATTR_NONSTRING() char L232[495]; /* 233..248 */ + RBIMPL_ATTR_NONSTRING() char L248[488]; /* 249..271 */ + RBIMPL_ATTR_NONSTRING() char L271[502]; /* 272..294 */ + RBIMPL_ATTR_NONSTRING() char L294[413]; /* 295..311 */ + RBIMPL_ATTR_NONSTRING() char L311[420]; /* 312..322 */ + RBIMPL_ATTR_NONSTRING() char L322[503]; /* 323..343 */ + RBIMPL_ATTR_NONSTRING() char L343[486]; /* 344..354 */ + RBIMPL_ATTR_NONSTRING() char L354[456]; /* 355..362 */ + RBIMPL_ATTR_NONSTRING() char L362[507]; /* 363..369 */ + RBIMPL_ATTR_NONSTRING() char L369[488]; /* 370..375 */ + RBIMPL_ATTR_NONSTRING() char L375[406]; /* 376..379 */ + RBIMPL_ATTR_NONSTRING() char L379[445]; /* 380..384 */ + RBIMPL_ATTR_NONSTRING() char L384[472]; /* 385..390 */ + RBIMPL_ATTR_NONSTRING() char L390[454]; /* 391..396 */ + RBIMPL_ATTR_NONSTRING() char L396[503]; /* 397..403 */ + RBIMPL_ATTR_NONSTRING() char L403[483]; /* 404..410 */ + RBIMPL_ATTR_NONSTRING() char L410[501]; /* 411..417 */ + RBIMPL_ATTR_NONSTRING() char L417[460]; /* 418..423 */ + RBIMPL_ATTR_NONSTRING() char L423[476]; /* 424..429 */ + RBIMPL_ATTR_NONSTRING() char L429[498]; /* 430..435 */ + RBIMPL_ATTR_NONSTRING() char L435[445]; /* 436..440 */ + RBIMPL_ATTR_NONSTRING() char L440[502]; /* 441..446 */ + RBIMPL_ATTR_NONSTRING() char L446[449]; /* 447..451 */ + RBIMPL_ATTR_NONSTRING() char L451[508]; /* 452..468 */ + RBIMPL_ATTR_NONSTRING() char L468[506]; /* 469..495 */ + RBIMPL_ATTR_NONSTRING() char L495[493]; /* 496..518 */ + RBIMPL_ATTR_NONSTRING() char L518[476]; /* 519..539 */ + RBIMPL_ATTR_NONSTRING() char L539[508]; /* 540..559 */ + RBIMPL_ATTR_NONSTRING() char L559[470]; /* 560..579 */ + RBIMPL_ATTR_NONSTRING() char L579[455]; /* 580..599 */ + RBIMPL_ATTR_NONSTRING() char L599[478]; /* 600..619 */ + RBIMPL_ATTR_NONSTRING() char L619[473]; /* 620..639 */ + RBIMPL_ATTR_NONSTRING() char L639[476]; /* 640..659 */ + RBIMPL_ATTR_NONSTRING() char L659[507]; /* 660..679 */ + RBIMPL_ATTR_NONSTRING() char L679[463]; /* 680..699 */ + RBIMPL_ATTR_NONSTRING() char L699[487]; /* 700..719 */ + RBIMPL_ATTR_NONSTRING() char L719[490]; /* 720..738 */ + RBIMPL_ATTR_NONSTRING() char L738[499]; /* 739..758 */ + RBIMPL_ATTR_NONSTRING() char L758[446]; /* 759..775 */ + RBIMPL_ATTR_NONSTRING() char L775[471]; /* 776..795 */ + RBIMPL_ATTR_NONSTRING() char L795[485]; /* 796..812 */ + RBIMPL_ATTR_NONSTRING() char L812[430]; /* 813..819 */ + RBIMPL_ATTR_NONSTRING() char L819[467]; /* 820..833 */ + RBIMPL_ATTR_NONSTRING() char L833[492]; /* 834..844 */ + RBIMPL_ATTR_NONSTRING() char L844[463]; /* 845..850 */ + RBIMPL_ATTR_NONSTRING() char L850[477]; /* 851..861 */ + RBIMPL_ATTR_NONSTRING() char L861[489]; /* 862..868 */ + RBIMPL_ATTR_NONSTRING() char L868[493]; /* 869..880 */ + RBIMPL_ATTR_NONSTRING() char L880[400]; /* 881..887 */ + RBIMPL_ATTR_NONSTRING() char L887[504]; /* 888..900 */ + RBIMPL_ATTR_NONSTRING() char L900[508]; /* 901..908 */ + RBIMPL_ATTR_NONSTRING() char L908[408]; /* 909..912 */ + RBIMPL_ATTR_NONSTRING() char L912[500]; /* 913..920 */ + RBIMPL_ATTR_NONSTRING() char L920[457]; /* 921..928 */ + RBIMPL_ATTR_NONSTRING() char L928[507]; /* 929..934 */ + RBIMPL_ATTR_NONSTRING() char L934[496]; /* 935..950 */ + RBIMPL_ATTR_NONSTRING() char L950[456]; /* 951..963 */ + RBIMPL_ATTR_NONSTRING() char L963[379]; /* 964..966 */ + RBIMPL_ATTR_NONSTRING() char L966[413]; /* 967..974 */ + RBIMPL_ATTR_NONSTRING() char L974[461]; /* 975..982 */ + RBIMPL_ATTR_NONSTRING() char L982[419]; /* 983..985 */ + RBIMPL_ATTR_NONSTRING() char L985[446]; /* 986..993 */ + RBIMPL_ATTR_NONSTRING() char L993[419]; /* 994..996 */ + RBIMPL_ATTR_NONSTRING() char L996[459]; /* 997..1005 */ + RBIMPL_ATTR_NONSTRING() char L1005[478]; /* 1006..1011 */ + RBIMPL_ATTR_NONSTRING() char L1011[442]; /* 1012..1022 */ + RBIMPL_ATTR_NONSTRING() char L1022[486]; /* 1023..1027 */ + RBIMPL_ATTR_NONSTRING() char L1027[395]; /* 1028..1035 */ + RBIMPL_ATTR_NONSTRING() char L1035[429]; /* 1036..1043 */ + RBIMPL_ATTR_NONSTRING() char L1043[465]; /* 1044..1050 */ + RBIMPL_ATTR_NONSTRING() char L1050[391]; /* 1051..1058 */ + RBIMPL_ATTR_NONSTRING() char L1058[493]; /* 1059..1062 */ + RBIMPL_ATTR_NONSTRING() char L1062[447]; /* 1063..1070 */ + RBIMPL_ATTR_NONSTRING() char L1070[458]; /* 1071..1074 */ + RBIMPL_ATTR_NONSTRING() char L1074[474]; /* 1075..1082 */ + RBIMPL_ATTR_NONSTRING() char L1082[432]; /* 1083..1085 */ + RBIMPL_ATTR_NONSTRING() char L1085[423]; /* 1086..1088 */ + RBIMPL_ATTR_NONSTRING() char L1088[474]; /* 1089..1091 */ + RBIMPL_ATTR_NONSTRING() char L1091[438]; /* 1092..1094 */ + RBIMPL_ATTR_NONSTRING() char L1094[438]; /* 1095..1097 */ + RBIMPL_ATTR_NONSTRING() char L1097[408]; /* 1098..1100 */ + RBIMPL_ATTR_NONSTRING() char L1100[435]; /* 1101..1104 */ + RBIMPL_ATTR_NONSTRING() char L1104[453]; /* 1105..1111 */ + RBIMPL_ATTR_NONSTRING() char L1111[496]; /* 1112..1119 */ + RBIMPL_ATTR_NONSTRING() char L1119[497]; /* 1120..1126 */ + RBIMPL_ATTR_NONSTRING() char L1126[439]; /* 1127..1134 */ + RBIMPL_ATTR_NONSTRING() char L1134[373]; /* 1135..1137 */ + RBIMPL_ATTR_NONSTRING() char L1137[420]; /* 1138..1140 */ + RBIMPL_ATTR_NONSTRING() char L1140[426]; /* 1141..1143 */ + RBIMPL_ATTR_NONSTRING() char L1143[498]; /* 1144..1147 */ + RBIMPL_ATTR_NONSTRING() char L1147[443]; /* 1148..1150 */ + RBIMPL_ATTR_NONSTRING() char L1150[490]; /* 1151..1154 */ + RBIMPL_ATTR_NONSTRING() char L1154[472]; /* 1155..1158 */ + RBIMPL_ATTR_NONSTRING() char L1158[382]; /* 1159..1161 */ + RBIMPL_ATTR_NONSTRING() char L1161[437]; /* 1162..1164 */ + RBIMPL_ATTR_NONSTRING() char L1164[427]; /* 1165..1167 */ + RBIMPL_ATTR_NONSTRING() char L1167[476]; /* 1168..1172 */ + RBIMPL_ATTR_NONSTRING() char L1172[446]; /* 1173..1176 */ + RBIMPL_ATTR_NONSTRING() char L1176[491]; /* 1177..1184 */ + RBIMPL_ATTR_NONSTRING() char L1184[452]; /* 1185..1188 */ + RBIMPL_ATTR_NONSTRING() char L1188[505]; /* 1189..1196 */ + RBIMPL_ATTR_NONSTRING() char L1196[487]; /* 1197..1200 */ + RBIMPL_ATTR_NONSTRING() char L1200[490]; /* 1201..1208 */ + RBIMPL_ATTR_NONSTRING() char L1208[446]; /* 1209..1213 */ + RBIMPL_ATTR_NONSTRING() char L1213[378]; /* 1214..1218 */ + RBIMPL_ATTR_NONSTRING() char L1218[421]; /* 1219..1223 */ + RBIMPL_ATTR_NONSTRING() char L1223[473]; /* 1224..1239 */ + RBIMPL_ATTR_NONSTRING() char L1239[484]; /* 1240..1248 */ + RBIMPL_ATTR_NONSTRING() char L1248[468]; /* 1249..1256 */ + RBIMPL_ATTR_NONSTRING() char L1256[491]; /* 1257..1263 */ + RBIMPL_ATTR_NONSTRING() char L1263[481]; /* 1264..1272 */ + RBIMPL_ATTR_NONSTRING() char L1272[472]; /* 1273..1281 */ + RBIMPL_ATTR_NONSTRING() char L1281[452]; /* 1282..1289 */ + RBIMPL_ATTR_NONSTRING() char L1289[494]; /* 1290..1293 */ + RBIMPL_ATTR_NONSTRING() char L1293[418]; /* 1294..1301 */ + RBIMPL_ATTR_NONSTRING() char L1301[429]; /* 1302..1309 */ + RBIMPL_ATTR_NONSTRING() char L1309[467]; /* 1310..1325 */ + RBIMPL_ATTR_NONSTRING() char L1325[508]; /* 1326..1330 */ + RBIMPL_ATTR_NONSTRING() char L1330[420]; /* 1331..1334 */ + RBIMPL_ATTR_NONSTRING() char L1334[418]; /* 1335..1342 */ + RBIMPL_ATTR_NONSTRING() char L1342[476]; /* 1343..1345 */ + RBIMPL_ATTR_NONSTRING() char L1345[358]; /* 1346..1347 */ + RBIMPL_ATTR_NONSTRING() char L1347[358]; /* 1348..1349 */ + RBIMPL_ATTR_NONSTRING() char L1349[350]; /* 1350..1351 */ + RBIMPL_ATTR_NONSTRING() char L1351[484]; /* 1352..1354 */ + RBIMPL_ATTR_NONSTRING() char L1354[466]; /* 1355..1357 */ + RBIMPL_ATTR_NONSTRING() char L1357[484]; /* 1358..1360 */ + RBIMPL_ATTR_NONSTRING() char L1360[434]; /* 1361..1363 */ + RBIMPL_ATTR_NONSTRING() char L1363[432]; /* 1364..1366 */ + RBIMPL_ATTR_NONSTRING() char L1366[450]; /* 1367..1369 */ + RBIMPL_ATTR_NONSTRING() char L1369[502]; /* 1370..1372 */ + RBIMPL_ATTR_NONSTRING() char L1372[462]; /* 1373..1375 */ + RBIMPL_ATTR_NONSTRING() char L1375[470]; /* 1376..1378 */ + RBIMPL_ATTR_NONSTRING() char L1378[486]; /* 1379..1381 */ + RBIMPL_ATTR_NONSTRING() char L1381[332]; /* 1382..1383 */ + RBIMPL_ATTR_NONSTRING() char L1383[374]; /* 1384..1385 */ + RBIMPL_ATTR_NONSTRING() char L1385[492]; /* 1386..1388 */ + RBIMPL_ATTR_NONSTRING() char L1388[488]; /* 1389..1391 */ + RBIMPL_ATTR_NONSTRING() char L1391[500]; /* 1392..1394 */ + RBIMPL_ATTR_NONSTRING() char L1394[352]; /* 1395..1396 */ + RBIMPL_ATTR_NONSTRING() char L1396[340]; /* 1397..1398 */ + RBIMPL_ATTR_NONSTRING() char L1398[374]; /* 1399..1400 */ + RBIMPL_ATTR_NONSTRING() char L1400[504]; /* 1401..1403 */ + RBIMPL_ATTR_NONSTRING() char L1403[498]; /* 1404..1406 */ + RBIMPL_ATTR_NONSTRING() char L1406[484]; /* 1407..1409 */ + RBIMPL_ATTR_NONSTRING() char L1409[470]; /* 1410..1412 */ + RBIMPL_ATTR_NONSTRING() char L1412[366]; /* 1413..1414 */ + RBIMPL_ATTR_NONSTRING() char L1414[386]; /* 1415..1416 */ + RBIMPL_ATTR_NONSTRING() char L1416[348]; /* 1417..1418 */ + RBIMPL_ATTR_NONSTRING() char L1418[344]; /* 1419..1420 */ + RBIMPL_ATTR_NONSTRING() char L1420[358]; /* 1421..1422 */ + RBIMPL_ATTR_NONSTRING() char L1422[346]; /* 1423..1424 */ + RBIMPL_ATTR_NONSTRING() char L1424[494]; /* 1425..1427 */ + RBIMPL_ATTR_NONSTRING() char L1427[468]; /* 1428..1430 */ + RBIMPL_ATTR_NONSTRING() char L1430[504]; /* 1431..1433 */ + RBIMPL_ATTR_NONSTRING() char L1433[342]; /* 1434..1435 */ + RBIMPL_ATTR_NONSTRING() char L1435[352]; /* 1436..1437 */ + RBIMPL_ATTR_NONSTRING() char L1437[364]; /* 1438..1439 */ + RBIMPL_ATTR_NONSTRING() char L1439[478]; /* 1440..1442 */ + RBIMPL_ATTR_NONSTRING() char L1442[488]; /* 1443..1445 */ + RBIMPL_ATTR_NONSTRING() char L1445[476]; /* 1446..1448 */ + RBIMPL_ATTR_NONSTRING() char L1448[486]; /* 1449..1451 */ + RBIMPL_ATTR_NONSTRING() char L1451[464]; /* 1452..1454 */ + RBIMPL_ATTR_NONSTRING() char L1454[476]; /* 1455..1457 */ + RBIMPL_ATTR_NONSTRING() char L1457[336]; /* 1458..1459 */ + RBIMPL_ATTR_NONSTRING() char L1459[364]; /* 1460..1461 */ + RBIMPL_ATTR_NONSTRING() char L1461[506]; /* 1462..1464 */ + RBIMPL_ATTR_NONSTRING() char L1464[445]; /* 1465..1476 */ + RBIMPL_ATTR_NONSTRING() char L1476[493]; /* 1477..1480 */ + RBIMPL_ATTR_NONSTRING() char L1480[474]; /* 1481..1492 */ + RBIMPL_ATTR_NONSTRING() char L1492[469]; /* 1493..1496 */ + RBIMPL_ATTR_NONSTRING() char L1496[493]; /* 1497..1500 */ + RBIMPL_ATTR_NONSTRING() char L1500[475]; /* 1501..1504 */ + RBIMPL_ATTR_NONSTRING() char L1504[455]; /* 1505..1507 */ + RBIMPL_ATTR_NONSTRING() char L1507[494]; /* 1508..1511 */ + RBIMPL_ATTR_NONSTRING() char L1511[375]; /* 1512..1514 */ + RBIMPL_ATTR_NONSTRING() char L1514[455]; /* 1515..1519 */ + RBIMPL_ATTR_NONSTRING() char L1519[486]; /* 1520..1524 */ + RBIMPL_ATTR_NONSTRING() char L1524[437]; /* 1525..1529 */ + RBIMPL_ATTR_NONSTRING() char L1529[479]; /* 1530..1533 */ + RBIMPL_ATTR_NONSTRING() char L1533[346]; /* 1534..1536 */ + RBIMPL_ATTR_NONSTRING() char L1536[477]; /* 1537..1546 */ + RBIMPL_ATTR_NONSTRING() char L1546[499]; /* 1547..1570 */ + RBIMPL_ATTR_NONSTRING() char L1570[506]; /* 1571..1601 */ + RBIMPL_ATTR_NONSTRING() char L1601[483]; /* 1602..1629 */ + RBIMPL_ATTR_NONSTRING() char L1629[505]; /* 1630..1659 */ + RBIMPL_ATTR_NONSTRING() char L1659[480]; /* 1660..1686 */ + RBIMPL_ATTR_NONSTRING() char L1686[146]; /* 1687..1696 */ } prelude_code7 = { #line 1 "rjit_c.rb" ""/* frozen_string_literal: true */ @@ -4118,12 +4119,12 @@ "\n" "\n"/* # RJIT bindgen end ### */ "end if Primitive.rjit_enabled_p\n" -#line 4122 "miniprelude.c" +#line 4123 "miniprelude.c" }; static const char prelude_name8[] = "<internal:pack>"; static const struct { - char L0[273]; /* 1..32 */ + RBIMPL_ATTR_NONSTRING() char L0[273]; /* 1..32 */ } prelude_code8 = { #line 1 "pack.rb" "class Array\n" @@ -4157,15 +4158,15 @@ " Primitive.pack_unpack1(fmt, offset)\n" " end\n" "end\n" -#line 4161 "miniprelude.c" +#line 4162 "miniprelude.c" }; static const char prelude_name9[] = "<internal:trace_point>"; static const struct { - char L0[508]; /* 1..237 */ - char L237[506]; /* 238..327 */ - char L327[495]; /* 328..401 */ - char L401[215]; /* 402..419 */ + RBIMPL_ATTR_NONSTRING() char L0[508]; /* 1..237 */ + RBIMPL_ATTR_NONSTRING() char L237[506]; /* 238..327 */ + RBIMPL_ATTR_NONSTRING() char L327[495]; /* 328..401 */ + RBIMPL_ATTR_NONSTRING() char L401[215]; /* 402..419 */ } prelude_code9 = { #line 1 "trace_point.rb" ""/* loaded from vm_trace.c */ @@ -4592,12 +4593,12 @@ " Primitive.tracepoint_attr_instruction_sequence\n" " end\n" "end\n" -#line 4596 "miniprelude.c" +#line 4597 "miniprelude.c" }; static const char prelude_name10[] = "<internal:warning>"; static const struct { - char L0[182]; /* 1..54 */ + RBIMPL_ATTR_NONSTRING() char L0[182]; /* 1..54 */ } prelude_code10 = { #line 1 "warning.rb" ""/* encoding: utf-8 */ @@ -4653,14 +4654,14 @@ " Primitive.rb_warn_m(msgs, uplevel, category)\n" " end\n" "end\n" -#line 4657 "miniprelude.c" +#line 4658 "miniprelude.c" }; static const char prelude_name11[] = "<internal:array>"; static const struct { - char L0[493]; /* 1..102 */ - char L102[478]; /* 103..150 */ - char L150[175]; /* 151..158 */ + RBIMPL_ATTR_NONSTRING() char L0[493]; /* 1..102 */ + RBIMPL_ATTR_NONSTRING() char L102[478]; /* 103..150 */ + RBIMPL_ATTR_NONSTRING() char L150[175]; /* 151..158 */ } prelude_code11 = { #line 1 "array.rb" "class Array\n" @@ -4824,14 +4825,14 @@ " end\n" " end\n" "end\n" -#line 4828 "miniprelude.c" +#line 4829 "miniprelude.c" }; static const char prelude_name12[] = "<internal:kernel>"; static const struct { - char L0[446]; /* 1..130 */ - char L130[508]; /* 131..192 */ - char L192[464]; /* 193..313 */ + RBIMPL_ATTR_NONSTRING() char L0[446]; /* 1..130 */ + RBIMPL_ATTR_NONSTRING() char L130[508]; /* 131..192 */ + RBIMPL_ATTR_NONSTRING() char L192[464]; /* 193..313 */ } prelude_code12 = { #line 1 "kernel.rb" "module Kernel\n" @@ -5150,19 +5151,19 @@ " end\n" " end\n" "end\n" -#line 5154 "miniprelude.c" +#line 5155 "miniprelude.c" }; static const char prelude_name13[] = "<internal:ractor>"; static const struct { - char L0[502]; /* 1..281 */ - char L281[503]; /* 282..360 */ - char L360[465]; /* 361..442 */ - char L442[508]; /* 443..620 */ - char L620[503]; /* 621..719 */ - char L719[485]; /* 720..767 */ - char L767[487]; /* 768..838 */ - char L838[230]; /* 839..854 */ + RBIMPL_ATTR_NONSTRING() char L0[502]; /* 1..281 */ + RBIMPL_ATTR_NONSTRING() char L281[503]; /* 282..360 */ + RBIMPL_ATTR_NONSTRING() char L360[465]; /* 361..442 */ + RBIMPL_ATTR_NONSTRING() char L442[508]; /* 443..620 */ + RBIMPL_ATTR_NONSTRING() char L620[503]; /* 621..719 */ + RBIMPL_ATTR_NONSTRING() char L719[485]; /* 720..767 */ + RBIMPL_ATTR_NONSTRING() char L767[487]; /* 768..838 */ + RBIMPL_ATTR_NONSTRING() char L838[230]; /* 839..854 */ } prelude_code13 = { #line 1 "ractor.rb" ""/* \\Ractor is an Actor-model abstraction for Ruby that provides thread-safe parallel execution. */ @@ -6032,12 +6033,12 @@ " }\n" " end\n" "end\n" -#line 6036 "miniprelude.c" +#line 6037 "miniprelude.c" }; static const char prelude_name14[] = "<internal:symbol>"; static const struct { - char L0[74]; /* 1..14 */ + RBIMPL_ATTR_NONSTRING() char L0[74]; /* 1..14 */ } prelude_code14 = { #line 1 "symbol.rb" "class Symbol\n" @@ -6053,14 +6054,14 @@ "\n" " alias intern to_sym\n" "end\n" -#line 6057 "miniprelude.c" +#line 6058 "miniprelude.c" }; static const char prelude_name15[] = "<internal:timev>"; static const struct { - char L0[477]; /* 1..394 */ - char L394[507]; /* 395..412 */ - char L412[78]; /* 413..416 */ + RBIMPL_ATTR_NONSTRING() char L0[477]; /* 1..394 */ + RBIMPL_ATTR_NONSTRING() char L394[507]; /* 395..412 */ + RBIMPL_ATTR_NONSTRING() char L412[78]; /* 413..416 */ } prelude_code15 = { #line 1 "timev.rb" ""/* A +Time+ object represents a date and time: */ @@ -6482,13 +6483,13 @@ " Primitive.time_init_args(year, mon, mday, hour, min, sec, zone)\n" " end\n" "end\n" -#line 6486 "miniprelude.c" +#line 6487 "miniprelude.c" }; static const char prelude_name16[] = "<internal:thread_sync>"; static const struct { - char L0[500]; /* 1..38 */ - char L38[446]; /* 39..69 */ + RBIMPL_ATTR_NONSTRING() char L0[500]; /* 1..38 */ + RBIMPL_ATTR_NONSTRING() char L38[446]; /* 39..69 */ } prelude_code16 = { #line 1 "thread_sync.rb" "class Thread\n" @@ -6561,12 +6562,12 @@ " alias_method :<<, :push\n" " end\n" "end\n" -#line 6565 "miniprelude.c" +#line 6566 "miniprelude.c" }; static const char prelude_name17[] = "<internal:nilclass>"; static const struct { - char L0[98]; /* 1..26 */ + RBIMPL_ATTR_NONSTRING() char L0[98]; /* 1..26 */ } prelude_code17 = { #line 1 "nilclass.rb" "class NilClass\n" @@ -6594,12 +6595,12 @@ " return 0.0\n" " end\n" "end\n" -#line 6598 "miniprelude.c" +#line 6599 "miniprelude.c" }; static const char prelude_name18[] = "<internal:prelude>"; static const struct { - char L0[352]; /* 1..32 */ + RBIMPL_ATTR_NONSTRING() char L0[352]; /* 1..32 */ } prelude_code18 = { #line 1 "prelude.rb" "class Binding\n" @@ -6633,13 +6634,13 @@ " klass.new(self, *args, &block)\n" " end unless instance_methods.include?(:to_set)\n"/* RJIT could already load this from builtin prelude */ "end\n" -#line 6637 "miniprelude.c" +#line 6638 "miniprelude.c" }; static const char prelude_name19[] = "<internal:gem_prelude>"; static const struct { - char L0[478]; /* 1..25 */ - char L25[74]; /* 26..29 */ + RBIMPL_ATTR_NONSTRING() char L0[478]; /* 1..25 */ + RBIMPL_ATTR_NONSTRING() char L25[74]; /* 26..29 */ } prelude_code19 = { #line 1 "gem_prelude.rb" "begin\n" @@ -6672,46 +6673,46 @@ " warn \"`syntax_suggest' was not loaded.\"\n" "end if defined?(SyntaxSuggest)\n" "\n" -#line 6676 "miniprelude.c" +#line 6677 "miniprelude.c" }; static const char prelude_name20[] = "<internal:yjit>"; static const struct { - char L0[506]; /* 1..39 */ - char L39[506]; /* 40..60 */ - char L60[496]; /* 61..90 */ - char L90[500]; /* 91..107 */ - char L107[459]; /* 108..152 */ - char L152[488]; /* 153..172 */ - char L172[488]; /* 173..192 */ - char L192[494]; /* 193..224 */ - char L224[474]; /* 225..251 */ - char L251[460]; /* 252..261 */ - char L261[411]; /* 262..265 */ - char L265[504]; /* 266..283 */ - char L283[493]; /* 284..297 */ - char L297[409]; /* 298..309 */ - char L309[444]; /* 310..313 */ - char L313[449]; /* 314..317 */ - char L317[457]; /* 318..323 */ - char L323[500]; /* 324..329 */ - char L329[505]; /* 330..335 */ - char L335[431]; /* 336..339 */ - char L339[471]; /* 340..345 */ - char L345[452]; /* 346..351 */ - char L351[476]; /* 352..357 */ - char L357[463]; /* 358..363 */ - char L363[468]; /* 364..368 */ - char L368[432]; /* 369..373 */ - char L373[491]; /* 374..381 */ - char L381[505]; /* 382..401 */ - char L401[440]; /* 402..413 */ - char L413[476]; /* 414..427 */ - char L427[505]; /* 428..437 */ - char L437[477]; /* 438..454 */ - char L454[461]; /* 455..469 */ - char L469[472]; /* 470..487 */ - char L487[244]; /* 488..496 */ + RBIMPL_ATTR_NONSTRING() char L0[506]; /* 1..39 */ + RBIMPL_ATTR_NONSTRING() char L39[506]; /* 40..60 */ + RBIMPL_ATTR_NONSTRING() char L60[496]; /* 61..90 */ + RBIMPL_ATTR_NONSTRING() char L90[500]; /* 91..107 */ + RBIMPL_ATTR_NONSTRING() char L107[459]; /* 108..152 */ + RBIMPL_ATTR_NONSTRING() char L152[488]; /* 153..172 */ + RBIMPL_ATTR_NONSTRING() char L172[488]; /* 173..192 */ + RBIMPL_ATTR_NONSTRING() char L192[494]; /* 193..224 */ + RBIMPL_ATTR_NONSTRING() char L224[474]; /* 225..251 */ + RBIMPL_ATTR_NONSTRING() char L251[460]; /* 252..261 */ + RBIMPL_ATTR_NONSTRING() char L261[411]; /* 262..265 */ + RBIMPL_ATTR_NONSTRING() char L265[504]; /* 266..283 */ + RBIMPL_ATTR_NONSTRING() char L283[493]; /* 284..297 */ + RBIMPL_ATTR_NONSTRING() char L297[409]; /* 298..309 */ + RBIMPL_ATTR_NONSTRING() char L309[444]; /* 310..313 */ + RBIMPL_ATTR_NONSTRING() char L313[449]; /* 314..317 */ + RBIMPL_ATTR_NONSTRING() char L317[457]; /* 318..323 */ + RBIMPL_ATTR_NONSTRING() char L323[500]; /* 324..329 */ + RBIMPL_ATTR_NONSTRING() char L329[505]; /* 330..335 */ + RBIMPL_ATTR_NONSTRING() char L335[431]; /* 336..339 */ + RBIMPL_ATTR_NONSTRING() char L339[471]; /* 340..345 */ + RBIMPL_ATTR_NONSTRING() char L345[452]; /* 346..351 */ + RBIMPL_ATTR_NONSTRING() char L351[476]; /* 352..357 */ + RBIMPL_ATTR_NONSTRING() char L357[463]; /* 358..363 */ + RBIMPL_ATTR_NONSTRING() char L363[468]; /* 364..368 */ + RBIMPL_ATTR_NONSTRING() char L368[432]; /* 369..373 */ + RBIMPL_ATTR_NONSTRING() char L373[491]; /* 374..381 */ + RBIMPL_ATTR_NONSTRING() char L381[505]; /* 382..401 */ + RBIMPL_ATTR_NONSTRING() char L401[440]; /* 402..413 */ + RBIMPL_ATTR_NONSTRING() char L413[476]; /* 414..427 */ + RBIMPL_ATTR_NONSTRING() char L427[505]; /* 428..437 */ + RBIMPL_ATTR_NONSTRING() char L437[477]; /* 438..454 */ + RBIMPL_ATTR_NONSTRING() char L454[461]; /* 455..469 */ + RBIMPL_ATTR_NONSTRING() char L469[472]; /* 470..487 */ + RBIMPL_ATTR_NONSTRING() char L487[244]; /* 488..496 */ } prelude_code20 = { #line 1 "yjit.rb" ""/* frozen_string_literal: true */ @@ -7277,7 +7278,7 @@ " end\n" " end\n" "end\n" -#line 7281 "miniprelude.c" +#line 7282 "miniprelude.c" }; COMPILER_WARNING_POP diff -Nru ruby3.3-3.3.8/numeric.c ruby3.3-3.3.13/numeric.c --- ruby3.3-3.3.8/numeric.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/numeric.c 2026-10-23 03:17:41.000000000 +0000 @@ -5487,7 +5487,7 @@ } bases = rb_ary_new(); - for (VALUE b = base; int_lt(b, num) == Qtrue; b = rb_int_mul(b, b)) { + for (VALUE b = base; int_le(b, num) == Qtrue; b = rb_int_mul(b, b)) { rb_ary_push(bases, b); } digits = rb_ary_new_from_args(1, num); diff -Nru ruby3.3-3.3.8/pack.c ruby3.3-3.3.13/pack.c --- ruby3.3-3.3.8/pack.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/pack.c 2026-10-23 03:17:41.000000000 +0000 @@ -287,7 +287,7 @@ else if (ISDIGIT(*p)) { errno = 0; len = STRTOUL(p, (char**)&p, 10); - if (errno) { + if (len < 0 || errno) { rb_raise(rb_eRangeError, "pack length too big"); } } diff -Nru ruby3.3-3.3.8/prism/util/pm_memchr.c ruby3.3-3.3.13/prism/util/pm_memchr.c --- ruby3.3-3.3.8/prism/util/pm_memchr.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/prism/util/pm_memchr.c 2026-10-23 03:17:41.000000000 +0000 @@ -7,7 +7,7 @@ * we need to search for a character in a buffer that could be the trailing byte * of a multibyte character. */ -void * +const void * pm_memchr(const void *memory, int character, size_t number, bool encoding_changed, const pm_encoding_t *encoding) { if (encoding_changed && encoding->multibyte && character >= PRISM_MEMCHR_TRAILING_BYTE_MINIMUM) { const uint8_t *source = (const uint8_t *) memory; diff -Nru ruby3.3-3.3.8/prism/util/pm_memchr.h ruby3.3-3.3.13/prism/util/pm_memchr.h --- ruby3.3-3.3.8/prism/util/pm_memchr.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/prism/util/pm_memchr.h 2026-10-23 03:17:41.000000000 +0000 @@ -24,6 +24,6 @@ * @return A pointer to the first occurrence of the character in the source * string, or NULL if no such character exists. */ -void * pm_memchr(const void *source, int character, size_t number, bool encoding_changed, const pm_encoding_t *encoding); +const void * pm_memchr(const void *source, int character, size_t number, bool encoding_changed, const pm_encoding_t *encoding); #endif diff -Nru ruby3.3-3.3.8/prism_compile.c ruby3.3-3.3.13/prism_compile.c --- ruby3.3-3.3.8/prism_compile.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/prism_compile.c 2026-10-23 03:17:41.000000000 +0000 @@ -2786,7 +2786,7 @@ int event = RUBY_EVENT_LINE; ISEQ_COMPILE_DATA(iseq)->last_line = lineno; - if (ISEQ_COVERAGE(iseq) && ISEQ_LINE_COVERAGE(iseq)) { + if (lineno > 0 && ISEQ_COVERAGE(iseq) && ISEQ_LINE_COVERAGE(iseq)) { event |= RUBY_EVENT_COVERAGE_LINE; } ADD_TRACE(ret, event); diff -Nru ruby3.3-3.3.8/proc.c ruby3.3-3.3.13/proc.c --- ruby3.3-3.3.8/proc.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/proc.c 2026-10-23 03:17:41.000000000 +0000 @@ -22,6 +22,7 @@ #include "method.h" #include "iseq.h" #include "vm_core.h" +#include "ractor_core.h" #include "yjit.h" const rb_cref_t *rb_vm_cref_in_context(VALUE self, VALUE cbase); @@ -1508,23 +1509,26 @@ long index; ID id; - if (!sym_proc_cache) { - sym_proc_cache = rb_ary_hidden_new(SYM_PROC_CACHE_SIZE * 2); - rb_gc_register_mark_object(sym_proc_cache); - rb_ary_store(sym_proc_cache, SYM_PROC_CACHE_SIZE*2 - 1, Qnil); - } - id = SYM2ID(sym); - index = (id % SYM_PROC_CACHE_SIZE) << 1; - if (RARRAY_AREF(sym_proc_cache, index) == sym) { - return RARRAY_AREF(sym_proc_cache, index + 1); - } - else { - proc = sym_proc_new(rb_cProc, ID2SYM(id)); - RARRAY_ASET(sym_proc_cache, index, sym); - RARRAY_ASET(sym_proc_cache, index + 1, proc); - return proc; + if (rb_ractor_main_p()) { + index = (id % SYM_PROC_CACHE_SIZE) << 1; + if (!sym_proc_cache) { + sym_proc_cache = rb_ary_hidden_new(SYM_PROC_CACHE_SIZE * 2); + rb_gc_register_mark_object(sym_proc_cache); + rb_ary_store(sym_proc_cache, SYM_PROC_CACHE_SIZE*2 - 1, Qnil); + } + if (RARRAY_AREF(sym_proc_cache, index) == sym) { + return RARRAY_AREF(sym_proc_cache, index + 1); + } + else { + proc = sym_proc_new(rb_cProc, ID2SYM(id)); + RARRAY_ASET(sym_proc_cache, index, sym); + RARRAY_ASET(sym_proc_cache, index + 1, proc); + return proc; + } + } else { + return sym_proc_new(rb_cProc, ID2SYM(id)); } } @@ -1827,6 +1831,8 @@ klass1 = method_entry_defined_class(m1->me); klass2 = method_entry_defined_class(m2->me); + if (RB_TYPE_P(klass1, T_ICLASS)) klass1 = RBASIC_CLASS(klass1); + if (RB_TYPE_P(klass2, T_ICLASS)) klass2 = RBASIC_CLASS(klass2); if (!rb_method_entry_eq(m1->me, m2->me) || klass1 != klass2 || @@ -3922,12 +3928,13 @@ switch (proc->block.type) { case block_type_iseq: if (ISEQ_BODY(proc->block.as.captured.code.iseq)->param.flags.has_rest && + !ISEQ_BODY(proc->block.as.captured.code.iseq)->param.flags.has_post && !ISEQ_BODY(proc->block.as.captured.code.iseq)->param.flags.has_kw && !ISEQ_BODY(proc->block.as.captured.code.iseq)->param.flags.has_kwrest) { ISEQ_BODY(proc->block.as.captured.code.iseq)->param.flags.ruby2_keywords = 1; } else { - rb_warn("Skipping set of ruby2_keywords flag for proc (proc accepts keywords or proc does not accept argument splat)"); + rb_warn("Skipping set of ruby2_keywords flag for proc (proc accepts keywords or post arguments or proc does not accept argument splat)"); } break; default: diff -Nru ruby3.3-3.3.8/ractor.c ruby3.3-3.3.13/ractor.c --- ruby3.3-3.3.8/ractor.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ractor.c 2026-10-23 03:17:41.000000000 +0000 @@ -216,6 +216,8 @@ rb_gc_mark(r->r_stdin); rb_gc_mark(r->r_stdout); rb_gc_mark(r->r_stderr); + rb_gc_mark(r->verbose); + rb_gc_mark(r->debug); rb_hook_list_mark(&r->pub.hooks); if (r->threads.cnt > 0) { diff -Nru ruby3.3-3.3.8/random.c ruby3.3-3.3.13/random.c --- ruby3.3-3.3.8/random.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/random.c 2026-10-23 03:17:41.000000000 +0000 @@ -437,23 +437,17 @@ # define USE_DEV_URANDOM 0 #endif -#ifdef HAVE_GETENTROPY -# define MAX_SEED_LEN_PER_READ 256 -static int -fill_random_bytes_urandom(void *seed, size_t size) -{ - unsigned char *p = (unsigned char *)seed; - while (size) { - size_t len = size < MAX_SEED_LEN_PER_READ ? size : MAX_SEED_LEN_PER_READ; - if (getentropy(p, len) != 0) { - return -1; - } - p += len; - size -= len; - } - return 0; -} -#elif USE_DEV_URANDOM +#if ! defined HAVE_GETRANDOM && defined __linux__ && defined __NR_getrandom +# ifndef GRND_NONBLOCK +# define GRND_NONBLOCK 0x0001 /* not defined in musl libc */ +# endif +# define getrandom(ptr, size, flags) \ + (ssize_t)syscall(__NR_getrandom, (ptr), (size), (flags)) +# define HAVE_GETRANDOM 1 +#endif + +/* fill random bytes by reading random device directly */ +#if USE_DEV_URANDOM static int fill_random_bytes_urandom(void *seed, size_t size) { @@ -493,15 +487,7 @@ # define fill_random_bytes_urandom(seed, size) -1 #endif -#if ! defined HAVE_GETRANDOM && defined __linux__ && defined __NR_getrandom -# ifndef GRND_NONBLOCK -# define GRND_NONBLOCK 0x0001 /* not defined in musl libc */ -# endif -# define getrandom(ptr, size, flags) \ - (ssize_t)syscall(__NR_getrandom, (ptr), (size), (flags)) -# define HAVE_GETRANDOM 1 -#endif - +/* fill random bytes by library */ #if 0 #elif defined MAC_OS_X_VERSION_10_7 && MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7 @@ -519,7 +505,7 @@ # endif static int -fill_random_bytes_syscall(void *seed, size_t size, int unused) +fill_random_bytes_lib(void *seed, size_t size) { #if USE_COMMON_RANDOM CCRNGStatus status = CCRandomGenerateBytes(seed, size); @@ -546,18 +532,16 @@ } return 0; } -#elif defined(HAVE_ARC4RANDOM_BUF) +#elif defined(HAVE_ARC4RANDOM_BUF) && \ + ((defined(__OpenBSD__) && OpenBSD >= 201411) || \ + (defined(__NetBSD__) && __NetBSD_Version__ >= 700000000) || \ + (defined(__FreeBSD__) && __FreeBSD_version >= 1200079)) +// [Bug #15039] arc4random_buf(3) should used only if we know it is fork-safe static int -fill_random_bytes_syscall(void *buf, size_t size, int unused) +fill_random_bytes_lib(void *buf, size_t size) { -#if (defined(__OpenBSD__) && OpenBSD >= 201411) || \ - (defined(__NetBSD__) && __NetBSD_Version__ >= 700000000) || \ - (defined(__FreeBSD__) && __FreeBSD_version >= 1200079) arc4random_buf(buf, size); return 0; -#else - return -1; -#endif } #elif defined(_WIN32) @@ -633,11 +617,17 @@ } static int -fill_random_bytes_syscall(void *seed, size_t size, int unused) +fill_random_bytes_lib(void *seed, size_t size) { if (fill_random_bytes_bcrypt(seed, size) == 0) return 0; return fill_random_bytes_crypt(seed, size); } +#else +# define fill_random_bytes_lib(seed, size) -1 +#endif + +/* fill random bytes by dedicated syscall */ +#if 0 #elif defined HAVE_GETRANDOM static int fill_random_bytes_syscall(void *seed, size_t size, int need_secure) @@ -661,6 +651,31 @@ } return -1; } +#elif defined(HAVE_GETENTROPY) +/* + * The Open Group Base Specifications Issue 8 - IEEE Std 1003.1-2024 + * https://pubs.opengroup.org/onlinepubs/9799919799/functions/getentropy.html + * + * NOTE: `getentropy`(3) on Linux is implemented using `getrandom`(2), + * prefer the latter over this if both are defined. + */ +#ifndef GETENTROPY_MAX +# define GETENTROPY_MAX 256 +#endif +static int +fill_random_bytes_syscall(void *seed, size_t size, int need_secure) +{ + unsigned char *p = (unsigned char *)seed; + while (size) { + size_t len = size < GETENTROPY_MAX ? size : GETENTROPY_MAX; + if (getentropy(p, len) != 0) { + return -1; + } + p += len; + size -= len; + } + return 0; +} #else # define fill_random_bytes_syscall(seed, size, need_secure) -1 #endif @@ -670,6 +685,7 @@ { int ret = fill_random_bytes_syscall(seed, size, need_secure); if (ret == 0) return ret; + if (fill_random_bytes_lib(seed, size) == 0) return 0; return fill_random_bytes_urandom(seed, size); } diff -Nru ruby3.3-3.3.8/regcomp.c ruby3.3-3.3.13/regcomp.c --- ruby3.3-3.3.8/regcomp.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/regcomp.c 2026-10-23 03:17:41.000000000 +0000 @@ -223,6 +223,10 @@ static int add_opcode(regex_t* reg, int opcode) { + /* Every instruction passes here, so this is where a program that would + outgrow its offset type is stopped, while it is still being emitted. */ + if (reg->used > MAX_COMPILED_PROGRAM_SIZE) + return ONIGERR_TOO_BIG_COMPILED_PROGRAM; BBUF_ADD1(reg, opcode); return 0; } @@ -394,6 +398,7 @@ r = add_mem_num(reg, reg->num_null_check); /* NULL CHECK ID */ if (r) return r; reg->num_null_check++; + if ((MemNumType)reg->num_null_check <= 0) return ONIGERR_TOO_MANY_NULL_CHECK; } r = compile_tree(node, reg); @@ -640,17 +645,17 @@ else { if (ONIGENC_MBC_MINLEN(reg->enc) > 1 || bitset_is_empty(cc->bs)) { if (IS_NCCLASS_NOT(cc)) - add_opcode(reg, OP_CCLASS_MB_NOT); + add_opcode(reg, OP_CCLASS_MB_NOT); else - add_opcode(reg, OP_CCLASS_MB); + add_opcode(reg, OP_CCLASS_MB); r = add_multi_byte_cclass(cc->mbuf, reg); } else { if (IS_NCCLASS_NOT(cc)) - add_opcode(reg, OP_CCLASS_MIX_NOT); + add_opcode(reg, OP_CCLASS_MIX_NOT); else - add_opcode(reg, OP_CCLASS_MIX); + add_opcode(reg, OP_CCLASS_MIX); r = add_bitset(reg, cc->bs); if (r) return r; @@ -703,6 +708,7 @@ if (r) return r; r = add_mem_num(reg, num_repeat); /* OP_REPEAT ID */ reg->num_repeat++; + if ((MemNumType)reg->num_repeat <= 0) return ONIGERR_TOO_MANY_RANGE_REPEAT; if (r) return r; r = add_rel_addr(reg, target_len + SIZE_OP_REPEAT_INC); if (r) return r; @@ -739,6 +745,10 @@ } #define QUANTIFIER_EXPAND_LIMIT_SIZE 50 +/* (tlen * n <= QUANTIFIER_EXPAND_LIMIT_SIZE) without overflowing int: tlen + and n are each bounded by ONIG_MAX_REPEAT_NUM, but their product is not. */ +#define IS_EXPAND_LIMIT_OK(tlen, n) \ + ((n) <= 0 || (tlen) <= QUANTIFIER_EXPAND_LIMIT_SIZE / (n)) #define CKN_ON (ckn > 0) #ifdef USE_COMBINATION_EXPLOSION_CHECK @@ -762,9 +772,9 @@ if (NTYPE(qn->target) == NT_CANY) { if (qn->greedy && infinite) { if (IS_NOT_NULL(qn->next_head_exact) && !CKN_ON) - return SIZE_OP_ANYCHAR_STAR_PEEK_NEXT + tlen * qn->lower + cklen; + return SIZE_OP_ANYCHAR_STAR_PEEK_NEXT + tlen * qn->lower + cklen; else - return SIZE_OP_ANYCHAR_STAR + tlen * qn->lower + cklen; + return SIZE_OP_ANYCHAR_STAR + tlen * qn->lower + cklen; } } @@ -776,17 +786,17 @@ if (infinite && qn->lower <= 1) { if (qn->greedy) { if (qn->lower == 1) - len = SIZE_OP_JUMP; + len = SIZE_OP_JUMP; else - len = 0; + len = 0; len += SIZE_OP_PUSH + cklen + mod_tlen + SIZE_OP_JUMP; } else { if (qn->lower == 0) - len = SIZE_OP_JUMP; + len = SIZE_OP_JUMP; else - len = 0; + len = 0; len += mod_tlen + SIZE_OP_PUSH + cklen; } @@ -800,10 +810,10 @@ else if (qn->upper == 1 && qn->greedy) { if (qn->lower == 0) { if (CKN_ON) { - len = SIZE_OP_STATE_CHECK_PUSH + tlen; + len = SIZE_OP_STATE_CHECK_PUSH + tlen; } else { - len = SIZE_OP_PUSH + tlen; + len = SIZE_OP_PUSH + tlen; } } else { @@ -841,31 +851,31 @@ if (r) return r; if (IS_NOT_NULL(qn->next_head_exact) && !CKN_ON) { if (IS_MULTILINE(reg->options)) - r = add_opcode(reg, OP_ANYCHAR_ML_STAR_PEEK_NEXT); + r = add_opcode(reg, OP_ANYCHAR_ML_STAR_PEEK_NEXT); else - r = add_opcode(reg, OP_ANYCHAR_STAR_PEEK_NEXT); + r = add_opcode(reg, OP_ANYCHAR_STAR_PEEK_NEXT); if (r) return r; if (CKN_ON) { - r = add_state_check_num(reg, ckn); - if (r) return r; + r = add_state_check_num(reg, ckn); + if (r) return r; } return add_bytes(reg, NSTR(qn->next_head_exact)->s, 1); } else { if (IS_MULTILINE(reg->options)) { - r = add_opcode(reg, (CKN_ON ? - OP_STATE_CHECK_ANYCHAR_ML_STAR - : OP_ANYCHAR_ML_STAR)); + r = add_opcode(reg, (CKN_ON ? + OP_STATE_CHECK_ANYCHAR_ML_STAR + : OP_ANYCHAR_ML_STAR)); } else { - r = add_opcode(reg, (CKN_ON ? - OP_STATE_CHECK_ANYCHAR_STAR - : OP_ANYCHAR_STAR)); + r = add_opcode(reg, (CKN_ON ? + OP_STATE_CHECK_ANYCHAR_STAR + : OP_ANYCHAR_STAR)); } if (r) return r; if (CKN_ON) - r = add_state_check_num(reg, ckn); + r = add_state_check_num(reg, ckn); return r; } @@ -879,45 +889,45 @@ if (infinite && qn->lower <= 1) { if (qn->greedy) { if (qn->lower == 1) { - r = add_opcode_rel_addr(reg, OP_JUMP, - (CKN_ON ? SIZE_OP_STATE_CHECK_PUSH : SIZE_OP_PUSH)); - if (r) return r; + r = add_opcode_rel_addr(reg, OP_JUMP, + (CKN_ON ? SIZE_OP_STATE_CHECK_PUSH : SIZE_OP_PUSH)); + if (r) return r; } if (CKN_ON) { - r = add_opcode(reg, OP_STATE_CHECK_PUSH); - if (r) return r; - r = add_state_check_num(reg, ckn); - if (r) return r; - r = add_rel_addr(reg, mod_tlen + SIZE_OP_JUMP); + r = add_opcode(reg, OP_STATE_CHECK_PUSH); + if (r) return r; + r = add_state_check_num(reg, ckn); + if (r) return r; + r = add_rel_addr(reg, mod_tlen + SIZE_OP_JUMP); } else { - r = add_opcode_rel_addr(reg, OP_PUSH, mod_tlen + SIZE_OP_JUMP); + r = add_opcode_rel_addr(reg, OP_PUSH, mod_tlen + SIZE_OP_JUMP); } if (r) return r; r = compile_tree_empty_check(qn->target, reg, empty_info); if (r) return r; r = add_opcode_rel_addr(reg, OP_JUMP, - -(mod_tlen + (int )SIZE_OP_JUMP - + (int )(CKN_ON ? SIZE_OP_STATE_CHECK_PUSH : SIZE_OP_PUSH))); + -(mod_tlen + (int )SIZE_OP_JUMP + + (int )(CKN_ON ? SIZE_OP_STATE_CHECK_PUSH : SIZE_OP_PUSH))); } else { if (qn->lower == 0) { - r = add_opcode_rel_addr(reg, OP_JUMP, mod_tlen); - if (r) return r; + r = add_opcode_rel_addr(reg, OP_JUMP, mod_tlen); + if (r) return r; } r = compile_tree_empty_check(qn->target, reg, empty_info); if (r) return r; if (CKN_ON) { - r = add_opcode(reg, OP_STATE_CHECK_PUSH_OR_JUMP); - if (r) return r; - r = add_state_check_num(reg, ckn); - if (r) return r; - r = add_rel_addr(reg, - -(mod_tlen + (int )SIZE_OP_STATE_CHECK_PUSH_OR_JUMP)); + r = add_opcode(reg, OP_STATE_CHECK_PUSH_OR_JUMP); + if (r) return r; + r = add_state_check_num(reg, ckn); + if (r) return r; + r = add_rel_addr(reg, + -(mod_tlen + (int )SIZE_OP_STATE_CHECK_PUSH_OR_JUMP)); } else - r = add_opcode_rel_addr(reg, OP_PUSH, -(mod_tlen + (int )SIZE_OP_PUSH)); + r = add_opcode_rel_addr(reg, OP_PUSH, -(mod_tlen + (int )SIZE_OP_PUSH)); } } else if (qn->upper == 0) { @@ -932,14 +942,14 @@ else if (qn->upper == 1 && qn->greedy) { if (qn->lower == 0) { if (CKN_ON) { - r = add_opcode(reg, OP_STATE_CHECK_PUSH); - if (r) return r; - r = add_state_check_num(reg, ckn); - if (r) return r; - r = add_rel_addr(reg, tlen); + r = add_opcode(reg, OP_STATE_CHECK_PUSH); + if (r) return r; + r = add_state_check_num(reg, ckn); + if (r) return r; + r = add_rel_addr(reg, tlen); } else { - r = add_opcode_rel_addr(reg, OP_PUSH, tlen); + r = add_opcode_rel_addr(reg, OP_PUSH, tlen); } if (r) return r; } @@ -991,9 +1001,9 @@ if (NTYPE(qn->target) == NT_CANY) { if (qn->greedy && infinite) { if (IS_NOT_NULL(qn->next_head_exact)) - return SIZE_OP_ANYCHAR_STAR_PEEK_NEXT + tlen * qn->lower; + return SIZE_OP_ANYCHAR_STAR_PEEK_NEXT + tlen * qn->lower; else - return SIZE_OP_ANYCHAR_STAR + tlen * qn->lower; + return SIZE_OP_ANYCHAR_STAR + tlen * qn->lower; } } @@ -1003,7 +1013,7 @@ mod_tlen = tlen; if (infinite && - (qn->lower <= 1 || tlen * qn->lower <= QUANTIFIER_EXPAND_LIMIT_SIZE)) { + (qn->lower <= 1 || IS_EXPAND_LIMIT_OK(tlen, qn->lower))) { if (qn->lower == 1 && tlen > QUANTIFIER_EXPAND_LIMIT_SIZE) { len = SIZE_OP_JUMP; } @@ -1014,13 +1024,13 @@ if (qn->greedy) { #ifdef USE_OP_PUSH_OR_JUMP_EXACT if (IS_NOT_NULL(qn->head_exact)) - len += SIZE_OP_PUSH_OR_JUMP_EXACT1 + mod_tlen + SIZE_OP_JUMP; + len += SIZE_OP_PUSH_OR_JUMP_EXACT1 + mod_tlen + SIZE_OP_JUMP; else #endif if (IS_NOT_NULL(qn->next_head_exact)) - len += SIZE_OP_PUSH_IF_PEEK_NEXT + mod_tlen + SIZE_OP_JUMP; + len += SIZE_OP_PUSH_IF_PEEK_NEXT + mod_tlen + SIZE_OP_JUMP; else - len += SIZE_OP_PUSH + mod_tlen + SIZE_OP_JUMP; + len += SIZE_OP_PUSH + mod_tlen + SIZE_OP_JUMP; } else len += SIZE_OP_JUMP + mod_tlen + SIZE_OP_PUSH; @@ -1029,8 +1039,8 @@ len = SIZE_OP_JUMP + tlen; } else if (!infinite && qn->greedy && - (qn->upper == 1 || (tlen + SIZE_OP_PUSH) * qn->upper - <= QUANTIFIER_EXPAND_LIMIT_SIZE)) { + (qn->upper == 1 || + IS_EXPAND_LIMIT_OK(tlen + SIZE_OP_PUSH, qn->upper))) { len = tlen * qn->lower; len += (SIZE_OP_PUSH + tlen) * (qn->upper - qn->lower); } @@ -1060,17 +1070,17 @@ if (r) return r; if (IS_NOT_NULL(qn->next_head_exact)) { if (IS_MULTILINE(reg->options)) - r = add_opcode(reg, OP_ANYCHAR_ML_STAR_PEEK_NEXT); + r = add_opcode(reg, OP_ANYCHAR_ML_STAR_PEEK_NEXT); else - r = add_opcode(reg, OP_ANYCHAR_STAR_PEEK_NEXT); + r = add_opcode(reg, OP_ANYCHAR_STAR_PEEK_NEXT); if (r) return r; return add_bytes(reg, NSTR(qn->next_head_exact)->s, 1); } else { if (IS_MULTILINE(reg->options)) - return add_opcode(reg, OP_ANYCHAR_ML_STAR); + return add_opcode(reg, OP_ANYCHAR_ML_STAR); else - return add_opcode(reg, OP_ANYCHAR_STAR); + return add_opcode(reg, OP_ANYCHAR_STAR); } } @@ -1080,21 +1090,21 @@ mod_tlen = tlen; if (infinite && - (qn->lower <= 1 || tlen * qn->lower <= QUANTIFIER_EXPAND_LIMIT_SIZE)) { + (qn->lower <= 1 || IS_EXPAND_LIMIT_OK(tlen, qn->lower))) { if (qn->lower == 1 && tlen > QUANTIFIER_EXPAND_LIMIT_SIZE) { if (qn->greedy) { #ifdef USE_OP_PUSH_OR_JUMP_EXACT - if (IS_NOT_NULL(qn->head_exact)) - r = add_opcode_rel_addr(reg, OP_JUMP, SIZE_OP_PUSH_OR_JUMP_EXACT1); - else -#endif - if (IS_NOT_NULL(qn->next_head_exact)) - r = add_opcode_rel_addr(reg, OP_JUMP, SIZE_OP_PUSH_IF_PEEK_NEXT); - else - r = add_opcode_rel_addr(reg, OP_JUMP, SIZE_OP_PUSH); + if (IS_NOT_NULL(qn->head_exact)) + r = add_opcode_rel_addr(reg, OP_JUMP, SIZE_OP_PUSH_OR_JUMP_EXACT1); + else +#endif + if (IS_NOT_NULL(qn->next_head_exact)) + r = add_opcode_rel_addr(reg, OP_JUMP, SIZE_OP_PUSH_IF_PEEK_NEXT); + else + r = add_opcode_rel_addr(reg, OP_JUMP, SIZE_OP_PUSH); } else { - r = add_opcode_rel_addr(reg, OP_JUMP, SIZE_OP_JUMP); + r = add_opcode_rel_addr(reg, OP_JUMP, SIZE_OP_JUMP); } if (r) return r; } @@ -1106,34 +1116,34 @@ if (qn->greedy) { #ifdef USE_OP_PUSH_OR_JUMP_EXACT if (IS_NOT_NULL(qn->head_exact)) { - r = add_opcode_rel_addr(reg, OP_PUSH_OR_JUMP_EXACT1, - mod_tlen + SIZE_OP_JUMP); - if (r) return r; - add_bytes(reg, NSTR(qn->head_exact)->s, 1); - r = compile_tree_empty_check(qn->target, reg, empty_info); - if (r) return r; - r = add_opcode_rel_addr(reg, OP_JUMP, - -(mod_tlen + (int )SIZE_OP_JUMP + (int )SIZE_OP_PUSH_OR_JUMP_EXACT1)); + r = add_opcode_rel_addr(reg, OP_PUSH_OR_JUMP_EXACT1, + mod_tlen + SIZE_OP_JUMP); + if (r) return r; + add_bytes(reg, NSTR(qn->head_exact)->s, 1); + r = compile_tree_empty_check(qn->target, reg, empty_info); + if (r) return r; + r = add_opcode_rel_addr(reg, OP_JUMP, + -(mod_tlen + (int )SIZE_OP_JUMP + (int )SIZE_OP_PUSH_OR_JUMP_EXACT1)); } else #endif if (IS_NOT_NULL(qn->next_head_exact)) { - r = add_opcode_rel_addr(reg, OP_PUSH_IF_PEEK_NEXT, - mod_tlen + SIZE_OP_JUMP); - if (r) return r; - add_bytes(reg, NSTR(qn->next_head_exact)->s, 1); - r = compile_tree_empty_check(qn->target, reg, empty_info); - if (r) return r; - r = add_opcode_rel_addr(reg, OP_JUMP, + r = add_opcode_rel_addr(reg, OP_PUSH_IF_PEEK_NEXT, + mod_tlen + SIZE_OP_JUMP); + if (r) return r; + add_bytes(reg, NSTR(qn->next_head_exact)->s, 1); + r = compile_tree_empty_check(qn->target, reg, empty_info); + if (r) return r; + r = add_opcode_rel_addr(reg, OP_JUMP, -(mod_tlen + (int )SIZE_OP_JUMP + (int )SIZE_OP_PUSH_IF_PEEK_NEXT)); } else { - r = add_opcode_rel_addr(reg, OP_PUSH, mod_tlen + SIZE_OP_JUMP); - if (r) return r; - r = compile_tree_empty_check(qn->target, reg, empty_info); - if (r) return r; - r = add_opcode_rel_addr(reg, OP_JUMP, - -(mod_tlen + (int )SIZE_OP_JUMP + (int )SIZE_OP_PUSH)); + r = add_opcode_rel_addr(reg, OP_PUSH, mod_tlen + SIZE_OP_JUMP); + if (r) return r; + r = compile_tree_empty_check(qn->target, reg, empty_info); + if (r) return r; + r = add_opcode_rel_addr(reg, OP_JUMP, + -(mod_tlen + (int )SIZE_OP_JUMP + (int )SIZE_OP_PUSH)); } } else { @@ -1150,8 +1160,8 @@ r = compile_tree(qn->target, reg); } else if (!infinite && qn->greedy && - (qn->upper == 1 || (tlen + SIZE_OP_PUSH) * qn->upper - <= QUANTIFIER_EXPAND_LIMIT_SIZE)) { + (qn->upper == 1 || + IS_EXPAND_LIMIT_OK(tlen + SIZE_OP_PUSH, qn->upper))) { int n = qn->upper - qn->lower; r = compile_tree_n_times(qn->target, qn->lower, reg); @@ -1159,7 +1169,7 @@ for (i = 0; i < n; i++) { r = add_opcode_rel_addr(reg, OP_PUSH, - (n - i) * tlen + (n - i - 1) * SIZE_OP_PUSH); + (n - i) * tlen + (n - i - 1) * SIZE_OP_PUSH); if (r) return r; r = compile_tree(qn->target, reg); if (r) return r; @@ -1246,29 +1256,29 @@ #ifdef USE_SUBEXP_CALL if (IS_ENCLOSE_CALLED(node)) { len = SIZE_OP_MEMORY_START_PUSH + tlen - + SIZE_OP_CALL + SIZE_OP_JUMP + SIZE_OP_RETURN; + + SIZE_OP_CALL + SIZE_OP_JUMP + SIZE_OP_RETURN; if (BIT_STATUS_AT(reg->bt_mem_end, node->regnum)) - len += (IS_ENCLOSE_RECURSION(node) - ? SIZE_OP_MEMORY_END_PUSH_REC : SIZE_OP_MEMORY_END_PUSH); + len += (IS_ENCLOSE_RECURSION(node) + ? SIZE_OP_MEMORY_END_PUSH_REC : SIZE_OP_MEMORY_END_PUSH); else - len += (IS_ENCLOSE_RECURSION(node) - ? SIZE_OP_MEMORY_END_REC : SIZE_OP_MEMORY_END); + len += (IS_ENCLOSE_RECURSION(node) + ? SIZE_OP_MEMORY_END_REC : SIZE_OP_MEMORY_END); } else if (IS_ENCLOSE_RECURSION(node)) { len = SIZE_OP_MEMORY_START_PUSH; len += tlen + (BIT_STATUS_AT(reg->bt_mem_end, node->regnum) - ? SIZE_OP_MEMORY_END_PUSH_REC : SIZE_OP_MEMORY_END_REC); + ? SIZE_OP_MEMORY_END_PUSH_REC : SIZE_OP_MEMORY_END_REC); } else #endif { if (BIT_STATUS_AT(reg->bt_mem_start, node->regnum)) - len = SIZE_OP_MEMORY_START_PUSH; + len = SIZE_OP_MEMORY_START_PUSH; else - len = SIZE_OP_MEMORY_START; + len = SIZE_OP_MEMORY_START; len += tlen + (BIT_STATUS_AT(reg->bt_mem_end, node->regnum) - ? SIZE_OP_MEMORY_END_PUSH : SIZE_OP_MEMORY_END); + ? SIZE_OP_MEMORY_END_PUSH : SIZE_OP_MEMORY_END); } break; @@ -1283,7 +1293,7 @@ if (tlen < 0) return tlen; len = tlen * qn->lower - + SIZE_OP_PUSH + tlen + SIZE_OP_POP + SIZE_OP_JUMP; + + SIZE_OP_PUSH + tlen + SIZE_OP_POP + SIZE_OP_JUMP; } else { #endif @@ -1348,11 +1358,11 @@ len = compile_length_tree(node->target, reg); len += (SIZE_OP_MEMORY_START_PUSH + SIZE_OP_RETURN); if (BIT_STATUS_AT(reg->bt_mem_end, node->regnum)) - len += (IS_ENCLOSE_RECURSION(node) - ? SIZE_OP_MEMORY_END_PUSH_REC : SIZE_OP_MEMORY_END_PUSH); + len += (IS_ENCLOSE_RECURSION(node) + ? SIZE_OP_MEMORY_END_PUSH_REC : SIZE_OP_MEMORY_END_PUSH); else - len += (IS_ENCLOSE_RECURSION(node) - ? SIZE_OP_MEMORY_END_REC : SIZE_OP_MEMORY_END); + len += (IS_ENCLOSE_RECURSION(node) + ? SIZE_OP_MEMORY_END_REC : SIZE_OP_MEMORY_END); r = add_opcode_rel_addr(reg, OP_JUMP, len); if (r) return r; @@ -1370,11 +1380,11 @@ #ifdef USE_SUBEXP_CALL if (IS_ENCLOSE_CALLED(node)) { if (BIT_STATUS_AT(reg->bt_mem_end, node->regnum)) - r = add_opcode(reg, (IS_ENCLOSE_RECURSION(node) - ? OP_MEMORY_END_PUSH_REC : OP_MEMORY_END_PUSH)); + r = add_opcode(reg, (IS_ENCLOSE_RECURSION(node) + ? OP_MEMORY_END_PUSH_REC : OP_MEMORY_END_PUSH)); else - r = add_opcode(reg, (IS_ENCLOSE_RECURSION(node) - ? OP_MEMORY_END_REC : OP_MEMORY_END)); + r = add_opcode(reg, (IS_ENCLOSE_RECURSION(node) + ? OP_MEMORY_END_REC : OP_MEMORY_END)); if (r) return r; r = add_mem_num(reg, node->regnum); @@ -1383,9 +1393,9 @@ } else if (IS_ENCLOSE_RECURSION(node)) { if (BIT_STATUS_AT(reg->bt_mem_end, node->regnum)) - r = add_opcode(reg, OP_MEMORY_END_PUSH_REC); + r = add_opcode(reg, OP_MEMORY_END_PUSH_REC); else - r = add_opcode(reg, OP_MEMORY_END_REC); + r = add_opcode(reg, OP_MEMORY_END_REC); if (r) return r; r = add_mem_num(reg, node->regnum); } @@ -1393,9 +1403,9 @@ #endif { if (BIT_STATUS_AT(reg->bt_mem_end, node->regnum)) - r = add_opcode(reg, OP_MEMORY_END_PUSH); + r = add_opcode(reg, OP_MEMORY_END_PUSH); else - r = add_opcode(reg, OP_MEMORY_END); + r = add_opcode(reg, OP_MEMORY_END); if (r) return r; r = add_mem_num(reg, node->regnum); } @@ -1421,7 +1431,7 @@ r = add_opcode(reg, OP_POP); if (r) return r; r = add_opcode_rel_addr(reg, OP_JUMP, - -((int )SIZE_OP_PUSH + len + (int )SIZE_OP_POP + (int )SIZE_OP_JUMP)); + -((int )SIZE_OP_PUSH + len + (int )SIZE_OP_POP + (int )SIZE_OP_JUMP)); } else { #endif @@ -1579,11 +1589,11 @@ r = add_opcode(reg, OP_LOOK_BEHIND); if (r) return r; if (node->char_len < 0) { - r = get_char_length_tree(node->target, reg, &n); - if (r) return ONIGERR_INVALID_LOOK_BEHIND_PATTERN; + r = get_char_length_tree(node->target, reg, &n); + if (r) return ONIGERR_INVALID_LOOK_BEHIND_PATTERN; } else - n = node->char_len; + n = node->char_len; r = add_length(reg, n); if (r) return r; r = compile_tree(node->target, reg); @@ -1595,14 +1605,14 @@ int n; len = compile_length_tree(node->target, reg); r = add_opcode_rel_addr(reg, OP_PUSH_LOOK_BEHIND_NOT, - len + SIZE_OP_FAIL_LOOK_BEHIND_NOT); + len + SIZE_OP_FAIL_LOOK_BEHIND_NOT); if (r) return r; if (node->char_len < 0) { - r = get_char_length_tree(node->target, reg, &n); - if (r) return ONIGERR_INVALID_LOOK_BEHIND_PATTERN; + r = get_char_length_tree(node->target, reg, &n); + if (r) return ONIGERR_INVALID_LOOK_BEHIND_PATTERN; } else - n = node->char_len; + n = node->char_len; r = add_length(reg, n); if (r) return r; r = compile_tree(node->target, reg); @@ -1641,10 +1651,10 @@ int n = 0; len = 0; do { - r = compile_length_tree(NCAR(node), reg); - if (r < 0) return r; - len += r; - n++; + r = compile_length_tree(NCAR(node), reg); + if (r < 0) return r; + len += r; + n++; } while (IS_NOT_NULL(node = NCDR(node))); r = len; r += (SIZE_OP_PUSH + SIZE_OP_JUMP) * (n - 1); @@ -1673,17 +1683,17 @@ #ifdef USE_BACKREF_WITH_LEVEL if (IS_BACKREF_NEST_LEVEL(br)) { - r = SIZE_OPCODE + SIZE_OPTION + SIZE_LENGTH + + r = SIZE_OPCODE + SIZE_OPTION + SIZE_LENGTH + SIZE_LENGTH + (SIZE_MEMNUM * br->back_num); } else #endif if (br->back_num == 1) { - r = ((!IS_IGNORECASE(reg->options) && br->back_static[0] <= 2) - ? SIZE_OPCODE : (SIZE_OPCODE + SIZE_MEMNUM)); + r = ((!IS_IGNORECASE(reg->options) && br->back_static[0] <= 2) + ? SIZE_OPCODE : (SIZE_OPCODE + SIZE_MEMNUM)); } else { - r = SIZE_OPCODE + SIZE_LENGTH + (SIZE_MEMNUM * br->back_num); + r = SIZE_OPCODE + SIZE_LENGTH + (SIZE_MEMNUM * br->back_num); } } break; @@ -1732,26 +1742,26 @@ Node* x = node; len = 0; do { - len += compile_length_tree(NCAR(x), reg); - if (NCDR(x) != NULL) { - len += SIZE_OP_PUSH + SIZE_OP_JUMP; - } + len += compile_length_tree(NCAR(x), reg); + if (NCDR(x) != NULL) { + len += SIZE_OP_PUSH + SIZE_OP_JUMP; + } } while (IS_NOT_NULL(x = NCDR(x))); pos = reg->used + len; /* goal position */ do { - len = compile_length_tree(NCAR(node), reg); - if (IS_NOT_NULL(NCDR(node))) { - r = add_opcode_rel_addr(reg, OP_PUSH, len + SIZE_OP_JUMP); - if (r) break; - } - r = compile_tree(NCAR(node), reg); - if (r) break; - if (IS_NOT_NULL(NCDR(node))) { - len = pos - (reg->used + SIZE_OP_JUMP); - r = add_opcode_rel_addr(reg, OP_JUMP, len); - if (r) break; - } + len = compile_length_tree(NCAR(node), reg); + if (IS_NOT_NULL(NCDR(node))) { + r = add_opcode_rel_addr(reg, OP_PUSH, len + SIZE_OP_JUMP); + if (r) break; + } + r = compile_tree(NCAR(node), reg); + if (r) break; + if (IS_NOT_NULL(NCDR(node))) { + len = pos - (reg->used + SIZE_OP_JUMP); + r = add_opcode_rel_addr(reg, OP_JUMP, len); + if (r) break; + } } while (IS_NOT_NULL(node = NCDR(node))); } break; @@ -1773,18 +1783,18 @@ switch (NCTYPE(node)->ctype) { case ONIGENC_CTYPE_WORD: - if (NCTYPE(node)->ascii_range != 0) { - if (NCTYPE(node)->not != 0) op = OP_NOT_ASCII_WORD; - else op = OP_ASCII_WORD; - } - else { - if (NCTYPE(node)->not != 0) op = OP_NOT_WORD; - else op = OP_WORD; - } - break; + if (NCTYPE(node)->ascii_range != 0) { + if (NCTYPE(node)->not != 0) op = OP_NOT_ASCII_WORD; + else op = OP_ASCII_WORD; + } + else { + if (NCTYPE(node)->not != 0) op = OP_NOT_WORD; + else op = OP_WORD; + } + break; default: - return ONIGERR_TYPE_BUG; - break; + return ONIGERR_TYPE_BUG; + break; } r = add_opcode(reg, op); } @@ -1803,58 +1813,58 @@ #ifdef USE_BACKREF_WITH_LEVEL if (IS_BACKREF_NEST_LEVEL(br)) { - r = add_opcode(reg, OP_BACKREF_WITH_LEVEL); - if (r) return r; - r = add_option(reg, (reg->options & ONIG_OPTION_IGNORECASE)); - if (r) return r; - r = add_length(reg, br->nest_level); - if (r) return r; + r = add_opcode(reg, OP_BACKREF_WITH_LEVEL); + if (r) return r; + r = add_option(reg, (reg->options & ONIG_OPTION_IGNORECASE)); + if (r) return r; + r = add_length(reg, br->nest_level); + if (r) return r; - goto add_bacref_mems; + goto add_bacref_mems; } else #endif if (br->back_num == 1) { - n = br->back_static[0]; - if (IS_IGNORECASE(reg->options)) { - r = add_opcode(reg, OP_BACKREFN_IC); - if (r) return r; - r = add_mem_num(reg, n); - } - else { - switch (n) { - case 1: r = add_opcode(reg, OP_BACKREF1); break; - case 2: r = add_opcode(reg, OP_BACKREF2); break; - default: - r = add_opcode(reg, OP_BACKREFN); - if (r) return r; - r = add_mem_num(reg, n); - break; - } - } + n = br->back_static[0]; + if (IS_IGNORECASE(reg->options)) { + r = add_opcode(reg, OP_BACKREFN_IC); + if (r) return r; + r = add_mem_num(reg, n); + } + else { + switch (n) { + case 1: r = add_opcode(reg, OP_BACKREF1); break; + case 2: r = add_opcode(reg, OP_BACKREF2); break; + default: + r = add_opcode(reg, OP_BACKREFN); + if (r) return r; + r = add_mem_num(reg, n); + break; + } + } } else { - int i; - int* p; + int i; + int* p; - if (IS_IGNORECASE(reg->options)) { - r = add_opcode(reg, OP_BACKREF_MULTI_IC); - } - else { - r = add_opcode(reg, OP_BACKREF_MULTI); - } - if (r) return r; + if (IS_IGNORECASE(reg->options)) { + r = add_opcode(reg, OP_BACKREF_MULTI_IC); + } + else { + r = add_opcode(reg, OP_BACKREF_MULTI); + } + if (r) return r; #ifdef USE_BACKREF_WITH_LEVEL add_bacref_mems: #endif - r = add_length(reg, br->back_num); - if (r) return r; - p = BACKREFS_P(br); - for (i = br->back_num - 1; i >= 0; i--) { - r = add_mem_num(reg, p[i]); - if (r) return r; - } + r = add_length(reg, br->back_num); + if (r) return r; + p = BACKREFS_P(br); + for (i = br->back_num - 1; i >= 0; i--) { + r = add_mem_num(reg, p[i]); + if (r) return r; + } } } break; @@ -1909,7 +1919,7 @@ Node* old = *ptarget; r = noname_disable_map(ptarget, map, counter); if (*ptarget != old && NTYPE(*ptarget) == NT_QTFR) { - onig_reduce_nested_quantifier(node, *ptarget); + onig_reduce_nested_quantifier(node, *ptarget); } } break; @@ -1918,18 +1928,18 @@ { EncloseNode* en = NENCLOSE(node); if (en->type == ENCLOSE_MEMORY) { - if (IS_ENCLOSE_NAMED_GROUP(en)) { - (*counter)++; - map[en->regnum].new_val = *counter; - en->regnum = *counter; - } - else if (en->regnum != 0) { - *plink = en->target; - en->target = NULL_NODE; - onig_node_free(node); - r = noname_disable_map(plink, map, counter); - break; - } + if (IS_ENCLOSE_NAMED_GROUP(en)) { + (*counter)++; + map[en->regnum].new_val = *counter; + en->regnum = *counter; + } + else if (en->regnum != 0) { + *plink = en->target; + en->target = NULL_NODE; + onig_node_free(node); + r = noname_disable_map(plink, map, counter); + break; + } } r = noname_disable_map(&(en->target), map, counter); } @@ -1995,8 +2005,8 @@ { EncloseNode* en = NENCLOSE(node); if (en->type == ENCLOSE_CONDITION) { - if (en->regnum > num_mem) return ONIGERR_INVALID_BACKREF; - en->regnum = map[en->regnum].new_val; + if (en->regnum > num_mem) return ONIGERR_INVALID_BACKREF; + en->regnum = map[en->regnum].new_val; } r = renumber_by_map(en->target, map, num_mem); } @@ -2127,8 +2137,8 @@ { int v; do { - v = quantifiers_memory_node_info(NCAR(node)); - if (v > r) r = v; + v = quantifiers_memory_node_info(NCAR(node)); + if (v > r) r = v; } while (v >= 0 && IS_NOT_NULL(node = NCDR(node))); } break; @@ -2147,7 +2157,7 @@ { QtfrNode* qn = NQTFR(node); if (qn->upper != 0) { - r = quantifiers_memory_node_info(qn->target); + r = quantifiers_memory_node_info(qn->target); } } break; @@ -2157,17 +2167,17 @@ EncloseNode* en = NENCLOSE(node); switch (en->type) { case ENCLOSE_MEMORY: - return NQ_TARGET_IS_EMPTY_MEM; - break; + return NQ_TARGET_IS_EMPTY_MEM; + break; case ENCLOSE_OPTION: case ENCLOSE_STOP_BACKTRACK: case ENCLOSE_CONDITION: case ENCLOSE_ABSENT: - r = quantifiers_memory_node_info(en->target); - break; + r = quantifiers_memory_node_info(en->target); + break; default: - break; + break; } } break; @@ -2207,10 +2217,10 @@ r = get_min_match_length(nodes[backs[0]], min, env); if (r != 0) break; for (i = 1; i < br->back_num; i++) { - if (backs[i] > env->num_mem) return ONIGERR_INVALID_BACKREF; - r = get_min_match_length(nodes[backs[i]], &tmin, env); - if (r != 0) break; - if (*min > tmin) *min = tmin; + if (backs[i] > env->num_mem) return ONIGERR_INVALID_BACKREF; + r = get_min_match_length(nodes[backs[i]], &tmin, env); + if (r != 0) break; + if (*min > tmin) *min = tmin; } } break; @@ -2220,7 +2230,7 @@ if (IS_CALL_RECURSION(NCALL(node))) { EncloseNode* en = NENCLOSE(NCALL(node)->target); if (IS_ENCLOSE_MIN_FIXED(en)) - *min = en->min_len; + *min = en->min_len; } else r = get_min_match_length(NCALL(node)->target, min, env); @@ -2239,11 +2249,11 @@ Node *x, *y; y = node; do { - x = NCAR(y); - r = get_min_match_length(x, &tmin, env); - if (r != 0) break; - if (y == node) *min = tmin; - else if (*min > tmin) *min = tmin; + x = NCAR(y); + r = get_min_match_length(x, &tmin, env); + if (r != 0) break; + if (y == node) *min = tmin; + else if (*min > tmin) *min = tmin; } while (r == 0 && IS_NOT_NULL(y = NCDR(y))); } break; @@ -2269,9 +2279,9 @@ QtfrNode* qn = NQTFR(node); if (qn->lower > 0) { - r = get_min_match_length(qn->target, min, env); - if (r == 0) - *min = distance_multiply(*min, qn->lower); + r = get_min_match_length(qn->target, min, env); + if (r == 0) + *min = distance_multiply(*min, qn->lower); } } break; @@ -2284,28 +2294,28 @@ if (IS_ENCLOSE_MIN_FIXED(en)) *min = en->min_len; else { - if (IS_ENCLOSE_MARK1(NENCLOSE(node))) - *min = 0; /* recursive */ - else { - SET_ENCLOSE_STATUS(node, NST_MARK1); - r = get_min_match_length(en->target, min, env); - CLEAR_ENCLOSE_STATUS(node, NST_MARK1); - if (r == 0) { - en->min_len = *min; - SET_ENCLOSE_STATUS(node, NST_MIN_FIXED); - } - } + if (IS_ENCLOSE_MARK1(NENCLOSE(node))) + *min = 0; /* recursive */ + else { + SET_ENCLOSE_STATUS(node, NST_MARK1); + r = get_min_match_length(en->target, min, env); + CLEAR_ENCLOSE_STATUS(node, NST_MARK1); + if (r == 0) { + en->min_len = *min; + SET_ENCLOSE_STATUS(node, NST_MIN_FIXED); + } + } } break; case ENCLOSE_OPTION: case ENCLOSE_STOP_BACKTRACK: case ENCLOSE_CONDITION: - r = get_min_match_length(en->target, min, env); - break; + r = get_min_match_length(en->target, min, env); + break; case ENCLOSE_ABSENT: - break; + break; } } break; @@ -2330,7 +2340,7 @@ do { r = get_max_match_length(NCAR(node), &tmax, env); if (r == 0) - *max = distance_add(*max, tmax); + *max = distance_add(*max, tmax); } while (r == 0 && IS_NOT_NULL(node = NCDR(node))); break; @@ -2364,15 +2374,15 @@ Node** nodes = SCANENV_MEM_NODES(env); BRefNode* br = NBREF(node); if (br->state & NST_RECURSION) { - *max = ONIG_INFINITE_DISTANCE; - break; + *max = ONIG_INFINITE_DISTANCE; + break; } backs = BACKREFS_P(br); for (i = 0; i < br->back_num; i++) { - if (backs[i] > env->num_mem) return ONIGERR_INVALID_BACKREF; - r = get_max_match_length(nodes[backs[i]], &tmax, env); - if (r != 0) break; - if (*max < tmax) *max = tmax; + if (backs[i] > env->num_mem) return ONIGERR_INVALID_BACKREF; + r = get_max_match_length(nodes[backs[i]], &tmax, env); + if (r != 0) break; + if (*max < tmax) *max = tmax; } } break; @@ -2391,13 +2401,13 @@ QtfrNode* qn = NQTFR(node); if (qn->upper != 0) { - r = get_max_match_length(qn->target, max, env); - if (r == 0 && *max != 0) { - if (! IS_REPEAT_INFINITE(qn->upper)) - *max = distance_multiply(*max, qn->upper); - else - *max = ONIG_INFINITE_DISTANCE; - } + r = get_max_match_length(qn->target, max, env); + if (r == 0 && *max != 0) { + if (! IS_REPEAT_INFINITE(qn->upper)) + *max = distance_multiply(*max, qn->upper); + else + *max = ONIG_INFINITE_DISTANCE; + } } } break; @@ -2407,31 +2417,31 @@ EncloseNode* en = NENCLOSE(node); switch (en->type) { case ENCLOSE_MEMORY: - if (IS_ENCLOSE_MAX_FIXED(en)) - *max = en->max_len; - else { - if (IS_ENCLOSE_MARK1(NENCLOSE(node))) - *max = ONIG_INFINITE_DISTANCE; - else { - SET_ENCLOSE_STATUS(node, NST_MARK1); - r = get_max_match_length(en->target, max, env); - CLEAR_ENCLOSE_STATUS(node, NST_MARK1); - if (r == 0) { - en->max_len = *max; - SET_ENCLOSE_STATUS(node, NST_MAX_FIXED); - } - } - } - break; + if (IS_ENCLOSE_MAX_FIXED(en)) + *max = en->max_len; + else { + if (IS_ENCLOSE_MARK1(NENCLOSE(node))) + *max = ONIG_INFINITE_DISTANCE; + else { + SET_ENCLOSE_STATUS(node, NST_MARK1); + r = get_max_match_length(en->target, max, env); + CLEAR_ENCLOSE_STATUS(node, NST_MARK1); + if (r == 0) { + en->max_len = *max; + SET_ENCLOSE_STATUS(node, NST_MAX_FIXED); + } + } + } + break; case ENCLOSE_OPTION: case ENCLOSE_STOP_BACKTRACK: case ENCLOSE_CONDITION: - r = get_max_match_length(en->target, max, env); - break; + r = get_max_match_length(en->target, max, env); + break; case ENCLOSE_ABSENT: - break; + break; } } break; @@ -2461,7 +2471,7 @@ do { r = get_char_length_tree1(NCAR(node), reg, &tlen, level); if (r == 0) - *len = (int )distance_add(*len, tlen); + *len = (int )distance_add(*len, tlen); } while (r == 0 && IS_NOT_NULL(node = NCDR(node))); break; @@ -2472,21 +2482,21 @@ r = get_char_length_tree1(NCAR(node), reg, &tlen, level); while (r == 0 && IS_NOT_NULL(node = NCDR(node))) { - r = get_char_length_tree1(NCAR(node), reg, &tlen2, level); - if (r == 0) { - if (tlen != tlen2) - varlen = 1; - } + r = get_char_length_tree1(NCAR(node), reg, &tlen2, level); + if (r == 0) { + if (tlen != tlen2) + varlen = 1; + } } if (r == 0) { - if (varlen != 0) { - if (level == 1) - r = GET_CHAR_LEN_TOP_ALT_VARLEN; - else - r = GET_CHAR_LEN_VARLEN; - } - else - *len = tlen; + if (varlen != 0) { + if (level == 1) + r = GET_CHAR_LEN_TOP_ALT_VARLEN; + else + r = GET_CHAR_LEN_VARLEN; + } + else + *len = tlen; } } break; @@ -2496,8 +2506,8 @@ StrNode* sn = NSTR(node); UChar *s = sn->s; while (s < sn->end) { - s += enclen(reg->enc, s, sn->end); - (*len)++; + s += enclen(reg->enc, s, sn->end); + (*len)++; } } break; @@ -2506,12 +2516,12 @@ { QtfrNode* qn = NQTFR(node); if (qn->lower == qn->upper) { - r = get_char_length_tree1(qn->target, reg, &tlen, level); - if (r == 0) - *len = (int )distance_multiply(tlen, qn->lower); + r = get_char_length_tree1(qn->target, reg, &tlen, level); + if (r == 0) + *len = (int )distance_multiply(tlen, qn->lower); } else - r = GET_CHAR_LEN_VARLEN; + r = GET_CHAR_LEN_VARLEN; } break; @@ -2539,25 +2549,25 @@ switch (en->type) { case ENCLOSE_MEMORY: #ifdef USE_SUBEXP_CALL - if (IS_ENCLOSE_CLEN_FIXED(en)) - *len = en->char_len; - else { - r = get_char_length_tree1(en->target, reg, len, level); - if (r == 0) { - en->char_len = *len; - SET_ENCLOSE_STATUS(node, NST_CLEN_FIXED); - } - } - break; + if (IS_ENCLOSE_CLEN_FIXED(en)) + *len = en->char_len; + else { + r = get_char_length_tree1(en->target, reg, len, level); + if (r == 0) { + en->char_len = *len; + SET_ENCLOSE_STATUS(node, NST_CLEN_FIXED); + } + } + break; #endif case ENCLOSE_OPTION: case ENCLOSE_STOP_BACKTRACK: case ENCLOSE_CONDITION: - r = get_char_length_tree1(en->target, reg, len, level); - break; + r = get_char_length_tree1(en->target, reg, len, level); + break; case ENCLOSE_ABSENT: default: - break; + break; } } break; @@ -2596,29 +2606,29 @@ { switch (ytype) { case NT_CTYPE: - if (NCTYPE(y)->ctype == NCTYPE(x)->ctype && - NCTYPE(y)->not != NCTYPE(x)->not && - NCTYPE(y)->ascii_range == NCTYPE(x)->ascii_range) - return 1; - else - return 0; - break; + if (NCTYPE(y)->ctype == NCTYPE(x)->ctype && + NCTYPE(y)->not != NCTYPE(x)->not && + NCTYPE(y)->ascii_range == NCTYPE(x)->ascii_range) + return 1; + else + return 0; + break; case NT_CCLASS: swap: - { - Node* tmp; - tmp = x; x = y; y = tmp; - goto retry; - } - break; + { + Node* tmp; + tmp = x; x = y; y = tmp; + goto retry; + } + break; case NT_STR: - goto swap; - break; + goto swap; + break; default: - break; + break; } } break; @@ -2628,80 +2638,80 @@ CClassNode* xc = NCCLASS(x); switch (ytype) { case NT_CTYPE: - switch (NCTYPE(y)->ctype) { - case ONIGENC_CTYPE_WORD: - if (NCTYPE(y)->not == 0) { - if (IS_NULL(xc->mbuf) && !IS_NCCLASS_NOT(xc)) { - for (i = 0; i < SINGLE_BYTE_SIZE; i++) { - if (BITSET_AT(xc->bs, i)) { - if (NCTYPE(y)->ascii_range) { - if (IS_CODE_SB_WORD(reg->enc, i)) return 0; - } - else { - if (ONIGENC_IS_CODE_WORD(reg->enc, i)) return 0; - } - } - } - return 1; - } - return 0; - } - else { - if (IS_NOT_NULL(xc->mbuf)) return 0; - for (i = 0; i < SINGLE_BYTE_SIZE; i++) { - int is_word; - if (NCTYPE(y)->ascii_range) - is_word = IS_CODE_SB_WORD(reg->enc, i); - else - is_word = ONIGENC_IS_CODE_WORD(reg->enc, i); - if (! is_word) { - if (!IS_NCCLASS_NOT(xc)) { - if (BITSET_AT(xc->bs, i)) - return 0; - } - else { - if (! BITSET_AT(xc->bs, i)) - return 0; - } - } - } - return 1; - } - break; - - default: - break; - } - break; + switch (NCTYPE(y)->ctype) { + case ONIGENC_CTYPE_WORD: + if (NCTYPE(y)->not == 0) { + if (IS_NULL(xc->mbuf) && !IS_NCCLASS_NOT(xc)) { + for (i = 0; i < SINGLE_BYTE_SIZE; i++) { + if (BITSET_AT(xc->bs, i)) { + if (NCTYPE(y)->ascii_range) { + if (IS_CODE_SB_WORD(reg->enc, i)) return 0; + } + else { + if (ONIGENC_IS_CODE_WORD(reg->enc, i)) return 0; + } + } + } + return 1; + } + return 0; + } + else { + if (IS_NOT_NULL(xc->mbuf)) return 0; + for (i = 0; i < SINGLE_BYTE_SIZE; i++) { + int is_word; + if (NCTYPE(y)->ascii_range) + is_word = IS_CODE_SB_WORD(reg->enc, i); + else + is_word = ONIGENC_IS_CODE_WORD(reg->enc, i); + if (! is_word) { + if (!IS_NCCLASS_NOT(xc)) { + if (BITSET_AT(xc->bs, i)) + return 0; + } + else { + if (! BITSET_AT(xc->bs, i)) + return 0; + } + } + } + return 1; + } + break; + + default: + break; + } + break; case NT_CCLASS: - { - int v; - CClassNode* yc = NCCLASS(y); - - for (i = 0; i < SINGLE_BYTE_SIZE; i++) { - v = BITSET_AT(xc->bs, i); - if ((v != 0 && !IS_NCCLASS_NOT(xc)) || - (v == 0 && IS_NCCLASS_NOT(xc))) { - v = BITSET_AT(yc->bs, i); - if ((v != 0 && !IS_NCCLASS_NOT(yc)) || - (v == 0 && IS_NCCLASS_NOT(yc))) - return 0; - } - } - if ((IS_NULL(xc->mbuf) && !IS_NCCLASS_NOT(xc)) || - (IS_NULL(yc->mbuf) && !IS_NCCLASS_NOT(yc))) - return 1; - return 0; - } - break; + { + int v; + CClassNode* yc = NCCLASS(y); + + for (i = 0; i < SINGLE_BYTE_SIZE; i++) { + v = BITSET_AT(xc->bs, i); + if ((v != 0 && !IS_NCCLASS_NOT(xc)) || + (v == 0 && IS_NCCLASS_NOT(xc))) { + v = BITSET_AT(yc->bs, i); + if ((v != 0 && !IS_NCCLASS_NOT(yc)) || + (v == 0 && IS_NCCLASS_NOT(yc))) + return 0; + } + } + if ((IS_NULL(xc->mbuf) && !IS_NCCLASS_NOT(xc)) || + (IS_NULL(yc->mbuf) && !IS_NCCLASS_NOT(yc))) + return 1; + return 0; + } + break; case NT_STR: - goto swap; - break; + goto swap; + break; default: - break; + break; } } break; @@ -2710,60 +2720,60 @@ { StrNode* xs = NSTR(x); if (NSTRING_LEN(x) == 0) - break; + break; switch (ytype) { case NT_CTYPE: - switch (NCTYPE(y)->ctype) { - case ONIGENC_CTYPE_WORD: - if (NCTYPE(y)->ascii_range) { - if (ONIGENC_IS_MBC_ASCII_WORD(reg->enc, xs->s, xs->end)) - return NCTYPE(y)->not; - else - return !(NCTYPE(y)->not); - } - else { - if (ONIGENC_IS_MBC_WORD(reg->enc, xs->s, xs->end)) - return NCTYPE(y)->not; - else - return !(NCTYPE(y)->not); - } - break; - default: - break; - } - break; + switch (NCTYPE(y)->ctype) { + case ONIGENC_CTYPE_WORD: + if (NCTYPE(y)->ascii_range) { + if (ONIGENC_IS_MBC_ASCII_WORD(reg->enc, xs->s, xs->end)) + return NCTYPE(y)->not; + else + return !(NCTYPE(y)->not); + } + else { + if (ONIGENC_IS_MBC_WORD(reg->enc, xs->s, xs->end)) + return NCTYPE(y)->not; + else + return !(NCTYPE(y)->not); + } + break; + default: + break; + } + break; case NT_CCLASS: - { - CClassNode* cc = NCCLASS(y); + { + CClassNode* cc = NCCLASS(y); - code = ONIGENC_MBC_TO_CODE(reg->enc, xs->s, - xs->s + ONIGENC_MBC_MAXLEN(reg->enc)); - return (onig_is_code_in_cc(reg->enc, code, cc) != 0 ? 0 : 1); - } - break; + code = ONIGENC_MBC_TO_CODE(reg->enc, xs->s, + xs->s + ONIGENC_MBC_MAXLEN(reg->enc)); + return (onig_is_code_in_cc(reg->enc, code, cc) != 0 ? 0 : 1); + } + break; case NT_STR: - { - UChar *q; - StrNode* ys = NSTR(y); - len = NSTRING_LEN(x); - if (len > NSTRING_LEN(y)) len = NSTRING_LEN(y); - if (NSTRING_IS_AMBIG(x) || NSTRING_IS_AMBIG(y)) { - /* tiny version */ - return 0; - } - else { - for (i = 0, p = ys->s, q = xs->s; (OnigDistance )i < len; i++, p++, q++) { - if (*p != *q) return 1; - } - } - } - break; + { + UChar *q; + StrNode* ys = NSTR(y); + len = NSTRING_LEN(x); + if (len > NSTRING_LEN(y)) len = NSTRING_LEN(y); + if (NSTRING_IS_AMBIG(x) || NSTRING_IS_AMBIG(y)) { + /* tiny version */ + return 0; + } + else { + for (i = 0, p = ys->s, q = xs->s; (OnigDistance )i < len; i++, p++, q++) { + if (*p != *q) return 1; + } + } + } + break; default: - break; + break; } } break; @@ -2803,15 +2813,12 @@ case NT_STR: { StrNode* sn = NSTR(node); - if (sn->end <= sn->s) - break; + break; - if (exact != 0 && - !NSTRING_IS_RAW(node) && IS_IGNORECASE(reg->options)) { - } - else { - n = node; + if (exact == 0 || + NSTRING_IS_RAW(node) || !IS_IGNORECASE(reg->options)) { + n = node; } } break; @@ -2821,11 +2828,11 @@ QtfrNode* qn = NQTFR(node); if (qn->lower > 0) { #ifdef USE_OP_PUSH_OR_JUMP_EXACT - if (IS_NOT_NULL(qn->head_exact)) - n = qn->head_exact; - else + if (IS_NOT_NULL(qn->head_exact)) + n = qn->head_exact; + else #endif - n = get_head_value_node(qn->target, exact, reg); + n = get_head_value_node(qn->target, exact, reg); } } break; @@ -2835,23 +2842,23 @@ EncloseNode* en = NENCLOSE(node); switch (en->type) { case ENCLOSE_OPTION: - { - OnigOptionType options = reg->options; + { + OnigOptionType options = reg->options; - reg->options = NENCLOSE(node)->option; - n = get_head_value_node(NENCLOSE(node)->target, exact, reg); - reg->options = options; - } - break; + reg->options = NENCLOSE(node)->option; + n = get_head_value_node(NENCLOSE(node)->target, exact, reg); + reg->options = options; + } + break; case ENCLOSE_MEMORY: case ENCLOSE_STOP_BACKTRACK: case ENCLOSE_CONDITION: - n = get_head_value_node(en->target, exact, reg); - break; + n = get_head_value_node(en->target, exact, reg); + break; case ENCLOSE_ABSENT: - break; + break; } } break; @@ -2882,20 +2889,20 @@ case NT_ALT: do { r = check_type_tree(NCAR(node), type_mask, enclose_mask, - anchor_mask); + anchor_mask); } while (r == 0 && IS_NOT_NULL(node = NCDR(node))); break; case NT_QTFR: r = check_type_tree(NQTFR(node)->target, type_mask, enclose_mask, - anchor_mask); + anchor_mask); break; case NT_ENCLOSE: { EncloseNode* en = NENCLOSE(node); if ((en->type & enclose_mask) == 0) - return 1; + return 1; r = check_type_tree(en->target, type_mask, enclose_mask, anchor_mask); } @@ -2908,7 +2915,7 @@ if (NANCHOR(node)->target) r = check_type_tree(NANCHOR(node)->target, - type_mask, enclose_mask, anchor_mask); + type_mask, enclose_mask, anchor_mask); break; default: @@ -2938,14 +2945,14 @@ x = node; do { - ret = subexp_inf_recursive_check(NCAR(x), env, head); - if (ret < 0 || ret == RECURSION_INFINITE) return ret; - r |= ret; - if (head) { - ret = get_min_match_length(NCAR(x), &min, env); - if (ret != 0) return ret; - if (min != 0) head = 0; - } + ret = subexp_inf_recursive_check(NCAR(x), env, head); + if (ret < 0 || ret == RECURSION_INFINITE) return ret; + r |= ret; + if (head) { + ret = get_min_match_length(NCAR(x), &min, env); + if (ret != 0) return ret; + if (min != 0) head = 0; + } } while (IS_NOT_NULL(x = NCDR(x))); } break; @@ -2955,9 +2962,9 @@ int ret; r = RECURSION_EXIST; do { - ret = subexp_inf_recursive_check(NCAR(node), env, head); - if (ret < 0 || ret == RECURSION_INFINITE) return ret; - r &= ret; + ret = subexp_inf_recursive_check(NCAR(node), env, head); + if (ret < 0 || ret == RECURSION_INFINITE) return ret; + r &= ret; } while (IS_NOT_NULL(node = NCDR(node))); } break; @@ -2977,8 +2984,8 @@ case ANCHOR_PREC_READ_NOT: case ANCHOR_LOOK_BEHIND: case ANCHOR_LOOK_BEHIND_NOT: - r = subexp_inf_recursive_check(an->target, env, head); - break; + r = subexp_inf_recursive_check(an->target, env, head); + break; } } break; @@ -3033,8 +3040,8 @@ case ANCHOR_PREC_READ_NOT: case ANCHOR_LOOK_BEHIND: case ANCHOR_LOOK_BEHIND_NOT: - r = subexp_inf_recursive_check_trav(an->target, env); - break; + r = subexp_inf_recursive_check_trav(an->target, env); + break; } } break; @@ -3044,10 +3051,10 @@ EncloseNode* en = NENCLOSE(node); if (IS_ENCLOSE_RECURSION(en)) { - SET_ENCLOSE_STATUS(node, NST_MARK1); - r = subexp_inf_recursive_check(en->target, env, 1); - if (r > 0) return ONIGERR_NEVER_ENDING_RECURSION; - CLEAR_ENCLOSE_STATUS(node, NST_MARK1); + SET_ENCLOSE_STATUS(node, NST_MARK1); + r = subexp_inf_recursive_check(en->target, env, 1); + if (r > 0) return ONIGERR_NEVER_ENDING_RECURSION; + CLEAR_ENCLOSE_STATUS(node, NST_MARK1); } r = subexp_inf_recursive_check_trav(en->target, env); } @@ -3086,8 +3093,8 @@ case ANCHOR_PREC_READ_NOT: case ANCHOR_LOOK_BEHIND: case ANCHOR_LOOK_BEHIND_NOT: - r = subexp_recursive_check(an->target); - break; + r = subexp_recursive_check(an->target); + break; } } break; @@ -3132,9 +3139,9 @@ { int ret; do { - ret = subexp_recursive_check_trav(NCAR(node), env); - if (ret == FOUND_CALLED_NODE) r = FOUND_CALLED_NODE; - else if (ret < 0) return ret; + ret = subexp_recursive_check_trav(NCAR(node), env); + if (ret == FOUND_CALLED_NODE) r = FOUND_CALLED_NODE; + else if (ret < 0) return ret; } while (IS_NOT_NULL(node = NCDR(node))); } break; @@ -3143,7 +3150,7 @@ r = subexp_recursive_check_trav(NQTFR(node)->target, env); if (NQTFR(node)->upper == 0) { if (r == FOUND_CALLED_NODE) - NQTFR(node)->is_referred = 1; + NQTFR(node)->is_referred = 1; } break; @@ -3155,8 +3162,8 @@ case ANCHOR_PREC_READ_NOT: case ANCHOR_LOOK_BEHIND: case ANCHOR_LOOK_BEHIND_NOT: - r = subexp_recursive_check_trav(an->target, env); - break; + r = subexp_recursive_check_trav(an->target, env); + break; } } break; @@ -3166,16 +3173,16 @@ EncloseNode* en = NENCLOSE(node); if (! IS_ENCLOSE_RECURSION(en)) { - if (IS_ENCLOSE_CALLED(en)) { - SET_ENCLOSE_STATUS(node, NST_MARK1); - r = subexp_recursive_check(en->target); - if (r != 0) SET_ENCLOSE_STATUS(node, NST_RECURSION); - CLEAR_ENCLOSE_STATUS(node, NST_MARK1); - } + if (IS_ENCLOSE_CALLED(en)) { + SET_ENCLOSE_STATUS(node, NST_MARK1); + r = subexp_recursive_check(en->target); + if (r != 0) SET_ENCLOSE_STATUS(node, NST_RECURSION); + CLEAR_ENCLOSE_STATUS(node, NST_MARK1); + } } r = subexp_recursive_check_trav(en->target, env); if (IS_ENCLOSE_CALLED(en)) - r |= FOUND_CALLED_NODE; + r |= FOUND_CALLED_NODE; } break; @@ -3219,60 +3226,60 @@ Node** nodes = SCANENV_MEM_NODES(env); if (cn->group_num != 0) { - int gnum = cn->group_num; + int gnum = cn->group_num; # ifdef USE_NAMED_GROUP - if (env->num_named > 0 && - IS_SYNTAX_BV(env->syntax, ONIG_SYN_CAPTURE_ONLY_NAMED_GROUP) && - !ONIG_IS_OPTION_ON(env->option, ONIG_OPTION_CAPTURE_GROUP)) { - return ONIGERR_NUMBERED_BACKREF_OR_CALL_NOT_ALLOWED; - } + if (env->num_named > 0 && + IS_SYNTAX_BV(env->syntax, ONIG_SYN_CAPTURE_ONLY_NAMED_GROUP) && + !ONIG_IS_OPTION_ON(env->option, ONIG_OPTION_CAPTURE_GROUP)) { + return ONIGERR_NUMBERED_BACKREF_OR_CALL_NOT_ALLOWED; + } # endif - if (gnum > env->num_mem) { - onig_scan_env_set_error_string(env, - ONIGERR_UNDEFINED_GROUP_REFERENCE, cn->name, cn->name_end); - return ONIGERR_UNDEFINED_GROUP_REFERENCE; - } + if (gnum > env->num_mem) { + onig_scan_env_set_error_string(env, + ONIGERR_UNDEFINED_GROUP_REFERENCE, cn->name, cn->name_end); + return ONIGERR_UNDEFINED_GROUP_REFERENCE; + } # ifdef USE_NAMED_GROUP set_call_attr: # endif - cn->target = nodes[cn->group_num]; - if (IS_NULL(cn->target)) { - onig_scan_env_set_error_string(env, - ONIGERR_UNDEFINED_NAME_REFERENCE, cn->name, cn->name_end); - return ONIGERR_UNDEFINED_NAME_REFERENCE; - } - SET_ENCLOSE_STATUS(cn->target, NST_CALLED); - BIT_STATUS_ON_AT(env->bt_mem_start, cn->group_num); - cn->unset_addr_list = env->unset_addr_list; + cn->target = nodes[cn->group_num]; + if (IS_NULL(cn->target)) { + onig_scan_env_set_error_string(env, + ONIGERR_UNDEFINED_NAME_REFERENCE, cn->name, cn->name_end); + return ONIGERR_UNDEFINED_NAME_REFERENCE; + } + SET_ENCLOSE_STATUS(cn->target, NST_CALLED); + BIT_STATUS_ON_AT(env->bt_mem_start, cn->group_num); + cn->unset_addr_list = env->unset_addr_list; } # ifdef USE_NAMED_GROUP # ifdef USE_PERL_SUBEXP_CALL else if (cn->name == cn->name_end) { - goto set_call_attr; + goto set_call_attr; } # endif else { - int *refs; + int *refs; - int n = onig_name_to_group_numbers(env->reg, cn->name, cn->name_end, - &refs); - if (n <= 0) { - onig_scan_env_set_error_string(env, - ONIGERR_UNDEFINED_NAME_REFERENCE, cn->name, cn->name_end); - return ONIGERR_UNDEFINED_NAME_REFERENCE; - } - else if (n > 1 && - ! IS_SYNTAX_BV(env->syntax, ONIG_SYN_ALLOW_MULTIPLEX_DEFINITION_NAME_CALL)) { - onig_scan_env_set_error_string(env, - ONIGERR_MULTIPLEX_DEFINITION_NAME_CALL, cn->name, cn->name_end); - return ONIGERR_MULTIPLEX_DEFINITION_NAME_CALL; - } - else { - cn->group_num = refs[0]; - goto set_call_attr; - } + int n = onig_name_to_group_numbers(env->reg, cn->name, cn->name_end, + &refs); + if (n <= 0) { + onig_scan_env_set_error_string(env, + ONIGERR_UNDEFINED_NAME_REFERENCE, cn->name, cn->name_end); + return ONIGERR_UNDEFINED_NAME_REFERENCE; + } + else if (n > 1 && + ! IS_SYNTAX_BV(env->syntax, ONIG_SYN_ALLOW_MULTIPLEX_DEFINITION_NAME_CALL)) { + onig_scan_env_set_error_string(env, + ONIGERR_MULTIPLEX_DEFINITION_NAME_CALL, cn->name, cn->name_end); + return ONIGERR_MULTIPLEX_DEFINITION_NAME_CALL; + } + else { + cn->group_num = refs[0]; + goto set_call_attr; + } } # endif } @@ -3287,8 +3294,8 @@ case ANCHOR_PREC_READ_NOT: case ANCHOR_LOOK_BEHIND: case ANCHOR_LOOK_BEHIND_NOT: - r = setup_subexp_call(an->target, env); - break; + r = setup_subexp_call(an->target, env); + break; } } break; @@ -3301,6 +3308,14 @@ } #endif +#define IN_ALT (1<<0) +#define IN_NOT (1<<1) +#define IN_REPEAT (1<<2) +#define IN_VAR_REPEAT (1<<3) +#define IN_CALL (1<<4) +#define IN_RECCALL (1<<5) +#define IN_LOOK_BEHIND (1<<6) + /* divide different length alternatives in look-behind. (?<=A|B) ==> (?<=A)|(?<=B) (?<!A|B) ==> (?<!A)(?<!B) @@ -3370,26 +3385,26 @@ Node* n = get_head_value_node(next_node, 1, reg); /* '\0': for UTF-16BE etc... */ if (IS_NOT_NULL(n) && NSTR(n)->s[0] != '\0') { - qn->next_head_exact = n; + qn->next_head_exact = n; } #endif /* automatic possessification a*b ==> (?>a*)b */ if (qn->lower <= 1) { - int ttype = NTYPE(qn->target); - if (IS_NODE_TYPE_SIMPLE(ttype)) { - Node *x, *y; - x = get_head_value_node(qn->target, 0, reg); - if (IS_NOT_NULL(x)) { - y = get_head_value_node(next_node, 0, reg); - if (IS_NOT_NULL(y) && is_not_included(x, y, reg)) { - Node* en = onig_node_new_enclose(ENCLOSE_STOP_BACKTRACK); - CHECK_NULL_RETURN_MEMERR(en); - SET_ENCLOSE_STATUS(en, NST_STOP_BT_SIMPLE_REPEAT); - swap_node(node, en); - NENCLOSE(node)->target = en; - } - } - } + int ttype = NTYPE(qn->target); + if (IS_NODE_TYPE_SIMPLE(ttype)) { + Node *x, *y; + x = get_head_value_node(qn->target, 0, reg); + if (IS_NOT_NULL(x)) { + y = get_head_value_node(next_node, 0, reg); + if (IS_NOT_NULL(y) && is_not_included(x, y, reg)) { + Node* en = onig_node_new_enclose(ENCLOSE_STOP_BACKTRACK); + CHECK_NULL_RETURN_MEMERR(en); + SET_ENCLOSE_STATUS(en, NST_STOP_BT_SIMPLE_REPEAT); + swap_node(node, en); + NENCLOSE(node)->target = en; + } + } + } } } } @@ -3425,15 +3440,15 @@ len = ONIGENC_MBC_CASE_FOLD(reg->enc, reg->case_fold_flag, &p, end, buf); for (i = 0; i < len; i++) { if (sp >= ebuf) { - UChar* p = (UChar* )xrealloc(sbuf, sbuf_size * 2); - if (IS_NULL(p)) { - xfree(sbuf); - return ONIGERR_MEMORY; - } - sbuf = p; - sp = sbuf + sbuf_size; - sbuf_size *= 2; - ebuf = sbuf + sbuf_size; + UChar* p = (UChar* )xrealloc(sbuf, sbuf_size * 2); + if (IS_NULL(p)) { + xfree(sbuf); + return ONIGERR_MEMORY; + } + sbuf = p; + sp = sbuf + sbuf_size; + sbuf_size *= 2; + ebuf = sbuf + sbuf_size; } *sp++ = buf[i]; @@ -3448,7 +3463,7 @@ static int expand_case_fold_make_rem_string(Node** rnode, UChar *s, UChar *end, - regex_t* reg) + regex_t* reg) { int r; Node *node; @@ -3470,7 +3485,7 @@ static int is_case_fold_variable_len(int item_num, OnigCaseFoldCodeItem items[], - int slen) + int slen) { int i; @@ -3487,8 +3502,8 @@ static int expand_case_fold_string_alt(int item_num, OnigCaseFoldCodeItem items[], - UChar *p, int slen, UChar *end, - regex_t* reg, Node **rnode) + UChar *p, int slen, UChar *end, + regex_t* reg, Node **rnode) { int r, i, j, len, varlen; Node *anode, *var_anode, *snode, *xnode, *an; @@ -3533,8 +3548,8 @@ for (j = 0; j < items[i].code_len; j++) { len = ONIGENC_CODE_TO_MBC(reg->enc, items[i].code[j], buf); if (len < 0) { - r = len; - goto mem_err2; + r = len; + goto mem_err2; } r = onig_node_str_cat(snode, buf, buf + len); @@ -3551,29 +3566,29 @@ UChar *q = p + items[i].byte_len; if (q < end) { - r = expand_case_fold_make_rem_string(&rem, q, end, reg); - if (r != 0) { - onig_node_free(an); - goto mem_err2; - } - - xnode = onig_node_list_add(NULL_NODE, snode); - if (IS_NULL(xnode)) { - onig_node_free(an); - onig_node_free(rem); - goto mem_err2; - } - if (IS_NULL(onig_node_list_add(xnode, rem))) { - onig_node_free(an); - onig_node_free(xnode); - onig_node_free(rem); - goto mem_err; - } + r = expand_case_fold_make_rem_string(&rem, q, end, reg); + if (r != 0) { + onig_node_free(an); + goto mem_err2; + } - NCAR(an) = xnode; + xnode = onig_node_list_add(NULL_NODE, snode); + if (IS_NULL(xnode)) { + onig_node_free(an); + onig_node_free(rem); + goto mem_err2; + } + if (IS_NULL(onig_node_list_add(xnode, rem))) { + onig_node_free(an); + onig_node_free(xnode); + onig_node_free(rem); + goto mem_err; + } + + NCAR(an) = xnode; } else { - NCAR(an) = snode; + NCAR(an) = snode; } NCDR(var_anode) = an; @@ -3597,31 +3612,36 @@ return ONIGERR_MEMORY; } -static int -expand_case_fold_string(Node* node, regex_t* reg) -{ #define THRESHOLD_CASE_FOLD_ALT_FOR_EXPANSION 8 +static int +expand_case_fold_string(Node* node, regex_t* reg, int state) +{ int r, n, len, alt_num; int varlen = 0; + int is_in_look_behind; UChar *start, *end, *p; Node *top_root, *root, *snode, *prev_node; OnigCaseFoldCodeItem items[ONIGENC_GET_CASE_FOLD_CODES_MAX_NUM]; - StrNode* sn = NSTR(node); + StrNode* sn; if (NSTRING_IS_AMBIG(node)) return 0; + sn = NSTR(node); + start = sn->s; end = sn->end; if (start >= end) return 0; + is_in_look_behind = (state & IN_LOOK_BEHIND) != 0; + r = 0; top_root = root = prev_node = snode = NULL_NODE; alt_num = 1; p = start; while (p < end) { n = ONIGENC_GET_CASE_FOLD_CODES_BY_STR(reg->enc, reg->case_fold_flag, - p, end, items); + p, end, items); if (n < 0) { r = n; goto err; @@ -3630,25 +3650,25 @@ len = enclen(reg->enc, p, end); varlen = is_case_fold_variable_len(n, items, len); - if (n == 0 || varlen == 0) { + if (n == 0 || varlen == 0 || is_in_look_behind) { if (IS_NULL(snode)) { - if (IS_NULL(root) && IS_NOT_NULL(prev_node)) { + if (IS_NULL(root) && IS_NOT_NULL(prev_node)) { onig_node_free(top_root); - top_root = root = onig_node_list_add(NULL_NODE, prev_node); - if (IS_NULL(root)) { - onig_node_free(prev_node); - goto mem_err; - } - } - - prev_node = snode = onig_node_new_str(NULL, NULL); - if (IS_NULL(snode)) goto mem_err; - if (IS_NOT_NULL(root)) { - if (IS_NULL(onig_node_list_add(root, snode))) { - onig_node_free(snode); - goto mem_err; - } - } + top_root = root = onig_node_list_add(NULL_NODE, prev_node); + if (IS_NULL(root)) { + onig_node_free(prev_node); + goto mem_err; + } + } + + prev_node = snode = onig_node_new_str(NULL, NULL); + if (IS_NULL(snode)) goto mem_err; + if (IS_NOT_NULL(root)) { + if (IS_NULL(onig_node_list_add(root, snode))) { + onig_node_free(snode); + goto mem_err; + } + } } r = onig_node_str_cat(snode, p, p + len); @@ -3659,42 +3679,42 @@ if (alt_num > THRESHOLD_CASE_FOLD_ALT_FOR_EXPANSION) break; if (IS_NOT_NULL(snode)) { - r = update_string_node_case_fold(reg, snode); - if (r == 0) { - NSTRING_SET_AMBIG(snode); - } + r = update_string_node_case_fold(reg, snode); + if (r == 0) { + NSTRING_SET_AMBIG(snode); + } } if (IS_NULL(root) && IS_NOT_NULL(prev_node)) { onig_node_free(top_root); - top_root = root = onig_node_list_add(NULL_NODE, prev_node); - if (IS_NULL(root)) { - onig_node_free(prev_node); - goto mem_err; - } + top_root = root = onig_node_list_add(NULL_NODE, prev_node); + if (IS_NULL(root)) { + onig_node_free(prev_node); + goto mem_err; + } } r = expand_case_fold_string_alt(n, items, p, len, end, reg, &prev_node); if (r < 0) goto mem_err; if (r == 1) { - if (IS_NULL(root)) { - top_root = prev_node; - } - else { - if (IS_NULL(onig_node_list_add(root, prev_node))) { - onig_node_free(prev_node); - goto mem_err; - } - } + if (IS_NULL(root)) { + top_root = prev_node; + } + else { + if (IS_NULL(onig_node_list_add(root, prev_node))) { + onig_node_free(prev_node); + goto mem_err; + } + } - root = NCAR(prev_node); + root = NCAR(prev_node); } else { /* r == 0 */ - if (IS_NOT_NULL(root)) { - if (IS_NULL(onig_node_list_add(root, prev_node))) { - onig_node_free(prev_node); - goto mem_err; - } - } + if (IS_NOT_NULL(root)) { + if (IS_NULL(onig_node_list_add(root, prev_node))) { + onig_node_free(prev_node); + goto mem_err; + } + } } snode = NULL_NODE; @@ -3719,9 +3739,9 @@ onig_node_free(top_root); top_root = root = onig_node_list_add(NULL_NODE, prev_node); if (IS_NULL(root)) { - onig_node_free(srem); - onig_node_free(prev_node); - goto mem_err; + onig_node_free(srem); + onig_node_free(prev_node); + goto mem_err; } } @@ -3730,8 +3750,8 @@ } else { if (IS_NULL(onig_node_list_add(root, srem))) { - onig_node_free(srem); - goto mem_err; + onig_node_free(srem); + goto mem_err; } } } @@ -3771,7 +3791,7 @@ case NT_LIST: { do { - r = setup_comb_exp_check(NCAR(node), r, env); + r = setup_comb_exp_check(NCAR(node), r, env); } while (r >= 0 && IS_NOT_NULL(node = NCDR(node))); } break; @@ -3780,8 +3800,8 @@ { int ret; do { - ret = setup_comb_exp_check(NCAR(node), state, env); - r |= ret; + ret = setup_comb_exp_check(NCAR(node), state, env); + r |= ret; } while (ret >= 0 && IS_NOT_NULL(node = NCDR(node))); } break; @@ -3795,55 +3815,55 @@ int var_num; if (! IS_REPEAT_INFINITE(qn->upper)) { - if (qn->upper > 1) { - /* {0,1}, {1,1} are allowed */ - child_state |= CEC_IN_FINITE_REPEAT; - - /* check (a*){n,m}, (a+){n,m} => (a*){n,n}, (a+){n,n} */ - if (env->backrefed_mem == 0) { - if (NTYPE(qn->target) == NT_ENCLOSE) { - EncloseNode* en = NENCLOSE(qn->target); - if (en->type == ENCLOSE_MEMORY) { - if (NTYPE(en->target) == NT_QTFR) { - QtfrNode* q = NQTFR(en->target); - if (IS_REPEAT_INFINITE(q->upper) - && q->greedy == qn->greedy) { - qn->upper = (qn->lower == 0 ? 1 : qn->lower); - if (qn->upper == 1) - child_state = state; - } - } - } - } - } - } + if (qn->upper > 1) { + /* {0,1}, {1,1} are allowed */ + child_state |= CEC_IN_FINITE_REPEAT; + + /* check (a*){n,m}, (a+){n,m} => (a*){n,n}, (a+){n,n} */ + if (env->backrefed_mem == 0) { + if (NTYPE(qn->target) == NT_ENCLOSE) { + EncloseNode* en = NENCLOSE(qn->target); + if (en->type == ENCLOSE_MEMORY) { + if (NTYPE(en->target) == NT_QTFR) { + QtfrNode* q = NQTFR(en->target); + if (IS_REPEAT_INFINITE(q->upper) + && q->greedy == qn->greedy) { + qn->upper = (qn->lower == 0 ? 1 : qn->lower); + if (qn->upper == 1) + child_state = state; + } + } + } + } + } + } } if (state & CEC_IN_FINITE_REPEAT) { - qn->comb_exp_check_num = -1; + qn->comb_exp_check_num = -1; } else { - if (IS_REPEAT_INFINITE(qn->upper)) { - var_num = CEC_INFINITE_NUM; - child_state |= CEC_IN_INFINITE_REPEAT; - } - else { - var_num = qn->upper - qn->lower; - } - - if (var_num >= CEC_THRES_NUM_BIG_REPEAT) - add_state |= CEC_CONT_BIG_REPEAT; - - if (((state & CEC_IN_INFINITE_REPEAT) != 0 && var_num != 0) || - ((state & CEC_CONT_BIG_REPEAT) != 0 && - var_num >= CEC_THRES_NUM_BIG_REPEAT)) { - if (qn->comb_exp_check_num == 0) { - env->num_comb_exp_check++; - qn->comb_exp_check_num = env->num_comb_exp_check; - if (env->curr_max_regnum > env->comb_exp_max_regnum) - env->comb_exp_max_regnum = env->curr_max_regnum; - } - } + if (IS_REPEAT_INFINITE(qn->upper)) { + var_num = CEC_INFINITE_NUM; + child_state |= CEC_IN_INFINITE_REPEAT; + } + else { + var_num = qn->upper - qn->lower; + } + + if (var_num >= CEC_THRES_NUM_BIG_REPEAT) + add_state |= CEC_CONT_BIG_REPEAT; + + if (((state & CEC_IN_INFINITE_REPEAT) != 0 && var_num != 0) || + ((state & CEC_CONT_BIG_REPEAT) != 0 && + var_num >= CEC_THRES_NUM_BIG_REPEAT)) { + if (qn->comb_exp_check_num == 0) { + env->num_comb_exp_check++; + qn->comb_exp_check_num = env->num_comb_exp_check; + if (env->curr_max_regnum > env->comb_exp_max_regnum) + env->comb_exp_max_regnum = env->curr_max_regnum; + } + } } r = setup_comb_exp_check(target, child_state, env); @@ -3857,17 +3877,17 @@ switch (en->type) { case ENCLOSE_MEMORY: - { - if (env->curr_max_regnum < en->regnum) - env->curr_max_regnum = en->regnum; - - r = setup_comb_exp_check(en->target, state, env); - } - break; + { + if (env->curr_max_regnum < en->regnum) + env->curr_max_regnum = en->regnum; + + r = setup_comb_exp_check(en->target, state, env); + } + break; default: - r = setup_comb_exp_check(en->target, state, env); - break; + r = setup_comb_exp_check(en->target, state, env); + break; } } break; @@ -3889,13 +3909,6 @@ } #endif -#define IN_ALT (1<<0) -#define IN_NOT (1<<1) -#define IN_REPEAT (1<<2) -#define IN_VAR_REPEAT (1<<3) -#define IN_CALL (1<<4) -#define IN_RECCALL (1<<5) - /* setup_tree does the following work. 1. check empty loop. (set qn->target_empty_info) 2. expand ignore-case in char class. @@ -3917,11 +3930,11 @@ { Node* prev = NULL_NODE; do { - r = setup_tree(NCAR(node), reg, state, env); - if (IS_NOT_NULL(prev) && r == 0) { - r = next_setup(prev, NCAR(node), reg); - } - prev = NCAR(node); + r = setup_tree(NCAR(node), reg, state, env); + if (IS_NOT_NULL(prev) && r == 0) { + r = next_setup(prev, NCAR(node), reg); + } + prev = NCAR(node); } while (r == 0 && IS_NOT_NULL(node = NCDR(node))); } break; @@ -3937,7 +3950,7 @@ case NT_STR: if (IS_IGNORECASE(reg->options) && !NSTRING_IS_RAW(node)) { - r = expand_case_fold_string(node, reg); + r = expand_case_fold_string(node, reg, state); } break; @@ -3958,15 +3971,15 @@ BRefNode* br = NBREF(node); p = BACKREFS_P(br); for (i = 0; i < br->back_num; i++) { - if (p[i] > env->num_mem) return ONIGERR_INVALID_BACKREF; - BIT_STATUS_ON_AT(env->backrefed_mem, p[i]); - BIT_STATUS_ON_AT(env->bt_mem_start, p[i]); + if (p[i] > env->num_mem) return ONIGERR_INVALID_BACKREF; + BIT_STATUS_ON_AT(env->backrefed_mem, p[i]); + BIT_STATUS_ON_AT(env->bt_mem_start, p[i]); #ifdef USE_BACKREF_WITH_LEVEL - if (IS_BACKREF_NEST_LEVEL(br)) { - BIT_STATUS_ON_AT(env->bt_mem_end, p[i]); - } + if (IS_BACKREF_NEST_LEVEL(br)) { + BIT_STATUS_ON_AT(env->bt_mem_end, p[i]); + } #endif - SET_ENCLOSE_STATUS(nodes[p[i]], NST_MEM_BACKREFED); + SET_ENCLOSE_STATUS(nodes[p[i]], NST_MEM_BACKREFED); } } break; @@ -3978,100 +3991,100 @@ Node* target = qn->target; if ((state & IN_REPEAT) != 0) { - qn->state |= NST_IN_REPEAT; + qn->state |= NST_IN_REPEAT; } if (IS_REPEAT_INFINITE(qn->upper) || qn->upper >= 1) { - r = get_min_match_length(target, &d, env); - if (r) break; - if (d == 0) { - qn->target_empty_info = NQ_TARGET_IS_EMPTY; + r = get_min_match_length(target, &d, env); + if (r) break; + if (d == 0) { + qn->target_empty_info = NQ_TARGET_IS_EMPTY; #ifdef USE_MONOMANIAC_CHECK_CAPTURES_IN_ENDLESS_REPEAT - r = quantifiers_memory_node_info(target); - if (r < 0) break; - if (r > 0) { - qn->target_empty_info = r; - } + r = quantifiers_memory_node_info(target); + if (r < 0) break; + if (r > 0) { + qn->target_empty_info = r; + } #endif #if 0 - r = get_max_match_length(target, &d, env); - if (r == 0 && d == 0) { - /* ()* ==> ()?, ()+ ==> () */ - qn->upper = 1; - if (qn->lower > 1) qn->lower = 1; - if (NTYPE(target) == NT_STR) { - qn->upper = qn->lower = 0; /* /(?:)+/ ==> // */ - } - } + r = get_max_match_length(target, &d, env); + if (r == 0 && d == 0) { + /* ()* ==> ()?, ()+ ==> () */ + qn->upper = 1; + if (qn->lower > 1) qn->lower = 1; + if (NTYPE(target) == NT_STR) { + qn->upper = qn->lower = 0; /* /(?:)+/ ==> // */ + } + } #endif - } + } } state |= IN_REPEAT; if (qn->lower != qn->upper) - state |= IN_VAR_REPEAT; + state |= IN_VAR_REPEAT; r = setup_tree(target, reg, state, env); if (r) break; /* expand string */ #define EXPAND_STRING_MAX_LENGTH 100 if (NTYPE(target) == NT_STR) { - if (qn->lower > 1) { - int i, n = qn->lower; - OnigDistance len = NSTRING_LEN(target); - StrNode* sn = NSTR(target); - Node* np; - - np = onig_node_new_str(sn->s, sn->end); - if (IS_NULL(np)) return ONIGERR_MEMORY; - NSTR(np)->flag = sn->flag; - - for (i = 1; i < n && (i+1) * len <= EXPAND_STRING_MAX_LENGTH; i++) { - r = onig_node_str_cat(np, sn->s, sn->end); - if (r) { - onig_node_free(np); - return r; - } - } - if (i < qn->upper || IS_REPEAT_INFINITE(qn->upper)) { - Node *np1, *np2; - - qn->lower -= i; - if (! IS_REPEAT_INFINITE(qn->upper)) - qn->upper -= i; - - np1 = onig_node_new_list(np, NULL); - if (IS_NULL(np1)) { - onig_node_free(np); - return ONIGERR_MEMORY; - } - swap_node(np1, node); - np2 = onig_node_list_add(node, np1); - if (IS_NULL(np2)) { - onig_node_free(np1); - return ONIGERR_MEMORY; - } - } - else { - swap_node(np, node); - onig_node_free(np); - } - break; /* break case NT_QTFR: */ - } + if (qn->lower > 1) { + int i, n = qn->lower; + OnigDistance len = NSTRING_LEN(target); + StrNode* sn = NSTR(target); + Node* np; + + np = onig_node_new_str(sn->s, sn->end); + if (IS_NULL(np)) return ONIGERR_MEMORY; + NSTR(np)->flag = sn->flag; + + for (i = 1; i < n && (i+1) * len <= EXPAND_STRING_MAX_LENGTH; i++) { + r = onig_node_str_cat(np, sn->s, sn->end); + if (r) { + onig_node_free(np); + return r; + } + } + if (i < qn->upper || IS_REPEAT_INFINITE(qn->upper)) { + Node *np1, *np2; + + qn->lower -= i; + if (! IS_REPEAT_INFINITE(qn->upper)) + qn->upper -= i; + + np1 = onig_node_new_list(np, NULL); + if (IS_NULL(np1)) { + onig_node_free(np); + return ONIGERR_MEMORY; + } + swap_node(np1, node); + np2 = onig_node_list_add(node, np1); + if (IS_NULL(np2)) { + onig_node_free(np1); + return ONIGERR_MEMORY; + } + } + else { + swap_node(np, node); + onig_node_free(np); + } + break; /* break case NT_QTFR: */ + } } #ifdef USE_OP_PUSH_OR_JUMP_EXACT if (qn->greedy && (qn->target_empty_info != 0)) { - if (NTYPE(target) == NT_QTFR) { - QtfrNode* tqn = NQTFR(target); - if (IS_NOT_NULL(tqn->head_exact)) { - qn->head_exact = tqn->head_exact; - tqn->head_exact = NULL; - } - } - else { - qn->head_exact = get_head_value_node(qn->target, 1, reg); - } + if (NTYPE(target) == NT_QTFR) { + QtfrNode* tqn = NQTFR(target); + if (IS_NOT_NULL(tqn->head_exact)) { + qn->head_exact = tqn->head_exact; + tqn->head_exact = NULL; + } + } + else { + qn->head_exact = get_head_value_node(qn->target, 1, reg); + } } #endif } @@ -4083,61 +4096,61 @@ switch (en->type) { case ENCLOSE_OPTION: - { - OnigOptionType options = reg->options; - reg->options = NENCLOSE(node)->option; - r = setup_tree(NENCLOSE(node)->target, reg, state, env); - reg->options = options; - } - break; + { + OnigOptionType options = reg->options; + reg->options = NENCLOSE(node)->option; + r = setup_tree(NENCLOSE(node)->target, reg, state, env); + reg->options = options; + } + break; case ENCLOSE_MEMORY: - if ((state & (IN_ALT | IN_NOT | IN_VAR_REPEAT | IN_CALL)) != 0) { - BIT_STATUS_ON_AT(env->bt_mem_start, en->regnum); - /* SET_ENCLOSE_STATUS(node, NST_MEM_IN_ALT_NOT); */ - } - if (IS_ENCLOSE_CALLED(en)) - state |= IN_CALL; - if (IS_ENCLOSE_RECURSION(en)) - state |= IN_RECCALL; - else if ((state & IN_RECCALL) != 0) - SET_CALL_RECURSION(node); - r = setup_tree(en->target, reg, state, env); - break; + if ((state & (IN_ALT | IN_NOT | IN_VAR_REPEAT | IN_CALL)) != 0) { + BIT_STATUS_ON_AT(env->bt_mem_start, en->regnum); + /* SET_ENCLOSE_STATUS(node, NST_MEM_IN_ALT_NOT); */ + } + if (IS_ENCLOSE_CALLED(en)) + state |= IN_CALL; + if (IS_ENCLOSE_RECURSION(en)) + state |= IN_RECCALL; + else if ((state & IN_RECCALL) != 0) + SET_CALL_RECURSION(node); + r = setup_tree(en->target, reg, state, env); + break; case ENCLOSE_STOP_BACKTRACK: - { - Node* target = en->target; - r = setup_tree(target, reg, state, env); - if (NTYPE(target) == NT_QTFR) { - QtfrNode* tqn = NQTFR(target); - if (IS_REPEAT_INFINITE(tqn->upper) && tqn->lower <= 1 && - tqn->greedy != 0) { /* (?>a*), a*+ etc... */ - int qtype = NTYPE(tqn->target); - if (IS_NODE_TYPE_SIMPLE(qtype)) - SET_ENCLOSE_STATUS(node, NST_STOP_BT_SIMPLE_REPEAT); - } - } - } - break; + { + Node* target = en->target; + r = setup_tree(target, reg, state, env); + if (NTYPE(target) == NT_QTFR) { + QtfrNode* tqn = NQTFR(target); + if (IS_REPEAT_INFINITE(tqn->upper) && tqn->lower <= 1 && + tqn->greedy != 0) { /* (?>a*), a*+ etc... */ + int qtype = NTYPE(tqn->target); + if (IS_NODE_TYPE_SIMPLE(qtype)) + SET_ENCLOSE_STATUS(node, NST_STOP_BT_SIMPLE_REPEAT); + } + } + } + break; case ENCLOSE_CONDITION: #ifdef USE_NAMED_GROUP - if (! IS_ENCLOSE_NAME_REF(NENCLOSE(node)) && - env->num_named > 0 && - IS_SYNTAX_BV(env->syntax, ONIG_SYN_CAPTURE_ONLY_NAMED_GROUP) && - !ONIG_IS_OPTION_ON(env->option, ONIG_OPTION_CAPTURE_GROUP)) { - return ONIGERR_NUMBERED_BACKREF_OR_CALL_NOT_ALLOWED; - } -#endif - if (NENCLOSE(node)->regnum > env->num_mem) - return ONIGERR_INVALID_BACKREF; - r = setup_tree(NENCLOSE(node)->target, reg, state, env); - break; + if (! IS_ENCLOSE_NAME_REF(NENCLOSE(node)) && + env->num_named > 0 && + IS_SYNTAX_BV(env->syntax, ONIG_SYN_CAPTURE_ONLY_NAMED_GROUP) && + !ONIG_IS_OPTION_ON(env->option, ONIG_OPTION_CAPTURE_GROUP)) { + return ONIGERR_NUMBERED_BACKREF_OR_CALL_NOT_ALLOWED; + } +#endif + if (NENCLOSE(node)->regnum > env->num_mem) + return ONIGERR_INVALID_BACKREF; + r = setup_tree(NENCLOSE(node)->target, reg, state, env); + break; case ENCLOSE_ABSENT: - r = setup_tree(NENCLOSE(node)->target, reg, state, env); - break; + r = setup_tree(NENCLOSE(node)->target, reg, state, env); + break; } } break; @@ -4148,11 +4161,11 @@ switch (an->type) { case ANCHOR_PREC_READ: - r = setup_tree(an->target, reg, state, env); - break; + r = setup_tree(an->target, reg, state, env); + break; case ANCHOR_PREC_READ_NOT: - r = setup_tree(an->target, reg, (state | IN_NOT), env); - break; + r = setup_tree(an->target, reg, (state | IN_NOT), env); + break; /* allowed node types in look-behind */ #define ALLOWED_TYPE_IN_LB \ @@ -4174,30 +4187,31 @@ ANCHOR_WORD_BEGIN | ANCHOR_WORD_END ) case ANCHOR_LOOK_BEHIND: - { - r = check_type_tree(an->target, ALLOWED_TYPE_IN_LB, - ALLOWED_ENCLOSE_IN_LB, ALLOWED_ANCHOR_IN_LB); - if (r < 0) return r; - if (r > 0) return ONIGERR_INVALID_LOOK_BEHIND_PATTERN; - if (NTYPE(node) != NT_ANCHOR) goto restart; - r = setup_tree(an->target, reg, state, env); - if (r != 0) return r; - r = setup_look_behind(node, reg, env); - } - break; + { + r = check_type_tree(an->target, ALLOWED_TYPE_IN_LB, + ALLOWED_ENCLOSE_IN_LB, ALLOWED_ANCHOR_IN_LB); + if (r < 0) return r; + if (r > 0) return ONIGERR_INVALID_LOOK_BEHIND_PATTERN; + if (NTYPE(node) != NT_ANCHOR) goto restart; + r = setup_tree(an->target, reg, (state | IN_LOOK_BEHIND), env); + if (r != 0) return r; + r = setup_look_behind(node, reg, env); + } + break; case ANCHOR_LOOK_BEHIND_NOT: - { - r = check_type_tree(an->target, ALLOWED_TYPE_IN_LB, - ALLOWED_ENCLOSE_IN_LB_NOT, ALLOWED_ANCHOR_IN_LB_NOT); - if (r < 0) return r; - if (r > 0) return ONIGERR_INVALID_LOOK_BEHIND_PATTERN; - if (NTYPE(node) != NT_ANCHOR) goto restart; - r = setup_tree(an->target, reg, (state | IN_NOT), env); - if (r != 0) return r; - r = setup_look_behind(node, reg, env); - } - break; + { + r = check_type_tree(an->target, ALLOWED_TYPE_IN_LB, + ALLOWED_ENCLOSE_IN_LB_NOT, ALLOWED_ANCHOR_IN_LB_NOT); + if (r < 0) return r; + if (r > 0) return ONIGERR_INVALID_LOOK_BEHIND_PATTERN; + if (NTYPE(node) != NT_ANCHOR) goto restart; + r = setup_tree(an->target, reg, (state | IN_NOT | IN_LOOK_BEHIND), + env); + if (r != 0) return r; + r = setup_look_behind(node, reg, env); + } + break; } } break; @@ -4209,126 +4223,65 @@ return r; } -#ifndef USE_SUNDAY_QUICK_SEARCH -/* set skip map for Boyer-Moore search */ +/* set skip map for Sunday's quick search */ static int set_bm_skip(UChar* s, UChar* end, regex_t* reg, - UChar skip[], int** int_skip, int ignore_case) + UChar skip[], int** int_skip, int ignore_case) { OnigDistance i, len; int clen, flen, n, j, k; - UChar *p, buf[ONIGENC_GET_CASE_FOLD_CODES_MAX_NUM][ONIGENC_MBC_CASE_FOLD_MAXLEN]; + UChar *p, buf[ONIGENC_MBC_CASE_FOLD_MAXLEN]; OnigCaseFoldCodeItem items[ONIGENC_GET_CASE_FOLD_CODES_MAX_NUM]; OnigEncoding enc = reg->enc; len = end - s; if (len < ONIG_CHAR_TABLE_SIZE) { - for (i = 0; i < ONIG_CHAR_TABLE_SIZE; i++) skip[i] = (UChar )len; - - n = 0; - for (i = 0; i < len - 1; i += clen) { - p = s + i; - if (ignore_case) - n = ONIGENC_GET_CASE_FOLD_CODES_BY_STR(enc, reg->case_fold_flag, - p, end, items); - clen = enclen(enc, p, end); - if (p + clen > end) - clen = (int )(end - p); - - for (j = 0; j < n; j++) { - if ((items[j].code_len != 1) || (items[j].byte_len != clen)) - return 1; /* different length isn't supported. */ - flen = ONIGENC_CODE_TO_MBC(enc, items[j].code[0], buf[j]); - if (flen != clen) - return 1; /* different length isn't supported. */ - } - for (j = 0; j < clen; j++) { - skip[s[i + j]] = (UChar )(len - 1 - i - j); - for (k = 0; k < n; k++) { - skip[buf[k][j]] = (UChar )(len - 1 - i - j); - } + if (ignore_case) { + for (i = 0; i < len; i += clen) { + p = s + i; + n = ONIGENC_GET_CASE_FOLD_CODES_BY_STR(enc, reg->case_fold_flag, + p, end, items); + clen = enclen(enc, p, end); + if (p + clen > end) + clen = (int )(end - p); + + for (j = 0; j < n; j++) { + if ((items[j].code_len != 1) || (items[j].byte_len != clen)) { + /* Different length isn't supported. Stop optimization at here. */ + end = p; + goto endcheck; + } + flen = ONIGENC_CODE_TO_MBC(enc, items[j].code[0], buf); + if (flen != clen) { + /* Different length isn't supported. Stop optimization at here. */ + end = p; + goto endcheck; + } + } } +endcheck: + ; } - } - else { -# if OPT_EXACT_MAXLEN < ONIG_CHAR_TABLE_SIZE - /* This should not happen. */ - return ONIGERR_TYPE_BUG; -# else - if (IS_NULL(*int_skip)) { - *int_skip = (int* )xmalloc(sizeof(int) * ONIG_CHAR_TABLE_SIZE); - if (IS_NULL(*int_skip)) return ONIGERR_MEMORY; - } - for (i = 0; i < ONIG_CHAR_TABLE_SIZE; i++) (*int_skip)[i] = (int )len; - - n = 0; - for (i = 0; i < len - 1; i += clen) { - p = s + i; - if (ignore_case) - n = ONIGENC_GET_CASE_FOLD_CODES_BY_STR(enc, reg->case_fold_flag, - p, end, items); - clen = enclen(enc, p, end); - if (p + clen > end) - clen = (int )(end - p); - - for (j = 0; j < n; j++) { - if ((items[j].code_len != 1) || (items[j].byte_len != clen)) - return 1; /* different length isn't supported. */ - flen = ONIGENC_CODE_TO_MBC(enc, items[j].code[0], buf[j]); - if (flen != clen) - return 1; /* different length isn't supported. */ - } - for (j = 0; j < clen; j++) { - (*int_skip)[s[i + j]] = (int )(len - 1 - i - j); - for (k = 0; k < n; k++) { - (*int_skip)[buf[k][j]] = (int )(len - 1 - i - j); - } - } - } -# endif - } - return 0; -} - -#else /* USE_SUNDAY_QUICK_SEARCH */ - -/* set skip map for Sunday's quick search */ -static int -set_bm_skip(UChar* s, UChar* end, regex_t* reg, - UChar skip[], int** int_skip, int ignore_case) -{ - OnigDistance i, len; - int clen, flen, n, j, k; - UChar *p, buf[ONIGENC_GET_CASE_FOLD_CODES_MAX_NUM][ONIGENC_MBC_CASE_FOLD_MAXLEN]; - OnigCaseFoldCodeItem items[ONIGENC_GET_CASE_FOLD_CODES_MAX_NUM]; - OnigEncoding enc = reg->enc; - - len = end - s; - if (len < ONIG_CHAR_TABLE_SIZE) { - for (i = 0; i < ONIG_CHAR_TABLE_SIZE; i++) skip[i] = (UChar )(len + 1); + len = end - s; + for (i = 0; i < ONIG_CHAR_TABLE_SIZE; i++) + skip[i] = (UChar )(len + 1); n = 0; for (i = 0; i < len; i += clen) { p = s + i; if (ignore_case) - n = ONIGENC_GET_CASE_FOLD_CODES_BY_STR(enc, reg->case_fold_flag, - p, end, items); + n = ONIGENC_GET_CASE_FOLD_CODES_BY_STR(enc, reg->case_fold_flag, + p, end, items); clen = enclen(enc, p, end); if (p + clen > end) - clen = (int )(end - p); + clen = (int )(end - p); - for (j = 0; j < n; j++) { - if ((items[j].code_len != 1) || (items[j].byte_len != clen)) - return 1; /* different length isn't supported. */ - flen = ONIGENC_CODE_TO_MBC(enc, items[j].code[0], buf[j]); - if (flen != clen) - return 1; /* different length isn't supported. */ - } for (j = 0; j < clen; j++) { - skip[s[i + j]] = (UChar )(len - i - j); - for (k = 0; k < n; k++) { - skip[buf[k][j]] = (UChar )(len - i - j); - } + skip[s[i + j]] = (UChar )(len - i - j); + for (k = 0; k < n; k++) { + ONIGENC_CODE_TO_MBC(enc, items[k].code[0], buf); + skip[buf[j]] = (UChar )(len - i - j); + } } } } @@ -4347,31 +4300,30 @@ for (i = 0; i < len; i += clen) { p = s + i; if (ignore_case) - n = ONIGENC_GET_CASE_FOLD_CODES_BY_STR(enc, reg->case_fold_flag, - p, end, items); + n = ONIGENC_GET_CASE_FOLD_CODES_BY_STR(enc, reg->case_fold_flag, + p, end, items); clen = enclen(enc, p, end); if (p + clen > end) - clen = (int )(end - p); + clen = (int )(end - p); for (j = 0; j < n; j++) { - if ((items[j].code_len != 1) || (items[j].byte_len != clen)) - return 1; /* different length isn't supported. */ - flen = ONIGENC_CODE_TO_MBC(enc, items[j].code[0], buf[j]); - if (flen != clen) - return 1; /* different length isn't supported. */ + if ((items[j].code_len != 1) || (items[j].byte_len != clen)) + return 1; /* different length isn't supported. */ + flen = ONIGENC_CODE_TO_MBC(enc, items[j].code[0], buf[j]); + if (flen != clen) + return 1; /* different length isn't supported. */ } for (j = 0; j < clen; j++) { - (*int_skip)[s[i + j]] = (int )(len - i - j); - for (k = 0; k < n; k++) { - (*int_skip)[buf[k][j]] = (int )(len - i - j); - } + (*int_skip)[s[i + j]] = (int )(len - i - j); + for (k = 0; k < n; k++) { + (*int_skip)[buf[k][j]] = (int )(len - i - j); + } } } # endif } - return 0; + return (int)len; } -#endif /* USE_SUNDAY_QUICK_SEARCH */ typedef struct { OnigDistance min; /* min byte length */ @@ -4562,7 +4514,7 @@ static void concat_opt_anc_info(OptAncInfo* to, OptAncInfo* left, OptAncInfo* right, - OnigDistance left_len, OnigDistance right_len) + OnigDistance left_len, OnigDistance right_len) { clear_opt_anc_info(to); @@ -4678,7 +4630,7 @@ static void concat_opt_exact_info_str(OptExactInfo* to, UChar* s, UChar* end, - int raw ARG_UNUSED, OnigEncoding enc) + int raw ARG_UNUSED, OnigEncoding enc) { int i, j, len; UChar *p; @@ -4923,7 +4875,7 @@ if (add->exb.len > 0 && to->len.max == 0) { concat_opt_anc_info(&tanc, &to->anc, &add->exb.anc, - to->len.max, add->len.max); + to->len.max, add->len.max); copy_opt_anc_info(&add->exb.anc, &tanc); } @@ -4954,12 +4906,12 @@ if (to->expr.len > 0) { if (add->len.max > 0) { if (to->expr.len > (int )add->len.max) - to->expr.len = (int )add->len.max; + to->expr.len = (int )add->len.max; if (to->expr.mmd.max == 0) - select_opt_exact_info(enc, &to->exb, &to->expr); + select_opt_exact_info(enc, &to->exb, &to->expr); else - select_opt_exact_info(enc, &to->exm, &to->expr); + select_opt_exact_info(enc, &to->exm, &to->expr); } } else if (add->expr.len > 0) { @@ -5005,11 +4957,11 @@ copy_opt_env(&nenv, env); do { - r = optimize_node_left(NCAR(nd), &nopt, &nenv); - if (r == 0) { - add_mml(&nenv.mmd, &nopt.len); - concat_left_node_opt_info(env->enc, opt, &nopt); - } + r = optimize_node_left(NCAR(nd), &nopt, &nenv); + if (r == 0) { + add_mml(&nenv.mmd, &nopt.len); + concat_left_node_opt_info(env->enc, opt, &nopt); + } } while (r == 0 && IS_NOT_NULL(nd = NCDR(nd))); } break; @@ -5020,11 +4972,11 @@ Node* nd = node; do { - r = optimize_node_left(NCAR(nd), &nopt, env); - if (r == 0) { - if (nd == node) copy_node_opt_info(opt, &nopt); - else alt_merge_node_opt_info(opt, &nopt, env); - } + r = optimize_node_left(NCAR(nd), &nopt, env); + if (r == 0) { + if (nd == node) copy_node_opt_info(opt, &nopt); + else alt_merge_node_opt_info(opt, &nopt, env); + } } while ((r == 0) && IS_NOT_NULL(nd = NCDR(nd))); } break; @@ -5036,40 +4988,40 @@ int is_raw = NSTRING_IS_RAW(node); if (! NSTRING_IS_AMBIG(node)) { - concat_opt_exact_info_str(&opt->exb, sn->s, sn->end, - is_raw, env->enc); - opt->exb.ignore_case = 0; - if (slen > 0) { - add_char_opt_map_info(&opt->map, *(sn->s), env->enc); - } - set_mml(&opt->len, slen, slen); + concat_opt_exact_info_str(&opt->exb, sn->s, sn->end, + is_raw, env->enc); + opt->exb.ignore_case = 0; + if (slen > 0) { + add_char_opt_map_info(&opt->map, *(sn->s), env->enc); + } + set_mml(&opt->len, slen, slen); } else { - OnigDistance max; + OnigDistance max; - if (NSTRING_IS_DONT_GET_OPT_INFO(node)) { - int n = onigenc_strlen(env->enc, sn->s, sn->end); - max = ONIGENC_MBC_MAXLEN_DIST(env->enc) * (OnigDistance)n; - } - else { - concat_opt_exact_info_str(&opt->exb, sn->s, sn->end, - is_raw, env->enc); - opt->exb.ignore_case = 1; - - if (slen > 0) { - r = add_char_amb_opt_map_info(&opt->map, sn->s, sn->end, - env->enc, env->case_fold_flag); - if (r != 0) break; - } + if (NSTRING_IS_DONT_GET_OPT_INFO(node)) { + int n = onigenc_strlen(env->enc, sn->s, sn->end); + max = (OnigDistance )ONIGENC_MBC_MAXLEN_DIST(env->enc) * (OnigDistance)n; + } + else { + concat_opt_exact_info_str(&opt->exb, sn->s, sn->end, + is_raw, env->enc); + opt->exb.ignore_case = 1; + + if (slen > 0) { + r = add_char_amb_opt_map_info(&opt->map, sn->s, sn->end, + env->enc, env->case_fold_flag); + if (r != 0) break; + } - max = slen; - } + max = slen; + } - set_mml(&opt->len, slen, max); + set_mml(&opt->len, slen, max); } if ((OnigDistance )opt->exb.len == slen) - opt->exb.reach_end = 1; + opt->exb.reach_end = 1; } break; @@ -5081,19 +5033,19 @@ /* no need to check ignore case. (set in setup_tree()) */ if (IS_NOT_NULL(cc->mbuf) || IS_NCCLASS_NOT(cc)) { - OnigDistance min = ONIGENC_MBC_MINLEN(env->enc); - OnigDistance max = ONIGENC_MBC_MAXLEN_DIST(env->enc); + OnigDistance min = ONIGENC_MBC_MINLEN(env->enc); + OnigDistance max = ONIGENC_MBC_MAXLEN_DIST(env->enc); - set_mml(&opt->len, min, max); + set_mml(&opt->len, min, max); } else { - for (i = 0; i < SINGLE_BYTE_SIZE; i++) { - z = BITSET_AT(cc->bs, i); - if ((z && !IS_NCCLASS_NOT(cc)) || (!z && IS_NCCLASS_NOT(cc))) { - add_char_opt_map_info(&opt->map, (UChar )i, env->enc); - } - } - set_mml(&opt->len, 1, 1); + for (i = 0; i < SINGLE_BYTE_SIZE; i++) { + z = BITSET_AT(cc->bs, i); + if ((z && !IS_NCCLASS_NOT(cc)) || (!z && IS_NCCLASS_NOT(cc))) { + add_char_opt_map_info(&opt->map, (UChar )i, env->enc); + } + } + set_mml(&opt->len, 1, 1); } } break; @@ -5106,30 +5058,30 @@ max = ONIGENC_MBC_MAXLEN_DIST(env->enc); if (max == 1) { - min = 1; + min = 1; - maxcode = NCTYPE(node)->ascii_range ? 0x80 : SINGLE_BYTE_SIZE; - switch (NCTYPE(node)->ctype) { - case ONIGENC_CTYPE_WORD: - if (NCTYPE(node)->not != 0) { - for (i = 0; i < SINGLE_BYTE_SIZE; i++) { - if (! ONIGENC_IS_CODE_WORD(env->enc, i) || i >= maxcode) { - add_char_opt_map_info(&opt->map, (UChar )i, env->enc); - } - } - } - else { - for (i = 0; i < maxcode; i++) { - if (ONIGENC_IS_CODE_WORD(env->enc, i)) { - add_char_opt_map_info(&opt->map, (UChar )i, env->enc); - } - } - } - break; - } + maxcode = NCTYPE(node)->ascii_range ? 0x80 : SINGLE_BYTE_SIZE; + switch (NCTYPE(node)->ctype) { + case ONIGENC_CTYPE_WORD: + if (NCTYPE(node)->not != 0) { + for (i = 0; i < SINGLE_BYTE_SIZE; i++) { + if (! ONIGENC_IS_CODE_WORD(env->enc, i) || i >= maxcode) { + add_char_opt_map_info(&opt->map, (UChar )i, env->enc); + } + } + } + else { + for (i = 0; i < maxcode; i++) { + if (ONIGENC_IS_CODE_WORD(env->enc, i)) { + add_char_opt_map_info(&opt->map, (UChar )i, env->enc); + } + } + } + break; + } } else { - min = ONIGENC_MBC_MINLEN(env->enc); + min = ONIGENC_MBC_MINLEN(env->enc); } set_mml(&opt->len, min, max); } @@ -5158,20 +5110,20 @@ case ANCHOR_PREC_READ: { - NodeOptInfo nopt; + NodeOptInfo nopt; + + r = optimize_node_left(NANCHOR(node)->target, &nopt, env); + if (r == 0) { + if (nopt.exb.len > 0) + copy_opt_exact_info(&opt->expr, &nopt.exb); + else if (nopt.exm.len > 0) + copy_opt_exact_info(&opt->expr, &nopt.exm); - r = optimize_node_left(NANCHOR(node)->target, &nopt, env); - if (r == 0) { - if (nopt.exb.len > 0) - copy_opt_exact_info(&opt->expr, &nopt.exb); - else if (nopt.exm.len > 0) - copy_opt_exact_info(&opt->expr, &nopt.exm); - - opt->expr.reach_end = 0; - - if (nopt.map.value > 0) - copy_opt_map_info(&opt->map, &nopt.map); - } + opt->expr.reach_end = 0; + + if (nopt.map.value > 0) + copy_opt_map_info(&opt->map, &nopt.map); + } } break; @@ -5189,8 +5141,8 @@ BRefNode* br = NBREF(node); if (br->state & NST_RECURSION) { - set_mml(&opt->len, 0, ONIG_INFINITE_DISTANCE); - break; + set_mml(&opt->len, 0, ONIG_INFINITE_DISTANCE); + break; } backs = BACKREFS_P(br); r = get_min_match_length(nodes[backs[0]], &min, env->scan_env); @@ -5198,12 +5150,12 @@ r = get_max_match_length(nodes[backs[0]], &max, env->scan_env); if (r != 0) break; for (i = 1; i < br->back_num; i++) { - r = get_min_match_length(nodes[backs[i]], &tmin, env->scan_env); - if (r != 0) break; - r = get_max_match_length(nodes[backs[i]], &tmax, env->scan_env); - if (r != 0) break; - if (min > tmin) min = tmin; - if (max < tmax) max = tmax; + r = get_min_match_length(nodes[backs[i]], &tmin, env->scan_env); + if (r != 0) break; + r = get_max_match_length(nodes[backs[i]], &tmax, env->scan_env); + if (r != 0) break; + if (min > tmin) min = tmin; + if (max < tmax) max = tmax; } if (r == 0) set_mml(&opt->len, min, max); } @@ -5232,45 +5184,45 @@ r = optimize_node_left(qn->target, &nopt, env); if (r) break; - if (/*qn->lower == 0 &&*/ IS_REPEAT_INFINITE(qn->upper)) { - if (env->mmd.max == 0 && - NTYPE(qn->target) == NT_CANY && qn->greedy) { - if (IS_MULTILINE(env->options)) - /* implicit anchor: /.*a/ ==> /\A.*a/ */ - add_opt_anc_info(&opt->anc, ANCHOR_ANYCHAR_STAR_ML); - else - add_opt_anc_info(&opt->anc, ANCHOR_ANYCHAR_STAR); - } + if (qn->lower == 0 && IS_REPEAT_INFINITE(qn->upper)) { + if (env->mmd.max == 0 && + NTYPE(qn->target) == NT_CANY && qn->greedy) { + if (IS_MULTILINE(env->options)) + /* implicit anchor: /.*a/ ==> /\A.*a/ */ + add_opt_anc_info(&opt->anc, ANCHOR_ANYCHAR_STAR_ML); + else + add_opt_anc_info(&opt->anc, ANCHOR_ANYCHAR_STAR); + } } else { - if (qn->lower > 0) { - copy_node_opt_info(opt, &nopt); - if (nopt.exb.len > 0) { - if (nopt.exb.reach_end) { - for (i = 2; i <= qn->lower && - ! is_full_opt_exact_info(&opt->exb); i++) { - concat_opt_exact_info(&opt->exb, &nopt.exb, env->enc); - } - if (i < qn->lower) { - opt->exb.reach_end = 0; - } - } - } - - if (qn->lower != qn->upper) { - opt->exb.reach_end = 0; - opt->exm.reach_end = 0; - } - if (qn->lower > 1) - opt->exm.reach_end = 0; - } + if (qn->lower > 0) { + copy_node_opt_info(opt, &nopt); + if (nopt.exb.len > 0) { + if (nopt.exb.reach_end) { + for (i = 2; i <= qn->lower && + ! is_full_opt_exact_info(&opt->exb); i++) { + concat_opt_exact_info(&opt->exb, &nopt.exb, env->enc); + } + if (i < qn->lower) { + opt->exb.reach_end = 0; + } + } + } + + if (qn->lower != qn->upper) { + opt->exb.reach_end = 0; + opt->exm.reach_end = 0; + } + if (qn->lower > 1) + opt->exm.reach_end = 0; + } } min = distance_multiply(nopt.len.min, qn->lower); if (IS_REPEAT_INFINITE(qn->upper)) - max = (nopt.len.max > 0 ? ONIG_INFINITE_DISTANCE : 0); + max = (nopt.len.max > 0 ? ONIG_INFINITE_DISTANCE : 0); else - max = distance_multiply(nopt.len.max, qn->upper); + max = distance_multiply(nopt.len.max, qn->upper); set_mml(&opt->len, min, max); } @@ -5282,47 +5234,47 @@ switch (en->type) { case ENCLOSE_OPTION: - { - OnigOptionType save = env->options; + { + OnigOptionType save = env->options; - env->options = en->option; - r = optimize_node_left(en->target, opt, env); - env->options = save; - } - break; + env->options = en->option; + r = optimize_node_left(en->target, opt, env); + env->options = save; + } + break; case ENCLOSE_MEMORY: #ifdef USE_SUBEXP_CALL - en->opt_count++; - if (en->opt_count > MAX_NODE_OPT_INFO_REF_COUNT) { - OnigDistance min, max; - - min = 0; - max = ONIG_INFINITE_DISTANCE; - if (IS_ENCLOSE_MIN_FIXED(en)) min = en->min_len; - if (IS_ENCLOSE_MAX_FIXED(en)) max = en->max_len; - set_mml(&opt->len, min, max); - } - else -#endif - { - r = optimize_node_left(en->target, opt, env); - - if (is_set_opt_anc_info(&opt->anc, ANCHOR_ANYCHAR_STAR_MASK)) { - if (BIT_STATUS_AT(env->scan_env->backrefed_mem, en->regnum)) - remove_opt_anc_info(&opt->anc, ANCHOR_ANYCHAR_STAR_MASK); - } - } - break; + en->opt_count++; + if (en->opt_count > MAX_NODE_OPT_INFO_REF_COUNT) { + OnigDistance min, max; + + min = 0; + max = ONIG_INFINITE_DISTANCE; + if (IS_ENCLOSE_MIN_FIXED(en)) min = en->min_len; + if (IS_ENCLOSE_MAX_FIXED(en)) max = en->max_len; + set_mml(&opt->len, min, max); + } + else +#endif + { + r = optimize_node_left(en->target, opt, env); + + if (is_set_opt_anc_info(&opt->anc, ANCHOR_ANYCHAR_STAR_MASK)) { + if (BIT_STATUS_AT(env->scan_env->backrefed_mem, en->regnum)) + remove_opt_anc_info(&opt->anc, ANCHOR_ANYCHAR_STAR_MASK); + } + } + break; case ENCLOSE_STOP_BACKTRACK: case ENCLOSE_CONDITION: - r = optimize_node_left(en->target, opt, env); - break; + r = optimize_node_left(en->target, opt, env); + break; case ENCLOSE_ABSENT: - set_mml(&opt->len, 0, ONIG_INFINITE_DISTANCE); - break; + set_mml(&opt->len, 0, ONIG_INFINITE_DISTANCE); + break; } } break; @@ -5330,7 +5282,7 @@ default: #ifdef ONIG_DEBUG fprintf(stderr, "optimize_node_left: undefined node type %d\n", - NTYPE(node)); + NTYPE(node)); #endif r = ONIGERR_TYPE_BUG; break; @@ -5342,7 +5294,6 @@ static int set_optimize_exact_info(regex_t* reg, OptExactInfo* e) { - int r; int allow_reverse; if (e->len == 0) return 0; @@ -5353,19 +5304,22 @@ reg->exact_end = reg->exact + e->len; allow_reverse = - ONIGENC_IS_ALLOWED_REVERSE_MATCH(reg->enc, reg->exact, reg->exact_end); + ONIGENC_IS_ALLOWED_REVERSE_MATCH(reg->enc, reg->exact, reg->exact_end); if (e->ignore_case > 0) { if (e->len >= 3 || (e->len >= 2 && allow_reverse)) { - r = set_bm_skip(reg->exact, reg->exact_end, reg, - reg->map, &(reg->int_map), 1); - if (r == 0) { - reg->optimize = (allow_reverse != 0 - ? ONIG_OPTIMIZE_EXACT_BM_IC : ONIG_OPTIMIZE_EXACT_BM_NOT_REV_IC); + e->len = set_bm_skip(reg->exact, reg->exact_end, reg, + reg->map, &(reg->int_map), 1); + reg->exact_end = reg->exact + e->len; + if (e->len >= 3) { + reg->optimize = (allow_reverse != 0 + ? ONIG_OPTIMIZE_EXACT_BM_IC : ONIG_OPTIMIZE_EXACT_BM_NOT_REV_IC); } - else { - reg->optimize = ONIG_OPTIMIZE_EXACT_IC; + else if (e->len > 0) { + reg->optimize = ONIG_OPTIMIZE_EXACT_IC; } + else + return 0; } else { reg->optimize = ONIG_OPTIMIZE_EXACT_IC; @@ -5373,15 +5327,10 @@ } else { if (e->len >= 3 || (e->len >= 2 && allow_reverse)) { - r = set_bm_skip(reg->exact, reg->exact_end, reg, - reg->map, &(reg->int_map), 0); - if (r == 0) { - reg->optimize = (allow_reverse != 0 - ? ONIG_OPTIMIZE_EXACT_BM : ONIG_OPTIMIZE_EXACT_BM_NOT_REV); - } - else { - reg->optimize = ONIG_OPTIMIZE_EXACT; - } + set_bm_skip(reg->exact, reg->exact_end, reg, + reg->map, &(reg->int_map), 0); + reg->optimize = (allow_reverse != 0 + ? ONIG_OPTIMIZE_EXACT_BM : ONIG_OPTIMIZE_EXACT_BM_NOT_REV); } else { reg->optimize = ONIG_OPTIMIZE_EXACT; @@ -5451,7 +5400,7 @@ reg->anchor &= ~ANCHOR_ANYCHAR_STAR_ML; reg->anchor |= opt.anc.right_anchor & (ANCHOR_END_BUF | ANCHOR_SEMI_END_BUF | - ANCHOR_PREC_READ_NOT); + ANCHOR_PREC_READ_NOT); if (reg->anchor & (ANCHOR_END_BUF | ANCHOR_SEMI_END_BUF)) { reg->anchor_dmin = opt.len.min; @@ -5461,7 +5410,7 @@ if (opt.exb.len > 0 || opt.exm.len > 0) { select_opt_exact_info(reg->enc, &opt.exb, &opt.exm); if (opt.map.value > 0 && - comp_opt_exact_or_map_info(&opt.exb, &opt.map) > 0) { + comp_opt_exact_or_map_info(&opt.exb, &opt.map) > 0) { goto set_map; } else { @@ -5505,7 +5454,7 @@ #ifdef ONIG_DEBUG static void print_enc_string(FILE* fp, OnigEncoding enc, - const UChar *s, const UChar *end) + const UChar *s, const UChar *end) { fprintf(fp, "\nPATTERN: /"); @@ -5517,10 +5466,10 @@ while (p < end) { code = ONIGENC_MBC_TO_CODE(enc, p, end); if (code >= 0x80) { - fprintf(fp, " 0x%04x ", (int )code); + fprintf(fp, " 0x%04x ", (int )code); } else { - fputc((int )code, fp); + fputc((int )code, fp); } p += enclen(enc, p, end); @@ -5641,15 +5590,15 @@ c = 0; fputc('[', f); for (i = 0; i < ONIG_CHAR_TABLE_SIZE; i++) { - if (reg->map[i] != 0) { - if (c > 0) fputs(", ", f); - c++; - if (ONIGENC_MBC_MAXLEN(reg->enc) == 1 && - ONIGENC_IS_CODE_PRINT(reg->enc, (OnigCodePoint )i)) - fputc(i, f); - else - fprintf(f, "%d", i); - } + if (reg->map[i] != 0) { + if (c > 0) fputs(", ", f); + c++; + if (ONIGENC_MBC_MAXLEN(reg->enc) == 1 && + ONIGENC_IS_CODE_PRINT(reg->enc, (OnigCodePoint )i)) + fputc(i, f); + else + fprintf(f, "%d", i); + } } fprintf(f, "]\n"); } @@ -5808,7 +5757,7 @@ #ifdef RUBY extern int onig_compile(regex_t* reg, const UChar* pattern, const UChar* pattern_end, - OnigErrorInfo* einfo) + OnigErrorInfo* einfo) { return onig_compile_ruby(reg, pattern, pattern_end, einfo, NULL, 0); } @@ -5817,11 +5766,11 @@ #ifdef RUBY extern int onig_compile_ruby(regex_t* reg, const UChar* pattern, const UChar* pattern_end, - OnigErrorInfo* einfo, const char *sourcefile, int sourceline) + OnigErrorInfo* einfo, const char *sourcefile, int sourceline) #else extern int onig_compile(regex_t* reg, const UChar* pattern, const UChar* pattern_end, - OnigErrorInfo* einfo) + OnigErrorInfo* einfo) #endif { #define COMPILE_INIT_SIZE 20 @@ -5938,10 +5887,10 @@ if (scan_env.comb_exp_max_regnum > 0) { int i; for (i = 1; i <= scan_env.comb_exp_max_regnum; i++) { - if (BIT_STATUS_AT(scan_env.backrefed_mem, i) != 0) { - scan_env.num_comb_exp_check = 0; - break; - } + if (BIT_STATUS_AT(scan_env.backrefed_mem, i) != 0) { + scan_env.num_comb_exp_check = 0; + break; + } } } } @@ -5963,6 +5912,7 @@ r = compile_tree(root, reg); if (r == 0) { r = add_opcode(reg, OP_END); + if (r != 0) goto err_unset; #ifdef USE_SUBEXP_CALL if (scan_env.num_call > 0) { r = unset_addr_list_fix(&uslist, reg); @@ -5975,9 +5925,9 @@ reg->stack_pop_level = STACK_POP_LEVEL_ALL; else { if (reg->bt_mem_start != 0) - reg->stack_pop_level = STACK_POP_LEVEL_MEM_START; + reg->stack_pop_level = STACK_POP_LEVEL_MEM_START; else - reg->stack_pop_level = STACK_POP_LEVEL_FREE; + reg->stack_pop_level = STACK_POP_LEVEL_FREE; } } #ifdef USE_SUBEXP_CALL @@ -6023,8 +5973,8 @@ extern int onig_reg_init(regex_t* reg, OnigOptionType option, - OnigCaseFoldType case_fold_flag, - OnigEncoding enc, const OnigSyntaxType* syntax) + OnigCaseFoldType case_fold_flag, + OnigEncoding enc, const OnigSyntaxType* syntax) { if (! onig_inited) onig_init(); @@ -6084,8 +6034,8 @@ extern int onig_new(regex_t** reg, const UChar* pattern, const UChar* pattern_end, - OnigOptionType option, OnigEncoding enc, const OnigSyntaxType* syntax, - OnigErrorInfo* einfo) + OnigOptionType option, OnigEncoding enc, const OnigSyntaxType* syntax, + OnigErrorInfo* einfo) { *reg = (regex_t* )xmalloc(sizeof(regex_t)); if (IS_NULL(*reg)) return ONIGERR_MEMORY; @@ -6438,9 +6388,9 @@ break; case ARG_OPTION: { - OnigOptionType option = *((OnigOptionType* )bp); - bp += SIZE_OPTION; - fprintf(f, ":%d", option); + OnigOptionType option = *((OnigOptionType* )bp); + bp += SIZE_OPTION; + fprintf(f, ":%d", option); } break; @@ -6489,13 +6439,13 @@ break; case OP_EXACTMBN: { - int mb_len; + int mb_len; - GET_LENGTH_INC(mb_len, bp); - GET_LENGTH_INC(len, bp); - fprintf(f, ":%d:%d:", mb_len, len); - n = len * mb_len; - while (n-- > 0) { fputc(*bp++, f); } + GET_LENGTH_INC(mb_len, bp); + GET_LENGTH_INC(len, bp); + fprintf(f, ":%d:%d:", mb_len, len); + n = len * mb_len; + while (n-- > 0) { fputc(*bp++, f); } } break; @@ -6559,40 +6509,40 @@ fputs(" ", f); GET_LENGTH_INC(len, bp); for (i = 0; i < len; i++) { - GET_MEMNUM_INC(mem, bp); - if (i > 0) fputs(", ", f); - fprintf(f, "%d", mem); + GET_MEMNUM_INC(mem, bp); + if (i > 0) fputs(", ", f); + fprintf(f, "%d", mem); } break; case OP_BACKREF_WITH_LEVEL: { - OnigOptionType option; - LengthType level; + OnigOptionType option; + LengthType level; - GET_OPTION_INC(option, bp); - fprintf(f, ":%d", option); - GET_LENGTH_INC(level, bp); - fprintf(f, ":%d", level); - - fputs(" ", f); - GET_LENGTH_INC(len, bp); - for (i = 0; i < len; i++) { - GET_MEMNUM_INC(mem, bp); - if (i > 0) fputs(", ", f); - fprintf(f, "%d", mem); - } + GET_OPTION_INC(option, bp); + fprintf(f, ":%d", option); + GET_LENGTH_INC(level, bp); + fprintf(f, ":%d", level); + + fputs(" ", f); + GET_LENGTH_INC(len, bp); + for (i = 0; i < len; i++) { + GET_MEMNUM_INC(mem, bp); + if (i > 0) fputs(", ", f); + fprintf(f, "%d", mem); + } } break; case OP_REPEAT: case OP_REPEAT_NG: { - mem = *((MemNumType* )bp); - bp += SIZE_MEMNUM; - addr = *((RelAddrType* )bp); - bp += SIZE_RELADDR; - fprintf(f, ":%d:%d", mem, addr); + mem = *((MemNumType* )bp); + bp += SIZE_MEMNUM; + addr = *((RelAddrType* )bp); + bp += SIZE_RELADDR; + fprintf(f, ":%d:%d", mem, addr); } break; @@ -6633,7 +6583,7 @@ default: fprintf(stderr, "onig_print_compiled_byte_code: undefined code %d\n", - bp[-1]); + bp[-1]); } } fputs("]", f); @@ -6690,8 +6640,8 @@ print_indent_tree(f, NCAR(node), indent + add); while (IS_NOT_NULL(node = NCDR(node))) { if (NTYPE(node) != type) { - fprintf(f, "ERROR: list/alt right is not a cons. %d\n", NTYPE(node)); - exit(0); + fprintf(f, "ERROR: list/alt right is not a cons. %d\n", NTYPE(node)); + exit(0); } print_indent_tree(f, NCAR(node), indent + add); } @@ -6699,12 +6649,12 @@ case NT_STR: fprintf(f, "<string%s:%"PRIxPTR">", - (NSTRING_IS_RAW(node) ? "-raw" : ""), (intptr_t )node); + (NSTRING_IS_RAW(node) ? "-raw" : ""), (intptr_t )node); for (p = NSTR(node)->s; p < NSTR(node)->end; p++) { if (*p >= 0x20 && *p < 0x7f) - fputc(*p, f); + fputc(*p, f); else { - fprintf(f, " 0x%02x", *p); + fprintf(f, " 0x%02x", *p); } } break; @@ -6718,8 +6668,8 @@ OnigCodePoint* end = (OnigCodePoint* )(bbuf->p + bbuf->used); fprintf(f, "%d", *data++); for (; data < end; data+=2) { - fprintf(f, ","); - fprintf(f, "%04x-%04x", data[0], data[1]); + fprintf(f, ","); + fprintf(f, "%04x-%04x", data[0], data[1]); } } break; @@ -6729,9 +6679,9 @@ switch (NCTYPE(node)->ctype) { case ONIGENC_CTYPE_WORD: if (NCTYPE(node)->not != 0) - fputs("not word", f); + fputs("not word", f); else - fputs("word", f); + fputs("word", f); break; default: @@ -6779,8 +6729,8 @@ p = BACKREFS_P(br); fprintf(f, "<backref:%"PRIxPTR">", (intptr_t )node); for (i = 0; i < br->back_num; i++) { - if (i > 0) fputs(", ", f); - fprintf(f, "%d", p[i]); + if (i > 0) fputs(", ", f); + fprintf(f, "%d", p[i]); } } break; @@ -6797,8 +6747,8 @@ case NT_QTFR: fprintf(f, "<quantifier:%"PRIxPTR">{%d,%d}%s\n", (intptr_t )node, - NQTFR(node)->lower, NQTFR(node)->upper, - (NQTFR(node)->greedy ? "" : "?")); + NQTFR(node)->lower, NQTFR(node)->upper, + (NQTFR(node)->greedy ? "" : "?")); print_indent_tree(f, NQTFR(node)->target, indent + add); break; diff -Nru ruby3.3-3.3.8/regenc.c ruby3.3-3.3.13/regenc.c --- ruby3.3-3.3.8/regenc.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/regenc.c 2026-10-23 03:17:41.000000000 +0000 @@ -89,7 +89,7 @@ extern UChar* onigenc_get_right_adjust_char_head_with_prev(OnigEncoding enc, - const UChar* start, const UChar* s, const UChar* end, const UChar** prev) + const UChar* start, const UChar* s, const UChar* end, const UChar** prev) { UChar* p = ONIGENC_LEFT_ADJUST_CHAR_HEAD(enc, start, s, end); @@ -425,8 +425,8 @@ extern int onigenc_ascii_apply_all_case_fold(OnigCaseFoldType flag ARG_UNUSED, - OnigApplyAllCaseFoldFunc f, void* arg, - OnigEncoding enc ARG_UNUSED) + OnigApplyAllCaseFoldFunc f, void* arg, + OnigEncoding enc ARG_UNUSED) { OnigCodePoint code; int i, r; @@ -446,8 +446,8 @@ extern int onigenc_ascii_get_case_fold_codes_by_str(OnigCaseFoldType flag ARG_UNUSED, - const OnigUChar* p, const OnigUChar* end ARG_UNUSED, - OnigCaseFoldCodeItem items[], OnigEncoding enc ARG_UNUSED) + const OnigUChar* p, const OnigUChar* end ARG_UNUSED, + OnigCaseFoldCodeItem items[], OnigEncoding enc ARG_UNUSED) { if (0x41 <= *p && *p <= 0x5a) { items[0].byte_len = 1; @@ -467,7 +467,7 @@ static int ss_apply_all_case_fold(OnigCaseFoldType flag ARG_UNUSED, - OnigApplyAllCaseFoldFunc f, void* arg) + OnigApplyAllCaseFoldFunc f, void* arg) { OnigCodePoint ss[] = { 0x73, 0x73 }; @@ -513,7 +513,7 @@ items[0].code_len = 1; items[0].code[0] = (OnigCodePoint )(*p + 0x20); if (*p == 0x53 && ess_tsett_flag != 0 && end > p + 1 - && (*(p+1) == 0x53 || *(p+1) == 0x73)) { + && (*(p+1) == 0x53 || *(p+1) == 0x73)) { /* SS */ items[1].byte_len = 2; items[1].code_len = 1; @@ -528,7 +528,7 @@ items[0].code_len = 1; items[0].code[0] = (OnigCodePoint )(*p - 0x20); if (*p == 0x73 && ess_tsett_flag != 0 && end > p + 1 - && (*(p+1) == 0x73 || *(p+1) == 0x53)) { + && (*(p+1) == 0x73 || *(p+1) == 0x53)) { /* ss */ items[1].byte_len = 2; items[1].code_len = 1; @@ -566,16 +566,16 @@ for (i = 0; i < map_size; i++) { if (*p == map[i].from) { - items[0].byte_len = 1; - items[0].code_len = 1; - items[0].code[0] = map[i].to; - return 1; + items[0].byte_len = 1; + items[0].code_len = 1; + items[0].code[0] = map[i].to; + return 1; } else if (*p == map[i].to) { - items[0].byte_len = 1; - items[0].code_len = 1; - items[0].code[0] = map[i].from; - return 1; + items[0].byte_len = 1; + items[0].code_len = 1; + items[0].code[0] = map[i].from; + return 1; } } } @@ -586,9 +586,9 @@ extern int onigenc_not_support_get_ctype_code_range(OnigCtype ctype ARG_UNUSED, - OnigCodePoint* sb_out ARG_UNUSED, - const OnigCodePoint* ranges[] ARG_UNUSED, - OnigEncoding enc) + OnigCodePoint* sb_out ARG_UNUSED, + const OnigCodePoint* ranges[] ARG_UNUSED, + OnigEncoding enc) { return ONIG_NO_SUPPORT_CONFIG; } @@ -605,7 +605,7 @@ /* for single byte encodings */ extern int onigenc_ascii_mbc_case_fold(OnigCaseFoldType flag ARG_UNUSED, const UChar** p, - const UChar* end, UChar* lower, OnigEncoding enc ARG_UNUSED) + const UChar* end, UChar* lower, OnigEncoding enc ARG_UNUSED) { *lower = ONIGENC_ASCII_CODE_TO_LOWER_CASE(**p); @@ -616,7 +616,7 @@ #if 0 extern int onigenc_ascii_is_mbc_ambiguous(OnigCaseFoldType flag ARG_UNUSED, - const UChar** pp, const UChar* end ARG_UNUSED) + const UChar** pp, const UChar* end ARG_UNUSED) { const UChar* p = *pp; @@ -627,14 +627,14 @@ extern int onigenc_single_byte_mbc_enc_len(const UChar* p ARG_UNUSED, const UChar* e ARG_UNUSED, - OnigEncoding enc ARG_UNUSED) + OnigEncoding enc ARG_UNUSED) { return 1; } extern OnigCodePoint onigenc_single_byte_mbc_to_code(const UChar* p, const UChar* end ARG_UNUSED, - OnigEncoding enc ARG_UNUSED) + OnigEncoding enc ARG_UNUSED) { return (OnigCodePoint )(*p); } @@ -658,25 +658,25 @@ extern UChar* onigenc_single_byte_left_adjust_char_head(const UChar* start ARG_UNUSED, - const UChar* s, - const UChar* end ARG_UNUSED, - OnigEncoding enc ARG_UNUSED) + const UChar* s, + const UChar* end ARG_UNUSED, + OnigEncoding enc ARG_UNUSED) { return (UChar* )s; } extern int onigenc_always_true_is_allowed_reverse_match(const UChar* s ARG_UNUSED, - const UChar* end ARG_UNUSED, - OnigEncoding enc ARG_UNUSED) + const UChar* end ARG_UNUSED, + OnigEncoding enc ARG_UNUSED) { return TRUE; } extern int onigenc_always_false_is_allowed_reverse_match(const UChar* s ARG_UNUSED, - const UChar* end ARG_UNUSED, - OnigEncoding enc ARG_UNUSED) + const UChar* end ARG_UNUSED, + OnigEncoding enc ARG_UNUSED) { return FALSE; } @@ -712,7 +712,7 @@ extern int onigenc_mbn_mbc_case_fold(OnigEncoding enc, OnigCaseFoldType flag ARG_UNUSED, const UChar** pp, const UChar* end ARG_UNUSED, - UChar* lower) + UChar* lower) { int len; const UChar *p = *pp; @@ -843,7 +843,7 @@ extern int onigenc_mb2_is_code_ctype(OnigEncoding enc, OnigCodePoint code, - unsigned int ctype) + unsigned int ctype) { if (code < 128) return ONIGENC_IS_ASCII_CODE_CTYPE(code, ctype); @@ -858,7 +858,7 @@ extern int onigenc_mb4_is_code_ctype(OnigEncoding enc, OnigCodePoint code, - unsigned int ctype) + unsigned int ctype) { if (code < 128) return ONIGENC_IS_ASCII_CODE_CTYPE(code, ctype); @@ -961,14 +961,14 @@ *pnum = *pnum + 1; onig_st_insert_strend(*table, name, name + strlen((char* )name), - (hash_data_type )(*pnum + ONIGENC_MAX_STD_CTYPE)); + (hash_data_type )(*pnum + ONIGENC_MAX_STD_CTYPE)); return 0; } #endif extern int onigenc_ascii_only_case_map(OnigCaseFoldType* flagP, const OnigUChar** pp, const OnigUChar* end, - OnigUChar* to, OnigUChar* to_end, const struct OnigEncodingTypeST* enc) + OnigUChar* to, OnigUChar* to_end, const struct OnigEncodingTypeST* enc) { OnigCodePoint code; OnigUChar *to_start = to; @@ -984,9 +984,10 @@ if (code >= 'a' && code <= 'z' && (flags & ONIGENC_CASE_UPCASE)) { flags |= ONIGENC_CASE_MODIFIED; - code += 'A' - 'a'; - } else if (code >= 'A' && code <= 'Z' && - (flags & (ONIGENC_CASE_DOWNCASE | ONIGENC_CASE_FOLD))) { + code -= 'a' - 'A'; + } + else if (code >= 'A' && code <= 'Z' && + (flags & (ONIGENC_CASE_DOWNCASE | ONIGENC_CASE_FOLD))) { flags |= ONIGENC_CASE_MODIFIED; code += 'a' - 'A'; } @@ -1000,8 +1001,8 @@ extern int onigenc_single_byte_ascii_only_case_map(OnigCaseFoldType* flagP, const OnigUChar** pp, - const OnigUChar* end, OnigUChar* to, OnigUChar* to_end, - const struct OnigEncodingTypeST* enc) + const OnigUChar* end, OnigUChar* to, OnigUChar* to_end, + const struct OnigEncodingTypeST* enc) { OnigCodePoint code; OnigUChar *to_start = to; @@ -1012,9 +1013,10 @@ if (code >= 'a' && code <= 'z' && (flags & ONIGENC_CASE_UPCASE)) { flags |= ONIGENC_CASE_MODIFIED; - code += 'A' - 'a'; - } else if (code >= 'A' && code <= 'Z' && - (flags & (ONIGENC_CASE_DOWNCASE | ONIGENC_CASE_FOLD))) { + code -= 'a' - 'A'; + } + else if (code >= 'A' && code <= 'Z' && + (flags & (ONIGENC_CASE_DOWNCASE | ONIGENC_CASE_FOLD))) { flags |= ONIGENC_CASE_MODIFIED; code += 'a' - 'A'; } diff -Nru ruby3.3-3.3.8/regenc.h ruby3.3-3.3.13/regenc.h --- ruby3.3-3.3.8/regenc.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/regenc.h 2026-10-23 03:17:41.000000000 +0000 @@ -118,6 +118,11 @@ typedef struct { short int len; +#if defined(__has_attribute) +# if __has_attribute(nonstring) + __attribute__((nonstring)) +# endif +#endif const UChar name[6]; int ctype; } PosixBracketEntryType; @@ -187,8 +192,8 @@ #define UTF16_IS_SURROGATE_SECOND(c) (((c) & 0xfc) == 0xdc) #define UTF16_IS_SURROGATE(c) (((c) & 0xf8) == 0xd8) #define UNICODE_VALID_CODEPOINT_P(c) ( \ - ((c) <= 0x10ffff) && \ - !((c) < 0x10000 && UTF16_IS_SURROGATE((c) >> 8))) + ((c) <= 0x10ffff) && \ + !((c) < 0x10000 && UTF16_IS_SURROGATE((c) >> 8))) #define ONIGENC_ISO_8859_1_TO_LOWER_CASE(c) \ OnigEncISO_8859_1_ToLowerCaseTable[c] @@ -234,8 +239,8 @@ # define OnigEncodingDefine(f,n) \ OnigEncodingDeclare(n); \ void Init_##f(void) { \ - ONIG_ENC_REGISTER(OnigEncodingName(n).name, \ - &OnigEncodingName(n)); \ + ONIG_ENC_REGISTER(OnigEncodingName(n).name, \ + &OnigEncodingName(n)); \ } \ OnigEncodingDeclare(n) #else diff -Nru ruby3.3-3.3.8/regerror.c ruby3.3-3.3.13/regerror.c --- ruby3.3-3.3.8/regerror.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/regerror.c 2026-10-23 03:17:41.000000000 +0000 @@ -165,6 +165,12 @@ p = "group number is too big for capture history"; break; case ONIGERR_INVALID_CHAR_PROPERTY_NAME: p = "invalid character property name {%n}"; break; + case ONIGERR_TOO_MANY_RANGE_REPEAT: + p = "too many range repeat"; break; + case ONIGERR_TOO_MANY_NULL_CHECK: + p = "too many null check"; break; + case ONIGERR_TOO_BIG_COMPILED_PROGRAM: + p = "too big compiled program"; break; case ONIGERR_TOO_MANY_CAPTURE_GROUPS: p = "too many capture groups are specified"; break; case ONIGERR_INVALID_CODE_POINT_VALUE: @@ -194,7 +200,7 @@ } static int to_ascii(OnigEncoding enc, UChar *s, UChar *end, - UChar buf[], int buf_size, int *is_over) + UChar buf[], int buf_size, int *is_over) { int len; UChar *p; @@ -206,24 +212,24 @@ while (p < end) { code = ONIGENC_MBC_TO_CODE(enc, p, end); if (code >= 0x80) { - if (code > 0xffff && len + 10 <= buf_size) { - sprint_byte_with_x((char*)(&(buf[len])), (unsigned int)(code >> 24)); - sprint_byte((char*)(&(buf[len+4])), (unsigned int)(code >> 16)); - sprint_byte((char*)(&(buf[len+6])), (unsigned int)(code >> 8)); - sprint_byte((char*)(&(buf[len+8])), (unsigned int)code); - len += 10; - } - else if (len + 6 <= buf_size) { - sprint_byte_with_x((char*)(&(buf[len])), (unsigned int)(code >> 8)); - sprint_byte((char*)(&(buf[len+4])), (unsigned int)code); - len += 6; - } - else { - break; - } + if (code > 0xffff && len + 10 <= buf_size) { + sprint_byte_with_x((char*)(&(buf[len])), (unsigned int)(code >> 24)); + sprint_byte((char*)(&(buf[len+4])), (unsigned int)(code >> 16)); + sprint_byte((char*)(&(buf[len+6])), (unsigned int)(code >> 8)); + sprint_byte((char*)(&(buf[len+8])), (unsigned int)code); + len += 10; + } + else if (len + 6 <= buf_size) { + sprint_byte_with_x((char*)(&(buf[len])), (unsigned int)(code >> 8)); + sprint_byte((char*)(&(buf[len+4])), (unsigned int)code); + len += 6; + } + else { + break; + } } else { - buf[len++] = (UChar )code; + buf[len++] = (UChar )code; } p += enclen(enc, p, end); @@ -267,27 +273,27 @@ case ONIGERR_INVALID_CHAR_PROPERTY_NAME: einfo = va_arg(vargs, OnigErrorInfo*); len = to_ascii(einfo->enc, einfo->par, einfo->par_end, - parbuf, MAX_ERROR_PAR_LEN - 3, &is_over); + parbuf, MAX_ERROR_PAR_LEN - 3, &is_over); q = onig_error_code_to_format(code); p = s; while (*q != '\0') { if (*q == '%') { - q++; - if (*q == 'n') { /* '%n': name */ - xmemcpy(p, parbuf, len); - p += len; - if (is_over != 0) { - xmemcpy(p, "...", 3); - p += 3; - } - q++; - } - else - goto normal_char; + q++; + if (*q == 'n') { /* '%n': name */ + xmemcpy(p, parbuf, len); + p += len; + if (is_over != 0) { + xmemcpy(p, "...", 3); + p += 3; + } + q++; + } + else + goto normal_char; } else { normal_char: - *p++ = *q++; + *p++ = *q++; } } *p = '\0'; @@ -347,24 +353,24 @@ } } else if (*p == '\\') { - *s++ = *p++; - len = enclen(enc, p, pat_end); - while (len-- > 0) *s++ = *p++; + *s++ = *p++; + len = enclen(enc, p, pat_end); + while (len-- > 0) *s++ = *p++; } else if (*p == '/') { - *s++ = (unsigned char )'\\'; - *s++ = *p++; + *s++ = (unsigned char )'\\'; + *s++ = *p++; } else if (!ONIGENC_IS_CODE_PRINT(enc, *p) && - (!ONIGENC_IS_CODE_SPACE(enc, *p) || + (!ONIGENC_IS_CODE_SPACE(enc, *p) || ONIGENC_IS_CODE_CNTRL(enc, *p))) { - sprint_byte_with_x((char* )bs, (unsigned int )(*p++)); - len = onigenc_str_bytelen_null(ONIG_ENCODING_ASCII, bs); + sprint_byte_with_x((char* )bs, (unsigned int )(*p++)); + len = onigenc_str_bytelen_null(ONIG_ENCODING_ASCII, bs); bp = bs; - while (len-- > 0) *s++ = *bp++; + while (len-- > 0) *s++ = *bp++; } else { - *s++ = *p++; + *s++ = *p++; } } @@ -381,7 +387,7 @@ va_list args; va_start(args, fmt); onig_vsnprintf_with_pattern(buf, bufsize, enc, - pat, pat_end, fmt, args); + pat, pat_end, fmt, args); va_end(args); } #endif diff -Nru ruby3.3-3.3.8/regexec.c ruby3.3-3.3.13/regexec.c --- ruby3.3-3.3.8/regexec.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/regexec.c 2026-10-23 03:17:41.000000000 +0000 @@ -55,7 +55,7 @@ # define ONIGENC_IS_MBC_ASCII_WORD(enc,s,end) \ (rb_enc_asciicompat(enc) ? (ISALNUM(*s) || *s=='_') : \ onigenc_ascii_is_code_ctype( \ - ONIGENC_MBC_TO_CODE(enc,s,end),ONIGENC_CTYPE_WORD,enc)) + ONIGENC_MBC_TO_CODE(enc,s,end),ONIGENC_CTYPE_WORD,enc)) #endif /* RUBY */ #ifdef USE_CRNL_AS_LINE_TERMINATOR @@ -66,28 +66,28 @@ is_mbc_newline_ex((enc),(p),(start),(end),(option),(check_prev)) static int is_mbc_newline_ex(OnigEncoding enc, const UChar *p, const UChar *start, - const UChar *end, OnigOptionType option, int check_prev) + const UChar *end, OnigOptionType option, int check_prev) { if (IS_NEWLINE_CRLF(option)) { if (ONIGENC_MBC_TO_CODE(enc, p, end) == 0x0a) { if (check_prev) { - const UChar *prev = onigenc_get_prev_char_head(enc, start, p, end); - if ((prev != NULL) && ONIGENC_MBC_TO_CODE(enc, prev, end) == 0x0d) - return 0; - else - return 1; + const UChar *prev = onigenc_get_prev_char_head(enc, start, p, end); + if ((prev != NULL) && ONIGENC_MBC_TO_CODE(enc, prev, end) == 0x0d) + return 0; + else + return 1; } else - return 1; + return 1; } else { const UChar *pnext = p + enclen(enc, p, end); if (pnext < end && - ONIGENC_MBC_TO_CODE(enc, p, end) == 0x0d && - ONIGENC_MBC_TO_CODE(enc, pnext, end) == 0x0a) - return 1; + ONIGENC_MBC_TO_CODE(enc, p, end) == 0x0d && + ONIGENC_MBC_TO_CODE(enc, pnext, end) == 0x0a) + return 1; if (ONIGENC_IS_MBC_NEWLINE(enc, p, end)) - return 1; + return 1; return 0; } } @@ -111,7 +111,7 @@ if (IS_NOT_NULL(node)) { for (i = 0; i < node->num_childs; i++) { if (IS_NOT_NULL(node->childs[i])) { - history_tree_free(node->childs[i]); + history_tree_free(node->childs[i]); } } for (i = 0; i < node->allocated; i++) { @@ -170,18 +170,18 @@ if (IS_NULL(parent->childs)) { n = HISTORY_TREE_INIT_ALLOC_SIZE; parent->childs = - (OnigCaptureTreeNode** )xmalloc(sizeof(OnigCaptureTreeNode*) * n); + (OnigCaptureTreeNode** )xmalloc(sizeof(OnigCaptureTreeNode*) * n); CHECK_NULL_RETURN_MEMERR(parent->childs); } else { OnigCaptureTreeNode** tmp; n = parent->allocated * 2; tmp = - (OnigCaptureTreeNode** )xrealloc(parent->childs, - sizeof(OnigCaptureTreeNode*) * n); + (OnigCaptureTreeNode** )xrealloc(parent->childs, + sizeof(OnigCaptureTreeNode*) * n); if (tmp == 0) { - history_tree_clear(parent); - return ONIGERR_MEMORY; + history_tree_clear(parent); + return ONIGERR_MEMORY; } parent->childs = tmp; } @@ -276,7 +276,7 @@ switch (*p++) { case OP_FINISH: case OP_END: - break; + break; case OP_EXACT1: p++; break; case OP_EXACT2: p += 2; break; @@ -284,50 +284,50 @@ case OP_EXACT4: p += 4; break; case OP_EXACT5: p += 5; break; case OP_EXACTN: - GET_LENGTH_INC(len, p); p += len; break; + GET_LENGTH_INC(len, p); p += len; break; case OP_EXACTMB2N1: p += 2; break; case OP_EXACTMB2N2: p += 4; break; case OP_EXACTMB2N3: p += 6; break; case OP_EXACTMB2N: - GET_LENGTH_INC(len, p); p += len * 2; break; + GET_LENGTH_INC(len, p); p += len * 2; break; case OP_EXACTMB3N: - GET_LENGTH_INC(len, p); p += len * 3; break; + GET_LENGTH_INC(len, p); p += len * 3; break; case OP_EXACTMBN: - { - int mb_len; - GET_LENGTH_INC(mb_len, p); - GET_LENGTH_INC(len, p); - p += mb_len * len; - } - break; + { + int mb_len; + GET_LENGTH_INC(mb_len, p); + GET_LENGTH_INC(len, p); + p += mb_len * len; + } + break; case OP_EXACT1_IC: - len = enclen(enc, p, pend); p += len; break; + len = enclen(enc, p, pend); p += len; break; case OP_EXACTN_IC: - GET_LENGTH_INC(len, p); p += len; break; + GET_LENGTH_INC(len, p); p += len; break; case OP_CCLASS: case OP_CCLASS_NOT: - p += SIZE_BITSET; break; + p += SIZE_BITSET; break; case OP_CCLASS_MB: case OP_CCLASS_MB_NOT: - GET_LENGTH_INC(len, p); p += len; break; + GET_LENGTH_INC(len, p); p += len; break; case OP_CCLASS_MIX: case OP_CCLASS_MIX_NOT: - p += SIZE_BITSET; - GET_LENGTH_INC(len, p); - p += len; - break; + p += SIZE_BITSET; + GET_LENGTH_INC(len, p); + p += len; + break; case OP_ANYCHAR: case OP_ANYCHAR_ML: - break; + break; case OP_ANYCHAR_STAR: case OP_ANYCHAR_ML_STAR: - num_cache_opcodes++; break; + num_cache_opcodes++; break; case OP_ANYCHAR_STAR_PEEK_NEXT: case OP_ANYCHAR_ML_STAR_PEEK_NEXT: - p++; num_cache_opcodes++; break; + p++; num_cache_opcodes++; break; case OP_WORD: case OP_NOT_WORD: @@ -335,7 +335,7 @@ case OP_NOT_WORD_BOUND: case OP_WORD_BEGIN: case OP_WORD_END: - break; + break; case OP_ASCII_WORD: case OP_NOT_ASCII_WORD: @@ -343,7 +343,7 @@ case OP_NOT_ASCII_WORD_BOUND: case OP_ASCII_WORD_BEGIN: case OP_ASCII_WORD_END: - break; + break; case OP_BEGIN_BUF: case OP_END_BUF: @@ -351,7 +351,7 @@ case OP_END_LINE: case OP_SEMI_END_BUF: case OP_BEGIN_POSITION: - break; + break; case OP_BACKREF1: case OP_BACKREF2: @@ -360,7 +360,7 @@ case OP_BACKREF_MULTI: case OP_BACKREF_MULTI_IC: case OP_BACKREF_WITH_LEVEL: - goto impossible; + goto impossible; case OP_MEMORY_START: case OP_MEMORY_START_PUSH: @@ -368,152 +368,152 @@ case OP_MEMORY_END_PUSH_REC: case OP_MEMORY_END: case OP_MEMORY_END_REC: - p += SIZE_MEMNUM; - // A memory (capture) in look-around is found. - if (lookaround_nesting != 0) { - goto impossible; + p += SIZE_MEMNUM; + // A memory (capture) in look-around is found. + if (lookaround_nesting != 0) { + goto impossible; } - break; + break; case OP_KEEP: - break; + break; case OP_FAIL: - break; + break; case OP_JUMP: - p += SIZE_RELADDR; - break; + p += SIZE_RELADDR; + break; case OP_PUSH: - p += SIZE_RELADDR; - num_cache_opcodes++; - break; + p += SIZE_RELADDR; + num_cache_opcodes++; + break; case OP_POP: - break; + break; case OP_PUSH_OR_JUMP_EXACT1: case OP_PUSH_IF_PEEK_NEXT: - p += SIZE_RELADDR + 1; num_cache_opcodes++; break; + p += SIZE_RELADDR + 1; num_cache_opcodes++; break; case OP_REPEAT: case OP_REPEAT_NG: - if (current_repeat_mem != -1) { - // A nested OP_REPEAT is not yet supported. - goto impossible; - } - GET_MEMNUM_INC(repeat_mem, p); - p += SIZE_RELADDR; - if (reg->repeat_range[repeat_mem].lower == 0) { - num_cache_opcodes++; - } - result = count_num_cache_opcodes_inner(reg, repeat_mem, lookaround_nesting, &p, &num_cache_opcodes); - if (result < 0 || num_cache_opcodes < 0) { - goto fail; - } + if (current_repeat_mem != -1) { + // A nested OP_REPEAT is not yet supported. + goto impossible; + } + GET_MEMNUM_INC(repeat_mem, p); + p += SIZE_RELADDR; + if (reg->repeat_range[repeat_mem].lower == 0) { + num_cache_opcodes++; + } + result = count_num_cache_opcodes_inner(reg, repeat_mem, lookaround_nesting, &p, &num_cache_opcodes); + if (result < 0 || num_cache_opcodes < 0) { + goto fail; + } { - OnigRepeatRange *repeat_range = ®->repeat_range[repeat_mem]; - if (repeat_range->lower < repeat_range->upper) { - num_cache_opcodes++; - } + OnigRepeatRange *repeat_range = ®->repeat_range[repeat_mem]; + if (repeat_range->lower < repeat_range->upper) { + num_cache_opcodes++; + } } - break; + break; case OP_REPEAT_INC: case OP_REPEAT_INC_NG: - GET_MEMNUM_INC(repeat_mem, p); - if (repeat_mem != current_repeat_mem) { - // A lone or invalid OP_REPEAT_INC is found. - goto impossible; - } - goto exit; + GET_MEMNUM_INC(repeat_mem, p); + if (repeat_mem != current_repeat_mem) { + // A lone or invalid OP_REPEAT_INC is found. + goto impossible; + } + goto exit; case OP_REPEAT_INC_SG: case OP_REPEAT_INC_NG_SG: - goto impossible; + goto impossible; case OP_NULL_CHECK_START: - p += SIZE_MEMNUM; - break; + p += SIZE_MEMNUM; + break; case OP_NULL_CHECK_END: case OP_NULL_CHECK_END_MEMST_PUSH: - p += SIZE_MEMNUM; - break; + p += SIZE_MEMNUM; + break; case OP_NULL_CHECK_END_MEMST: - p += SIZE_MEMNUM; - break; + p += SIZE_MEMNUM; + break; case OP_PUSH_POS: - if (lookaround_nesting < 0) { - // A look-around nested in a atomic grouping is found. - goto impossible; - } - result = count_num_cache_opcodes_inner(reg, current_repeat_mem, lookaround_nesting + 1, &p, &num_cache_opcodes); - if (result < 0 || num_cache_opcodes < 0) { - goto fail; - } - break; + if (lookaround_nesting < 0) { + // A look-around nested in a atomic grouping is found. + goto impossible; + } + result = count_num_cache_opcodes_inner(reg, current_repeat_mem, lookaround_nesting + 1, &p, &num_cache_opcodes); + if (result < 0 || num_cache_opcodes < 0) { + goto fail; + } + break; case OP_PUSH_POS_NOT: - if (lookaround_nesting < 0) { - // A look-around nested in a atomic grouping is found. - goto impossible; - } - p += SIZE_RELADDR; - result = count_num_cache_opcodes_inner(reg, current_repeat_mem, lookaround_nesting + 1, &p, &num_cache_opcodes); - if (result < 0 || num_cache_opcodes < 0) { - goto fail; - } - break; + if (lookaround_nesting < 0) { + // A look-around nested in a atomic grouping is found. + goto impossible; + } + p += SIZE_RELADDR; + result = count_num_cache_opcodes_inner(reg, current_repeat_mem, lookaround_nesting + 1, &p, &num_cache_opcodes); + if (result < 0 || num_cache_opcodes < 0) { + goto fail; + } + break; case OP_PUSH_LOOK_BEHIND_NOT: - if (lookaround_nesting < 0) { - // A look-around nested in a atomic grouping is found. - goto impossible; - } - p += SIZE_RELADDR; - p += SIZE_LENGTH; - result = count_num_cache_opcodes_inner(reg, current_repeat_mem, lookaround_nesting + 1, &p, &num_cache_opcodes); - if (result < 0 || num_cache_opcodes < 0) { - goto fail; - } - break; + if (lookaround_nesting < 0) { + // A look-around nested in a atomic grouping is found. + goto impossible; + } + p += SIZE_RELADDR; + p += SIZE_LENGTH; + result = count_num_cache_opcodes_inner(reg, current_repeat_mem, lookaround_nesting + 1, &p, &num_cache_opcodes); + if (result < 0 || num_cache_opcodes < 0) { + goto fail; + } + break; case OP_PUSH_STOP_BT: - if (lookaround_nesting != 0) { - // A nested atomic grouping is found. - goto impossible; - } - result = count_num_cache_opcodes_inner(reg, current_repeat_mem, -1, &p, &num_cache_opcodes); - if (result < 0 || num_cache_opcodes < 0) { - goto fail; - } - break; + if (lookaround_nesting != 0) { + // A nested atomic grouping is found. + goto impossible; + } + result = count_num_cache_opcodes_inner(reg, current_repeat_mem, -1, &p, &num_cache_opcodes); + if (result < 0 || num_cache_opcodes < 0) { + goto fail; + } + break; case OP_POP_POS: case OP_FAIL_POS: case OP_FAIL_LOOK_BEHIND_NOT: case OP_POP_STOP_BT: - goto exit; + goto exit; case OP_LOOK_BEHIND: - p += SIZE_LENGTH; - break; + p += SIZE_LENGTH; + break; case OP_PUSH_ABSENT_POS: case OP_ABSENT_END: case OP_ABSENT: - goto impossible; + goto impossible; case OP_CALL: case OP_RETURN: - goto impossible; + goto impossible; case OP_CONDITION: - goto impossible; + goto impossible; case OP_STATE_CHECK_PUSH: case OP_STATE_CHECK_PUSH_OR_JUMP: case OP_STATE_CHECK: case OP_STATE_CHECK_ANYCHAR_STAR: case OP_STATE_CHECK_ANYCHAR_ML_STAR: - goto impossible; + goto impossible; case OP_SET_OPTION_PUSH: case OP_SET_OPTION: - p += SIZE_OPTION; - break; + p += SIZE_OPTION; + break; default: - goto bytecode_error; + goto bytecode_error; } } @@ -582,7 +582,7 @@ switch (*p++) { case OP_FINISH: case OP_END: - break; + break; case OP_EXACT1: p++; break; case OP_EXACT2: p += 2; break; @@ -590,53 +590,53 @@ case OP_EXACT4: p += 4; break; case OP_EXACT5: p += 5; break; case OP_EXACTN: - GET_LENGTH_INC(len, p); p += len; break; + GET_LENGTH_INC(len, p); p += len; break; case OP_EXACTMB2N1: p += 2; break; case OP_EXACTMB2N2: p += 4; break; case OP_EXACTMB2N3: p += 6; break; case OP_EXACTMB2N: - GET_LENGTH_INC(len, p); p += len * 2; break; + GET_LENGTH_INC(len, p); p += len * 2; break; case OP_EXACTMB3N: - GET_LENGTH_INC(len, p); p += len * 3; break; + GET_LENGTH_INC(len, p); p += len * 3; break; case OP_EXACTMBN: - { - int mb_len; - GET_LENGTH_INC(mb_len, p); - GET_LENGTH_INC(len, p); - p += mb_len * len; - } - break; + { + int mb_len; + GET_LENGTH_INC(mb_len, p); + GET_LENGTH_INC(len, p); + p += mb_len * len; + } + break; case OP_EXACT1_IC: - len = enclen(enc, p, pend); p += len; break; + len = enclen(enc, p, pend); p += len; break; case OP_EXACTN_IC: - GET_LENGTH_INC(len, p); p += len; break; + GET_LENGTH_INC(len, p); p += len; break; case OP_CCLASS: case OP_CCLASS_NOT: - p += SIZE_BITSET; break; + p += SIZE_BITSET; break; case OP_CCLASS_MB: case OP_CCLASS_MB_NOT: - GET_LENGTH_INC(len, p); p += len; break; + GET_LENGTH_INC(len, p); p += len; break; case OP_CCLASS_MIX: case OP_CCLASS_MIX_NOT: - p += SIZE_BITSET; - GET_LENGTH_INC(len, p); - p += len; - break; + p += SIZE_BITSET; + GET_LENGTH_INC(len, p); + p += len; + break; case OP_ANYCHAR: case OP_ANYCHAR_ML: - break; + break; case OP_ANYCHAR_STAR: case OP_ANYCHAR_ML_STAR: - INC_CACHE_OPCODES; - break; + INC_CACHE_OPCODES; + break; case OP_ANYCHAR_STAR_PEEK_NEXT: case OP_ANYCHAR_ML_STAR_PEEK_NEXT: - p++; - INC_CACHE_OPCODES; - break; + p++; + INC_CACHE_OPCODES; + break; case OP_WORD: case OP_NOT_WORD: @@ -644,7 +644,7 @@ case OP_NOT_WORD_BOUND: case OP_WORD_BEGIN: case OP_WORD_END: - break; + break; case OP_ASCII_WORD: case OP_NOT_ASCII_WORD: @@ -652,7 +652,7 @@ case OP_NOT_ASCII_WORD_BOUND: case OP_ASCII_WORD_BEGIN: case OP_ASCII_WORD_END: - break; + break; case OP_BEGIN_BUF: case OP_END_BUF: @@ -660,7 +660,7 @@ case OP_END_LINE: case OP_SEMI_END_BUF: case OP_BEGIN_POSITION: - break; + break; case OP_BACKREF1: case OP_BACKREF2: @@ -669,7 +669,7 @@ case OP_BACKREF_MULTI: case OP_BACKREF_MULTI_IC: case OP_BACKREF_WITH_LEVEL: - goto unexpected_bytecode_error; + goto unexpected_bytecode_error; case OP_MEMORY_START: case OP_MEMORY_START_PUSH: @@ -677,149 +677,149 @@ case OP_MEMORY_END_PUSH_REC: case OP_MEMORY_END: case OP_MEMORY_END_REC: - p += SIZE_MEMNUM; - if (lookaround_nesting != 0) { - goto unexpected_bytecode_error; - } - break; + p += SIZE_MEMNUM; + if (lookaround_nesting != 0) { + goto unexpected_bytecode_error; + } + break; case OP_KEEP: - break; + break; case OP_FAIL: - break; + break; case OP_JUMP: - p += SIZE_RELADDR; - break; + p += SIZE_RELADDR; + break; case OP_PUSH: - p += SIZE_RELADDR; - INC_CACHE_OPCODES; - break; + p += SIZE_RELADDR; + INC_CACHE_OPCODES; + break; case OP_POP: - break; + break; case OP_PUSH_OR_JUMP_EXACT1: case OP_PUSH_IF_PEEK_NEXT: - p += SIZE_RELADDR + 1; - INC_CACHE_OPCODES; - break; + p += SIZE_RELADDR + 1; + INC_CACHE_OPCODES; + break; case OP_REPEAT: case OP_REPEAT_NG: - GET_MEMNUM_INC(repeat_mem, p); - p += SIZE_RELADDR; - if (reg->repeat_range[repeat_mem].lower == 0) { - INC_CACHE_OPCODES; - } - { - long num_cache_points_in_repeat = 0; + GET_MEMNUM_INC(repeat_mem, p); + p += SIZE_RELADDR; + if (reg->repeat_range[repeat_mem].lower == 0) { + INC_CACHE_OPCODES; + } + { + long num_cache_points_in_repeat = 0; long num_cache_points_at_repeat = cache_point; - OnigCacheOpcode* cache_opcodes_in_repeat = cache_opcodes; - result = init_cache_opcodes_inner(reg, repeat_mem, lookaround_nesting, &cache_opcodes, &p, &num_cache_points_in_repeat); - if (result != 0) { - goto fail; - } - OnigRepeatRange *repeat_range = ®->repeat_range[repeat_mem]; - if (repeat_range->lower < repeat_range->upper) { - INC_CACHE_OPCODES; - cache_point -= lookaround_nesting != 0 ? 2 : 1; - } - int repeat_bounds = repeat_range->upper == 0x7fffffff ? 1 : repeat_range->upper - repeat_range->lower; - cache_point += num_cache_points_in_repeat * repeat_range->lower + (num_cache_points_in_repeat + (lookaround_nesting != 0 ? 2 : 1)) * repeat_bounds; - for (; cache_opcodes_in_repeat < cache_opcodes; cache_opcodes_in_repeat++) { - cache_opcodes_in_repeat->num_cache_points_at_outer_repeat = num_cache_points_at_repeat; - cache_opcodes_in_repeat->num_cache_points_in_outer_repeat = num_cache_points_in_repeat; - } - } - break; + OnigCacheOpcode* cache_opcodes_in_repeat = cache_opcodes; + result = init_cache_opcodes_inner(reg, repeat_mem, lookaround_nesting, &cache_opcodes, &p, &num_cache_points_in_repeat); + if (result != 0) { + goto fail; + } + OnigRepeatRange *repeat_range = ®->repeat_range[repeat_mem]; + if (repeat_range->lower < repeat_range->upper) { + INC_CACHE_OPCODES; + cache_point -= lookaround_nesting != 0 ? 2 : 1; + } + int repeat_bounds = repeat_range->upper == 0x7fffffff ? 1 : repeat_range->upper - repeat_range->lower; + cache_point += num_cache_points_in_repeat * repeat_range->lower + (num_cache_points_in_repeat + (lookaround_nesting != 0 ? 2 : 1)) * repeat_bounds; + for (; cache_opcodes_in_repeat < cache_opcodes; cache_opcodes_in_repeat++) { + cache_opcodes_in_repeat->num_cache_points_at_outer_repeat = num_cache_points_at_repeat; + cache_opcodes_in_repeat->num_cache_points_in_outer_repeat = num_cache_points_in_repeat; + } + } + break; case OP_REPEAT_INC: case OP_REPEAT_INC_NG: - p += SIZE_MEMNUM; + p += SIZE_MEMNUM; goto exit; case OP_REPEAT_INC_SG: case OP_REPEAT_INC_NG_SG: - goto unexpected_bytecode_error; + goto unexpected_bytecode_error; case OP_NULL_CHECK_START: - p += SIZE_MEMNUM; - break; + p += SIZE_MEMNUM; + break; case OP_NULL_CHECK_END: case OP_NULL_CHECK_END_MEMST_PUSH: - p += SIZE_MEMNUM; - break; + p += SIZE_MEMNUM; + break; case OP_NULL_CHECK_END_MEMST: - p += SIZE_MEMNUM; - break; + p += SIZE_MEMNUM; + break; case OP_PUSH_POS: - lookaround: - { - OnigCacheOpcode* cache_opcodes_in_lookaround = cache_opcodes; - result = init_cache_opcodes_inner(reg, current_repeat_mem, lookaround_nesting + 1, &cache_opcodes, &p, &cache_point); - if (result != 0) { - goto fail; - } - UChar* match_addr = p - 1; - for (; cache_opcodes_in_lookaround < cache_opcodes; cache_opcodes_in_lookaround++) { - if (cache_opcodes_in_lookaround->match_addr == NULL) { - cache_opcodes_in_lookaround->match_addr = match_addr; - } - } - } - break; + lookaround: + { + OnigCacheOpcode* cache_opcodes_in_lookaround = cache_opcodes; + result = init_cache_opcodes_inner(reg, current_repeat_mem, lookaround_nesting + 1, &cache_opcodes, &p, &cache_point); + if (result != 0) { + goto fail; + } + UChar* match_addr = p - 1; + for (; cache_opcodes_in_lookaround < cache_opcodes; cache_opcodes_in_lookaround++) { + if (cache_opcodes_in_lookaround->match_addr == NULL) { + cache_opcodes_in_lookaround->match_addr = match_addr; + } + } + } + break; case OP_PUSH_POS_NOT: - p += SIZE_RELADDR; + p += SIZE_RELADDR; goto lookaround; case OP_PUSH_LOOK_BEHIND_NOT: - p += SIZE_RELADDR; - p += SIZE_LENGTH; + p += SIZE_RELADDR; + p += SIZE_LENGTH; goto lookaround; case OP_PUSH_STOP_BT: - { - OnigCacheOpcode* cache_opcodes_in_atomic = cache_opcodes; - result = init_cache_opcodes_inner(reg, current_repeat_mem, -1, &cache_opcodes, &p, &cache_point); - if (result != 0) { - goto fail; - } - UChar* match_addr = p - 1; - for (; cache_opcodes_in_atomic < cache_opcodes; cache_opcodes_in_atomic++) { - if (cache_opcodes_in_atomic->match_addr == NULL) { - cache_opcodes_in_atomic->match_addr = match_addr; - } - } - } - break; + { + OnigCacheOpcode* cache_opcodes_in_atomic = cache_opcodes; + result = init_cache_opcodes_inner(reg, current_repeat_mem, -1, &cache_opcodes, &p, &cache_point); + if (result != 0) { + goto fail; + } + UChar* match_addr = p - 1; + for (; cache_opcodes_in_atomic < cache_opcodes; cache_opcodes_in_atomic++) { + if (cache_opcodes_in_atomic->match_addr == NULL) { + cache_opcodes_in_atomic->match_addr = match_addr; + } + } + } + break; case OP_POP_POS: case OP_FAIL_POS: case OP_FAIL_LOOK_BEHIND_NOT: case OP_POP_STOP_BT: - goto exit; + goto exit; case OP_LOOK_BEHIND: - p += SIZE_LENGTH; - break; + p += SIZE_LENGTH; + break; case OP_ABSENT_END: case OP_ABSENT: - goto unexpected_bytecode_error; + goto unexpected_bytecode_error; case OP_CALL: case OP_RETURN: - goto unexpected_bytecode_error; + goto unexpected_bytecode_error; case OP_CONDITION: - goto unexpected_bytecode_error; + goto unexpected_bytecode_error; case OP_STATE_CHECK_PUSH: case OP_STATE_CHECK_PUSH_OR_JUMP: case OP_STATE_CHECK: case OP_STATE_CHECK_ANYCHAR_STAR: case OP_STATE_CHECK_ANYCHAR_ML_STAR: - goto unexpected_bytecode_error; + goto unexpected_bytecode_error; case OP_SET_OPTION_PUSH: case OP_SET_OPTION: - p += SIZE_OPTION; - break; + p += SIZE_OPTION; + break; default: - goto bytecode_error; + goto bytecode_error; } } @@ -1175,7 +1175,7 @@ }\ else {\ alloc_addr = (char* )xalloca(sizeof(OnigStackIndex) * (ptr_num)\ - + sizeof(OnigStackType) * (stack_num));\ + + sizeof(OnigStackType) * (stack_num));\ heap_addr = NULL;\ stk_alloc = (OnigStackType* )(alloc_addr + sizeof(OnigStackIndex) * (ptr_num));\ stk_base = stk_alloc;\ @@ -1208,7 +1208,7 @@ static int stack_double(OnigStackType** arg_stk_base, OnigStackType** arg_stk_end, - OnigStackType** arg_stk, OnigStackType* stk_alloc, OnigMatchArg* msa) + OnigStackType** arg_stk, OnigStackType* stk_alloc, OnigMatchArg* msa) { size_t n; OnigStackType *x, *stk_base, *stk_end, *stk; @@ -1232,9 +1232,9 @@ n *= 2; if (limit_size != 0 && n > limit_size) { if ((unsigned int )(stk_end - stk_base) == limit_size) - return ONIGERR_MATCH_STACK_LIMIT_OVER; + return ONIGERR_MATCH_STACK_LIMIT_OVER; else - n = limit_size; + n = limit_size; } x = (OnigStackType* )xrealloc(stk_base, sizeof(OnigStackType) * n); if (IS_NULL(x)) { @@ -1883,7 +1883,7 @@ } while(0) static int string_cmp_ic(OnigEncoding enc, int case_fold_flag, - UChar* s1, UChar** ps2, OnigDistance mblen, const UChar* text_end) + UChar* s1, UChar** ps2, OnigDistance mblen, const UChar* text_end) { UChar buf1[ONIGENC_MBC_CASE_FOLD_MAXLEN]; UChar buf2[ONIGENC_MBC_CASE_FOLD_MAXLEN]; @@ -1970,29 +1970,29 @@ if (k->type == STK_MEM_START) { n = k->u.mem.num; if (n <= ONIG_MAX_CAPTURE_HISTORY_GROUP && - BIT_STATUS_AT(reg->capture_history, n) != 0) { - child = history_node_new(); - CHECK_NULL_RETURN_MEMERR(child); - child->group = n; - child->beg = k->u.mem.pstr - str; - r = history_tree_add_child(node, child); - if (r != 0) { - history_tree_free(child); - return r; - } - *kp = (k + 1); - r = make_capture_history_tree(child, kp, stk_top, str, reg); - if (r != 0) return r; + BIT_STATUS_AT(reg->capture_history, n) != 0) { + child = history_node_new(); + CHECK_NULL_RETURN_MEMERR(child); + child->group = n; + child->beg = k->u.mem.pstr - str; + r = history_tree_add_child(node, child); + if (r != 0) { + history_tree_free(child); + return r; + } + *kp = (k + 1); + r = make_capture_history_tree(child, kp, stk_top, str, reg); + if (r != 0) return r; - k = *kp; - child->end = k->u.mem.pstr - str; + k = *kp; + child->end = k->u.mem.pstr - str; } } else if (k->type == STK_MEM_END) { if (k->u.mem.num == node->group) { - node->end = k->u.mem.pstr - str; - *kp = k; - return 0; + node->end = k->u.mem.pstr - str; + *kp = k; + return 0; } } k++; @@ -2017,9 +2017,9 @@ } static int backref_match_at_nested_level(regex_t* reg, - OnigStackType* top, OnigStackType* stk_base, - int ignore_case, int case_fold_flag, - int nest, int mem_num, UChar* memp, UChar** s, const UChar* send) + OnigStackType* top, OnigStackType* stk_base, + int ignore_case, int case_fold_flag, + int nest, int mem_num, UChar* memp, UChar** s, const UChar* send) { UChar *ss, *p, *pstart, *pend = NULL_UCHARP; int level; @@ -2037,33 +2037,33 @@ } else if (level == nest) { if (k->type == STK_MEM_START) { - if (mem_is_in_memp(k->u.mem.num, mem_num, memp)) { - pstart = k->u.mem.pstr; - if (pend != NULL_UCHARP) { - if (pend - pstart > send - *s) return 0; /* or goto next_mem; */ - p = pstart; - ss = *s; - - if (ignore_case != 0) { - if (string_cmp_ic(reg->enc, case_fold_flag, - pstart, &ss, pend - pstart, send) == 0) - return 0; /* or goto next_mem; */ - } - else { - while (p < pend) { - if (*p++ != *ss++) return 0; /* or goto next_mem; */ - } - } - - *s = ss; - return 1; - } - } + if (mem_is_in_memp(k->u.mem.num, mem_num, memp)) { + pstart = k->u.mem.pstr; + if (pend != NULL_UCHARP) { + if (pend - pstart > send - *s) return 0; /* or goto next_mem; */ + p = pstart; + ss = *s; + + if (ignore_case != 0) { + if (string_cmp_ic(reg->enc, case_fold_flag, + pstart, &ss, pend - pstart, send) == 0) + return 0; /* or goto next_mem; */ + } + else { + while (p < pend) { + if (*p++ != *ss++) return 0; /* or goto next_mem; */ + } + } + + *s = ss; + return 1; + } + } } else if (k->type == STK_MEM_END) { - if (mem_is_in_memp(k->u.mem.num, mem_num, memp)) { - pend = k->u.mem.pstr; - } + if (mem_is_in_memp(k->u.mem.num, mem_num, memp)) { + pend = k->u.mem.pstr; + } } } k--; @@ -2081,7 +2081,7 @@ static LARGE_INTEGER ts, te, freq; # define GETTIME(t) QueryPerformanceCounter(&(t)) # define TIMEDIFF(te,ts) (unsigned long )(((te).QuadPart - (ts).QuadPart) \ - * 1000000 / freq.QuadPart) + * 1000000 / freq.QuadPart) # else /* _WIN32 */ # define USE_TIMEOFDAY @@ -2147,7 +2147,7 @@ fprintf(f, " count prev time\n"); for (i = 0; OnigOpInfo[i].opcode >= 0; i++) { fprintf(f, "%8d: %8d: %10lu: %s\n", - OpCounter[i], OpPrevCounter[i], OpTime[i], OnigOpInfo[i].name); + OpCounter[i], OpPrevCounter[i], OpTime[i], OnigOpInfo[i].name); } fprintf(f, "\nmax stack depth: %d\n", MaxStackDepth); } @@ -2286,9 +2286,9 @@ static OnigPosition match_at(regex_t* reg, const UChar* str, const UChar* end, #ifdef USE_MATCH_RANGE_MUST_BE_INSIDE_OF_SPECIFIED_RANGE - const UChar* right_range, + const UChar* right_range, #endif - const UChar* sstart, UChar* sprev, OnigMatchArg* msa) + const UChar* sstart, UChar* sprev, OnigMatchArg* msa) { static const UChar FinishCode[] = { OP_FINISH }; @@ -2538,16 +2538,16 @@ } #ifndef USE_SUBEXP_CALL mem_start_stk--; /* for index start from 1, - mem_start_stk[1]..mem_start_stk[num_mem] */ + mem_start_stk[1]..mem_start_stk[num_mem] */ mem_end_stk--; /* for index start from 1, - mem_end_stk[1]..mem_end_stk[num_mem] */ + mem_end_stk[1]..mem_end_stk[num_mem] */ #endif #ifdef ONIG_DEBUG_MATCH fprintf(stderr, "match_at: str: %"PRIuPTR" (%p), end: %"PRIuPTR" (%p), start: %"PRIuPTR" (%p), sprev: %"PRIuPTR" (%p)\n", - (uintptr_t )str, str, (uintptr_t )end, end, (uintptr_t )sstart, sstart, (uintptr_t )sprev, sprev); + (uintptr_t )str, str, (uintptr_t )end, end, (uintptr_t )sstart, sstart, (uintptr_t )sprev, sprev); fprintf(stderr, "size: %d, start offset: %d\n", - (int )(end - str), (int )(sstart - str)); + (int )(end - str), (int )(sstart - str)); fprintf(stderr, "\n ofs> str stk:type addr:opcode\n"); #endif @@ -2567,10 +2567,10 @@ bp = buf; \ q = s; \ if (*op != OP_FINISH) { /* s may not be a valid pointer if OP_FINISH. */ \ - for (i = 0; i < 7 && q < end; i++) { \ - len = enclen(encode, q, end); \ - while (len-- > 0) *bp++ = *q++; \ - } \ + for (i = 0; i < 7 && q < end; i++) { \ + len = enclen(encode, q, end); \ + while (len-- > 0) *bp++ = *q++; \ + } \ if (q < end) { xmemcpy(bp, "...", 3); bp += 3; } \ } \ xmemcpy(bp, "\"", 1); bp += 1; \ @@ -2578,9 +2578,9 @@ fputs((char* )buf, stderr); \ for (i = 0; i < 20 - (bp - buf); i++) fputc(' ', stderr); \ fprintf(stderr, "%4"PRIdPTR":%s %4"PRIdPTR":", \ - stk - stk_base - 1, \ - (stk > stk_base) ? stack_type_str(stk[-1].type) : " ", \ - (op == FinishCode) ? (ptrdiff_t )-1 : op - reg->p); \ + stk - stk_base - 1, \ + (stk > stk_base) ? stack_type_str(stk[-1].type) : " ", \ + (op == FinishCode) ? (ptrdiff_t )-1 : op - reg->p); \ onig_print_compiled_byte_code(stderr, op, reg->p+reg->used, NULL, encode); \ fprintf(stderr, "\n"); \ } @@ -2609,16 +2609,16 @@ uint8_t match_cache_point_mask = 1 << (match_cache_point & 7);\ MATCH_CACHE_DEBUG;\ if (msa->match_cache_buf[match_cache_point_index] & match_cache_point_mask) {\ - MATCH_CACHE_DEBUG_HIT; MATCH_CACHE_HIT;\ - if (cache_opcode->lookaround_nesting == 0) goto fail;\ - else if (cache_opcode->lookaround_nesting < 0) {\ - if (check_extended_match_cache_point(msa->match_cache_buf, match_cache_point_index, match_cache_point_mask)) {\ + MATCH_CACHE_DEBUG_HIT; MATCH_CACHE_HIT;\ + if (cache_opcode->lookaround_nesting == 0) goto fail;\ + else if (cache_opcode->lookaround_nesting < 0) {\ + if (check_extended_match_cache_point(msa->match_cache_buf, match_cache_point_index, match_cache_point_mask)) {\ STACK_STOP_BT_FAIL;\ goto fail;\ } else goto fail;\ } else {\ - if (check_extended_match_cache_point(msa->match_cache_buf, match_cache_point_index, match_cache_point_mask)) {\ - p = cache_opcode->match_addr;\ + if (check_extended_match_cache_point(msa->match_cache_buf, match_cache_point_index, match_cache_point_mask)) {\ + p = cache_opcode->match_addr;\ MOP_OUT;\ JUMP;\ } else goto fail;\ @@ -2636,66 +2636,66 @@ CASE(OP_END) MOP_IN(OP_END); n = s - sstart; if (n > best_len) { - OnigRegion* region; + OnigRegion* region; #ifdef USE_FIND_LONGEST_SEARCH_ALL_OF_RANGE - if (IS_FIND_LONGEST(option)) { - if (n > msa->best_len) { - msa->best_len = n; - msa->best_s = (UChar* )sstart; - } - else - goto end_best_len; - } + if (IS_FIND_LONGEST(option)) { + if (n > msa->best_len) { + msa->best_len = n; + msa->best_s = (UChar* )sstart; + } + else + goto end_best_len; + } #endif - best_len = n; - region = msa->region; - if (region) { - region->beg[0] = ((pkeep > s) ? s : pkeep) - str; - region->end[0] = s - str; - for (i = 1; i <= num_mem; i++) { - if (mem_end_stk[i] != INVALID_STACK_INDEX) { - if (BIT_STATUS_AT(reg->bt_mem_start, i)) - region->beg[i] = STACK_AT(mem_start_stk[i])->u.mem.pstr - str; - else - region->beg[i] = (UChar* )((void* )mem_start_stk[i]) - str; - - region->end[i] = (BIT_STATUS_AT(reg->bt_mem_end, i) - ? STACK_AT(mem_end_stk[i])->u.mem.pstr - : (UChar* )((void* )mem_end_stk[i])) - str; - } - else { - region->beg[i] = region->end[i] = ONIG_REGION_NOTPOS; - } - } + best_len = n; + region = msa->region; + if (region) { + region->beg[0] = ((pkeep > s) ? s : pkeep) - str; + region->end[0] = s - str; + for (i = 1; i <= num_mem; i++) { + if (mem_end_stk[i] != INVALID_STACK_INDEX) { + if (BIT_STATUS_AT(reg->bt_mem_start, i)) + region->beg[i] = STACK_AT(mem_start_stk[i])->u.mem.pstr - str; + else + region->beg[i] = (UChar* )((void* )mem_start_stk[i]) - str; + + region->end[i] = (BIT_STATUS_AT(reg->bt_mem_end, i) + ? STACK_AT(mem_end_stk[i])->u.mem.pstr + : (UChar* )((void* )mem_end_stk[i])) - str; + } + else { + region->beg[i] = region->end[i] = ONIG_REGION_NOTPOS; + } + } #ifdef USE_CAPTURE_HISTORY - if (reg->capture_history != 0) { - int r; - OnigCaptureTreeNode* node; - - if (IS_NULL(region->history_root)) { - region->history_root = node = history_node_new(); - CHECK_NULL_RETURN_MEMERR(node); - } - else { - node = region->history_root; - history_tree_clear(node); - } - - node->group = 0; - node->beg = ((pkeep > s) ? s : pkeep) - str; - node->end = s - str; - - stkp = stk_base; - r = make_capture_history_tree(region->history_root, &stkp, - stk, (UChar* )str, reg); - if (r < 0) { - best_len = r; /* error code */ - goto finish; - } - } + if (reg->capture_history != 0) { + int r; + OnigCaptureTreeNode* node; + + if (IS_NULL(region->history_root)) { + region->history_root = node = history_node_new(); + CHECK_NULL_RETURN_MEMERR(node); + } + else { + node = region->history_root; + history_tree_clear(node); + } + + node->group = 0; + node->beg = ((pkeep > s) ? s : pkeep) - str; + node->end = s - str; + + stkp = stk_base; + r = make_capture_history_tree(region->history_root, &stkp, + stk, (UChar* )str, reg); + if (r < 0) { + best_len = r; /* error code */ + goto finish; + } + } #endif /* USE_CAPTURE_HISTORY */ - } /* if (region) */ + } /* if (region) */ } /* n > best_len */ #ifdef USE_FIND_LONGEST_SEARCH_ALL_OF_RANGE @@ -2704,18 +2704,17 @@ MOP_OUT; if (IS_FIND_CONDITION(option)) { - if (IS_FIND_NOT_EMPTY(option) && s == sstart) { - best_len = ONIG_MISMATCH; - goto fail; /* for retry */ - } - if (IS_FIND_LONGEST(option) && DATA_ENSURE_CHECK1) { - goto fail; /* for retry */ - } + if (IS_FIND_NOT_EMPTY(option) && s == sstart) { + best_len = ONIG_MISMATCH; + goto fail; /* for retry */ + } + if (IS_FIND_LONGEST(option) && DATA_ENSURE_CHECK1) { + goto fail; /* for retry */ + } } /* default behavior: return first-matching result. */ goto finish; - NEXT; CASE(OP_EXACT1) MOP_IN(OP_EXACT1); DATA_ENSURE(1); @@ -2726,22 +2725,22 @@ CASE(OP_EXACT1_IC) MOP_IN(OP_EXACT1_IC); { - int len; - UChar *q, lowbuf[ONIGENC_MBC_CASE_FOLD_MAXLEN]; + int len; + UChar *q, lowbuf[ONIGENC_MBC_CASE_FOLD_MAXLEN]; - DATA_ENSURE(1); - len = ONIGENC_MBC_CASE_FOLD(encode, - /* DISABLE_CASE_FOLD_MULTI_CHAR(case_fold_flag), */ - case_fold_flag, - &s, end, lowbuf); - DATA_ENSURE(0); - q = lowbuf; - while (len-- > 0) { - if (*p != *q) { - goto fail; - } - p++; q++; - } + DATA_ENSURE(1); + len = ONIGENC_MBC_CASE_FOLD(encode, + /* DISABLE_CASE_FOLD_MULTI_CHAR(case_fold_flag), */ + case_fold_flag, + &s, end, lowbuf); + DATA_ENSURE(0); + q = lowbuf; + while (len-- > 0) { + if (*p != *q) { + goto fail; + } + p++; q++; + } } MOP_OUT; NEXT; @@ -2802,7 +2801,7 @@ GET_LENGTH_INC(tlen, p); DATA_ENSURE(tlen); while (tlen-- > 0) { - if (*p++ != *s++) goto fail; + if (*p++ != *s++) goto fail; } sprev = s - 1; MOP_OUT; @@ -2810,26 +2809,26 @@ CASE(OP_EXACTN_IC) MOP_IN(OP_EXACTN_IC); { - int len; - UChar *q, *endp, lowbuf[ONIGENC_MBC_CASE_FOLD_MAXLEN]; + int len; + UChar *q, *endp, lowbuf[ONIGENC_MBC_CASE_FOLD_MAXLEN]; - GET_LENGTH_INC(tlen, p); - endp = p + tlen; + GET_LENGTH_INC(tlen, p); + endp = p + tlen; - while (p < endp) { - sprev = s; - DATA_ENSURE(1); - len = ONIGENC_MBC_CASE_FOLD(encode, - /* DISABLE_CASE_FOLD_MULTI_CHAR(case_fold_flag), */ - case_fold_flag, - &s, end, lowbuf); - DATA_ENSURE(0); - q = lowbuf; - while (len-- > 0) { - if (*p != *q) goto fail; - p++; q++; - } - } + while (p < endp) { + sprev = s; + DATA_ENSURE(1); + len = ONIGENC_MBC_CASE_FOLD(encode, + /* DISABLE_CASE_FOLD_MULTI_CHAR(case_fold_flag), */ + case_fold_flag, + &s, end, lowbuf); + DATA_ENSURE(0); + q = lowbuf; + while (len-- > 0) { + if (*p != *q) goto fail; + p++; q++; + } + } } MOP_OUT; @@ -2880,10 +2879,10 @@ GET_LENGTH_INC(tlen, p); DATA_ENSURE(tlen * 2); while (tlen-- > 0) { - if (*p != *s) goto fail; - p++; s++; - if (*p != *s) goto fail; - p++; s++; + if (*p != *s) goto fail; + p++; s++; + if (*p != *s) goto fail; + p++; s++; } sprev = s - 2; MOP_OUT; @@ -2893,12 +2892,12 @@ GET_LENGTH_INC(tlen, p); DATA_ENSURE(tlen * 3); while (tlen-- > 0) { - if (*p != *s) goto fail; - p++; s++; - if (*p != *s) goto fail; - p++; s++; - if (*p != *s) goto fail; - p++; s++; + if (*p != *s) goto fail; + p++; s++; + if (*p != *s) goto fail; + p++; s++; + if (*p != *s) goto fail; + p++; s++; } sprev = s - 3; MOP_OUT; @@ -2910,8 +2909,8 @@ tlen2 *= tlen; DATA_ENSURE(tlen2); while (tlen2-- > 0) { - if (*p != *s) goto fail; - p++; s++; + if (*p != *s) goto fail; + p++; s++; } sprev = s - tlen; MOP_OUT; @@ -2931,23 +2930,23 @@ cclass_mb: GET_LENGTH_INC(tlen, p); { - OnigCodePoint code; - UChar *ss; - int mb_len; - - DATA_ENSURE(1); - mb_len = enclen_approx(encode, s, end); - DATA_ENSURE(mb_len); - ss = s; - s += mb_len; - code = ONIGENC_MBC_TO_CODE(encode, ss, s); + OnigCodePoint code; + UChar *ss; + int mb_len; + + DATA_ENSURE(1); + mb_len = enclen_approx(encode, s, end); + DATA_ENSURE(mb_len); + ss = s; + s += mb_len; + code = ONIGENC_MBC_TO_CODE(encode, ss, s); #ifdef PLATFORM_UNALIGNED_WORD_ACCESS - if (! onig_is_in_code_range(p, code)) goto fail; + if (! onig_is_in_code_range(p, code)) goto fail; #else - q = p; - ALIGNMENT_RIGHT(q); - if (! onig_is_in_code_range(q, code)) goto fail; + q = p; + ALIGNMENT_RIGHT(q); + if (! onig_is_in_code_range(q, code)) goto fail; #endif } p += tlen; @@ -2957,17 +2956,17 @@ CASE(OP_CCLASS_MIX) MOP_IN(OP_CCLASS_MIX); DATA_ENSURE(1); if (ONIGENC_IS_MBC_HEAD(encode, s, end)) { - p += SIZE_BITSET; - goto cclass_mb; + p += SIZE_BITSET; + goto cclass_mb; } else { - if (BITSET_AT(((BitSetRef )p), *s) == 0) - goto fail; + if (BITSET_AT(((BitSetRef )p), *s) == 0) + goto fail; - p += SIZE_BITSET; - GET_LENGTH_INC(tlen, p); - p += tlen; - s++; + p += SIZE_BITSET; + GET_LENGTH_INC(tlen, p); + p += tlen; + s++; } MOP_OUT; NEXT; @@ -2983,36 +2982,36 @@ CASE(OP_CCLASS_MB_NOT) MOP_IN(OP_CCLASS_MB_NOT); DATA_ENSURE(1); if (! ONIGENC_IS_MBC_HEAD(encode, s, end)) { - s++; - GET_LENGTH_INC(tlen, p); - p += tlen; - goto cc_mb_not_success; + s++; + GET_LENGTH_INC(tlen, p); + p += tlen; + goto cc_mb_not_success; } cclass_mb_not: GET_LENGTH_INC(tlen, p); { - OnigCodePoint code; - UChar *ss; - int mb_len = enclen(encode, s, end); - - if (! DATA_ENSURE_CHECK(mb_len)) { - DATA_ENSURE(1); - s = (UChar* )end; - p += tlen; - goto cc_mb_not_success; - } + OnigCodePoint code; + UChar *ss; + int mb_len = enclen(encode, s, end); + + if (! DATA_ENSURE_CHECK(mb_len)) { + DATA_ENSURE(1); + s = (UChar* )end; + p += tlen; + goto cc_mb_not_success; + } - ss = s; - s += mb_len; - code = ONIGENC_MBC_TO_CODE(encode, ss, s); + ss = s; + s += mb_len; + code = ONIGENC_MBC_TO_CODE(encode, ss, s); #ifdef PLATFORM_UNALIGNED_WORD_ACCESS - if (onig_is_in_code_range(p, code)) goto fail; + if (onig_is_in_code_range(p, code)) goto fail; #else - q = p; - ALIGNMENT_RIGHT(q); - if (onig_is_in_code_range(q, code)) goto fail; + q = p; + ALIGNMENT_RIGHT(q); + if (onig_is_in_code_range(q, code)) goto fail; #endif } p += tlen; @@ -3024,17 +3023,17 @@ CASE(OP_CCLASS_MIX_NOT) MOP_IN(OP_CCLASS_MIX_NOT); DATA_ENSURE(1); if (ONIGENC_IS_MBC_HEAD(encode, s, end)) { - p += SIZE_BITSET; - goto cclass_mb_not; + p += SIZE_BITSET; + goto cclass_mb_not; } else { - if (BITSET_AT(((BitSetRef )p), *s) != 0) - goto fail; + if (BITSET_AT(((BitSetRef )p), *s) != 0) + goto fail; - p += SIZE_BITSET; - GET_LENGTH_INC(tlen, p); - p += tlen; - s++; + p += SIZE_BITSET; + GET_LENGTH_INC(tlen, p); + p += tlen; + s++; } MOP_OUT; NEXT; @@ -3058,52 +3057,52 @@ CASE(OP_ANYCHAR_STAR) MOP_IN(OP_ANYCHAR_STAR); while (DATA_ENSURE_CHECK1) { - CHECK_MATCH_CACHE; - STACK_PUSH_ALT(p, s, sprev, pkeep); - n = enclen_approx(encode, s, end); - DATA_ENSURE(n); - if (ONIGENC_IS_MBC_NEWLINE_EX(encode, s, str, end, option, 0)) goto fail; - sprev = s; - s += n; + CHECK_MATCH_CACHE; + STACK_PUSH_ALT(p, s, sprev, pkeep); + n = enclen_approx(encode, s, end); + DATA_ENSURE(n); + if (ONIGENC_IS_MBC_NEWLINE_EX(encode, s, str, end, option, 0)) goto fail; + sprev = s; + s += n; } MOP_OUT; JUMP; CASE(OP_ANYCHAR_ML_STAR) MOP_IN(OP_ANYCHAR_ML_STAR); while (DATA_ENSURE_CHECK1) { - CHECK_MATCH_CACHE; - STACK_PUSH_ALT(p, s, sprev, pkeep); - n = enclen_approx(encode, s, end); - if (n > 1) { - DATA_ENSURE(n); - sprev = s; - s += n; - } - else { - sprev = s; - s++; - } + CHECK_MATCH_CACHE; + STACK_PUSH_ALT(p, s, sprev, pkeep); + n = enclen_approx(encode, s, end); + if (n > 1) { + DATA_ENSURE(n); + sprev = s; + s += n; + } + else { + sprev = s; + s++; + } } MOP_OUT; JUMP; CASE(OP_ANYCHAR_STAR_PEEK_NEXT) MOP_IN(OP_ANYCHAR_STAR_PEEK_NEXT); while (DATA_ENSURE_CHECK1) { - CHECK_MATCH_CACHE; - if (*p == *s) { - STACK_PUSH_ALT(p + 1, s, sprev, pkeep); - } else { + CHECK_MATCH_CACHE; + if (*p == *s) { + STACK_PUSH_ALT(p + 1, s, sprev, pkeep); + } else { #ifdef USE_MATCH_CACHE - /* We need to increment num_fails here, for invoking a cache optimization correctly. */ - /* Actually, the matching will be failed if we use `OP_ANYCHAR_STAR` simply in this case.*/ - msa->num_fails++; + /* We need to increment num_fails here, for invoking a cache optimization correctly. */ + /* Actually, the matching will be failed if we use `OP_ANYCHAR_STAR` simply in this case.*/ + msa->num_fails++; #endif - } - n = enclen_approx(encode, s, end); - DATA_ENSURE(n); - if (ONIGENC_IS_MBC_NEWLINE_EX(encode, s, str, end, option, 0)) goto fail; - sprev = s; - s += n; + } + n = enclen_approx(encode, s, end); + DATA_ENSURE(n); + if (ONIGENC_IS_MBC_NEWLINE_EX(encode, s, str, end, option, 0)) goto fail; + sprev = s; + s += n; } p++; MOP_OUT; @@ -3111,26 +3110,26 @@ CASE(OP_ANYCHAR_ML_STAR_PEEK_NEXT)MOP_IN(OP_ANYCHAR_ML_STAR_PEEK_NEXT); while (DATA_ENSURE_CHECK1) { - CHECK_MATCH_CACHE; - if (*p == *s) { - STACK_PUSH_ALT(p + 1, s, sprev, pkeep); - } else { + CHECK_MATCH_CACHE; + if (*p == *s) { + STACK_PUSH_ALT(p + 1, s, sprev, pkeep); + } else { #ifdef USE_MATCH_CACHE - /* We need to increment num_fails here, for invoking a cache optimization correctly. */ - /* Actually, the matching will be failed if we use `OP_ANYCHAR_STAR_ML` simply in this case.*/ - msa->num_fails++; + /* We need to increment num_fails here, for invoking a cache optimization correctly. */ + /* Actually, the matching will be failed if we use `OP_ANYCHAR_STAR_ML` simply in this case.*/ + msa->num_fails++; #endif - } - n = enclen_approx(encode, s, end); - if (n > 1) { - DATA_ENSURE(n); - sprev = s; - s += n; - } - else { - sprev = s; - s++; - } + } + n = enclen_approx(encode, s, end); + if (n > 1) { + DATA_ENSURE(n); + sprev = s; + s += n; + } + else { + sprev = s; + s++; + } } p++; MOP_OUT; @@ -3140,15 +3139,15 @@ CASE(OP_STATE_CHECK_ANYCHAR_STAR) MOP_IN(OP_STATE_CHECK_ANYCHAR_STAR); GET_STATE_CHECK_NUM_INC(mem, p); while (DATA_ENSURE_CHECK1) { - STATE_CHECK_VAL(scv, mem); - if (scv) goto fail; + STATE_CHECK_VAL(scv, mem); + if (scv) goto fail; - STACK_PUSH_ALT_WITH_STATE_CHECK(p, s, sprev, mem, pkeep); - n = enclen_approx(encode, s, end); - DATA_ENSURE(n); - if (ONIGENC_IS_MBC_NEWLINE_EX(encode, s, str, end, option, 0)) goto fail; - sprev = s; - s += n; + STACK_PUSH_ALT_WITH_STATE_CHECK(p, s, sprev, mem, pkeep); + n = enclen_approx(encode, s, end); + DATA_ENSURE(n); + if (ONIGENC_IS_MBC_NEWLINE_EX(encode, s, str, end, option, 0)) goto fail; + sprev = s; + s += n; } MOP_OUT; NEXT; @@ -3158,20 +3157,20 @@ GET_STATE_CHECK_NUM_INC(mem, p); while (DATA_ENSURE_CHECK1) { - STATE_CHECK_VAL(scv, mem); - if (scv) goto fail; + STATE_CHECK_VAL(scv, mem); + if (scv) goto fail; - STACK_PUSH_ALT_WITH_STATE_CHECK(p, s, sprev, mem, pkeep); - n = enclen_approx(encode, s, end); - if (n > 1) { - DATA_ENSURE(n); - sprev = s; - s += n; - } - else { - sprev = s; - s++; - } + STACK_PUSH_ALT_WITH_STATE_CHECK(p, s, sprev, mem, pkeep); + n = enclen_approx(encode, s, end); + if (n > 1) { + DATA_ENSURE(n); + sprev = s; + s += n; + } + else { + sprev = s; + s++; + } } MOP_OUT; NEXT; @@ -3180,7 +3179,7 @@ CASE(OP_WORD) MOP_IN(OP_WORD); DATA_ENSURE(1); if (! ONIGENC_IS_MBC_WORD(encode, s, end)) - goto fail; + goto fail; s += enclen(encode, s, end); MOP_OUT; @@ -3189,7 +3188,7 @@ CASE(OP_ASCII_WORD) MOP_IN(OP_ASCII_WORD); DATA_ENSURE(1); if (! ONIGENC_IS_MBC_ASCII_WORD(encode, s, end)) - goto fail; + goto fail; s += enclen(encode, s, end); MOP_OUT; @@ -3198,7 +3197,7 @@ CASE(OP_NOT_WORD) MOP_IN(OP_NOT_WORD); DATA_ENSURE(1); if (ONIGENC_IS_MBC_WORD(encode, s, end)) - goto fail; + goto fail; s += enclen(encode, s, end); MOP_OUT; @@ -3207,7 +3206,7 @@ CASE(OP_NOT_ASCII_WORD) MOP_IN(OP_NOT_ASCII_WORD); DATA_ENSURE(1); if (ONIGENC_IS_MBC_ASCII_WORD(encode, s, end)) - goto fail; + goto fail; s += enclen(encode, s, end); MOP_OUT; @@ -3215,70 +3214,70 @@ CASE(OP_WORD_BOUND) MOP_IN(OP_WORD_BOUND); if (ON_STR_BEGIN(s)) { - DATA_ENSURE(1); - if (! ONIGENC_IS_MBC_WORD(encode, s, end)) - goto fail; + DATA_ENSURE(1); + if (! ONIGENC_IS_MBC_WORD(encode, s, end)) + goto fail; } else if (ON_STR_END(s)) { - if (! ONIGENC_IS_MBC_WORD(encode, sprev, end)) - goto fail; + if (! ONIGENC_IS_MBC_WORD(encode, sprev, end)) + goto fail; } else { - if (ONIGENC_IS_MBC_WORD(encode, s, end) - == ONIGENC_IS_MBC_WORD(encode, sprev, end)) - goto fail; + if (ONIGENC_IS_MBC_WORD(encode, s, end) + == ONIGENC_IS_MBC_WORD(encode, sprev, end)) + goto fail; } MOP_OUT; JUMP; CASE(OP_ASCII_WORD_BOUND) MOP_IN(OP_ASCII_WORD_BOUND); if (ON_STR_BEGIN(s)) { - DATA_ENSURE(1); - if (! ONIGENC_IS_MBC_ASCII_WORD(encode, s, end)) - goto fail; + DATA_ENSURE(1); + if (! ONIGENC_IS_MBC_ASCII_WORD(encode, s, end)) + goto fail; } else if (ON_STR_END(s)) { - if (! ONIGENC_IS_MBC_ASCII_WORD(encode, sprev, end)) - goto fail; + if (! ONIGENC_IS_MBC_ASCII_WORD(encode, sprev, end)) + goto fail; } else { - if (ONIGENC_IS_MBC_ASCII_WORD(encode, s, end) - == ONIGENC_IS_MBC_ASCII_WORD(encode, sprev, end)) - goto fail; + if (ONIGENC_IS_MBC_ASCII_WORD(encode, s, end) + == ONIGENC_IS_MBC_ASCII_WORD(encode, sprev, end)) + goto fail; } MOP_OUT; JUMP; CASE(OP_NOT_WORD_BOUND) MOP_IN(OP_NOT_WORD_BOUND); if (ON_STR_BEGIN(s)) { - if (DATA_ENSURE_CHECK1 && ONIGENC_IS_MBC_WORD(encode, s, end)) - goto fail; + if (DATA_ENSURE_CHECK1 && ONIGENC_IS_MBC_WORD(encode, s, end)) + goto fail; } else if (ON_STR_END(s)) { - if (ONIGENC_IS_MBC_WORD(encode, sprev, end)) - goto fail; + if (ONIGENC_IS_MBC_WORD(encode, sprev, end)) + goto fail; } else { - if (ONIGENC_IS_MBC_WORD(encode, s, end) - != ONIGENC_IS_MBC_WORD(encode, sprev, end)) - goto fail; + if (ONIGENC_IS_MBC_WORD(encode, s, end) + != ONIGENC_IS_MBC_WORD(encode, sprev, end)) + goto fail; } MOP_OUT; JUMP; CASE(OP_NOT_ASCII_WORD_BOUND) MOP_IN(OP_NOT_ASCII_WORD_BOUND); if (ON_STR_BEGIN(s)) { - if (DATA_ENSURE_CHECK1 && ONIGENC_IS_MBC_ASCII_WORD(encode, s, end)) - goto fail; + if (DATA_ENSURE_CHECK1 && ONIGENC_IS_MBC_ASCII_WORD(encode, s, end)) + goto fail; } else if (ON_STR_END(s)) { - if (ONIGENC_IS_MBC_ASCII_WORD(encode, sprev, end)) - goto fail; + if (ONIGENC_IS_MBC_ASCII_WORD(encode, sprev, end)) + goto fail; } else { - if (ONIGENC_IS_MBC_ASCII_WORD(encode, s, end) - != ONIGENC_IS_MBC_ASCII_WORD(encode, sprev, end)) - goto fail; + if (ONIGENC_IS_MBC_ASCII_WORD(encode, s, end) + != ONIGENC_IS_MBC_ASCII_WORD(encode, sprev, end)) + goto fail; } MOP_OUT; JUMP; @@ -3286,43 +3285,39 @@ #ifdef USE_WORD_BEGIN_END CASE(OP_WORD_BEGIN) MOP_IN(OP_WORD_BEGIN); if (DATA_ENSURE_CHECK1 && ONIGENC_IS_MBC_WORD(encode, s, end)) { - if (ON_STR_BEGIN(s) || !ONIGENC_IS_MBC_WORD(encode, sprev, end)) { - MOP_OUT; - JUMP; + if (ON_STR_BEGIN(s) || !ONIGENC_IS_MBC_WORD(encode, sprev, end)) { + MOP_OUT; + JUMP; } } goto fail; - NEXT; CASE(OP_ASCII_WORD_BEGIN) MOP_IN(OP_ASCII_WORD_BEGIN); if (DATA_ENSURE_CHECK1 && ONIGENC_IS_MBC_ASCII_WORD(encode, s, end)) { - if (ON_STR_BEGIN(s) || !ONIGENC_IS_MBC_ASCII_WORD(encode, sprev, end)) { - MOP_OUT; - JUMP; + if (ON_STR_BEGIN(s) || !ONIGENC_IS_MBC_ASCII_WORD(encode, sprev, end)) { + MOP_OUT; + JUMP; } } goto fail; - NEXT; CASE(OP_WORD_END) MOP_IN(OP_WORD_END); if (!ON_STR_BEGIN(s) && ONIGENC_IS_MBC_WORD(encode, sprev, end)) { - if (ON_STR_END(s) || !ONIGENC_IS_MBC_WORD(encode, s, end)) { - MOP_OUT; - JUMP; + if (ON_STR_END(s) || !ONIGENC_IS_MBC_WORD(encode, s, end)) { + MOP_OUT; + JUMP; } } goto fail; - NEXT; CASE(OP_ASCII_WORD_END) MOP_IN(OP_ASCII_WORD_END); if (!ON_STR_BEGIN(s) && ONIGENC_IS_MBC_ASCII_WORD(encode, sprev, end)) { - if (ON_STR_END(s) || !ONIGENC_IS_MBC_ASCII_WORD(encode, s, end)) { - MOP_OUT; - JUMP; + if (ON_STR_END(s) || !ONIGENC_IS_MBC_ASCII_WORD(encode, s, end)) { + MOP_OUT; + JUMP; } } goto fail; - NEXT; #endif CASE(OP_BEGIN_BUF) MOP_IN(OP_BEGIN_BUF); @@ -3341,76 +3336,73 @@ CASE(OP_BEGIN_LINE) MOP_IN(OP_BEGIN_LINE); if (ON_STR_BEGIN(s)) { - if (IS_NOTBOL(msa->options)) goto fail; - MOP_OUT; - JUMP; + if (IS_NOTBOL(msa->options)) goto fail; + MOP_OUT; + JUMP; } else if (ONIGENC_IS_MBC_NEWLINE(encode, sprev, end) #ifdef USE_CRNL_AS_LINE_TERMINATOR - && !(IS_NEWLINE_CRLF(option) - && ONIGENC_IS_MBC_CRNL(encode, sprev, end)) + && !(IS_NEWLINE_CRLF(option) + && ONIGENC_IS_MBC_CRNL(encode, sprev, end)) #endif - && !ON_STR_END(s)) { - MOP_OUT; + && !ON_STR_END(s)) { + MOP_OUT; JUMP; } goto fail; - NEXT; CASE(OP_END_LINE) MOP_IN(OP_END_LINE); if (ON_STR_END(s)) { #ifndef USE_NEWLINE_AT_END_OF_STRING_HAS_EMPTY_LINE - if (IS_EMPTY_STR || !ONIGENC_IS_MBC_NEWLINE_EX(encode, sprev, str, end, option, 1)) { + if (IS_EMPTY_STR || !ONIGENC_IS_MBC_NEWLINE_EX(encode, sprev, str, end, option, 1)) { #endif - if (IS_NOTEOL(msa->options)) goto fail; - MOP_OUT; - JUMP; + if (IS_NOTEOL(msa->options)) goto fail; + MOP_OUT; + JUMP; #ifndef USE_NEWLINE_AT_END_OF_STRING_HAS_EMPTY_LINE - } + } #endif } else if (ONIGENC_IS_MBC_NEWLINE_EX(encode, s, str, end, option, 1)) { - MOP_OUT; + MOP_OUT; JUMP; } goto fail; - NEXT; CASE(OP_SEMI_END_BUF) MOP_IN(OP_SEMI_END_BUF); if (ON_STR_END(s)) { #ifndef USE_NEWLINE_AT_END_OF_STRING_HAS_EMPTY_LINE - if (IS_EMPTY_STR || !ONIGENC_IS_MBC_NEWLINE_EX(encode, sprev, str, end, option, 1)) { + if (IS_EMPTY_STR || !ONIGENC_IS_MBC_NEWLINE_EX(encode, sprev, str, end, option, 1)) { #endif - if (IS_NOTEOL(msa->options)) goto fail; - MOP_OUT; - JUMP; + if (IS_NOTEOL(msa->options)) goto fail; + MOP_OUT; + JUMP; #ifndef USE_NEWLINE_AT_END_OF_STRING_HAS_EMPTY_LINE - } + } #endif } else if (ONIGENC_IS_MBC_NEWLINE_EX(encode, s, str, end, option, 1)) { - UChar* ss = s + enclen(encode, s, end); - if (ON_STR_END(ss)) { - MOP_OUT; - JUMP; - } + UChar* ss = s + enclen(encode, s, end); + if (ON_STR_END(ss)) { + MOP_OUT; + JUMP; + } #ifdef USE_CRNL_AS_LINE_TERMINATOR - else if (IS_NEWLINE_CRLF(option) - && ONIGENC_IS_MBC_CRNL(encode, s, end)) { - ss += enclen(encode, ss, end); - if (ON_STR_END(ss)) { - MOP_OUT; - JUMP; - } - } + else if (IS_NEWLINE_CRLF(option) + && ONIGENC_IS_MBC_CRNL(encode, s, end)) { + ss += enclen(encode, ss, end); + if (ON_STR_END(ss)) { + MOP_OUT; + JUMP; + } + } #endif } goto fail; - NEXT; CASE(OP_BEGIN_POSITION) MOP_IN(OP_BEGIN_POSITION); if (s != msa->gpos) - goto fail; + goto fail; MOP_OUT; JUMP; @@ -3460,9 +3452,9 @@ STACK_GET_MEM_START(mem, stkp); if (BIT_STATUS_AT(reg->bt_mem_start, mem)) - mem_start_stk[mem] = GET_STACK_INDEX(stkp); + mem_start_stk[mem] = GET_STACK_INDEX(stkp); else - mem_start_stk[mem] = (OnigStackIndex )((void* )stkp->u.mem.pstr); + mem_start_stk[mem] = (OnigStackIndex )((void* )stkp->u.mem.pstr); STACK_PUSH_MEM_END_MARK(mem); MOP_OUT; @@ -3472,178 +3464,176 @@ CASE(OP_BACKREF1) MOP_IN(OP_BACKREF1); mem = 1; goto backref; - NEXT; CASE(OP_BACKREF2) MOP_IN(OP_BACKREF2); mem = 2; goto backref; - NEXT; CASE(OP_BACKREFN) MOP_IN(OP_BACKREFN); GET_MEMNUM_INC(mem, p); backref: { - int len; - UChar *pstart, *pend; + int len; + UChar *pstart, *pend; - /* if you want to remove following line, - you should check in parse and compile time. */ - if (mem > num_mem) goto fail; - if (mem_end_stk[mem] == INVALID_STACK_INDEX) goto fail; - if (mem_start_stk[mem] == INVALID_STACK_INDEX) goto fail; - - if (BIT_STATUS_AT(reg->bt_mem_start, mem)) - pstart = STACK_AT(mem_start_stk[mem])->u.mem.pstr; - else - pstart = (UChar* )((void* )mem_start_stk[mem]); - - pend = (BIT_STATUS_AT(reg->bt_mem_end, mem) - ? STACK_AT(mem_end_stk[mem])->u.mem.pstr - : (UChar* )((void* )mem_end_stk[mem])); - n = pend - pstart; - DATA_ENSURE(n); - sprev = s; - STRING_CMP(pstart, s, n); - while (sprev + (len = enclen_approx(encode, sprev, end)) < s) - sprev += len; + /* if you want to remove following line, + you should check in parse and compile time. */ + if (mem > num_mem) goto fail; + if (mem_end_stk[mem] == INVALID_STACK_INDEX) goto fail; + if (mem_start_stk[mem] == INVALID_STACK_INDEX) goto fail; + + if (BIT_STATUS_AT(reg->bt_mem_start, mem)) + pstart = STACK_AT(mem_start_stk[mem])->u.mem.pstr; + else + pstart = (UChar* )((void* )mem_start_stk[mem]); + + pend = (BIT_STATUS_AT(reg->bt_mem_end, mem) + ? STACK_AT(mem_end_stk[mem])->u.mem.pstr + : (UChar* )((void* )mem_end_stk[mem])); + n = pend - pstart; + DATA_ENSURE(n); + sprev = s; + STRING_CMP(pstart, s, n); + while (sprev + (len = enclen_approx(encode, sprev, end)) < s) + sprev += len; - MOP_OUT; - JUMP; + MOP_OUT; + JUMP; } CASE(OP_BACKREFN_IC) MOP_IN(OP_BACKREFN_IC); GET_MEMNUM_INC(mem, p); { - int len; - UChar *pstart, *pend; + int len; + UChar *pstart, *pend; - /* if you want to remove following line, - you should check in parse and compile time. */ - if (mem > num_mem) goto fail; - if (mem_end_stk[mem] == INVALID_STACK_INDEX) goto fail; - if (mem_start_stk[mem] == INVALID_STACK_INDEX) goto fail; - - if (BIT_STATUS_AT(reg->bt_mem_start, mem)) - pstart = STACK_AT(mem_start_stk[mem])->u.mem.pstr; - else - pstart = (UChar* )((void* )mem_start_stk[mem]); - - pend = (BIT_STATUS_AT(reg->bt_mem_end, mem) - ? STACK_AT(mem_end_stk[mem])->u.mem.pstr - : (UChar* )((void* )mem_end_stk[mem])); - n = pend - pstart; - DATA_ENSURE(n); - sprev = s; - STRING_CMP_IC(case_fold_flag, pstart, &s, n, end); - while (sprev + (len = enclen_approx(encode, sprev, end)) < s) - sprev += len; + /* if you want to remove following line, + you should check in parse and compile time. */ + if (mem > num_mem) goto fail; + if (mem_end_stk[mem] == INVALID_STACK_INDEX) goto fail; + if (mem_start_stk[mem] == INVALID_STACK_INDEX) goto fail; + + if (BIT_STATUS_AT(reg->bt_mem_start, mem)) + pstart = STACK_AT(mem_start_stk[mem])->u.mem.pstr; + else + pstart = (UChar* )((void* )mem_start_stk[mem]); + + pend = (BIT_STATUS_AT(reg->bt_mem_end, mem) + ? STACK_AT(mem_end_stk[mem])->u.mem.pstr + : (UChar* )((void* )mem_end_stk[mem])); + n = pend - pstart; + DATA_ENSURE(n); + sprev = s; + STRING_CMP_IC(case_fold_flag, pstart, &s, n, end); + while (sprev + (len = enclen_approx(encode, sprev, end)) < s) + sprev += len; - MOP_OUT; - JUMP; + MOP_OUT; + JUMP; } NEXT; CASE(OP_BACKREF_MULTI) MOP_IN(OP_BACKREF_MULTI); { - int len, is_fail; - UChar *pstart, *pend, *swork; + int len, is_fail; + UChar *pstart, *pend, *swork; - GET_LENGTH_INC(tlen, p); - for (i = 0; i < tlen; i++) { - GET_MEMNUM_INC(mem, p); - - if (mem_end_stk[mem] == INVALID_STACK_INDEX) continue; - if (mem_start_stk[mem] == INVALID_STACK_INDEX) continue; - - if (BIT_STATUS_AT(reg->bt_mem_start, mem)) - pstart = STACK_AT(mem_start_stk[mem])->u.mem.pstr; - else - pstart = (UChar* )((void* )mem_start_stk[mem]); - - pend = (BIT_STATUS_AT(reg->bt_mem_end, mem) - ? STACK_AT(mem_end_stk[mem])->u.mem.pstr - : (UChar* )((void* )mem_end_stk[mem])); - n = pend - pstart; - DATA_ENSURE_CONTINUE(n); - sprev = s; - swork = s; - STRING_CMP_VALUE(pstart, swork, n, is_fail); - if (is_fail) continue; - s = swork; - while (sprev + (len = enclen_approx(encode, sprev, end)) < s) - sprev += len; + GET_LENGTH_INC(tlen, p); + for (i = 0; i < tlen; i++) { + GET_MEMNUM_INC(mem, p); + + if (mem_end_stk[mem] == INVALID_STACK_INDEX) continue; + if (mem_start_stk[mem] == INVALID_STACK_INDEX) continue; + + if (BIT_STATUS_AT(reg->bt_mem_start, mem)) + pstart = STACK_AT(mem_start_stk[mem])->u.mem.pstr; + else + pstart = (UChar* )((void* )mem_start_stk[mem]); + + pend = (BIT_STATUS_AT(reg->bt_mem_end, mem) + ? STACK_AT(mem_end_stk[mem])->u.mem.pstr + : (UChar* )((void* )mem_end_stk[mem])); + n = pend - pstart; + DATA_ENSURE_CONTINUE(n); + sprev = s; + swork = s; + STRING_CMP_VALUE(pstart, swork, n, is_fail); + if (is_fail) continue; + s = swork; + while (sprev + (len = enclen_approx(encode, sprev, end)) < s) + sprev += len; - p += (SIZE_MEMNUM * (tlen - i - 1)); - break; /* success */ - } - if (i == tlen) goto fail; - MOP_OUT; - JUMP; + p += (SIZE_MEMNUM * (tlen - i - 1)); + break; /* success */ + } + if (i == tlen) goto fail; + MOP_OUT; + JUMP; } NEXT; CASE(OP_BACKREF_MULTI_IC) MOP_IN(OP_BACKREF_MULTI_IC); { - int len, is_fail; - UChar *pstart, *pend, *swork; + int len, is_fail; + UChar *pstart, *pend, *swork; - GET_LENGTH_INC(tlen, p); - for (i = 0; i < tlen; i++) { - GET_MEMNUM_INC(mem, p); - - if (mem_end_stk[mem] == INVALID_STACK_INDEX) continue; - if (mem_start_stk[mem] == INVALID_STACK_INDEX) continue; - - if (BIT_STATUS_AT(reg->bt_mem_start, mem)) - pstart = STACK_AT(mem_start_stk[mem])->u.mem.pstr; - else - pstart = (UChar* )((void* )mem_start_stk[mem]); - - pend = (BIT_STATUS_AT(reg->bt_mem_end, mem) - ? STACK_AT(mem_end_stk[mem])->u.mem.pstr - : (UChar* )((void* )mem_end_stk[mem])); - n = pend - pstart; - DATA_ENSURE_CONTINUE(n); - sprev = s; - swork = s; - STRING_CMP_VALUE_IC(case_fold_flag, pstart, &swork, n, end, is_fail); - if (is_fail) continue; - s = swork; - while (sprev + (len = enclen(encode, sprev, end)) < s) - sprev += len; + GET_LENGTH_INC(tlen, p); + for (i = 0; i < tlen; i++) { + GET_MEMNUM_INC(mem, p); + + if (mem_end_stk[mem] == INVALID_STACK_INDEX) continue; + if (mem_start_stk[mem] == INVALID_STACK_INDEX) continue; + + if (BIT_STATUS_AT(reg->bt_mem_start, mem)) + pstart = STACK_AT(mem_start_stk[mem])->u.mem.pstr; + else + pstart = (UChar* )((void* )mem_start_stk[mem]); + + pend = (BIT_STATUS_AT(reg->bt_mem_end, mem) + ? STACK_AT(mem_end_stk[mem])->u.mem.pstr + : (UChar* )((void* )mem_end_stk[mem])); + n = pend - pstart; + DATA_ENSURE_CONTINUE(n); + sprev = s; + swork = s; + STRING_CMP_VALUE_IC(case_fold_flag, pstart, &swork, n, end, is_fail); + if (is_fail) continue; + s = swork; + while (sprev + (len = enclen(encode, sprev, end)) < s) + sprev += len; - p += (SIZE_MEMNUM * (tlen - i - 1)); - break; /* success */ - } - if (i == tlen) goto fail; - MOP_OUT; - JUMP; + p += (SIZE_MEMNUM * (tlen - i - 1)); + break; /* success */ + } + if (i == tlen) goto fail; + MOP_OUT; + JUMP; } #ifdef USE_BACKREF_WITH_LEVEL CASE(OP_BACKREF_WITH_LEVEL) { - int len; - OnigOptionType ic; - LengthType level; - - GET_OPTION_INC(ic, p); - GET_LENGTH_INC(level, p); - GET_LENGTH_INC(tlen, p); - - sprev = s; - if (backref_match_at_nested_level(reg, stk, stk_base, ic, - case_fold_flag, (int )level, (int )tlen, p, &s, end)) { - while (sprev + (len = enclen(encode, sprev, end)) < s) - sprev += len; + int len; + OnigOptionType ic; + LengthType level; + + GET_OPTION_INC(ic, p); + GET_LENGTH_INC(level, p); + GET_LENGTH_INC(tlen, p); + + sprev = s; + if (backref_match_at_nested_level(reg, stk, stk_base, ic, + case_fold_flag, (int )level, (int )tlen, p, &s, end)) { + while (sprev + (len = enclen(encode, sprev, end)) < s) + sprev += len; - p += (SIZE_MEMNUM * tlen); - } - else - goto fail; + p += (SIZE_MEMNUM * tlen); + } + else + goto fail; - MOP_OUT; - JUMP; + MOP_OUT; + JUMP; } #endif @@ -3670,33 +3660,33 @@ CASE(OP_NULL_CHECK_END) MOP_IN(OP_NULL_CHECK_END); { - int isnull; + int isnull; - GET_MEMNUM_INC(mem, p); /* mem: null check id */ - STACK_NULL_CHECK(isnull, mem, s); - if (isnull) { + GET_MEMNUM_INC(mem, p); /* mem: null check id */ + STACK_NULL_CHECK(isnull, mem, s); + if (isnull) { #ifdef ONIG_DEBUG_MATCH - fprintf(stderr, "NULL_CHECK_END: skip id:%d, s:%"PRIuPTR" (%p)\n", - (int )mem, (uintptr_t )s, s); + fprintf(stderr, "NULL_CHECK_END: skip id:%d, s:%"PRIuPTR" (%p)\n", + (int )mem, (uintptr_t )s, s); #endif - null_check_found: - /* empty loop founded, skip next instruction */ - switch (*p++) { - case OP_JUMP: - case OP_PUSH: - p += SIZE_RELADDR; - break; - case OP_REPEAT_INC: - case OP_REPEAT_INC_NG: - case OP_REPEAT_INC_SG: - case OP_REPEAT_INC_NG_SG: - p += SIZE_MEMNUM; - break; - default: - goto unexpected_bytecode_error; - break; - } - } + null_check_found: + /* empty loop founded, skip next instruction */ + switch (*p++) { + case OP_JUMP: + case OP_PUSH: + p += SIZE_RELADDR; + break; + case OP_REPEAT_INC: + case OP_REPEAT_INC_NG: + case OP_REPEAT_INC_SG: + case OP_REPEAT_INC_NG_SG: + p += SIZE_MEMNUM; + break; + default: + goto unexpected_bytecode_error; + break; + } + } } MOP_OUT; JUMP; @@ -3704,18 +3694,18 @@ #ifdef USE_MONOMANIAC_CHECK_CAPTURES_IN_ENDLESS_REPEAT CASE(OP_NULL_CHECK_END_MEMST) MOP_IN(OP_NULL_CHECK_END_MEMST); { - int isnull; + int isnull; - GET_MEMNUM_INC(mem, p); /* mem: null check id */ - STACK_NULL_CHECK_MEMST(isnull, mem, s, reg); - if (isnull) { + GET_MEMNUM_INC(mem, p); /* mem: null check id */ + STACK_NULL_CHECK_MEMST(isnull, mem, s, reg); + if (isnull) { # ifdef ONIG_DEBUG_MATCH - fprintf(stderr, "NULL_CHECK_END_MEMST: skip id:%d, s:%"PRIuPTR" (%p)\n", - (int )mem, (uintptr_t )s, s); + fprintf(stderr, "NULL_CHECK_END_MEMST: skip id:%d, s:%"PRIuPTR" (%p)\n", + (int )mem, (uintptr_t )s, s); # endif - if (isnull == -1) goto fail; - goto null_check_found; - } + if (isnull == -1) goto fail; + goto null_check_found; + } } MOP_OUT; JUMP; @@ -3725,25 +3715,25 @@ CASE(OP_NULL_CHECK_END_MEMST_PUSH) MOP_IN(OP_NULL_CHECK_END_MEMST_PUSH); { - int isnull; + int isnull; - GET_MEMNUM_INC(mem, p); /* mem: null check id */ + GET_MEMNUM_INC(mem, p); /* mem: null check id */ # ifdef USE_MONOMANIAC_CHECK_CAPTURES_IN_ENDLESS_REPEAT - STACK_NULL_CHECK_MEMST_REC(isnull, mem, s, reg); + STACK_NULL_CHECK_MEMST_REC(isnull, mem, s, reg); # else - STACK_NULL_CHECK_REC(isnull, mem, s); + STACK_NULL_CHECK_REC(isnull, mem, s); # endif - if (isnull) { + if (isnull) { # ifdef ONIG_DEBUG_MATCH - fprintf(stderr, "NULL_CHECK_END_MEMST_PUSH: skip id:%d, s:%"PRIuPTR" (%p)\n", - (int )mem, (uintptr_t )s, s); + fprintf(stderr, "NULL_CHECK_END_MEMST_PUSH: skip id:%d, s:%"PRIuPTR" (%p)\n", + (int )mem, (uintptr_t )s, s); # endif - if (isnull == -1) goto fail; - goto null_check_found; - } - else { - STACK_PUSH_NULL_CHECK_END(mem); - } + if (isnull == -1) goto fail; + goto null_check_found; + } + else { + STACK_PUSH_NULL_CHECK_END(mem); + } } MOP_OUT; JUMP; @@ -3779,10 +3769,10 @@ GET_RELADDR_INC(addr, p); STATE_CHECK_VAL(scv, mem); if (scv) { - p += addr; + p += addr; } else { - STACK_PUSH_ALT_WITH_STATE_CHECK(p + addr, s, sprev, mem, pkeep); + STACK_PUSH_ALT_WITH_STATE_CHECK(p + addr, s, sprev, mem, pkeep); } MOP_OUT; JUMP; @@ -3811,11 +3801,11 @@ CASE(OP_PUSH_OR_JUMP_EXACT1) MOP_IN(OP_PUSH_OR_JUMP_EXACT1); GET_RELADDR_INC(addr, p); if (*p == *s && DATA_ENSURE_CHECK1) { - p++; - CHECK_MATCH_CACHE; - STACK_PUSH_ALT(p + addr, s, sprev, pkeep); - MOP_OUT; - JUMP; + p++; + CHECK_MATCH_CACHE; + STACK_PUSH_ALT(p + addr, s, sprev, pkeep); + MOP_OUT; + JUMP; } p += (addr + 1); MOP_OUT; @@ -3826,10 +3816,10 @@ GET_RELADDR_INC(addr, p); CHECK_MATCH_CACHE; if (*p == *s) { - p++; - STACK_PUSH_ALT(p + addr, s, sprev, pkeep); - MOP_OUT; - JUMP; + p++; + STACK_PUSH_ALT(p + addr, s, sprev, pkeep); + MOP_OUT; + JUMP; } p++; INC_NUM_FAILS; @@ -3838,35 +3828,35 @@ CASE(OP_REPEAT) MOP_IN(OP_REPEAT); { - GET_MEMNUM_INC(mem, p); /* mem: OP_REPEAT ID */ - GET_RELADDR_INC(addr, p); + GET_MEMNUM_INC(mem, p); /* mem: OP_REPEAT ID */ + GET_RELADDR_INC(addr, p); - STACK_ENSURE(1); - repeat_stk[mem] = GET_STACK_INDEX(stk); - STACK_PUSH_REPEAT(mem, p); - - if (reg->repeat_range[mem].lower == 0) { - CHECK_MATCH_CACHE; - STACK_PUSH_ALT(p + addr, s, sprev, pkeep); - } + STACK_ENSURE(1); + repeat_stk[mem] = GET_STACK_INDEX(stk); + STACK_PUSH_REPEAT(mem, p); + + if (reg->repeat_range[mem].lower == 0) { + CHECK_MATCH_CACHE; + STACK_PUSH_ALT(p + addr, s, sprev, pkeep); + } } MOP_OUT; JUMP; CASE(OP_REPEAT_NG) MOP_IN(OP_REPEAT_NG); { - GET_MEMNUM_INC(mem, p); /* mem: OP_REPEAT ID */ - GET_RELADDR_INC(addr, p); + GET_MEMNUM_INC(mem, p); /* mem: OP_REPEAT ID */ + GET_RELADDR_INC(addr, p); - STACK_ENSURE(1); - repeat_stk[mem] = GET_STACK_INDEX(stk); - STACK_PUSH_REPEAT(mem, p); - - if (reg->repeat_range[mem].lower == 0) { - CHECK_MATCH_CACHE; - STACK_PUSH_ALT(p, s, sprev, pkeep); - p += addr; - } + STACK_ENSURE(1); + repeat_stk[mem] = GET_STACK_INDEX(stk); + STACK_PUSH_REPEAT(mem, p); + + if (reg->repeat_range[mem].lower == 0) { + CHECK_MATCH_CACHE; + STACK_PUSH_ALT(p, s, sprev, pkeep); + p += addr; + } } MOP_OUT; JUMP; @@ -3879,23 +3869,23 @@ repeat_inc: stkp->u.repeat.count++; if (stkp->u.repeat.count >= reg->repeat_range[mem].upper) { - /* end of repeat. Nothing to do. */ + /* end of repeat. Nothing to do. */ } else if (stkp->u.repeat.count >= reg->repeat_range[mem].lower) { #ifdef USE_MATCH_CACHE - if (*pbegin == OP_REPEAT_INC) { + if (*pbegin == OP_REPEAT_INC) { #undef MATCH_CACHE_HIT #define MATCH_CACHE_HIT stkp->u.repeat.count--; - CHECK_MATCH_CACHE; + CHECK_MATCH_CACHE; #undef MATCH_CACHE_HIT #define MATCH_CACHE_HIT ((void) 0) - } + } #endif - STACK_PUSH_ALT(p, s, sprev, pkeep); - p = STACK_AT(si)->u.repeat.pcode; /* Don't use stkp after PUSH. */ + STACK_PUSH_ALT(p, s, sprev, pkeep); + p = STACK_AT(si)->u.repeat.pcode; /* Don't use stkp after PUSH. */ } else { - p = stkp->u.repeat.pcode; + p = stkp->u.repeat.pcode; } STACK_PUSH_REPEAT_INC(si); MOP_OUT; @@ -3907,7 +3897,6 @@ STACK_GET_REPEAT(mem, stkp); si = GET_STACK_INDEX(stkp); goto repeat_inc; - NEXT; CASE(OP_REPEAT_INC_NG) MOP_IN(OP_REPEAT_INC_NG); GET_MEMNUM_INC(mem, p); /* mem: OP_REPEAT ID */ @@ -3917,22 +3906,22 @@ repeat_inc_ng: stkp->u.repeat.count++; if (stkp->u.repeat.count < reg->repeat_range[mem].upper) { - if (stkp->u.repeat.count >= reg->repeat_range[mem].lower) { - UChar* pcode = stkp->u.repeat.pcode; + if (stkp->u.repeat.count >= reg->repeat_range[mem].lower) { + UChar* pcode = stkp->u.repeat.pcode; - STACK_PUSH_REPEAT_INC(si); - if (*pbegin == OP_REPEAT_INC_NG) { - CHECK_MATCH_CACHE; - } - STACK_PUSH_ALT(pcode, s, sprev, pkeep); - } - else { - p = stkp->u.repeat.pcode; - STACK_PUSH_REPEAT_INC(si); - } + STACK_PUSH_REPEAT_INC(si); + if (*pbegin == OP_REPEAT_INC_NG) { + CHECK_MATCH_CACHE; + } + STACK_PUSH_ALT(pcode, s, sprev, pkeep); + } + else { + p = stkp->u.repeat.pcode; + STACK_PUSH_REPEAT_INC(si); + } } else if (stkp->u.repeat.count == reg->repeat_range[mem].upper) { - STACK_PUSH_REPEAT_INC(si); + STACK_PUSH_REPEAT_INC(si); } MOP_OUT; CHECK_INTERRUPT_IN_MATCH_AT; @@ -3943,7 +3932,6 @@ STACK_GET_REPEAT(mem, stkp); si = GET_STACK_INDEX(stkp); goto repeat_inc_ng; - NEXT; CASE(OP_PUSH_POS) MOP_IN(OP_PUSH_POS); STACK_PUSH_POS(s, sprev, pkeep); @@ -3952,9 +3940,9 @@ CASE(OP_POP_POS) MOP_IN(OP_POP_POS); { - STACK_POS_END(stkp); - s = stkp->u.state.pstr; - sprev = stkp->u.state.pstr_prev; + STACK_POS_END(stkp); + s = stkp->u.state.pstr; + sprev = stkp->u.state.pstr_prev; } MOP_OUT; JUMP; @@ -3968,7 +3956,6 @@ CASE(OP_FAIL_POS) MOP_IN(OP_FAIL_POS); STACK_POP_TIL_POS_NOT; goto fail; - NEXT; CASE(OP_PUSH_STOP_BT) MOP_IN(OP_PUSH_STOP_BT); STACK_PUSH_STOP_BT; @@ -3993,15 +3980,15 @@ GET_LENGTH_INC(tlen, p); q = (UChar* )ONIGENC_STEP_BACK(encode, str, s, end, (int )tlen); if (IS_NULL(q)) { - /* too short case -> success. ex. /(?<!XXX)a/.match("a") - If you want to change to fail, replace following line. */ - p += addr; - /* goto fail; */ + /* too short case -> success. ex. /(?<!XXX)a/.match("a") + If you want to change to fail, replace following line. */ + p += addr; + /* goto fail; */ } else { - STACK_PUSH_LOOK_BEHIND_NOT(p + addr, s, sprev, pkeep); - s = q; - sprev = (UChar* )onigenc_get_prev_char_head(encode, str, s, end); + STACK_PUSH_LOOK_BEHIND_NOT(p + addr, s, sprev, pkeep); + s = q; + sprev = (UChar* )onigenc_get_prev_char_head(encode, str, s, end); } MOP_OUT; JUMP; @@ -4009,7 +3996,6 @@ CASE(OP_FAIL_LOOK_BEHIND_NOT) MOP_IN(OP_FAIL_LOOK_BEHIND_NOT); STACK_POP_TIL_LOOK_BEHIND_NOT; goto fail; - NEXT; CASE(OP_PUSH_ABSENT_POS) MOP_IN(OP_PUSH_ABSENT_POS); /* Save the absent-start-pos and the original end-pos. */ @@ -4019,44 +4005,44 @@ CASE(OP_ABSENT) MOP_IN(OP_ABSENT); { - const UChar* aend = ABSENT_END_POS; - UChar* absent; - UChar* selfp = p - 1; + const UChar* aend = ABSENT_END_POS; + UChar* absent; + UChar* selfp = p - 1; - STACK_POP_ABSENT_POS(absent, ABSENT_END_POS); /* Restore end-pos. */ - GET_RELADDR_INC(addr, p); + STACK_POP_ABSENT_POS(absent, ABSENT_END_POS); /* Restore end-pos. */ + GET_RELADDR_INC(addr, p); #ifdef ONIG_DEBUG_MATCH - fprintf(stderr, "ABSENT: s:%p, end:%p, absent:%p, aend:%p\n", s, end, absent, aend); + fprintf(stderr, "ABSENT: s:%p, end:%p, absent:%p, aend:%p\n", s, end, absent, aend); #endif - if ((absent > aend) && (s > absent)) { - /* An empty match occurred in (?~...) at the start point. - * Never match. */ - STACK_POP; - goto fail; - } - else if ((s >= aend) && (s > absent)) { - if (s > aend) { - /* Only one (or less) character matched in the last iteration. - * This is not a possible point. */ - goto fail; - } - /* All possible points were found. Try matching after (?~...). */ - DATA_ENSURE(0); - p += addr; - } - else if (s == end) { - /* At the end of the string, just match with it */ - DATA_ENSURE(0); - p += addr; - } - else { - STACK_PUSH_ALT(p + addr, s, sprev, pkeep); /* Push possible point. */ - n = enclen(encode, s, end); - STACK_PUSH_ABSENT_POS(absent, ABSENT_END_POS); /* Save the original pos. */ - STACK_PUSH_ALT(selfp, s + n, s, pkeep); /* Next iteration. */ - STACK_PUSH_ABSENT; - ABSENT_END_POS = aend; - } + if ((absent > aend) && (s > absent)) { + /* An empty match occurred in (?~...) at the start point. + * Never match. */ + STACK_POP; + goto fail; + } + else if ((s >= aend) && (s > absent)) { + if (s > aend) { + /* Only one (or less) character matched in the last iteration. + * This is not a possible point. */ + goto fail; + } + /* All possible points were found. Try matching after (?~...). */ + DATA_ENSURE(0); + p += addr; + } + else if (s == end) { + /* At the end of the string, just match with it */ + DATA_ENSURE(0); + p += addr; + } + else { + STACK_PUSH_ALT(p + addr, s, sprev, pkeep); /* Push possible point. */ + n = enclen(encode, s, end); + STACK_PUSH_ABSENT_POS(absent, ABSENT_END_POS); /* Save the original pos. */ + STACK_PUSH_ALT(selfp, s + n, s, pkeep); /* Next iteration. */ + STACK_PUSH_ABSENT; + ABSENT_END_POS = aend; + } } MOP_OUT; JUMP; @@ -4065,13 +4051,12 @@ /* The pattern inside (?~...) was matched. * Set the end-pos temporary and go to next iteration. */ if (sprev < ABSENT_END_POS) - ABSENT_END_POS = sprev; + ABSENT_END_POS = sprev; #ifdef ONIG_DEBUG_MATCH fprintf(stderr, "ABSENT_END: end:%p\n", ABSENT_END_POS); #endif STACK_POP_TIL_ABSENT; goto fail; - NEXT; #ifdef USE_SUBEXP_CALL CASE(OP_CALL) MOP_IN(OP_CALL); @@ -4092,22 +4077,21 @@ GET_MEMNUM_INC(mem, p); GET_RELADDR_INC(addr, p); if ((mem > num_mem) || - (mem_end_stk[mem] == INVALID_STACK_INDEX) || - (mem_start_stk[mem] == INVALID_STACK_INDEX)) { - p += addr; + (mem_end_stk[mem] == INVALID_STACK_INDEX) || + (mem_start_stk[mem] == INVALID_STACK_INDEX)) { + p += addr; } MOP_OUT; JUMP; CASE(OP_FINISH) goto finish; - NEXT; CASE(OP_FAIL) if (0) { - /* fall */ + /* fall */ fail: - MOP_OUT; + MOP_OUT; } MOP_IN(OP_FAIL); STACK_POP; @@ -4118,71 +4102,71 @@ #ifdef USE_MATCH_CACHE if ( - msa->match_cache_status != MATCH_CACHE_STATUS_DISABLED && - ++msa->num_fails >= (long)(end - str) * msa->num_cache_opcodes + msa->match_cache_status != MATCH_CACHE_STATUS_DISABLED && + ++msa->num_fails >= (long)(end - str) * msa->num_cache_opcodes ) { - if (msa->match_cache_status == MATCH_CACHE_STATUS_UNINIT) { - msa->match_cache_status = MATCH_CACHE_STATUS_INIT; - OnigPosition r = count_num_cache_opcodes(reg, &msa->num_cache_opcodes); - if (r < 0) goto bytecode_error; - } - if (msa->num_cache_opcodes == NUM_CACHE_OPCODES_IMPOSSIBLE || msa->num_cache_opcodes == 0) { - msa->match_cache_status = MATCH_CACHE_STATUS_DISABLED; - goto fail_match_cache; - } - if (msa->num_fails < (long)(end - str) * msa->num_cache_opcodes) { - goto fail_match_cache; - } - if (msa->cache_opcodes == NULL) { - msa->match_cache_status = MATCH_CACHE_STATUS_ENABLED; - OnigCacheOpcode* cache_opcodes = (OnigCacheOpcode*)xmalloc(msa->num_cache_opcodes * sizeof(OnigCacheOpcode)); - if (cache_opcodes == NULL) { - return ONIGERR_MEMORY; - } - OnigPosition r = init_cache_opcodes(reg, cache_opcodes, &msa->num_cache_points); - if (r < 0) { - if (r == ONIGERR_UNEXPECTED_BYTECODE) goto unexpected_bytecode_error; - else goto bytecode_error; - } - msa->cache_opcodes = cache_opcodes; + if (msa->match_cache_status == MATCH_CACHE_STATUS_UNINIT) { + msa->match_cache_status = MATCH_CACHE_STATUS_INIT; + OnigPosition r = count_num_cache_opcodes(reg, &msa->num_cache_opcodes); + if (r < 0) goto bytecode_error; + } + if (msa->num_cache_opcodes == NUM_CACHE_OPCODES_IMPOSSIBLE || msa->num_cache_opcodes == 0) { + msa->match_cache_status = MATCH_CACHE_STATUS_DISABLED; + goto fail_match_cache; + } + if (msa->num_fails < (long)(end - str) * msa->num_cache_opcodes) { + goto fail_match_cache; + } + if (msa->cache_opcodes == NULL) { + msa->match_cache_status = MATCH_CACHE_STATUS_ENABLED; + OnigCacheOpcode* cache_opcodes = (OnigCacheOpcode*)xmalloc(msa->num_cache_opcodes * sizeof(OnigCacheOpcode)); + if (cache_opcodes == NULL) { + return ONIGERR_MEMORY; + } + OnigPosition r = init_cache_opcodes(reg, cache_opcodes, &msa->num_cache_points); + if (r < 0) { + if (r == ONIGERR_UNEXPECTED_BYTECODE) goto unexpected_bytecode_error; + else goto bytecode_error; + } + msa->cache_opcodes = cache_opcodes; #ifdef ONIG_DEBUG_MATCH_CACHE - fprintf(stderr, "MATCH CACHE: #cache opcodes = %ld\n", msa->num_cache_opcodes); - fprintf(stderr, "MATCH CACHE: #cache points = %ld\n", msa->num_cache_points); - fprintf(stderr, "MATCH CACHE: cache opcodes (%p):\n", msa->cache_opcodes); - for (int i = 0; i < msa->num_cache_opcodes; i++) { - fprintf(stderr, "MATCH CACHE: [%p] cache_point=%ld outer_repeat_mem=%d num_cache_opcodes_at_outer_repeat=%ld num_cache_opcodes_in_outer_repeat=%ld lookaround_nesting=%d match_addr=%p\n", msa->cache_opcodes[i].addr, msa->cache_opcodes[i].cache_point, msa->cache_opcodes[i].outer_repeat_mem, msa->cache_opcodes[i].num_cache_points_at_outer_repeat, msa->cache_opcodes[i].num_cache_points_in_outer_repeat, msa->cache_opcodes[i].lookaround_nesting, msa->cache_opcodes[i].match_addr); - } + fprintf(stderr, "MATCH CACHE: #cache opcodes = %ld\n", msa->num_cache_opcodes); + fprintf(stderr, "MATCH CACHE: #cache points = %ld\n", msa->num_cache_points); + fprintf(stderr, "MATCH CACHE: cache opcodes (%p):\n", msa->cache_opcodes); + for (int i = 0; i < msa->num_cache_opcodes; i++) { + fprintf(stderr, "MATCH CACHE: [%p] cache_point=%ld outer_repeat_mem=%d num_cache_opcodes_at_outer_repeat=%ld num_cache_opcodes_in_outer_repeat=%ld lookaround_nesting=%d match_addr=%p\n", msa->cache_opcodes[i].addr, msa->cache_opcodes[i].cache_point, msa->cache_opcodes[i].outer_repeat_mem, msa->cache_opcodes[i].num_cache_points_at_outer_repeat, msa->cache_opcodes[i].num_cache_points_in_outer_repeat, msa->cache_opcodes[i].lookaround_nesting, msa->cache_opcodes[i].match_addr); + } #endif - } - if (msa->match_cache_buf == NULL) { - size_t length = (end - str) + 1; - size_t num_match_cache_points = (size_t)msa->num_cache_points * length; + } + if (msa->match_cache_buf == NULL) { + size_t length = (end - str) + 1; + size_t num_match_cache_points = (size_t)msa->num_cache_points * length; #ifdef ONIG_DEBUG_MATCH_CACHE - fprintf(stderr, "MATCH CACHE: #match cache points = %"PRIuSIZE" (length = %"PRIuSIZE")\n", num_match_cache_points, length); + fprintf(stderr, "MATCH CACHE: #match cache points = %"PRIuSIZE" (length = %"PRIuSIZE")\n", num_match_cache_points, length); #endif - /* Overflow check */ - if (num_match_cache_points / length != (size_t)msa->num_cache_points) { - return ONIGERR_MEMORY; - } - if (num_match_cache_points >= LONG_MAX_LIMIT) { - return ONIGERR_MEMORY; - } - size_t match_cache_buf_length = (num_match_cache_points >> 3) + (num_match_cache_points & 7 ? 1 : 0) + 1; - uint8_t* match_cache_buf = (uint8_t*)xmalloc(match_cache_buf_length * sizeof(uint8_t)); - if (match_cache_buf == NULL) { - return ONIGERR_MEMORY; - } - xmemset(match_cache_buf, 0, match_cache_buf_length * sizeof(uint8_t)); - msa->match_cache_buf = match_cache_buf; - } + /* Overflow check */ + if (num_match_cache_points / length != (size_t)msa->num_cache_points) { + return ONIGERR_MEMORY; + } + if (num_match_cache_points >= LONG_MAX_LIMIT) { + return ONIGERR_MEMORY; + } + size_t match_cache_buf_length = (num_match_cache_points >> 3) + (num_match_cache_points & 7 ? 1 : 0) + 1; + uint8_t* match_cache_buf = (uint8_t*)xmalloc(match_cache_buf_length * sizeof(uint8_t)); + if (match_cache_buf == NULL) { + return ONIGERR_MEMORY; + } + xmemset(match_cache_buf, 0, match_cache_buf_length * sizeof(uint8_t)); + msa->match_cache_buf = match_cache_buf; + } } fail_match_cache: #endif #ifdef USE_COMBINATION_EXPLOSION_CHECK if (stk->u.state.state_check != 0) { - stk->type = STK_STATE_CHECK_MARK; - stk++; + stk->type = STK_STATE_CHECK_MARK; + stk++; } #endif @@ -4225,7 +4209,7 @@ static UChar* slow_search(OnigEncoding enc, UChar* target, UChar* target_end, - const UChar* text, const UChar* text_end, UChar* text_range) + const UChar* text, const UChar* text_end, UChar* text_range) { UChar *t, *p, *s, *end; @@ -4241,10 +4225,10 @@ while (s < end) { if (*s == *target) { - p = s + 1; - t = target + 1; - if (target_end == t || memcmp(t, p, target_end - t) == 0) - return s; + p = s + 1; + t = target + 1; + if (target_end == t || memcmp(t, p, target_end - t) == 0) + return s; } s += n; } @@ -4255,7 +4239,7 @@ p = s + 1; t = target + 1; if (target_end == t || memcmp(t, p, target_end - t) == 0) - return s; + return s; } s += enclen(enc, s, text_end); } @@ -4265,8 +4249,8 @@ static int str_lower_case_match(OnigEncoding enc, int case_fold_flag, - const UChar* t, const UChar* tend, - const UChar* p, const UChar* end) + const UChar* t, const UChar* tend, + const UChar* p, const UChar* end) { int lowlen; UChar *q, lowbuf[ONIGENC_MBC_CASE_FOLD_MAXLEN]; @@ -4285,8 +4269,8 @@ static UChar* slow_search_ic(OnigEncoding enc, int case_fold_flag, - UChar* target, UChar* target_end, - const UChar* text, const UChar* text_end, UChar* text_range) + UChar* target, UChar* target_end, + const UChar* text, const UChar* text_end, UChar* text_range) { UChar *s, *end; @@ -4299,7 +4283,7 @@ while (s < end) { if (str_lower_case_match(enc, case_fold_flag, target, target_end, - s, text_end)) + s, text_end)) return s; s += enclen(enc, s, text_end); @@ -4310,8 +4294,8 @@ static UChar* slow_search_backward(OnigEncoding enc, UChar* target, UChar* target_end, - const UChar* text, const UChar* adjust_text, - const UChar* text_end, const UChar* text_start) + const UChar* text, const UChar* adjust_text, + const UChar* text_end, const UChar* text_start) { UChar *t, *p, *s; @@ -4327,12 +4311,12 @@ p = s + 1; t = target + 1; while (t < target_end) { - if (*t != *p++) - break; - t++; + if (*t != *p++) + break; + t++; } if (t == target_end) - return s; + return s; } s = (UChar* )onigenc_get_prev_char_head(enc, adjust_text, s, text_end); } @@ -4342,9 +4326,9 @@ static UChar* slow_search_backward_ic(OnigEncoding enc, int case_fold_flag, - UChar* target, UChar* target_end, - const UChar* text, const UChar* adjust_text, - const UChar* text_end, const UChar* text_start) + UChar* target, UChar* target_end, + const UChar* text, const UChar* adjust_text, + const UChar* text_end, const UChar* text_start) { UChar *s; @@ -4357,7 +4341,7 @@ while (s >= text) { if (str_lower_case_match(enc, case_fold_flag, - target, target_end, s, text_end)) + target, target_end, s, text_end)) return s; s = (UChar* )onigenc_get_prev_char_head(enc, adjust_text, s, text_end); @@ -4366,224 +4350,11 @@ return (UChar* )NULL; } -#ifndef USE_SUNDAY_QUICK_SEARCH -/* Boyer-Moore-Horspool search applied to a multibyte string */ -static UChar* -bm_search_notrev(regex_t* reg, const UChar* target, const UChar* target_end, - const UChar* text, const UChar* text_end, - const UChar* text_range) -{ - const UChar *s, *se, *t, *p, *end; - const UChar *tail; - ptrdiff_t skip, tlen1; - -# ifdef ONIG_DEBUG_SEARCH - fprintf(stderr, "bm_search_notrev: text: %"PRIuPTR" (%p), text_end: %"PRIuPTR" (%p), text_range: %"PRIuPTR" (%p)\n", - (uintptr_t )text, text, (uintptr_t )text_end, text_end, (uintptr_t )text_range, text_range); -# endif - - tail = target_end - 1; - tlen1 = tail - target; - end = text_range; - if (end + tlen1 > text_end) - end = text_end - tlen1; - - s = text; - - if (IS_NULL(reg->int_map)) { - while (s < end) { - p = se = s + tlen1; - t = tail; - while (*p == *t) { - if (t == target) return (UChar* )s; - p--; t--; - } - skip = reg->map[*se]; - t = s; - do { - s += enclen(reg->enc, s, end); - } while ((s - t) < skip && s < end); - } - } - else { -# if OPT_EXACT_MAXLEN >= ONIG_CHAR_TABLE_SIZE - while (s < end) { - p = se = s + tlen1; - t = tail; - while (*p == *t) { - if (t == target) return (UChar* )s; - p--; t--; - } - skip = reg->int_map[*se]; - t = s; - do { - s += enclen(reg->enc, s, end); - } while ((s - t) < skip && s < end); - } -# endif - } - - return (UChar* )NULL; -} - -/* Boyer-Moore-Horspool search */ -static UChar* -bm_search(regex_t* reg, const UChar* target, const UChar* target_end, - const UChar* text, const UChar* text_end, const UChar* text_range) -{ - const UChar *s, *t, *p, *end; - const UChar *tail; - -# ifdef ONIG_DEBUG_SEARCH - fprintf(stderr, "bm_search: text: %"PRIuPTR" (%p), text_end: %"PRIuPTR" (%p), text_range: %"PRIuPTR" (%p)\n", - (uintptr_t )text, text, (uintptr_t )text_end, text_end, (uintptr_t )text_range, text_range); -# endif - - end = text_range + (target_end - target) - 1; - if (end > text_end) - end = text_end; - - tail = target_end - 1; - s = text + (target_end - target) - 1; - if (IS_NULL(reg->int_map)) { - while (s < end) { - p = s; - t = tail; -# ifdef ONIG_DEBUG_SEARCH - fprintf(stderr, "bm_search_loop: pos: %"PRIdPTR" %s\n", - (intptr_t )(s - text), s); -# endif - while (*p == *t) { - if (t == target) return (UChar* )p; - p--; t--; - } - s += reg->map[*s]; - } - } - else { /* see int_map[] */ -# if OPT_EXACT_MAXLEN >= ONIG_CHAR_TABLE_SIZE - while (s < end) { - p = s; - t = tail; - while (*p == *t) { - if (t == target) return (UChar* )p; - p--; t--; - } - s += reg->int_map[*s]; - } -# endif - } - return (UChar* )NULL; -} - -/* Boyer-Moore-Horspool search applied to a multibyte string (ignore case) */ -static UChar* -bm_search_notrev_ic(regex_t* reg, const UChar* target, const UChar* target_end, - const UChar* text, const UChar* text_end, - const UChar* text_range) -{ - const UChar *s, *se, *t, *end; - const UChar *tail; - ptrdiff_t skip, tlen1; - OnigEncoding enc = reg->enc; - int case_fold_flag = reg->case_fold_flag; - -# ifdef ONIG_DEBUG_SEARCH - fprintf(stderr, "bm_search_notrev_ic: text: %d (%p), text_end: %d (%p), text_range: %d (%p)\n", - (int )text, text, (int )text_end, text_end, (int )text_range, text_range); -# endif - - tail = target_end - 1; - tlen1 = tail - target; - end = text_range; - if (end + tlen1 > text_end) - end = text_end - tlen1; - - s = text; - - if (IS_NULL(reg->int_map)) { - while (s < end) { - se = s + tlen1; - if (str_lower_case_match(enc, case_fold_flag, target, target_end, - s, se + 1)) - return (UChar* )s; - skip = reg->map[*se]; - t = s; - do { - s += enclen(reg->enc, s, end); - } while ((s - t) < skip && s < end); - } - } - else { -# if OPT_EXACT_MAXLEN >= ONIG_CHAR_TABLE_SIZE - while (s < end) { - se = s + tlen1; - if (str_lower_case_match(enc, case_fold_flag, target, target_end, - s, se + 1)) - return (UChar* )s; - skip = reg->int_map[*se]; - t = s; - do { - s += enclen(reg->enc, s, end); - } while ((s - t) < skip && s < end); - } -# endif - } - - return (UChar* )NULL; -} - -/* Boyer-Moore-Horspool search (ignore case) */ -static UChar* -bm_search_ic(regex_t* reg, const UChar* target, const UChar* target_end, - const UChar* text, const UChar* text_end, const UChar* text_range) -{ - const UChar *s, *p, *end; - const UChar *tail; - OnigEncoding enc = reg->enc; - int case_fold_flag = reg->case_fold_flag; - -# ifdef ONIG_DEBUG_SEARCH - fprintf(stderr, "bm_search_ic: text: %d (%p), text_end: %d (%p), text_range: %d (%p)\n", - (int )text, text, (int )text_end, text_end, (int )text_range, text_range); -# endif - - end = text_range + (target_end - target) - 1; - if (end > text_end) - end = text_end; - - tail = target_end - 1; - s = text + (target_end - target) - 1; - if (IS_NULL(reg->int_map)) { - while (s < end) { - p = s - (target_end - target) + 1; - if (str_lower_case_match(enc, case_fold_flag, target, target_end, - p, s + 1)) - return (UChar* )p; - s += reg->map[*s]; - } - } - else { /* see int_map[] */ -# if OPT_EXACT_MAXLEN >= ONIG_CHAR_TABLE_SIZE - while (s < end) { - p = s - (target_end - target) + 1; - if (str_lower_case_match(enc, case_fold_flag, target, target_end, - p, s + 1)) - return (UChar* )p; - s += reg->int_map[*s]; - } -# endif - } - return (UChar* )NULL; -} - -#else /* USE_SUNDAY_QUICK_SEARCH */ - /* Sunday's quick search applied to a multibyte string */ static UChar* bm_search_notrev(regex_t* reg, const UChar* target, const UChar* target_end, - const UChar* text, const UChar* text_end, - const UChar* text_range) + const UChar* text, const UChar* text_end, + const UChar* text_range) { const UChar *s, *se, *t, *p, *end; const UChar *tail; @@ -4592,7 +4363,7 @@ # ifdef ONIG_DEBUG_SEARCH fprintf(stderr, "bm_search_notrev: text: %"PRIuPTR" (%p), text_end: %"PRIuPTR" (%p), text_range: %"PRIuPTR" (%p)\n", - (uintptr_t )text, text, (uintptr_t )text_end, text_end, (uintptr_t )text_range, text_range); + (uintptr_t )text, text, (uintptr_t )text_end, text_end, (uintptr_t )text_range, text_range); # endif tail = target_end - 1; @@ -4608,14 +4379,14 @@ p = se = s + tlen1; t = tail; while (*p == *t) { - if (t == target) return (UChar* )s; - p--; t--; + if (t == target) return (UChar* )s; + p--; t--; } if (s + 1 >= end) break; skip = reg->map[se[1]]; t = s; do { - s += enclen(enc, s, end); + s += enclen(enc, s, end); } while ((s - t) < skip && s < end); } } @@ -4625,14 +4396,14 @@ p = se = s + tlen1; t = tail; while (*p == *t) { - if (t == target) return (UChar* )s; - p--; t--; + if (t == target) return (UChar* )s; + p--; t--; } if (s + 1 >= end) break; skip = reg->int_map[se[1]]; t = s; do { - s += enclen(enc, s, end); + s += enclen(enc, s, end); } while ((s - t) < skip && s < end); } # endif @@ -4644,7 +4415,7 @@ /* Sunday's quick search */ static UChar* bm_search(regex_t* reg, const UChar* target, const UChar* target_end, - const UChar* text, const UChar* text_end, const UChar* text_range) + const UChar* text, const UChar* text_end, const UChar* text_range) { const UChar *s, *t, *p, *end; const UChar *tail; @@ -4652,7 +4423,7 @@ # ifdef ONIG_DEBUG_SEARCH fprintf(stderr, "bm_search: text: %"PRIuPTR" (%p), text_end: %"PRIuPTR" (%p), text_range: %"PRIuPTR" (%p)\n", - (uintptr_t )text, text, (uintptr_t )text_end, text_end, (uintptr_t )text_range, text_range); + (uintptr_t )text, text, (uintptr_t )text_end, text_end, (uintptr_t )text_range, text_range); # endif tail = target_end - 1; @@ -4667,8 +4438,8 @@ p = s; t = tail; while (*p == *t) { - if (t == target) return (UChar* )p; - p--; t--; + if (t == target) return (UChar* )p; + p--; t--; } if (s + 1 >= end) break; s += reg->map[s[1]]; @@ -4680,8 +4451,8 @@ p = s; t = tail; while (*p == *t) { - if (t == target) return (UChar* )p; - p--; t--; + if (t == target) return (UChar* )p; + p--; t--; } if (s + 1 >= end) break; s += reg->int_map[s[1]]; @@ -4694,8 +4465,8 @@ /* Sunday's quick search applied to a multibyte string (ignore case) */ static UChar* bm_search_notrev_ic(regex_t* reg, const UChar* target, const UChar* target_end, - const UChar* text, const UChar* text_end, - const UChar* text_range) + const UChar* text, const UChar* text_end, + const UChar* text_range) { const UChar *s, *se, *t, *end; const UChar *tail; @@ -4705,7 +4476,7 @@ # ifdef ONIG_DEBUG_SEARCH fprintf(stderr, "bm_search_notrev_ic: text: %"PRIuPTR" (%p), text_end: %"PRIuPTR" (%p), text_range: %"PRIuPTR" (%p)\n", - (uintptr_t )text, text, (uintptr_t )text_end, text_end, (uintptr_t )text_range, text_range); + (uintptr_t )text, text, (uintptr_t )text_end, text_end, (uintptr_t )text_range, text_range); # endif tail = target_end - 1; @@ -4720,13 +4491,13 @@ while (s < end) { se = s + tlen1; if (str_lower_case_match(enc, case_fold_flag, target, target_end, - s, se + 1)) - return (UChar* )s; + s, se + 1)) + return (UChar* )s; if (s + 1 >= end) break; skip = reg->map[se[1]]; t = s; do { - s += enclen(enc, s, end); + s += enclen(enc, s, end); } while ((s - t) < skip && s < end); } } @@ -4735,13 +4506,13 @@ while (s < end) { se = s + tlen1; if (str_lower_case_match(enc, case_fold_flag, target, target_end, - s, se + 1)) - return (UChar* )s; + s, se + 1)) + return (UChar* )s; if (s + 1 >= end) break; skip = reg->int_map[se[1]]; t = s; do { - s += enclen(enc, s, end); + s += enclen(enc, s, end); } while ((s - t) < skip && s < end); } # endif @@ -4753,7 +4524,7 @@ /* Sunday's quick search (ignore case) */ static UChar* bm_search_ic(regex_t* reg, const UChar* target, const UChar* target_end, - const UChar* text, const UChar* text_end, const UChar* text_range) + const UChar* text, const UChar* text_end, const UChar* text_range) { const UChar *s, *p, *end; const UChar *tail; @@ -4763,7 +4534,7 @@ # ifdef ONIG_DEBUG_SEARCH fprintf(stderr, "bm_search_ic: text: %"PRIuPTR" (%p), text_end: %"PRIuPTR" (%p), text_range: %"PRIuPTR" (%p)\n", - (uintptr_t )text, text, (uintptr_t )text_end, text_end, (uintptr_t )text_range, text_range); + (uintptr_t )text, text, (uintptr_t )text_end, text_end, (uintptr_t )text_range, text_range); # endif tail = target_end - 1; @@ -4777,8 +4548,8 @@ while (s < end) { p = s - tlen1; if (str_lower_case_match(enc, case_fold_flag, target, target_end, - p, s + 1)) - return (UChar* )p; + p, s + 1)) + return (UChar* )p; if (s + 1 >= end) break; s += reg->map[s[1]]; } @@ -4788,8 +4559,8 @@ while (s < end) { p = s - tlen1; if (str_lower_case_match(enc, case_fold_flag, target, target_end, - p, s + 1)) - return (UChar* )p; + p, s + 1)) + return (UChar* )p; if (s + 1 >= end) break; s += reg->int_map[s[1]]; } @@ -4797,12 +4568,11 @@ } return (UChar* )NULL; } -#endif /* USE_SUNDAY_QUICK_SEARCH */ #ifdef USE_INT_MAP_BACKWARD static int set_bm_backward_skip(UChar* s, UChar* end, OnigEncoding enc ARG_UNUSED, - int** skip) + int** skip) { int i, len; @@ -4823,8 +4593,8 @@ static UChar* bm_search_backward(regex_t* reg, const UChar* target, const UChar* target_end, - const UChar* text, const UChar* adjust_text, - const UChar* text_end, const UChar* text_start) + const UChar* text, const UChar* adjust_text, + const UChar* text_end, const UChar* text_start) { const UChar *s, *t, *p; @@ -4853,7 +4623,7 @@ static UChar* map_search(OnigEncoding enc, UChar map[], - const UChar* text, const UChar* text_range, const UChar* text_end) + const UChar* text, const UChar* text_range, const UChar* text_end) { const UChar *s = text; @@ -4867,8 +4637,8 @@ static UChar* map_search_backward(OnigEncoding enc, UChar map[], - const UChar* text, const UChar* adjust_text, - const UChar* text_start, const UChar* text_end) + const UChar* text, const UChar* adjust_text, + const UChar* text_start, const UChar* text_end) { const UChar *s = text_start; @@ -4882,7 +4652,7 @@ extern OnigPosition onig_match(regex_t* reg, const UChar* str, const UChar* end, const UChar* at, OnigRegion* region, - OnigOptionType option) + OnigOptionType option) { ptrdiff_t r; UChar *prev; @@ -4906,9 +4676,9 @@ prev = (UChar* )onigenc_get_prev_char_head(reg->enc, str, at, end); r = match_at(reg, str, end, #ifdef USE_MATCH_RANGE_MUST_BE_INSIDE_OF_SPECIFIED_RANGE - end, + end, #endif - at, prev, &msa); + at, prev, &msa); } MATCH_ARG_FREE(msa); @@ -4917,14 +4687,14 @@ static int forward_search_range(regex_t* reg, const UChar* str, const UChar* end, UChar* s, - UChar* range, UChar** low, UChar** high, UChar** low_prev) + UChar* range, UChar** low, UChar** high, UChar** low_prev) { UChar *p, *pprev = (UChar* )NULL; size_t input_len = end - str; #ifdef ONIG_DEBUG_SEARCH fprintf(stderr, "forward_search_range: str: %"PRIuPTR" (%p), end: %"PRIuPTR" (%p), s: %"PRIuPTR" (%p), range: %"PRIuPTR" (%p)\n", - (uintptr_t )str, str, (uintptr_t )end, end, (uintptr_t )s, s, (uintptr_t )range, range); + (uintptr_t )str, str, (uintptr_t )end, end, (uintptr_t )s, s, (uintptr_t )range, range); #endif if (reg->dmin > input_len) { @@ -4932,14 +4702,14 @@ } p = s; - if (reg->dmin > 0) { + if (reg->dmin != 0) { + if ((OnigDistance)(end - p) <= reg->dmin) return 0; /* fail */ if (ONIGENC_IS_SINGLEBYTE(reg->enc)) { p += reg->dmin; } else { UChar *q = p + reg->dmin; - if (q >= end) return 0; /* fail */ while (p < q) p += enclen(reg->enc, p, end); } } @@ -4951,7 +4721,7 @@ break; case ONIG_OPTIMIZE_EXACT_IC: p = slow_search_ic(reg->enc, reg->case_fold_flag, - reg->exact, reg->exact_end, p, end, range); + reg->exact, reg->exact_end, p, end, range); break; case ONIG_OPTIMIZE_EXACT_BM: @@ -4976,7 +4746,7 @@ } if (p && p < range) { - if (p - reg->dmin < s) { + if ((OnigDistance)(p - s) < reg->dmin) { retry_gate: pprev = p; p += enclen(reg->enc, p, end); @@ -4988,70 +4758,74 @@ switch (reg->sub_anchor) { case ANCHOR_BEGIN_LINE: - if (!ON_STR_BEGIN(p)) { - prev = onigenc_get_prev_char_head(reg->enc, - (pprev ? pprev : str), p, end); - if (!ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, prev, str, end, reg->options, 0)) - goto retry_gate; - } - break; + if (!ON_STR_BEGIN(p)) { + prev = onigenc_get_prev_char_head(reg->enc, + (pprev ? pprev : str), p, end); + if (!ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, prev, str, end, reg->options, 0)) + goto retry_gate; + } + break; case ANCHOR_END_LINE: - if (ON_STR_END(p)) { + if (ON_STR_END(p)) { #ifndef USE_NEWLINE_AT_END_OF_STRING_HAS_EMPTY_LINE - prev = (UChar* )onigenc_get_prev_char_head(reg->enc, - (pprev ? pprev : str), p); - if (prev && ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, prev, str, end, reg->options, 1)) - goto retry_gate; + prev = (UChar* )onigenc_get_prev_char_head(reg->enc, + (pprev ? pprev : str), p); + if (prev && ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, prev, str, end, reg->options, 1)) + goto retry_gate; #endif - } - else if (! ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, p, str, end, reg->options, 1)) - goto retry_gate; - break; + } + else if (! ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, p, str, end, reg->options, 1)) + goto retry_gate; + break; } } if (reg->dmax == 0) { *low = p; if (low_prev) { - if (*low > s) - *low_prev = onigenc_get_prev_char_head(reg->enc, s, p, end); - else - *low_prev = onigenc_get_prev_char_head(reg->enc, - (pprev ? pprev : str), p, end); + if (*low > s) + *low_prev = onigenc_get_prev_char_head(reg->enc, s, p, end); + else + *low_prev = onigenc_get_prev_char_head(reg->enc, + (pprev ? pprev : str), p, end); } + *high = p; } else { if (reg->dmax != ONIG_INFINITE_DISTANCE) { - if (p < str + reg->dmax) { - *low = (UChar* )str; - if (low_prev) - *low_prev = onigenc_get_prev_char_head(reg->enc, str, *low, end); - } - else { - *low = p - reg->dmax; - if (*low > s) { - *low = onigenc_get_right_adjust_char_head_with_prev(reg->enc, s, - *low, end, (const UChar** )low_prev); - if (low_prev && IS_NULL(*low_prev)) - *low_prev = onigenc_get_prev_char_head(reg->enc, - (pprev ? pprev : s), *low, end); - } - else { - if (low_prev) - *low_prev = onigenc_get_prev_char_head(reg->enc, - (pprev ? pprev : str), *low, end); - } - } + if ((OnigDistance)(p - str) < reg->dmax) { + *low = (UChar* )str; + if (low_prev) + *low_prev = onigenc_get_prev_char_head(reg->enc, str, *low, end); + } + else { + *low = p - reg->dmax; + if (*low > s) { + *low = onigenc_get_right_adjust_char_head_with_prev(reg->enc, s, + *low, end, (const UChar** )low_prev); + if (low_prev && IS_NULL(*low_prev)) + *low_prev = onigenc_get_prev_char_head(reg->enc, + (pprev ? pprev : s), *low, end); + } + else { + if (low_prev) + *low_prev = onigenc_get_prev_char_head(reg->enc, + (pprev ? pprev : str), *low, end); + } + } } + /* no needs to adjust *high, *high is used as range check only */ + if ((OnigDistance)(p - str) < reg->dmin) + *high = (UChar* )str; + else + *high = p - reg->dmin; } - /* no needs to adjust *high, *high is used as range check only */ - *high = p - reg->dmin; #ifdef ONIG_DEBUG_SEARCH fprintf(stderr, "forward_search_range success: low: %"PRIdPTR", high: %"PRIdPTR", dmin: %"PRIdPTR", dmax: %"PRIdPTR"\n", - *low - str, *high - str, reg->dmin, reg->dmax); + *low - str, *high - str, reg->dmin, reg->dmax); #endif return 1; /* success */ } @@ -5063,8 +4837,8 @@ static int backward_search_range(regex_t* reg, const UChar* str, const UChar* end, - UChar* s, const UChar* range, UChar* adjrange, - UChar** low, UChar** high) + UChar* s, const UChar* range, UChar* adjrange, + UChar** low, UChar** high) { UChar *p; size_t input_len = end - str; @@ -5073,7 +4847,6 @@ return 0; } - range += reg->dmin; p = s; retry: @@ -5081,15 +4854,15 @@ case ONIG_OPTIMIZE_EXACT: exact_method: p = slow_search_backward(reg->enc, reg->exact, reg->exact_end, - range, adjrange, end, p); + range, adjrange, end, p); break; case ONIG_OPTIMIZE_EXACT_IC: case ONIG_OPTIMIZE_EXACT_BM_IC: case ONIG_OPTIMIZE_EXACT_BM_NOT_REV_IC: p = slow_search_backward_ic(reg->enc, reg->case_fold_flag, - reg->exact, reg->exact_end, - range, adjrange, end, p); + reg->exact, reg->exact_end, + range, adjrange, end, p); break; case ONIG_OPTIMIZE_EXACT_BM: @@ -5098,14 +4871,14 @@ if (IS_NULL(reg->int_map_backward)) { int r; if (s - range < BM_BACKWARD_SEARCH_LENGTH_THRESHOLD) - goto exact_method; + goto exact_method; r = set_bm_backward_skip(reg->exact, reg->exact_end, reg->enc, - &(reg->int_map_backward)); + &(reg->int_map_backward)); if (r) return r; } p = bm_search_backward(reg, reg->exact, reg->exact_end, range, adjrange, - end, p); + end, p); #else goto exact_method; #endif @@ -5122,45 +4895,57 @@ switch (reg->sub_anchor) { case ANCHOR_BEGIN_LINE: - if (!ON_STR_BEGIN(p)) { - prev = onigenc_get_prev_char_head(reg->enc, str, p, end); - if (!ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, prev, str, end, reg->options, 0)) { - p = prev; - goto retry; - } - } - break; + if (!ON_STR_BEGIN(p)) { + prev = onigenc_get_prev_char_head(reg->enc, str, p, end); + if (!ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, prev, str, end, reg->options, 0)) { + p = prev; + goto retry; + } + } + break; case ANCHOR_END_LINE: - if (ON_STR_END(p)) { + if (ON_STR_END(p)) { #ifndef USE_NEWLINE_AT_END_OF_STRING_HAS_EMPTY_LINE - prev = onigenc_get_prev_char_head(reg->enc, adjrange, p); - if (IS_NULL(prev)) goto fail; - if (ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, prev, str, end, reg->options, 1)) { - p = prev; - goto retry; - } + prev = onigenc_get_prev_char_head(reg->enc, adjrange, p); + if (IS_NULL(prev)) goto fail; + if (ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, prev, str, end, reg->options, 1)) { + p = prev; + goto retry; + } #endif - } - else if (! ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, p, str, end, reg->options, 1)) { - p = onigenc_get_prev_char_head(reg->enc, adjrange, p, end); - if (IS_NULL(p)) goto fail; - goto retry; - } - break; + } + else if (! ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, p, str, end, reg->options, 1)) { + p = onigenc_get_prev_char_head(reg->enc, adjrange, p, end); + if (IS_NULL(p)) goto fail; + goto retry; + } + break; } } - /* no needs to adjust *high, *high is used as range check only */ if (reg->dmax != ONIG_INFINITE_DISTANCE) { - *low = p - reg->dmax; - *high = p - reg->dmin; + if ((OnigDistance)(p - str) < reg->dmax) + *low = (UChar* )str; + else + *low = p - reg->dmax; + + if (reg->dmin != 0) { + if ((OnigDistance)(p - str) < reg->dmin) + *high = (UChar* )str; + else + *high = p - reg->dmin; + } + else { + *high = p; + } + *high = onigenc_get_right_adjust_char_head(reg->enc, adjrange, *high, end); } #ifdef ONIG_DEBUG_SEARCH fprintf(stderr, "backward_search_range: low: %d, high: %d\n", - (int )(*low - str), (int )(*high - str)); + (int )(*low - str), (int )(*high - str)); #endif return 1; /* success */ } @@ -5175,15 +4960,15 @@ extern OnigPosition onig_search(regex_t* reg, const UChar* str, const UChar* end, - const UChar* start, const UChar* range, OnigRegion* region, OnigOptionType option) + const UChar* start, const UChar* range, OnigRegion* region, OnigOptionType option) { return onig_search_gpos(reg, str, end, start, start, range, region, option); } extern OnigPosition onig_search_gpos(regex_t* reg, const UChar* str, const UChar* end, - const UChar* global_pos, - const UChar* start, const UChar* range, OnigRegion* region, OnigOptionType option) + const UChar* global_pos, + const UChar* start, const UChar* range, OnigRegion* region, OnigOptionType option) { ptrdiff_t r; UChar *s, *prev; @@ -5283,62 +5068,69 @@ begin_position: if (range > start) { - if (global_pos > start) - { - if (global_pos < range) - range = global_pos + 1; - } - else - range = start + 1; + if (global_pos > start) + { + if (global_pos < range) + range = global_pos + 1; + } + else + range = start + 1; } else - range = start; + range = start; } else if (reg->anchor & ANCHOR_BEGIN_BUF) { /* search str-position only */ if (range > start) { - if (start != str) goto mismatch_no_msa; - range = str + 1; + if (start != str) goto mismatch_no_msa; + range = str + 1; } else { - if (range <= str) { - start = str; - range = str; - } - else - goto mismatch_no_msa; + if (range <= str) { + start = str; + range = str; + } + else + goto mismatch_no_msa; } } else if (reg->anchor & ANCHOR_END_BUF) { min_semi_end = max_semi_end = (UChar* )end; end_buf: - if ((OnigDistance )(max_semi_end - str) < reg->anchor_dmin) - goto mismatch_no_msa; + if ((OnigDistance)(max_semi_end - str) < reg->anchor_dmin) + goto mismatch_no_msa; if (range > start) { - if ((OnigDistance )(min_semi_end - start) > reg->anchor_dmax) { - start = min_semi_end - reg->anchor_dmax; - if (start < end) - start = onigenc_get_right_adjust_char_head(reg->enc, str, start, end); - } - if ((OnigDistance )(max_semi_end - (range - 1)) < reg->anchor_dmin) { - range = max_semi_end - reg->anchor_dmin + 1; - } + if ((OnigDistance)(min_semi_end - start) > reg->anchor_dmax) { + start = min_semi_end - reg->anchor_dmax; + if (start < end) + start = onigenc_get_right_adjust_char_head(reg->enc, str, start, end); + } + if ((OnigDistance)(max_semi_end - (range - 1)) < reg->anchor_dmin) { + if ((OnigDistance)(max_semi_end - str + 1) < reg->anchor_dmin) + goto mismatch_no_msa; + else + range = max_semi_end - reg->anchor_dmin + 1; + } - if (start > range) goto mismatch_no_msa; - /* If start == range, match with empty at end. - Backward search is used. */ + if (start > range) goto mismatch_no_msa; + /* If start == range, match with empty at end. + Backward search is used. */ } else { - if ((OnigDistance )(min_semi_end - range) > reg->anchor_dmax) { - range = min_semi_end - reg->anchor_dmax; - } - if ((OnigDistance )(max_semi_end - start) < reg->anchor_dmin) { - start = max_semi_end - reg->anchor_dmin; - start = ONIGENC_LEFT_ADJUST_CHAR_HEAD(reg->enc, str, start, end); - } - if (range > start) goto mismatch_no_msa; + if ((OnigDistance)(min_semi_end - range) > reg->anchor_dmax) { + range = min_semi_end - reg->anchor_dmax; + } + if ((OnigDistance)(max_semi_end - start) < reg->anchor_dmin) { + if ((OnigDistance)(max_semi_end - str) < reg->anchor_dmin) + goto mismatch_no_msa; + else { + start = max_semi_end - reg->anchor_dmin; + start = ONIGENC_LEFT_ADJUST_CHAR_HEAD(reg->enc, str, start, end); + } + } + if (range > start) goto mismatch_no_msa; } } else if (reg->anchor & ANCHOR_SEMI_END_BUF) { @@ -5346,23 +5138,23 @@ max_semi_end = (UChar* )end; if (ONIGENC_IS_MBC_NEWLINE(reg->enc, pre_end, end)) { - min_semi_end = pre_end; + min_semi_end = pre_end; #ifdef USE_CRNL_AS_LINE_TERMINATOR - pre_end = ONIGENC_STEP_BACK(reg->enc, str, pre_end, end, 1); - if (IS_NOT_NULL(pre_end) && - IS_NEWLINE_CRLF(reg->options) && - ONIGENC_IS_MBC_CRNL(reg->enc, pre_end, end)) { - min_semi_end = pre_end; - } + pre_end = ONIGENC_STEP_BACK(reg->enc, str, pre_end, end, 1); + if (IS_NOT_NULL(pre_end) && + IS_NEWLINE_CRLF(reg->options) && + ONIGENC_IS_MBC_CRNL(reg->enc, pre_end, end)) { + min_semi_end = pre_end; + } #endif - if (min_semi_end > str && start <= min_semi_end) { - goto end_buf; - } + if (min_semi_end > str && start <= min_semi_end) { + goto end_buf; + } } else { - min_semi_end = (UChar* )end; - goto end_buf; + min_semi_end = (UChar* )end; + goto end_buf; } } else if ((reg->anchor & ANCHOR_ANYCHAR_STAR_ML)) { @@ -5394,7 +5186,7 @@ #ifdef ONIG_DEBUG_SEARCH fprintf(stderr, "onig_search(apply anchor): end: %d, start: %d, range: %d\n", - (int )(end - str), (int )(start - str), (int )(range - str)); + (int )(end - str), (int )(start - str), (int )(range - str)); #endif MATCH_ARG_INIT(msa, option, region, start, global_pos); @@ -5415,55 +5207,59 @@ if (reg->optimize != ONIG_OPTIMIZE_NONE) { UChar *sch_range, *low, *high, *low_prev; - sch_range = (UChar* )range; if (reg->dmax != 0) { - if (reg->dmax == ONIG_INFINITE_DISTANCE) - sch_range = (UChar* )end; - else { - sch_range += reg->dmax; - if (sch_range > end) sch_range = (UChar* )end; - } + if (reg->dmax == ONIG_INFINITE_DISTANCE) + sch_range = (UChar* )end; + else { + if ((OnigDistance)(end - range) < reg->dmax) + sch_range = (UChar* )end; + else { + sch_range = (UChar* )range + reg->dmax; + } + } } + else + sch_range = (UChar* )range; if ((end - start) < reg->threshold_len) - goto mismatch; + goto mismatch; if (reg->dmax != ONIG_INFINITE_DISTANCE) { - do { - if (! forward_search_range(reg, str, end, s, sch_range, - &low, &high, &low_prev)) goto mismatch; - if (s < low) { - s = low; - prev = low_prev; - } - while (s <= high) { - MATCH_AND_RETURN_CHECK(orig_range); - prev = s; - s += enclen(reg->enc, s, end); - } - } while (s < range); - goto mismatch; + do { + if (! forward_search_range(reg, str, end, s, sch_range, + &low, &high, &low_prev)) goto mismatch; + if (s < low) { + s = low; + prev = low_prev; + } + while (s <= high) { + MATCH_AND_RETURN_CHECK(orig_range); + prev = s; + s += enclen(reg->enc, s, end); + } + } while (s < range); + goto mismatch; } else { /* check only. */ - if (! forward_search_range(reg, str, end, s, sch_range, - &low, &high, (UChar** )NULL)) goto mismatch; + if (! forward_search_range(reg, str, end, s, sch_range, + &low, &high, (UChar** )NULL)) goto mismatch; - if ((reg->anchor & ANCHOR_ANYCHAR_STAR) != 0) { - do { - MATCH_AND_RETURN_CHECK(orig_range); - prev = s; - s += enclen(reg->enc, s, end); - - if ((reg->anchor & (ANCHOR_LOOK_BEHIND | ANCHOR_PREC_READ_NOT)) == 0) { - while (!ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, prev, str, end, reg->options, 0) - && s < range) { - prev = s; - s += enclen(reg->enc, s, end); - } - } - } while (s < range); - goto mismatch; - } + if ((reg->anchor & ANCHOR_ANYCHAR_STAR) != 0) { + do { + MATCH_AND_RETURN_CHECK(orig_range); + prev = s; + s += enclen(reg->enc, s, end); + + if ((reg->anchor & (ANCHOR_LOOK_BEHIND | ANCHOR_PREC_READ_NOT)) == 0) { + while (!ONIGENC_IS_MBC_NEWLINE_EX(reg->enc, prev, str, end, reg->options, 0) + && s < range) { + prev = s; + s += enclen(reg->enc, s, end); + } + } + } while (s < range); + goto mismatch; + } } } @@ -5480,49 +5276,61 @@ else { /* backward search */ if (reg->optimize != ONIG_OPTIMIZE_NONE) { UChar *low, *high, *adjrange, *sch_start; + const UChar *min_range; if (range < end) - adjrange = ONIGENC_LEFT_ADJUST_CHAR_HEAD(reg->enc, str, range, end); + adjrange = ONIGENC_LEFT_ADJUST_CHAR_HEAD(reg->enc, str, range, end); else - adjrange = (UChar* )end; + adjrange = (UChar* )end; + + if ((OnigDistance)(end - range) > reg->dmin) + min_range = range + reg->dmin; + else + min_range = end; if (reg->dmax != ONIG_INFINITE_DISTANCE && - (end - range) >= reg->threshold_len) { - do { - sch_start = s + reg->dmax; - if (sch_start > end) sch_start = (UChar* )end; - if (backward_search_range(reg, str, end, sch_start, range, adjrange, - &low, &high) <= 0) - goto mismatch; - - if (s > high) - s = high; - - while (s >= low) { - prev = onigenc_get_prev_char_head(reg->enc, str, s, end); - MATCH_AND_RETURN_CHECK(orig_start); - s = prev; - } - } while (s >= range); - goto mismatch; + end - range >= reg->threshold_len) { + do { + if ((OnigDistance)(end - s) > reg->dmax) + sch_start = s + reg->dmax; + else + sch_start = (UChar* )end; + + if (backward_search_range(reg, str, end, sch_start, min_range, adjrange, + &low, &high) <= 0) + goto mismatch; + + if (s > high) + s = high; + + while (s >= low) { + prev = onigenc_get_prev_char_head(reg->enc, str, s, end); + MATCH_AND_RETURN_CHECK(orig_start); + s = prev; + } + } while (s >= range); + goto mismatch; } else { /* check only. */ - if ((end - range) < reg->threshold_len) goto mismatch; + if (end - range < reg->threshold_len) goto mismatch; - sch_start = s; - if (reg->dmax != 0) { - if (reg->dmax == ONIG_INFINITE_DISTANCE) - sch_start = (UChar* )end; - else { - sch_start += reg->dmax; - if (sch_start > end) sch_start = (UChar* )end; - else - sch_start = ONIGENC_LEFT_ADJUST_CHAR_HEAD(reg->enc, - start, sch_start, end); - } - } - if (backward_search_range(reg, str, end, sch_start, range, adjrange, - &low, &high) <= 0) goto mismatch; + if (reg->dmax != 0) { + if (reg->dmax == ONIG_INFINITE_DISTANCE) + sch_start = (UChar* )end; + else { + if ((OnigDistance)(end - s) > reg->dmax) { + sch_start = s + reg->dmax; + sch_start = ONIGENC_LEFT_ADJUST_CHAR_HEAD(reg->enc, + start, sch_start, end); + } else + sch_start = (UChar* )end; + } + } + else + sch_start = (UChar* )s; + + if (backward_search_range(reg, str, end, sch_start, min_range, adjrange, + &low, &high) <= 0) goto mismatch; } } @@ -5579,9 +5387,9 @@ extern OnigPosition onig_scan(regex_t* reg, const UChar* str, const UChar* end, - OnigRegion* region, OnigOptionType option, - int (*scan_callback)(OnigPosition, OnigPosition, OnigRegion*, void*), - void* callback_arg) + OnigRegion* region, OnigOptionType option, + int (*scan_callback)(OnigPosition, OnigPosition, OnigRegion*, void*), + void* callback_arg) { OnigPosition r; OnigPosition n; @@ -5596,17 +5404,17 @@ rs = scan_callback(n, r, region, callback_arg); n++; if (rs != 0) - return rs; + return rs; if (region->end[0] == start - str) { - if (start >= end) break; - start += enclen(reg->enc, start, end); + if (start >= end) break; + start += enclen(reg->enc, start, end); } else - start = str + region->end[0]; + start = str + region->end[0]; if (start > end) - break; + break; } else if (r == ONIG_MISMATCH) { break; diff -Nru ruby3.3-3.3.8/regint.h ruby3.3-3.3.13/regint.h --- ruby3.3-3.3.8/regint.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/regint.h 2026-10-23 03:17:41.000000000 +0000 @@ -86,7 +86,6 @@ /* #define USE_OP_PUSH_OR_JUMP_EXACT */ #define USE_QTFR_PEEK_NEXT #define USE_ST_LIBRARY -#define USE_SUNDAY_QUICK_SEARCH #define INIT_MATCH_STACK_SIZE 160 #define DEFAULT_MATCH_STACK_LIMIT_SIZE 0 /* unlimited */ @@ -394,6 +393,11 @@ #define INT_MAX_LIMIT ((1UL << (SIZEOF_INT * 8 - 1)) - 1) #define LONG_MAX_LIMIT ((1UL << (SIZEOF_LONG * 8 - 1)) - 1) +/* Program offsets are RelAddrType, and the compile_length_*() functions sum + into int, so a larger program would wrap both. The quarter leaves room + for the sums the offset arithmetic makes out of those lengths. */ +#define MAX_COMPILED_PROGRAM_SIZE ((unsigned int )(INT_MAX_LIMIT / 4)) + #define DIGITVAL(code) ((code) - '0') #define ODIGITVAL(code) DIGITVAL(code) #define XDIGITVAL(enc,code) \ diff -Nru ruby3.3-3.3.8/regparse.c ruby3.3-3.3.13/regparse.c --- ruby3.3-3.3.8/regparse.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/regparse.c 2026-10-23 03:17:41.000000000 +0000 @@ -329,7 +329,7 @@ static UChar* strcat_capa(UChar* dest, UChar* dest_end, const UChar* src, const UChar* src_end, - size_t capa) + size_t capa) { UChar* r; @@ -346,7 +346,7 @@ /* dest on static area */ static UChar* strcat_capa_from_static(UChar* dest, UChar* dest_end, - const UChar* src, const UChar* src_end, size_t capa) + const UChar* src, const UChar* src_end, size_t capa) { UChar* r; @@ -426,7 +426,7 @@ extern int onig_st_lookup_strend(hash_table_type* table, const UChar* str_key, - const UChar* end_key, hash_data_type *value) + const UChar* end_key, hash_data_type *value) { st_str_end_key key; @@ -438,7 +438,7 @@ extern int onig_st_insert_strend(hash_table_type* table, const UChar* str_key, - const UChar* end_key, hash_data_type value) + const UChar* end_key, hash_data_type value) { st_str_end_key* key; int result; @@ -630,10 +630,10 @@ NameEntry* e = (NameEntry *)e_; INamesArg* arg = (INamesArg *)arg_; int r = (*(arg->func))(e->name, - e->name + e->name_len, - e->back_num, - (e->back_num > 1 ? e->back_refs : &(e->back_ref1)), - arg->reg, arg->arg); + e->name + e->name_len, + e->back_num, + (e->back_num > 1 ? e->back_refs : &(e->back_ref1)), + arg->reg, arg->arg); if (r != 0) { arg->ret = r; return ST_STOP; @@ -725,16 +725,16 @@ e = &(t->e[i]); fprintf(fp, "%s: ", e->name); if (e->back_num == 0) { - fputs("-", fp); + fputs("-", fp); } else if (e->back_num == 1) { - fprintf(fp, "%d", e->back_ref1); + fprintf(fp, "%d", e->back_ref1); } else { - for (j = 0; j < e->back_num; j++) { - if (j > 0) fprintf(fp, ", "); - fprintf(fp, "%d", e->back_refs[j]); - } + for (j = 0; j < e->back_num; j++) { + if (j > 0) fprintf(fp, ", "); + fprintf(fp, "%d", e->back_refs[j]); + } } fputs("\n", fp); } @@ -755,13 +755,13 @@ for (i = 0; i < t->num; i++) { e = &(t->e[i]); if (IS_NOT_NULL(e->name)) { - xfree(e->name); - e->name = NULL; - e->name_len = 0; - e->back_num = 0; - e->back_alloc = 0; - xfree(e->back_refs); - e->back_refs = (int* )NULL; + xfree(e->name); + e->name = NULL; + e->name_len = 0; + e->back_num = 0; + e->back_alloc = 0; + xfree(e->back_refs); + e->back_refs = (int* )NULL; } } if (IS_NOT_NULL(t->e)) { @@ -842,7 +842,7 @@ for (i = 0; i < t->num; i++) { e = &(t->e[i]); if (len == e->name_len && onig_strncmp(name, e->name, len) == 0) - return e; + return e; } } return (NameEntry* )NULL; @@ -860,8 +860,8 @@ for (i = 0; i < t->num; i++) { e = &(t->e[i]); r = (*func)(e->name, e->name + e->name_len, e->back_num, - (e->back_num > 1 ? e->back_refs : &(e->back_ref1)), - reg, arg); + (e->back_num > 1 ? e->back_refs : &(e->back_ref1)), + reg, arg); if (r != 0) return r; } } @@ -950,8 +950,8 @@ t->e = (NameEntry* )xmalloc(sizeof(NameEntry) * alloc); if (IS_NULL(t->e)) { - xfree(t); - return ONIGERR_MEMORY; + xfree(t); + return ONIGERR_MEMORY; } t->alloc = alloc; reg->name_table = t; @@ -969,11 +969,11 @@ clear: for (i = t->num; i < t->alloc; i++) { - t->e[i].name = NULL; - t->e[i].name_len = 0; - t->e[i].back_num = 0; - t->e[i].back_alloc = 0; - t->e[i].back_refs = (int* )NULL; + t->e[i].name = NULL; + t->e[i].name_len = 0; + t->e[i].back_num = 0; + t->e[i].back_alloc = 0; + t->e[i].back_refs = (int* )NULL; } } e = &(t->e[t->num]); @@ -987,7 +987,7 @@ if (e->back_num >= 1 && ! IS_SYNTAX_BV(env->syntax, ONIG_SYN_ALLOW_MULTIPLEX_DEFINITION_NAME)) { onig_scan_env_set_error_string(env, ONIGERR_MULTIPLEX_DEFINED_NAME, - name, name_end); + name, name_end); return ONIGERR_MULTIPLEX_DEFINED_NAME; } @@ -1006,12 +1006,12 @@ } else { if (e->back_num > e->back_alloc) { - int* p; - alloc = e->back_alloc * 2; - p = (int* )xrealloc(e->back_refs, sizeof(int) * alloc); - CHECK_NULL_RETURN_MEMERR(p); - e->back_refs = p; - e->back_alloc = alloc; + int* p; + alloc = e->back_alloc * 2; + p = (int* )xrealloc(e->back_refs, sizeof(int) * alloc); + CHECK_NULL_RETURN_MEMERR(p); + e->back_refs = p; + e->back_alloc = alloc; } e->back_refs[e->back_num - 1] = backref; } @@ -1022,7 +1022,7 @@ extern int onig_name_to_group_numbers(regex_t* reg, const UChar* name, - const UChar* name_end, int** nums) + const UChar* name_end, int** nums) { NameEntry* e = name_find(reg, name, name_end); @@ -1044,7 +1044,7 @@ extern int onig_name_to_backref_number(regex_t* reg, const UChar* name, - const UChar* name_end, const OnigRegion *region) + const UChar* name_end, const OnigRegion *region) { int i, n, *nums; @@ -1058,8 +1058,8 @@ else { if (IS_NOT_NULL(region)) { for (i = n - 1; i >= 0; i--) { - if (region->beg[nums[i]] != ONIG_REGION_NOTPOS) - return nums[i]; + if (region->beg[nums[i]] != ONIG_REGION_NOTPOS) + return nums[i]; } } return nums[n - 1]; @@ -1070,14 +1070,14 @@ extern int onig_name_to_group_numbers(regex_t* reg, const UChar* name, - const UChar* name_end, int** nums) + const UChar* name_end, int** nums) { return ONIG_NO_SUPPORT_CONFIG; } extern int onig_name_to_backref_number(regex_t* reg, const UChar* name, - const UChar* name_end, const OnigRegion* region) + const UChar* name_end, const OnigRegion* region) { return ONIG_NO_SUPPORT_CONFIG; } @@ -1166,20 +1166,20 @@ if (need >= SCANENV_MEMNODES_SIZE) { if (env->mem_alloc <= need) { if (IS_NULL(env->mem_nodes_dynamic)) { - alloc = INIT_SCANENV_MEMNODES_ALLOC_SIZE; - p = (Node** )xmalloc(sizeof(Node*) * alloc); - CHECK_NULL_RETURN_MEMERR(p); - xmemcpy(p, env->mem_nodes_static, - sizeof(Node*) * SCANENV_MEMNODES_SIZE); + alloc = INIT_SCANENV_MEMNODES_ALLOC_SIZE; + p = (Node** )xmalloc(sizeof(Node*) * alloc); + CHECK_NULL_RETURN_MEMERR(p); + xmemcpy(p, env->mem_nodes_static, + sizeof(Node*) * SCANENV_MEMNODES_SIZE); } else { - alloc = env->mem_alloc * 2; - p = (Node** )xrealloc(env->mem_nodes_dynamic, sizeof(Node*) * alloc); - CHECK_NULL_RETURN_MEMERR(p); + alloc = env->mem_alloc * 2; + p = (Node** )xrealloc(env->mem_nodes_dynamic, sizeof(Node*) * alloc); + CHECK_NULL_RETURN_MEMERR(p); } for (i = env->num_mem + 1; i < alloc; i++) - p[i] = NULL_NODE; + p[i] = NULL_NODE; env->mem_nodes_dynamic = p; env->mem_alloc = alloc; @@ -1210,7 +1210,7 @@ switch (NTYPE(node)) { case NT_STR: if (NSTR(node)->capa != 0 && - IS_NOT_NULL(NSTR(node)->s) && NSTR(node)->s != NSTR(node)->buf) { + IS_NOT_NULL(NSTR(node)->s) && NSTR(node)->s != NSTR(node)->buf) { xfree(NSTR(node)->s); } break; @@ -1373,9 +1373,9 @@ static Node* node_new_backref(int back_num, int* backrefs, int by_name, #ifdef USE_BACKREF_WITH_LEVEL - int exist_level, int nest_level, + int exist_level, int nest_level, #endif - ScanEnv* env) + ScanEnv* env) { int i; Node* node = node_new(); @@ -1398,7 +1398,7 @@ for (i = 0; i < back_num; i++) { if (backrefs[i] <= env->num_mem && - IS_NULL(SCANENV_MEM_NODES(env)[backrefs[i]])) { + IS_NULL(SCANENV_MEM_NODES(env)[backrefs[i]])) { NBREF(node)->state |= NST_RECURSION; /* /...(\1).../ */ break; } @@ -1523,18 +1523,18 @@ ptrdiff_t capa = len + addlen + NODE_STR_MARGIN; if (capa <= NSTR(node)->capa) { - onig_strcpy(NSTR(node)->s + len, s, end); + onig_strcpy(NSTR(node)->s + len, s, end); } else { - if (NSTR(node)->s == NSTR(node)->buf) - p = strcat_capa_from_static(NSTR(node)->s, NSTR(node)->end, - s, end, capa); - else - p = strcat_capa(NSTR(node)->s, NSTR(node)->end, s, end, capa); - - CHECK_NULL_RETURN_MEMERR(p); - NSTR(node)->s = p; - NSTR(node)->capa = (int )capa; + if (NSTR(node)->s == NSTR(node)->buf) + p = strcat_capa_from_static(NSTR(node)->s, NSTR(node)->end, + s, end, capa); + else + p = strcat_capa(NSTR(node)->s, NSTR(node)->end, s, end, capa); + + CHECK_NULL_RETURN_MEMERR(p); + NSTR(node)->s = p; + NSTR(node)->capa = (int )capa; } } else { @@ -1656,7 +1656,7 @@ if (p && p > sn->s) { /* can be split. */ n = node_new_str(p, sn->end); if (IS_NOT_NULL(n) && (sn->flag & NSTR_RAW) != 0) - NSTRING_SET_RAW(n); + NSTRING_SET_RAW(n); sn->end = (UChar* )p; } } @@ -1704,7 +1704,7 @@ if (ONIGENC_IS_CODE_DIGIT(enc, c)) { val = (unsigned int )DIGITVAL(c); if ((INT_MAX_LIMIT - val) / 10UL < num) - return -1; /* overflow */ + return -1; /* overflow */ num = num * 10 + val; } @@ -1719,7 +1719,7 @@ static int scan_unsigned_hexadecimal_number(UChar** src, UChar* end, int minlen, - int maxlen, OnigEncoding enc) + int maxlen, OnigEncoding enc) { OnigCodePoint c; unsigned int num, val; @@ -1734,7 +1734,7 @@ if (ONIGENC_IS_CODE_XDIGIT(enc, c)) { val = (unsigned int )XDIGITVAL(enc,c); if ((INT_MAX_LIMIT - val) / 16UL < num) - return -1; /* overflow */ + return -1; /* overflow */ num = (num << 4) + XDIGITVAL(enc,c); } @@ -1752,7 +1752,7 @@ static int scan_unsigned_octal_number(UChar** src, UChar* end, int maxlen, - OnigEncoding enc) + OnigEncoding enc) { OnigCodePoint c; unsigned int num, val; @@ -1765,7 +1765,7 @@ if (ONIGENC_IS_CODE_DIGIT(enc, c) && c < '8') { val = ODIGITVAL(c); if ((INT_MAX_LIMIT - val) / 8UL < num) - return -1; /* overflow */ + return -1; /* overflow */ num = (num << 3) + val; } @@ -1806,7 +1806,7 @@ static int add_code_range_to_buf0(BBuf** pbuf, ScanEnv* env, OnigCodePoint from, OnigCodePoint to, - int checkdup) + int checkdup) { int r, inc_n, pos; OnigCodePoint low, high, bound, x; @@ -1857,7 +1857,7 @@ if (inc_n != 1) { if (checkdup && from <= data[low*2+1] - && (data[low*2] <= from || data[low*2+1] <= to)) + && (data[low*2] <= from || data[low*2+1] <= to)) CC_DUP_WARN(env, from, to); if (from > data[low*2]) from = data[low*2]; @@ -1871,8 +1871,8 @@ if (inc_n > 0) { if (high < n) { - int size = (n - high) * 2 * SIZE_CODE_POINT; - BBUF_MOVE_RIGHT(bbuf, from_pos, to_pos, size); + int size = (n - high) * 2 * SIZE_CODE_POINT; + BBUF_MOVE_RIGHT(bbuf, from_pos, to_pos, size); } } else { @@ -1982,10 +1982,10 @@ } else { if (not2 == 0) { - return bbuf_clone(pbuf, bbuf2); + return bbuf_clone(pbuf, bbuf2); } else { - return not_code_range_buf(enc, bbuf2, pbuf, env); + return not_code_range_buf(enc, bbuf2, pbuf, env); } } } @@ -2016,7 +2016,7 @@ static int and_code_range1(BBuf** pbuf, ScanEnv* env, OnigCodePoint from1, OnigCodePoint to1, - OnigCodePoint* data, int n) + OnigCodePoint* data, int n) { int i, r; OnigCodePoint from2, to2; @@ -2027,19 +2027,19 @@ if (from2 < from1) { if (to2 < from1) continue; else { - from1 = to2 + 1; + from1 = to2 + 1; } } else if (from2 <= to1) { if (to2 < to1) { - if (from1 <= from2 - 1) { - r = add_code_range_to_buf(pbuf, env, from1, from2-1); - if (r != 0) return r; - } - from1 = to2 + 1; + if (from1 <= from2 - 1) { + r = add_code_range_to_buf(pbuf, env, from1, from2-1); + if (r != 0) return r; + } + from1 = to2 + 1; } else { - to1 = from2 - 1; + to1 = from2 - 1; } } else { @@ -2088,14 +2088,14 @@ from1 = data1[i*2]; to1 = data1[i*2+1]; for (j = 0; j < n2; j++) { - from2 = data2[j*2]; - to2 = data2[j*2+1]; - if (from2 > to1) break; - if (to2 < from1) continue; - from = MAX(from1, from2); - to = MIN(to1, to2); - r = add_code_range_to_buf(pbuf, env, from, to); - if (r != 0) return r; + from2 = data2[j*2]; + to2 = data2[j*2+1]; + if (from2 > to1) break; + if (to2 < from1) continue; + from = MAX(from1, from2); + to = MIN(to1, to2); + r = add_code_range_to_buf(pbuf, env, from, to); + if (r != 0) return r; } } } @@ -2151,10 +2151,10 @@ else { r = and_code_range_buf(buf1, not1, buf2, not2, &pbuf, env); if (r == 0 && not1 != 0) { - BBuf *tbuf = 0; - r = not_code_range_buf(enc, pbuf, &tbuf, env); - bbuf_free(pbuf); - pbuf = tbuf; + BBuf *tbuf = 0; + r = not_code_range_buf(enc, pbuf, &tbuf, env); + bbuf_free(pbuf); + pbuf = tbuf; } } if (r != 0) { @@ -2209,10 +2209,10 @@ else { r = or_code_range_buf(enc, buf1, not1, buf2, not2, &pbuf, env); if (r == 0 && not1 != 0) { - BBuf *tbuf = 0; - r = not_code_range_buf(enc, pbuf, &tbuf, env); - bbuf_free(pbuf); - pbuf = tbuf; + BBuf *tbuf = 0; + r = not_code_range_buf(enc, pbuf, &tbuf, env); + bbuf_free(pbuf); + pbuf = tbuf; } } if (r != 0) { @@ -2244,12 +2244,12 @@ case 'e': return '\033'; case 'v': if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_ESC_V_VTAB)) - return '\v'; + return '\v'; break; default: if (('a' <= c && c <= 'z') || ('A' <= c && c <= 'Z')) - UNKNOWN_ESC_WARN(env, c); + UNKNOWN_ESC_WARN(env, c); break; } } @@ -2508,7 +2508,7 @@ if (p == prev) { if (non_low != 0) - goto invalid; + goto invalid; up = REPEAT_INFINITE; /* {n,} : {n,infinite} */ } } @@ -2568,8 +2568,8 @@ if (PEND) return ONIGERR_END_PATTERN_AT_META; PFETCH_S(c); if (c == MC_ESC(env->syntax)) { - v = fetch_escaped_value(&p, end, env, &c); - if (v < 0) return v; + v = fetch_escaped_value(&p, end, env, &c); + if (v < 0) return v; } c = ((c & 0xff) | 0x80); } @@ -2593,14 +2593,14 @@ if (PEND) return ONIGERR_END_PATTERN_AT_CONTROL; PFETCH_S(c); if (c == '?') { - c = 0177; + c = 0177; } else { - if (c == MC_ESC(env->syntax)) { - v = fetch_escaped_value(&p, end, env, &c); - if (v < 0) return v; - } - c &= 0x9f; + if (c == MC_ESC(env->syntax)) { + v = fetch_escaped_value(&p, end, env, &c); + if (v < 0) return v; + } + c &= 0x9f; } break; } @@ -2651,8 +2651,8 @@ */ static int fetch_name_with_level(OnigCodePoint start_code, UChar** src, UChar* end, - UChar** rname_end, ScanEnv* env, - int* rback_num, int* rlevel) + UChar** rname_end, ScanEnv* env, + int* rback_num, int* rlevel) { int r, sign, is_num, exist_level; OnigCodePoint end_code; @@ -2703,11 +2703,11 @@ if (is_num != 0) { if (ONIGENC_IS_CODE_DIGIT(enc, c)) { - is_num = 1; + is_num = 1; } else { - r = ONIGERR_INVALID_GROUP_NAME; - is_num = 0; + r = ONIGERR_INVALID_GROUP_NAME; + is_num = 0; } } else if (!ONIGENC_IS_CODE_NAME(enc, c)) { @@ -2721,8 +2721,8 @@ int flag = (c == '-' ? -1 : 1); if (PEND) { - r = ONIGERR_INVALID_CHAR_IN_GROUP_NAME; - goto end; + r = ONIGERR_INVALID_CHAR_IN_GROUP_NAME; + goto end; } PFETCH(c); if (! ONIGENC_IS_CODE_DIGIT(enc, c)) goto err; @@ -2733,9 +2733,9 @@ exist_level = 1; if (!PEND) { - PFETCH(c); - if (c == end_code) - goto end; + PFETCH(c); + if (c == end_code) + goto end; } } @@ -2771,7 +2771,7 @@ */ static int fetch_name(OnigCodePoint start_code, UChar** src, UChar* end, - UChar** rname_end, ScanEnv* env, int* rback_num, int ref) + UChar** rname_end, ScanEnv* env, int* rback_num, int ref) { int r, is_num, sign; OnigCodePoint end_code; @@ -2800,21 +2800,21 @@ if (ONIGENC_IS_CODE_DIGIT(enc, c)) { if (ref == 1) - is_num = 1; + is_num = 1; else { - r = ONIGERR_INVALID_GROUP_NAME; - is_num = 0; + r = ONIGERR_INVALID_GROUP_NAME; + is_num = 0; } } else if (c == '-') { if (ref == 1) { - is_num = 2; - sign = -1; - pnum_head = p; + is_num = 2; + sign = -1; + pnum_head = p; } else { - r = ONIGERR_INVALID_GROUP_NAME; - is_num = 0; + r = ONIGERR_INVALID_GROUP_NAME; + is_num = 0; } } else if (!ONIGENC_IS_CODE_NAME(enc, c)) { @@ -2827,30 +2827,30 @@ name_end = p; PFETCH_S(c); if (c == end_code || c == ')') { - if (is_num == 2) { - r = ONIGERR_INVALID_GROUP_NAME; - goto teardown; - } - break; + if (is_num == 2) { + r = ONIGERR_INVALID_GROUP_NAME; + goto teardown; + } + break; } if (is_num != 0) { - if (ONIGENC_IS_CODE_DIGIT(enc, c)) { - is_num = 1; - } - else { - if (!ONIGENC_IS_CODE_WORD(enc, c)) - r = ONIGERR_INVALID_CHAR_IN_GROUP_NAME; - else - r = ONIGERR_INVALID_GROUP_NAME; - goto teardown; - } + if (ONIGENC_IS_CODE_DIGIT(enc, c)) { + is_num = 1; + } + else { + if (!ONIGENC_IS_CODE_WORD(enc, c)) + r = ONIGERR_INVALID_CHAR_IN_GROUP_NAME; + else + r = ONIGERR_INVALID_GROUP_NAME; + goto teardown; + } } else { - if (!ONIGENC_IS_CODE_NAME(enc, c)) { - r = ONIGERR_INVALID_CHAR_IN_GROUP_NAME; - goto teardown; - } + if (!ONIGENC_IS_CODE_NAME(enc, c)) { + r = ONIGERR_INVALID_CHAR_IN_GROUP_NAME; + goto teardown; + } } } @@ -2864,8 +2864,8 @@ *rback_num = onig_scan_unsigned_number(&pnum_head, name_end, enc); if (*rback_num < 0) return ONIGERR_TOO_BIG_NUMBER; else if (*rback_num == 0) { - r = ONIGERR_INVALID_GROUP_NAME; - goto err; + r = ONIGERR_INVALID_GROUP_NAME; + goto err; } *rback_num *= sign; @@ -2881,7 +2881,7 @@ name_end = p; PFETCH_S(c); if (c == end_code || c == ')') - break; + break; } if (PEND) name_end = end; @@ -2894,7 +2894,7 @@ #else static int fetch_name(OnigCodePoint start_code, UChar** src, UChar* end, - UChar** rname_end, ScanEnv* env, int* rback_num, int ref) + UChar** rname_end, ScanEnv* env, int* rback_num, int ref) { int r, is_num, sign; OnigCodePoint end_code; @@ -2982,8 +2982,8 @@ UChar buf[WARN_BUFSIZE]; va_start(args, fmt); onig_vsnprintf_with_pattern(buf, WARN_BUFSIZE, env->enc, - env->pattern, env->pattern_end, - fmt, args); + env->pattern, env->pattern_end, + fmt, args); va_end(args); #ifdef RUBY if (env->sourcefile == NULL) @@ -3045,7 +3045,7 @@ static UChar* find_str_position(OnigCodePoint s[], int n, UChar* from, UChar* to, - UChar **next, OnigEncoding enc) + UChar **next, OnigEncoding enc) { int i; OnigCodePoint x; @@ -3057,14 +3057,14 @@ q = p + enclen(enc, p, to); if (x == s[0]) { for (i = 1; i < n && q < to; i++) { - x = ONIGENC_MBC_TO_CODE(enc, q, to); - if (x != s[i]) break; - q += enclen(enc, q, to); + x = ONIGENC_MBC_TO_CODE(enc, q, to); + if (x != s[i]) break; + q += enclen(enc, q, to); } if (i >= n) { - if (IS_NOT_NULL(next)) - *next = q; - return p; + if (IS_NOT_NULL(next)) + *next = q; + return p; } } p = q; @@ -3074,7 +3074,7 @@ static int str_exist_check_with_esc(OnigCodePoint s[], int n, UChar* from, UChar* to, - OnigCodePoint bad, OnigEncoding enc, const OnigSyntaxType* syn) + OnigCodePoint bad, OnigEncoding enc, const OnigSyntaxType* syn) { int i, in_esc; OnigCodePoint x; @@ -3091,19 +3091,19 @@ x = ONIGENC_MBC_TO_CODE(enc, p, to); q = p + enclen(enc, p, to); if (x == s[0]) { - for (i = 1; i < n && q < to; i++) { - x = ONIGENC_MBC_TO_CODE(enc, q, to); - if (x != s[i]) break; - q += enclen(enc, q, to); - } - if (i >= n) return 1; - p += enclen(enc, p, to); + for (i = 1; i < n && q < to; i++) { + x = ONIGENC_MBC_TO_CODE(enc, q, to); + if (x != s[i]) break; + q += enclen(enc, q, to); + } + if (i >= n) return 1; + p += enclen(enc, p, to); } else { - x = ONIGENC_MBC_TO_CODE(enc, p, to); - if (x == bad) return 0; - else if (x == MC_ESC(syn)) in_esc = 1; - p = q; + x = ONIGENC_MBC_TO_CODE(enc, p, to); + if (x == bad) return 0; + else if (x == MC_ESC(syn)) in_esc = 1; + p = q; } } } @@ -3197,22 +3197,22 @@ c2 = PPEEK; if (c2 == '{' && - IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_P_BRACE_CHAR_PROPERTY)) { - PINC; - tok->type = TK_CHAR_PROPERTY; - tok->u.prop.not = (c == 'P' ? 1 : 0); - - if (!PEND && IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_P_BRACE_CIRCUMFLEX_NOT)) { - PFETCH(c2); - if (c2 == '^') { - tok->u.prop.not = (tok->u.prop.not == 0 ? 1 : 0); - } - else - PUNFETCH; - } + IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_P_BRACE_CHAR_PROPERTY)) { + PINC; + tok->type = TK_CHAR_PROPERTY; + tok->u.prop.not = (c == 'P' ? 1 : 0); + + if (!PEND && IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_P_BRACE_CIRCUMFLEX_NOT)) { + PFETCH(c2); + if (c2 == '^') { + tok->u.prop.not = (tok->u.prop.not == 0 ? 1 : 0); + } + else + PUNFETCH; + } } else { - onig_syntax_warn(env, "invalid Unicode Property \\%c", c); + onig_syntax_warn(env, "invalid Unicode Property \\%c", c); } break; @@ -3221,35 +3221,35 @@ prev = p; if (PPEEK_IS('{') && IS_SYNTAX_OP(syn, ONIG_SYN_OP_ESC_X_BRACE_HEX8)) { - PINC; - num = scan_unsigned_hexadecimal_number(&p, end, 0, 8, enc); - if (num < 0) return ONIGERR_TOO_BIG_WIDE_CHAR_VALUE; - if (!PEND) { - c2 = PPEEK; - if (ONIGENC_IS_CODE_XDIGIT(enc, c2)) - return ONIGERR_TOO_LONG_WIDE_CHAR_VALUE; - } + PINC; + num = scan_unsigned_hexadecimal_number(&p, end, 0, 8, enc); + if (num < 0) return ONIGERR_TOO_BIG_WIDE_CHAR_VALUE; + if (!PEND) { + c2 = PPEEK; + if (ONIGENC_IS_CODE_XDIGIT(enc, c2)) + return ONIGERR_TOO_LONG_WIDE_CHAR_VALUE; + } - if (p > prev + enclen(enc, prev, end) && !PEND && (PPEEK_IS('}'))) { - PINC; - tok->type = TK_CODE_POINT; - tok->base = 16; - tok->u.code = (OnigCodePoint )num; - } - else { - /* can't read nothing or invalid format */ - p = prev; - } + if (p > prev + enclen(enc, prev, end) && !PEND && (PPEEK_IS('}'))) { + PINC; + tok->type = TK_CODE_POINT; + tok->base = 16; + tok->u.code = (OnigCodePoint )num; + } + else { + /* can't read nothing or invalid format */ + p = prev; + } } else if (IS_SYNTAX_OP(syn, ONIG_SYN_OP_ESC_X_HEX2)) { - num = scan_unsigned_hexadecimal_number(&p, end, 0, 2, enc); - if (num < 0) return ONIGERR_TOO_BIG_NUMBER; - if (p == prev) { /* can't read nothing. */ - num = 0; /* but, it's not error */ - } - tok->type = TK_RAW_BYTE; - tok->base = 16; - tok->u.c = num; + num = scan_unsigned_hexadecimal_number(&p, end, 0, 2, enc); + if (num < 0) return ONIGERR_TOO_BIG_NUMBER; + if (p == prev) { /* can't read nothing. */ + num = 0; /* but, it's not error */ + } + tok->type = TK_RAW_BYTE; + tok->base = 16; + tok->u.c = num; } break; @@ -3258,15 +3258,15 @@ prev = p; if (IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_U_HEX4)) { - num = scan_unsigned_hexadecimal_number(&p, end, 4, 4, enc); - if (num < -1) return ONIGERR_TOO_SHORT_DIGITS; - else if (num < 0) return ONIGERR_TOO_BIG_NUMBER; - if (p == prev) { /* can't read nothing. */ - num = 0; /* but, it's not error */ - } - tok->type = TK_CODE_POINT; - tok->base = 16; - tok->u.code = (OnigCodePoint )num; + num = scan_unsigned_hexadecimal_number(&p, end, 4, 4, enc); + if (num < -1) return ONIGERR_TOO_SHORT_DIGITS; + else if (num < 0) return ONIGERR_TOO_BIG_NUMBER; + if (p == prev) { /* can't read nothing. */ + num = 0; /* but, it's not error */ + } + tok->type = TK_CODE_POINT; + tok->base = 16; + tok->u.code = (OnigCodePoint )num; } break; @@ -3275,41 +3275,41 @@ prev = p; if (PPEEK_IS('{') && IS_SYNTAX_OP(syn, ONIG_SYN_OP_ESC_O_BRACE_OCTAL)) { - PINC; - num = scan_unsigned_octal_number(&p, end, 11, enc); - if (num < 0) return ONIGERR_TOO_BIG_WIDE_CHAR_VALUE; - if (!PEND) { - c2 = PPEEK; - if (ONIGENC_IS_CODE_DIGIT(enc, c2) && c2 < '8') - return ONIGERR_TOO_LONG_WIDE_CHAR_VALUE; - } + PINC; + num = scan_unsigned_octal_number(&p, end, 11, enc); + if (num < 0) return ONIGERR_TOO_BIG_WIDE_CHAR_VALUE; + if (!PEND) { + c2 = PPEEK; + if (ONIGENC_IS_CODE_DIGIT(enc, c2) && c2 < '8') + return ONIGERR_TOO_LONG_WIDE_CHAR_VALUE; + } - if (p > prev + enclen(enc, prev, end) && !PEND && (PPEEK_IS('}'))) { - PINC; - tok->type = TK_CODE_POINT; - tok->base = 8; - tok->u.code = (OnigCodePoint )num; - } - else { - /* can't read nothing or invalid format */ - p = prev; - } + if (p > prev + enclen(enc, prev, end) && !PEND && (PPEEK_IS('}'))) { + PINC; + tok->type = TK_CODE_POINT; + tok->base = 8; + tok->u.code = (OnigCodePoint )num; + } + else { + /* can't read nothing or invalid format */ + p = prev; + } } break; case '0': case '1': case '2': case '3': case '4': case '5': case '6': case '7': if (IS_SYNTAX_OP(syn, ONIG_SYN_OP_ESC_OCTAL3)) { - PUNFETCH; - prev = p; - num = scan_unsigned_octal_number(&p, end, 3, enc); - if (num < 0 || 0xff < num) return ONIGERR_TOO_BIG_NUMBER; - if (p == prev) { /* can't read nothing. */ - num = 0; /* but, it's not error */ - } - tok->type = TK_RAW_BYTE; - tok->base = 8; - tok->u.c = num; + PUNFETCH; + prev = p; + num = scan_unsigned_octal_number(&p, end, 3, enc); + if (num < 0 || 0xff < num) return ONIGERR_TOO_BIG_NUMBER; + if (p == prev) { /* can't read nothing. */ + num = 0; /* but, it's not error */ + } + tok->type = TK_RAW_BYTE; + tok->base = 8; + tok->u.c = num; } break; @@ -3318,8 +3318,8 @@ num = fetch_escaped_value(&p, end, env, &c2); if (num < 0) return num; if ((OnigCodePoint )tok->u.c != c2) { - tok->u.code = (OnigCodePoint )c2; - tok->type = TK_CODE_POINT; + tok->u.code = (OnigCodePoint )c2; + tok->type = TK_CODE_POINT; } break; } @@ -3331,26 +3331,26 @@ PINC; if (str_exist_check_with_esc(send, 2, p, end, (OnigCodePoint )']', enc, syn)) { - tok->type = TK_POSIX_BRACKET_OPEN; + tok->type = TK_POSIX_BRACKET_OPEN; } else { - PUNFETCH; - goto cc_in_cc; + PUNFETCH; + goto cc_in_cc; } } else { cc_in_cc: if (IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_CCLASS_SET_OP)) { - tok->type = TK_CC_CC_OPEN; + tok->type = TK_CC_CC_OPEN; } else { - CC_ESC_WARN(env, (UChar* )"["); + CC_ESC_WARN(env, (UChar* )"["); } } } else if (c == '&') { if (IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_CCLASS_SET_OP) && - !PEND && (PPEEK_IS('&'))) { + !PEND && (PPEEK_IS('&'))) { PINC; tok->type = TK_CC_AND; } @@ -3364,7 +3364,7 @@ #ifdef USE_NAMED_GROUP static int fetch_named_backref_token(OnigCodePoint c, OnigToken* tok, UChar** src, - UChar* end, ScanEnv* env) + UChar* end, ScanEnv* env) { int r, num; const OnigSyntaxType* syn = env->syntax; @@ -3379,7 +3379,7 @@ # ifdef USE_BACKREF_WITH_LEVEL name_end = NULL_UCHARP; /* no need. escape gcc warning. */ r = fetch_name_with_level(c, &p, end, &name_end, - env, &back_num, &tok->u.backref.level); + env, &back_num, &tok->u.backref.level); if (r == 1) tok->u.backref.exist_level = 1; else tok->u.backref.exist_level = 0; # else @@ -3391,13 +3391,13 @@ if (back_num < 0) { back_num = BACKREF_REL_TO_ABS(back_num, env); if (back_num <= 0) - return ONIGERR_INVALID_BACKREF; + return ONIGERR_INVALID_BACKREF; } if (IS_SYNTAX_BV(syn, ONIG_SYN_STRICT_CHECK_BACKREF)) { if (back_num > env->num_mem || - IS_NULL(SCANENV_MEM_NODES(env)[back_num])) - return ONIGERR_INVALID_BACKREF; + IS_NULL(SCANENV_MEM_NODES(env)[back_num])) + return ONIGERR_INVALID_BACKREF; } tok->type = TK_BACKREF; tok->u.backref.by_name = 0; @@ -3408,15 +3408,15 @@ num = onig_name_to_group_numbers(env->reg, prev, name_end, &backs); if (num <= 0) { onig_scan_env_set_error_string(env, - ONIGERR_UNDEFINED_NAME_REFERENCE, prev, name_end); + ONIGERR_UNDEFINED_NAME_REFERENCE, prev, name_end); return ONIGERR_UNDEFINED_NAME_REFERENCE; } if (IS_SYNTAX_BV(syn, ONIG_SYN_STRICT_CHECK_BACKREF)) { int i; for (i = 0; i < num; i++) { - if (backs[i] > env->num_mem || - IS_NULL(SCANENV_MEM_NODES(env)[backs[i]])) - return ONIGERR_INVALID_BACKREF; + if (backs[i] > env->num_mem || + IS_NULL(SCANENV_MEM_NODES(env)[backs[i]])) + return ONIGERR_INVALID_BACKREF; } } @@ -3490,26 +3490,26 @@ tok->u.repeat.upper = 1; greedy_check: if (!PEND && PPEEK_IS('?') && - IS_SYNTAX_OP(syn, ONIG_SYN_OP_QMARK_NON_GREEDY)) { - PFETCH(c); - tok->u.repeat.greedy = 0; - tok->u.repeat.possessive = 0; + IS_SYNTAX_OP(syn, ONIG_SYN_OP_QMARK_NON_GREEDY)) { + PFETCH(c); + tok->u.repeat.greedy = 0; + tok->u.repeat.possessive = 0; } else { possessive_check: - if (!PEND && PPEEK_IS('+') && - ((IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_PLUS_POSSESSIVE_REPEAT) && - tok->type != TK_INTERVAL) || - (IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_PLUS_POSSESSIVE_INTERVAL) && - tok->type == TK_INTERVAL))) { - PFETCH(c); - tok->u.repeat.greedy = 1; - tok->u.repeat.possessive = 1; - } - else { - tok->u.repeat.greedy = 1; - tok->u.repeat.possessive = 0; - } + if (!PEND && PPEEK_IS('+') && + ((IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_PLUS_POSSESSIVE_REPEAT) && + tok->type != TK_INTERVAL) || + (IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_PLUS_POSSESSIVE_INTERVAL) && + tok->type == TK_INTERVAL))) { + PFETCH(c); + tok->u.repeat.greedy = 1; + tok->u.repeat.possessive = 1; + } + else { + tok->u.repeat.greedy = 1; + tok->u.repeat.possessive = 0; + } } break; @@ -3519,10 +3519,10 @@ if (r < 0) return r; /* error */ if (r == 0) goto greedy_check; else if (r == 2) { /* {n} */ - if (IS_SYNTAX_BV(syn, ONIG_SYN_FIXED_INTERVAL_IS_GREEDY_ONLY)) - goto possessive_check; + if (IS_SYNTAX_BV(syn, ONIG_SYN_FIXED_INTERVAL_IS_GREEDY_ONLY)) + goto possessive_check; - goto greedy_check; + goto greedy_check; } /* r == 1 : normal char */ break; @@ -3561,7 +3561,7 @@ tok->type = TK_ANCHOR; tok->u.anchor.subtype = ANCHOR_WORD_BOUND; tok->u.anchor.ascii_range = IS_ASCII_RANGE(env->option) - && ! IS_WORD_BOUND_ALL_RANGE(env->option); + && ! IS_WORD_BOUND_ALL_RANGE(env->option); break; case 'B': @@ -3569,7 +3569,7 @@ tok->type = TK_ANCHOR; tok->u.anchor.subtype = ANCHOR_NOT_WORD_BOUND; tok->u.anchor.ascii_range = IS_ASCII_RANGE(env->option) - && ! IS_WORD_BOUND_ALL_RANGE(env->option); + && ! IS_WORD_BOUND_ALL_RANGE(env->option); break; #ifdef USE_WORD_BEGIN_END @@ -3671,33 +3671,33 @@ prev = p; if (PPEEK_IS('{') && IS_SYNTAX_OP(syn, ONIG_SYN_OP_ESC_X_BRACE_HEX8)) { - PINC; - num = scan_unsigned_hexadecimal_number(&p, end, 0, 8, enc); - if (num < 0) return ONIGERR_TOO_BIG_WIDE_CHAR_VALUE; - if (!PEND) { - if (ONIGENC_IS_CODE_XDIGIT(enc, PPEEK)) - return ONIGERR_TOO_LONG_WIDE_CHAR_VALUE; - } + PINC; + num = scan_unsigned_hexadecimal_number(&p, end, 0, 8, enc); + if (num < 0) return ONIGERR_TOO_BIG_WIDE_CHAR_VALUE; + if (!PEND) { + if (ONIGENC_IS_CODE_XDIGIT(enc, PPEEK)) + return ONIGERR_TOO_LONG_WIDE_CHAR_VALUE; + } - if ((p > prev + enclen(enc, prev, end)) && !PEND && PPEEK_IS('}')) { - PINC; - tok->type = TK_CODE_POINT; - tok->u.code = (OnigCodePoint )num; - } - else { - /* can't read nothing or invalid format */ - p = prev; - } + if ((p > prev + enclen(enc, prev, end)) && !PEND && PPEEK_IS('}')) { + PINC; + tok->type = TK_CODE_POINT; + tok->u.code = (OnigCodePoint )num; + } + else { + /* can't read nothing or invalid format */ + p = prev; + } } else if (IS_SYNTAX_OP(syn, ONIG_SYN_OP_ESC_X_HEX2)) { - num = scan_unsigned_hexadecimal_number(&p, end, 0, 2, enc); - if (num < 0) return ONIGERR_TOO_BIG_NUMBER; - if (p == prev) { /* can't read nothing. */ - num = 0; /* but, it's not error */ - } - tok->type = TK_RAW_BYTE; - tok->base = 16; - tok->u.c = num; + num = scan_unsigned_hexadecimal_number(&p, end, 0, 2, enc); + if (num < 0) return ONIGERR_TOO_BIG_NUMBER; + if (p == prev) { /* can't read nothing. */ + num = 0; /* but, it's not error */ + } + tok->type = TK_RAW_BYTE; + tok->base = 16; + tok->u.c = num; } break; @@ -3706,15 +3706,15 @@ prev = p; if (IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_U_HEX4)) { - num = scan_unsigned_hexadecimal_number(&p, end, 4, 4, enc); - if (num < -1) return ONIGERR_TOO_SHORT_DIGITS; - else if (num < 0) return ONIGERR_TOO_BIG_NUMBER; - if (p == prev) { /* can't read nothing. */ - num = 0; /* but, it's not error */ - } - tok->type = TK_CODE_POINT; - tok->base = 16; - tok->u.code = (OnigCodePoint )num; + num = scan_unsigned_hexadecimal_number(&p, end, 4, 4, enc); + if (num < -1) return ONIGERR_TOO_SHORT_DIGITS; + else if (num < 0) return ONIGERR_TOO_BIG_NUMBER; + if (p == prev) { /* can't read nothing. */ + num = 0; /* but, it's not error */ + } + tok->type = TK_CODE_POINT; + tok->base = 16; + tok->u.code = (OnigCodePoint )num; } break; @@ -3723,24 +3723,24 @@ prev = p; if (PPEEK_IS('{') && IS_SYNTAX_OP(syn, ONIG_SYN_OP_ESC_O_BRACE_OCTAL)) { - PINC; - num = scan_unsigned_octal_number(&p, end, 11, enc); - if (num < 0) return ONIGERR_TOO_BIG_WIDE_CHAR_VALUE; - if (!PEND) { - OnigCodePoint c = PPEEK; - if (ONIGENC_IS_CODE_DIGIT(enc, c) && c < '8') - return ONIGERR_TOO_LONG_WIDE_CHAR_VALUE; - } + PINC; + num = scan_unsigned_octal_number(&p, end, 11, enc); + if (num < 0) return ONIGERR_TOO_BIG_WIDE_CHAR_VALUE; + if (!PEND) { + OnigCodePoint c = PPEEK; + if (ONIGENC_IS_CODE_DIGIT(enc, c) && c < '8') + return ONIGERR_TOO_LONG_WIDE_CHAR_VALUE; + } - if ((p > prev + enclen(enc, prev, end)) && !PEND && PPEEK_IS('}')) { - PINC; - tok->type = TK_CODE_POINT; - tok->u.code = (OnigCodePoint )num; - } - else { - /* can't read nothing or invalid format */ - p = prev; - } + if ((p > prev + enclen(enc, prev, end)) && !PEND && PPEEK_IS('}')) { + PINC; + tok->type = TK_CODE_POINT; + tok->u.code = (OnigCodePoint )num; + } + else { + /* can't read nothing or invalid format */ + p = prev; + } } break; @@ -3750,64 +3750,64 @@ prev = p; num = onig_scan_unsigned_number(&p, end, enc); if (num < 0 || num > ONIG_MAX_BACKREF_NUM) { - goto skip_backref; + goto skip_backref; } if (IS_SYNTAX_OP(syn, ONIG_SYN_OP_DECIMAL_BACKREF) && - (num <= env->num_mem || num <= 9)) { /* This spec. from GNU regex */ - if (IS_SYNTAX_BV(syn, ONIG_SYN_STRICT_CHECK_BACKREF)) { - if (num > env->num_mem || IS_NULL(SCANENV_MEM_NODES(env)[num])) - return ONIGERR_INVALID_BACKREF; - } + (num <= env->num_mem || num <= 9)) { /* This spec. from GNU regex */ + if (IS_SYNTAX_BV(syn, ONIG_SYN_STRICT_CHECK_BACKREF)) { + if (num > env->num_mem || IS_NULL(SCANENV_MEM_NODES(env)[num])) + return ONIGERR_INVALID_BACKREF; + } - tok->type = TK_BACKREF; - tok->u.backref.num = 1; - tok->u.backref.ref1 = num; - tok->u.backref.by_name = 0; + tok->type = TK_BACKREF; + tok->u.backref.num = 1; + tok->u.backref.ref1 = num; + tok->u.backref.by_name = 0; #ifdef USE_BACKREF_WITH_LEVEL - tok->u.backref.exist_level = 0; + tok->u.backref.exist_level = 0; #endif - break; + break; } skip_backref: if (c == '8' || c == '9') { - /* normal char */ - p = prev; PINC; - break; + /* normal char */ + p = prev; PINC; + break; } p = prev; /* fall through */ case '0': if (IS_SYNTAX_OP(syn, ONIG_SYN_OP_ESC_OCTAL3)) { - prev = p; - num = scan_unsigned_octal_number(&p, end, (c == '0' ? 2:3), enc); - if (num < 0 || 0xff < num) return ONIGERR_TOO_BIG_NUMBER; - if (p == prev) { /* can't read nothing. */ - num = 0; /* but, it's not error */ - } - tok->type = TK_RAW_BYTE; - tok->base = 8; - tok->u.c = num; + prev = p; + num = scan_unsigned_octal_number(&p, end, (c == '0' ? 2:3), enc); + if (num < 0 || 0xff < num) return ONIGERR_TOO_BIG_NUMBER; + if (p == prev) { /* can't read nothing. */ + num = 0; /* but, it's not error */ + } + tok->type = TK_RAW_BYTE; + tok->base = 8; + tok->u.c = num; } else if (c != '0') { - PINC; + PINC; } break; #ifdef USE_NAMED_GROUP case 'k': if (!PEND && IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_K_NAMED_BACKREF)) { - PFETCH(c); - if (c == '<' || c == '\'') { - r = fetch_named_backref_token(c, tok, &p, end, env); - if (r < 0) return r; - } - else { - PUNFETCH; - onig_syntax_warn(env, "invalid back reference"); - } + PFETCH(c); + if (c == '<' || c == '\'') { + r = fetch_named_backref_token(c, tok, &p, end, env); + if (r < 0) return r; + } + else { + PUNFETCH; + onig_syntax_warn(env, "invalid back reference"); + } } break; #endif @@ -3816,52 +3816,52 @@ case 'g': # ifdef USE_NAMED_GROUP if (!PEND && IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_G_BRACE_BACKREF)) { - PFETCH(c); - if (c == '{') { - r = fetch_named_backref_token(c, tok, &p, end, env); - if (r < 0) return r; - } - else - PUNFETCH; + PFETCH(c); + if (c == '{') { + r = fetch_named_backref_token(c, tok, &p, end, env); + if (r < 0) return r; + } + else + PUNFETCH; } # endif # ifdef USE_SUBEXP_CALL if (!PEND && IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_G_SUBEXP_CALL)) { - PFETCH(c); - if (c == '<' || c == '\'') { - int gnum = -1, rel = 0; - UChar* name_end; - OnigCodePoint cnext; - - cnext = PPEEK; - if (cnext == '0') { - PINC; - if (PPEEK_IS(get_name_end_code_point(c))) { /* \g<0>, \g'0' */ - PINC; - name_end = p; - gnum = 0; - } - } - else if (cnext == '+') { - PINC; - rel = 1; - } - prev = p; - if (gnum < 0) { - r = fetch_name((OnigCodePoint )c, &p, end, &name_end, env, &gnum, 1); - if (r < 0) return r; - } + PFETCH(c); + if (c == '<' || c == '\'') { + int gnum = -1, rel = 0; + UChar* name_end; + OnigCodePoint cnext; + + cnext = PPEEK; + if (cnext == '0') { + PINC; + if (PPEEK_IS(get_name_end_code_point(c))) { /* \g<0>, \g'0' */ + PINC; + name_end = p; + gnum = 0; + } + } + else if (cnext == '+') { + PINC; + rel = 1; + } + prev = p; + if (gnum < 0) { + r = fetch_name((OnigCodePoint )c, &p, end, &name_end, env, &gnum, 1); + if (r < 0) return r; + } - tok->type = TK_CALL; - tok->u.call.name = prev; - tok->u.call.name_end = name_end; - tok->u.call.gnum = gnum; - tok->u.call.rel = rel; - } - else { - onig_syntax_warn(env, "invalid subexp call"); - PUNFETCH; - } + tok->type = TK_CALL; + tok->u.call.name = prev; + tok->u.call.name_end = name_end; + tok->u.call.gnum = gnum; + tok->u.call.rel = rel; + } + else { + onig_syntax_warn(env, "invalid subexp call"); + PUNFETCH; + } } # endif break; @@ -3869,65 +3869,65 @@ case 'Q': if (IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_CAPITAL_Q_QUOTE)) { - tok->type = TK_QUOTE_OPEN; + tok->type = TK_QUOTE_OPEN; } break; case 'p': case 'P': if (PPEEK_IS('{') && - IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_P_BRACE_CHAR_PROPERTY)) { - PINC; - tok->type = TK_CHAR_PROPERTY; - tok->u.prop.not = (c == 'P' ? 1 : 0); - - if (!PEND && IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_P_BRACE_CIRCUMFLEX_NOT)) { - PFETCH(c); - if (c == '^') { - tok->u.prop.not = (tok->u.prop.not == 0 ? 1 : 0); - } - else - PUNFETCH; - } + IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_P_BRACE_CHAR_PROPERTY)) { + PINC; + tok->type = TK_CHAR_PROPERTY; + tok->u.prop.not = (c == 'P' ? 1 : 0); + + if (!PEND && IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_P_BRACE_CIRCUMFLEX_NOT)) { + PFETCH(c); + if (c == '^') { + tok->u.prop.not = (tok->u.prop.not == 0 ? 1 : 0); + } + else + PUNFETCH; + } } else { - onig_syntax_warn(env, "invalid Unicode Property \\%c", c); + onig_syntax_warn(env, "invalid Unicode Property \\%c", c); } break; case 'R': if (IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_CAPITAL_R_LINEBREAK)) { - tok->type = TK_LINEBREAK; + tok->type = TK_LINEBREAK; } break; case 'X': if (IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_CAPITAL_X_EXTENDED_GRAPHEME_CLUSTER)) { - tok->type = TK_EXTENDED_GRAPHEME_CLUSTER; + tok->type = TK_EXTENDED_GRAPHEME_CLUSTER; } break; case 'K': if (IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_ESC_CAPITAL_K_KEEP)) { - tok->type = TK_KEEP; + tok->type = TK_KEEP; } break; default: { - OnigCodePoint c2; + OnigCodePoint c2; - PUNFETCH; - num = fetch_escaped_value(&p, end, env, &c2); - if (num < 0) return num; - /* set_raw: */ - if ((OnigCodePoint )tok->u.c != c2) { - tok->type = TK_CODE_POINT; - tok->u.code = (OnigCodePoint )c2; - } - else { /* string */ - p = tok->backp + enclen(enc, tok->backp, end); - } + PUNFETCH; + num = fetch_escaped_value(&p, end, env, &c2); + if (num < 0) return num; + /* set_raw: */ + if ((OnigCodePoint )tok->u.c != c2) { + tok->type = TK_CODE_POINT; + tok->u.code = (OnigCodePoint )c2; + } + else { /* string */ + p = tok->backp + enclen(enc, tok->backp, end); + } } break; } @@ -3938,18 +3938,18 @@ #ifdef USE_VARIABLE_META_CHARS if ((c != ONIG_INEFFECTIVE_META_CHAR) && - IS_SYNTAX_OP(syn, ONIG_SYN_OP_VARIABLE_META_CHARACTERS)) { + IS_SYNTAX_OP(syn, ONIG_SYN_OP_VARIABLE_META_CHARACTERS)) { if (c == MC_ANYCHAR(syn)) - goto any_char; + goto any_char; else if (c == MC_ANYTIME(syn)) - goto anytime; + goto anytime; else if (c == MC_ZERO_OR_ONE_TIME(syn)) - goto zero_or_one_time; + goto zero_or_one_time; else if (c == MC_ONE_OR_MORE_TIME(syn)) - goto one_or_more_time; + goto one_or_more_time; else if (c == MC_ANYCHAR_ANYTIME(syn)) { - tok->type = TK_ANYCHAR_ANYTIME; - goto out; + tok->type = TK_ANYCHAR_ANYTIME; + goto out; } } #endif @@ -4002,10 +4002,10 @@ if (r < 0) return r; /* error */ if (r == 0) goto greedy_check; else if (r == 2) { /* {n} */ - if (IS_SYNTAX_BV(syn, ONIG_SYN_FIXED_INTERVAL_IS_GREEDY_ONLY)) - goto possessive_check; + if (IS_SYNTAX_BV(syn, ONIG_SYN_FIXED_INTERVAL_IS_GREEDY_ONLY)) + goto possessive_check; - goto greedy_check; + goto greedy_check; } /* r == 1 : normal char */ break; @@ -4017,114 +4017,114 @@ case '(': if (PPEEK_IS('?') && - IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_QMARK_GROUP_EFFECT)) { - PINC; - if (PPEEK_IS('#')) { - PFETCH(c); - while (1) { - if (PEND) return ONIGERR_END_PATTERN_IN_GROUP; - PFETCH(c); - if (c == MC_ESC(syn)) { - if (!PEND) PFETCH(c); - } - else { - if (c == ')') break; - } - } - goto start; - } + IS_SYNTAX_OP2(syn, ONIG_SYN_OP2_QMARK_GROUP_EFFECT)) { + PINC; + if (PPEEK_IS('#')) { + PFETCH(c); + while (1) { + if (PEND) return ONIGERR_END_PATTERN_IN_GROUP; + PFETCH(c); + if (c == MC_ESC(syn)) { + if (!PEND) PFETCH(c); + } + else { + if (c == ')') break; + } + } + goto start; + } #ifdef USE_PERL_SUBEXP_CALL - /* (?&name), (?n), (?R), (?0), (?+n), (?-n) */ - c = PPEEK; - if ((c == '&' || c == 'R' || ONIGENC_IS_CODE_DIGIT(enc, c)) && - IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_SUBEXP_CALL)) { - /* (?&name), (?n), (?R), (?0) */ - int gnum; - UChar *name; - UChar *name_end; - - if (c == 'R' || c == '0') { - PINC; /* skip 'R' / '0' */ - if (!PPEEK_IS(')')) return ONIGERR_INVALID_GROUP_NAME; - PINC; /* skip ')' */ - name_end = name = p; - gnum = 0; - } - else { - int numref = 1; - if (c == '&') { /* (?&name) */ - PINC; - numref = 0; /* don't allow number name */ - } - name = p; - r = fetch_name((OnigCodePoint )'(', &p, end, &name_end, env, &gnum, numref); - if (r < 0) return r; - } + /* (?&name), (?n), (?R), (?0), (?+n), (?-n) */ + c = PPEEK; + if ((c == '&' || c == 'R' || ONIGENC_IS_CODE_DIGIT(enc, c)) && + IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_SUBEXP_CALL)) { + /* (?&name), (?n), (?R), (?0) */ + int gnum; + UChar *name; + UChar *name_end; + + if (c == 'R' || c == '0') { + PINC; /* skip 'R' / '0' */ + if (!PPEEK_IS(')')) return ONIGERR_INVALID_GROUP_NAME; + PINC; /* skip ')' */ + name_end = name = p; + gnum = 0; + } + else { + int numref = 1; + if (c == '&') { /* (?&name) */ + PINC; + numref = 0; /* don't allow number name */ + } + name = p; + r = fetch_name((OnigCodePoint )'(', &p, end, &name_end, env, &gnum, numref); + if (r < 0) return r; + } - tok->type = TK_CALL; - tok->u.call.name = name; - tok->u.call.name_end = name_end; - tok->u.call.gnum = gnum; - tok->u.call.rel = 0; - break; - } - else if ((c == '-' || c == '+') && - IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_SUBEXP_CALL)) { - /* (?+n), (?-n) */ - int gnum; - UChar *name; - UChar *name_end; - OnigCodePoint cnext; - PFETCH_READY; - - PINC; /* skip '-' / '+' */ - cnext = PPEEK; - if (ONIGENC_IS_CODE_DIGIT(enc, cnext)) { - if (c == '-') PUNFETCH; - name = p; - r = fetch_name((OnigCodePoint )'(', &p, end, &name_end, env, &gnum, 1); - if (r < 0) return r; - - tok->type = TK_CALL; - tok->u.call.name = name; - tok->u.call.name_end = name_end; - tok->u.call.gnum = gnum; - tok->u.call.rel = 1; - break; - } - } + tok->type = TK_CALL; + tok->u.call.name = name; + tok->u.call.name_end = name_end; + tok->u.call.gnum = gnum; + tok->u.call.rel = 0; + break; + } + else if ((c == '-' || c == '+') && + IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_SUBEXP_CALL)) { + /* (?+n), (?-n) */ + int gnum; + UChar *name; + UChar *name_end; + OnigCodePoint cnext; + PFETCH_READY; + + PINC; /* skip '-' / '+' */ + cnext = PPEEK; + if (ONIGENC_IS_CODE_DIGIT(enc, cnext)) { + if (c == '-') PUNFETCH; + name = p; + r = fetch_name((OnigCodePoint )'(', &p, end, &name_end, env, &gnum, 1); + if (r < 0) return r; + + tok->type = TK_CALL; + tok->u.call.name = name; + tok->u.call.name_end = name_end; + tok->u.call.gnum = gnum; + tok->u.call.rel = 1; + break; + } + } #endif /* USE_PERL_SUBEXP_CALL */ #ifdef USE_CAPITAL_P_NAMED_GROUP - if (PPEEK_IS('P') && - IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_CAPITAL_P_NAMED_GROUP)) { - int gnum; - UChar *name; - UChar *name_end; - PFETCH_READY; - - PINC; /* skip 'P' */ - if (PEND) return ONIGERR_UNDEFINED_GROUP_OPTION; - PFETCH(c); - if (c == '=') { /* (?P=name): backref */ - r = fetch_named_backref_token((OnigCodePoint )'(', tok, &p, end, env); - if (r < 0) return r; - break; - } - else if (c == '>') { /* (?P>name): subexp call */ - name = p; - r = fetch_name((OnigCodePoint )'(', &p, end, &name_end, env, &gnum, 0); - if (r < 0) return r; - - tok->type = TK_CALL; - tok->u.call.name = name; - tok->u.call.name_end = name_end; - tok->u.call.gnum = gnum; - tok->u.call.rel = 0; - break; - } - } + if (PPEEK_IS('P') && + IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_CAPITAL_P_NAMED_GROUP)) { + int gnum; + UChar *name; + UChar *name_end; + PFETCH_READY; + + PINC; /* skip 'P' */ + if (PEND) return ONIGERR_UNDEFINED_GROUP_OPTION; + PFETCH(c); + if (c == '=') { /* (?P=name): backref */ + r = fetch_named_backref_token((OnigCodePoint )'(', tok, &p, end, env); + if (r < 0) return r; + break; + } + else if (c == '>') { /* (?P>name): subexp call */ + name = p; + r = fetch_name((OnigCodePoint )'(', &p, end, &name_end, env, &gnum, 0); + if (r < 0) return r; + + tok->type = TK_CALL; + tok->u.call.name = name; + tok->u.call.name_end = name_end; + tok->u.call.gnum = gnum; + tok->u.call.rel = 0; + break; + } + } #endif /* USE_CAPITAL_P_NAMED_GROUP */ - PUNFETCH; + PUNFETCH; } if (! IS_SYNTAX_OP(syn, ONIG_SYN_OP_LPAREN_SUBEXP)) break; @@ -4140,14 +4140,14 @@ if (! IS_SYNTAX_OP(syn, ONIG_SYN_OP_LINE_ANCHOR)) break; tok->type = TK_ANCHOR; tok->u.anchor.subtype = (IS_SINGLELINE(env->option) - ? ANCHOR_BEGIN_BUF : ANCHOR_BEGIN_LINE); + ? ANCHOR_BEGIN_BUF : ANCHOR_BEGIN_LINE); break; case '$': if (! IS_SYNTAX_OP(syn, ONIG_SYN_OP_LINE_ANCHOR)) break; tok->type = TK_ANCHOR; tok->u.anchor.subtype = (IS_SINGLELINE(env->option) - ? ANCHOR_SEMI_END_BUF : ANCHOR_END_LINE); + ? ANCHOR_SEMI_END_BUF : ANCHOR_END_LINE); break; case '[': @@ -4157,24 +4157,24 @@ case ']': if (*src > env->pattern) /* /].../ is allowed. */ - CLOSE_BRACKET_WITHOUT_ESC_WARN(env, (UChar* )"]"); + CLOSE_BRACKET_WITHOUT_ESC_WARN(env, (UChar* )"]"); break; case '#': if (IS_EXTEND(env->option)) { - while (!PEND) { - PFETCH(c); - if (ONIGENC_IS_CODE_NEWLINE(enc, c)) - break; - } - goto start; - break; + while (!PEND) { + PFETCH(c); + if (ONIGENC_IS_CODE_NEWLINE(enc, c)) + break; + } + goto start; + break; } break; case ' ': case '\t': case '\n': case '\r': case '\f': if (IS_EXTEND(env->option)) - goto start; + goto start; break; default: @@ -4203,18 +4203,18 @@ if (not == 0) { for (i = 0; i < n; i++) { for (j = ONIGENC_CODE_RANGE_FROM(mbr, i); - j <= ONIGENC_CODE_RANGE_TO(mbr, i); j++) { - if (j >= sb_out) { - if (j > ONIGENC_CODE_RANGE_FROM(mbr, i)) { - r = add_code_range_to_buf(&(cc->mbuf), env, j, - ONIGENC_CODE_RANGE_TO(mbr, i)); - if (r != 0) return r; - i++; - } + j <= ONIGENC_CODE_RANGE_TO(mbr, i); j++) { + if (j >= sb_out) { + if (j > ONIGENC_CODE_RANGE_FROM(mbr, i)) { + r = add_code_range_to_buf(&(cc->mbuf), env, j, + ONIGENC_CODE_RANGE_TO(mbr, i)); + if (r != 0) return r; + i++; + } - goto sb_end; - } - BITSET_SET_BIT_CHKDUP(cc->bs, j); + goto sb_end; + } + BITSET_SET_BIT_CHKDUP(cc->bs, j); } } @@ -4231,11 +4231,11 @@ for (i = 0; i < n; i++) { for (j = prev; - j < ONIGENC_CODE_RANGE_FROM(mbr, i); j++) { - if (j >= sb_out) { - goto sb_end2; - } - BITSET_SET_BIT_CHKDUP(cc->bs, j); + j < ONIGENC_CODE_RANGE_FROM(mbr, i); j++) { + if (j >= sb_out) { + goto sb_end2; + } + BITSET_SET_BIT_CHKDUP(cc->bs, j); } prev = ONIGENC_CODE_RANGE_TO(mbr, i) + 1; } @@ -4248,9 +4248,9 @@ for (i = 0; i < n; i++) { if (prev < ONIGENC_CODE_RANGE_FROM(mbr, i)) { - r = add_code_range_to_buf(&(cc->mbuf), env, prev, + r = add_code_range_to_buf(&(cc->mbuf), env, prev, ONIGENC_CODE_RANGE_FROM(mbr, i) - 1); - if (r != 0) return r; + if (r != 0) return r; } prev = ONIGENC_CODE_RANGE_TO(mbr, i) + 1; } @@ -4278,30 +4278,30 @@ CClassNode ccwork; initialize_cclass(&ccwork); r = add_ctype_to_cc_by_range(&ccwork, ctype, not, env, sb_out, - ranges); + ranges); if (r == 0) { - if (not) { - r = add_code_range_to_buf0(&(ccwork.mbuf), env, 0x80, ONIG_LAST_CODE_POINT, FALSE); - } - else { - CClassNode ccascii; - initialize_cclass(&ccascii); - if (ONIGENC_MBC_MINLEN(env->enc) > 1) { - r = add_code_range(&(ccascii.mbuf), env, 0x00, 0x7F); - } - else { - bitset_set_range(env, ccascii.bs, 0x00, 0x7F); - r = 0; - } - if (r == 0) { - r = and_cclass(&ccwork, &ccascii, env); - } - if (IS_NOT_NULL(ccascii.mbuf)) bbuf_free(ccascii.mbuf); - } - if (r == 0) { - r = or_cclass(cc, &ccwork, env); - } - if (IS_NOT_NULL(ccwork.mbuf)) bbuf_free(ccwork.mbuf); + if (not) { + r = add_code_range_to_buf0(&(ccwork.mbuf), env, 0x80, ONIG_LAST_CODE_POINT, FALSE); + } + else { + CClassNode ccascii; + initialize_cclass(&ccascii); + if (ONIGENC_MBC_MINLEN(env->enc) > 1) { + r = add_code_range(&(ccascii.mbuf), env, 0x00, 0x7F); + } + else { + bitset_set_range(env, ccascii.bs, 0x00, 0x7F); + r = 0; + } + if (r == 0) { + r = and_cclass(&ccwork, &ccascii, env); + } + if (IS_NOT_NULL(ccascii.mbuf)) bbuf_free(ccascii.mbuf); + } + if (r == 0) { + r = or_cclass(cc, &ccwork, env); + } + if (IS_NOT_NULL(ccwork.mbuf)) bbuf_free(ccwork.mbuf); } } else { @@ -4329,15 +4329,15 @@ case ONIGENC_CTYPE_ALNUM: if (not != 0) { for (c = 0; c < SINGLE_BYTE_SIZE; c++) { - if (! ONIGENC_IS_CODE_CTYPE(enc, (OnigCodePoint )c, ctype)) - BITSET_SET_BIT_CHKDUP(cc->bs, c); + if (! ONIGENC_IS_CODE_CTYPE(enc, (OnigCodePoint )c, ctype)) + BITSET_SET_BIT_CHKDUP(cc->bs, c); } ADD_ALL_MULTI_BYTE_RANGE(enc, cc->mbuf); } else { for (c = 0; c < SINGLE_BYTE_SIZE; c++) { - if (ONIGENC_IS_CODE_CTYPE(enc, (OnigCodePoint )c, ctype)) - BITSET_SET_BIT_CHKDUP(cc->bs, c); + if (ONIGENC_IS_CODE_CTYPE(enc, (OnigCodePoint )c, ctype)) + BITSET_SET_BIT_CHKDUP(cc->bs, c); } } break; @@ -4346,39 +4346,39 @@ case ONIGENC_CTYPE_PRINT: if (not != 0) { for (c = 0; c < SINGLE_BYTE_SIZE; c++) { - if (! ONIGENC_IS_CODE_CTYPE(enc, (OnigCodePoint )c, ctype) - || c >= maxcode) - BITSET_SET_BIT_CHKDUP(cc->bs, c); + if (! ONIGENC_IS_CODE_CTYPE(enc, (OnigCodePoint )c, ctype) + || c >= maxcode) + BITSET_SET_BIT_CHKDUP(cc->bs, c); } if (ascii_range) - ADD_ALL_MULTI_BYTE_RANGE(enc, cc->mbuf); + ADD_ALL_MULTI_BYTE_RANGE(enc, cc->mbuf); } else { for (c = 0; c < maxcode; c++) { - if (ONIGENC_IS_CODE_CTYPE(enc, (OnigCodePoint )c, ctype)) - BITSET_SET_BIT_CHKDUP(cc->bs, c); + if (ONIGENC_IS_CODE_CTYPE(enc, (OnigCodePoint )c, ctype)) + BITSET_SET_BIT_CHKDUP(cc->bs, c); } if (! ascii_range) - ADD_ALL_MULTI_BYTE_RANGE(enc, cc->mbuf); + ADD_ALL_MULTI_BYTE_RANGE(enc, cc->mbuf); } break; case ONIGENC_CTYPE_WORD: if (not == 0) { for (c = 0; c < maxcode; c++) { - if (ONIGENC_IS_CODE_WORD(enc, c)) BITSET_SET_BIT_CHKDUP(cc->bs, c); + if (ONIGENC_IS_CODE_WORD(enc, c)) BITSET_SET_BIT_CHKDUP(cc->bs, c); } if (! ascii_range) - ADD_ALL_MULTI_BYTE_RANGE(enc, cc->mbuf); + ADD_ALL_MULTI_BYTE_RANGE(enc, cc->mbuf); } else { for (c = 0; c < SINGLE_BYTE_SIZE; c++) { - if ((ONIGENC_CODE_TO_MBCLEN(enc, c) > 0) /* check invalid code point */ - && (! ONIGENC_IS_CODE_WORD(enc, c) || c >= maxcode)) - BITSET_SET_BIT_CHKDUP(cc->bs, c); + if ((ONIGENC_CODE_TO_MBCLEN(enc, c) > 0) /* check invalid code point */ + && (! ONIGENC_IS_CODE_WORD(enc, c) || c >= maxcode)) + BITSET_SET_BIT_CHKDUP(cc->bs, c); } if (ascii_range) - ADD_ALL_MULTI_BYTE_RANGE(enc, cc->mbuf); + ADD_ALL_MULTI_BYTE_RANGE(enc, cc->mbuf); } break; @@ -4392,7 +4392,7 @@ static int parse_posix_bracket(CClassNode* cc, CClassNode* asc_cc, - UChar** src, UChar* end, ScanEnv* env) + UChar** src, UChar* end, ScanEnv* env) { #define POSIX_BRACKET_CHECK_LIMIT_LENGTH 20 #define POSIX_BRACKET_NAME_MIN_LEN 4 @@ -4432,22 +4432,22 @@ goto not_posix_bracket; ascii_range = IS_ASCII_RANGE(env->option) && - ! IS_POSIX_BRACKET_ALL_RANGE(env->option); + ! IS_POSIX_BRACKET_ALL_RANGE(env->option); for (pb = PBS; pb < PBS + numberof(PBS); pb++) { if (onigenc_with_ascii_strncmp(enc, p, end, pb->name, pb->len) == 0) { p = (UChar* )onigenc_step(enc, p, end, pb->len); if (onigenc_with_ascii_strncmp(enc, p, end, (UChar* )":]", 2) != 0) - return ONIGERR_INVALID_POSIX_BRACKET_TYPE; + return ONIGERR_INVALID_POSIX_BRACKET_TYPE; r = add_ctype_to_cc(cc, pb->ctype, not, ascii_range, env); if (r != 0) return r; if (IS_NOT_NULL(asc_cc)) { - if (pb->ctype != ONIGENC_CTYPE_WORD && - pb->ctype != ONIGENC_CTYPE_ASCII && - !ascii_range) - r = add_ctype_to_cc(asc_cc, pb->ctype, not, ascii_range, env); - if (r != 0) return r; + if (pb->ctype != ONIGENC_CTYPE_WORD && + pb->ctype != ONIGENC_CTYPE_ASCII && + !ascii_range) + r = add_ctype_to_cc(asc_cc, pb->ctype, not, ascii_range, env); + if (r != 0) return r; } PINC_S; PINC_S; @@ -4468,7 +4468,7 @@ if (! PEND) { PFETCH_S(c); if (c == ']') - return ONIGERR_INVALID_POSIX_BRACKET_TYPE; + return ONIGERR_INVALID_POSIX_BRACKET_TYPE; } } @@ -4509,7 +4509,7 @@ static int parse_char_property(Node** np, OnigToken* tok, UChar** src, UChar* end, - ScanEnv* env) + ScanEnv* env) { int r, ctype; CClassNode* cc; @@ -4547,8 +4547,8 @@ static int next_state_class(CClassNode* cc, CClassNode* asc_cc, - OnigCodePoint* vs, enum CCVALTYPE* type, - enum CCSTATE* state, ScanEnv* env) + OnigCodePoint* vs, enum CCVALTYPE* type, + enum CCSTATE* state, ScanEnv* env) { int r; @@ -4559,14 +4559,14 @@ if (*type == CCV_SB) { BITSET_SET_BIT_CHKDUP(cc->bs, (int )(*vs)); if (IS_NOT_NULL(asc_cc)) - BITSET_SET_BIT(asc_cc->bs, (int )(*vs)); + BITSET_SET_BIT(asc_cc->bs, (int )(*vs)); } else if (*type == CCV_CODE_POINT) { r = add_code_range(&(cc->mbuf), env, *vs, *vs); if (r < 0) return r; if (IS_NOT_NULL(asc_cc)) { - r = add_code_range0(&(asc_cc->mbuf), env, *vs, *vs, 0); - if (r < 0) return r; + r = add_code_range0(&(asc_cc->mbuf), env, *vs, *vs, 0); + if (r < 0) return r; } } } @@ -4578,10 +4578,10 @@ static int next_state_val(CClassNode* cc, CClassNode* asc_cc, - OnigCodePoint *from, OnigCodePoint to, - int* from_israw, int to_israw, - enum CCVALTYPE intype, enum CCVALTYPE* type, - enum CCSTATE* state, ScanEnv* env) + OnigCodePoint *from, OnigCodePoint to, + int* from_israw, int to_israw, + enum CCVALTYPE intype, enum CCVALTYPE* type, + enum CCSTATE* state, ScanEnv* env) { int r; @@ -4590,14 +4590,14 @@ if (*type == CCV_SB) { BITSET_SET_BIT_CHKDUP(cc->bs, (int )(*from)); if (IS_NOT_NULL(asc_cc)) - BITSET_SET_BIT(asc_cc->bs, (int )(*from)); + BITSET_SET_BIT(asc_cc->bs, (int )(*from)); } else if (*type == CCV_CODE_POINT) { r = add_code_range(&(cc->mbuf), env, *from, *from); if (r < 0) return r; if (IS_NOT_NULL(asc_cc)) { - r = add_code_range0(&(asc_cc->mbuf), env, *from, *from, 0); - if (r < 0) return r; + r = add_code_range0(&(asc_cc->mbuf), env, *from, *from, 0); + if (r < 0) return r; } } break; @@ -4605,42 +4605,42 @@ case CCS_RANGE: if (intype == *type) { if (intype == CCV_SB) { - if (*from > 0xff || to > 0xff) - return ONIGERR_INVALID_CODE_POINT_VALUE; + if (*from > 0xff || to > 0xff) + return ONIGERR_INVALID_CODE_POINT_VALUE; - if (*from > to) { - if (IS_SYNTAX_BV(env->syntax, ONIG_SYN_ALLOW_EMPTY_RANGE_IN_CC)) - goto ccs_range_end; - else - return ONIGERR_EMPTY_RANGE_IN_CHAR_CLASS; - } - bitset_set_range(env, cc->bs, (int )*from, (int )to); - if (IS_NOT_NULL(asc_cc)) - bitset_set_range(env, asc_cc->bs, (int )*from, (int )to); + if (*from > to) { + if (IS_SYNTAX_BV(env->syntax, ONIG_SYN_ALLOW_EMPTY_RANGE_IN_CC)) + goto ccs_range_end; + else + return ONIGERR_EMPTY_RANGE_IN_CHAR_CLASS; + } + bitset_set_range(env, cc->bs, (int )*from, (int )to); + if (IS_NOT_NULL(asc_cc)) + bitset_set_range(env, asc_cc->bs, (int )*from, (int )to); } else { - r = add_code_range(&(cc->mbuf), env, *from, to); - if (r < 0) return r; - if (IS_NOT_NULL(asc_cc)) { - r = add_code_range0(&(asc_cc->mbuf), env, *from, to, 0); - if (r < 0) return r; - } + r = add_code_range(&(cc->mbuf), env, *from, to); + if (r < 0) return r; + if (IS_NOT_NULL(asc_cc)) { + r = add_code_range0(&(asc_cc->mbuf), env, *from, to, 0); + if (r < 0) return r; + } } } else { if (*from > to) { - if (IS_SYNTAX_BV(env->syntax, ONIG_SYN_ALLOW_EMPTY_RANGE_IN_CC)) - goto ccs_range_end; - else - return ONIGERR_EMPTY_RANGE_IN_CHAR_CLASS; + if (IS_SYNTAX_BV(env->syntax, ONIG_SYN_ALLOW_EMPTY_RANGE_IN_CC)) + goto ccs_range_end; + else + return ONIGERR_EMPTY_RANGE_IN_CHAR_CLASS; } bitset_set_range(env, cc->bs, (int )*from, (int )(to < 0xff ? to : 0xff)); r = add_code_range(&(cc->mbuf), env, (OnigCodePoint )*from, to); if (r < 0) return r; if (IS_NOT_NULL(asc_cc)) { - bitset_set_range(env, asc_cc->bs, (int )*from, (int )(to < 0xff ? to : 0xff)); - r = add_code_range0(&(asc_cc->mbuf), env, (OnigCodePoint )*from, to, 0); - if (r < 0) return r; + bitset_set_range(env, asc_cc->bs, (int )*from, (int )(to < 0xff ? to : 0xff)); + r = add_code_range0(&(asc_cc->mbuf), env, (OnigCodePoint )*from, to, 0); + if (r < 0) return r; } } ccs_range_end: @@ -4664,7 +4664,7 @@ static int code_exist_check(OnigCodePoint c, UChar* from, UChar* end, int ignore_escaped, - ScanEnv* env) + ScanEnv* env) { int in_esc; OnigCodePoint code; @@ -4687,7 +4687,7 @@ static int parse_char_class(Node** np, Node** asc_np, OnigToken* tok, UChar** src, UChar* end, - ScanEnv* env) + ScanEnv* env) { int r, neg, len, fetched, and_start; OnigCodePoint v, vs; @@ -4748,16 +4748,16 @@ switch (r) { case TK_CHAR: if ((tok->u.code >= SINGLE_BYTE_SIZE) || - (len = ONIGENC_CODE_TO_MBCLEN(env->enc, tok->u.c)) > 1) { - in_type = CCV_CODE_POINT; + (len = ONIGENC_CODE_TO_MBCLEN(env->enc, tok->u.c)) > 1) { + in_type = CCV_CODE_POINT; } else if (len < 0) { - r = len; - goto err; + r = len; + goto err; } else { sb_char: - in_type = CCV_SB; + in_type = CCV_SB; } v = (OnigCodePoint )tok->u.c; in_israw = 0; @@ -4767,54 +4767,54 @@ case TK_RAW_BYTE: /* tok->base != 0 : octal or hexadec. */ if (! ONIGENC_IS_SINGLEBYTE(env->enc) && tok->base != 0) { - UChar buf[ONIGENC_CODE_TO_MBC_MAXLEN]; - UChar* bufe = buf + ONIGENC_CODE_TO_MBC_MAXLEN; - UChar* psave = p; - int i, base = tok->base; - - buf[0] = (UChar )tok->u.c; - for (i = 1; i < ONIGENC_MBC_MAXLEN(env->enc); i++) { - r = fetch_token_in_cc(tok, &p, end, env); - if (r < 0) goto err; - if (r != TK_RAW_BYTE || tok->base != base) { - fetched = 1; - break; - } - buf[i] = (UChar )tok->u.c; - } + UChar buf[ONIGENC_CODE_TO_MBC_MAXLEN]; + UChar* bufe = buf + ONIGENC_CODE_TO_MBC_MAXLEN; + UChar* psave = p; + int i, base = tok->base; + + buf[0] = (UChar )tok->u.c; + for (i = 1; i < ONIGENC_MBC_MAXLEN(env->enc); i++) { + r = fetch_token_in_cc(tok, &p, end, env); + if (r < 0) goto err; + if (r != TK_RAW_BYTE || tok->base != base) { + fetched = 1; + break; + } + buf[i] = (UChar )tok->u.c; + } - if (i < ONIGENC_MBC_MINLEN(env->enc)) { - r = ONIGERR_TOO_SHORT_MULTI_BYTE_STRING; - goto err; - } + if (i < ONIGENC_MBC_MINLEN(env->enc)) { + r = ONIGERR_TOO_SHORT_MULTI_BYTE_STRING; + goto err; + } - len = enclen(env->enc, buf, buf + i); - if (i < len) { - r = ONIGERR_TOO_SHORT_MULTI_BYTE_STRING; - goto err; - } - else if (i > len) { /* fetch back */ - p = psave; - for (i = 1; i < len; i++) { - (void)fetch_token_in_cc(tok, &p, end, env); - /* no need to check the return value (already checked above) */ - } - fetched = 0; - } + len = enclen(env->enc, buf, buf + i); + if (i < len) { + r = ONIGERR_TOO_SHORT_MULTI_BYTE_STRING; + goto err; + } + else if (i > len) { /* fetch back */ + p = psave; + for (i = 1; i < len; i++) { + (void)fetch_token_in_cc(tok, &p, end, env); + /* no need to check the return value (already checked above) */ + } + fetched = 0; + } - if (i == 1) { - v = (OnigCodePoint )buf[0]; - goto raw_single; - } - else { - v = ONIGENC_MBC_TO_CODE(env->enc, buf, bufe); - in_type = CCV_CODE_POINT; - } + if (i == 1) { + v = (OnigCodePoint )buf[0]; + goto raw_single; + } + else { + v = ONIGENC_MBC_TO_CODE(env->enc, buf, bufe); + in_type = CCV_CODE_POINT; + } } else { - v = (OnigCodePoint )tok->u.c; + v = (OnigCodePoint )tok->u.c; raw_single: - in_type = CCV_SB; + in_type = CCV_SB; } in_israw = 1; goto val_entry2; @@ -4826,13 +4826,13 @@ val_entry: len = ONIGENC_CODE_TO_MBCLEN(env->enc, v); if (len < 0) { - r = len; - goto err; + r = len; + goto err; } in_type = (len == 1 ? CCV_SB : CCV_CODE_POINT); val_entry2: r = next_state_val(cc, asc_cc, &vs, v, &val_israw, in_israw, in_type, &val_type, - &state, env); + &state, env); if (r != 0) goto err; break; @@ -4840,24 +4840,24 @@ r = parse_posix_bracket(cc, asc_cc, &p, end, env); if (r < 0) goto err; if (r == 1) { /* is not POSIX bracket */ - CC_ESC_WARN(env, (UChar* )"["); - p = tok->backp; - v = (OnigCodePoint )tok->u.c; - in_israw = 0; - goto val_entry; + CC_ESC_WARN(env, (UChar* )"["); + p = tok->backp; + v = (OnigCodePoint )tok->u.c; + in_israw = 0; + goto val_entry; } goto next_class; break; case TK_CHAR_TYPE: r = add_ctype_to_cc(cc, tok->u.prop.ctype, tok->u.prop.not, - IS_ASCII_RANGE(env->option), env); + IS_ASCII_RANGE(env->option), env); if (r != 0) return r; if (IS_NOT_NULL(asc_cc)) { - if (tok->u.prop.ctype != ONIGENC_CTYPE_WORD) - r = add_ctype_to_cc(asc_cc, tok->u.prop.ctype, tok->u.prop.not, - IS_ASCII_RANGE(env->option), env); - if (r != 0) return r; + if (tok->u.prop.ctype != ONIGENC_CTYPE_WORD) + r = add_ctype_to_cc(asc_cc, tok->u.prop.ctype, tok->u.prop.not, + IS_ASCII_RANGE(env->option), env); + if (r != 0) return r; } next_class: @@ -4867,133 +4867,133 @@ case TK_CHAR_PROPERTY: { - int ctype; + int ctype; - ctype = fetch_char_property_to_ctype(&p, end, env); - if (ctype < 0) return ctype; - r = add_ctype_to_cc(cc, ctype, tok->u.prop.not, 0, env); - if (r != 0) return r; - if (IS_NOT_NULL(asc_cc)) { - if (ctype != ONIGENC_CTYPE_ASCII) - r = add_ctype_to_cc(asc_cc, ctype, tok->u.prop.not, 0, env); - if (r != 0) return r; - } - goto next_class; + ctype = fetch_char_property_to_ctype(&p, end, env); + if (ctype < 0) return ctype; + r = add_ctype_to_cc(cc, ctype, tok->u.prop.not, 0, env); + if (r != 0) return r; + if (IS_NOT_NULL(asc_cc)) { + if (ctype != ONIGENC_CTYPE_ASCII) + r = add_ctype_to_cc(asc_cc, ctype, tok->u.prop.not, 0, env); + if (r != 0) return r; + } + goto next_class; } break; case TK_CC_RANGE: if (state == CCS_VALUE) { - r = fetch_token_in_cc(tok, &p, end, env); - if (r < 0) goto err; - fetched = 1; - if (r == TK_CC_CLOSE) { /* allow [x-] */ - range_end_val: - v = (OnigCodePoint )'-'; - in_israw = 0; - goto val_entry; - } - else if (r == TK_CC_AND) { - CC_ESC_WARN(env, (UChar* )"-"); - goto range_end_val; - } + r = fetch_token_in_cc(tok, &p, end, env); + if (r < 0) goto err; + fetched = 1; + if (r == TK_CC_CLOSE) { /* allow [x-] */ + range_end_val: + v = (OnigCodePoint )'-'; + in_israw = 0; + goto val_entry; + } + else if (r == TK_CC_AND) { + CC_ESC_WARN(env, (UChar* )"-"); + goto range_end_val; + } - if (val_type == CCV_CLASS) { - r = ONIGERR_UNMATCHED_RANGE_SPECIFIER_IN_CHAR_CLASS; - goto err; - } + if (val_type == CCV_CLASS) { + r = ONIGERR_UNMATCHED_RANGE_SPECIFIER_IN_CHAR_CLASS; + goto err; + } - state = CCS_RANGE; + state = CCS_RANGE; } else if (state == CCS_START) { - /* [-xa] is allowed */ - v = (OnigCodePoint )tok->u.c; - in_israw = 0; - - r = fetch_token_in_cc(tok, &p, end, env); - if (r < 0) goto err; - fetched = 1; - /* [--x] or [a&&-x] is warned. */ - if (r == TK_CC_RANGE || and_start != 0) - CC_ESC_WARN(env, (UChar* )"-"); + /* [-xa] is allowed */ + v = (OnigCodePoint )tok->u.c; + in_israw = 0; + + r = fetch_token_in_cc(tok, &p, end, env); + if (r < 0) goto err; + fetched = 1; + /* [--x] or [a&&-x] is warned. */ + if (r == TK_CC_RANGE || and_start != 0) + CC_ESC_WARN(env, (UChar* )"-"); - goto val_entry; + goto val_entry; } else if (state == CCS_RANGE) { - CC_ESC_WARN(env, (UChar* )"-"); - goto sb_char; /* [!--x] is allowed */ + CC_ESC_WARN(env, (UChar* )"-"); + goto sb_char; /* [!--x] is allowed */ } else { /* CCS_COMPLETE */ - r = fetch_token_in_cc(tok, &p, end, env); - if (r < 0) goto err; - fetched = 1; - if (r == TK_CC_CLOSE) goto range_end_val; /* allow [a-b-] */ - else if (r == TK_CC_AND) { - CC_ESC_WARN(env, (UChar* )"-"); - goto range_end_val; - } + r = fetch_token_in_cc(tok, &p, end, env); + if (r < 0) goto err; + fetched = 1; + if (r == TK_CC_CLOSE) goto range_end_val; /* allow [a-b-] */ + else if (r == TK_CC_AND) { + CC_ESC_WARN(env, (UChar* )"-"); + goto range_end_val; + } - if (IS_SYNTAX_BV(env->syntax, ONIG_SYN_ALLOW_DOUBLE_RANGE_OP_IN_CC)) { - CC_ESC_WARN(env, (UChar* )"-"); - goto range_end_val; /* [0-9-a] is allowed as [0-9\-a] */ - } - r = ONIGERR_UNMATCHED_RANGE_SPECIFIER_IN_CHAR_CLASS; - goto err; + if (IS_SYNTAX_BV(env->syntax, ONIG_SYN_ALLOW_DOUBLE_RANGE_OP_IN_CC)) { + CC_ESC_WARN(env, (UChar* )"-"); + goto range_end_val; /* [0-9-a] is allowed as [0-9\-a] */ + } + r = ONIGERR_UNMATCHED_RANGE_SPECIFIER_IN_CHAR_CLASS; + goto err; } break; case TK_CC_CC_OPEN: /* [ */ { - Node *anode, *aasc_node; - CClassNode* acc; + Node *anode, *aasc_node; + CClassNode* acc; - r = parse_char_class(&anode, &aasc_node, tok, &p, end, env); - if (r == 0) { - acc = NCCLASS(anode); - r = or_cclass(cc, acc, env); - } - if (r == 0 && IS_NOT_NULL(aasc_node)) { - acc = NCCLASS(aasc_node); - r = or_cclass(asc_cc, acc, env); - } - onig_node_free(anode); - onig_node_free(aasc_node); - if (r != 0) goto err; + r = parse_char_class(&anode, &aasc_node, tok, &p, end, env); + if (r == 0) { + acc = NCCLASS(anode); + r = or_cclass(cc, acc, env); + } + if (r == 0 && IS_NOT_NULL(aasc_node)) { + acc = NCCLASS(aasc_node); + r = or_cclass(asc_cc, acc, env); + } + onig_node_free(anode); + onig_node_free(aasc_node); + if (r != 0) goto err; } break; case TK_CC_AND: /* && */ { - if (state == CCS_VALUE) { - r = next_state_val(cc, asc_cc, &vs, 0, &val_israw, 0, val_type, - &val_type, &state, env); - if (r != 0) goto err; - } - /* initialize local variables */ - and_start = 1; - state = CCS_START; - - if (IS_NOT_NULL(prev_cc)) { - r = and_cclass(prev_cc, cc, env); - if (r != 0) goto err; - bbuf_free(cc->mbuf); - if (IS_NOT_NULL(asc_cc)) { - r = and_cclass(asc_prev_cc, asc_cc, env); - if (r != 0) goto err; - bbuf_free(asc_cc->mbuf); - } - } - else { - prev_cc = cc; - cc = &work_cc; - if (IS_NOT_NULL(asc_cc)) { - asc_prev_cc = asc_cc; - asc_cc = &asc_work_cc; - } - } - initialize_cclass(cc); - if (IS_NOT_NULL(asc_cc)) - initialize_cclass(asc_cc); + if (state == CCS_VALUE) { + r = next_state_val(cc, asc_cc, &vs, 0, &val_israw, 0, val_type, + &val_type, &state, env); + if (r != 0) goto err; + } + /* initialize local variables */ + and_start = 1; + state = CCS_START; + + if (IS_NOT_NULL(prev_cc)) { + r = and_cclass(prev_cc, cc, env); + if (r != 0) goto err; + bbuf_free(cc->mbuf); + if (IS_NOT_NULL(asc_cc)) { + r = and_cclass(asc_prev_cc, asc_cc, env); + if (r != 0) goto err; + bbuf_free(asc_cc->mbuf); + } + } + else { + prev_cc = cc; + cc = &work_cc; + if (IS_NOT_NULL(asc_cc)) { + asc_prev_cc = asc_cc; + asc_cc = &asc_work_cc; + } + } + initialize_cclass(cc); + if (IS_NOT_NULL(asc_cc)) + initialize_cclass(asc_cc); } break; @@ -5017,7 +5017,7 @@ if (state == CCS_VALUE) { r = next_state_val(cc, asc_cc, &vs, 0, &val_israw, 0, val_type, - &val_type, &state, env); + &val_type, &state, env); if (r != 0) goto err; } @@ -5056,12 +5056,12 @@ #define NEWLINE_CODE 0x0a if (ONIGENC_IS_CODE_NEWLINE(env->enc, NEWLINE_CODE)) { - if (ONIGENC_CODE_TO_MBCLEN(env->enc, NEWLINE_CODE) == 1) - BITSET_SET_BIT_CHKDUP(cc->bs, NEWLINE_CODE); - else { - r = add_code_range(&(cc->mbuf), env, NEWLINE_CODE, NEWLINE_CODE); - if (r < 0) goto err; - } + if (ONIGENC_CODE_TO_MBCLEN(env->enc, NEWLINE_CODE) == 1) + BITSET_SET_BIT_CHKDUP(cc->bs, NEWLINE_CODE); + else { + r = add_code_range(&(cc->mbuf), env, NEWLINE_CODE, NEWLINE_CODE); + if (r < 0) goto err; + } } } } @@ -5078,11 +5078,11 @@ } static int parse_subexp(Node** top, OnigToken* tok, int term, - UChar** src, UChar* end, ScanEnv* env); + UChar** src, UChar* end, ScanEnv* env); static int parse_enclose(Node** np, OnigToken* tok, int term, UChar** src, UChar* end, - ScanEnv* env) + ScanEnv* env) { int r = 0, num; Node *target, *work1 = NULL, *work2 = NULL; @@ -5129,28 +5129,28 @@ break; case '~': /* (?~...) absent operator */ if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_TILDE_ABSENT)) { - *np = node_new_enclose(ENCLOSE_ABSENT); + *np = node_new_enclose(ENCLOSE_ABSENT); } else { - return ONIGERR_UNDEFINED_GROUP_OPTION; + return ONIGERR_UNDEFINED_GROUP_OPTION; } break; #ifdef USE_NAMED_GROUP case '\'': if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_LT_NAMED_GROUP)) { - goto named_group1; + goto named_group1; } else - return ONIGERR_UNDEFINED_GROUP_OPTION; + return ONIGERR_UNDEFINED_GROUP_OPTION; break; # ifdef USE_CAPITAL_P_NAMED_GROUP case 'P': /* (?P<name>...) */ if (!PEND && - IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_CAPITAL_P_NAMED_GROUP)) { - PFETCH(c); - if (c == '<') goto named_group1; + IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_CAPITAL_P_NAMED_GROUP)) { + PFETCH(c); + if (c == '<') goto named_group1; } return ONIGERR_UNDEFINED_GROUP_OPTION; break; @@ -5161,49 +5161,49 @@ if (PEND) return ONIGERR_END_PATTERN_WITH_UNMATCHED_PARENTHESIS; PFETCH(c); if (c == '=') - *np = onig_node_new_anchor(ANCHOR_LOOK_BEHIND); + *np = onig_node_new_anchor(ANCHOR_LOOK_BEHIND); else if (c == '!') - *np = onig_node_new_anchor(ANCHOR_LOOK_BEHIND_NOT); + *np = onig_node_new_anchor(ANCHOR_LOOK_BEHIND_NOT); #ifdef USE_NAMED_GROUP else { /* (?<name>...) */ - if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_LT_NAMED_GROUP)) { - UChar *name; - UChar *name_end; + if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_LT_NAMED_GROUP)) { + UChar *name; + UChar *name_end; - PUNFETCH; - c = '<'; + PUNFETCH; + c = '<'; - named_group1: - list_capture = 0; + named_group1: + list_capture = 0; # ifdef USE_CAPTURE_HISTORY - named_group2: + named_group2: # endif - name = p; - r = fetch_name((OnigCodePoint )c, &p, end, &name_end, env, &num, 0); - if (r < 0) return r; - - num = scan_env_add_mem_entry(env); - if (num < 0) return num; - if (list_capture != 0 && num >= (int )BIT_STATUS_BITS_NUM) - return ONIGERR_GROUP_NUMBER_OVER_FOR_CAPTURE_HISTORY; - - r = name_add(env->reg, name, name_end, num, env); - if (r != 0) return r; - *np = node_new_enclose_memory(env->option, 1); - CHECK_NULL_RETURN_MEMERR(*np); - NENCLOSE(*np)->regnum = num; - if (list_capture != 0) - BIT_STATUS_ON_AT_SIMPLE(env->capture_history, num); - env->num_named++; - } - else { - return ONIGERR_UNDEFINED_GROUP_OPTION; - } + name = p; + r = fetch_name((OnigCodePoint )c, &p, end, &name_end, env, &num, 0); + if (r < 0) return r; + + num = scan_env_add_mem_entry(env); + if (num < 0) return num; + if (list_capture != 0 && num >= (int )BIT_STATUS_BITS_NUM) + return ONIGERR_GROUP_NUMBER_OVER_FOR_CAPTURE_HISTORY; + + r = name_add(env->reg, name, name_end, num, env); + if (r != 0) return r; + *np = node_new_enclose_memory(env->option, 1); + CHECK_NULL_RETURN_MEMERR(*np); + NENCLOSE(*np)->regnum = num; + if (list_capture != 0) + BIT_STATUS_ON_AT_SIMPLE(env->capture_history, num); + env->num_named++; + } + else { + return ONIGERR_UNDEFINED_GROUP_OPTION; + } } #else else { - return ONIGERR_UNDEFINED_GROUP_OPTION; + return ONIGERR_UNDEFINED_GROUP_OPTION; } #endif break; @@ -5212,122 +5212,122 @@ case '@': if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_ATMARK_CAPTURE_HISTORY)) { # ifdef USE_NAMED_GROUP - if (!PEND && - IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_LT_NAMED_GROUP)) { - PFETCH(c); - if (c == '<' || c == '\'') { - list_capture = 1; - goto named_group2; /* (?@<name>...) */ - } - PUNFETCH; - } + if (!PEND && + IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_LT_NAMED_GROUP)) { + PFETCH(c); + if (c == '<' || c == '\'') { + list_capture = 1; + goto named_group2; /* (?@<name>...) */ + } + PUNFETCH; + } # endif - *np = node_new_enclose_memory(env->option, 0); - CHECK_NULL_RETURN_MEMERR(*np); - num = scan_env_add_mem_entry(env); - if (num < 0) return num; - if (num >= (int )BIT_STATUS_BITS_NUM) - return ONIGERR_GROUP_NUMBER_OVER_FOR_CAPTURE_HISTORY; + *np = node_new_enclose_memory(env->option, 0); + CHECK_NULL_RETURN_MEMERR(*np); + num = scan_env_add_mem_entry(env); + if (num < 0) return num; + if (num >= (int )BIT_STATUS_BITS_NUM) + return ONIGERR_GROUP_NUMBER_OVER_FOR_CAPTURE_HISTORY; - NENCLOSE(*np)->regnum = num; - BIT_STATUS_ON_AT_SIMPLE(env->capture_history, num); + NENCLOSE(*np)->regnum = num; + BIT_STATUS_ON_AT_SIMPLE(env->capture_history, num); } else { - return ONIGERR_UNDEFINED_GROUP_OPTION; + return ONIGERR_UNDEFINED_GROUP_OPTION; } break; #endif /* USE_CAPTURE_HISTORY */ case '(': /* conditional expression: (?(cond)yes), (?(cond)yes|no) */ if (!PEND && - IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_LPAREN_CONDITION)) { - UChar *name = NULL; - UChar *name_end; - PFETCH(c); - if (ONIGENC_IS_CODE_DIGIT(enc, c)) { /* (n) */ - PUNFETCH; - r = fetch_name((OnigCodePoint )'(', &p, end, &name_end, env, &num, 1); - if (r < 0) return r; + IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_LPAREN_CONDITION)) { + UChar *name = NULL; + UChar *name_end; + PFETCH(c); + if (ONIGENC_IS_CODE_DIGIT(enc, c)) { /* (n) */ + PUNFETCH; + r = fetch_name((OnigCodePoint )'(', &p, end, &name_end, env, &num, 1); + if (r < 0) return r; #if 0 - /* Relative number is not currently supported. (same as Perl) */ - if (num < 0) { - num = BACKREF_REL_TO_ABS(num, env); - if (num <= 0) - return ONIGERR_INVALID_BACKREF; - } + /* Relative number is not currently supported. (same as Perl) */ + if (num < 0) { + num = BACKREF_REL_TO_ABS(num, env); + if (num <= 0) + return ONIGERR_INVALID_BACKREF; + } #endif - if (IS_SYNTAX_BV(env->syntax, ONIG_SYN_STRICT_CHECK_BACKREF)) { - if (num > env->num_mem || - IS_NULL(SCANENV_MEM_NODES(env)[num])) - return ONIGERR_INVALID_BACKREF; - } - } + if (IS_SYNTAX_BV(env->syntax, ONIG_SYN_STRICT_CHECK_BACKREF)) { + if (num > env->num_mem || + IS_NULL(SCANENV_MEM_NODES(env)[num])) + return ONIGERR_INVALID_BACKREF; + } + } #ifdef USE_NAMED_GROUP - else if (c == '<' || c == '\'') { /* (<name>), ('name') */ - name = p; - r = fetch_named_backref_token(c, tok, &p, end, env); - if (r < 0) return r; - if (!PPEEK_IS(')')) return ONIGERR_UNDEFINED_GROUP_OPTION; - PINC; + else if (c == '<' || c == '\'') { /* (<name>), ('name') */ + name = p; + r = fetch_named_backref_token(c, tok, &p, end, env); + if (r < 0) return r; + if (!PPEEK_IS(')')) return ONIGERR_UNDEFINED_GROUP_OPTION; + PINC; - if (IS_SYNTAX_BV(env->syntax, ONIG_SYN_USE_LEFT_MOST_NAMED_GROUP)) { - num = tok->u.backref.ref1; - } - else { - /* FIXME: - * Use left most named group for now. This is the same as Perl. - * However this should use the same strategy as normal back- - * references on Ruby syntax; search right to left. */ - int len = tok->u.backref.num; - num = len > 1 ? tok->u.backref.refs[0] : tok->u.backref.ref1; - } - } + if (IS_SYNTAX_BV(env->syntax, ONIG_SYN_USE_LEFT_MOST_NAMED_GROUP)) { + num = tok->u.backref.ref1; + } + else { + /* FIXME: + * Use left most named group for now. This is the same as Perl. + * However this should use the same strategy as normal back- + * references on Ruby syntax; search right to left. */ + int len = tok->u.backref.num; + num = len > 1 ? tok->u.backref.refs[0] : tok->u.backref.ref1; + } + } #endif - else - return ONIGERR_INVALID_CONDITION_PATTERN; - *np = node_new_enclose(ENCLOSE_CONDITION); - CHECK_NULL_RETURN_MEMERR(*np); - NENCLOSE(*np)->regnum = num; - if (IS_NOT_NULL(name)) NENCLOSE(*np)->state |= NST_NAME_REF; + else + return ONIGERR_INVALID_CONDITION_PATTERN; + *np = node_new_enclose(ENCLOSE_CONDITION); + CHECK_NULL_RETURN_MEMERR(*np); + NENCLOSE(*np)->regnum = num; + if (IS_NOT_NULL(name)) NENCLOSE(*np)->state |= NST_NAME_REF; } else - return ONIGERR_UNDEFINED_GROUP_OPTION; + return ONIGERR_UNDEFINED_GROUP_OPTION; break; #if 0 case '|': /* branch reset: (?|...) */ if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_QMARK_VBAR_BRANCH_RESET)) { - /* TODO */ + /* TODO */ } else - return ONIGERR_UNDEFINED_GROUP_OPTION; + return ONIGERR_UNDEFINED_GROUP_OPTION; break; #endif case '^': /* loads default options */ if (!PEND && IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL)) { - /* d-imsx */ - ONOFF(option, ONIG_OPTION_ASCII_RANGE, 1); - ONOFF(option, ONIG_OPTION_IGNORECASE, 1); - ONOFF(option, ONIG_OPTION_SINGLELINE, 0); - ONOFF(option, ONIG_OPTION_MULTILINE, 1); - ONOFF(option, ONIG_OPTION_EXTEND, 1); - PFETCH(c); + /* d-imsx */ + ONOFF(option, ONIG_OPTION_ASCII_RANGE, 1); + ONOFF(option, ONIG_OPTION_IGNORECASE, 1); + ONOFF(option, ONIG_OPTION_SINGLELINE, 0); + ONOFF(option, ONIG_OPTION_MULTILINE, 1); + ONOFF(option, ONIG_OPTION_EXTEND, 1); + PFETCH(c); } #if 0 else if (!PEND && IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_RUBY)) { - /* d-imx */ - ONOFF(option, ONIG_OPTION_ASCII_RANGE, 0); - ONOFF(option, ONIG_OPTION_POSIX_BRACKET_ALL_RANGE, 0); - ONOFF(option, ONIG_OPTION_WORD_BOUND_ALL_RANGE, 0); - ONOFF(option, ONIG_OPTION_IGNORECASE, 1); - ONOFF(option, ONIG_OPTION_MULTILINE, 1); - ONOFF(option, ONIG_OPTION_EXTEND, 1); - PFETCH(c); + /* d-imx */ + ONOFF(option, ONIG_OPTION_ASCII_RANGE, 0); + ONOFF(option, ONIG_OPTION_POSIX_BRACKET_ALL_RANGE, 0); + ONOFF(option, ONIG_OPTION_WORD_BOUND_ALL_RANGE, 0); + ONOFF(option, ONIG_OPTION_IGNORECASE, 1); + ONOFF(option, ONIG_OPTION_MULTILINE, 1); + ONOFF(option, ONIG_OPTION_EXTEND, 1); + PFETCH(c); } #endif else { - return ONIGERR_UNDEFINED_GROUP_OPTION; + return ONIGERR_UNDEFINED_GROUP_OPTION; } /* fall through */ #ifdef USE_POSIXLINE_OPTION @@ -5336,120 +5336,120 @@ case '-': case 'i': case 'm': case 's': case 'x': case 'a': case 'd': case 'l': case 'u': { - int neg = 0; + int neg = 0; - while (1) { - switch (c) { - case ':': - case ')': - break; - - case '-': neg = 1; break; - case 'x': ONOFF(option, ONIG_OPTION_EXTEND, neg); break; - case 'i': ONOFF(option, ONIG_OPTION_IGNORECASE, neg); break; - case 's': - if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL)) { - ONOFF(option, ONIG_OPTION_MULTILINE, neg); - } - else - return ONIGERR_UNDEFINED_GROUP_OPTION; - break; - - case 'm': - if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL)) { - ONOFF(option, ONIG_OPTION_SINGLELINE, (neg == 0 ? 1 : 0)); - } - else if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_RUBY)) { - ONOFF(option, ONIG_OPTION_MULTILINE, neg); - } - else - return ONIGERR_UNDEFINED_GROUP_OPTION; - break; + while (1) { + switch (c) { + case ':': + case ')': + break; + + case '-': neg = 1; break; + case 'x': ONOFF(option, ONIG_OPTION_EXTEND, neg); break; + case 'i': ONOFF(option, ONIG_OPTION_IGNORECASE, neg); break; + case 's': + if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL)) { + ONOFF(option, ONIG_OPTION_MULTILINE, neg); + } + else + return ONIGERR_UNDEFINED_GROUP_OPTION; + break; + + case 'm': + if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL)) { + ONOFF(option, ONIG_OPTION_SINGLELINE, (neg == 0 ? 1 : 0)); + } + else if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_RUBY)) { + ONOFF(option, ONIG_OPTION_MULTILINE, neg); + } + else + return ONIGERR_UNDEFINED_GROUP_OPTION; + break; #ifdef USE_POSIXLINE_OPTION - case 'p': - ONOFF(option, ONIG_OPTION_MULTILINE|ONIG_OPTION_SINGLELINE, neg); - break; -#endif - - case 'a': /* limits \d, \s, \w and POSIX brackets to ASCII range */ - if ((IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL) || - IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_RUBY)) && - (neg == 0)) { - ONOFF(option, ONIG_OPTION_ASCII_RANGE, 0); - ONOFF(option, ONIG_OPTION_POSIX_BRACKET_ALL_RANGE, 1); - ONOFF(option, ONIG_OPTION_WORD_BOUND_ALL_RANGE, 1); - } - else - return ONIGERR_UNDEFINED_GROUP_OPTION; - break; - - case 'u': - if ((IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL) || - IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_RUBY)) && - (neg == 0)) { - ONOFF(option, ONIG_OPTION_ASCII_RANGE, 1); - ONOFF(option, ONIG_OPTION_POSIX_BRACKET_ALL_RANGE, 1); - ONOFF(option, ONIG_OPTION_WORD_BOUND_ALL_RANGE, 1); - } - else - return ONIGERR_UNDEFINED_GROUP_OPTION; - break; - - case 'd': - if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL) && - (neg == 0)) { - ONOFF(option, ONIG_OPTION_ASCII_RANGE, 1); - } - else if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_RUBY) && - (neg == 0)) { - ONOFF(option, ONIG_OPTION_ASCII_RANGE, 0); - ONOFF(option, ONIG_OPTION_POSIX_BRACKET_ALL_RANGE, 0); - ONOFF(option, ONIG_OPTION_WORD_BOUND_ALL_RANGE, 0); - } - else - return ONIGERR_UNDEFINED_GROUP_OPTION; - break; - - case 'l': - if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL) && (neg == 0)) { - ONOFF(option, ONIG_OPTION_ASCII_RANGE, 1); - } - else - return ONIGERR_UNDEFINED_GROUP_OPTION; - break; + case 'p': + ONOFF(option, ONIG_OPTION_MULTILINE|ONIG_OPTION_SINGLELINE, neg); + break; +#endif - default: - return ONIGERR_UNDEFINED_GROUP_OPTION; - } + case 'a': /* limits \d, \s, \w and POSIX brackets to ASCII range */ + if ((IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL) || + IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_RUBY)) && + (neg == 0)) { + ONOFF(option, ONIG_OPTION_ASCII_RANGE, 0); + ONOFF(option, ONIG_OPTION_POSIX_BRACKET_ALL_RANGE, 1); + ONOFF(option, ONIG_OPTION_WORD_BOUND_ALL_RANGE, 1); + } + else + return ONIGERR_UNDEFINED_GROUP_OPTION; + break; + + case 'u': + if ((IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL) || + IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_RUBY)) && + (neg == 0)) { + ONOFF(option, ONIG_OPTION_ASCII_RANGE, 1); + ONOFF(option, ONIG_OPTION_POSIX_BRACKET_ALL_RANGE, 1); + ONOFF(option, ONIG_OPTION_WORD_BOUND_ALL_RANGE, 1); + } + else + return ONIGERR_UNDEFINED_GROUP_OPTION; + break; + + case 'd': + if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL) && + (neg == 0)) { + ONOFF(option, ONIG_OPTION_ASCII_RANGE, 1); + } + else if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_RUBY) && + (neg == 0)) { + ONOFF(option, ONIG_OPTION_ASCII_RANGE, 0); + ONOFF(option, ONIG_OPTION_POSIX_BRACKET_ALL_RANGE, 0); + ONOFF(option, ONIG_OPTION_WORD_BOUND_ALL_RANGE, 0); + } + else + return ONIGERR_UNDEFINED_GROUP_OPTION; + break; + + case 'l': + if (IS_SYNTAX_OP2(env->syntax, ONIG_SYN_OP2_OPTION_PERL) && (neg == 0)) { + ONOFF(option, ONIG_OPTION_ASCII_RANGE, 1); + } + else + return ONIGERR_UNDEFINED_GROUP_OPTION; + break; - if (c == ')') { - *np = node_new_option(option); - CHECK_NULL_RETURN_MEMERR(*np); - *src = p; - return 2; /* option only */ - } - else if (c == ':') { - OnigOptionType prev = env->option; + default: + return ONIGERR_UNDEFINED_GROUP_OPTION; + } - env->option = option; - r = fetch_token(tok, &p, end, env); - if (r < 0) { - env->option = prev; - return r; - } - r = parse_subexp(&target, tok, term, &p, end, env); - env->option = prev; - if (r < 0) return r; - *np = node_new_option(option); - CHECK_NULL_RETURN_MEMERR(*np); - NENCLOSE(*np)->target = target; - *src = p; - return 0; - } + if (c == ')') { + *np = node_new_option(option); + CHECK_NULL_RETURN_MEMERR(*np); + *src = p; + return 2; /* option only */ + } + else if (c == ':') { + OnigOptionType prev = env->option; - if (PEND) return ONIGERR_END_PATTERN_IN_GROUP; - PFETCH(c); - } + env->option = option; + r = fetch_token(tok, &p, end, env); + if (r < 0) { + env->option = prev; + return r; + } + r = parse_subexp(&target, tok, term, &p, end, env); + env->option = prev; + if (r < 0) return r; + *np = node_new_option(option); + CHECK_NULL_RETURN_MEMERR(*np); + NENCLOSE(*np)->target = target; + *src = p; + return 0; + } + + if (PEND) return ONIGERR_END_PATTERN_IN_GROUP; + PFETCH(c); + } } break; @@ -5488,14 +5488,14 @@ } else if (NENCLOSE(*np)->type == ENCLOSE_CONDITION) { if (NTYPE(target) != NT_ALT) { - /* convert (?(cond)yes) to (?(cond)yes|empty) */ - work1 = node_new_empty(); - if (IS_NULL(work1)) goto err; - work2 = onig_node_new_alt(work1, NULL_NODE); - if (IS_NULL(work2)) goto err; - work1 = onig_node_new_alt(target, work2); - if (IS_NULL(work1)) goto err; - NENCLOSE(*np)->target = work1; + /* convert (?(cond)yes) to (?(cond)yes|empty) */ + work1 = node_new_empty(); + if (IS_NULL(work1)) goto err; + work2 = onig_node_new_alt(work1, NULL_NODE); + if (IS_NULL(work2)) goto err; + work1 = onig_node_new_alt(target, work2); + if (IS_NULL(work1)) goto err; + NENCLOSE(*np)->target = work1; } } } @@ -5534,11 +5534,11 @@ if (! group) { StrNode* sn = NSTR(target); if (str_node_can_be_split(sn, env->enc)) { - Node* n = str_node_split_last_char(sn, env->enc); - if (IS_NOT_NULL(n)) { - qn->target = n; - return 2; - } + Node* n = str_node_split_last_char(sn, env->enc); + if (IS_NOT_NULL(n)) { + qn->target = n; + return 2; + } } } break; @@ -5552,43 +5552,43 @@ #ifdef USE_WARNING_REDUNDANT_NESTED_REPEAT_OPERATOR if (nestq_num >= 0 && targetq_num >= 0 && - IS_SYNTAX_BV(env->syntax, ONIG_SYN_WARN_REDUNDANT_NESTED_REPEAT)) { - switch (ReduceTypeTable[targetq_num][nestq_num]) { - case RQ_ASIS: - break; - - case RQ_DEL: - if (onig_warn != onig_null_warn) { - onig_syntax_warn(env, "regular expression has redundant nested repeat operator '%s'", - PopularQStr[targetq_num]); - } - goto warn_exit; - break; + IS_SYNTAX_BV(env->syntax, ONIG_SYN_WARN_REDUNDANT_NESTED_REPEAT)) { + switch (ReduceTypeTable[targetq_num][nestq_num]) { + case RQ_ASIS: + break; + + case RQ_DEL: + if (onig_warn != onig_null_warn) { + onig_syntax_warn(env, "regular expression has redundant nested repeat operator '%s'", + PopularQStr[targetq_num]); + } + goto warn_exit; + break; - default: - if (onig_warn != onig_null_warn) { - onig_syntax_warn(env, "nested repeat operator '%s' and '%s' was replaced with '%s' in regular expression", - PopularQStr[targetq_num], PopularQStr[nestq_num], - ReduceQStr[ReduceTypeTable[targetq_num][nestq_num]]); - } - goto warn_exit; - break; - } + default: + if (onig_warn != onig_null_warn) { + onig_syntax_warn(env, "nested repeat operator '%s' and '%s' was replaced with '%s' in regular expression", + PopularQStr[targetq_num], PopularQStr[nestq_num], + ReduceQStr[ReduceTypeTable[targetq_num][nestq_num]]); + } + goto warn_exit; + break; + } } warn_exit: #endif if (targetq_num >= 0) { - if (nestq_num >= 0) { - onig_reduce_nested_quantifier(qnode, target); - goto q_exit; - } - else if (targetq_num == 1 || targetq_num == 2) { /* * or + */ - /* (?:a*){n,m}, (?:a+){n,m} => (?:a*){n,n}, (?:a+){n,n} */ - if (! IS_REPEAT_INFINITE(qn->upper) && qn->upper > 1 && qn->greedy) { - qn->upper = (qn->lower == 0 ? 1 : qn->lower); - } - } + if (nestq_num >= 0) { + onig_reduce_nested_quantifier(qnode, target); + goto q_exit; + } + else if (targetq_num == 1 || targetq_num == 2) { /* * or + */ + /* (?:a*){n,m}, (?:a+){n,m} => (?:a*){n,n}, (?:a+){n,n} */ + if (! IS_REPEAT_INFINITE(qn->upper) && qn->upper > 1 && qn->greedy) { + qn->upper = (qn->lower == 0 ? 1 : qn->lower); + } + } } } break; @@ -5638,7 +5638,7 @@ static int i_apply_case_fold(OnigCodePoint from, OnigCodePoint to[], - int to_len, void* arg) + int to_len, void* arg) { IApplyCaseFoldArg* iarg; ScanEnv* env; @@ -5669,7 +5669,7 @@ int is_in = onig_is_code_in_cc(env->enc, from, cc); #ifdef CASE_FOLD_IS_APPLIED_INSIDE_NEGATIVE_CCLASS if ((is_in != 0 && !IS_NCCLASS_NOT(cc)) || - (is_in == 0 && IS_NCCLASS_NOT(cc))) { + (is_in == 0 && IS_NCCLASS_NOT(cc))) { if (add_flag) { if (ONIGENC_MBC_MINLEN(env->enc) > 1 || *to >= SINGLE_BYTE_SIZE) { r = add_code_range0(&(cc->mbuf), env, *to, *to, 0); @@ -5707,26 +5707,26 @@ if (onig_is_code_in_cc(env->enc, from, cc) #ifdef CASE_FOLD_IS_APPLIED_INSIDE_NEGATIVE_CCLASS - && !IS_NCCLASS_NOT(cc) + && !IS_NCCLASS_NOT(cc) #endif - ) { + ) { for (i = 0; i < to_len; i++) { - len = ONIGENC_CODE_TO_MBC(env->enc, to[i], buf); - if (i == 0) { - snode = onig_node_new_str(buf, buf + len); - CHECK_NULL_RETURN_MEMERR(snode); - - /* char-class expanded multi-char only - compare with string folded at match time. */ - NSTRING_SET_AMBIG(snode); - } - else { - r = onig_node_str_cat(snode, buf, buf + len); - if (r < 0) { - onig_node_free(snode); - return r; - } - } + len = ONIGENC_CODE_TO_MBC(env->enc, to[i], buf); + if (i == 0) { + snode = onig_node_new_str(buf, buf + len); + CHECK_NULL_RETURN_MEMERR(snode); + + /* char-class expanded multi-char only + compare with string folded at match time. */ + NSTRING_SET_AMBIG(snode); + } + else { + r = onig_node_str_cat(snode, buf, buf + len); + if (r < 0) { + onig_node_free(snode); + return r; + } + } } *(iarg->ptail) = onig_node_new_alt(snode, NULL_NODE); @@ -5751,7 +5751,7 @@ iarg.ptail = &(iarg.alt_root); r = ONIGENC_APPLY_ALL_CASE_FOLD(env->enc, env->case_fold_flag, - i_apply_case_fold, &iarg); + i_apply_case_fold, &iarg); if (r != 0) { onig_node_free(iarg.alt_root); return r; @@ -6214,8 +6214,8 @@ /* only one char found in the bbuf, save the code point. */ c = data[0]; if (((c < SINGLE_BYTE_SIZE) && BITSET_AT(cc->bs, c))) { - /* skip if c is included in the bitset */ - c = not_found; + /* skip if c is included in the bitset */ + c = not_found; } } else { @@ -6228,9 +6228,10 @@ Bits b1 = cc->bs[i]; if (b1 != 0) { if (((b1 & (b1 - 1)) == 0) && (c == not_found)) { - c = BITS_IN_ROOM * i + countbits(b1 - 1); - } else { - return 0; /* the character class contains multiple chars */ + c = BITS_IN_ROOM * i + countbits(b1 - 1); + } + else { + return 0; /* the character class contains multiple chars */ } } } @@ -6247,7 +6248,7 @@ static int parse_exp(Node** np, OnigToken* tok, int term, - UChar** src, UChar* end, ScanEnv* env) + UChar** src, UChar* end, ScanEnv* env) { int r, len, group = 0; Node* qn; @@ -6276,14 +6277,14 @@ env->option = NENCLOSE(*np)->option; r = fetch_token(tok, src, end, env); if (r < 0) { - env->option = prev; - return r; + env->option = prev; + return r; } r = parse_subexp(&target, tok, term, src, end, env); env->option = prev; if (r < 0) { - onig_node_free(target); - return r; + onig_node_free(target); + return r; } NENCLOSE(*np)->target = target; return tok->type; @@ -6321,20 +6322,20 @@ string_loop: while (1) { - r = fetch_token(tok, src, end, env); - if (r < 0) return r; - if (r == TK_STRING) { - r = onig_node_str_cat(*np, tok->backp, *src); - } + r = fetch_token(tok, src, end, env); + if (r < 0) return r; + if (r == TK_STRING) { + r = onig_node_str_cat(*np, tok->backp, *src); + } #ifndef NUMBERED_CHAR_IS_NOT_CASE_AMBIG - else if (r == TK_CODE_POINT) { - r = node_str_cat_codepoint(*np, env->enc, tok->u.code); - } + else if (r == TK_CODE_POINT) { + r = node_str_cat_codepoint(*np, env->enc, tok->u.code); + } #endif - else { - break; - } - if (r < 0) return r; + else { + break; + } + if (r < 0) return r; } string_end: @@ -6350,36 +6351,36 @@ CHECK_NULL_RETURN_MEMERR(*np); len = 1; while (1) { - if (len >= ONIGENC_MBC_MINLEN(env->enc)) { - if (len == enclen(env->enc, NSTR(*np)->s, NSTR(*np)->end)) { - r = fetch_token(tok, src, end, env); - NSTRING_CLEAR_RAW(*np); - goto string_end; - } - } + if (len >= ONIGENC_MBC_MINLEN(env->enc)) { + if (len == enclen(env->enc, NSTR(*np)->s, NSTR(*np)->end)) { + r = fetch_token(tok, src, end, env); + NSTRING_CLEAR_RAW(*np); + goto string_end; + } + } - r = fetch_token(tok, src, end, env); - if (r < 0) return r; - if (r != TK_RAW_BYTE) { - /* Don't use this, it is wrong for little endian encodings. */ + r = fetch_token(tok, src, end, env); + if (r < 0) return r; + if (r != TK_RAW_BYTE) { + /* Don't use this, it is wrong for little endian encodings. */ #ifdef USE_PAD_TO_SHORT_BYTE_CHAR - int rem; - if (len < ONIGENC_MBC_MINLEN(env->enc)) { - rem = ONIGENC_MBC_MINLEN(env->enc) - len; - (void )node_str_head_pad(NSTR(*np), rem, (UChar )0); - if (len + rem == enclen(env->enc, NSTR(*np)->s)) { - NSTRING_CLEAR_RAW(*np); - goto string_end; - } - } + int rem; + if (len < ONIGENC_MBC_MINLEN(env->enc)) { + rem = ONIGENC_MBC_MINLEN(env->enc) - len; + (void )node_str_head_pad(NSTR(*np), rem, (UChar )0); + if (len + rem == enclen(env->enc, NSTR(*np)->s)) { + NSTRING_CLEAR_RAW(*np); + goto string_end; + } + } #endif - return ONIGERR_TOO_SHORT_MULTI_BYTE_STRING; - } + return ONIGERR_TOO_SHORT_MULTI_BYTE_STRING; + } - r = node_str_cat_char(*np, (UChar )tok->u.c); - if (r < 0) return r; + r = node_str_cat_char(*np, (UChar )tok->u.c); + if (r < 0) return r; - len++; + len++; } } break; @@ -6408,7 +6409,7 @@ qstart = *src; qend = find_str_position(end_op, 2, qstart, end, &nextp, env->enc); if (IS_NULL(qend)) { - nextp = qend = end; + nextp = qend = end; } *np = node_new_str(qstart, qend); CHECK_NULL_RETURN_MEMERR(*np); @@ -6420,30 +6421,30 @@ { switch (tok->u.prop.ctype) { case ONIGENC_CTYPE_WORD: - *np = node_new_ctype(tok->u.prop.ctype, tok->u.prop.not, - IS_ASCII_RANGE(env->option)); - CHECK_NULL_RETURN_MEMERR(*np); - break; + *np = node_new_ctype(tok->u.prop.ctype, tok->u.prop.not, + IS_ASCII_RANGE(env->option)); + CHECK_NULL_RETURN_MEMERR(*np); + break; case ONIGENC_CTYPE_SPACE: case ONIGENC_CTYPE_DIGIT: case ONIGENC_CTYPE_XDIGIT: - { - CClassNode* cc; + { + CClassNode* cc; - *np = node_new_cclass(); - CHECK_NULL_RETURN_MEMERR(*np); - cc = NCCLASS(*np); - r = add_ctype_to_cc(cc, tok->u.prop.ctype, 0, - IS_ASCII_RANGE(env->option), env); - if (r != 0) return r; - if (tok->u.prop.not != 0) NCCLASS_SET_NOT(cc); - } - break; + *np = node_new_cclass(); + CHECK_NULL_RETURN_MEMERR(*np); + cc = NCCLASS(*np); + r = add_ctype_to_cc(cc, tok->u.prop.ctype, 0, + IS_ASCII_RANGE(env->option), env); + if (r != 0) return r; + if (tok->u.prop.not != 0) NCCLASS_SET_NOT(cc); + } + break; default: - return ONIGERR_PARSER_BUG; - break; + return ONIGERR_PARSER_BUG; + break; } } break; @@ -6461,26 +6462,26 @@ r = parse_char_class(np, &asc_node, tok, src, end, env); if (r != 0) { - onig_node_free(asc_node); - return r; + onig_node_free(asc_node); + return r; } cc = NCCLASS(*np); if (is_onechar_cclass(cc, &code)) { - onig_node_free(*np); - onig_node_free(asc_node); - *np = node_new_empty(); - CHECK_NULL_RETURN_MEMERR(*np); - r = node_str_cat_codepoint(*np, env->enc, code); - if (r != 0) return r; - goto string_loop; + onig_node_free(*np); + onig_node_free(asc_node); + *np = node_new_empty(); + CHECK_NULL_RETURN_MEMERR(*np); + r = node_str_cat_codepoint(*np, env->enc, code); + if (r != 0) return r; + goto string_loop; } if (IS_IGNORECASE(env->option)) { - r = cclass_case_fold(np, cc, NCCLASS(asc_node), env); - if (r != 0) { - onig_node_free(asc_node); - return r; - } + r = cclass_case_fold(np, cc, NCCLASS(asc_node), env); + if (r != 0) { + onig_node_free(asc_node); + return r; + } } onig_node_free(asc_node); } @@ -6503,13 +6504,13 @@ case TK_BACKREF: len = tok->u.backref.num; *np = node_new_backref(len, - (len > 1 ? tok->u.backref.refs : &(tok->u.backref.ref1)), - tok->u.backref.by_name, + (len > 1 ? tok->u.backref.refs : &(tok->u.backref.ref1)), + tok->u.backref.by_name, #ifdef USE_BACKREF_WITH_LEVEL - tok->u.backref.exist_level, - tok->u.backref.level, + tok->u.backref.exist_level, + tok->u.backref.level, #endif - env); + env); CHECK_NULL_RETURN_MEMERR(*np); break; @@ -6519,10 +6520,10 @@ int gnum = tok->u.call.gnum; if (gnum < 0 || tok->u.call.rel != 0) { - if (gnum > 0) gnum--; - gnum = BACKREF_REL_TO_ABS(gnum, env); - if (gnum <= 0) - return ONIGERR_INVALID_BACKREF; + if (gnum > 0) gnum--; + gnum = BACKREF_REL_TO_ABS(gnum, env); + if (gnum <= 0) + return ONIGERR_INVALID_BACKREF; } *np = node_new_call(tok->u.call.name, tok->u.call.name_end, gnum); CHECK_NULL_RETURN_MEMERR(*np); @@ -6541,9 +6542,9 @@ case TK_INTERVAL: if (IS_SYNTAX_BV(env->syntax, ONIG_SYN_CONTEXT_INDEP_REPEAT_OPS)) { if (IS_SYNTAX_BV(env->syntax, ONIG_SYN_CONTEXT_INVALID_REPEAT_OPS)) - return ONIGERR_TARGET_OF_REPEAT_OPERATOR_NOT_SPECIFIED; + return ONIGERR_TARGET_OF_REPEAT_OPERATOR_NOT_SPECIFIED; else - *np = node_new_empty(); + *np = node_new_empty(); } else { goto tk_byte; @@ -6565,49 +6566,49 @@ repeat: if (r == TK_OP_REPEAT || r == TK_INTERVAL) { if (is_invalid_quantifier_target(*targetp)) - return ONIGERR_TARGET_OF_REPEAT_OPERATOR_INVALID; + return ONIGERR_TARGET_OF_REPEAT_OPERATOR_INVALID; qn = node_new_quantifier(tok->u.repeat.lower, tok->u.repeat.upper, - (r == TK_INTERVAL ? 1 : 0)); + (r == TK_INTERVAL ? 1 : 0)); CHECK_NULL_RETURN_MEMERR(qn); NQTFR(qn)->greedy = tok->u.repeat.greedy; r = set_quantifier(qn, *targetp, group, env); if (r < 0) { - onig_node_free(qn); - return r; + onig_node_free(qn); + return r; } if (tok->u.repeat.possessive != 0) { - Node* en; - en = node_new_enclose(ENCLOSE_STOP_BACKTRACK); - if (IS_NULL(en)) { - onig_node_free(qn); - return ONIGERR_MEMORY; - } - NENCLOSE(en)->target = qn; - qn = en; + Node* en; + en = node_new_enclose(ENCLOSE_STOP_BACKTRACK); + if (IS_NULL(en)) { + onig_node_free(qn); + return ONIGERR_MEMORY; + } + NENCLOSE(en)->target = qn; + qn = en; } if (r == 0) { - *targetp = qn; + *targetp = qn; } else if (r == 1) { - onig_node_free(qn); + onig_node_free(qn); } else if (r == 2) { /* split case: /abc+/ */ - Node *tmp; + Node *tmp; - *targetp = node_new_list(*targetp, NULL); - if (IS_NULL(*targetp)) { - onig_node_free(qn); - return ONIGERR_MEMORY; - } - tmp = NCDR(*targetp) = node_new_list(qn, NULL); - if (IS_NULL(tmp)) { - onig_node_free(qn); - return ONIGERR_MEMORY; - } - targetp = &(NCAR(tmp)); + *targetp = node_new_list(*targetp, NULL); + if (IS_NULL(*targetp)) { + onig_node_free(qn); + return ONIGERR_MEMORY; + } + tmp = NCDR(*targetp) = node_new_list(qn, NULL); + if (IS_NULL(tmp)) { + onig_node_free(qn); + return ONIGERR_MEMORY; + } + targetp = &(NCAR(tmp)); } goto re_entry; } @@ -6618,7 +6619,7 @@ static int parse_branch(Node** top, OnigToken* tok, int term, - UChar** src, UChar* end, ScanEnv* env) + UChar** src, UChar* end, ScanEnv* env) { int r; Node *node, **headp; @@ -6639,18 +6640,18 @@ while (r != TK_EOT && r != term && r != TK_ALT) { r = parse_exp(&node, tok, term, src, end, env); if (r < 0) { - onig_node_free(node); - return r; + onig_node_free(node); + return r; } if (NTYPE(node) == NT_LIST) { - *headp = node; - while (IS_NOT_NULL(NCDR(node))) node = NCDR(node); - headp = &(NCDR(node)); + *headp = node; + while (IS_NOT_NULL(NCDR(node))) node = NCDR(node); + headp = &(NCDR(node)); } else { - *headp = node_new_list(node, NULL); - headp = &(NCDR(*headp)); + *headp = node_new_list(node, NULL); + headp = &(NCDR(*headp)); } } } @@ -6661,10 +6662,10 @@ /* term_tok: TK_EOT or TK_SUBEXP_CLOSE */ static int parse_subexp(Node** top, OnigToken* tok, int term, - UChar** src, UChar* end, ScanEnv* env) + UChar** src, UChar* end, ScanEnv* env) { int r; - Node *node, **headp; + Node *node, *topnode, **headp; *top = NULL; env->parse_depth++; @@ -6680,23 +6681,31 @@ *top = node; } else if (r == TK_ALT) { - *top = onig_node_new_alt(node, NULL); - headp = &(NCDR(*top)); + topnode = onig_node_new_alt(node, NULL); + headp = &(NCDR(topnode)); while (r == TK_ALT) { r = fetch_token(tok, src, end, env); - if (r < 0) return r; + if (r < 0) { + onig_node_free(topnode); + return r; + } r = parse_branch(&node, tok, term, src, end, env); if (r < 0) { - onig_node_free(node); - return r; + /* the failed branch is not linked into topnode yet: free both */ + onig_node_free(node); + onig_node_free(topnode); + return r; } *headp = onig_node_new_alt(node, NULL); - headp = &(NCDR(*headp)); + headp = &(NCDR(*headp)); } - if (tok->type != (enum TokenSyms )term) + if (tok->type != (enum TokenSyms )term) { + onig_node_free(topnode); goto err; + } + *top = topnode; } else { onig_node_free(node); @@ -6733,8 +6742,8 @@ NENCLOSE(np)->target = *top; r = scan_env_set_mem_node(env, num, np); if (r != 0) { - onig_node_free(np); - return r; + onig_node_free(np); + return r; } *top = np; } @@ -6744,7 +6753,7 @@ extern int onig_parse_make_tree(Node** root, const UChar* pattern, const UChar* end, - regex_t* reg, ScanEnv* env) + regex_t* reg, ScanEnv* env) { int r; UChar* p; @@ -6771,7 +6780,7 @@ extern void onig_scan_env_set_error_string(ScanEnv* env, int ecode ARG_UNUSED, - UChar* arg, UChar* arg_end) + UChar* arg, UChar* arg_end) { env->error = arg; env->error_end = arg_end; diff -Nru ruby3.3-3.3.8/regparse.h ruby3.3-3.3.13/regparse.h --- ruby3.3-3.3.8/regparse.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/regparse.h 2026-10-23 03:17:41.000000000 +0000 @@ -69,8 +69,8 @@ #define NTYPE(node) ((node)->u.base.type) #define SET_NTYPE(node, ntype) \ do { \ - int value = ntype; \ - memcpy(&((node)->u.base.type), &value, sizeof(int)); \ + int value = ntype; \ + memcpy(&((node)->u.base.type), &value, sizeof(int)); \ } while (0) #define NSTR(node) (&((node)->u.str)) diff -Nru ruby3.3-3.3.8/revision.h ruby3.3-3.3.13/revision.h --- ruby3.3-3.3.8/revision.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/revision.h 2026-10-23 03:17:41.000000000 +0000 @@ -1,5 +1,5 @@ -#define RUBY_REVISION "b200bad6cd" -#define RUBY_FULL_REVISION "b200bad6cd40d08e9f33b93e1a85c270b337867c" -#define RUBY_RELEASE_YEAR 2025 -#define RUBY_RELEASE_MONTH 4 -#define RUBY_RELEASE_DAY 9 +#define RUBY_REVISION "af48f08f21" +#define RUBY_FULL_REVISION "af48f08f2113db1cc4ee171f34e399d7a902151b" +#define RUBY_RELEASE_YEAR 2026 +#define RUBY_RELEASE_MONTH 10 +#define RUBY_RELEASE_DAY 23 diff -Nru ruby3.3-3.3.8/ruby.c ruby3.3-3.3.13/ruby.c --- ruby3.3-3.3.8/ruby.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/ruby.c 2026-10-23 03:17:41.000000000 +0000 @@ -1336,7 +1336,7 @@ static void proc_encoding_option(ruby_cmdline_options_t *opt, const char *s, const char *opt_name) { - char *p; + const char *p; # define set_encoding_part(type) \ if (!(p = strchr(s, ':'))) { \ set_##type##_encoding_once(opt, s, 0); \ diff -Nru ruby3.3-3.3.8/scheduler.c ruby3.3-3.3.13/scheduler.c --- ruby3.3-3.3.8/scheduler.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/scheduler.c 2026-10-23 03:17:41.000000000 +0000 @@ -9,6 +9,7 @@ **********************************************************************/ #include "vm_core.h" +#include "eval_intern.h" #include "ruby/fiber/scheduler.h" #include "ruby/io.h" #include "ruby/io/buffer.h" @@ -403,11 +404,32 @@ { VM_ASSERT(rb_obj_is_fiber(fiber)); + VALUE result; + enum ruby_tag_type state; + // `rb_fiber_scheduler_unblock` can be called from points where `errno` is expected to be preserved. Therefore, we should save and restore it. For example `io_binwrite` calls `rb_fiber_scheduler_unblock` and if `errno` is reset to 0 by user code, it will break the error handling in `io_write`. + // // If we explicitly preserve `errno` in `io_binwrite` and other similar functions (e.g. by returning it), this code is no longer needed. I hope in the future we will be able to remove it. int saved_errno = errno; - VALUE result = rb_funcall(scheduler, id_unblock, 2, blocker, fiber); + // We must prevent interrupts while invoking the unblock method, because otherwise fibers can be left permanently blocked if an interrupt occurs during the execution of user code. + rb_execution_context_t *ec = GET_EC(); + int saved_interrupt_mask = ec->interrupt_mask; + ec->interrupt_mask |= PENDING_INTERRUPT_MASK; + + EC_PUSH_TAG(ec); + if ((state = EC_EXEC_TAG()) == TAG_NONE) { + result = rb_funcall(scheduler, id_unblock, 2, blocker, fiber); + } + EC_POP_TAG(); + + ec->interrupt_mask = saved_interrupt_mask; + + if (state) { + EC_JUMP_TAG(ec, state); + } + + RUBY_VM_CHECK_INTS(ec); errno = saved_errno; diff -Nru ruby3.3-3.3.8/signal.c ruby3.3-3.3.13/signal.c --- ruby3.3-3.3.8/signal.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/signal.c 2026-10-23 03:17:41.000000000 +0000 @@ -45,6 +45,7 @@ #include "ruby_atomic.h" #include "vm_core.h" #include "ractor_core.h" +#include "ruby/internal/attr/nonstring.h" #ifdef NEED_RUBY_ATOMIC_OPS rb_atomic_t @@ -849,6 +850,7 @@ * otherwise it can cause stack overflow again at the same * place. */ if ((crit = (!ec->tag->prev || !--uplevel)) != FALSE) break; + rb_vm_tag_jmpbuf_deinit(&ec->tag->buf); ec->tag = ec->tag->prev; } reset_sigmask(sig); @@ -968,7 +970,7 @@ if (prev) { ssize_t RB_UNUSED_VAR(err); static const int stderr_fd = 2; -#define NOZ(name, str) name[sizeof(str)-1] = str +#define NOZ(name, str) RBIMPL_ATTR_NONSTRING() name[sizeof(str)-1] = str static const char NOZ(msg1, " received in "); static const char NOZ(msg2, " handler\n"); diff -Nru ruby3.3-3.3.8/siphash.c ruby3.3-3.3.13/siphash.c --- ruby3.3-3.3.8/siphash.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/siphash.c 2026-10-23 03:17:41.000000000 +0000 @@ -140,6 +140,9 @@ #endif static const union { +#if defined(__has_attribute) && __has_attribute(nonstring) + __attribute__((nonstring)) +#endif char bin[32]; uint64_t u64[4]; } sip_init_state_bin = {"uespemos""modnarod""arenegyl""setybdet"}; diff -Nru ruby3.3-3.3.8/spec/bundler/spec_helper.rb ruby3.3-3.3.13/spec/bundler/spec_helper.rb --- ruby3.3-3.3.8/spec/bundler/spec_helper.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/bundler/spec_helper.rb 2026-10-23 03:17:41.000000000 +0000 @@ -84,6 +84,16 @@ ENV["XDG_CONFIG_HOME"] = nil ENV["GEMRC"] = nil + # Disable git background maintenance. Since Git 2.46, commands like + # `git commit` spawn a detached `git maintenance run --auto` process, + # which briefly creates `.git/objects/maintenance.lock`. That races with + # specs copying repositories with FileUtils.cp_r, causing flaky ENOENT + # failures. GIT_CONFIG_COUNT is available since Git 2.31 and silently + # ignored by older versions. + ENV["GIT_CONFIG_COUNT"] = "1" + ENV["GIT_CONFIG_KEY_0"] = "maintenance.auto" + ENV["GIT_CONFIG_VALUE_0"] = "false" + # Don't wrap output in tests ENV["THOR_COLUMNS"] = "10000" diff -Nru ruby3.3-3.3.8/spec/bundler/support/builders.rb ruby3.3-3.3.13/spec/bundler/support/builders.rb --- ruby3.3-3.3.8/spec/bundler/support/builders.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/bundler/support/builders.rb 2026-10-23 03:17:41.000000000 +0000 @@ -22,10 +22,6 @@ Gem::Platform.new(platform) end - def rake_version - "13.2.1" - end - def build_repo1 build_repo gem_repo1 do FileUtils.cp rake_path, "#{gem_repo1}/gems/" diff -Nru ruby3.3-3.3.8/spec/bundler/support/path.rb ruby3.3-3.3.13/spec/bundler/support/path.rb --- ruby3.3-3.3.8/spec/bundler/support/path.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/bundler/support/path.rb 2026-10-23 03:17:41.000000000 +0000 @@ -280,6 +280,10 @@ Dir["#{base_system_gems}/#{Bundler.ruby_scope}/**/rake*.gem"].first end + def rake_version + File.basename(rake_path).delete_prefix("rake-").delete_suffix(".gem") + end + private def git_ls_files(glob) diff -Nru ruby3.3-3.3.8/spec/ruby/core/file/atime_spec.rb ruby3.3-3.3.13/spec/ruby/core/file/atime_spec.rb --- ruby3.3-3.3.8/spec/ruby/core/file/atime_spec.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/ruby/core/file/atime_spec.rb 2026-10-23 03:17:41.000000000 +0000 @@ -27,6 +27,9 @@ else File.atime(__FILE__).usec.should == 0 end + rescue Errno::ENOENT => e + # Native Windows don't have stat command. + skip e.message end end end diff -Nru ruby3.3-3.3.8/spec/ruby/core/file/ctime_spec.rb ruby3.3-3.3.13/spec/ruby/core/file/ctime_spec.rb --- ruby3.3-3.3.8/spec/ruby/core/file/ctime_spec.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/ruby/core/file/ctime_spec.rb 2026-10-23 03:17:41.000000000 +0000 @@ -22,6 +22,9 @@ else File.ctime(__FILE__).usec.should == 0 end + rescue Errno::ENOENT => e + # Windows don't have stat command. + skip e.message end end diff -Nru ruby3.3-3.3.8/spec/ruby/core/file/mtime_spec.rb ruby3.3-3.3.13/spec/ruby/core/file/mtime_spec.rb --- ruby3.3-3.3.8/spec/ruby/core/file/mtime_spec.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/ruby/core/file/mtime_spec.rb 2026-10-23 03:17:41.000000000 +0000 @@ -26,6 +26,9 @@ else File.mtime(__FILE__).usec.should == 0 end + rescue Errno::ENOENT => e + # Windows don't have stat command. + skip e.message end end end diff -Nru ruby3.3-3.3.8/spec/ruby/core/kernel/shared/require.rb ruby3.3-3.3.13/spec/ruby/core/kernel/shared/require.rb --- ruby3.3-3.3.8/spec/ruby/core/kernel/shared/require.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/ruby/core/kernel/shared/require.rb 2026-10-23 03:17:41.000000000 +0000 @@ -223,7 +223,7 @@ it "loads c-extension file when passed absolute path without extension when no .rb is present" do # the error message is specific to what dlerror() returns path = File.join CODE_LOADING_DIR, "a", "load_fixture" - -> { @object.send(@method, path) }.should raise_error(Exception, /file too short|not a mach-o file/) + -> { @object.send(@method, path) }.should raise_error(LoadError) end end @@ -231,7 +231,7 @@ it "loads .bundle file when passed absolute path with .so" do # the error message is specific to what dlerror() returns path = File.join CODE_LOADING_DIR, "a", "load_fixture.so" - -> { @object.send(@method, path) }.should raise_error(Exception, /load_fixture\.bundle.+(file too short|not a mach-o file)/) + -> { @object.send(@method, path) }.should raise_error(LoadError) end end diff -Nru ruby3.3-3.3.8/spec/ruby/core/marshal/dump_spec.rb ruby3.3-3.3.13/spec/ruby/core/marshal/dump_spec.rb --- ruby3.3-3.3.8/spec/ruby/core/marshal/dump_spec.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/ruby/core/marshal/dump_spec.rb 2026-10-23 03:17:41.000000000 +0000 @@ -193,9 +193,12 @@ Marshal.dump(MarshalSpec::ClassWithOverriddenName).should == "\x04\bc)MarshalSpec::ClassWithOverriddenName" end - it "dumps a class with multibyte characters in name" do - source_object = eval("MarshalSpec::MultibyteぁあぃいClass".force_encoding(Encoding::UTF_8)) - Marshal.dump(source_object).should == "\x04\bc,MarshalSpec::Multibyte\xE3\x81\x81\xE3\x81\x82\xE3\x81\x83\xE3\x81\x84Class" + ruby_version_is "3.3" do + it "dumps a class with multibyte characters in name" do + source_object = eval("MarshalSpec::MultibyteぁあぃいClass".dup.force_encoding(Encoding::UTF_8)) + Marshal.dump(source_object).should == "\x04\bIc,MarshalSpec::Multibyte\xE3\x81\x81\xE3\x81\x82\xE3\x81\x83\xE3\x81\x84Class\x06:\x06ET" + Marshal.load(Marshal.dump(source_object)) == source_object + end end it "raises TypeError with an anonymous Class" do @@ -216,9 +219,12 @@ Marshal.dump(MarshalSpec::ModuleWithOverriddenName).should == "\x04\bc*MarshalSpec::ModuleWithOverriddenName" end - it "dumps a module with multibyte characters in name" do - source_object = eval("MarshalSpec::MultibyteけげこごModule".force_encoding(Encoding::UTF_8)) - Marshal.dump(source_object).should == "\x04\bm-MarshalSpec::Multibyte\xE3\x81\x91\xE3\x81\x92\xE3\x81\x93\xE3\x81\x94Module" + ruby_version_is "3.3" do + it "dumps a module with multibyte characters in name" do + source_object = eval("MarshalSpec::MultibyteけげこごModule".dup.force_encoding(Encoding::UTF_8)) + Marshal.dump(source_object).should == "\x04\bIm-MarshalSpec::Multibyte\xE3\x81\x91\xE3\x81\x92\xE3\x81\x93\xE3\x81\x94Module\x06:\x06ET" + Marshal.load(Marshal.dump(source_object)) == source_object + end end it "raises TypeError with an anonymous Module" do @@ -684,9 +690,12 @@ Marshal.dump(obj).should include("MarshalSpec::TimeWithOverriddenName") end - it "dumps a Time subclass with multibyte characters in name" do - source_object = eval("MarshalSpec::MultibyteぁあぃいTime".force_encoding(Encoding::UTF_8)) - Marshal.dump(source_object).should == "\x04\bc+MarshalSpec::Multibyte\xE3\x81\x81\xE3\x81\x82\xE3\x81\x83\xE3\x81\x84Time" + ruby_version_is "3.3" do + it "dumps a Time subclass with multibyte characters in name" do + source_object = eval("MarshalSpec::MultibyteぁあぃいTime".dup.force_encoding(Encoding::UTF_8)) + Marshal.dump(source_object).should == "\x04\bIc+MarshalSpec::Multibyte\xE3\x81\x81\xE3\x81\x82\xE3\x81\x83\xE3\x81\x84Time\x06:\x06ET" + Marshal.load(Marshal.dump(source_object)) == source_object + end end it "raises TypeError with an anonymous Time subclass" do diff -Nru ruby3.3-3.3.8/spec/ruby/core/math/lgamma_spec.rb ruby3.3-3.3.13/spec/ruby/core/math/lgamma_spec.rb --- ruby3.3-3.3.8/spec/ruby/core/math/lgamma_spec.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/ruby/core/math/lgamma_spec.rb 2026-10-23 03:17:41.000000000 +0000 @@ -5,10 +5,8 @@ Math.lgamma(0).should == [infinity_value, 1] end - platform_is_not :windows do - it "returns [Infinity, 1] when passed -1" do - Math.lgamma(-1).should == [infinity_value, 1] - end + it "returns [Infinity, ...] when passed -1" do + Math.lgamma(-1)[0].should == infinity_value end it "returns [Infinity, -1] when passed -0.0" do @@ -47,8 +45,7 @@ Math.lgamma(infinity_value).should == [infinity_value, 1] end - it "returns [NaN, 1] when passed NaN" do - Math.lgamma(nan_value)[0].nan?.should be_true - Math.lgamma(nan_value)[1].should == 1 + it "returns [NaN, ...] when passed NaN" do + Math.lgamma(nan_value)[0].should.nan? end end diff -Nru ruby3.3-3.3.8/spec/ruby/core/module/ruby2_keywords_spec.rb ruby3.3-3.3.13/spec/ruby/core/module/ruby2_keywords_spec.rb --- ruby3.3-3.3.8/spec/ruby/core/module/ruby2_keywords_spec.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/ruby/core/module/ruby2_keywords_spec.rb 2026-10-23 03:17:41.000000000 +0000 @@ -275,7 +275,7 @@ it "prints warning when a method accepts keywords" do obj = Object.new - def obj.foo(a:, b:) end + def obj.foo(*a, b:) end -> { obj.singleton_class.class_exec do @@ -286,7 +286,7 @@ it "prints warning when a method accepts keyword splat" do obj = Object.new - def obj.foo(**a) end + def obj.foo(*a, **b) end -> { obj.singleton_class.class_exec do @@ -294,4 +294,17 @@ end }.should complain(/Skipping set of ruby2_keywords flag for/) end + + ruby_version_is "3.5" do + it "prints warning when a method accepts post arguments" do + obj = Object.new + def obj.foo(*a, b) end + + -> { + obj.singleton_class.class_exec do + ruby2_keywords :foo + end + }.should complain(/Skipping set of ruby2_keywords flag for/) + end + end end diff -Nru ruby3.3-3.3.8/spec/ruby/core/proc/ruby2_keywords_spec.rb ruby3.3-3.3.13/spec/ruby/core/proc/ruby2_keywords_spec.rb --- ruby3.3-3.3.8/spec/ruby/core/proc/ruby2_keywords_spec.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/ruby/core/proc/ruby2_keywords_spec.rb 2026-10-23 03:17:41.000000000 +0000 @@ -39,7 +39,7 @@ end it "prints warning when a proc accepts keywords" do - f = -> a:, b: { } + f = -> *a, b: { } -> { f.ruby2_keywords @@ -47,10 +47,20 @@ end it "prints warning when a proc accepts keyword splat" do - f = -> **a { } + f = -> *a, **b { } -> { f.ruby2_keywords }.should complain(/Skipping set of ruby2_keywords flag for/) end + + ruby_version_is "3.5" do + it "prints warning when a proc accepts post arguments" do + f = -> *a, b { } + + -> { + f.ruby2_keywords + }.should complain(/Skipping set of ruby2_keywords flag for/) + end + end end diff -Nru ruby3.3-3.3.8/spec/ruby/core/process/daemon_spec.rb ruby3.3-3.3.13/spec/ruby/core/process/daemon_spec.rb --- ruby3.3-3.3.8/spec/ruby/core/process/daemon_spec.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/ruby/core/process/daemon_spec.rb 2026-10-23 03:17:41.000000000 +0000 @@ -2,6 +2,9 @@ require_relative 'fixtures/common' platform_is_not :windows do + # macOS 15 is not working this examples + return if /darwin/ =~ RUBY_PLATFORM && /15/ =~ `sw_vers -productVersion` + describe :process_daemon_keep_stdio_open_false, shared: true do it "redirects stdout to /dev/null" do @daemon.invoke("keep_stdio_open_false_stdout", @object).should == "" diff -Nru ruby3.3-3.3.8/spec/ruby/core/unboundmethod/equal_value_spec.rb ruby3.3-3.3.13/spec/ruby/core/unboundmethod/equal_value_spec.rb --- ruby3.3-3.3.8/spec/ruby/core/unboundmethod/equal_value_spec.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/ruby/core/unboundmethod/equal_value_spec.rb 2026-10-23 03:17:41.000000000 +0000 @@ -35,6 +35,12 @@ @method_one = UnboundMethodSpecs::Methods.instance_method(:one) @method_two = UnboundMethodSpecs::Methods.instance_method(:two) + + @mixin = UnboundMethodSpecs::Mixin.instance_method(:mixin_method) + @includer_base = UnboundMethodSpecs::IncluderBase.new.method(:mixin_method).unbind + @includer_child = UnboundMethodSpecs::IncluderChild.new.method(:mixin_method).unbind + @extender_base = UnboundMethodSpecs::ExtenderBase.method(:mixin_method).unbind + @extender_child = UnboundMethodSpecs::ExtenderChild.method(:mixin_method).unbind end it "returns true if objects refer to the same method" do @@ -110,6 +116,30 @@ end end + ruby_bug "#21873", ""..."3.3" do + it "returns true if same method is present in an object through module inclusion" do + (@mixin == @includer_base).should == true + (@includer_base == @mixin).should == true + + (@mixin == @includer_child).should == true + (@includer_child == @mixin).should == true + + (@includer_base == @includer_child).should == true + (@includer_child == @includer_base).should == true + end + + it "returns true if same method is present in an object through module extension" do + (@mixin == @extender_base).should == true + (@extender_base == @mixin).should == true + + (@mixin == @extender_child).should == true + (@extender_child == @mixin).should == true + + (@extender_base == @extender_child).should == true + (@extender_child == @extender_base).should == true + end + end + it "returns false if both have same Module, same name, identical body but not the same" do class UnboundMethodSpecs::Methods def discard_1; :discard; end diff -Nru ruby3.3-3.3.8/spec/ruby/core/unboundmethod/fixtures/classes.rb ruby3.3-3.3.13/spec/ruby/core/unboundmethod/fixtures/classes.rb --- ruby3.3-3.3.8/spec/ruby/core/unboundmethod/fixtures/classes.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/ruby/core/unboundmethod/fixtures/classes.rb 2026-10-23 03:17:41.000000000 +0000 @@ -80,6 +80,22 @@ end end + module Mixin + def mixin_method; end + end + + class IncluderBase + include Mixin + end + + class IncluderChild < IncluderBase; end + + class ExtenderBase + extend Mixin + end + + class ExtenderChild < ExtenderBase; end + class A def baz(a, b) return [__FILE__, self.class] diff -Nru ruby3.3-3.3.8/spec/ruby/library/uri/set_component_spec.rb ruby3.3-3.3.13/spec/ruby/library/uri/set_component_spec.rb --- ruby3.3-3.3.8/spec/ruby/library/uri/set_component_spec.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/ruby/library/uri/set_component_spec.rb 2026-10-23 03:17:41.000000000 +0000 @@ -6,25 +6,27 @@ it "conforms to the MatzRuby tests" do uri = URI.parse('http://foo:bar@baz') (uri.user = 'oof').should == 'oof' - uri.to_s.should == 'http://oof:bar@baz' - (uri.password = 'rab').should == 'rab' - uri.to_s.should == 'http://oof:rab@baz' - (uri.userinfo = 'foo').should == 'foo' - uri.to_s.should == 'http://foo:rab@baz' - (uri.userinfo = ['foo', 'bar']).should == ['foo', 'bar'] - uri.to_s.should == 'http://foo:bar@baz' - (uri.userinfo = ['foo']).should == ['foo'] - uri.to_s.should == 'http://foo:bar@baz' - (uri.host = 'zab').should == 'zab' - uri.to_s.should == 'http://foo:bar@zab' - (uri.port = 8080).should == 8080 - uri.to_s.should == 'http://foo:bar@zab:8080' - (uri.path = '/').should == '/' - uri.to_s.should == 'http://foo:bar@zab:8080/' - (uri.query = 'a=1').should == 'a=1' - uri.to_s.should == 'http://foo:bar@zab:8080/?a=1' - (uri.fragment = 'b123').should == 'b123' - uri.to_s.should == 'http://foo:bar@zab:8080/?a=1#b123' + version_is(URI::VERSION, "0.13.3") do + uri.to_s.should == 'http://oof@baz' + (uri.password = 'rab').should == 'rab' + uri.to_s.should == 'http://oof:rab@baz' + (uri.userinfo = 'foo').should == 'foo' + uri.to_s.should == 'http://foo@baz' + (uri.userinfo = ['foo', 'bar']).should == ['foo', 'bar'] + uri.to_s.should == 'http://foo:bar@baz' + (uri.userinfo = ['foo']).should == ['foo'] + uri.to_s.should == 'http://foo@baz' + (uri.host = 'zab').should == 'zab' + uri.to_s.should == 'http://zab' + (uri.port = 8080).should == 8080 + uri.to_s.should == 'http://zab:8080' + (uri.path = '/').should == '/' + uri.to_s.should == 'http://zab:8080/' + (uri.query = 'a=1').should == 'a=1' + uri.to_s.should == 'http://zab:8080/?a=1' + (uri.fragment = 'b123').should == 'b123' + uri.to_s.should == 'http://zab:8080/?a=1#b123' + end uri = URI.parse('http://example.com') -> { uri.password = 'bar' }.should raise_error(URI::InvalidURIError) diff -Nru ruby3.3-3.3.8/spec/syntax_suggest/integration/syntax_suggest_spec.rb ruby3.3-3.3.13/spec/syntax_suggest/integration/syntax_suggest_spec.rb --- ruby3.3-3.3.8/spec/syntax_suggest/integration/syntax_suggest_spec.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/syntax_suggest/integration/syntax_suggest_spec.rb 2026-10-23 03:17:41.000000000 +0000 @@ -4,6 +4,10 @@ module SyntaxSuggest RSpec.describe "Integration tests that don't spawn a process (like using the cli)" do + before(:each) do + skip "Benchmark is not available" unless defined?(::Benchmark) + end + it "does not timeout on massive files" do next unless ENV["SYNTAX_SUGGEST_TIMEOUT"] diff -Nru ruby3.3-3.3.8/spec/syntax_suggest/spec_helper.rb ruby3.3-3.3.13/spec/syntax_suggest/spec_helper.rb --- ruby3.3-3.3.8/spec/syntax_suggest/spec_helper.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/spec/syntax_suggest/spec_helper.rb 2026-10-23 03:17:41.000000000 +0000 @@ -3,7 +3,10 @@ require "bundler/setup" require "syntax_suggest/api" -require "benchmark" +begin + require "benchmark" +rescue LoadError +end require "tempfile" RSpec.configure do |config| diff -Nru ruby3.3-3.3.8/spec/syntax_suggest/unit/mini_stringio_spec.rb ruby3.3-3.3.13/spec/syntax_suggest/unit/mini_stringio_spec.rb --- ruby3.3-3.3.8/spec/syntax_suggest/unit/mini_stringio_spec.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/spec/syntax_suggest/unit/mini_stringio_spec.rb 2026-10-23 03:17:41.000000000 +0000 @@ -0,0 +1,25 @@ +# frozen_string_literal: true + +require_relative "../spec_helper" + +module SyntaxSuggest + RSpec.describe "MiniStringIO" do + it "#puts with no inputs" do + io = MiniStringIO.new + io.puts + expect(io.string).to eq($/) + end + + it "#puts with an input" do + io = MiniStringIO.new + io.puts "Hello" + expect(io.string).to eq(["Hello", $/].join) + end + + it "#puts with an input with a newline" do + io = MiniStringIO.new + io.puts "Hello\n" + expect(io.string).to eq(["Hello\n", $/].join) + end + end +end diff -Nru ruby3.3-3.3.8/st.c ruby3.3-3.3.13/st.c --- ruby3.3-3.3.8/st.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/st.c 2026-10-23 03:17:41.000000000 +0000 @@ -1482,7 +1482,16 @@ value = entry->record; } old_key = key; + + unsigned int rebuilds_num = tab->rebuilds_num; + retval = (*func)(&key, &value, arg, existing); + + // We need to make sure that the callback didn't cause a table rebuild + // Ideally we would make sure no operations happened + assert(rebuilds_num == tab->rebuilds_num); + (void)rebuilds_num; + switch (retval) { case ST_CONTINUE: if (! existing) { diff -Nru ruby3.3-3.3.8/string.c ruby3.3-3.3.13/string.c --- ruby3.3-3.3.8/string.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/string.c 2026-10-23 03:17:41.000000000 +0000 @@ -44,6 +44,7 @@ #include "ruby/util.h" #include "ruby_assert.h" #include "vm_sync.h" +#include "ruby/internal/attr/nonstring.h" #if defined HAVE_CRYPT_R # if defined HAVE_CRYPT_H @@ -485,14 +486,14 @@ VALUE rb_fstring_new(const char *ptr, long len) { - struct RString fake_str; + struct RString fake_str = {RBASIC_INIT}; return register_fstring(setup_fake_str(&fake_str, ptr, len, ENCINDEX_US_ASCII), FALSE); } VALUE rb_fstring_enc_new(const char *ptr, long len, rb_encoding *enc) { - struct RString fake_str; + struct RString fake_str = {RBASIC_INIT}; return register_fstring(rb_setup_fake_str(&fake_str, ptr, len, enc), FALSE); } @@ -544,7 +545,7 @@ static inline const char * search_nonascii(const char *p, const char *e) { - const uintptr_t *s, *t; + const char *s, *t; #if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L) # if SIZEOF_UINTPTR_T == 8 @@ -588,17 +589,19 @@ #define aligned_ptr(value) \ __builtin_assume_aligned((value), sizeof(uintptr_t)) #else -#define aligned_ptr(value) (uintptr_t *)(value) +#define aligned_ptr(value) (value) #endif s = aligned_ptr(p); - t = (uintptr_t *)(e - (SIZEOF_VOIDP-1)); + t = (e - (SIZEOF_VOIDP-1)); #undef aligned_ptr - for (;s < t; s++) { - if (*s & NONASCII_MASK) { + for (;s < t; s += sizeof(uintptr_t)) { + uintptr_t word; + memcpy(&word, s, sizeof(word)); + if (word & NONASCII_MASK) { #ifdef WORDS_BIGENDIAN - return (const char *)s + (nlz_intptr(*s&NONASCII_MASK)>>3); + return (const char *)s + (nlz_intptr(word&NONASCII_MASK)>>3); #else - return (const char *)s + (ntz_intptr(*s&NONASCII_MASK)>>3); + return (const char *)s + (ntz_intptr(word&NONASCII_MASK)>>3); #endif } } @@ -2406,7 +2409,9 @@ VALUE tmp = rb_check_array_type(arg); if (!NIL_P(tmp)) { - return rb_str_format(RARRAY_LENINT(tmp), RARRAY_CONST_PTR(tmp), str); + VALUE result = rb_str_format(RARRAY_LENINT(tmp), RARRAY_CONST_PTR(tmp), str); + RB_GC_GUARD(tmp); + return result; } return rb_str_format(1, &arg, str); } @@ -8813,11 +8818,15 @@ } } -#define SPLIT_STR(beg, len) (empty_count = split_string(result, str, beg, len, empty_count)) +#define SPLIT_STR(beg, len) ( \ + empty_count = split_string(result, str, beg, len, empty_count), \ + str_mod_check(str, str_start, str_len)) beg = 0; char *ptr = RSTRING_PTR(str); - char *eptr = RSTRING_END(str); + char *const str_start = ptr; + const long str_len = RSTRING_LEN(str); + char *const eptr = str_start + str_len; if (split_type == SPLIT_TYPE_AWK) { char *bptr = ptr; int skip = 1; @@ -8878,7 +8887,6 @@ } } else if (split_type == SPLIT_TYPE_STRING) { - char *str_start = ptr; char *substr_start = ptr; char *sptr = RSTRING_PTR(spat); long slen = RSTRING_LEN(spat); @@ -8895,6 +8903,7 @@ continue; } SPLIT_STR(substr_start - str_start, (ptr+end) - substr_start); + str_mod_check(spat, sptr, slen); ptr += end + slen; substr_start = ptr; if (!NIL_P(limit) && lim <= ++i) break; @@ -8902,7 +8911,6 @@ beg = ptr - str_start; } else if (split_type == SPLIT_TYPE_CHARS) { - char *str_start = ptr; int n; if (result) result = rb_ary_new_capa(RSTRING_LEN(str)); @@ -11120,7 +11128,7 @@ encidx = rb_enc_to_index(enc); #define DEFAULT_REPLACE_CHAR(str) do { \ - static const char replace[sizeof(str)-1] = str; \ + RBIMPL_ATTR_NONSTRING() static const char replace[sizeof(str)-1] = str; \ rep = replace; replen = (int)sizeof(replace); \ } while (0) @@ -12080,7 +12088,7 @@ VALUE rb_interned_str(const char *ptr, long len) { - struct RString fake_str; + struct RString fake_str = {RBASIC_INIT}; return register_fstring(setup_fake_str(&fake_str, ptr, len, ENCINDEX_US_ASCII), TRUE); } @@ -12097,7 +12105,7 @@ rb_enc_autoload(enc); } - struct RString fake_str; + struct RString fake_str = {RBASIC_INIT}; return register_fstring(rb_setup_fake_str(&fake_str, ptr, len, enc), TRUE); } diff -Nru ruby3.3-3.3.8/struct.c ruby3.3-3.3.13/struct.c --- ruby3.3-3.3.8/struct.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/struct.c 2026-10-23 03:17:41.000000000 +0000 @@ -52,7 +52,8 @@ RUBY_ASSERT(RB_TYPE_P(c, T_CLASS)); ivar = rb_attr_get(c, id); if (!NIL_P(ivar)) { - return rb_ivar_set(orig, id, ivar); + if (!OBJ_FROZEN(orig)) rb_ivar_set(orig, id, ivar); + return ivar; } } } @@ -1784,6 +1785,7 @@ if (num_members > 0) { rb_exc_raise(rb_keyword_error_new("missing", members)); } + OBJ_FREEZE(self); return Qnil; } if (argc > 1 || !RB_TYPE_P(argv[0], T_HASH)) { diff -Nru ruby3.3-3.3.8/symbol.c ruby3.3-3.3.13/symbol.c --- ruby3.3-3.3.8/symbol.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/symbol.c 2026-10-23 03:17:41.000000000 +0000 @@ -22,6 +22,7 @@ #include "symbol.h" #include "vm_sync.h" #include "builtin.h" +#include "ruby/internal/attr/nonstring.h" #if defined(USE_SYMBOL_GC) && !(USE_SYMBOL_GC+0) # undef USE_SYMBOL_GC @@ -735,7 +736,7 @@ rb_intern3(const char *name, long len, rb_encoding *enc) { VALUE sym; - struct RString fake_str; + struct RString fake_str = {RBASIC_INIT}; VALUE str = rb_setup_fake_str(&fake_str, name, len, enc); OBJ_FREEZE(str); sym = lookup_str_sym(str); @@ -1190,7 +1191,7 @@ ID rb_check_id_cstr(const char *ptr, long len, rb_encoding *enc) { - struct RString fake_str; + struct RString fake_str = {RBASIC_INIT}; const VALUE name = rb_setup_fake_str(&fake_str, ptr, len, enc); sym_check_asciionly(name, true); @@ -1202,7 +1203,7 @@ rb_check_symbol_cstr(const char *ptr, long len, rb_encoding *enc) { VALUE sym; - struct RString fake_str; + struct RString fake_str = {RBASIC_INIT}; const VALUE name = rb_setup_fake_str(&fake_str, ptr, len, enc); sym_check_asciionly(name, true); @@ -1226,7 +1227,7 @@ VALUE rb_sym_intern(const char *ptr, long len, rb_encoding *enc) { - struct RString fake_str; + struct RString fake_str = {RBASIC_INIT}; const VALUE name = rb_setup_fake_str(&fake_str, ptr, len, enc); return rb_str_intern(name); } diff -Nru ruby3.3-3.3.8/template/Makefile.in ruby3.3-3.3.13/template/Makefile.in --- ruby3.3-3.3.8/template/Makefile.in 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/template/Makefile.in 2026-10-23 03:17:41.000000000 +0000 @@ -74,7 +74,8 @@ EXTOUT = @EXTOUT@ TIMESTAMPDIR = $(EXTOUT)/.timestamp -arch_hdrdir = $(EXTOUT)/include/$(arch) +ext_hdrdir = $(EXTOUT)/include +arch_hdrdir = $(ext_hdrdir)/$(arch) VPATH = $(arch_hdrdir)/ruby:$(hdrdir)/ruby:$(srcdir):$(srcdir)/missing empty = @@ -324,7 +325,8 @@ @-[ -n "$(EXTSTATIC)" ] || $(PRE_LIBRUBY_UPDATE) $(ECHO) linking shared-library $@ $(Q) $(LDSHARED) $(DLDFLAGS) $(OBJS) $(DLDOBJS) $(SOLIBS) $(EXTSOLIBS) $(OUTFLAG)$@ - -$(Q) $(OBJCOPY) -w -L '$(SYMBOL_PREFIX)Init_*' -L '$(SYMBOL_PREFIX)ruby_static_id_*' \ + -$(Q) $(OBJCOPY) -w -L '$(SYMBOL_PREFIX)Init_*' -L '$(SYMBOL_PREFIX)InitVM_*' \ + -L '$(SYMBOL_PREFIX)ruby_static_id_*' \ -L '$(SYMBOL_PREFIX)*_threadptr_*' -L '$(SYMBOL_PREFIX)*_ec_*' $@ $(Q) $(POSTLINK) @-$(MINIRUBY) -e 'so, *aliases = ARGV; aliases.uniq!; aliases.delete(File.basename(so)); \ @@ -337,13 +339,40 @@ PKG_CONFIG = @PKG_CONFIG@ ruby_pc = @ruby_pc@ $(ruby_pc): config.status Makefile - $(Q)./config.status --file=-:$(srcdir)/template/ruby.pc.in | \ + $(Q) \ + pkg="$(@libdirname@)/pkgconfig" prefix="$(prefix)"; \ + if [ "$(LIBRUBY_RELATIVE)" = yes ]; then \ + case "$$pkg" in "$$prefix"/?*) \ + pkg="$${pkg#$$prefix/}"; \ + prefix='$${pcfiledir}'`echo "/$${pkg}" | sed -e 's|/[^/][^/]*|/..|g'`; \ + esac; \ + fi; \ + ./config.status --file=-:$(srcdir)/template/ruby.pc.in | \ sed -e 's/\$$(\([A-Za-z_][A-Za-z0-9_]*\))/$${\1}/g' \ - -e 's|^prefix=.*|prefix=$(prefix)|' \ + -e "s|^prefix=.*|prefix=$$prefix|" \ > ruby.tmp.pc $(Q)pkg_config=${PKG_CONFIG} && PKG_CONFIG_PATH=. $${pkg_config:-:} --print-errors ruby.tmp $(Q)$(MV) -f ruby.tmp.pc $(ruby_pc) +test-pc: install-data + set -ex; \ + [ -z "$${pkg_config=$(PKG_CONFIG)}" ] && exit; \ + export PKG_CONFIG_PATH=$(DESTDIR)/$(libdir)/pkgconfig$${PKG_CONFIG_PATH:+:$$PKG_CONFIG_PATH}; \ + $${pkg_config} --exists $(ruby_pc:.pc=); \ + path=`$${pkg_config} --variable=prefix $(ruby_pc:.pc=)`; \ + if [ "$(LIBRUBY_RELATIVE)" = yes ]; then \ + test "$$path" -ef "$(DESTDIR)$(prefix)"; \ + else \ + test "$$path" = "$(prefix)"; \ + fi + +install-data: pkgconfig-data pre-install-data do-install-data post-install-data +pre-install-data:: install-prereq +do-install-data: $(PREP) pre-install-data + $(INSTRUBY) --make="$(MAKE)" $(INSTRUBY_ARGS) --install=data +post-install-data:: + @$(NULLCMD) + pre-install-local:: pkgconfig-data ruby-runner.h: template/ruby-runner.h.in config.status @@ -416,7 +445,7 @@ $(CP) $(srcdir)/lex.c.blt $@; \ else \ [ $(Q) ] && echo generating $@ || set -x; \ - gperf -C -P -p -j1 -i 1 -g -o -t -N rb_reserved_word -k1,3,$$ $? \ + gperf -C -L ANSI-C -P -p -j1 -i 1 -g -o -t -N rb_reserved_word -k1,3,$$ $? \ | sed -f $(tooldir)/gperf.sed \ > $@.tmp && \ $(MV) $@.tmp $@ && \ @@ -424,7 +453,7 @@ $(CP) $@ $(srcdir)/lex.c.blt; \ fi -JIS_PROPS_OPTIONS = -k1,3 -7 -c -j1 -i1 -t -C -P -t --ignore-case -H onig_jis_property_hash -Q onig_jis_property_pool -N onig_jis_property +JIS_PROPS_OPTIONS = -L ANSI-C -k1,3 -7 -c -j1 -i1 -t -C -P -t --ignore-case -H onig_jis_property_hash -Q onig_jis_property_pool -N onig_jis_property $(srcdir)/enc/jis/props.h: enc/jis/props.kwd $(MAKEDIRS) $(@D) @@ -647,3 +676,28 @@ PLATFORM=$(hdrdir)/ruby/$(PLATFORM_DIR).h $(srcdir)/configure.ac \ $(COMMONOBJS) $(LIBRUBY_FOR_LEAKED_GLOBALS:yes=$(LIBRUBY_SO)) $(ACTIONS_ENDGROUP) + +test-syntax-suggest-precheck: $(TEST_RUNNABLE)-test-syntax-suggest-precheck +no-test-syntax-suggest-precheck: +yes-test-syntax-suggest-precheck: main + +test-syntax-suggest-prepare: $(TEST_RUNNABLE)-test-syntax-suggest-prepare +no-test-syntax-suggest-prepare: no-test-syntax-suggest-precheck +yes-test-syntax-suggest-prepare: yes-test-syntax-suggest-precheck + $(ACTIONS_GROUP) + $(XRUBY) -C "$(srcdir)" bin/gem install --no-document \ + --install-dir .bundle --conservative "rspec:~> 3" + $(ACTIONS_ENDGROUP) + +RSPECOPTS = +SYNTAX_SUGGEST_SPECS = +PREPARE_SYNTAX_SUGGEST = $(TEST_RUNNABLE)-test-syntax-suggest-prepare +test-syntax-suggest: $(TEST_RUNNABLE)-test-syntax-suggest +yes-test-syntax-suggest: $(PREPARE_SYNTAX_SUGGEST) + $(ACTIONS_GROUP) + $(XRUBY) -C $(srcdir) -Ispec/syntax_suggest:spec/lib .bundle/bin/rspec \ + --require rspec/expectations \ + --require spec_helper --require formatter_overrides --require spec_coverage \ + $(RSPECOPTS) spec/syntax_suggest/$(SYNTAX_SUGGEST_SPECS) + $(ACTIONS_ENDGROUP) +no-test-syntax-suggest: diff -Nru ruby3.3-3.3.8/template/fake.rb.in ruby3.3-3.3.13/template/fake.rb.in --- ruby3.3-3.3.8/template/fake.rb.in 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/template/fake.rb.in 2026-10-23 03:17:41.000000000 +0000 @@ -9,6 +9,7 @@ end if inc = arg['i'] src = inc == '-' ? STDIN.read : File.read(inc) + src.tr!("\r", " ") src.gsub!(/^#.*\n/, '') else src = "" diff -Nru ruby3.3-3.3.8/template/id.c.tmpl ruby3.3-3.3.13/template/id.c.tmpl --- ruby3.3-3.3.8/template/id.c.tmpl 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/template/id.c.tmpl 2026-10-23 03:17:41.000000000 +0000 @@ -22,7 +22,8 @@ static const struct { unsigned short token; - const char name[3], term; + RBIMPL_ATTR_NONSTRING() const char name[3]; + const char term; } op_tbl[] = { % ops.each do |_id, op, token| % next unless token diff -Nru ruby3.3-3.3.8/template/prelude.c.tmpl ruby3.3-3.3.13/template/prelude.c.tmpl --- ruby3.3-3.3.8/template/prelude.c.tmpl 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/template/prelude.c.tmpl 2026-10-23 03:17:41.000000000 +0000 @@ -93,6 +93,7 @@ #include "internal/ruby_parser.h" #include "internal/warnings.h" #include "iseq.h" +#include "ruby/internal/attr/nonstring.h" #include "ruby/ruby.h" #include "vm_core.h" @@ -112,12 +113,12 @@ % size += line.size % next % end - char L<%=beg%><%=%>[<%=size%><%=%>]; /* <%=beg+1%>..<%=n%> */ + RBIMPL_ATTR_NONSTRING() char L<%=beg%><%=%>[<%=size%><%=%>]; /* <%=beg+1%>..<%=n%> */ % size = line.size % beg = n % } % if size > 0 - char L<%=beg%><%=%>[<%=size%><%=%>]; /* <%=beg+1%>..<%=lines.size+1%> */ + RBIMPL_ATTR_NONSTRING() char L<%=beg%><%=%>[<%=size%><%=%>]; /* <%=beg+1%>..<%=lines.size+1%> */ % end } prelude_code<%=i%><%=%> = { % size = 0 diff -Nru ruby3.3-3.3.8/test/-ext-/bug_reporter/test_bug_reporter.rb ruby3.3-3.3.13/test/-ext-/bug_reporter/test_bug_reporter.rb --- ruby3.3-3.3.8/test/-ext-/bug_reporter/test_bug_reporter.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/-ext-/bug_reporter/test_bug_reporter.rb 2026-10-23 03:17:41.000000000 +0000 @@ -5,6 +5,8 @@ class TestBugReporter < Test::Unit::TestCase def test_bug_reporter_add + pend "macOS 15 is not working with this test" if macos?(15) + omit "flaky with RJIT" if JITSupport.rjit_enabled? description = RUBY_DESCRIPTION description = description.sub(/\+PRISM /, '') unless EnvUtil.invoke_ruby(["-v"], "", true, false)[0].include?("+PRISM") diff -Nru ruby3.3-3.3.8/test/-ext-/debug/test_debug.rb ruby3.3-3.3.13/test/-ext-/debug/test_debug.rb --- ruby3.3-3.3.8/test/-ext-/debug/test_debug.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/-ext-/debug/test_debug.rb 2026-10-23 03:17:41.000000000 +0000 @@ -72,4 +72,19 @@ end assert_equal true, x, '[Bug #15105]' end + + # This is a YJIT test, but we can't test this without a C extension that calls + # rb_debug_inspector_open(), so we're testing it using "-test-/debug" here. + def test_yjit_invalidates_setlocal_after_inspector_call + val = setlocal_after_proc_call(proc { Bug::Debug.inspector; :ok }) + assert_equal :ok, val + end if defined?(RubyVM::YJIT) && RubyVM::YJIT.enabled? + + private + + def setlocal_after_proc_call(block) + local = block.call # setlocal followed by OPTIMIZED_METHOD_TYPE_CALL + itself # split a block using a C call + local # getlocal + end end diff -Nru ruby3.3-3.3.8/test/coverage/test_coverage.rb ruby3.3-3.3.13/test/coverage/test_coverage.rb --- ruby3.3-3.3.8/test/coverage/test_coverage.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/coverage/test_coverage.rb 2026-10-23 03:17:41.000000000 +0000 @@ -181,6 +181,23 @@ end; end + def test_eval_negative_lineno + assert_in_out_err(["-rcoverage"], <<-"end;", ["[1, 1, 1]"], []) + Coverage.start(eval: true, lines: true) + + eval(<<-RUBY, TOPLEVEL_BINDING, "test.rb", -2) + p # -2 # Not subject to measurement + p # -1 # Not subject to measurement + p # 0 # Not subject to measurement + p # 1 # Subject to measurement + p # 2 # Subject to measurement + p # 3 # Subject to measurement + RUBY + + p Coverage.result["test.rb"][:lines] + end; + end + def test_coverage_supported assert Coverage.supported?(:lines) assert Coverage.supported?(:oneshot_lines) diff -Nru ruby3.3-3.3.8/test/date/test_date.rb ruby3.3-3.3.13/test/date/test_date.rb --- ruby3.3-3.3.8/test/date/test_date.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/date/test_date.rb 2026-10-23 03:17:41.000000000 +0000 @@ -135,6 +135,10 @@ assert_equal(9, h[DateTime.new(1999,5,25)]) h = {} + h[Date.new(3171505571716611468830131104691,2,19)] = 0 + assert_equal(true, h.key?(Date.new(3171505571716611468830131104691,2,19))) + + h = {} h[DateTime.new(1999,5,23)] = 0 h[DateTime.new(1999,5,24)] = 1 h[DateTime.new(1999,5,25)] = 2 diff -Nru ruby3.3-3.3.8/test/erb/test_erb.rb ruby3.3-3.3.13/test/erb/test_erb.rb --- ruby3.3-3.3.8/test/erb/test_erb.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/erb/test_erb.rb 2026-10-23 03:17:41.000000000 +0000 @@ -714,6 +714,33 @@ assert_raise(ArgumentError) {erb.result} end + def test_prohibited_marshal_load_def_method + erb = ERB.allocate + erb.instance_variable_set(:@src, "") + erb.instance_variable_set(:@lineno, 1) + erb.instance_variable_set(:@_init, true) + erb = Marshal.load(Marshal.dump(erb)) + assert_raise(ArgumentError) {erb.def_method(Class.new, 'render')} + end + + def test_prohibited_marshal_load_def_module + erb = ERB.allocate + erb.instance_variable_set(:@src, "") + erb.instance_variable_set(:@lineno, 1) + erb.instance_variable_set(:@_init, true) + erb = Marshal.load(Marshal.dump(erb)) + assert_raise(ArgumentError) {erb.def_module} + end + + def test_prohibited_marshal_load_def_class + erb = ERB.allocate + erb.instance_variable_set(:@src, "") + erb.instance_variable_set(:@lineno, 1) + erb.instance_variable_set(:@_init, true) + erb = Marshal.load(Marshal.dump(erb)) + assert_raise(ArgumentError) {erb.def_class} + end + def test_multi_line_comment_lineno erb = ERB.new(<<~EOS) <%= __LINE__ %> diff -Nru ruby3.3-3.3.8/test/io/wait/test_io_wait_uncommon.rb ruby3.3-3.3.13/test/io/wait/test_io_wait_uncommon.rb --- ruby3.3-3.3.8/test/io/wait/test_io_wait_uncommon.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/io/wait/test_io_wait_uncommon.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1,5 +1,6 @@ # frozen_string_literal: true require 'test/unit' +require 'io/wait' # test uncommon device types to check portability problems # We may optimize IO#wait_*able for non-Linux kernels in the future @@ -74,4 +75,33 @@ def test_wait_writable_null check_dev(IO::NULL, :wait_writable) end + + def test_after_ungetc_ready? + check_dev(IO::NULL, mode: "r") {|fp| + assert_respond_to fp, :ready? + fp.ungetc(?a) + assert_predicate fp, :ready? + } + end + + def test_after_ungetc_wait_readable + check_dev(IO::NULL, mode: "r") {|fp| + fp.ungetc(?a) + assert_predicate fp, :wait_readable + } + end + + def test_after_ungetc_in_text_ready? + check_dev(IO::NULL, mode: "rt") {|fp| + fp.ungetc(?a) + assert_predicate fp, :ready? + } + end + + def test_after_ungetc_in_text_wait_readable + check_dev(IO::NULL, mode: "rt") {|fp| + fp.ungetc(?a) + assert_predicate fp, :wait_readable + } + end end diff -Nru ruby3.3-3.3.8/test/openssl/test_asn1.rb ruby3.3-3.3.13/test/openssl/test_asn1.rb --- ruby3.3-3.3.8/test/openssl/test_asn1.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/openssl/test_asn1.rb 2026-10-23 03:17:41.000000000 +0000 @@ -326,7 +326,9 @@ oid = (0...100).to_a.join(".").b obj = OpenSSL::ASN1::ObjectId.new(oid) assert_equal oid, obj.oid + end + def test_object_identifier_equality aki = [ OpenSSL::ASN1::ObjectId.new("authorityKeyIdentifier"), OpenSSL::ASN1::ObjectId.new("X509v3 Authority Key Identifier"), @@ -341,17 +343,22 @@ aki.each do |a| aki.each do |b| - assert a == b + assert_equal true, a == b end ski.each do |b| - refute a == b + assert_equal false, a == b end end - assert_raise(TypeError) { - OpenSSL::ASN1::ObjectId.new("authorityKeyIdentifier") == nil - } + obj1 = OpenSSL::ASN1::ObjectId.new("1.2.34.56789.10") + obj2 = OpenSSL::ASN1::ObjectId.new("1.2.34.56789.10") + obj3 = OpenSSL::ASN1::ObjectId.new("1.2.34.56789.11") + omit "OID 1.2.34.56789.10 is registered" if obj1.sn + assert_equal true, obj1 == obj2 + assert_equal false, obj1 == obj3 + + assert_equal false, OpenSSL::ASN1::ObjectId.new("authorityKeyIdentifier") == nil end def test_sequence diff -Nru ruby3.3-3.3.8/test/openssl/test_bn.rb ruby3.3-3.3.13/test/openssl/test_bn.rb --- ruby3.3-3.3.8/test/openssl/test_bn.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/openssl/test_bn.rb 2026-10-23 03:17:41.000000000 +0000 @@ -343,28 +343,36 @@ assert_equal(4, e.get_flags(OpenSSL::BN::CONSTTIME)) end - if respond_to?(:ractor) + if defined?(Ractor) && respond_to?(:ractor) + unless Ractor.method_defined?(:value) # Ruby 3.4 or earlier + using Module.new { + refine Ractor do + alias value take + end + } + end + ractor def test_ractor - assert_equal(@e1, Ractor.new { OpenSSL::BN.new("999") }.take) - assert_equal(@e3, Ractor.new { OpenSSL::BN.new("\a\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF", 2) }.take) - assert_equal("999", Ractor.new(@e1) { |e1| e1.to_s }.take) - assert_equal("07FFFFFFFFFFFFFFFFFFFFFFFFFF", Ractor.new(@e3) { |e3| e3.to_s(16) }.take) - assert_equal(2**107-1, Ractor.new(@e3) { _1.to_i }.take) - assert_equal([1000, -999], Ractor.new(@e2) { _1.coerce(1000) }.take) - assert_equal(false, Ractor.new { 1.to_bn.zero? }.take) - assert_equal(true, Ractor.new { 1.to_bn.one? }.take) - assert_equal(true, Ractor.new(@e2) { _1.negative? }.take) - assert_equal("-03E7", Ractor.new(@e2) { _1.to_s(16) }.take) - assert_equal(2**107-1, Ractor.new(@e3) { _1.to_i }.take) - assert_equal([1000, -999], Ractor.new(@e2) { _1.coerce(1000) }.take) - assert_equal(true, Ractor.new { 0.to_bn.zero? }.take) - assert_equal(true, Ractor.new { 1.to_bn.one? }.take ) - assert_equal(false,Ractor.new { 2.to_bn.odd? }.take) - assert_equal(true, Ractor.new(@e2) { _1.negative? }.take) - assert_include(128..255, Ractor.new { OpenSSL::BN.rand(8)}.take) - assert_include(0...2**32, Ractor.new { OpenSSL::BN.generate_prime(32) }.take) - assert_equal(0, Ractor.new { OpenSSL::BN.new(999).get_flags(OpenSSL::BN::CONSTTIME) }.take) + assert_equal(@e1, Ractor.new { OpenSSL::BN.new("999") }.value) + assert_equal(@e3, Ractor.new { OpenSSL::BN.new("\a\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF", 2) }.value) + assert_equal("999", Ractor.new(@e1) { |e1| e1.to_s }.value) + assert_equal("07FFFFFFFFFFFFFFFFFFFFFFFFFF", Ractor.new(@e3) { |e3| e3.to_s(16) }.value) + assert_equal(2**107-1, Ractor.new(@e3) { _1.to_i }.value) + assert_equal([1000, -999], Ractor.new(@e2) { _1.coerce(1000) }.value) + assert_equal(false, Ractor.new { 1.to_bn.zero? }.value) + assert_equal(true, Ractor.new { 1.to_bn.one? }.value) + assert_equal(true, Ractor.new(@e2) { _1.negative? }.value) + assert_equal("-03E7", Ractor.new(@e2) { _1.to_s(16) }.value) + assert_equal(2**107-1, Ractor.new(@e3) { _1.to_i }.value) + assert_equal([1000, -999], Ractor.new(@e2) { _1.coerce(1000) }.value) + assert_equal(true, Ractor.new { 0.to_bn.zero? }.value) + assert_equal(true, Ractor.new { 1.to_bn.one? }.value ) + assert_equal(false,Ractor.new { 2.to_bn.odd? }.value) + assert_equal(true, Ractor.new(@e2) { _1.negative? }.value) + assert_include(128..255, Ractor.new { OpenSSL::BN.rand(8)}.value) + assert_include(0...2**32, Ractor.new { OpenSSL::BN.generate_prime(32) }.value) + assert_equal(0, Ractor.new { OpenSSL::BN.new(999).get_flags(OpenSSL::BN::CONSTTIME) }.value) end end end diff -Nru ruby3.3-3.3.8/test/openssl/test_cipher.rb ruby3.3-3.3.13/test/openssl/test_cipher.rb --- ruby3.3-3.3.8/test/openssl/test_cipher.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/openssl/test_cipher.rb 2026-10-23 03:17:41.000000000 +0000 @@ -128,6 +128,30 @@ assert_equal pt, cipher.update(ct) << cipher.final end + def test_update_with_buffer + cipher = OpenSSL::Cipher.new("aes-128-ecb").encrypt + cipher.random_key + expected = cipher.update("data") << cipher.final + assert_equal 16, expected.bytesize + + # Buffer is supplied + cipher.reset + buf = String.new + assert_same buf, cipher.update("data", buf) + assert_equal expected, buf + cipher.final + + # Buffer is frozen + cipher.reset + assert_raise(FrozenError) { cipher.update("data", String.new.freeze) } + + # Buffer is a shared string [ruby-core:120141] [Bug #20937] + cipher.reset + buf = "x" * 1024 + shared = buf[-("data".bytesize + 32)..-1] + assert_same shared, cipher.update("data", shared) + assert_equal expected, shared + cipher.final + end + def test_ciphers ciphers = OpenSSL::Cipher.ciphers assert_kind_of Array, ciphers @@ -331,6 +355,22 @@ assert_equal tag1, tag2 end + def test_aes_keywrap_pad + # RFC 5649 Section 6; The second example + kek = ["5840df6e29b02af1ab493b705bf16ea1ae8338f4dcc176a8"].pack("H*") + key = ["466f7250617369"].pack("H*") + wrap = ["afbeb0f07dfbf5419200f2ccb50bb24f"].pack("H*") + + begin + cipher = OpenSSL::Cipher.new("id-aes192-wrap-pad").encrypt + rescue OpenSSL::Cipher::CipherError, RuntimeError + omit "id-aes192-wrap-pad is not supported: #$!" + end + cipher.key = kek + ct = cipher.update(key) << cipher.final + assert_equal wrap, ct + end + def test_non_aead_cipher_set_auth_data assert_raise(OpenSSL::Cipher::CipherError) { cipher = OpenSSL::Cipher.new("aes-128-cfb").encrypt diff -Nru ruby3.3-3.3.8/test/openssl/test_ossl.rb ruby3.3-3.3.13/test/openssl/test_ossl.rb --- ruby3.3-3.3.8/test/openssl/test_ossl.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/openssl/test_ossl.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1,8 +1,6 @@ # frozen_string_literal: true require_relative "utils" -require 'benchmark' - if defined?(OpenSSL) class OpenSSL::OSSL < OpenSSL::SSLTestCase @@ -54,8 +52,14 @@ a_b_time = a_c_time = 0 100.times do - a_b_time += Benchmark.measure { 100.times { OpenSSL.fixed_length_secure_compare(a, b) } }.real - a_c_time += Benchmark.measure { 100.times { OpenSSL.fixed_length_secure_compare(a, c) } }.real + t1 = Process.clock_gettime(Process::CLOCK_MONOTONIC) + 100.times { OpenSSL.fixed_length_secure_compare(a, b) } + t2 = Process.clock_gettime(Process::CLOCK_MONOTONIC) + 100.times { OpenSSL.fixed_length_secure_compare(a, c) } + t3 = Process.clock_gettime(Process::CLOCK_MONOTONIC) + + a_b_time += t2 - t1 + a_c_time += t3 - t2 end assert_operator(a_b_time, :<, a_c_time * 10, "fixed_length_secure_compare timing test failed") assert_operator(a_c_time, :<, a_b_time * 10, "fixed_length_secure_compare timing test failed") diff -Nru ruby3.3-3.3.8/test/openssl/test_pkcs7.rb ruby3.3-3.3.13/test/openssl/test_pkcs7.rb --- ruby3.3-3.3.8/test/openssl/test_pkcs7.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/openssl/test_pkcs7.rb 2026-10-23 03:17:41.000000000 +0000 @@ -155,6 +155,21 @@ assert_equal(data, p7.decrypt(@rsa1024)) end + def test_empty_signed_data_ruby_bug_19974 + data = "-----BEGIN PKCS7-----\nMAsGCSqGSIb3DQEHAg==\n-----END PKCS7-----\n" + assert_raise(ArgumentError) { OpenSSL::PKCS7.new(data) } + + data = <<END +MIME-Version: 1.0 +Content-Disposition: attachment; filename="smime.p7m" +Content-Type: application/x-pkcs7-mime; smime-type=signed-data; name="smime.p7m" +Content-Transfer-Encoding: base64 + +#{data} +END + assert_raise(OpenSSL::PKCS7::PKCS7Error) { OpenSSL::PKCS7.read_smime(data) } + end + def test_graceful_parsing_failure #[ruby-core:43250] contents = File.read(__FILE__) assert_raise(ArgumentError) { OpenSSL::PKCS7.new(contents) } diff -Nru ruby3.3-3.3.8/test/openssl/test_pkey.rb ruby3.3-3.3.13/test/openssl/test_pkey.rb --- ruby3.3-3.3.8/test/openssl/test_pkey.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/openssl/test_pkey.rb 2026-10-23 03:17:41.000000000 +0000 @@ -8,6 +8,7 @@ assert_instance_of OpenSSL::PKey::RSA, rsa assert_equal "rsaEncryption", rsa.oid assert_match %r{oid=rsaEncryption}, rsa.inspect + assert_match %r{type_name=RSA}, rsa.inspect if openssl?(3, 0, 0) # X25519 private key x25519_pem = <<~EOF @@ -38,6 +39,12 @@ assert_raise(OpenSSL::PKey::PKeyError) { OpenSSL::PKey.generate_parameters("EC", "invalid" => "option") } + end + + def test_s_generate_parameters_with_block + # DSA kengen is not FIPS-approved. + # https://github.com/openssl/openssl/commit/49a35f0#diff-605396c063194975af8ce31399d42690ab18186b422fb5012101cc9132660fe1R611-R614 + omit_on_fips # Parameter generation callback is called if openssl?(3, 0, 0, 0) && !openssl?(3, 0, 0, 6) @@ -144,32 +151,6 @@ assert_raise(OpenSSL::PKey::PKeyError) { priv.derive(pub) } end - def test_ed25519_not_approved_on_fips - omit_on_non_fips - # Ed25519 is technically allowed in the OpenSSL 3.0 code as a kind of bug. - # So, we need to omit OpenSSL 3.0. - # - # See OpenSSL providers/fips/fipsprov.c PROV_NAMES_ED25519 entries with - # FIPS_DEFAULT_PROPERTIES on openssl-3.0 branch and - # FIPS_UNAPPROVED_PROPERTIES on openssl-3.1 branch. - # - # See also - # https://github.com/openssl/openssl/issues/20758#issuecomment-1639658102 - # for details. - unless openssl?(3, 1, 0, 0) - omit 'Ed25519 is allowed in the OpenSSL 3.0 FIPS code as a kind of bug' - end - - priv_pem = <<~EOF - -----BEGIN PRIVATE KEY----- - MC4CAQAwBQYDK2VwBCIEIEzNCJso/5banbbDRuwRTg9bijGfNaumJNqM9u1PuKb7 - -----END PRIVATE KEY----- - EOF - assert_raise(OpenSSL::PKey::PKeyError) do - OpenSSL::PKey.read(priv_pem) - end - end - def test_x25519 # Test vector from RFC 7748 Section 6.1 alice_pem = <<~EOF @@ -191,6 +172,8 @@ pend "X25519 is not implemented" end assert_instance_of OpenSSL::PKey::PKey, alice + assert_equal "X25519", alice.oid + assert_match %r{oid=X25519}, alice.inspect assert_equal alice_pem, alice.private_to_pem assert_equal bob_pem, bob.public_to_pem assert_equal [shared_secret].pack("H*"), alice.derive(bob) @@ -213,6 +196,25 @@ bob_public_raw end + def test_ml_dsa + # AWS-LC also supports ML-DSA, but it's implemented in a different way + return unless openssl?(3, 5, 0) + + pkey = OpenSSL::PKey.generate_key("ML-DSA-44") + assert_match(/type_name=ML-DSA-44/, pkey.inspect) + sig = pkey.sign(nil, "data") + assert_equal(2420, sig.bytesize) + assert_equal(true, pkey.verify(nil, sig, "data")) + + pub2 = OpenSSL::PKey.read(pkey.public_to_der) + assert_equal(true, pub2.verify(nil, sig, "data")) + + raw_public_key = pkey.raw_public_key + assert_equal(1312, raw_public_key.bytesize) + pub3 = OpenSSL::PKey.new_raw_public_key("ML-DSA-44", raw_public_key) + assert_equal(true, pub3.verify(nil, sig, "data")) + end + def raw_initialize pend "Ed25519 is not implemented" unless openssl?(1, 1, 1) # >= v1.1.1 diff -Nru ruby3.3-3.3.8/test/openssl/test_pkey_dsa.rb ruby3.3-3.3.13/test/openssl/test_pkey_dsa.rb --- ruby3.3-3.3.8/test/openssl/test_pkey_dsa.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/openssl/test_pkey_dsa.rb 2026-10-23 03:17:41.000000000 +0000 @@ -28,6 +28,12 @@ end end + def test_new_empty + key = OpenSSL::PKey::DSA.new + assert_nil(key.p) + assert_raise(OpenSSL::PKey::PKeyError) { key.to_der } + end + def test_generate # DSA.generate used to call DSA_generate_parameters_ex(), which adjusts the # size of q according to the size of p diff -Nru ruby3.3-3.3.8/test/openssl/test_pkey_rsa.rb ruby3.3-3.3.13/test/openssl/test_pkey_rsa.rb --- ruby3.3-3.3.8/test/openssl/test_pkey_rsa.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/openssl/test_pkey_rsa.rb 2026-10-23 03:17:41.000000000 +0000 @@ -172,7 +172,7 @@ assert_raise(OpenSSL::PKey::PKeyError, "[Bug #12783]") { rsa.verify("SHA1", "a", "b") } - end + end unless openssl?(3, 0, 0) def test_sign_verify_pss key = Fixtures.pkey("rsa1024") diff -Nru ruby3.3-3.3.8/test/openssl/test_provider.rb ruby3.3-3.3.13/test/openssl/test_provider.rb --- ruby3.3-3.3.8/test/openssl/test_provider.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/openssl/test_provider.rb 2026-10-23 03:17:41.000000000 +0000 @@ -12,15 +12,14 @@ end def test_openssl_provider_names - omit 'not working on freebsd RubyCI' if ENV['RUBYCI_NICKNAME'] =~ /freebsd/ with_openssl <<-'end;' - legacy_provider = OpenSSL::Provider.load("legacy") + base_provider = OpenSSL::Provider.load("base") assert_equal(2, OpenSSL::Provider.provider_names.size) - assert_includes(OpenSSL::Provider.provider_names, "legacy") + assert_includes(OpenSSL::Provider.provider_names, "base") - assert_equal(true, legacy_provider.unload) + assert_equal(true, base_provider.unload) assert_equal(1, OpenSSL::Provider.provider_names.size) - assert_not_includes(OpenSSL::Provider.provider_names, "legacy") + assert_not_includes(OpenSSL::Provider.provider_names, "base") end; end @@ -34,9 +33,13 @@ end def test_openssl_legacy_provider - omit 'not working on freebsd RubyCI' if ENV['RUBYCI_NICKNAME'] =~ /freebsd/ with_openssl(<<-'end;') - OpenSSL::Provider.load("legacy") + begin + OpenSSL::Provider.load("legacy") + rescue OpenSSL::Provider::ProviderError + omit "Only for OpenSSL with legacy provider" + end + algo = "RC4" data = "a" * 1000 key = OpenSSL::Random.random_bytes(16) diff -Nru ruby3.3-3.3.8/test/openssl/test_ssl.rb ruby3.3-3.3.13/test/openssl/test_ssl.rb --- ruby3.3-3.3.8/test/openssl/test_ssl.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/openssl/test_ssl.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1634,7 +1634,9 @@ } } start_server(ctx_proc: ctx_proc) do |port| - server_connect(port) { |ssl| + ctx = OpenSSL::SSL::SSLContext.new + ctx.ecdh_curves = "P-256" # Exclude RFC 7919 groups + server_connect(port, ctx) { |ssl| assert called, "dh callback should be called" assert_equal dh.to_der, ssl.tmp_key.to_der } @@ -1761,7 +1763,9 @@ ctx.tmp_dh = dh } start_server(ctx_proc: ctx_proc) do |port| - server_connect(port) { |ssl| + ctx = OpenSSL::SSL::SSLContext.new + ctx.ecdh_curves = "P-256" # Exclude RFC 7919 groups + server_connect(port, ctx) { |ssl| assert_equal dh.to_der, ssl.tmp_key.to_der } end diff -Nru ruby3.3-3.3.8/test/openssl/test_x509cert.rb ruby3.3-3.3.13/test/openssl/test_x509cert.rb --- ruby3.3-3.3.8/test/openssl/test_x509cert.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/openssl/test_x509cert.rb 2026-10-23 03:17:41.000000000 +0000 @@ -68,7 +68,7 @@ assert_equal(now.getutc, cert.not_after) end - def test_extension + def test_extension_factory ca_exts = [ ["basicConstraints","CA:TRUE",true], ["keyUsage","keyCertSign, cRLSign",true], @@ -76,9 +76,6 @@ ["authorityKeyIdentifier","issuer:always,keyid:always",false], ] ca_cert = issue_cert(@ca, @rsa2048, 1, ca_exts, nil, nil) - keyid = get_subject_key_id(ca_cert.to_der, hex: false) - assert_equal keyid, ca_cert.authority_key_identifier - assert_equal keyid, ca_cert.subject_key_identifier ca_cert.extensions.each_with_index{|ext, i| assert_equal(ca_exts[i].first, ext.oid) assert_equal(ca_exts[i].last, ext.critical?) @@ -90,7 +87,6 @@ ["authorityKeyIdentifier","issuer:always,keyid:always",false], ["extendedKeyUsage","clientAuth, emailProtection, codeSigning",false], ["subjectAltName","email:ee1@ruby-lang.org",false], - ["authorityInfoAccess","caIssuers;URI:http://www.example.com/caIssuers,OCSP;URI:http://www.example.com/ocsp",false], ] ee1_cert = issue_cert(@ee1, @rsa1024, 2, ee1_exts, ca_cert, @rsa2048) assert_equal(ca_cert.subject.to_der, ee1_cert.issuer.to_der) @@ -98,15 +94,54 @@ assert_equal(ee1_exts[i].first, ext.oid) assert_equal(ee1_exts[i].last, ext.critical?) } - assert_nil(ee1_cert.crl_uris) + end + + def test_akiski + ca_cert = generate_cert(@ca, @rsa2048, 4, nil) + ef = OpenSSL::X509::ExtensionFactory.new(ca_cert, ca_cert) + ca_cert.add_extension( + ef.create_extension("subjectKeyIdentifier", "hash", false)) + ca_cert.add_extension( + ef.create_extension("authorityKeyIdentifier", "issuer:always,keyid:always", false)) + ca_cert.sign(@rsa2048, "sha256") + + ca_keyid = get_subject_key_id(ca_cert.to_der, hex: false) + assert_equal ca_keyid, ca_cert.authority_key_identifier + assert_equal ca_keyid, ca_cert.subject_key_identifier + + ee_cert = generate_cert(@ee1, Fixtures.pkey("p256"), 5, ca_cert) + ef = OpenSSL::X509::ExtensionFactory.new(ca_cert, ee_cert) + ee_cert.add_extension( + ef.create_extension("subjectKeyIdentifier", "hash", false)) + ee_cert.add_extension( + ef.create_extension("authorityKeyIdentifier", "issuer:always,keyid:always", false)) + ee_cert.sign(@rsa2048, "sha256") + + ee_keyid = get_subject_key_id(ee_cert.to_der, hex: false) + assert_equal ca_keyid, ee_cert.authority_key_identifier + assert_equal ee_keyid, ee_cert.subject_key_identifier + end + + def test_akiski_missing + cert = issue_cert(@ee1, @rsa2048, 1, [], nil, nil) + assert_nil(cert.authority_key_identifier) + assert_nil(cert.subject_key_identifier) + end + + def test_crl_uris_no_crl_distribution_points + cert = issue_cert(@ee1, @rsa2048, 1, [], nil, nil) + assert_nil(cert.crl_uris) + end + def test_crl_uris + # Multiple DistributionPoint contains a single general name each ef = OpenSSL::X509::ExtensionFactory.new ef.config = OpenSSL::Config.parse(<<~_cnf_) [crlDistPts] URI.1 = http://www.example.com/crl URI.2 = ldap://ldap.example.com/cn=ca?certificateRevocationList;binary _cnf_ - cdp_cert = generate_cert(@ee1, @rsa1024, 3, ca_cert) + cdp_cert = generate_cert(@ee1, @rsa2048, 3, nil) ef.subject_certificate = cdp_cert cdp_cert.add_extension(ef.create_extension("crlDistributionPoints", "@crlDistPts")) cdp_cert.sign(@rsa2048, "sha256") @@ -114,9 +149,50 @@ ["http://www.example.com/crl", "ldap://ldap.example.com/cn=ca?certificateRevocationList;binary"], cdp_cert.crl_uris ) + end + def test_crl_uris_multiple_general_names + # Single DistributionPoint contains multiple general names of type URI ef = OpenSSL::X509::ExtensionFactory.new - aia_cert = generate_cert(@ee1, @rsa1024, 4, ca_cert) + ef.config = OpenSSL::Config.parse(<<~_cnf_) + [crlDistPts_section] + fullname = URI:http://www.example.com/crl, URI:ldap://ldap.example.com/cn=ca?certificateRevocationList;binary + _cnf_ + cdp_cert = generate_cert(@ee1, @rsa2048, 3, nil) + ef.subject_certificate = cdp_cert + cdp_cert.add_extension(ef.create_extension("crlDistributionPoints", "crlDistPts_section")) + cdp_cert.sign(@rsa2048, "sha256") + assert_equal( + ["http://www.example.com/crl", "ldap://ldap.example.com/cn=ca?certificateRevocationList;binary"], + cdp_cert.crl_uris + ) + end + + def test_crl_uris_no_uris + # The only DistributionPointName is a directoryName + ef = OpenSSL::X509::ExtensionFactory.new + ef.config = OpenSSL::Config.parse(<<~_cnf_) + [crlDistPts_section] + fullname = dirName:dirname_section + [dirname_section] + CN = dirname + _cnf_ + cdp_cert = generate_cert(@ee1, @rsa2048, 3, nil) + ef.subject_certificate = cdp_cert + cdp_cert.add_extension(ef.create_extension("crlDistributionPoints", "crlDistPts_section")) + cdp_cert.sign(@rsa2048, "sha256") + assert_nil(cdp_cert.crl_uris) + end + + def test_aia_missing + cert = issue_cert(@ee1, @rsa2048, 1, [], nil, nil) + assert_nil(cert.ca_issuer_uris) + assert_nil(cert.ocsp_uris) + end + + def test_aia + ef = OpenSSL::X509::ExtensionFactory.new + aia_cert = generate_cert(@ee1, @rsa2048, 4, nil) ef.subject_certificate = aia_cert aia_cert.add_extension( ef.create_extension( @@ -137,13 +213,6 @@ ["http://www.example.com/ocsp", "ldap://ldap.example.com/cn=ca?authorityInfoAccessOcsp;binary"], aia_cert.ocsp_uris ) - - no_exts_cert = issue_cert(@ca, @rsa2048, 5, [], nil, nil) - assert_equal nil, no_exts_cert.authority_key_identifier - assert_equal nil, no_exts_cert.subject_key_identifier - assert_equal nil, no_exts_cert.crl_uris - assert_equal nil, no_exts_cert.ca_issuer_uris - assert_equal nil, no_exts_cert.ocsp_uris end def test_invalid_extension diff -Nru ruby3.3-3.3.8/test/resolv/test_dns.rb ruby3.3-3.3.13/test/resolv/test_dns.rb --- ruby3.3-3.3.8/test/resolv/test_dns.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/resolv/test_dns.rb 2026-10-23 03:17:41.000000000 +0000 @@ -487,6 +487,8 @@ if RUBY_PLATFORM.match?(/mingw/) # cannot repo locally omit 'Timeout Error on MinGW CI' + elsif macos?(26,1) + omit 'Timeout Error on macOS 26.1+' else raise Timeout::Error end @@ -589,6 +591,212 @@ assert_operator(2**14, :<, m.to_s.length) end + def test_too_long_address + too_long_address_message = [0, 0, 1, 0, 0, 0].pack("n*") + "\x01x" * 129 + [0, 0, 0].pack("cnn") + assert_raise_with_message(Resolv::DNS::DecodeError, /name label data exceed 255 octets/) do + Resolv::DNS::Message.decode too_long_address_message + end + end + + # A DNS label is limited to 63 octets. [RFC 1035 2.3.4] Writing a longer label + # through the label path must raise instead of overflowing the length octet. + def test_put_label_rejects_label_over_63_octets + Resolv::DNS::Message::MessageEncoder.new {|msg| + assert_nothing_raised { msg.put_label("a" * 63) } + assert_raise_with_message(ArgumentError, /DNS label is too long/) do + msg.put_label("a" * 64) + end + } + # put_labels drives put_label, so the same guard applies to the name path. + Resolv::DNS::Message::MessageEncoder.new {|msg| + assert_raise_with_message(ArgumentError, /DNS label is too long/) do + msg.put_labels(["a" * 64]) + end + } + end + + # The per-label limit is an invariant of Label::Str, so no label object can + # exist that would overflow its length octet. [RFC 1035 2.3.4] + def test_label_str_rejects_label_over_63_octets + assert_nothing_raised { Resolv::DNS::Label::Str.new("a" * 63) } + assert_raise_with_message(ArgumentError, /DNS label is too long/) do + Resolv::DNS::Label::Str.new("a" * 64) + end + end + + # Every way of building a name goes through Label::Str, so the paths that + # skip Name.create are covered too. + def test_label_length_is_enforced_on_every_construction_path + assert_raise_with_message(ArgumentError, /DNS label is too long/) do + Resolv::DNS::Name.new(["a" * 64]) + end + assert_raise_with_message(ArgumentError, /DNS label is too long/) do + Resolv::DNS::Label.split("a" * 64) + end + # Config#generate_candidates appends search domains with Name.new, and the + # search list itself comes from Label.split, so a resolv.conf carrying an + # over-long label is rejected when the config is read. + config = Resolv::DNS::Config.new(nameserver: ['127.0.0.1'], + search: ["a" * 64], ndots: 1) + assert_raise_with_message(ArgumentError, /DNS label is too long/) do + config.lazy_initialize + end + end + + def test_name_create_rejects_too_long_label + assert_nothing_raised { Resolv::DNS::Name.create("a" * 63) } + assert_raise_with_message(Resolv::ResolvError, /DNS label is too long/) do + Resolv::DNS::Name.create("a" * 64) + end + end + + def test_name_create_rejects_too_long_name + # Five 63-octet labels total 321 encoded octets, over the 255 octet limit, + # while each individual label is still valid. + too_long = (["a" * 63] * 5).join(".") + assert_raise_with_message(Resolv::ResolvError, /DNS name is too long/) do + Resolv::DNS::Name.create(too_long) + end + end + + # A hostname is runtime data, so an over-long one has to stay rescuable the + # way the rest of name resolution is. It reaches Name.create through + # Config#generate_candidates, which runs outside Config#resolv's own rescue. + def test_oversized_name_is_rescuable_as_resolv_error + dns = Resolv::DNS.new(nameserver_port: [['127.0.0.1', 53]]) + assert_raise(Resolv::ResolvError) { dns.getaddress("a" * 64) } + assert_raise(Resolv::ResolvError) { dns.getaddress((["a" * 63] * 5).join(".")) } + ensure + dns&.close + end + + # A length octet of 64..191 is reserved, not a label length, but this decoder + # read it as one and accepted labels no encoder should ever produce. + # [RFC 1035 4.1.4] Rejecting them has to look like any other malformed + # message, so the caller's rescue DecodeError still covers it. + def test_decode_rejects_label_over_63_octets + message = ->(n) { + [0, 0x8180, 1, 0, 0, 0].pack("n*") + + [n].pack("C") + ("a" * n) + "\0" + [1, 1].pack("nn") + } + assert_nothing_raised { Resolv::DNS::Message.decode(message.call(63)) } + [64, 100, 191].each do |n| + assert_raise_with_message(Resolv::DNS::DecodeError, /DNS label is too long/) do + Resolv::DNS::Message.decode(message.call(n)) + end + end + end + + # The type check is a caller mistake rather than runtime data, so it keeps + # raising ArgumentError. + def test_name_create_still_raises_argument_error_for_wrong_type + assert_raise_with_message(ArgumentError, /cannot interpret as DNS name/) do + Resolv::DNS::Name.create(123) + end + end + + # The 255 octet limit counts the encoded form, including each label's length + # octet and the root label's terminating zero octet. [RFC 1035 2.3.4, 3.1] + # So the longest legal name encodes to exactly 255 octets. + def test_name_create_total_length_boundary + at_limit = (["a" * 63] * 3 + ["a" * 61]).join(".") + name = Resolv::DNS::Name.create(at_limit) + encoded = Resolv::DNS::Message::MessageEncoder.new {|msg| msg.put_name(name) }.to_s + assert_equal(255, encoded.bytesize, "longest legal name encodes to 255 octets") + + over_limit = (["a" * 63] * 3 + ["a" * 62]).join(".") + assert_raise_with_message(Resolv::ResolvError, /DNS name is too long/) do + Resolv::DNS::Name.create(over_limit) + end + + # Four 63-octet labels encode to 257 octets. Counting the presentation + # form instead of the encoded form lets these two extra octets through. + assert_raise_with_message(Resolv::ResolvError, /DNS name is too long/) do + Resolv::DNS::Name.create((["a" * 63] * 4).join(".")) + end + end + + # The decoder enforces the same limit, counted the same way. + def test_get_labels_total_length_boundary + encode = ->(labels) { + Resolv::DNS::Message::MessageEncoder.new {|msg| + msg.put_labels(labels.map {|l| Resolv::DNS::Label::Str.new(l) }) + }.to_s + } + + at_limit = encode.call(["a" * 63] * 3 + ["a" * 61]) + assert_equal(255, at_limit.bytesize) + Resolv::DNS::Message::MessageDecoder.new(at_limit) {|msg| + assert_equal(4, msg.get_labels.length) + } + + over_limit = encode.call(["a" * 63] * 4) + assert_equal(257, over_limit.bytesize) + assert_raise_with_message(Resolv::DNS::DecodeError, /name label data exceed 255 octets/) do + Resolv::DNS::Message::MessageDecoder.new(over_limit) {|msg| msg.get_labels } + end + end + + # A single 262-octet label whose bytes start with "target\x03com\x00". The + # old encoder wrote the length octet as 262 & 0xff == 6, so the wire bytes + # decoded to the unrelated name "target.com" (query name confusion / + # allowlist bypass). + def test_encoder_rejects_label_length_wrap + poc_label = "target".b + "\x03com\x00".b + ("a".b * 251) + assert_equal(262, poc_label.bytesize) + assert_equal(6, poc_label.bytesize & 0xff, "precondition: the length octet wraps to 6") + + # The bytes the buggy encoder would have emitted really do decode to a + # different name. This is the vulnerability being fixed. + wrapped = [poc_label.bytesize & 0xff].pack("C") + poc_label + Resolv::DNS::Message::MessageDecoder.new(wrapped) {|msg| + assert_equal("target.com", msg.get_labels.map(&:to_s).join(".")) + } + + # The fixed encoder refuses to emit it instead of silently wrapping, so it + # can no longer produce "target.com" from this input. + Resolv::DNS::Message::MessageEncoder.new {|msg| + assert_raise_with_message(ArgumentError, /DNS label is too long/) do + msg.put_label(poc_label) + end + } + assert_raise_with_message(Resolv::ResolvError, /DNS label is too long/) do + Resolv::DNS::Name.create(poc_label) + end + end + + # A character-string (e.g. TXT rdata) is prefixed by a single length octet and + # may legitimately be up to 255 octets, so the 63 octet label limit must not + # leak into put_string. [RFC 1035 3.3] + def test_put_string_allows_character_string_up_to_255 + [64, 200, 255].each do |n| + s = "a" * n + m = Resolv::DNS::Message::MessageEncoder.new {|msg| msg.put_string(s) } + encoded = m.to_s + assert_equal(n, encoded.getbyte(0), "length octet for #{n} byte string") + assert_equal(n + 1, encoded.bytesize) + Resolv::DNS::Message::MessageDecoder.new(encoded) {|msg| + assert_equal(s, msg.get_string) + } + end + end + + def test_txt_record_roundtrip_with_long_character_strings + txt = Resolv::DNS::Resource::IN::TXT.new("a" * 255, "b" * 64) + m = Resolv::DNS::Message.new(0) + m.add_answer("example.com.", 3600, txt) + decoded = Resolv::DNS::Message.decode(m.encode) + _, _, res = decoded.answer.first + assert_equal(["a" * 255, "b" * 64], res.strings) + end + + # put_string still guards against the length octet wrapping past 255 octets. + def test_put_string_rejects_over_255_octets + assert_raise_with_message(ArgumentError, /character-string is too long/) do + Resolv::DNS::Message::MessageEncoder.new {|msg| msg.put_string("a" * 256) } + end + end + def assert_no_fd_leak socket = assert_throw(self) do |tag| Resolv::DNS.stub(:bind_random_port, ->(s, *) {throw(tag, s)}) do diff -Nru ruby3.3-3.3.8/test/resolv/test_resource.rb ruby3.3-3.3.13/test/resolv/test_resource.rb --- ruby3.3-3.3.8/test/resolv/test_resource.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/resolv/test_resource.rb 2026-10-23 03:17:41.000000000 +0000 @@ -24,6 +24,67 @@ Resolv::LOC::Coord.create('1 2 1.1 N') end + # Decoding an unknown (type, class) pair builds a fresh class every time, so + # equality must not rest on the class identity. + def test_generic_equality + wire = generic_answer(40000, "\x01\x02\x03") + rr1 = decode_generic(wire) + rr2 = decode_generic(wire) + + assert_not_same rr1.class, rr2.class + assert_equal rr1, rr2 + assert rr1.eql?(rr2) + assert_equal rr1.hash, rr2.hash + assert_equal Resolv::DNS::Message.decode(wire), Resolv::DNS::Message.decode(wire) + end + + # Any descendant counts, not just a class create returned. + def test_generic_equality_between_descendants + generic = Resolv::DNS::Resource::Generic + direct = generic.create(40000, 60000) + descendant = Class.new(generic.create(40000, 60000)) + + assert_equal direct.new("\x01\x02\x03"), descendant.new("\x01\x02\x03") + assert_equal descendant.new("\x01\x02\x03"), direct.new("\x01\x02\x03") + assert_equal generic.new("\x01\x02\x03"), generic.new("\x01\x02\x03") + assert_not_equal direct.new("\x01\x02\x03"), + Class.new(generic.create(40001, 60000)).new("\x01\x02\x03") + end + + def test_generic_inequality + rr = decode_generic(generic_answer(40000, "\x01\x02\x03")) + + assert_not_equal rr, decode_generic(generic_answer(40001, "\x01\x02\x03")) + assert_not_equal rr, decode_generic(generic_answer(40000, "\x09\x09\x09")) + assert_not_equal rr, Resolv::DNS::Resource::IN::A.new("192.168.0.1") + end + + # A question holds the resource class itself, so it needs the same treatment. + def test_generic_question_equality + wire = generic_question(40000) + + assert_equal Resolv::DNS::Message.decode(wire), Resolv::DNS::Message.decode(wire) + assert_not_equal Resolv::DNS::Message.decode(wire), + Resolv::DNS::Message.decode(generic_question(40001)) + end + + private def header(qdcount, ancount) + "\x00\x00\x00\x00".b + [qdcount, ancount, 0, 0].pack('nnnn') + end + + private def generic_answer(type, rdata) + rdata = rdata.b + (header(0, 1) + "\x00".b + [type, 60000, 0, rdata.bytesize].pack('nnNn') + rdata).b + end + + private def generic_question(type) + (header(1, 0) + "\x07example\x03com\x00".b + [type, 60000].pack('nn')).b + end + + private def decode_generic(wire) + Resolv::DNS::Message.decode(wire).answer.first[2] + end + def test_srv_no_compress # Domain name in SRV RDATA should not be compressed issue29 = 'https://github.com/ruby/resolv/issues/29' diff -Nru ruby3.3-3.3.8/test/resolv/test_resource_leak.rb ruby3.3-3.3.13/test/resolv/test_resource_leak.rb --- ruby3.3-3.3.8/test/resolv/test_resource_leak.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/test/resolv/test_resource_leak.rb 2026-10-23 03:17:41.000000000 +0000 @@ -0,0 +1,101 @@ +# frozen_string_literal: false +require 'test/unit' +require 'resolv' + +# Decoding a response with unknown (type, class) pairs or unknown SvcParamKeys +# used to register a generated class permanently, so a malicious response could +# exhaust memory even after the response was discarded. +class TestResolvResourceLeak < Test::Unit::TestCase + # Number of dynamically-registered "Type<n>_Class<n>" constants on +mod+. + def type_const_count(mod) + mod.constants(false).count { |c| c.to_s.match?(/\AType\d+_Class\d+\z/) } + end + + def svcparam_key_const_count + Resolv::DNS::SvcParam::Generic.constants(false).count { |c| c.to_s.match?(/\AKey\d+\z/) } + end + + # A DNS response whose answer section holds +count+ RRs, each with a distinct + # unknown (type, class) pair. + def unknown_typeclass_response(count) + body = "".b + count.times do |i| + type = 40000 + i + klass = 60000 + rdata = "\x01\x02\x03".b + body << "\x00".b # NAME = root + body << [type, klass, 0, rdata.bytesize].pack('nnNn') + body << rdata + end + header = "\x00\x00\x00\x00".b + [0, count, 0, 0].pack('nnnn') + (header + body).b + end + + # An SVCB RR (type 64) carrying +count+ distinct unknown SvcParamKeys. + def unknown_svcparam_response(count) + rdata = "".b + rdata << [1].pack('n') # SvcPriority + rdata << "\x03foo\x07example\x03com\x00".b # TargetName + count.times do |i| + key = 1000 + i + val = "x".b + rdata << [key, val.bytesize].pack('nn') << val + end + header = "\x00\x00\x00\x00".b + [0, 1, 0, 0].pack('nnnn') + name = "\x07example\x03com\x00".b + rr = name + [64, 1, 0, rdata.bytesize].pack('nnNn') + rdata + (header + rr).b + end + + def test_unknown_typeclass_does_not_leak_classes + resource = Resolv::DNS::Resource + generic = Resolv::DNS::Resource::Generic + + before_resource = type_const_count(resource) + before_generic = type_const_count(generic) + + [100, 1000].each do |count| + msg = unknown_typeclass_response(count) + 3.times { Resolv::DNS::Message.decode(msg) } + end + GC.start + + assert_equal before_resource, type_const_count(resource), + 'decoding unknown (type, class) RRs must not register new Resource constants' + assert_equal before_generic, type_const_count(generic), + 'decoding unknown (type, class) RRs must not register new Generic constants' + end + + def test_unknown_svcparam_key_does_not_leak_classes + class_hash = Resolv::DNS::SvcParam::ClassHash + + before_consts = svcparam_key_const_count + before_hash = class_hash.size + + [100, 1000].each do |count| + msg = unknown_svcparam_response(count) + 3.times { Resolv::DNS::Message.decode(msg) } + end + GC.start + + assert_equal before_consts, svcparam_key_const_count, + 'decoding unknown SvcParamKeys must not register new Generic constants' + assert_equal before_hash, class_hash.size, + 'decoding unknown SvcParamKeys must not grow SvcParam::ClassHash' + end + + # Dropping the permanent registration must not break decoding of the unknown + # values themselves. + def test_unknown_values_still_decode + msg = Resolv::DNS::Message.decode(unknown_typeclass_response(3)) + assert_equal 3, msg.answer.size + _, _, rr = msg.answer.first + assert_kind_of Resolv::DNS::Resource::Generic, rr + assert_equal "\x01\x02\x03".b, rr.data + + msg = Resolv::DNS::Message.decode(unknown_svcparam_response(3)) + _, _, svcb = msg.answer.first + assert_equal 3, svcb.params.count + assert_equal "x".b, svcb.params[:key1000].value + end +end diff -Nru ruby3.3-3.3.8/test/ruby/test_bignum.rb ruby3.3-3.3.13/test/ruby/test_bignum.rb --- ruby3.3-3.3.8/test/ruby/test_bignum.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_bignum.rb 2026-10-23 03:17:41.000000000 +0000 @@ -778,6 +778,9 @@ assert_equal([7215, 2413, 6242], T1024P.digits(10_000).first(3)) assert_equal([11], 11.digits(T1024P)) assert_equal([T1024P - 1, 1], (T1024P + T1024P - 1).digits(T1024P)) + bug21680 = '[ruby-core:123769] [Bug #21680]' + assert_equal([0] * 64 + [1], (2**512).digits(256), bug21680) + assert_equal([0] * 128 + [1], (123**128).digits(123), bug21680) end def test_digits_for_negative_numbers diff -Nru ruby3.3-3.3.8/test/ruby/test_data.rb ruby3.3-3.3.13/test/ruby/test_data.rb --- ruby3.3-3.3.8/test/ruby/test_data.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_data.rb 2026-10-23 03:17:41.000000000 +0000 @@ -262,6 +262,7 @@ assert_equal('#<data >', test.inspect) assert_equal([], test.members) assert_equal({}, test.to_h) + assert_predicate(test, :frozen?) end def test_dup @@ -280,4 +281,10 @@ assert_not_same(test, loaded) assert_predicate(loaded, :frozen?) end + + def test_frozen_subclass + test = Class.new(Data.define(:a)).freeze.new(a: 0) + assert_kind_of(Data, test) + assert_equal([:a], test.members) + end end diff -Nru ruby3.3-3.3.8/test/ruby/test_exception.rb ruby3.3-3.3.13/test/ruby/test_exception.rb --- ruby3.3-3.3.8/test/ruby/test_exception.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_exception.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1459,6 +1459,15 @@ assert_equal("\e[1mRuntimeError (\e[1;4mRuntimeError\e[m\e[1m)\e[m", e.detailed_message(highlight: true)) end + def test_detailed_message_under_gc_compact_stress + omit "compaction doesn't work well on s390x" if RUBY_PLATFORM =~ /s390x/ # https://github.com/ruby/ruby/pull/5077 + EnvUtil.under_gc_compact_stress do + e = RuntimeError.new("foo\nbar\nbaz") + assert_equal("foo (RuntimeError)\nbar\nbaz", e.detailed_message) + assert_equal("\e[1mfoo (\e[1;4mRuntimeError\e[m\e[1m)\e[m\n\e[1mbar\e[m\n\e[1mbaz\e[m", e.detailed_message(highlight: true)) + end + end + def test_full_message_with_custom_detailed_message e = RuntimeError.new("message") opt_ = nil diff -Nru ruby3.3-3.3.8/test/ruby/test_hash.rb ruby3.3-3.3.13/test/ruby/test_hash.rb --- ruby3.3-3.3.8/test/ruby/test_hash.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_hash.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1268,6 +1268,17 @@ assert_equal(@cls[a: 10, b: 2, c: 3, d: 4, e: 5, f: 6, g: 7, h: 8, i: 9, j: 10], h) end + def test_update_modify_in_block + a = @cls[] + (1..1337).each {|k| a[k] = k} + b = {1=>1338} + assert_raise_with_message(RuntimeError, /rehash during iteration/) do + a.update(b) {|k, o, n| + a.rehash + } + end + end + def test_update_on_identhash key = +'a' i = @cls[].compare_by_identity @@ -1816,6 +1827,14 @@ end end assert_equal(@cls[a: 2, b: 2, c: 3, d: 4, e: 5, f: 6, g: 7, h: 8, i: 9, j: 10], x) + + x = (1..1337).to_h {|k| [k, k]} + assert_raise_with_message(RuntimeError, /rehash during iteration/) do + x.transform_values! {|v| + x.rehash if v == 1337 + v * 2 + } + end end def hrec h, n, &b @@ -2296,6 +2315,11 @@ end end + def test_bug_21357 + h = {x: []}.merge(x: nil) { |_k, v1, _v2| v1 } + assert_equal({x: []}, h) + end + def test_any_hash_fixable 20.times do assert_separately([], "#{<<~"begin;"}\n#{<<~'end;'}") diff -Nru ruby3.3-3.3.8/test/ruby/test_keyword.rb ruby3.3-3.3.13/test/ruby/test_keyword.rb --- ruby3.3-3.3.8/test/ruby/test_keyword.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_keyword.rb 2026-10-23 03:17:41.000000000 +0000 @@ -2378,6 +2378,21 @@ assert_raise(ArgumentError) { m.call(42, a: 1, **h2) } end + def test_ruby2_keywords_post_arg + def self.a(*c, **kw) [c, kw] end + def self.b(*a, b) a(*a, b) end + assert_warn(/Skipping set of ruby2_keywords flag for b \(method accepts keywords or post arguments or method does not accept argument splat\)/) do + assert_nil(singleton_class.send(:ruby2_keywords, :b)) + end + assert_equal([[{foo: 1}, {bar: 1}], {}], b({foo: 1}, bar: 1)) + + b = ->(*a, b){a(*a, b)} + assert_warn(/Skipping set of ruby2_keywords flag for proc \(proc accepts keywords or post arguments or proc does not accept argument splat\)/) do + b.ruby2_keywords + end + assert_equal([[{foo: 1}, {bar: 1}], {}], b.({foo: 1}, bar: 1)) + end + def test_proc_ruby2_keywords h1 = {:a=>1} foo = ->(*args, &block){block.call(*args)} @@ -2390,8 +2405,8 @@ assert_raise(ArgumentError) { foo.call(:a=>1, &->(arg, **kw){[arg, kw]}) } assert_equal(h1, foo.call(:a=>1, &->(arg){arg})) - [->(){}, ->(arg){}, ->(*args, **kw){}, ->(*args, k: 1){}, ->(*args, k: ){}].each do |pr| - assert_warn(/Skipping set of ruby2_keywords flag for proc \(proc accepts keywords or proc does not accept argument splat\)/) do + [->(){}, ->(arg){}, ->(*args, x){}, ->(*args, **kw){}, ->(*args, k: 1){}, ->(*args, k: ){}].each do |pr| + assert_warn(/Skipping set of ruby2_keywords flag for proc \(proc accepts keywords or post arguments or proc does not accept argument splat\)/) do pr.ruby2_keywords end end @@ -2744,10 +2759,27 @@ assert_equal(:opt, o.clear_last_opt(a: 1)) assert_nothing_raised(ArgumentError) { o.clear_last_empty_method(a: 1) } - assert_warn(/Skipping set of ruby2_keywords flag for bar \(method accepts keywords or method does not accept argument splat\)/) do + assert_warn(/Skipping set of ruby2_keywords flag for bar \(method accepts keywords or post arguments or method does not accept argument splat\)/) do assert_nil(c.send(:ruby2_keywords, :bar)) end + c.class_eval do + def bar_post(*a, x) = nil + define_method(:bar_post_bmethod) { |*a, x| } + end + assert_warn(/Skipping set of ruby2_keywords flag for bar_post \(method accepts keywords or post arguments or method does not accept argument splat\)/) do + assert_nil(c.send(:ruby2_keywords, :bar_post)) + end + assert_warn(/Skipping set of ruby2_keywords flag for bar_post_bmethod \(method accepts keywords or post arguments or method does not accept argument splat\)/) do + assert_nil(c.send(:ruby2_keywords, :bar_post_bmethod)) + end + + utf16_sym = "abcdef".encode("UTF-16LE").to_sym + c.send(:define_method, utf16_sym, c.instance_method(:itself)) + assert_warn(/abcdef/) do + assert_nil(c.send(:ruby2_keywords, utf16_sym)) + end + o = Object.new class << o alias bar p diff -Nru ruby3.3-3.3.8/test/ruby/test_marshal.rb ruby3.3-3.3.13/test/ruby/test_marshal.rb --- ruby3.3-3.3.8/test/ruby/test_marshal.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_marshal.rb 2026-10-23 03:17:41.000000000 +0000 @@ -268,7 +268,11 @@ classISO8859_1.name ClassISO8859_1 = classISO8859_1 - def test_class_nonascii + moduleUTF8 = const_set("C\u{30af 30e9 30b9}", Module.new) + moduleUTF8.name + ModuleUTF8 = moduleUTF8 + + def test_nonascii_class_instance a = ClassUTF8.new assert_instance_of(ClassUTF8, Marshal.load(Marshal.dump(a)), '[ruby-core:24790]') @@ -301,6 +305,12 @@ end end + def test_nonascii_class_module + assert_same(ClassUTF8, Marshal.load(Marshal.dump(ClassUTF8))) + assert_same(ClassISO8859_1, Marshal.load(Marshal.dump(ClassISO8859_1))) + assert_same(ModuleUTF8, Marshal.load(Marshal.dump(ModuleUTF8))) + end + def test_regexp2 assert_equal(/\\u/, Marshal.load("\004\b/\b\\\\u\000")) assert_equal(/u/, Marshal.load("\004\b/\a\\u\000")) @@ -961,5 +971,19 @@ refute_predicate Object, :frozen? refute_predicate Kernel, :frozen? end + + def test_linked_strings_are_frozen + str = "test" + str.instance_variable_set(:@self, str) + source = [str, str] + + objects = Marshal.load(encode(source), freeze: true) + assert_predicate objects[0], :frozen? + assert_predicate objects[1], :frozen? + assert_same objects[0], objects[1] + assert_same objects[0], objects[0].instance_variable_get(:@self) + assert_same objects[1], objects[1].instance_variable_get(:@self) + assert_same objects[0].instance_variable_get(:@self), objects[1].instance_variable_get(:@self) + end end end diff -Nru ruby3.3-3.3.8/test/ruby/test_math.rb ruby3.3-3.3.13/test/ruby/test_math.rb --- ruby3.3-3.3.8/test/ruby/test_math.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_math.rb 2026-10-23 03:17:41.000000000 +0000 @@ -301,11 +301,21 @@ assert_float_and_int([Math.log(6), 1], Math.lgamma(4)) assert_raise_with_message(Math::DomainError, /\blgamma\b/) { Math.lgamma(-Float::INFINITY) } + + x, sign = Math.lgamma(+0.0) + mesg = "Math.lgamma(+0.0) should be [INF, +1]" + assert_infinity(x, mesg) + assert_equal(+1, sign, mesg) + x, sign = Math.lgamma(-0.0) mesg = "Math.lgamma(-0.0) should be [INF, -1]" assert_infinity(x, mesg) assert_equal(-1, sign, mesg) - x, sign = Math.lgamma(Float::NAN) + + x, = Math.lgamma(-1) + assert_infinity(x, "Math.lgamma(-1) should be +INF") + + x, = Math.lgamma(Float::NAN) assert_nan(x) end diff -Nru ruby3.3-3.3.8/test/ruby/test_method.rb ruby3.3-3.3.13/test/ruby/test_method.rb --- ruby3.3-3.3.8/test/ruby/test_method.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_method.rb 2026-10-23 03:17:41.000000000 +0000 @@ -111,6 +111,20 @@ end end + def test_unbound_method_equality_with_extended_module + m = Module.new { def hello; "hello"; end } + base = Class.new { extend m } + sub = Class.new(base) + + from_module = m.instance_method(:hello) + from_base = base.method(:hello).unbind + from_sub = sub.method(:hello).unbind + + assert_equal(from_module, from_base) + assert_equal(from_module, from_sub) + assert_equal(from_base, from_sub) + end + def test_callee assert_equal(:test_callee, __method__) assert_equal(:m, Class.new {def m; __method__; end}.new.m) diff -Nru ruby3.3-3.3.8/test/ruby/test_numeric.rb ruby3.3-3.3.13/test/ruby/test_numeric.rb --- ruby3.3-3.3.8/test/ruby/test_numeric.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_numeric.rb 2026-10-23 03:17:41.000000000 +0000 @@ -483,6 +483,10 @@ assert_equal(0, 0.pow(3, 1)) assert_equal(0, 2.pow(3, 1)) assert_equal(0, -2.pow(3, 1)) + + min, max = RbConfig::LIMITS.values_at("FIXNUM_MIN", "FIXNUM_MAX") + assert_equal(0, 0.pow(2, min)) + assert_equal(0, Integer.sqrt(max+1).pow(2, min)) end end diff -Nru ruby3.3-3.3.8/test/ruby/test_process.rb ruby3.3-3.3.13/test/ruby/test_process.rb --- ruby3.3-3.3.8/test/ruby/test_process.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_process.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1884,6 +1884,8 @@ end def test_daemon_noclose + pend "macOS 15 beta is not working with this test" if macos?(15) + data = IO.popen("-", "r+") do |f| break f.read if f Process.daemon(false, true) diff -Nru ruby3.3-3.3.8/test/ruby/test_refinement.rb ruby3.3-3.3.13/test/ruby/test_refinement.rb --- ruby3.3-3.3.8/test/ruby/test_refinement.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_refinement.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1939,6 +1939,29 @@ end; end + def test_public_in_refine_for_method_in_superclass + assert_separately([], "#{<<-"begin;"}\n#{<<-"end;"}") + begin; + bug21446 = '[ruby-core:122558] [Bug #21446]' + + class CowSuper + private + def moo() "Moo"; end + end + class Cow < CowSuper + end + + module PublicCows + refine(Cow) { + public :moo + } + end + + using PublicCows + assert_equal("Moo", Cow.new.moo, bug21446) + end; + end + module SuperToModule class Parent end @@ -2689,6 +2712,18 @@ assert_equal(:v2, obj.cached_foo_callsite) end + def test_refined_module_method + m = Module.new { + x = Module.new {def qux;end} + refine(x) {def qux;end} + break x + } + extend m + meth = method(:qux) + assert_equal m, meth.owner + assert_equal :qux, meth.name + end + private def eval_using(mod, s) diff -Nru ruby3.3-3.3.8/test/ruby/test_regexp.rb ruby3.3-3.3.13/test/ruby/test_regexp.rb --- ruby3.3-3.3.8/test/ruby/test_regexp.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_regexp.rb 2026-10-23 03:17:41.000000000 +0000 @@ -989,6 +989,23 @@ assert_equal('foobazquux/foobazquux', result, bug8856) end + def test_alternation_compile_error_no_memory_leak + # A compile error in the 2nd+ branch of a top-level alternation leaked the + # partially parsed branch (parse_subexp freed the alternation list but not + # the node parse_branch had built so far). Regexp#to_s reaches this path + # for every /(?:a|b)c(d)/-shaped regexp. + assert_no_memory_leak([], "#{<<~"begin;"}", "#{<<~"end;"}", "[Bug #22384]", rss: true) + code = proc do + Regexp.new("a|b(c") rescue nil + /(?:a|b)c(d)/.to_s + end + + 1_000.times(&code) + begin; + 300_000.times(&code) + end; + end + def test_ignorecase v = assert_deprecated_warning(/variable \$= is no longer effective/) { $= } assert_equal(false, v) @@ -1602,6 +1619,33 @@ assert_raise(RegexpError, bug12418){ Regexp.new('(0?0|(?(5)||)|(?(5)||))?') } end + def test_quick_search + assert_match_at('(?i) *TOOKY', 'Mozilla/5.0 (Linux; Android 4.0.3; TOOKY', [[34, 40]]) # Issue #120 + end + + def test_ss_in_look_behind + assert_match_at("(?i:ss)", "ss", [[0, 2]]) + assert_match_at("(?i:ss)", "Ss", [[0, 2]]) + assert_match_at("(?i:ss)", "SS", [[0, 2]]) + assert_match_at("(?i:ss)", "\u017fS", [[0, 2]]) # LATIN SMALL LETTER LONG S + assert_match_at("(?i:ss)", "s\u017f", [[0, 2]]) + assert_match_at("(?i:ss)", "\u00df", [[0, 1]]) # LATIN SMALL LETTER SHARP S + assert_match_at("(?i:ss)", "\u1e9e", [[0, 1]]) # LATIN CAPITAL LETTER SHARP S + assert_match_at("(?i:xssy)", "xssy", [[0, 4]]) + assert_match_at("(?i:xssy)", "xSsy", [[0, 4]]) + assert_match_at("(?i:xssy)", "xSSy", [[0, 4]]) + assert_match_at("(?i:xssy)", "x\u017fSy", [[0, 4]]) + assert_match_at("(?i:xssy)", "xs\u017fy", [[0, 4]]) + assert_match_at("(?i:xssy)", "x\u00dfy", [[0, 3]]) + assert_match_at("(?i:xssy)", "x\u1e9ey", [[0, 3]]) + assert_match_at("(?i:\u00df)", "ss", [[0, 2]]) + assert_match_at("(?i:\u00df)", "SS", [[0, 2]]) + assert_match_at("(?i:[\u00df])", "ss", [[0, 2]]) + assert_match_at("(?i:[\u00df])", "SS", [[0, 2]]) + assert_match_at("(?i)(?<!ss)\u2728", "qq\u2728", [[2, 3]]) # Issue #92 + assert_match_at("(?i)(?<!xss)\u2728", "qq\u2728", [[2, 3]]) + end + def test_options_in_look_behind assert_nothing_raised { assert_match_at("(?<=(?i)ab)cd", "ABcd", [[2,4]]) @@ -1739,6 +1783,12 @@ end; end + def test_too_big_number_for_repeat_range + assert_raise_with_message(SyntaxError, /too big number for repeat range/) do + eval(%[/|{1000000}/]) + end + end + # This assertion is for porting x2() tests in testpy.py of Onigmo. def assert_match_at(re, str, positions, msg = nil) re = Regexp.new(re) unless re.is_a?(Regexp) @@ -2107,4 +2157,28 @@ re =~ s end end + + def test_too_many_range_repeat + source = '(?:foobar){0,100}' * 100000 + assert_raise(RegexpError) { Regexp.new(source) } + assert_raise(SyntaxError) { eval("/#{source}/") } + end + + def test_too_many_null_check + source = '(?:(?:foo)?|(?:bar)?)*' * 100000 + assert_raise(RegexpError) { Regexp.new(source) } + assert_raise(SyntaxError) { eval("/#{source}/") } + end + + def test_nested_repeat_expansion_overflow + assert_separately([], "#{<<-"begin;"}\n#{<<-'end;'}", timeout: 30) + begin; + # A nested repeat whose expanded size overflows int must not be + # unrolled: the compiler used to hang or emit wrapped jump offsets. + ["(?:.{90000,}){90000}", "(?:.{46341,}){46341}"].each do |src| + re = Regexp.new(src) + assert_nil(re.match("x" * 10), src) + end + end; + end end diff -Nru ruby3.3-3.3.8/test/ruby/test_require.rb ruby3.3-3.3.13/test/ruby/test_require.rb --- ruby3.3-3.3.8/test/ruby/test_require.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_require.rb 2026-10-23 03:17:41.000000000 +0000 @@ -840,6 +840,30 @@ p :ok end; } + + # [Bug #21567] + assert_separately(%w[-rtempfile], "#{<<~"begin;"}\n#{<<~"end;"}") + begin; + class MyString + def initialize(path) + @path = path + end + + def to_str + $LOADED_FEATURES.clear + @path + end + + def to_path = @path + end + + def create_ruby_file = Tempfile.create(["test", ".rb"]).path + + require MyString.new(create_ruby_file) + $LOADED_FEATURES.unshift(create_ruby_file) + $LOADED_FEATURES << MyString.new(create_ruby_file) + require create_ruby_file + end; end def test_loading_fifo_threading_raise @@ -1011,4 +1035,18 @@ end RUBY end + + def test_bug_21568 + load_path = $LOAD_PATH.dup + loaded_featrures = $LOADED_FEATURES.dup + + $LOAD_PATH.clear + $LOADED_FEATURES.replace(["foo.so", "a/foo.rb", "b/foo.rb"]) + + assert_nothing_raised(LoadError) { require "foo" } + + ensure + $LOAD_PATH.replace(load_path) if load_path + $LOADED_FEATURES.replace loaded_featrures + end end diff -Nru ruby3.3-3.3.8/test/ruby/test_rubyoptions.rb ruby3.3-3.3.13/test/ruby/test_rubyoptions.rb --- ruby3.3-3.3.8/test/ruby/test_rubyoptions.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_rubyoptions.rb 2026-10-23 03:17:41.000000000 +0000 @@ -560,6 +560,8 @@ assert_in_out_err(%w(- -#=foo), "#!ruby -s\n", [], /invalid name for global variable - -# \(NameError\)/) + + assert_in_out_err(['-s', '-e', 'GC.start; p $DEBUG', '--', '-DEBUG=x'], "", ['"x"']) end def test_assignment_in_conditional @@ -849,7 +851,9 @@ KILL_SELF = "Process.kill :SEGV, $$" end - def assert_segv(args, message=nil, list: SEGVTest::ExpectedStderrList, **opt) + def assert_segv(args, message=nil, list: SEGVTest::ExpectedStderrList, **opt, &block) + pend "macOS 15 is not working with this assertion" if macos?(15) + # We want YJIT to be enabled in the subprocess if it's enabled for us # so that the Ruby description matches. env = Hash === args.first ? args.shift : {} @@ -858,9 +862,10 @@ args.unshift(env) test_stdin = "" + tests = [//, list] unless block - assert_in_out_err(args, test_stdin, //, list, encoding: "ASCII-8BIT", - **SEGVTest::ExecOptions, **opt) + assert_in_out_err(args, test_stdin, *tests, encoding: "ASCII-8BIT", + **SEGVTest::ExecOptions, **opt, &block) end def test_segv_test @@ -888,7 +893,9 @@ } end - def assert_crash_report(path, cmd = nil) + def assert_crash_report(path, cmd = nil, &block) + pend "macOS 15 is not working with this assertion" if macos?(15) + Dir.mktmpdir("ruby_crash_report") do |dir| list = SEGVTest::ExpectedStderrList if cmd @@ -899,7 +906,8 @@ else cmd = ['-e', SEGVTest::KILL_SELF] end - status = assert_segv([{"RUBY_CRASH_REPORT"=>path}, *cmd], list: [], chdir: dir) + status = assert_segv([{"RUBY_CRASH_REPORT"=>path}, *cmd], list: [], chdir: dir, &block) + next if block reports = Dir.glob("*.log", File::FNM_DOTMATCH, base: dir) assert_equal(1, reports.size) assert_pattern_list(list, File.read(File.join(dir, reports.first))) @@ -908,43 +916,59 @@ end def test_crash_report - assert_crash_report("%e.%f.%p.log") do |status, report| - assert_equal("#{File.basename(EnvUtil.rubybin)}.-e.#{status.pid}.log", report) - end + status, report = assert_crash_report("%e.%f.%p.log") + assert_equal("#{File.basename(EnvUtil.rubybin)}.-e.#{status.pid}.log", report) end def test_crash_report_script - assert_crash_report("%e.%f.%p.log", "bug.rb") do |status, report| - assert_equal("#{File.basename(EnvUtil.rubybin)}.bug.rb.#{status.pid}.log", report) - end + status, report = assert_crash_report("%e.%f.%p.log", "bug.rb") + assert_equal("#{File.basename(EnvUtil.rubybin)}.bug.rb.#{status.pid}.log", report) end def test_crash_report_executable_path omit if EnvUtil.rubybin.size > 245 - assert_crash_report("%E.%p.log") do |status, report| - assert_equal("#{EnvUtil.rubybin.tr('/', '!')}.#{status.pid}.log", report) - end + status, report = assert_crash_report("%E.%p.log") + path = EnvUtil.rubybin.sub(/\A\w\K:[\/\\]/, '!').tr_s('/', '!') + assert_equal("#{path}.#{status.pid}.log", report) end def test_crash_report_script_path - assert_crash_report("%F.%p.log", "test/bug.rb") do |status, report| - assert_equal("test!bug.rb.#{status.pid}.log", report) - end + status, report = assert_crash_report("%F.%p.log", "test/bug.rb") + assert_equal("test!bug.rb.#{status.pid}.log", report) end def test_crash_report_pipe + pend "macOS 15 is not working with this assertion" if macos?(15) + if File.executable?(echo = "/bin/echo") elsif /mswin|ming/ =~ RUBY_PLATFORM echo = "echo" else omit "/bin/echo not found" end - env = {"RUBY_CRASH_REPORT"=>"| #{echo} %e:%f:%p", "RUBY_ON_BUG"=>nil} - assert_in_out_err([env], SEGVTest::KILL_SELF, - encoding: "ASCII-8BIT", - **SEGVTest::ExecOptions) do |stdout, stderr, status| - assert_empty(stderr) - assert_equal(["#{File.basename(EnvUtil.rubybin)}:-:#{status.pid}"], stdout) + assert_crash_report("| #{echo} %e:%f:%p") do |stdin, stdout, status| + assert_equal(["#{File.basename(EnvUtil.rubybin)}:-e:#{status.pid}"], stdin) + end + end + + def test_crash_report_pipe_script + omit "only runs on Linux" unless RUBY_PLATFORM.include?("linux") + + Tempfile.create(["script", ".sh"]) do |script| + Tempfile.create("crash_report") do |crash_report| + script.write(<<~BASH) + #!/usr/bin/env bash + + cat > #{crash_report.path} + BASH + script.close + + FileUtils.chmod("+x", script) + + assert_crash_report("| #{script.path}") do + assert_include(File.read(crash_report.path), "[BUG] Segmentation fault at") + end + end end end diff -Nru ruby3.3-3.3.8/test/ruby/test_string.rb ruby3.3-3.3.13/test/ruby/test_string.rb --- ruby3.3-3.3.8/test/ruby/test_string.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_string.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1908,6 +1908,13 @@ result = []; S("aaa,bbb,ccc,ddd").split(/,/) {|s| result << s.gsub(/./, "A")} assert_equal(["AAA"]*4, result) + + s = S("abc ") * 20 + assert_raise(RuntimeError) { + 10.times do + s.split {s.prepend("xxx" * 100)} + end + } ensure EnvUtil.suppress_warning {$; = fs} end diff -Nru ruby3.3-3.3.8/test/ruby/test_struct.rb ruby3.3-3.3.13/test/ruby/test_struct.rb --- ruby3.3-3.3.8/test/ruby/test_struct.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_struct.rb 2026-10-23 03:17:41.000000000 +0000 @@ -548,6 +548,12 @@ CODE end + def test_frozen_subclass + test = Class.new(@Struct.new(:a)).freeze.new(a: 0) + assert_kind_of(@Struct, test) + assert_equal([:a], test.members) + end + class TopStruct < Test::Unit::TestCase include TestStruct diff -Nru ruby3.3-3.3.8/test/ruby/test_thread.rb ruby3.3-3.3.13/test/ruby/test_thread.rb --- ruby3.3-3.3.8/test/ruby/test_thread.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_thread.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1555,4 +1555,65 @@ assert_equal(true, t.pending_interrupt?(Exception)) assert_equal(false, t.pending_interrupt?(ArgumentError)) end + + # [Bug #21342] + def test_unlock_locked_mutex_with_collected_fiber + bug21127 = '[ruby-core:120930] [Bug #21127]' + assert_separately([], "#{<<~"begin;"}\n#{<<~'end;'}") + begin; + 5.times do + m = Mutex.new + Thread.new do + m.synchronize do + end + end.join + Fiber.new do + GC.start + m.lock + end.resume + end + end; + end + + def test_unlock_locked_mutex_with_collected_fiber2 + assert_separately([], "#{<<~"begin;"}\n#{<<~'end;'}") + begin; + MUTEXES = [] + 5.times do + m = Mutex.new + Fiber.new do + GC.start + m.lock + end.resume + MUTEXES << m + end + 10.times do + MUTEXES.clear + GC.start + end + end; + end + + def test_mutexes_locked_in_fiber_dont_have_aba_issue_with_new_fibers + assert_separately([], "#{<<~"begin;"}\n#{<<~'end;'}") + begin; + mutexes = 1000.times.map do + Mutex.new + end + + mutexes.map do |m| + Fiber.new do + m.lock + end.resume + end + + GC.start + + 1000.times.map do + Fiber.new do + raise "FAILED!" if mutexes.any?(&:owned?) + end.resume + end + end; + end end diff -Nru ruby3.3-3.3.8/test/ruby/test_variable.rb ruby3.3-3.3.13/test/ruby/test_variable.rb --- ruby3.3-3.3.8/test/ruby/test_variable.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_variable.rb 2026-10-23 03:17:41.000000000 +0000 @@ -393,20 +393,39 @@ @a = 1 @b = 2 @c = 3 + @d = 4 + @e = 5 + @f = 6 + @g = 7 + @h = 8 end def ivars - [@a, @b, @c] + [@a, @b, @c, @d, @e, @f, @g, @h] end end def test_external_ivars 3.times{ # check inline cache for external ivar access - assert_equal [1, 2, 3], ExIvar.new.ivars + assert_equal [1, 2, 3, 4, 5, 6, 7, 8], ExIvar.new.ivars } end + def test_exivar_resize_with_compaction_stress + omit "compaction doesn't work well on s390x" if RUBY_PLATFORM =~ /s390x/ # https://github.com/ruby/ruby/pull/5077 + objs = 10_000.times.map do + ExIvar.new + end + EnvUtil.under_gc_compact_stress do + 10.times do + x = ExIvar.new + x.instance_variable_set(:@resize, 1) + x + end + end + end + def test_local_variables_with_kwarg bug11674 = '[ruby-core:71437] [Bug #11674]' v = with_kwargs_11(v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8,v9:9,v10:10,v11:11) diff -Nru ruby3.3-3.3.8/test/ruby/test_vm_dump.rb ruby3.3-3.3.13/test/ruby/test_vm_dump.rb --- ruby3.3-3.3.8/test/ruby/test_vm_dump.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_vm_dump.rb 2026-10-23 03:17:41.000000000 +0000 @@ -4,6 +4,8 @@ class TestVMDump < Test::Unit::TestCase def assert_darwin_vm_dump_works(args) omit if RUBY_PLATFORM !~ /darwin/ + pend "macOS 15 is not working with this assertion" if macos?(15) + assert_in_out_err(args, "", [], /^\[IMPORTANT\]/) end diff -Nru ruby3.3-3.3.8/test/ruby/test_yjit.rb ruby3.3-3.3.13/test/ruby/test_yjit.rb --- ruby3.3-3.3.8/test/ruby/test_yjit.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/ruby/test_yjit.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1526,6 +1526,18 @@ assert_in_out_err(%w[--yjit-stats --yjit-disable]) end + def test_proc_block_with_kwrest + # When the bug was present this required --yjit-stats to trigger. + assert_compiles(<<~RUBY, result: {extra: 5}) + def foo = bar(w: 1, x: 2, y: 3, z: 4, extra: 5, &proc { _1 }) + def bar(w:, x:, y:, z:, **kwrest) = yield kwrest + + GC.stress = true + foo + foo + RUBY + end + private def code_gc_helpers diff -Nru ruby3.3-3.3.8/test/rubygems/test_gem_request.rb ruby3.3-3.3.13/test/rubygems/test_gem_request.rb --- ruby3.3-3.3.8/test/rubygems/test_gem_request.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/rubygems/test_gem_request.rb 2026-10-23 03:17:41.000000000 +0000 @@ -249,7 +249,7 @@ auth_header = conn.payload["Authorization"] assert_equal "Basic #{base64_encode64("{DEScede}pass:x-oauth-basic")}".strip, auth_header - assert_includes @ui.output, "GET https://REDACTED:x-oauth-basic@example.rubygems/specs.#{Gem.marshal_version}" + assert_includes @ui.output, "GET https://REDACTED@example.rubygems/specs.#{Gem.marshal_version}" end def test_fetch_head diff -Nru ruby3.3-3.3.8/test/rubygems/test_gem_uri.rb ruby3.3-3.3.13/test/rubygems/test_gem_uri.rb --- ruby3.3-3.3.8/test/rubygems/test_gem_uri.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/rubygems/test_gem_uri.rb 2026-10-23 03:17:41.000000000 +0000 @@ -21,7 +21,7 @@ end def test_redacted_with_user_x_oauth_basic - assert_equal "https://REDACTED:x-oauth-basic@example.com", Gem::Uri.new("https://token:x-oauth-basic@example.com").redacted.to_s + assert_equal "https://REDACTED@example.com", Gem::Uri.new("https://token:x-oauth-basic@example.com").redacted.to_s end def test_redacted_without_credential diff -Nru ruby3.3-3.3.8/test/socket/test_unix.rb ruby3.3-3.3.13/test/socket/test_unix.rb --- ruby3.3-3.3.8/test/socket/test_unix.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/socket/test_unix.rb 2026-10-23 03:17:41.000000000 +0000 @@ -292,14 +292,18 @@ File.unlink path if path && File.socket?(path) end - def test_open_nul_byte - tmpfile = Tempfile.new("s") - path = tmpfile.path - tmpfile.close(true) - assert_raise(ArgumentError) {UNIXServer.open(path+"\0")} - assert_raise(ArgumentError) {UNIXSocket.open(path+"\0")} - ensure - File.unlink path if path && File.socket?(path) + def test_open_argument + assert_raise(TypeError) {UNIXServer.new(nil)} + assert_raise(TypeError) {UNIXServer.new(1)} + Tempfile.create("s") do |s| + path = s.path + s.close + File.unlink(path) + assert_raise(ArgumentError) {UNIXServer.open(path+"\0")} + assert_raise(ArgumentError) {UNIXSocket.open(path+"\0")} + arg = Struct.new(:to_path).new(path) + assert_equal(path, UNIXServer.open(arg) { |server| server.path }) + end end def test_addr diff -Nru ruby3.3-3.3.8/test/test_pstore.rb ruby3.3-3.3.13/test/test_pstore.rb --- ruby3.3-3.3.8/test/test_pstore.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/test_pstore.rb 2026-10-23 03:17:41.000000000 +0000 @@ -66,6 +66,16 @@ end end + def test_data_should_be_stored_correctly_when_in_ultra_safe_mode + @pstore.ultra_safe = true + @pstore.transaction do + @pstore[:foo] = "bar" + end + @pstore.transaction(true) do + assert_equal "bar", @pstore[:foo] + end + end + def test_writing_inside_readonly_transaction_raises_error assert_raise(PStore::Error) do @pstore.transaction(true) do @@ -133,7 +143,8 @@ def test_pstore_files_are_accessed_as_binary_files bug5311 = '[ruby-core:39503]' n = 128 - assert_in_out_err(["-Eutf-8:utf-8", "-rpstore", "-", @pstore_file], <<-SRC, [bug5311], [], bug5311, timeout: 30) + top_dir = File.expand_path('../lib', __dir__) + assert_in_out_err(["-Eutf-8:utf-8", "-I#{top_dir}", "-rpstore", "-", @pstore_file], <<-SRC, [bug5311], [], bug5311, timeout: 30) @pstore = PStore.new(ARGV[0]) (1..#{n}).each do |i| @pstore.transaction {@pstore["Key\#{i}"] = "value \#{i}"} diff -Nru ruby3.3-3.3.8/test/test_unicode_normalize.rb ruby3.3-3.3.13/test/test_unicode_normalize.rb --- ruby3.3-3.3.8/test/test_unicode_normalize.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/test_unicode_normalize.rb 2026-10-23 03:17:41.000000000 +0000 @@ -209,4 +209,23 @@ assert_equal true, ascii_string.unicode_normalized?(:nfkc) assert_equal true, ascii_string.unicode_normalized?(:nfkd) end + + def test_canonical_ordering + a = "\u03B1\u0313\u0300\u0345" + a_unordered1 = "\u03B1\u0345\u0313\u0300" + a_unordered2 = "\u03B1\u0313\u0345\u0300" + u1 = "U\u0308\u0304" + u2 = "U\u0304\u0308" + s = "s\u0323\u0307" + s_unordered = "s\u0307\u0323" + o = "\u{1611e}\u{1611e}\u{1611f}" + # Actual cases called through String#unicode_normalize + assert_equal(s + o, UnicodeNormalize.canonical_ordering_one(s_unordered + o)) + assert_equal(a[1..], UnicodeNormalize.canonical_ordering_one(a_unordered1[1..])) + assert_equal(a[1..] + o, UnicodeNormalize.canonical_ordering_one(a_unordered2[1..] + o)) + # Artificial cases + assert_equal(a + u1 + o + u2 + s, UnicodeNormalize.canonical_ordering_one(a + u1 + o + u2 + s)) + assert_equal(s[1..] + a + a, UnicodeNormalize.canonical_ordering_one(s_unordered[1..] + a_unordered1 + a_unordered2)) + assert_equal(o + s + u1 + a + o + a + u2 + o, UnicodeNormalize.canonical_ordering_one(o + s_unordered + u1 + a_unordered1 + o + a_unordered2 + u2 + o)) + end end diff -Nru ruby3.3-3.3.8/test/uri/test_generic.rb ruby3.3-3.3.13/test/uri/test_generic.rb --- ruby3.3-3.3.8/test/uri/test_generic.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/uri/test_generic.rb 2026-10-23 03:17:41.000000000 +0000 @@ -272,6 +272,9 @@ u0 = URI.parse('http://new.example.org/path') u1 = u.merge('//new.example.org/path') assert_equal(u0, u1) + u0 = URI.parse('http://other@example.net') + u1 = u.merge('//other@example.net') + assert_equal(u0, u1) end def test_route @@ -737,17 +740,18 @@ def test_set_component uri = URI.parse('http://foo:bar@baz') assert_equal('oof', uri.user = 'oof') - assert_equal('http://oof:bar@baz', uri.to_s) + assert_equal('http://oof@baz', uri.to_s) assert_equal('rab', uri.password = 'rab') assert_equal('http://oof:rab@baz', uri.to_s) assert_equal('foo', uri.userinfo = 'foo') - assert_equal('http://foo:rab@baz', uri.to_s) + assert_equal('http://foo@baz', uri.to_s) assert_equal(['foo', 'bar'], uri.userinfo = ['foo', 'bar']) assert_equal('http://foo:bar@baz', uri.to_s) assert_equal(['foo'], uri.userinfo = ['foo']) - assert_equal('http://foo:bar@baz', uri.to_s) + assert_equal('http://foo@baz', uri.to_s) assert_equal('zab', uri.host = 'zab') - assert_equal('http://foo:bar@zab', uri.to_s) + assert_equal('http://zab', uri.to_s) + uri.userinfo = ['foo', 'bar'] uri.port = "" assert_nil(uri.port) uri.port = "80" @@ -757,7 +761,8 @@ uri.port = " 080 " assert_equal(80, uri.port) assert_equal(8080, uri.port = 8080) - assert_equal('http://foo:bar@zab:8080', uri.to_s) + assert_equal('http://zab:8080', uri.to_s) + uri = URI.parse('http://foo:bar@zab:8080') assert_equal('/', uri.path = '/') assert_equal('http://foo:bar@zab:8080/', uri.to_s) assert_equal('a=1', uri.query = 'a=1') diff -Nru ruby3.3-3.3.8/test/zlib/test_zlib.rb ruby3.3-3.3.13/test/zlib/test_zlib.rb --- ruby3.3-3.3.8/test/zlib/test_zlib.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/test/zlib/test_zlib.rb 2026-10-23 03:17:41.000000000 +0000 @@ -876,6 +876,25 @@ assert_equal(-1, r.pos, "[ruby-core:81488][Bug #13616]") end + def test_ungetc_buffer_underflow + initial_bufsize = 1024 + payload = "A" * initial_bufsize + gzip_io = StringIO.new + Zlib::GzipWriter.wrap(gzip_io) { |gz| gz.write(payload) } + compressed = gzip_io.string + + reader = Zlib::GzipReader.new(StringIO.new(compressed)) + reader.read(1) + overflow_bytes = "B" * (initial_bufsize) + reader.ungetc(overflow_bytes) + data = reader.read(overflow_bytes.bytesize) + assert_equal overflow_bytes.bytesize, data.bytesize, data + assert_empty data.delete("B"), data + data = reader.read() + assert_equal initial_bufsize - 1, data.bytesize, data + assert_empty data.delete("A"), data + end + def test_open Tempfile.create("test_zlib_gzip_reader_open") {|t| t.close diff -Nru ruby3.3-3.3.8/thread.c ruby3.3-3.3.13/thread.c --- ruby3.3-3.3.8/thread.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/thread.c 2026-10-23 03:17:41.000000000 +0000 @@ -435,7 +435,7 @@ th->keeping_mutexes = mutex->next_mutex; // rb_warn("mutex #<%p> was not unlocked by thread #<%p>", (void *)mutex, (void*)th); - + VM_ASSERT(mutex->fiber); const char *error_message = rb_mutex_unlock_th(mutex, th, mutex->fiber); if (error_message) rb_bug("invalid keeping_mutexes: %s", error_message); } @@ -4698,6 +4698,7 @@ terminate_atfork_i(rb_thread_t *th, const rb_thread_t *current_th) { if (th != current_th) { + rb_native_mutex_initialize(&th->interrupt_lock); rb_mutex_abandon_keeping_mutexes(th); rb_mutex_abandon_locking_mutex(th); thread_cleanup_func(th, TRUE); @@ -5589,6 +5590,7 @@ VALUE lines = RARRAY_AREF(coverage, COVERAGE_INDEX_LINES); if (lines) { long line = rb_sourceline() - 1; + VM_ASSERT(line >= 0); long count; VALUE num; void rb_iseq_clear_event_flags(const rb_iseq_t *iseq, size_t pos, rb_event_flag_t reset); diff -Nru ruby3.3-3.3.8/thread_pthread.c ruby3.3-3.3.13/thread_pthread.c --- ruby3.3-3.3.8/thread_pthread.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/thread_pthread.c 2026-10-23 03:17:41.000000000 +0000 @@ -1295,7 +1295,7 @@ { // ractor lock of cr is acquired // r is sleeping statuss - rb_thread_t *th = rb_ec_thread_ptr(ec); + rb_thread_t * volatile th = rb_ec_thread_ptr(ec); struct rb_thread_sched *sched = TH_SCHED(th); cr->sync.wait.waiting_thread = th; // TODO: multi-thread @@ -1514,6 +1514,8 @@ #endif #if defined(HAVE_WORKING_FORK) +void rb_internal_thread_event_hooks_rw_lock_atfork(void); + static void thread_sched_atfork(struct rb_thread_sched *sched) { @@ -1531,6 +1533,11 @@ vm->ractor.sched.running_cnt = 0; rb_native_mutex_initialize(&vm->ractor.sched.lock); +#if VM_CHECK_MODE > 0 + vm->ractor.sched.lock_owner = NULL; + vm->ractor.sched.locked = false; +#endif + // rb_native_cond_destroy(&vm->ractor.sched.cond); rb_native_cond_initialize(&vm->ractor.sched.cond); rb_native_cond_initialize(&vm->ractor.sched.barrier_complete_cond); @@ -1540,6 +1547,8 @@ ccan_list_head_init(&vm->ractor.sched.timeslice_threads); ccan_list_head_init(&vm->ractor.sched.running_threads); + rb_internal_thread_event_hooks_rw_lock_atfork(); + VM_ASSERT(sched->is_running); sched->is_running_timeslice = false; @@ -2821,6 +2830,17 @@ #include "thread_pthread_mn.c" +static rb_thread_t * +thread_sched_waiting_thread(struct rb_thread_sched_waiting *w) +{ + if (w) { + return (rb_thread_t *)((size_t)w - offsetof(rb_thread_t, sched.waiting_reason)); + } + else { + return NULL; + } +} + static int timer_thread_set_timeout(rb_vm_t *vm) { @@ -2850,22 +2870,29 @@ } ractor_sched_unlock(vm, NULL); - if (vm->ractor.sched.timeslice_wait_inf) { - rb_native_mutex_lock(&timer_th.waiting_lock); - { - rb_thread_t *th = ccan_list_top(&timer_th.waiting, rb_thread_t, sched.waiting_reason.node); - if (th && (th->sched.waiting_reason.flags & thread_sched_waiting_timeout)) { - rb_hrtime_t now = rb_hrtime_now(); - rb_hrtime_t hrrel = rb_hrtime_sub(th->sched.waiting_reason.data.timeout, now); + // Always check waiting threads to find minimum timeout + // even when scheduler has work (grq_cnt > 0) + rb_native_mutex_lock(&timer_th.waiting_lock); + { + struct rb_thread_sched_waiting *w = ccan_list_top(&timer_th.waiting, struct rb_thread_sched_waiting, node); + rb_thread_t *th = thread_sched_waiting_thread(w); + + if (th && (th->sched.waiting_reason.flags & thread_sched_waiting_timeout)) { + rb_hrtime_t now = rb_hrtime_now(); + rb_hrtime_t hrrel = rb_hrtime_sub(th->sched.waiting_reason.data.timeout, now); - RUBY_DEBUG_LOG("th:%u now:%lu rel:%lu", rb_th_serial(th), (unsigned long)now, (unsigned long)hrrel); + RUBY_DEBUG_LOG("th:%u now:%lu rel:%lu", rb_th_serial(th), (unsigned long)now, (unsigned long)hrrel); - // TODO: overflow? - timeout = (int)((hrrel + RB_HRTIME_PER_MSEC - 1) / RB_HRTIME_PER_MSEC); // ms + // TODO: overflow? + int thread_timeout = (int)((hrrel + RB_HRTIME_PER_MSEC - 1) / RB_HRTIME_PER_MSEC); // ms + + // Use minimum of scheduler timeout and thread sleep timeout + if (timeout < 0 || thread_timeout < timeout) { + timeout = thread_timeout; } } - rb_native_mutex_unlock(&timer_th.waiting_lock); } + rb_native_mutex_unlock(&timer_th.waiting_lock); RUBY_DEBUG_LOG("timeout:%d inf:%d", timeout, (int)vm->ractor.sched.timeslice_wait_inf); @@ -2903,22 +2930,22 @@ static rb_thread_t * timer_thread_deq_wakeup(rb_vm_t *vm, rb_hrtime_t now) { - rb_thread_t *th = ccan_list_top(&timer_th.waiting, rb_thread_t, sched.waiting_reason.node); + struct rb_thread_sched_waiting *w = ccan_list_top(&timer_th.waiting, struct rb_thread_sched_waiting, node); - if (th != NULL && - (th->sched.waiting_reason.flags & thread_sched_waiting_timeout) && - timer_thread_check_exceed(th->sched.waiting_reason.data.timeout, now)) { + if (w != NULL && + (w->flags & thread_sched_waiting_timeout) && + timer_thread_check_exceed(w->data.timeout, now)) { - RUBY_DEBUG_LOG("wakeup th:%u", rb_th_serial(th)); + RUBY_DEBUG_LOG("wakeup th:%u", rb_th_serial(thread_sched_waiting_thread(w))); // delete from waiting list - ccan_list_del_init(&th->sched.waiting_reason.node); + ccan_list_del_init(&w->node); // setup result - th->sched.waiting_reason.flags = thread_sched_waiting_none; - th->sched.waiting_reason.data.result = 0; + w->flags = thread_sched_waiting_none; + w->data.result = 0; - return th; + return thread_sched_waiting_thread(w); } return NULL; @@ -3292,6 +3319,22 @@ static pthread_rwlock_t rb_internal_thread_event_hooks_rw_lock = PTHREAD_RWLOCK_INITIALIZER; +#if defined(HAVE_WORKING_FORK) +void +rb_internal_thread_event_hooks_rw_lock_atfork(void) +{ + // After fork(), this rwlock may have been held by a now-dead thread. + // + // pthread_rwlock_destroy() on a held lock is undefined behavior, and + // pthread_rwlock_init() on an already-initialized lock is also undefined + // behavior + // + // Direct assignment of PTHREAD_RWLOCK_INITIALIZER is safe and portable. + rb_internal_thread_event_hooks_rw_lock = + (pthread_rwlock_t)PTHREAD_RWLOCK_INITIALIZER; +} +#endif + rb_internal_thread_event_hook_t * rb_internal_thread_add_event_hook(rb_internal_thread_event_callback callback, rb_event_flag_t internal_event, void *user_data) { diff -Nru ruby3.3-3.3.8/thread_pthread.h ruby3.3-3.3.13/thread_pthread.h --- ruby3.3-3.3.8/thread_pthread.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/thread_pthread.h 2026-10-23 03:17:41.000000000 +0000 @@ -17,6 +17,31 @@ #define RB_NATIVETHREAD_LOCK_INIT PTHREAD_MUTEX_INITIALIZER #define RB_NATIVETHREAD_COND_INIT PTHREAD_COND_INITIALIZER +// this data should be protected by timer_th.waiting_lock +struct rb_thread_sched_waiting { + enum thread_sched_waiting_flag { + thread_sched_waiting_none = 0x00, + thread_sched_waiting_timeout = 0x01, + thread_sched_waiting_io_read = 0x02, + thread_sched_waiting_io_write = 0x08, + thread_sched_waiting_io_force = 0x40, // ignore readable + } flags; + + struct { + // should be compat with hrtime.h +#ifdef MY_RUBY_BUILD_MAY_TIME_TRAVEL + int128_t timeout; +#else + uint64_t timeout; +#endif + int fd; // -1 for timeout only + int result; + } data; + + // connected to timer_th.waiting + struct ccan_list_node node; +}; + // per-Thead scheduler helper data struct rb_thread_sched_item { struct { @@ -38,30 +63,7 @@ struct ccan_list_node zombie_threads; } node; - // this data should be protected by timer_th.waiting_lock - struct { - enum thread_sched_waiting_flag { - thread_sched_waiting_none = 0x00, - thread_sched_waiting_timeout = 0x01, - thread_sched_waiting_io_read = 0x02, - thread_sched_waiting_io_write = 0x08, - thread_sched_waiting_io_force = 0x40, // ignore readable - } flags; - - struct { - // should be compat with hrtime.h -#ifdef MY_RUBY_BUILD_MAY_TIME_TRAVEL - int128_t timeout; -#else - uint64_t timeout; -#endif - int fd; // -1 for timeout only - int result; - } data; - - // connected to timer_th.waiting - struct ccan_list_node node; - } waiting_reason; + struct rb_thread_sched_waiting waiting_reason; bool finished; bool malloc_stack; diff -Nru ruby3.3-3.3.8/thread_pthread_mn.c ruby3.3-3.3.13/thread_pthread_mn.c --- ruby3.3-3.3.8/thread_pthread_mn.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/thread_pthread_mn.c 2026-10-23 03:17:41.000000000 +0000 @@ -533,15 +533,18 @@ verify_waiting_list(void) { #if VM_CHECK_MODE > 0 - rb_thread_t *wth, *prev_wth = NULL; - ccan_list_for_each(&timer_th.waiting, wth, sched.waiting_reason.node) { + struct rb_thread_sched_waiting *w, *prev_w = NULL; + + // waiting list's timeout order should be [1, 2, 3, ..., 0, 0, 0] + + ccan_list_for_each(&timer_th.waiting, w, node) { // fprintf(stderr, "verify_waiting_list th:%u abs:%lu\n", rb_th_serial(wth), (unsigned long)wth->sched.waiting_reason.data.timeout); - if (prev_wth) { - rb_hrtime_t timeout = wth->sched.waiting_reason.data.timeout; - rb_hrtime_t prev_timeout = prev_wth->sched.waiting_reason.data.timeout; + if (prev_w) { + rb_hrtime_t timeout = w->data.timeout; + rb_hrtime_t prev_timeout = w->data.timeout; VM_ASSERT(timeout == 0 || prev_timeout <= timeout); } - prev_wth = wth; + prev_w = w; } #endif } @@ -619,16 +622,17 @@ static bool kqueue_already_registered(int fd) { - rb_thread_t *wth, *found_wth = NULL; - ccan_list_for_each(&timer_th.waiting, wth, sched.waiting_reason.node) { + struct rb_thread_sched_waiting *w, *found_w = NULL; + + ccan_list_for_each(&timer_th.waiting, w, node) { // Similar to EEXIST in epoll_ctl, but more strict because it checks fd rather than flags // for simplicity - if (wth->sched.waiting_reason.flags && wth->sched.waiting_reason.data.fd == fd) { - found_wth = wth; + if (w->flags && w->data.fd == fd) { + found_w = w; break; } } - return found_wth != NULL; + return found_w != NULL; } #endif // HAVE_SYS_EVENT_H @@ -773,20 +777,20 @@ VM_ASSERT(flags & thread_sched_waiting_timeout); // insert th to sorted list (TODO: O(n)) - rb_thread_t *wth, *prev_wth = NULL; + struct rb_thread_sched_waiting *w, *prev_w = NULL; - ccan_list_for_each(&timer_th.waiting, wth, sched.waiting_reason.node) { - if ((wth->sched.waiting_reason.flags & thread_sched_waiting_timeout) && - wth->sched.waiting_reason.data.timeout < abs) { - prev_wth = wth; + ccan_list_for_each(&timer_th.waiting, w, node) { + if ((w->flags & thread_sched_waiting_timeout) && + w->data.timeout < abs) { + prev_w = w; } else { break; } } - if (prev_wth) { - ccan_list_add_after(&timer_th.waiting, &prev_wth->sched.waiting_reason.node, &th->sched.waiting_reason.node); + if (prev_w) { + ccan_list_add_after(&timer_th.waiting, &prev_w->node, &th->sched.waiting_reason.node); } else { ccan_list_add(&timer_th.waiting, &th->sched.waiting_reason.node); @@ -794,8 +798,8 @@ verify_waiting_list(); - // update timeout seconds - timer_thread_wakeup(); + // update timeout seconds; force wake so timer thread notices short deadlines + timer_thread_wakeup_force(); } } else { diff -Nru ruby3.3-3.3.8/thread_sync.c ruby3.3-3.3.13/thread_sync.c --- ruby3.3-3.3.8/thread_sync.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/thread_sync.c 2026-10-23 03:17:41.000000000 +0000 @@ -8,6 +8,7 @@ /* Mutex */ typedef struct rb_mutex_struct { rb_fiber_t *fiber; + VALUE thread; // even if the fiber is collected, we might need access to the thread in mutex_free struct rb_mutex_struct *next_mutex; struct ccan_list_head waitq; /* protected by GVL */ } rb_mutex_t; @@ -106,8 +107,6 @@ * */ -#define mutex_mark ((void(*)(void*))0) - static size_t rb_mutex_num_waiting(rb_mutex_t *mutex) { @@ -123,13 +122,39 @@ rb_thread_t* rb_fiber_threadptr(const rb_fiber_t *fiber); +static bool +locked_p(rb_mutex_t *mutex) +{ + return mutex->fiber != 0; +} + +static void +mutex_mark(void *ptr) +{ + rb_mutex_t *mutex = ptr; + VALUE fiber; + if (locked_p(mutex)) { + fiber = rb_fiberptr_self(mutex->fiber); // rb_fiber_t* doesn't move along with fiber object + if (fiber) rb_gc_mark_movable(fiber); + rb_gc_mark_movable(mutex->thread); + } +} + +static void +mutex_compact(void *ptr) +{ + rb_mutex_t *mutex = ptr; + if (locked_p(mutex)) { + mutex->thread = rb_gc_location(mutex->thread); + } +} + static void mutex_free(void *ptr) { rb_mutex_t *mutex = ptr; - if (mutex->fiber) { - /* rb_warn("free locked mutex"); */ - const char *err = rb_mutex_unlock_th(mutex, rb_fiber_threadptr(mutex->fiber), mutex->fiber); + if (locked_p(mutex)) { + const char *err = rb_mutex_unlock_th(mutex, rb_thread_ptr(mutex->thread), mutex->fiber); if (err) rb_bug("%s", err); } ruby_xfree(ptr); @@ -143,7 +168,7 @@ static const rb_data_type_t mutex_data_type = { "mutex", - {mutex_mark, mutex_free, mutex_memsize,}, + {mutex_mark, mutex_free, mutex_memsize, mutex_compact,}, 0, 0, RUBY_TYPED_WB_PROTECTED | RUBY_TYPED_FREE_IMMEDIATELY }; @@ -204,12 +229,13 @@ { rb_mutex_t *mutex = mutex_ptr(self); - return RBOOL(mutex->fiber); + return RBOOL(locked_p(mutex)); } static void thread_mutex_insert(rb_thread_t *thread, rb_mutex_t *mutex) { + RUBY_ASSERT(!mutex->next_mutex); if (thread->keeping_mutexes) { mutex->next_mutex = thread->keeping_mutexes; } @@ -234,10 +260,24 @@ } static void -mutex_locked(rb_thread_t *th, VALUE self) +mutex_set_owner(VALUE self, rb_thread_t *th, rb_fiber_t *fiber) +{ + rb_mutex_t *mutex = mutex_ptr(self); + + mutex->thread = th->self; + mutex->fiber = fiber; + RB_OBJ_WRITTEN(self, Qundef, th->self); + if (fiber) { + RB_OBJ_WRITTEN(self, Qundef, rb_fiberptr_self(fiber)); + } +} + +static void +mutex_locked(rb_thread_t *th, rb_fiber_t *fiber, VALUE self) { rb_mutex_t *mutex = mutex_ptr(self); + mutex_set_owner(self, th, fiber); thread_mutex_insert(th, mutex); } @@ -258,9 +298,8 @@ rb_fiber_t *fiber = GET_EC()->fiber_ptr; rb_thread_t *th = GET_THREAD(); - mutex->fiber = fiber; - mutex_locked(th, self); + mutex_locked(th, fiber, self); return Qtrue; } else { @@ -328,7 +367,7 @@ rb_ensure(call_rb_fiber_scheduler_block, self, delete_from_waitq, (VALUE)&sync_waiter); if (!mutex->fiber) { - mutex->fiber = fiber; + mutex_set_owner(self, th, fiber); } } else { @@ -358,6 +397,7 @@ rb_ractor_sleeper_threads_inc(th->ractor); rb_check_deadlock(th->ractor); + RUBY_ASSERT(!th->locking_mutex); th->locking_mutex = self; ccan_list_add_tail(&mutex->waitq, &sync_waiter.node); @@ -368,7 +408,7 @@ // unlocked by another thread while sleeping if (!mutex->fiber) { - mutex->fiber = fiber; + mutex_set_owner(self, th, fiber); } rb_ractor_sleeper_threads_dec(th->ractor); @@ -382,10 +422,13 @@ if (interruptible_p) { /* release mutex before checking for interrupts...as interrupt checking * code might call rb_raise() */ - if (mutex->fiber == fiber) mutex->fiber = 0; + if (mutex->fiber == fiber) { + mutex->thread = Qfalse; + mutex->fiber = NULL; + } RUBY_VM_CHECK_INTS_BLOCKING(th->ec); /* may release mutex */ if (!mutex->fiber) { - mutex->fiber = fiber; + mutex_set_owner(self, th, fiber); } } else { @@ -404,7 +447,7 @@ } if (saved_ints) th->ec->interrupt_flag = saved_ints; - if (mutex->fiber == fiber) mutex_locked(th, self); + if (mutex->fiber == fiber) mutex_locked(th, fiber, self); } RUBY_DEBUG_LOG("%p locked", mutex); diff -Nru ruby3.3-3.3.8/tool/bundler/dev_gems.rb ruby3.3-3.3.13/tool/bundler/dev_gems.rb --- ruby3.3-3.3.8/tool/bundler/dev_gems.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/tool/bundler/dev_gems.rb 2026-10-23 03:17:41.000000000 +0000 @@ -4,7 +4,7 @@ gem "test-unit", "~> 3.0" gem "rake", "~> 13.1" -gem "rb_sys" +gem "rb_sys", "0.9.124" gem "webrick", "~> 1.6" gem "turbo_tests", "~> 2.2.3" diff -Nru ruby3.3-3.3.8/tool/bundler/vendor_gems.rb ruby3.3-3.3.13/tool/bundler/vendor_gems.rb --- ruby3.3-3.3.8/tool/bundler/vendor_gems.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/tool/bundler/vendor_gems.rb 2026-10-23 03:17:41.000000000 +0000 @@ -13,3 +13,4 @@ gem "timeout", "0.4.1" gem "thor", "1.3.0" gem "tsort", "0.2.0" +gem "uri", "0.13.3" diff -Nru ruby3.3-3.3.8/tool/commit-mail.rb ruby3.3-3.3.13/tool/commit-mail.rb --- ruby3.3-3.3.8/tool/commit-mail.rb 1970-01-01 00:00:00.000000000 +0000 +++ ruby3.3-3.3.13/tool/commit-mail.rb 2026-10-23 03:17:41.000000000 +0000 @@ -0,0 +1,399 @@ +#!/usr/bin/env ruby + +require "optparse" +require "ostruct" +require "nkf" +require "shellwords" + +CommitEmailInfo = Struct.new( + :author, + :author_email, + :revision, + :entire_sha256, + :date, + :log, + :branch, + :diffs, + :added_files, :deleted_files, :updated_files, + :added_dirs, :deleted_dirs, :updated_dirs, +) + +class GitInfoBuilder + GitCommandFailure = Class.new(RuntimeError) + + def initialize(repo_path) + @repo_path = repo_path + end + + def build(oldrev, newrev, refname) + diffs = build_diffs(oldrev, newrev) + + info = CommitEmailInfo.new + info.author = git_show(newrev, format: '%an') + info.author_email = normalize_email(git_show(newrev, format: '%aE')) + info.revision = newrev[0...10] + info.entire_sha256 = newrev + info.date = Time.at(Integer(git_show(newrev, format: '%at'))) + info.log = git_show(newrev, format: '%B') + info.branch = git('rev-parse', '--symbolic', '--abbrev-ref', refname).strip + info.diffs = diffs + info.added_files = find_files(diffs, status: :added) + info.deleted_files = find_files(diffs, status: :deleted) + info.updated_files = find_files(diffs, status: :modified) + info.added_dirs = [] # git does not deal with directory + info.deleted_dirs = [] # git does not deal with directory + info.updated_dirs = [] # git does not deal with directory + info + end + + private + + # Force git-svn email address to @ruby-lang.org to avoid email bounce by invalid email address. + def normalize_email(email) + if email.match(/\A[^@]+@\h{8}-\h{4}-\h{4}-\h{4}-\h{12}\z/) # git-svn + svn_user, _ = email.split('@', 2) + "#{svn_user}@ruby-lang.org" + else + email + end + end + + def find_files(diffs, status:) + files = [] + diffs.each do |path, values| + if values.keys.first == status + files << path + end + end + files + end + + # SVN version: + # { + # "filename" => { + # "[modified|added|deleted|copied|property_changed]" => { + # type: "[modified|added|deleted|copied|property_changed]", + # body: "diff body", # not implemented because not used + # added: Integer, + # deleted: Integer, + # } + # } + # } + def build_diffs(oldrev, newrev) + diffs = {} + + numstats = git('diff', '--numstat', oldrev, newrev).lines.map { |l| l.strip.split("\t", 3) } + git('diff', '--name-status', oldrev, newrev).each_line do |line| + status, path, _newpath = line.strip.split("\t", 3) + diff = build_diff(path, numstats) + + case status + when 'A' + diffs[path] = { added: { type: :added, **diff } } + when 'M' + diffs[path] = { modified: { type: :modified, **diff } } + when 'C' + diffs[path] = { copied: { type: :copied, **diff } } + when 'D' + diffs[path] = { deleted: { type: :deleted, **diff } } + when /\AR/ # R100 (which does not exist in git.ruby-lang.org's git 2.1.4) + # TODO: implement something + else + $stderr.puts "unexpected git diff status: #{status}" + end + end + + diffs + end + + def build_diff(path, numstats) + diff = { added: 0, deleted: 0 } # :body not implemented because not used + line = numstats.find { |(_added, _deleted, file, *)| file == path } + return diff if line.nil? + + added, deleted, _ = line + if added + diff[:added] = Integer(added) + end + if deleted + diff[:deleted] = Integer(deleted) + end + diff + end + + def git_show(revision, format:) + git('show', "--pretty=#{format}", '--no-patch', revision).strip + end + + def git(*args) + command = ['git', '-C', @repo_path, *args] + output = with_gitenv { IO.popen(command, external_encoding: 'UTF-8', &:read) } + unless $?.success? + raise GitCommandFailure, "failed to execute '#{command.join(' ')}':\n#{output}" + end + output + end + + def with_gitenv + orig = ENV.to_h.dup + begin + ENV.delete('GIT_DIR') + yield + ensure + ENV.replace(orig) + end + end +end + +CommitEmail = Module.new +class << CommitEmail + SENDMAIL = ENV.fetch('SENDMAIL', '/usr/sbin/sendmail') + private_constant :SENDMAIL + + def parse(args) + options = OpenStruct.new + options.error_to = nil + options.viewvc_uri = nil + + opts = OptionParser.new do |opts| + opts.separator('') + + opts.on('-e', '--error-to [TO]', + 'Add [TO] to to address when error is occurred') do |to| + options.error_to = to + end + + opts.on('--viewer-uri [URI]', + 'Use [URI] as URI of revision viewer') do |uri| + options.viewer_uri = uri + end + + opts.on_tail('--help', 'Show this message') do + puts opts + exit + end + end + + return opts.parse(args), options + end + + def main(repo_path, to, rest) + args, options = parse(rest) + + infos = args.each_slice(3).flat_map do |oldrev, newrev, refname| + revisions = IO.popen(['git', 'log', '--reverse', '--pretty=%H', "#{oldrev}^..#{newrev}"], &:read).lines.map(&:strip) + revisions[0..-2].zip(revisions[1..-1]).map do |old, new| + GitInfoBuilder.new(repo_path).build(old, new, refname) + end + end + + infos.each do |info| + next if info.branch.start_with?('notes/') + puts "#{info.branch}: #{info.revision} (#{info.author})" + + from = make_from(name: info.author, email: "noreply@ruby-lang.org") + sendmail(to, from, make_mail(to, from, info, viewer_uri: options.viewer_uri)) + end + end + + def sendmail(to, from, mail) + IO.popen([*SENDMAIL.shellsplit, to], 'w') do |f| + f.print(mail) + end + unless $?.success? + raise "Failed to run `#{SENDMAIL} #{to}` with: '#{mail}'" + end + end + + private + + def b_encode(str) + NKF.nkf('-WwM', str) + end + + def make_body(info, viewer_uri:) + body = '' + body << "#{info.author}\t#{format_time(info.date)}\n" + body << "\n" + body << " New Revision: #{info.revision}\n" + body << "\n" + body << " #{viewer_uri}#{info.revision}\n" + body << "\n" + body << " Log:\n" + body << info.log.lstrip.gsub(/^\t*/, ' ').rstrip + body << "\n\n" + body << added_dirs(info) + body << added_files(info) + body << deleted_dirs(info) + body << deleted_files(info) + body << modified_dirs(info) + body << modified_files(info) + [body.rstrip].pack('M') + end + + def format_time(time) + time.strftime('%Y-%m-%d %X %z (%a, %d %b %Y)') + end + + def changed_items(title, type, items) + rv = '' + unless items.empty? + rv << " #{title} #{type}:\n" + rv << items.collect {|item| " #{item}\n"}.join('') + end + rv + end + + def changed_files(title, files) + changed_items(title, 'files', files) + end + + def added_files(info) + changed_files('Added', info.added_files) + end + + def deleted_files(info) + changed_files('Removed', info.deleted_files) + end + + def modified_files(info) + changed_files('Modified', info.updated_files) + end + + def changed_dirs(title, files) + changed_items(title, 'directories', files) + end + + def added_dirs(info) + changed_dirs('Added', info.added_dirs) + end + + def deleted_dirs(info) + changed_dirs('Removed', info.deleted_dirs) + end + + def modified_dirs(info) + changed_dirs('Modified', info.updated_dirs) + end + + def changed_dirs_info(info, uri) + rev = info.revision + (info.added_dirs.collect do |dir| + " Added: #{dir}\n" + end + info.deleted_dirs.collect do |dir| + " Deleted: #{dir}\n" + end + info.updated_dirs.collect do |dir| + " Modified: #{dir}\n" + end).join("\n") + end + + def diff_info(info, uri) + info.diffs.collect do |key, values| + [ + key, + values.collect do |type, value| + case type + when :added + command = 'cat' + rev = "?revision=#{info.revision}&view=markup" + when :modified, :property_changed + command = 'diff' + prev_revision = (info.revision.is_a?(Integer) ? info.revision - 1 : "#{info.revision}^") + rev = "?r1=#{info.revision}&r2=#{prev_revision}&diff_format=u" + when :deleted, :copied + command = 'cat' + rev = '' + else + raise "unknown diff type: #{value[:type]}" + end + + link = [uri, key.sub(/ .+/, '') || ''].join('/') + rev + + desc = '' + + [desc, link] + end + ] + end + end + + def make_header(to, from, info) + headers = [] + headers << x_author(info) + headers << x_repository(info) + headers << x_revision(info) + headers << x_id(info) + headers << 'Mime-Version: 1.0' + headers << 'Content-Type: text/plain; charset=utf-8' + headers << 'Content-Transfer-Encoding: quoted-printable' + headers << "From: #{from}" + headers << "To: #{to}" + headers << "Subject: #{make_subject(info)}" + headers.find_all do |header| + /\A\s*\z/ !~ header + end.join("\n") + end + + def make_subject(info) + subject = '' + subject << "#{info.revision}" + subject << " (#{info.branch})" + subject << ': ' + subject << info.log.lstrip.lines.first.to_s.strip + b_encode(subject) + end + + # https://tools.ietf.org/html/rfc822#section-4.1 + # https://tools.ietf.org/html/rfc822#section-6.1 + # https://tools.ietf.org/html/rfc822#appendix-D + # https://tools.ietf.org/html/rfc2047 + def make_from(name:, email:) + if name.ascii_only? + escaped_name = name.gsub(/["\\\n]/) { |c| "\\#{c}" } + %Q["#{escaped_name}" <#{email}>] + else + escaped_name = "=?UTF-8?B?#{NKF.nkf('-WwMB', name)}?=" + %Q[#{escaped_name} <#{email}>] + end + end + + def x_author(info) + "X-SVN-Author: #{b_encode(info.author)}" + end + + def x_repository(info) + 'X-SVN-Repository: XXX' + end + + def x_id(info) + "X-SVN-Commit-Id: #{info.entire_sha256}" + end + + def x_revision(info) + "X-SVN-Revision: #{info.revision}" + end + + def make_mail(to, from, info, viewer_uri:) + "#{make_header(to, from, info)}\n#{make_body(info, viewer_uri: viewer_uri)}" + end +end + +repo_path, to, *rest = ARGV +begin + CommitEmail.main(repo_path, to, rest) +rescue StandardError => e + $stderr.puts "#{e.class}: #{e.message}" + $stderr.puts e.backtrace + + _, options = CommitEmail.parse(rest) + to = options.error_to + CommitEmail.sendmail(to, to, <<-MAIL) +From: #{to} +To: #{to} +Subject: Error + +#{$!.class}: #{$!.message} +#{$@.join("\n")} +MAIL + exit 1 +end diff -Nru ruby3.3-3.3.8/tool/config.guess ruby3.3-3.3.13/tool/config.guess --- ruby3.3-3.3.8/tool/config.guess 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/tool/config.guess 2026-10-23 03:17:41.000000000 +0000 @@ -1,12 +1,14 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright 1992-2021 Free Software Foundation, Inc. +# Copyright 1992-2022 Free Software Foundation, Inc. -timestamp='2021-01-25' +# shellcheck disable=SC2006,SC2268 # see below for rationale + +timestamp='2022-01-09' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or +# the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but @@ -32,7 +34,15 @@ # Please send patches to <config-patches@gnu.org>. -me=$(echo "$0" | sed -e 's,.*/,,') +# The "shellcheck disable" line above the timestamp inhibits complaints +# about features and limitations of the classic Bourne shell that were +# superseded or lifted in POSIX. However, this script identifies a wide +# variety of pre-POSIX systems that do not have POSIX shells at all, and +# even some reasonably current systems (Solaris 10 as case-in-point) still +# have a pre-POSIX /bin/sh. + + +me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] @@ -50,7 +60,7 @@ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright 1992-2021 Free Software Foundation, Inc. +Copyright 1992-2022 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -84,6 +94,9 @@ exit 1 fi +# Just in case it came from the environment. +GUESS= + # CC_FOR_BUILD -- compiler used by this script. Note that the use of a # compiler to aid in system detection is discouraged as it requires # temporary files to be created and, as you can see below, it is a @@ -102,8 +115,8 @@ # prevent multiple calls if $tmp is already set test "$tmp" && return 0 : "${TMPDIR=/tmp}" - # shellcheck disable=SC2039 - { tmp=$( (umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null) && test -n "$tmp" && test -d "$tmp" ; } || + # shellcheck disable=SC2039,SC3028 + { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir "$tmp" 2>/dev/null) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir "$tmp" 2>/dev/null) && echo "Warning: creating insecure temp directory" >&2 ; } || { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } @@ -112,7 +125,7 @@ ,,) echo "int x;" > "$dummy.c" for driver in cc gcc c89 c99 ; do if ($driver -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then - CC_FOR_BUILD="$driver" + CC_FOR_BUILD=$driver break fi done @@ -131,12 +144,12 @@ PATH=$PATH:/.attbin ; export PATH fi -UNAME_MACHINE=$( (uname -m) 2>/dev/null) || UNAME_MACHINE=unknown -UNAME_RELEASE=$( (uname -r) 2>/dev/null) || UNAME_RELEASE=unknown -UNAME_SYSTEM=$( (uname -s) 2>/dev/null) || UNAME_SYSTEM=unknown -UNAME_VERSION=$( (uname -v) 2>/dev/null) || UNAME_VERSION=unknown +UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown +UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown +UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown +UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown -case "$UNAME_SYSTEM" in +case $UNAME_SYSTEM in Linux|GNU|GNU/*) LIBC=unknown @@ -157,7 +170,8 @@ #endif #endif EOF - eval "$($CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g')" + cc_set_libc=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'` + eval "$cc_set_libc" # Second heuristic to detect musl libc. if [ "$LIBC" = unknown ] && @@ -176,7 +190,7 @@ # Note: order is significant - the case branches are not exclusive. -case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in +case $UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, @@ -188,11 +202,11 @@ # # Note: NetBSD doesn't particularly care about the vendor # portion of the name. We always set it to "unknown". - UNAME_MACHINE_ARCH=$( (uname -p 2>/dev/null || \ + UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \ /sbin/sysctl -n hw.machine_arch 2>/dev/null || \ /usr/sbin/sysctl -n hw.machine_arch 2>/dev/null || \ - echo unknown)) - case "$UNAME_MACHINE_ARCH" in + echo unknown)` + case $UNAME_MACHINE_ARCH in aarch64eb) machine=aarch64_be-unknown ;; armeb) machine=armeb-unknown ;; arm*) machine=arm-unknown ;; @@ -200,15 +214,15 @@ sh3eb) machine=sh-unknown ;; sh5el) machine=sh5le-unknown ;; earmv*) - arch=$(echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,') - endian=$(echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p') - machine="${arch}${endian}"-unknown + arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'` + endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'` + machine=${arch}${endian}-unknown ;; - *) machine="$UNAME_MACHINE_ARCH"-unknown ;; + *) machine=$UNAME_MACHINE_ARCH-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently (or will in the future) and ABI. - case "$UNAME_MACHINE_ARCH" in + case $UNAME_MACHINE_ARCH in earm*) os=netbsdelf ;; @@ -229,10 +243,10 @@ ;; esac # Determine ABI tags. - case "$UNAME_MACHINE_ARCH" in + case $UNAME_MACHINE_ARCH in earm*) expr='s/^earmv[0-9]/-eabi/;s/eb$//' - abi=$(echo "$UNAME_MACHINE_ARCH" | sed -e "$expr") + abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"` ;; esac # The OS release @@ -240,76 +254,82 @@ # thus, need a distinct triplet. However, they do not need # kernel version information, so it can be replaced with a # suitable tag, in the style of linux-gnu. - case "$UNAME_VERSION" in + case $UNAME_VERSION in Debian*) release='-gnu' ;; *) - release=$(echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2) + release=`echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2` ;; esac # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. - echo "$machine-${os}${release}${abi-}" - exit ;; + GUESS=$machine-${os}${release}${abi-} + ;; *:Bitrig:*:*) - UNAME_MACHINE_ARCH=$(arch | sed 's/Bitrig.//') - echo "$UNAME_MACHINE_ARCH"-unknown-bitrig"$UNAME_RELEASE" - exit ;; + UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` + GUESS=$UNAME_MACHINE_ARCH-unknown-bitrig$UNAME_RELEASE + ;; *:OpenBSD:*:*) - UNAME_MACHINE_ARCH=$(arch | sed 's/OpenBSD.//') - echo "$UNAME_MACHINE_ARCH"-unknown-openbsd"$UNAME_RELEASE" - exit ;; + UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` + GUESS=$UNAME_MACHINE_ARCH-unknown-openbsd$UNAME_RELEASE + ;; + *:SecBSD:*:*) + UNAME_MACHINE_ARCH=`arch | sed 's/SecBSD.//'` + GUESS=$UNAME_MACHINE_ARCH-unknown-secbsd$UNAME_RELEASE + ;; *:LibertyBSD:*:*) - UNAME_MACHINE_ARCH=$(arch | sed 's/^.*BSD\.//') - echo "$UNAME_MACHINE_ARCH"-unknown-libertybsd"$UNAME_RELEASE" - exit ;; + UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'` + GUESS=$UNAME_MACHINE_ARCH-unknown-libertybsd$UNAME_RELEASE + ;; *:MidnightBSD:*:*) - echo "$UNAME_MACHINE"-unknown-midnightbsd"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-midnightbsd$UNAME_RELEASE + ;; *:ekkoBSD:*:*) - echo "$UNAME_MACHINE"-unknown-ekkobsd"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-ekkobsd$UNAME_RELEASE + ;; *:SolidBSD:*:*) - echo "$UNAME_MACHINE"-unknown-solidbsd"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-solidbsd$UNAME_RELEASE + ;; *:OS108:*:*) - echo "$UNAME_MACHINE"-unknown-os108_"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-os108_$UNAME_RELEASE + ;; macppc:MirBSD:*:*) - echo powerpc-unknown-mirbsd"$UNAME_RELEASE" - exit ;; + GUESS=powerpc-unknown-mirbsd$UNAME_RELEASE + ;; *:MirBSD:*:*) - echo "$UNAME_MACHINE"-unknown-mirbsd"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-mirbsd$UNAME_RELEASE + ;; *:Sortix:*:*) - echo "$UNAME_MACHINE"-unknown-sortix - exit ;; + GUESS=$UNAME_MACHINE-unknown-sortix + ;; *:Twizzler:*:*) - echo "$UNAME_MACHINE"-unknown-twizzler - exit ;; + GUESS=$UNAME_MACHINE-unknown-twizzler + ;; *:Redox:*:*) - echo "$UNAME_MACHINE"-unknown-redox - exit ;; + GUESS=$UNAME_MACHINE-unknown-redox + ;; mips:OSF1:*.*) - echo mips-dec-osf1 - exit ;; + GUESS=mips-dec-osf1 + ;; alpha:OSF1:*:*) + # Reset EXIT trap before exiting to avoid spurious non-zero exit code. + trap '' 0 case $UNAME_RELEASE in *4.0) - UNAME_RELEASE=$(/usr/sbin/sizer -v | awk '{print $3}') + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; *5.*) - UNAME_RELEASE=$(/usr/sbin/sizer -v | awk '{print $4}') + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac # According to Compaq, /usr/sbin/psrinfo has been available on # OSF/1 and Tru64 systems produced since 1995. I hope that # covers most systems running today. This code pipes the CPU # types through head -n 1, so we only detect the type of CPU 0. - ALPHA_CPU_TYPE=$(/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1) - case "$ALPHA_CPU_TYPE" in + ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` + case $ALPHA_CPU_TYPE in "EV4 (21064)") UNAME_MACHINE=alpha ;; "EV4.5 (21064)") @@ -346,68 +366,69 @@ # A Tn.n version is a released field test version. # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. - echo "$UNAME_MACHINE"-dec-osf"$(echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz)" - # Reset EXIT trap before exiting to avoid spurious non-zero exit code. - exitcode=$? - trap '' 0 - exit $exitcode ;; + OSF_REL=`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` + GUESS=$UNAME_MACHINE-dec-osf$OSF_REL + ;; Amiga*:UNIX_System_V:4.0:*) - echo m68k-unknown-sysv4 - exit ;; + GUESS=m68k-unknown-sysv4 + ;; *:[Aa]miga[Oo][Ss]:*:*) - echo "$UNAME_MACHINE"-unknown-amigaos - exit ;; + GUESS=$UNAME_MACHINE-unknown-amigaos + ;; *:[Mm]orph[Oo][Ss]:*:*) - echo "$UNAME_MACHINE"-unknown-morphos - exit ;; + GUESS=$UNAME_MACHINE-unknown-morphos + ;; *:OS/390:*:*) - echo i370-ibm-openedition - exit ;; + GUESS=i370-ibm-openedition + ;; *:z/VM:*:*) - echo s390-ibm-zvmoe - exit ;; + GUESS=s390-ibm-zvmoe + ;; *:OS400:*:*) - echo powerpc-ibm-os400 - exit ;; + GUESS=powerpc-ibm-os400 + ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) - echo arm-acorn-riscix"$UNAME_RELEASE" - exit ;; + GUESS=arm-acorn-riscix$UNAME_RELEASE + ;; arm*:riscos:*:*|arm*:RISCOS:*:*) - echo arm-unknown-riscos - exit ;; + GUESS=arm-unknown-riscos + ;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) - echo hppa1.1-hitachi-hiuxmpp - exit ;; + GUESS=hppa1.1-hitachi-hiuxmpp + ;; Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. - if test "$( (/bin/universe) 2>/dev/null)" = att ; then - echo pyramid-pyramid-sysv3 - else - echo pyramid-pyramid-bsd - fi - exit ;; + case `(/bin/universe) 2>/dev/null` in + att) GUESS=pyramid-pyramid-sysv3 ;; + *) GUESS=pyramid-pyramid-bsd ;; + esac + ;; NILE*:*:*:dcosx) - echo pyramid-pyramid-svr4 - exit ;; + GUESS=pyramid-pyramid-svr4 + ;; DRS?6000:unix:4.0:6*) - echo sparc-icl-nx6 - exit ;; + GUESS=sparc-icl-nx6 + ;; DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) - case $(/usr/bin/uname -p) in - sparc) echo sparc-icl-nx7; exit ;; - esac ;; + case `/usr/bin/uname -p` in + sparc) GUESS=sparc-icl-nx7 ;; + esac + ;; s390x:SunOS:*:*) - echo "$UNAME_MACHINE"-ibm-solaris2"$(echo "$UNAME_RELEASE" | sed -e 's/[^.]*//')" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` + GUESS=$UNAME_MACHINE-ibm-solaris2$SUN_REL + ;; sun4H:SunOS:5.*:*) - echo sparc-hal-solaris2"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` + GUESS=sparc-hal-solaris2$SUN_REL + ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) - echo sparc-sun-solaris2"$(echo "$UNAME_RELEASE" | sed -e 's/[^.]*//')" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` + GUESS=sparc-sun-solaris2$SUN_REL + ;; i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) - echo i386-pc-auroraux"$UNAME_RELEASE" - exit ;; + GUESS=i386-pc-auroraux$UNAME_RELEASE + ;; i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) set_cc_for_build SUN_ARCH=i386 @@ -416,47 +437,50 @@ # This test works for both compilers. if test "$CC_FOR_BUILD" != no_compiler_found; then if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ + (CCOPTS="" $CC_FOR_BUILD -m64 -E - 2>/dev/null) | \ grep IS_64BIT_ARCH >/dev/null then SUN_ARCH=x86_64 fi fi - echo "$SUN_ARCH"-pc-solaris2"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` + GUESS=$SUN_ARCH-pc-solaris2$SUN_REL + ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize # SunOS6. Hard to guess exactly what SunOS6 will be like, but # it's likely to be more like Solaris than SunOS4. - echo sparc-sun-solaris3"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` + GUESS=sparc-sun-solaris3$SUN_REL + ;; sun4*:SunOS:*:*) - case "$(/usr/bin/arch -k)" in + case `/usr/bin/arch -k` in Series*|S4*) - UNAME_RELEASE=$(uname -v) + UNAME_RELEASE=`uname -v` ;; esac # Japanese Language versions have a version number like `4.1.3-JL'. - echo sparc-sun-sunos"$(echo "$UNAME_RELEASE"|sed -e 's/-/_/')" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/'` + GUESS=sparc-sun-sunos$SUN_REL + ;; sun3*:SunOS:*:*) - echo m68k-sun-sunos"$UNAME_RELEASE" - exit ;; + GUESS=m68k-sun-sunos$UNAME_RELEASE + ;; sun*:*:4.2BSD:*) - UNAME_RELEASE=$( (sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null) + UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3 - case "$(/bin/arch)" in + case `/bin/arch` in sun3) - echo m68k-sun-sunos"$UNAME_RELEASE" + GUESS=m68k-sun-sunos$UNAME_RELEASE ;; sun4) - echo sparc-sun-sunos"$UNAME_RELEASE" + GUESS=sparc-sun-sunos$UNAME_RELEASE ;; esac - exit ;; + ;; aushp:SunOS:*:*) - echo sparc-auspex-sunos"$UNAME_RELEASE" - exit ;; + GUESS=sparc-auspex-sunos$UNAME_RELEASE + ;; # The situation for MiNT is a little confusing. The machine name # can be virtually everything (everything which is not # "atarist" or "atariste" at least should have a processor @@ -466,41 +490,41 @@ # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint"$UNAME_RELEASE" - exit ;; + GUESS=m68k-atari-mint$UNAME_RELEASE + ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint"$UNAME_RELEASE" - exit ;; + GUESS=m68k-atari-mint$UNAME_RELEASE + ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) - echo m68k-atari-mint"$UNAME_RELEASE" - exit ;; + GUESS=m68k-atari-mint$UNAME_RELEASE + ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) - echo m68k-milan-mint"$UNAME_RELEASE" - exit ;; + GUESS=m68k-milan-mint$UNAME_RELEASE + ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) - echo m68k-hades-mint"$UNAME_RELEASE" - exit ;; + GUESS=m68k-hades-mint$UNAME_RELEASE + ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) - echo m68k-unknown-mint"$UNAME_RELEASE" - exit ;; + GUESS=m68k-unknown-mint$UNAME_RELEASE + ;; m68k:machten:*:*) - echo m68k-apple-machten"$UNAME_RELEASE" - exit ;; + GUESS=m68k-apple-machten$UNAME_RELEASE + ;; powerpc:machten:*:*) - echo powerpc-apple-machten"$UNAME_RELEASE" - exit ;; + GUESS=powerpc-apple-machten$UNAME_RELEASE + ;; RISC*:Mach:*:*) - echo mips-dec-mach_bsd4.3 - exit ;; + GUESS=mips-dec-mach_bsd4.3 + ;; RISC*:ULTRIX:*:*) - echo mips-dec-ultrix"$UNAME_RELEASE" - exit ;; + GUESS=mips-dec-ultrix$UNAME_RELEASE + ;; VAX*:ULTRIX*:*:*) - echo vax-dec-ultrix"$UNAME_RELEASE" - exit ;; + GUESS=vax-dec-ultrix$UNAME_RELEASE + ;; 2020:CLIX:*:* | 2430:CLIX:*:*) - echo clipper-intergraph-clix"$UNAME_RELEASE" - exit ;; + GUESS=clipper-intergraph-clix$UNAME_RELEASE + ;; mips:*:*:UMIPS | mips:*:*:RISCos) set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" @@ -525,78 +549,79 @@ } EOF $CC_FOR_BUILD -o "$dummy" "$dummy.c" && - dummyarg=$(echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p') && - SYSTEM_NAME=$("$dummy" "$dummyarg") && + dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` && + SYSTEM_NAME=`"$dummy" "$dummyarg"` && { echo "$SYSTEM_NAME"; exit; } - echo mips-mips-riscos"$UNAME_RELEASE" - exit ;; + GUESS=mips-mips-riscos$UNAME_RELEASE + ;; Motorola:PowerMAX_OS:*:*) - echo powerpc-motorola-powermax - exit ;; + GUESS=powerpc-motorola-powermax + ;; Motorola:*:4.3:PL8-*) - echo powerpc-harris-powermax - exit ;; + GUESS=powerpc-harris-powermax + ;; Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) - echo powerpc-harris-powermax - exit ;; + GUESS=powerpc-harris-powermax + ;; Night_Hawk:Power_UNIX:*:*) - echo powerpc-harris-powerunix - exit ;; + GUESS=powerpc-harris-powerunix + ;; m88k:CX/UX:7*:*) - echo m88k-harris-cxux7 - exit ;; + GUESS=m88k-harris-cxux7 + ;; m88k:*:4*:R4*) - echo m88k-motorola-sysv4 - exit ;; + GUESS=m88k-motorola-sysv4 + ;; m88k:*:3*:R3*) - echo m88k-motorola-sysv3 - exit ;; + GUESS=m88k-motorola-sysv3 + ;; AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures - UNAME_PROCESSOR=$(/usr/bin/uname -p) + UNAME_PROCESSOR=`/usr/bin/uname -p` if test "$UNAME_PROCESSOR" = mc88100 || test "$UNAME_PROCESSOR" = mc88110 then if test "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx || \ test "$TARGET_BINARY_INTERFACE"x = x then - echo m88k-dg-dgux"$UNAME_RELEASE" + GUESS=m88k-dg-dgux$UNAME_RELEASE else - echo m88k-dg-dguxbcs"$UNAME_RELEASE" + GUESS=m88k-dg-dguxbcs$UNAME_RELEASE fi else - echo i586-dg-dgux"$UNAME_RELEASE" + GUESS=i586-dg-dgux$UNAME_RELEASE fi - exit ;; + ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) - echo m88k-dolphin-sysv3 - exit ;; + GUESS=m88k-dolphin-sysv3 + ;; M88*:*:R3*:*) # Delta 88k system running SVR3 - echo m88k-motorola-sysv3 - exit ;; + GUESS=m88k-motorola-sysv3 + ;; XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) - echo m88k-tektronix-sysv3 - exit ;; + GUESS=m88k-tektronix-sysv3 + ;; Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) - echo m68k-tektronix-bsd - exit ;; + GUESS=m68k-tektronix-bsd + ;; *:IRIX*:*:*) - echo mips-sgi-irix"$(echo "$UNAME_RELEASE"|sed -e 's/-/_/g')" - exit ;; + IRIX_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/g'` + GUESS=mips-sgi-irix$IRIX_REL + ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. - echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id - exit ;; # Note that: echo "'$(uname -s)'" gives 'AIX ' + GUESS=romp-ibm-aix # uname -m gives an 8 hex-code CPU id + ;; # Note that: echo "'`uname -s`'" gives 'AIX ' i*86:AIX:*:*) - echo i386-ibm-aix - exit ;; + GUESS=i386-ibm-aix + ;; ia64:AIX:*:*) if test -x /usr/bin/oslevel ; then - IBM_REV=$(/usr/bin/oslevel) + IBM_REV=`/usr/bin/oslevel` else - IBM_REV="$UNAME_VERSION.$UNAME_RELEASE" + IBM_REV=$UNAME_VERSION.$UNAME_RELEASE fi - echo "$UNAME_MACHINE"-ibm-aix"$IBM_REV" - exit ;; + GUESS=$UNAME_MACHINE-ibm-aix$IBM_REV + ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then set_cc_for_build @@ -611,68 +636,68 @@ exit(0); } EOF - if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=$("$dummy") + if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` then - echo "$SYSTEM_NAME" + GUESS=$SYSTEM_NAME else - echo rs6000-ibm-aix3.2.5 + GUESS=rs6000-ibm-aix3.2.5 fi elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then - echo rs6000-ibm-aix3.2.4 + GUESS=rs6000-ibm-aix3.2.4 else - echo rs6000-ibm-aix3.2 + GUESS=rs6000-ibm-aix3.2 fi - exit ;; + ;; *:AIX:*:[4567]) - IBM_CPU_ID=$(/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }') + IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 else IBM_ARCH=powerpc fi if test -x /usr/bin/lslpp ; then - IBM_REV=$(/usr/bin/lslpp -Lqc bos.rte.libc | - awk -F: '{ print $3 }' | sed s/[0-9]*$/0/) + IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc | \ + awk -F: '{ print $3 }' | sed s/[0-9]*$/0/` else - IBM_REV="$UNAME_VERSION.$UNAME_RELEASE" + IBM_REV=$UNAME_VERSION.$UNAME_RELEASE fi - echo "$IBM_ARCH"-ibm-aix"$IBM_REV" - exit ;; + GUESS=$IBM_ARCH-ibm-aix$IBM_REV + ;; *:AIX:*:*) - echo rs6000-ibm-aix - exit ;; + GUESS=rs6000-ibm-aix + ;; ibmrt:4.4BSD:*|romp-ibm:4.4BSD:*) - echo romp-ibm-bsd4.4 - exit ;; + GUESS=romp-ibm-bsd4.4 + ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and - echo romp-ibm-bsd"$UNAME_RELEASE" # 4.3 with uname added to - exit ;; # report: romp-ibm BSD 4.3 + GUESS=romp-ibm-bsd$UNAME_RELEASE # 4.3 with uname added to + ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) - echo rs6000-bull-bosx - exit ;; + GUESS=rs6000-bull-bosx + ;; DPX/2?00:B.O.S.:*:*) - echo m68k-bull-sysv3 - exit ;; + GUESS=m68k-bull-sysv3 + ;; 9000/[34]??:4.3bsd:1.*:*) - echo m68k-hp-bsd - exit ;; + GUESS=m68k-hp-bsd + ;; hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) - echo m68k-hp-bsd4.4 - exit ;; + GUESS=m68k-hp-bsd4.4 + ;; 9000/[34678]??:HP-UX:*:*) - HPUX_REV=$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//') - case "$UNAME_MACHINE" in + HPUX_REV=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*.[0B]*//'` + case $UNAME_MACHINE in 9000/31?) HP_ARCH=m68000 ;; 9000/[34]??) HP_ARCH=m68k ;; 9000/[678][0-9][0-9]) if test -x /usr/bin/getconf; then - sc_cpu_version=$(/usr/bin/getconf SC_CPU_VERSION 2>/dev/null) - sc_kernel_bits=$(/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null) - case "$sc_cpu_version" in + sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` + sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` + case $sc_cpu_version in 523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0 528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1 532) # CPU_PA_RISC2_0 - case "$sc_kernel_bits" in + case $sc_kernel_bits in 32) HP_ARCH=hppa2.0n ;; 64) HP_ARCH=hppa2.0w ;; '') HP_ARCH=hppa2.0 ;; # HP-UX 10.20 @@ -714,7 +739,7 @@ exit (0); } EOF - (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=$("$dummy") + (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=`"$dummy"` test -z "$HP_ARCH" && HP_ARCH=hppa fi ;; esac @@ -739,12 +764,12 @@ HP_ARCH=hppa64 fi fi - echo "$HP_ARCH"-hp-hpux"$HPUX_REV" - exit ;; + GUESS=$HP_ARCH-hp-hpux$HPUX_REV + ;; ia64:HP-UX:*:*) - HPUX_REV=$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//') - echo ia64-hp-hpux"$HPUX_REV" - exit ;; + HPUX_REV=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*.[0B]*//'` + GUESS=ia64-hp-hpux$HPUX_REV + ;; 3050*:HI-UX:*:*) set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" @@ -772,38 +797,38 @@ exit (0); } EOF - $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=$("$dummy") && + $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` && { echo "$SYSTEM_NAME"; exit; } - echo unknown-hitachi-hiuxwe2 - exit ;; + GUESS=unknown-hitachi-hiuxwe2 + ;; 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*) - echo hppa1.1-hp-bsd - exit ;; + GUESS=hppa1.1-hp-bsd + ;; 9000/8??:4.3bsd:*:*) - echo hppa1.0-hp-bsd - exit ;; + GUESS=hppa1.0-hp-bsd + ;; *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) - echo hppa1.0-hp-mpeix - exit ;; + GUESS=hppa1.0-hp-mpeix + ;; hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*) - echo hppa1.1-hp-osf - exit ;; + GUESS=hppa1.1-hp-osf + ;; hp8??:OSF1:*:*) - echo hppa1.0-hp-osf - exit ;; + GUESS=hppa1.0-hp-osf + ;; i*86:OSF1:*:*) if test -x /usr/sbin/sysversion ; then - echo "$UNAME_MACHINE"-unknown-osf1mk + GUESS=$UNAME_MACHINE-unknown-osf1mk else - echo "$UNAME_MACHINE"-unknown-osf1 + GUESS=$UNAME_MACHINE-unknown-osf1 fi - exit ;; + ;; parisc*:Lites*:*:*) - echo hppa1.1-hp-lites - exit ;; + GUESS=hppa1.1-hp-lites + ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) - echo c1-convex-bsd - exit ;; + GUESS=c1-convex-bsd + ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd @@ -811,17 +836,18 @@ fi exit ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) - echo c34-convex-bsd - exit ;; + GUESS=c34-convex-bsd + ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) - echo c38-convex-bsd - exit ;; + GUESS=c38-convex-bsd + ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) - echo c4-convex-bsd - exit ;; + GUESS=c4-convex-bsd + ;; CRAY*Y-MP:*:*:*) - echo ymp-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; + CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` + GUESS=ymp-cray-unicos$CRAY_REL + ;; CRAY*[A-Z]90:*:*:*) echo "$UNAME_MACHINE"-cray-unicos"$UNAME_RELEASE" \ | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ @@ -829,114 +855,129 @@ -e 's/\.[^.]*$/.X/' exit ;; CRAY*TS:*:*:*) - echo t90-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; + CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` + GUESS=t90-cray-unicos$CRAY_REL + ;; CRAY*T3E:*:*:*) - echo alphaev5-cray-unicosmk"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; + CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` + GUESS=alphaev5-cray-unicosmk$CRAY_REL + ;; CRAY*SV1:*:*:*) - echo sv1-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; + CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` + GUESS=sv1-cray-unicos$CRAY_REL + ;; *:UNICOS/mp:*:*) - echo craynv-cray-unicosmp"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; + CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` + GUESS=craynv-cray-unicosmp$CRAY_REL + ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) - FUJITSU_PROC=$(uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz) - FUJITSU_SYS=$(uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///') - FUJITSU_REL=$(echo "$UNAME_RELEASE" | sed -e 's/ /_/') - echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; + FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` + FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` + FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'` + GUESS=${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL} + ;; 5000:UNIX_System_V:4.*:*) - FUJITSU_SYS=$(uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///') - FUJITSU_REL=$(echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/') - echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; + FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` + FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'` + GUESS=sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL} + ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) - echo "$UNAME_MACHINE"-pc-bsdi"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-pc-bsdi$UNAME_RELEASE + ;; sparc*:BSD/OS:*:*) - echo sparc-unknown-bsdi"$UNAME_RELEASE" - exit ;; + GUESS=sparc-unknown-bsdi$UNAME_RELEASE + ;; *:BSD/OS:*:*) - echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-bsdi$UNAME_RELEASE + ;; arm:FreeBSD:*:*) - UNAME_PROCESSOR=$(uname -p) + UNAME_PROCESSOR=`uname -p` set_cc_for_build if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_PCS_VFP then - echo "${UNAME_PROCESSOR}"-unknown-freebsd"$(echo ${UNAME_RELEASE}|sed -e 's/[-(].*//')"-gnueabi + FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` + GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL-gnueabi else - echo "${UNAME_PROCESSOR}"-unknown-freebsd"$(echo ${UNAME_RELEASE}|sed -e 's/[-(].*//')"-gnueabihf + FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` + GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL-gnueabihf fi - exit ;; + ;; *:FreeBSD:*:*) - UNAME_PROCESSOR=$(/usr/bin/uname -p) - case "$UNAME_PROCESSOR" in + UNAME_PROCESSOR=`/usr/bin/uname -p` + case $UNAME_PROCESSOR in amd64) UNAME_PROCESSOR=x86_64 ;; i386) UNAME_PROCESSOR=i586 ;; esac - echo "$UNAME_PROCESSOR"-unknown-freebsd"$(echo "$UNAME_RELEASE"|sed -e 's/[-(].*//')" - exit ;; + FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` + GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL + ;; i*:CYGWIN*:*) - echo "$UNAME_MACHINE"-pc-cygwin - exit ;; + GUESS=$UNAME_MACHINE-pc-cygwin + ;; *:MINGW64*:*) - echo "$UNAME_MACHINE"-pc-mingw64 - exit ;; + GUESS=$UNAME_MACHINE-pc-mingw64 + ;; *:MINGW*:*) - echo "$UNAME_MACHINE"-pc-mingw32 - exit ;; + GUESS=$UNAME_MACHINE-pc-mingw32 + ;; *:MSYS*:*) - echo "$UNAME_MACHINE"-pc-msys - exit ;; + GUESS=$UNAME_MACHINE-pc-msys + ;; i*:PW*:*) - echo "$UNAME_MACHINE"-pc-pw32 - exit ;; + GUESS=$UNAME_MACHINE-pc-pw32 + ;; + *:SerenityOS:*:*) + GUESS=$UNAME_MACHINE-pc-serenity + ;; *:Interix*:*) - case "$UNAME_MACHINE" in + case $UNAME_MACHINE in x86) - echo i586-pc-interix"$UNAME_RELEASE" - exit ;; + GUESS=i586-pc-interix$UNAME_RELEASE + ;; authenticamd | genuineintel | EM64T) - echo x86_64-unknown-interix"$UNAME_RELEASE" - exit ;; + GUESS=x86_64-unknown-interix$UNAME_RELEASE + ;; IA64) - echo ia64-unknown-interix"$UNAME_RELEASE" - exit ;; + GUESS=ia64-unknown-interix$UNAME_RELEASE + ;; esac ;; i*:UWIN*:*) - echo "$UNAME_MACHINE"-pc-uwin - exit ;; + GUESS=$UNAME_MACHINE-pc-uwin + ;; amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) - echo x86_64-pc-cygwin - exit ;; + GUESS=x86_64-pc-cygwin + ;; prep*:SunOS:5.*:*) - echo powerpcle-unknown-solaris2"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` + GUESS=powerpcle-unknown-solaris2$SUN_REL + ;; *:GNU:*:*) # the GNU system - echo "$(echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,')-unknown-$LIBC$(echo "$UNAME_RELEASE"|sed -e 's,/.*$,,')" - exit ;; + GNU_ARCH=`echo "$UNAME_MACHINE" | sed -e 's,[-/].*$,,'` + GNU_REL=`echo "$UNAME_RELEASE" | sed -e 's,/.*$,,'` + GUESS=$GNU_ARCH-unknown-$LIBC$GNU_REL + ;; *:GNU/*:*:*) # other systems with GNU libc and userland - echo "$UNAME_MACHINE-unknown-$(echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]")$(echo "$UNAME_RELEASE"|sed -e 's/[-(].*//')-$LIBC" - exit ;; + GNU_SYS=`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"` + GNU_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` + GUESS=$UNAME_MACHINE-unknown-$GNU_SYS$GNU_REL-$LIBC + ;; *:Minix:*:*) - echo "$UNAME_MACHINE"-unknown-minix - exit ;; + GUESS=$UNAME_MACHINE-unknown-minix + ;; aarch64:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; aarch64_be:Linux:*:*) UNAME_MACHINE=aarch64_be - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; alpha:Linux:*:*) - case $(sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' /proc/cpuinfo 2>/dev/null) in + case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' /proc/cpuinfo 2>/dev/null` in EV5) UNAME_MACHINE=alphaev5 ;; EV56) UNAME_MACHINE=alphaev56 ;; PCA56) UNAME_MACHINE=alphapca56 ;; @@ -947,63 +988,63 @@ esac objdump --private-headers /bin/sh | grep -q ld.so.1 if test "$?" = 0 ; then LIBC=gnulibc1 ; fi - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - arc:Linux:*:* | arceb:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; + arc:Linux:*:* | arceb:Linux:*:* | arc32:Linux:*:* | arc64:Linux:*:*) + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; arm*:Linux:*:*) set_cc_for_build if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_EABI__ then - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC else if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_PCS_VFP then - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabi + GUESS=$UNAME_MACHINE-unknown-linux-${LIBC}eabi else - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabihf + GUESS=$UNAME_MACHINE-unknown-linux-${LIBC}eabihf fi fi - exit ;; + ;; avr32*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; cris:Linux:*:*) - echo "$UNAME_MACHINE"-axis-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-axis-linux-$LIBC + ;; crisv32:Linux:*:*) - echo "$UNAME_MACHINE"-axis-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-axis-linux-$LIBC + ;; e2k:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; frv:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; hexagon:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; i*86:Linux:*:*) - echo "$UNAME_MACHINE"-pc-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-pc-linux-$LIBC + ;; ia64:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; k1om:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; loongarch32:Linux:*:* | loongarch64:Linux:*:* | loongarchx32:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; m32r*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; m68*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; mips:Linux:*:* | mips64:Linux:*:*) set_cc_for_build IS_GLIBC=0 @@ -1048,65 +1089,66 @@ #endif #endif EOF - eval "$($CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI')" + cc_set_vars=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'` + eval "$cc_set_vars" test "x$CPU" != x && { echo "$CPU${MIPS_ENDIAN}-unknown-linux-$LIBCABI"; exit; } ;; mips64el:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; openrisc*:Linux:*:*) - echo or1k-unknown-linux-"$LIBC" - exit ;; + GUESS=or1k-unknown-linux-$LIBC + ;; or32:Linux:*:* | or1k*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; padre:Linux:*:*) - echo sparc-unknown-linux-"$LIBC" - exit ;; + GUESS=sparc-unknown-linux-$LIBC + ;; parisc64:Linux:*:* | hppa64:Linux:*:*) - echo hppa64-unknown-linux-"$LIBC" - exit ;; + GUESS=hppa64-unknown-linux-$LIBC + ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level - case $(grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2) in - PA7*) echo hppa1.1-unknown-linux-"$LIBC" ;; - PA8*) echo hppa2.0-unknown-linux-"$LIBC" ;; - *) echo hppa-unknown-linux-"$LIBC" ;; + case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in + PA7*) GUESS=hppa1.1-unknown-linux-$LIBC ;; + PA8*) GUESS=hppa2.0-unknown-linux-$LIBC ;; + *) GUESS=hppa-unknown-linux-$LIBC ;; esac - exit ;; + ;; ppc64:Linux:*:*) - echo powerpc64-unknown-linux-"$LIBC" - exit ;; + GUESS=powerpc64-unknown-linux-$LIBC + ;; ppc:Linux:*:*) - echo powerpc-unknown-linux-"$LIBC" - exit ;; + GUESS=powerpc-unknown-linux-$LIBC + ;; ppc64le:Linux:*:*) - echo powerpc64le-unknown-linux-"$LIBC" - exit ;; + GUESS=powerpc64le-unknown-linux-$LIBC + ;; ppcle:Linux:*:*) - echo powerpcle-unknown-linux-"$LIBC" - exit ;; + GUESS=powerpcle-unknown-linux-$LIBC + ;; riscv32:Linux:*:* | riscv32be:Linux:*:* | riscv64:Linux:*:* | riscv64be:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; s390:Linux:*:* | s390x:Linux:*:*) - echo "$UNAME_MACHINE"-ibm-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-ibm-linux-$LIBC + ;; sh64*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; sh*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; sparc:Linux:*:* | sparc64:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; tile*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; vax:Linux:*:*) - echo "$UNAME_MACHINE"-dec-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-dec-linux-$LIBC + ;; x86_64:Linux:*:*) set_cc_for_build LIBCABI=$LIBC @@ -1115,71 +1157,71 @@ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ grep IS_X32 >/dev/null then - LIBCABI="$LIBC"x32 + LIBCABI=${LIBC}x32 fi fi - echo "$UNAME_MACHINE"-pc-linux-"$LIBCABI" - exit ;; + GUESS=$UNAME_MACHINE-pc-linux-$LIBCABI + ;; xtensa*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both # sysname and nodename. - echo i386-sequent-sysv4 - exit ;; + GUESS=i386-sequent-sysv4 + ;; i*86:UNIX_SV:4.2MP:2.*) # Unixware is an offshoot of SVR4, but it has its own version # number series starting with 2... # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. # Use sysv4.2uw... so that sysv4* matches it. - echo "$UNAME_MACHINE"-pc-sysv4.2uw"$UNAME_VERSION" - exit ;; + GUESS=$UNAME_MACHINE-pc-sysv4.2uw$UNAME_VERSION + ;; i*86:OS/2:*:*) # If we were able to find `uname', then EMX Unix compatibility # is probably installed. - echo "$UNAME_MACHINE"-pc-os2-emx - exit ;; + GUESS=$UNAME_MACHINE-pc-os2-emx + ;; i*86:XTS-300:*:STOP) - echo "$UNAME_MACHINE"-unknown-stop - exit ;; + GUESS=$UNAME_MACHINE-unknown-stop + ;; i*86:atheos:*:*) - echo "$UNAME_MACHINE"-unknown-atheos - exit ;; + GUESS=$UNAME_MACHINE-unknown-atheos + ;; i*86:syllable:*:*) - echo "$UNAME_MACHINE"-pc-syllable - exit ;; + GUESS=$UNAME_MACHINE-pc-syllable + ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) - echo i386-unknown-lynxos"$UNAME_RELEASE" - exit ;; + GUESS=i386-unknown-lynxos$UNAME_RELEASE + ;; i*86:*DOS:*:*) - echo "$UNAME_MACHINE"-pc-msdosdjgpp - exit ;; + GUESS=$UNAME_MACHINE-pc-msdosdjgpp + ;; i*86:*:4.*:*) - UNAME_REL=$(echo "$UNAME_RELEASE" | sed 's/\/MP$//') + UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then - echo "$UNAME_MACHINE"-univel-sysv"$UNAME_REL" + GUESS=$UNAME_MACHINE-univel-sysv$UNAME_REL else - echo "$UNAME_MACHINE"-pc-sysv"$UNAME_REL" + GUESS=$UNAME_MACHINE-pc-sysv$UNAME_REL fi - exit ;; + ;; i*86:*:5:[678]*) # UnixWare 7.x, OpenUNIX and OpenServer 6. - case $(/bin/uname -X | grep "^Machine") in + case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac - echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}" - exit ;; + GUESS=$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} + ;; i*86:*:3.2:*) if test -f /usr/options/cb.name; then - UNAME_REL=$(sed -n 's/.*Version //p' </usr/options/cb.name) - echo "$UNAME_MACHINE"-pc-isc"$UNAME_REL" + UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name` + GUESS=$UNAME_MACHINE-pc-isc$UNAME_REL elif /bin/uname -X 2>/dev/null >/dev/null ; then - UNAME_REL=$( (/bin/uname -X|grep Release|sed -e 's/.*= //')) + UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ && UNAME_MACHINE=i586 @@ -1187,11 +1229,11 @@ && UNAME_MACHINE=i686 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 - echo "$UNAME_MACHINE"-pc-sco"$UNAME_REL" + GUESS=$UNAME_MACHINE-pc-sco$UNAME_REL else - echo "$UNAME_MACHINE"-pc-sysv32 + GUESS=$UNAME_MACHINE-pc-sysv32 fi - exit ;; + ;; pc:*:*:*) # Left here for compatibility: # uname -m prints for DJGPP always 'pc', but it prints nothing about @@ -1199,37 +1241,37 @@ # Note: whatever this is, it MUST be the same as what config.sub # prints for the "djgpp" host, or else GDB configure will decide that # this is a cross-build. - echo i586-pc-msdosdjgpp - exit ;; + GUESS=i586-pc-msdosdjgpp + ;; Intel:Mach:3*:*) - echo i386-pc-mach3 - exit ;; + GUESS=i386-pc-mach3 + ;; paragon:*:*:*) - echo i860-intel-osf1 - exit ;; + GUESS=i860-intel-osf1 + ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then - echo i860-stardent-sysv"$UNAME_RELEASE" # Stardent Vistra i860-SVR4 + GUESS=i860-stardent-sysv$UNAME_RELEASE # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. - echo i860-unknown-sysv"$UNAME_RELEASE" # Unknown i860-SVR4 + GUESS=i860-unknown-sysv$UNAME_RELEASE # Unknown i860-SVR4 fi - exit ;; + ;; mini*:CTIX:SYS*5:*) # "miniframe" - echo m68010-convergent-sysv - exit ;; + GUESS=m68010-convergent-sysv + ;; mc68k:UNIX:SYSTEM5:3.51m) - echo m68k-convergent-sysv - exit ;; + GUESS=m68k-convergent-sysv + ;; M680?0:D-NIX:5.3:*) - echo m68k-diab-dnix - exit ;; + GUESS=m68k-diab-dnix + ;; M68*:*:R3V[5678]*:*) test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) OS_REL='' test -r /etc/.relid \ - && OS_REL=.$(sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid) + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ @@ -1240,7 +1282,7 @@ NCR*:*:4.2:* | MPRAS*:*:4.2:*) OS_REL='.3' test -r /etc/.relid \ - && OS_REL=.$(sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid) + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ @@ -1248,118 +1290,118 @@ /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) - echo m68k-unknown-lynxos"$UNAME_RELEASE" - exit ;; + GUESS=m68k-unknown-lynxos$UNAME_RELEASE + ;; mc68030:UNIX_System_V:4.*:*) - echo m68k-atari-sysv4 - exit ;; + GUESS=m68k-atari-sysv4 + ;; TSUNAMI:LynxOS:2.*:*) - echo sparc-unknown-lynxos"$UNAME_RELEASE" - exit ;; + GUESS=sparc-unknown-lynxos$UNAME_RELEASE + ;; rs6000:LynxOS:2.*:*) - echo rs6000-unknown-lynxos"$UNAME_RELEASE" - exit ;; + GUESS=rs6000-unknown-lynxos$UNAME_RELEASE + ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) - echo powerpc-unknown-lynxos"$UNAME_RELEASE" - exit ;; + GUESS=powerpc-unknown-lynxos$UNAME_RELEASE + ;; SM[BE]S:UNIX_SV:*:*) - echo mips-dde-sysv"$UNAME_RELEASE" - exit ;; + GUESS=mips-dde-sysv$UNAME_RELEASE + ;; RM*:ReliantUNIX-*:*:*) - echo mips-sni-sysv4 - exit ;; + GUESS=mips-sni-sysv4 + ;; RM*:SINIX-*:*:*) - echo mips-sni-sysv4 - exit ;; + GUESS=mips-sni-sysv4 + ;; *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then - UNAME_MACHINE=$( (uname -p) 2>/dev/null) - echo "$UNAME_MACHINE"-sni-sysv4 + UNAME_MACHINE=`(uname -p) 2>/dev/null` + GUESS=$UNAME_MACHINE-sni-sysv4 else - echo ns32k-sni-sysv + GUESS=ns32k-sni-sysv fi - exit ;; + ;; PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort # says <Richard.M.Bartel@ccMail.Census.GOV> - echo i586-unisys-sysv4 - exit ;; + GUESS=i586-unisys-sysv4 + ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes <hewes@openmarket.com>. # How about differentiating between stratus architectures? -djm - echo hppa1.1-stratus-sysv4 - exit ;; + GUESS=hppa1.1-stratus-sysv4 + ;; *:*:*:FTX*) # From seanf@swdc.stratus.com. - echo i860-stratus-sysv4 - exit ;; + GUESS=i860-stratus-sysv4 + ;; i*86:VOS:*:*) # From Paul.Green@stratus.com. - echo "$UNAME_MACHINE"-stratus-vos - exit ;; + GUESS=$UNAME_MACHINE-stratus-vos + ;; *:VOS:*:*) # From Paul.Green@stratus.com. - echo hppa1.1-stratus-vos - exit ;; + GUESS=hppa1.1-stratus-vos + ;; mc68*:A/UX:*:*) - echo m68k-apple-aux"$UNAME_RELEASE" - exit ;; + GUESS=m68k-apple-aux$UNAME_RELEASE + ;; news*:NEWS-OS:6*:*) - echo mips-sony-newsos6 - exit ;; + GUESS=mips-sony-newsos6 + ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if test -d /usr/nec; then - echo mips-nec-sysv"$UNAME_RELEASE" + GUESS=mips-nec-sysv$UNAME_RELEASE else - echo mips-unknown-sysv"$UNAME_RELEASE" + GUESS=mips-unknown-sysv$UNAME_RELEASE fi - exit ;; + ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. - echo powerpc-be-beos - exit ;; + GUESS=powerpc-be-beos + ;; BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. - echo powerpc-apple-beos - exit ;; + GUESS=powerpc-apple-beos + ;; BePC:BeOS:*:*) # BeOS running on Intel PC compatible. - echo i586-pc-beos - exit ;; + GUESS=i586-pc-beos + ;; BePC:Haiku:*:*) # Haiku running on Intel PC compatible. - echo i586-pc-haiku - exit ;; + GUESS=i586-pc-haiku + ;; x86_64:Haiku:*:*) - echo x86_64-unknown-haiku - exit ;; + GUESS=x86_64-unknown-haiku + ;; SX-4:SUPER-UX:*:*) - echo sx4-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sx4-nec-superux$UNAME_RELEASE + ;; SX-5:SUPER-UX:*:*) - echo sx5-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sx5-nec-superux$UNAME_RELEASE + ;; SX-6:SUPER-UX:*:*) - echo sx6-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sx6-nec-superux$UNAME_RELEASE + ;; SX-7:SUPER-UX:*:*) - echo sx7-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sx7-nec-superux$UNAME_RELEASE + ;; SX-8:SUPER-UX:*:*) - echo sx8-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sx8-nec-superux$UNAME_RELEASE + ;; SX-8R:SUPER-UX:*:*) - echo sx8r-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sx8r-nec-superux$UNAME_RELEASE + ;; SX-ACE:SUPER-UX:*:*) - echo sxace-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sxace-nec-superux$UNAME_RELEASE + ;; Power*:Rhapsody:*:*) - echo powerpc-apple-rhapsody"$UNAME_RELEASE" - exit ;; + GUESS=powerpc-apple-rhapsody$UNAME_RELEASE + ;; *:Rhapsody:*:*) - echo "$UNAME_MACHINE"-apple-rhapsody"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-apple-rhapsody$UNAME_RELEASE + ;; arm64:Darwin:*:*) - echo aarch64-apple-darwin"$UNAME_RELEASE" - exit ;; + GUESS=aarch64-apple-darwin$UNAME_RELEASE + ;; *:Darwin:*:*) - UNAME_PROCESSOR=$(uname -p) + UNAME_PROCESSOR=`uname -p` case $UNAME_PROCESSOR in unknown) UNAME_PROCESSOR=powerpc ;; esac @@ -1393,109 +1435,119 @@ # uname -m returns i386 or x86_64 UNAME_PROCESSOR=$UNAME_MACHINE fi - echo "$UNAME_PROCESSOR"-apple-darwin"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_PROCESSOR-apple-darwin$UNAME_RELEASE + ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) - UNAME_PROCESSOR=$(uname -p) + UNAME_PROCESSOR=`uname -p` if test "$UNAME_PROCESSOR" = x86; then UNAME_PROCESSOR=i386 UNAME_MACHINE=pc fi - echo "$UNAME_PROCESSOR"-"$UNAME_MACHINE"-nto-qnx"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_PROCESSOR-$UNAME_MACHINE-nto-qnx$UNAME_RELEASE + ;; *:QNX:*:4*) - echo i386-pc-qnx - exit ;; + GUESS=i386-pc-qnx + ;; NEO-*:NONSTOP_KERNEL:*:*) - echo neo-tandem-nsk"$UNAME_RELEASE" - exit ;; + GUESS=neo-tandem-nsk$UNAME_RELEASE + ;; NSE-*:NONSTOP_KERNEL:*:*) - echo nse-tandem-nsk"$UNAME_RELEASE" - exit ;; + GUESS=nse-tandem-nsk$UNAME_RELEASE + ;; NSR-*:NONSTOP_KERNEL:*:*) - echo nsr-tandem-nsk"$UNAME_RELEASE" - exit ;; + GUESS=nsr-tandem-nsk$UNAME_RELEASE + ;; NSV-*:NONSTOP_KERNEL:*:*) - echo nsv-tandem-nsk"$UNAME_RELEASE" - exit ;; + GUESS=nsv-tandem-nsk$UNAME_RELEASE + ;; NSX-*:NONSTOP_KERNEL:*:*) - echo nsx-tandem-nsk"$UNAME_RELEASE" - exit ;; + GUESS=nsx-tandem-nsk$UNAME_RELEASE + ;; *:NonStop-UX:*:*) - echo mips-compaq-nonstopux - exit ;; + GUESS=mips-compaq-nonstopux + ;; BS2000:POSIX*:*:*) - echo bs2000-siemens-sysv - exit ;; + GUESS=bs2000-siemens-sysv + ;; DS/*:UNIX_System_V:*:*) - echo "$UNAME_MACHINE"-"$UNAME_SYSTEM"-"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-$UNAME_SYSTEM-$UNAME_RELEASE + ;; *:Plan9:*:*) # "uname -m" is not consistent, so use $cputype instead. 386 # is converted to i386 for consistency with other x86 # operating systems. - # shellcheck disable=SC2154 - if test "$cputype" = 386; then + if test "${cputype-}" = 386; then UNAME_MACHINE=i386 - else - UNAME_MACHINE="$cputype" + elif test "x${cputype-}" != x; then + UNAME_MACHINE=$cputype fi - echo "$UNAME_MACHINE"-unknown-plan9 - exit ;; + GUESS=$UNAME_MACHINE-unknown-plan9 + ;; *:TOPS-10:*:*) - echo pdp10-unknown-tops10 - exit ;; + GUESS=pdp10-unknown-tops10 + ;; *:TENEX:*:*) - echo pdp10-unknown-tenex - exit ;; + GUESS=pdp10-unknown-tenex + ;; KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) - echo pdp10-dec-tops20 - exit ;; + GUESS=pdp10-dec-tops20 + ;; XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) - echo pdp10-xkl-tops20 - exit ;; + GUESS=pdp10-xkl-tops20 + ;; *:TOPS-20:*:*) - echo pdp10-unknown-tops20 - exit ;; + GUESS=pdp10-unknown-tops20 + ;; *:ITS:*:*) - echo pdp10-unknown-its - exit ;; + GUESS=pdp10-unknown-its + ;; SEI:*:*:SEIUX) - echo mips-sei-seiux"$UNAME_RELEASE" - exit ;; + GUESS=mips-sei-seiux$UNAME_RELEASE + ;; *:DragonFly:*:*) - echo "$UNAME_MACHINE"-unknown-dragonfly"$(echo "$UNAME_RELEASE"|sed -e 's/[-(].*//')" - exit ;; + DRAGONFLY_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` + GUESS=$UNAME_MACHINE-unknown-dragonfly$DRAGONFLY_REL + ;; *:*VMS:*:*) - UNAME_MACHINE=$( (uname -p) 2>/dev/null) - case "$UNAME_MACHINE" in - A*) echo alpha-dec-vms ; exit ;; - I*) echo ia64-dec-vms ; exit ;; - V*) echo vax-dec-vms ; exit ;; + UNAME_MACHINE=`(uname -p) 2>/dev/null` + case $UNAME_MACHINE in + A*) GUESS=alpha-dec-vms ;; + I*) GUESS=ia64-dec-vms ;; + V*) GUESS=vax-dec-vms ;; esac ;; *:XENIX:*:SysV) - echo i386-pc-xenix - exit ;; + GUESS=i386-pc-xenix + ;; i*86:skyos:*:*) - echo "$UNAME_MACHINE"-pc-skyos"$(echo "$UNAME_RELEASE" | sed -e 's/ .*$//')" - exit ;; + SKYOS_REL=`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'` + GUESS=$UNAME_MACHINE-pc-skyos$SKYOS_REL + ;; i*86:rdos:*:*) - echo "$UNAME_MACHINE"-pc-rdos - exit ;; + GUESS=$UNAME_MACHINE-pc-rdos + ;; + i*86:Fiwix:*:*) + GUESS=$UNAME_MACHINE-pc-fiwix + ;; *:AROS:*:*) - echo "$UNAME_MACHINE"-unknown-aros - exit ;; + GUESS=$UNAME_MACHINE-unknown-aros + ;; x86_64:VMkernel:*:*) - echo "$UNAME_MACHINE"-unknown-esx - exit ;; + GUESS=$UNAME_MACHINE-unknown-esx + ;; amd64:Isilon\ OneFS:*:*) - echo x86_64-unknown-onefs - exit ;; + GUESS=x86_64-unknown-onefs + ;; *:Unleashed:*:*) - echo "$UNAME_MACHINE"-unknown-unleashed"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-unleashed$UNAME_RELEASE + ;; esac +# Do we have a guess based on uname results? +if test "x$GUESS" != x; then + echo "$GUESS" + exit +fi + # No uname command or uname output not recognized. set_cc_for_build cat > "$dummy.c" <<EOF @@ -1535,7 +1587,7 @@ #define __ARCHITECTURE__ "m68k" #endif int version; - version=$( (hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null); + version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; if (version < 4) printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); else @@ -1627,7 +1679,7 @@ } EOF -$CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=$($dummy) && +$CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=`"$dummy"` && { echo "$SYSTEM_NAME"; exit; } # Apollos put the system type in the environment. @@ -1635,7 +1687,7 @@ echo "$0: unable to guess system type" >&2 -case "$UNAME_MACHINE:$UNAME_SYSTEM" in +case $UNAME_MACHINE:$UNAME_SYSTEM in mips:Linux | mips64:Linux) # If we got here on MIPS GNU/Linux, output extra information. cat >&2 <<EOF @@ -1657,9 +1709,11 @@ https://git.savannah.gnu.org/cgit/config.git/plain/config.sub EOF -year=$(echo $timestamp | sed 's,-.*,,') +our_year=`echo $timestamp | sed 's,-.*,,'` +thisyear=`date +%Y` # shellcheck disable=SC2003 -if test "$(expr "$(date +%Y)" - "$year")" -lt 3 ; then +script_age=`expr "$thisyear" - "$our_year"` +if test "$script_age" -lt 3 ; then cat >&2 <<EOF If $0 has already been updated, send the following data and any @@ -1668,20 +1722,20 @@ config.guess timestamp = $timestamp -uname -m = $( (uname -m) 2>/dev/null || echo unknown) -uname -r = $( (uname -r) 2>/dev/null || echo unknown) -uname -s = $( (uname -s) 2>/dev/null || echo unknown) -uname -v = $( (uname -v) 2>/dev/null || echo unknown) - -/usr/bin/uname -p = $( (/usr/bin/uname -p) 2>/dev/null) -/bin/uname -X = $( (/bin/uname -X) 2>/dev/null) - -hostinfo = $( (hostinfo) 2>/dev/null) -/bin/universe = $( (/bin/universe) 2>/dev/null) -/usr/bin/arch -k = $( (/usr/bin/arch -k) 2>/dev/null) -/bin/arch = $( (/bin/arch) 2>/dev/null) -/usr/bin/oslevel = $( (/usr/bin/oslevel) 2>/dev/null) -/usr/convex/getsysinfo = $( (/usr/convex/getsysinfo) 2>/dev/null) +uname -m = `(uname -m) 2>/dev/null || echo unknown` +uname -r = `(uname -r) 2>/dev/null || echo unknown` +uname -s = `(uname -s) 2>/dev/null || echo unknown` +uname -v = `(uname -v) 2>/dev/null || echo unknown` + +/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` +/bin/uname -X = `(/bin/uname -X) 2>/dev/null` + +hostinfo = `(hostinfo) 2>/dev/null` +/bin/universe = `(/bin/universe) 2>/dev/null` +/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` +/bin/arch = `(/bin/arch) 2>/dev/null` +/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` +/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` UNAME_MACHINE = "$UNAME_MACHINE" UNAME_RELEASE = "$UNAME_RELEASE" diff -Nru ruby3.3-3.3.8/tool/config.sub ruby3.3-3.3.13/tool/config.sub --- ruby3.3-3.3.8/tool/config.sub 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/tool/config.sub 2026-10-23 03:17:41.000000000 +0000 @@ -1,14 +1,14 @@ #! /bin/sh # Configuration validation subroutine script. -# Copyright 1992-2021 Free Software Foundation, Inc. +# Copyright 1992-2022 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale -timestamp='2021-10-27' +timestamp='2022-01-03' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or +# the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but @@ -76,7 +76,7 @@ version="\ GNU config.sub ($timestamp) -Copyright 1992-2021 Free Software Foundation, Inc. +Copyright 1992-2022 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -1020,6 +1020,11 @@ ;; # Here we normalize CPU types with a missing or matching vendor + armh-unknown | armh-alt) + cpu=armv7l + vendor=alt + basic_os=${basic_os:-linux-gnueabihf} + ;; dpx20-unknown | dpx20-bull) cpu=rs6000 vendor=bull @@ -1121,7 +1126,7 @@ xscale-* | xscalee[bl]-*) cpu=`echo "$cpu" | sed 's/^xscale/arm/'` ;; - arm64-*) + arm64-* | aarch64le-*) cpu=aarch64 ;; diff -Nru ruby3.3-3.3.8/tool/downloader.rb ruby3.3-3.3.13/tool/downloader.rb --- ruby3.3-3.3.8/tool/downloader.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/tool/downloader.rb 2026-10-23 03:17:41.000000000 +0000 @@ -215,9 +215,6 @@ $stdout.puts "#{file} already exists" $stdout.flush end - if cache_save - save_cache(cache, file, name) - end return file.to_path end if dryrun diff -Nru ruby3.3-3.3.8/tool/gperf.sed ruby3.3-3.3.13/tool/gperf.sed --- ruby3.3-3.3.8/tool/gperf.sed 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/tool/gperf.sed 2026-10-23 03:17:41.000000000 +0000 @@ -1,23 +1,4 @@ -/ANSI-C code/{ - h - s/.*/ANSI:offset:/ - x -} -/\/\*!ANSI{\*\//{ - G - s/\/\*!ANSI{\*\/\(.*\)\/\*}!ANSI\*\/\(.*\)\nANSI:.*/\/\*\1\*\/\2/ -} -s/(int)([a-z_]*)&((struct \([a-zA-Z_0-9][a-zA-Z_0-9]*\)_t *\*)0)->\1_str\([1-9][0-9]*\),/gperf_offsetof(\1, \2),/g -/^#line/{ - G - x - s/:offset:/:/ - x - s/\(.*\)\(\n\).*:offset:.*/#define gperf_offsetof(s, n) (short)offsetof(struct s##_t, s##_str##n)\2\1/ - s/\n[^#].*// -} /^[a-zA-Z_0-9]*hash/,/^}/{ s/ hval = / hval = (unsigned int)/ s/ return / return (unsigned int)/ } -s/^\(static\) \(unsigned char gperf_downcase\)/\1 const \2/ diff -Nru ruby3.3-3.3.8/tool/lib/core_assertions.rb ruby3.3-3.3.13/tool/lib/core_assertions.rb --- ruby3.3-3.3.8/tool/lib/core_assertions.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/tool/lib/core_assertions.rb 2026-10-23 03:17:41.000000000 +0000 @@ -861,6 +861,65 @@ token = "\e[7;1m#{$$.to_s}:#{Time.now.strftime('%s.%L')}:#{rand(0x10000).to_s(16)}:\e[m" return token.dump, Regexp.quote(token) end + + # Platform predicates + + def self.mswin? + defined?(@mswin) ? @mswin : @mswin = RUBY_PLATFORM.include?('mswin') + end + private def mswin? + CoreAssertions.mswin? + end + + def self.mingw? + defined?(@mingw) ? @mingw : @mingw = RUBY_PLATFORM.include?('mingw') + end + private def mingw? + CoreAssertions.mingw? + end + + module_function def windows? + mswin? or mingw? + end + + def self.compare_version(a, b) + b.empty? ? true && a : a && (a <=> b) >= 0 + end + + def self.linux?(*ver) + unless defined?(@linux) + @linux = RUBY_PLATFORM.include?('linux') && `uname -r`.scan(/\d+/).map(&:to_i) + end + compare_version @linux, ver + end + private def linux?(*ver) + CoreAssertions.linux?(*ver) + end + + def self.glibc?(*ver) + unless defined?(@glibc) + libc = `/usr/bin/ldd /bin/sh`[/^\s*libc.*=> *\K\S*/] + if libc and /version (\d+)\.(\d+)\.$/ =~ IO.popen([libc], &:read)[] + @glibc = [$1.to_i, $2.to_i] + else + @glibc = false + end + end + compare_version @glibc, ver + end + private def glibc?(*ver) + CoreAssertions.glibc?(*ver) + end + + def self.macos?(*ver) + unless defined?(@macos) + @macos = RUBY_PLATFORM.include?('darwin') && `sw_vers -productVersion`.scan(/\d+/).map(&:to_i) + end + compare_version @macos, ver + end + private def macos?(*ver) + CoreAssertions.macos?(*ver) + end end end end diff -Nru ruby3.3-3.3.8/tool/lib/test/unit.rb ruby3.3-3.3.13/tool/lib/test/unit.rb --- ruby3.3-3.3.8/tool/lib/test/unit.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/tool/lib/test/unit.rb 2026-10-23 03:17:41.000000000 +0000 @@ -1782,6 +1782,7 @@ @backtrace = ex.backtrace end + attr_accessor :message, :backtrace end end diff -Nru ruby3.3-3.3.8/tool/merger.rb ruby3.3-3.3.13/tool/merger.rb --- ruby3.3-3.3.8/tool/merger.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/tool/merger.rb 2026-10-23 03:17:41.000000000 +0000 @@ -65,7 +65,8 @@ if teeny v[2].succ! end - if pl != '-1' # trunk does not have patchlevel + # We stopped bumping RUBY_PATCHLEVEL at Ruby 4.0.0. + if Integer(v[0]) <= 3 pl.succ! end @@ -113,8 +114,17 @@ abort 'no relname is given and not in a release branch even if this is patch release' end end - tagname = "v#{v.join('_')}#{("_#{pl}" if v[0] < "2" || (v[0] == "2" && v[1] < "1") || /^(?:preview|rc)/ =~ pl)}" + if /^(?:preview|rc)/ =~ pl + tagname = "v#{v.join('.')}-#{pl}" + elsif Integer(v[0]) >= 4 + tagname = "v#{v.join('.')}" + else + tagname = "v#{v.join('_')}" + end + unless execute('git', 'diff', '--exit-code') + abort 'uncommitted changes' + end unless execute('git', 'tag', tagname) abort 'specfied tag already exists. check tag name and remove it if you want to force re-tagging' end @@ -132,10 +142,12 @@ unless relname raise ArgumentError, 'relname is not specified' end - if /^v/ !~ relname - tagname = "v#{relname.gsub(/[.-]/, '_')}" - else + if relname.start_with?('v') tagname = relname + elsif Integer(relname.split('.', 2).first) >= 4 + tagname = "v#{relname}" + else + tagname = "v#{relname.gsub(/[.-]/, '_')}" end execute('git', 'tag', '-d', tagname) @@ -260,7 +272,7 @@ end # Merge revision from Git patch - git_uri = "https://git.ruby-lang.org/ruby.git/patch/?id=#{git_rev}" + git_uri = "https://github.com/ruby/ruby/commit/#{git_rev}.patch" resp = Net::HTTP.get_response(URI(git_uri)) if resp.code != '200' abort "'#{git_uri}' returned status '#{resp.code}':\n#{resp.body}" diff -Nru ruby3.3-3.3.8/tool/redmine-backporter.rb ruby3.3-3.3.13/tool/redmine-backporter.rb --- ruby3.3-3.3.8/tool/redmine-backporter.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/tool/redmine-backporter.rb 2026-10-23 03:17:41.000000000 +0000 @@ -66,25 +66,25 @@ def color(fore=nil, back=nil, opts={}, bold: false, underscore: false) seq = "" if bold || opts[:bold] - seq << "\e[1m" + seq = seq + "\e[1m" end if underscore || opts[:underscore] - seq << "\e[2m" + seq = seq + "\e[2m" end if fore c = COLORS[fore] raise "unknown foreground color #{fore}" unless c - seq << "\e[#{c}m" + seq = seq + "\e[#{c}m" end if back c = COLORS[back] raise "unknown background color #{back}" unless c - seq << "\e[#{c + 10}m" + seq = seq + "\e[#{c + 10}m" end if seq.empty? self else - seq << self << "\e[0m" + seq = seq + self + "\e[0m" end end end @@ -190,7 +190,7 @@ next false if c.match(/\A\d{1,6}\z/) # skip SVN revision # check if the Git revision is included in master - has_commit(c, "master") + has_commit(c, "origin/master") end.sort_by do |changeset| Integer(IO.popen(%W[git show -s --format=%ct #{changeset}], &:read)) end @@ -351,27 +351,22 @@ next end - if rev.nil? && log = find_git_log("##@issue]") - /^commit (?<rev>\h{40})$/ =~ log - end - if log && rev - str = log[/merge revision\(s\) ([^:]+)(?=:)/] - if str - str.sub!(/\Amerge/, 'merged') - str.gsub!(/\h{8,40}/, 'commit:\0') - str = "ruby_#{TARGET_VERSION.tr('.','_')} commit:#{rev} #{str}." + if rev && has_commit(rev, "ruby_#{TARGET_VERSION.tr('.','_')}") + notes = "ruby_#{TARGET_VERSION.tr('.','_')} commit:#{rev}." + elsif rev.nil? && (log = find_git_log("##@issue]")) && !(revs = log.scan(/^commit (\h{40})$/).flatten).empty? + commits = revs.map { |rev| "commit:#{rev}" }.join(", ") + if merged_revs = log[/merge revision\(s\) ([^:]+)(?=:)/] + merged_revs.sub!(/\Amerge/, 'merged') + merged_revs.gsub!(/\h{8,40}/, 'commit:\0') + str = "ruby_#{TARGET_VERSION.tr('.','_')} #{commits} #{merged_revs}." else - str = "ruby_#{TARGET_VERSION.tr('.','_')} commit:#{rev}." + str = "ruby_#{TARGET_VERSION.tr('.','_')} #{commits}." end if notes str << "\n" str << notes end notes = str - elsif rev && has_commit(rev, "ruby_#{TARGET_VERSION.tr('.','_')}") - # Backport commit's log doesn't have the issue number. - # Instead of that manually it's provided. - notes = "ruby_#{TARGET_VERSION.tr('.','_')} commit:#{rev}." else puts "no commit is found whose log include ##@issue" next diff -Nru ruby3.3-3.3.8/tool/sync_default_gems.rb ruby3.3-3.3.13/tool/sync_default_gems.rb --- ruby3.3-3.3.8/tool/sync_default_gems.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/tool/sync_default_gems.rb 2026-10-23 03:17:41.000000000 +0000 @@ -489,7 +489,9 @@ def commits_in_ranges(gem, repo, default_branch, ranges) # If -a is given, discover all commits since the last picked commit if ranges == true - pattern = "https://github\.com/#{Regexp.quote(repo)}/commit/([0-9a-f]+)$" + # \r? needed in the regex in case the commit has windows-style line endings (because e.g. we're running + # tests on Windows) + pattern = "https://github\.com/#{Regexp.quote(repo)}/commit/([0-9a-f]+)\r?$" log = IO.popen(%W"git log -E --grep=#{pattern} -n1 --format=%B", &:read) ranges = ["#{log[%r[#{pattern}\n\s*(?i:co-authored-by:.*)*\s*\Z], 1]}..#{gem}/#{default_branch}"] end diff -Nru ruby3.3-3.3.8/tool/test/webrick/test_filehandler.rb ruby3.3-3.3.13/tool/test/webrick/test_filehandler.rb --- ruby3.3-3.3.8/tool/test/webrick/test_filehandler.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/tool/test/webrick/test_filehandler.rb 2026-10-23 03:17:41.000000000 +0000 @@ -216,6 +216,7 @@ def test_directory_traversal return if File.executable?(__FILE__) # skip on strange file system + omit "`..%5c..' (backslash) is resolved as a path separator on Windows" if windows? config = { :DocumentRoot => File.dirname(__FILE__), } log_tester = lambda {|log, access_log| diff -Nru ruby3.3-3.3.8/variable.c ruby3.3-3.3.13/variable.c --- ruby3.3-3.3.8/variable.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/variable.c 2026-10-23 03:17:41.000000000 +0000 @@ -1162,22 +1162,6 @@ return offsetof(struct gen_ivtbl, as.shape.ivptr) + n * sizeof(VALUE); } -static struct gen_ivtbl * -gen_ivtbl_resize(struct gen_ivtbl *old, uint32_t n) -{ - RUBY_ASSERT(n > 0); - - uint32_t len = old ? old->as.shape.numiv : 0; - struct gen_ivtbl *ivtbl = xrealloc(old, gen_ivtbl_bytes(n)); - - ivtbl->as.shape.numiv = n; - for (; len < n; len++) { - ivtbl->as.shape.ivptr[len] = Qundef; - } - - return ivtbl; -} - void rb_mark_generic_ivar(VALUE obj) { @@ -1632,41 +1616,6 @@ bool resize; }; -static int -generic_ivar_lookup_ensure_size(st_data_t *k, st_data_t *v, st_data_t u, int existing) -{ - ASSERT_vm_locking(); - - struct gen_ivar_lookup_ensure_size *ivar_lookup = (struct gen_ivar_lookup_ensure_size *)u; - struct gen_ivtbl *ivtbl = existing ? (struct gen_ivtbl *)*v : NULL; - - if (!existing || ivar_lookup->resize) { - if (existing) { - RUBY_ASSERT(ivar_lookup->shape->type == SHAPE_IVAR); - RUBY_ASSERT(rb_shape_get_shape_by_id(ivar_lookup->shape->parent_id)->capacity < ivar_lookup->shape->capacity); - } - else { - FL_SET_RAW((VALUE)*k, FL_EXIVAR); - } - - ivtbl = gen_ivtbl_resize(ivtbl, ivar_lookup->shape->capacity); - *v = (st_data_t)ivtbl; - } - - RUBY_ASSERT(FL_TEST((VALUE)*k, FL_EXIVAR)); - - ivar_lookup->ivtbl = ivtbl; - if (ivar_lookup->shape) { -#if SHAPE_IN_BASIC_FLAGS - rb_shape_set_shape(ivar_lookup->obj, ivar_lookup->shape); -#else - ivtbl->shape_id = rb_shape_id(ivar_lookup->shape); -#endif - } - - return ST_CONTINUE; -} - static VALUE * generic_ivar_set_shape_ivptr(VALUE obj, void *data) { @@ -1674,9 +1623,48 @@ struct gen_ivar_lookup_ensure_size *ivar_lookup = data; + // We can't use st_update, since when resizing the fields table GC can + // happen, which will modify the st_table and may rebuild it RB_VM_LOCK_ENTER(); { - st_update(generic_ivtbl(obj, ivar_lookup->id, false), (st_data_t)obj, generic_ivar_lookup_ensure_size, (st_data_t)ivar_lookup); + struct gen_ivtbl *ivtbl = NULL; + st_table *tbl = generic_ivtbl(obj, ivar_lookup->id, false); + int existing = st_lookup(tbl, (st_data_t)obj, (st_data_t *)&ivtbl); + + if (!existing || ivar_lookup->resize) { + uint32_t new_capa = ivar_lookup->shape->capacity; + uint32_t old_capa = rb_shape_get_shape_by_id(ivar_lookup->shape->parent_id)->capacity; + + if (existing) { + RUBY_ASSERT(ivar_lookup->shape->type == SHAPE_IVAR); + RUBY_ASSERT(old_capa < new_capa); + RUBY_ASSERT(ivtbl); + } else { + RUBY_ASSERT(!ivtbl); + RUBY_ASSERT(old_capa == 0); + } + RUBY_ASSERT(new_capa > 0); + + struct gen_ivtbl *old_ivtbl = ivtbl; + ivtbl = xmalloc(gen_ivtbl_bytes(new_capa)); + if (old_ivtbl) { + memcpy(ivtbl, old_ivtbl, gen_ivtbl_bytes(old_capa)); + } + ivtbl->as.shape.numiv = new_capa; + for (uint32_t i = old_capa; i < new_capa; i++) { + ivtbl->as.shape.ivptr[i] = Qundef; + } + + st_insert(tbl, (st_data_t)obj, (st_data_t)ivtbl); + if (old_ivtbl) { + xfree(old_ivtbl); + } + } + + ivar_lookup->ivtbl = ivtbl; + if (ivar_lookup->shape) { + rb_shape_set_shape(ivar_lookup->obj, ivar_lookup->shape); + } } RB_VM_LOCK_LEAVE(); @@ -2134,8 +2122,8 @@ new_ivtbl->as.complex.table = st_copy(obj_ivtbl->as.complex.table); } else { - new_ivtbl = gen_ivtbl_resize(0, obj_ivtbl->as.shape.numiv); - + new_ivtbl = xmalloc(gen_ivtbl_bytes(obj_ivtbl->as.shape.numiv)); + new_ivtbl->as.shape.numiv = obj_ivtbl->as.shape.numiv; for (uint32_t i=0; i<obj_ivtbl->as.shape.numiv; i++) { RB_OBJ_WRITE(clone, &new_ivtbl->as.shape.ivptr[i], obj_ivtbl->as.shape.ivptr[i]); } @@ -3330,7 +3318,8 @@ rb_check_frozen(mod); ce = rb_const_lookup(mod, id); - if (!ce || !rb_id_table_delete(RCLASS_CONST_TBL(mod), id)) { + + if (!ce) { if (rb_const_defined_at(mod, id)) { rb_name_err_raise("cannot remove %2$s::%1$s", mod, ID2SYM(id)); } @@ -3338,6 +3327,14 @@ undefined_constant(mod, ID2SYM(id)); } + VALUE writable_ce = 0; + if (rb_id_table_lookup(RCLASS_CONST_TBL(mod), id, &writable_ce)) { + rb_id_table_delete(RCLASS_CONST_TBL(mod), id); + if ((rb_const_entry_t *)writable_ce != ce) { + xfree((rb_const_entry_t *)writable_ce); + } + } + rb_clear_constant_cache_for_id(id); val = ce->value; diff -Nru ruby3.3-3.3.8/version.h ruby3.3-3.3.13/version.h --- ruby3.3-3.3.8/version.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/version.h 2026-10-23 03:17:41.000000000 +0000 @@ -9,9 +9,9 @@ */ # define RUBY_VERSION_MAJOR RUBY_API_VERSION_MAJOR # define RUBY_VERSION_MINOR RUBY_API_VERSION_MINOR -#define RUBY_VERSION_TEENY 8 +#define RUBY_VERSION_TEENY 13 #define RUBY_RELEASE_DATE RUBY_RELEASE_YEAR_STR"-"RUBY_RELEASE_MONTH_STR"-"RUBY_RELEASE_DAY_STR -#define RUBY_PATCHLEVEL 144 +#define RUBY_PATCHLEVEL 207 #include "ruby/version.h" #include "ruby/internal/abi.h" diff -Nru ruby3.3-3.3.8/vm.c ruby3.3-3.3.13/vm.c --- ruby3.3-3.3.8/vm.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/vm.c 2026-10-23 03:17:41.000000000 +0000 @@ -2729,6 +2729,7 @@ if (VM_FRAME_FINISHED_P(ec->cfp)) { rb_vm_pop_frame(ec); ec->errinfo = (VALUE)err; + rb_vm_tag_jmpbuf_deinit(&ec->tag->buf); ec->tag = ec->tag->prev; EC_JUMP_TAG(ec, state); } @@ -3528,10 +3529,10 @@ void rb_ec_clear_vm_stack(rb_execution_context_t *ec) { - rb_ec_set_vm_stack(ec, NULL, 0); - - // Avoid dangling pointers: + // set cfp to NULL before clearing the stack in case `thread_profile_frames` + // gets called in this middle of `rb_ec_set_vm_stack` via signal handler. ec->cfp = NULL; + rb_ec_set_vm_stack(ec, NULL, 0); } static void diff -Nru ruby3.3-3.3.8/vm_method.c ruby3.3-3.3.13/vm_method.c --- ruby3.3-3.3.8/vm_method.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/vm_method.c 2026-10-23 03:17:41.000000000 +0000 @@ -941,6 +941,7 @@ } } +static inline rb_method_entry_t* search_method0(VALUE klass, ID id, VALUE *defined_class_ptr, bool skip_refined); /* * klass->method_table[mid] = method_entry(defined_class, visi, def) * @@ -981,7 +982,12 @@ if (RB_TYPE_P(klass, T_MODULE) && FL_TEST(klass, RMODULE_IS_REFINEMENT)) { VALUE refined_class = rb_refinement_module_get_refined_class(klass); + bool search_superclass = type == VM_METHOD_TYPE_ZSUPER && !lookup_method_table(refined_class, mid); rb_add_refined_method_entry(refined_class, mid); + if (search_superclass) { + rb_method_entry_t *me = lookup_method_table(refined_class, mid); + me->def->body.refined.orig_me = search_method0(refined_class, mid, NULL, true); + } } if (type == VM_METHOD_TYPE_REFINED) { rb_method_entry_t *old_me = lookup_method_table(RCLASS_ORIGIN(klass), mid); @@ -1621,7 +1627,12 @@ tmp_me = me->def->body.refined.orig_me; if (tmp_me) { - if (defined_class_ptr) *defined_class_ptr = tmp_me->defined_class; + if (!tmp_me->defined_class) { + VM_ASSERT(RB_TYPE_P(tmp_me->owner, T_MODULE)); + } + else if (defined_class_ptr) { + *defined_class_ptr = tmp_me->defined_class; + } return tmp_me; } @@ -2576,13 +2587,14 @@ switch (me->def->type) { case VM_METHOD_TYPE_ISEQ: if (ISEQ_BODY(me->def->body.iseq.iseqptr)->param.flags.has_rest && + !ISEQ_BODY(me->def->body.iseq.iseqptr)->param.flags.has_post && !ISEQ_BODY(me->def->body.iseq.iseqptr)->param.flags.has_kw && !ISEQ_BODY(me->def->body.iseq.iseqptr)->param.flags.has_kwrest) { ISEQ_BODY(me->def->body.iseq.iseqptr)->param.flags.ruby2_keywords = 1; rb_clear_method_cache(module, name); } else { - rb_warn("Skipping set of ruby2_keywords flag for %s (method accepts keywords or method does not accept argument splat)", rb_id2name(name)); + rb_warn("Skipping set of ruby2_keywords flag for %"PRIsVALUE" (method accepts keywords or post arguments or method does not accept argument splat)", QUOTE_ID(name)); } break; case VM_METHOD_TYPE_BMETHOD: { @@ -2595,25 +2607,26 @@ const struct rb_captured_block *captured = VM_BH_TO_ISEQ_BLOCK(procval); const rb_iseq_t *iseq = rb_iseq_check(captured->code.iseq); if (ISEQ_BODY(iseq)->param.flags.has_rest && + !ISEQ_BODY(iseq)->param.flags.has_post && !ISEQ_BODY(iseq)->param.flags.has_kw && !ISEQ_BODY(iseq)->param.flags.has_kwrest) { ISEQ_BODY(iseq)->param.flags.ruby2_keywords = 1; rb_clear_method_cache(module, name); } else { - rb_warn("Skipping set of ruby2_keywords flag for %s (method accepts keywords or method does not accept argument splat)", rb_id2name(name)); + rb_warn("Skipping set of ruby2_keywords flag for %"PRIsVALUE" (method accepts keywords or post arguments or method does not accept argument splat)", QUOTE_ID(name)); } break; } } /* fallthrough */ default: - rb_warn("Skipping set of ruby2_keywords flag for %s (method not defined in Ruby)", rb_id2name(name)); + rb_warn("Skipping set of ruby2_keywords flag for %"PRIsVALUE" (method not defined in Ruby)", QUOTE_ID(name)); break; } } else { - rb_warn("Skipping set of ruby2_keywords flag for %s (can only set in method defining module)", rb_id2name(name)); + rb_warn("Skipping set of ruby2_keywords flag for %"PRIsVALUE" (can only set in method defining module)", QUOTE_ID(name)); } } return Qnil; diff -Nru ruby3.3-3.3.8/vm_trace.c ruby3.3-3.3.13/vm_trace.c --- ruby3.3-3.3.8/vm_trace.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/vm_trace.c 2026-10-23 03:17:41.000000000 +0000 @@ -455,6 +455,7 @@ if (state) { if (pop_p) { if (VM_FRAME_FINISHED_P(ec->cfp)) { + rb_vm_tag_jmpbuf_deinit(&ec->tag->buf); ec->tag = ec->tag->prev; } rb_vm_pop_frame(ec); diff -Nru ruby3.3-3.3.8/wasm/setjmp.c ruby3.3-3.3.13/wasm/setjmp.c --- ruby3.3-3.3.8/wasm/setjmp.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/wasm/setjmp.c 2026-10-23 03:17:41.000000000 +0000 @@ -143,9 +143,11 @@ try_catch->try_f = try_f; try_catch->catch_f = catch_f; try_catch->context = context; + try_catch->stack_pointer = NULL; } // NOTE: This function is not processed by Asyncify due to a call of asyncify_stop_rewind +__attribute__((noinline)) void rb_wasm_try_catch_loop_run(struct rb_wasm_try_catch *try_catch, rb_wasm_jmp_buf *target) { @@ -154,6 +156,10 @@ target->state = JMP_BUF_STATE_CAPTURED; + if (try_catch->stack_pointer == NULL) { + try_catch->stack_pointer = rb_wasm_get_stack_pointer(); + } + switch ((enum try_catch_phase)try_catch->state) { case TRY_CATCH_PHASE_MAIN: // may unwind @@ -175,6 +181,8 @@ // stop unwinding // (but call stop_rewind to update the asyncify state to "normal" from "unwind") asyncify_stop_rewind(); + // reset the stack pointer to what it was before the most recent call to try_f or catch_f + rb_wasm_set_stack_pointer(try_catch->stack_pointer); // clear the active jmpbuf because it's already stopped _rb_wasm_active_jmpbuf = NULL; // reset jmpbuf state to be able to unwind again diff -Nru ruby3.3-3.3.8/wasm/setjmp.h ruby3.3-3.3.13/wasm/setjmp.h --- ruby3.3-3.3.8/wasm/setjmp.h 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/wasm/setjmp.h 2026-10-23 03:17:41.000000000 +0000 @@ -65,6 +65,7 @@ rb_wasm_try_catch_func_t try_f; rb_wasm_try_catch_func_t catch_f; void *context; + void *stack_pointer; int state; }; diff -Nru ruby3.3-3.3.8/win32/Makefile.sub ruby3.3-3.3.13/win32/Makefile.sub --- ruby3.3-3.3.8/win32/Makefile.sub 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/win32/Makefile.sub 2026-10-23 03:17:41.000000000 +0000 @@ -281,6 +281,10 @@ !else WARNFLAGS = -W2 !endif +!if $(MSC_VER) >= 1944 +# https://developercommunity.visualstudio.com/t/warning-C5287:-operands-are-different-e/10877942 +WARNFLAGS = $(WARNFLAGS) -wd5287 +!endif !endif WERRORFLAG = -WX !if !defined(CFLAGS_NO_ARCH) @@ -344,7 +348,7 @@ ARFLAGS = -machine:$(MACHINE) -out: LD = $(CC) LDSHARED = $(LD) -LD -XCFLAGS = -DRUBY_EXPORT $(INCFLAGS) $(XCFLAGS) +XCFLAGS = -DRUBY_EXPORT $(INCFLAGS) $(XCFLAGS) $(XINCFLAGS) !if $(MSC_VER) >= 1400 # Prevents VC++ 2005 (cl ver 14) warnings MANIFESTTOOL = mt -nologo @@ -487,7 +491,8 @@ EXTOBJS = dmyext.$(OBJEXT) !endif -arch_hdrdir = $(EXTOUT)/include/$(arch) +ext_hdrdir = $(EXTOUT)/include +arch_hdrdir = $(ext_hdrdir)/$(arch) top_srcdir = $(srcdir) hdrdir = $(srcdir)/include tooldir = $(srcdir)/tool @@ -1399,8 +1404,6 @@ sed -e '1,/^const char ruby_initial_load_paths/d;/;/,$$d' \ -e '/^^ /!d;s/ *"\\\\0"$$//;s/" *"//g' -RUBYSPEC_CAPIEXT_SRCDIR = $(srcdir)/$(RUBYSPEC_CAPIEXT) -RUBYSPEC_CAPIEXT_DEPS = $(RUBYSPEC_CAPIEXT_SRCDIR)/rubyspec.h $(RUBY_H_INCLUDES) $(LIBRUBY) RUBYSPEC_CAPIEXT_EXTS = !if [echo>rubyspec-capiext.mk RUBYSPEC_CAPIEXT_EXTS = \] diff -Nru ruby3.3-3.3.8/win32/mkexports.rb ruby3.3-3.3.13/win32/mkexports.rb --- ruby3.3-3.3.8/win32/mkexports.rb 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/win32/mkexports.rb 2026-10-23 03:17:41.000000000 +0000 @@ -106,14 +106,11 @@ objs = objs.collect {|s| s.tr('/', '\\')} filetype = nil objdump(objs) do |l| - if filetype - if /^\f/ =~ l - filetype = nil - next - end + if (filetype = l[/^File Type: (.+)/, 1])..(/^\f/ =~ l) case filetype when /OBJECT/, /LIBRARY/ l.chomp! + next if (/^ .*\(pick any\)$/ =~ l)...true next if /^[[:xdigit:]]+ 0+ UNDEF / =~ l next unless /External/ =~ l next if /(?:_local_stdio_printf_options|v(f|sn?)printf(_s)?_l)\Z/ =~ l @@ -132,8 +129,6 @@ next end yield l.strip, is_data - else - filetype = l[/^File Type: (.+)/, 1] end end yield "strcasecmp", "msvcrt.stricmp" @@ -143,7 +138,11 @@ class Exports::Cygwin < Exports def self.nm - @@nm ||= RbConfig::CONFIG["NM"] + @@nm ||= + begin + require 'shellwords' + RbConfig::CONFIG["NM"].shellsplit + end end def exports(*) @@ -151,7 +150,9 @@ end def each_line(objs, &block) - IO.foreach("|#{self.class.nm} --extern-only --defined-only #{objs.join(' ')}", &block) + IO.popen([*self.class.nm, *%w[--extern-only --defined-only], *objs]) do |f| + f.each(&block) + end end def each_export(objs) @@ -160,7 +161,7 @@ re = /\s(?:(T)|[[:upper:]])\s#{symprefix}((?!#{PrivateNames}).*)$/ objdump(objs) do |l| next if /@.*@/ =~ l - yield $2, !$1 if re =~ l + yield $2.strip, !$1 if re =~ l end end end diff -Nru ruby3.3-3.3.8/win32/win32.c ruby3.3-3.3.13/win32/win32.c --- ruby3.3-3.3.8/win32/win32.c 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/win32/win32.c 2026-10-23 03:17:41.000000000 +0000 @@ -4832,10 +4832,11 @@ static int have_precisetime = -1; -static void -get_systemtime(FILETIME *ft) +typedef void (WINAPI *get_time_func)(FILETIME *ft); + +static get_time_func +get_systemtime_func(void) { - typedef void (WINAPI *get_time_func)(FILETIME *ft); static get_time_func func = (get_time_func)-1; if (func == (get_time_func)-1) { @@ -4848,8 +4849,14 @@ else have_precisetime = 1; } + return func; +} + +static void +get_systemtime(FILETIME *ft) +{ if (!ft) return; - func(ft); + get_systemtime_func()(ft); } /* License: Ruby's */ @@ -4889,6 +4896,7 @@ return 0; } +#if !defined(__MINGW32__) || !defined(HAVE_CLOCK_GETTIME) /* License: Ruby's */ int clock_gettime(clockid_t clock_id, struct timespec *sp) @@ -4928,7 +4936,9 @@ return -1; } } +#endif +#if !defined(__MINGW32__) || !defined(HAVE_CLOCK_GETRES) /* License: Ruby's */ int clock_getres(clockid_t clock_id, struct timespec *sp) @@ -4956,6 +4966,7 @@ return -1; } } +#endif /* License: Ruby's */ static char * @@ -5766,6 +5777,7 @@ if (GetFileInformationByHandle(h, &info)) { FILE_ID_INFO fii; + get_systemtime_func(); st->st_size = ((__int64)info.nFileSizeHigh << 32) | info.nFileSizeLow; st->st_atime = filetime_to_unixtime(&info.ftLastAccessTime); st->st_atimensec = filetime_to_nsec(&info.ftLastAccessTime); @@ -5911,6 +5923,7 @@ return -1; } FindClose(h); + get_systemtime_func(); st->st_mode = fileattr_to_unixmode(wfd.dwFileAttributes, path, 0); st->st_atime = filetime_to_unixtime(&wfd.ftLastAccessTime); st->st_atimensec = filetime_to_nsec(&wfd.ftLastAccessTime); diff -Nru ruby3.3-3.3.8/yjit/src/codegen.rs ruby3.3-3.3.13/yjit/src/codegen.rs --- ruby3.3-3.3.8/yjit/src/codegen.rs 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/yjit/src/codegen.rs 2026-10-23 03:17:41.000000000 +0000 @@ -6338,6 +6338,11 @@ gen_counter_incr(asm, Counter::send_iseq_clobbering_block_arg); return None; } + if iseq_has_rest { + // The proc would be stored above the current stack top, where GC can't see it + gen_counter_incr(asm, Counter::send_iseq_block_arg_gc_unsafe); + return None; + } let proc = asm.stack_pop(1); // Pop first, as argc doesn't account for the block arg let callee_specval = asm.ctx.sp_opnd(callee_specval as isize * SIZEOF_VALUE as isize); asm.store(callee_specval, proc); @@ -7449,7 +7454,6 @@ } OPTIMIZED_METHOD_TYPE_CALL => { - if block.is_some() { gen_counter_incr(asm, Counter::send_call_block); return None; @@ -7501,8 +7505,10 @@ let stack_ret = asm.stack_push(Type::Unknown); asm.mov(stack_ret, ret); - return Some(KeepCompiling); + // End the block to allow invalidating the next instruction + jump_to_next_insn(jit, asm, ocb); + return Some(EndBlock); } OPTIMIZED_METHOD_TYPE_BLOCK_CALL => { gen_counter_incr(asm, Counter::send_optimized_method_block_call); diff -Nru ruby3.3-3.3.8/yjit/src/core.rs ruby3.3-3.3.13/yjit/src/core.rs --- ruby3.3-3.3.8/yjit/src/core.rs 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/yjit/src/core.rs 2026-10-23 03:17:41.000000000 +0000 @@ -3232,7 +3232,23 @@ } // For each incoming branch - for branchref in block.incoming.0.take().iter() { + let mut incoming_branches = block.incoming.0.take(); + + // An adjacent branch will write into the start of the block being invalidated, possibly + // overwriting the block's exit. If we run out of memory after doing this, any subsequent + // incoming branches we rewrite won't be able use the block's exit as a fallback when they + // are unable to generate a stub. To avoid this, if there's an incoming branch that's + // adjacent to the invalidated block, make sure we process it last. + let adjacent_branch_idx = incoming_branches.iter().position(|branchref| { + let branch = unsafe { branchref.as_ref() }; + let target_next = block.start_addr == branch.end_addr.get(); + target_next + }); + if let Some(adjacent_branch_idx) = adjacent_branch_idx { + incoming_branches.swap(adjacent_branch_idx, incoming_branches.len() - 1) + } + + for (i, branchref) in incoming_branches.iter().enumerate() { let branch = unsafe { branchref.as_ref() }; let target_idx = if branch.get_target_address(0) == Some(block_start) { 0 @@ -3272,10 +3288,18 @@ let target_next = block.start_addr == branch.end_addr.get(); if target_next { - // The new block will no longer be adjacent. - // Note that we could be enlarging the branch and writing into the - // start of the block being invalidated. - branch.gen_fn.set_shape(BranchShape::Default); + if stub_addr != block.start_addr { + // The new block will no longer be adjacent. + // Note that we could be enlarging the branch and writing into the + // start of the block being invalidated. + branch.gen_fn.set_shape(BranchShape::Default); + } else { + // The branch target is still adjacent, so the branch must remain + // a fallthrough so we don't overwrite the target with a jump. + // + // This can happen if we're unable to generate a stub and the + // target block also exits on entry (block_start == block_entry_exit). + } } // Rewrite the branch with the new jump target address @@ -3285,6 +3309,11 @@ if target_next && branch.end_addr > block.end_addr { panic!("yjit invalidate rewrote branch past end of invalidated block: {:?} (code_size: {})", branch, block.code_size()); } + let is_last_incoming_branch = i == incoming_branches.len() - 1; + if target_next && branch.end_addr.get() > block_entry_exit && !is_last_incoming_branch { + // We might still need to jump to this exit if we run out of memory when rewriting another incoming branch. + panic!("yjit invalidate rewrote branch over exit of invalidated block: {:?}", branch); + } if !target_next && branch.code_size() > old_branch_size { panic!( "invalidated branch grew in size (start_addr: {:?}, old_size: {}, new_size: {})", diff -Nru ruby3.3-3.3.8/yjit/src/stats.rs ruby3.3-3.3.13/yjit/src/stats.rs --- ruby3.3-3.3.8/yjit/src/stats.rs 2025-04-09 09:23:04.000000000 +0000 +++ ruby3.3-3.3.13/yjit/src/stats.rs 2026-10-23 03:17:41.000000000 +0000 @@ -328,6 +328,7 @@ send_attrset_kwargs, send_iseq_tailcall, send_iseq_arity_error, + send_iseq_block_arg_gc_unsafe, send_iseq_clobbering_block_arg, send_iseq_leaf_builtin_block_arg_block_param, send_iseq_only_keywords,