summaryrefslogtreecommitdiff
path: root/spec/ruby/core
Commit message (Collapse)AuthorAgeFilesLines
* [Bug #19597] Freeze script nameNobuyoshi Nakada2023-05-101-2/+4
|
* marshal.c: shallow freeze user objectsJean Boussier2023-04-261-9/+7
| | | | | | When `freeze: true` argument is passed. [Bug #19427]
* Update to ruby/spec@7f6ca5bBenoit Daloze2023-04-251-1/+1
|
* Workaround CRuby adding x86_64-linux-fake in $LOADED_FEATURESBenoit Daloze2023-04-251-1/+5
|
* Update to ruby/spec@7f69c86Benoit Daloze2023-04-2577-179/+1557
|
* Allow anonymous memberless StructJeremy Evans2023-04-241-0/+14
| | | | | | | Previously, named memberless Structs were allowed, but anonymous memberless Structs were not. Fixes [Bug #19416]
* Check the precision of `getrusage` at runtimeNobuyoshi Nakada2023-04-231-1/+11
|
* Fix a guard of `Process.times`Nobuyoshi Nakada2023-04-221-8/+5
| | | | | | `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.
* Fix an example of `Process.times`Nobuyoshi Nakada2023-04-221-1/+1
| | | | | | | | 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.
* MatchData#named_captures: add optional symbolize_names keyword (#6952)Vladimir Dementyev2023-04-191-0/+12
|
* Add spec for `Warning[:performance]`Jean Boussier2023-04-171-0/+7
| | | | [Feature #19538]
* Implement ObjectSpace::WeakMap#delete and ObjectSpace::WeakKeyMap#deleteJean Boussier2023-04-152-0/+70
| | | | | | [Feature #19561] It's useful to be able to remove references from weak maps.
* * append newline at EOF. [ci skip]git2023-04-151-1/+1
|
* Add specs for ObjectSpace::WeakKeyMapJean Boussier2023-04-155-0/+161
| | | | [Feature #18498]
* Revert "Add specs for ObjectSpace::WeakKeyMap"Jean Boussier2023-04-145-151/+0
| | | | This reverts commit fce8f9f24e4903784266fc9694f86ddd930d6141.
* Add specs for ObjectSpace::WeakKeyMapJean Boussier2023-04-145-0/+151
| | | | [Feature #18498]
* [Bug #19533] Add spec of infinite range inclusionNobuyoshi Nakada2023-04-141-0/+6
|
* Revert "Fix transient heap mode"Aaron Patterson2023-04-041-11/+0
| | | | | | | | This reverts commit 87253d047ce35e7836b6f97edbb4f819879a3b25. Revert "Implement `Process.warmup`" This reverts commit ba6ccd871442f55080bffd53e33678c0726787d2.
* Implement `Process.warmup`Jean Boussier2023-04-041-0/+11
| | | | | | | | | | | | [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.
* Raise ArgumentError if IO.read is provided negative offsetJeremy Evans2023-03-241-3/+12
| | | | Fixes [Bug #19380]
* Add Dir.fchdirJeremy Evans2023-03-241-0/+78
| | | | | | | | | | | | 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]
* Change Hash#compact to keep default values and compare_by_identity flagJeremy Evans2023-03-241-0/+24
| | | | | | | | | 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]
* Copy compare_by_identity flag for empty hashes in Hash.ruby2_keywords_hashJeremy Evans2023-03-241-0/+24
| | | | | | | 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]
* Do not copy compare_by_identity flag for non-empty hashes in Hash.[]Jeremy Evans2023-03-241-0/+18
| | | | | | | | 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]
* Added assertion values for Amazon Linux 2023Hiroshi SHIBATA2023-03-221-3/+5
|
* rb_ary_sum: don't enter fast path if initial isn't a native numeric type.Jean Boussier2023-03-151-0/+13
| | | | | | | [Bug #19530] If the initial value isn't one of the special cased types, we directly jump to the slow path.
* Accept `sleep(nil)` as sleep forever. (#7484)Samuel Williams2023-03-101-4/+23
|
* s/mjit/rjit/Takashi Kokubun2023-03-063-3/+3
|
* s/MJIT/RJIT/Takashi Kokubun2023-03-063-11/+11
|
* Skip a spec failing on masterTakashi Kokubun2023-02-271-5/+7
| | | | | | 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
* Update to ruby/spec@e7dc804Benoit Daloze2023-02-27126-139/+1541
|
* Assigning `nil` to fiber storage deletes the association. (#7378)Samuel Williams2023-02-251-6/+13
| | | Also avoid allocations when looking up `Fiber#storage` if not needed.
* Marshal.load: restore instance variables on RegexpJean Boussier2023-02-211-0/+11
| | | | | | | | | | | | | | | | | | | [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.
* Update some ruby specs for the new message format of NoMethodErrorYusuke Endoh2023-02-201-17/+40
|
* Marshal.load: also freeze extended objectsJean Boussier2023-02-131-0/+20
| | | | | | [Bug #19427] The `proc` wouldn't be called either, that fixes both.
* [DOC] Move old ChangeLog files to doc/ChangeLog (#7293)Takashi Kokubun2023-02-102-2/+2
|
* Only emit circular dependency warning for owned thread shieldsJean byroot Boussier2023-02-081-0/+11
| | | | | | | | | | [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.
* Revert "Only emit circular dependency warning for owned thread shields"Jean byroot Boussier2023-02-061-10/+0
| | | | This reverts commit fa49651e05a06512e18ccb2f54a7198c9ff579de.
* Only emit circular dependency warning for owned thread shieldsJean Boussier2023-02-061-0/+10
| | | | | | | | | | [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.
* blade is hosted under ruby-lang.org nowHiroshi SHIBATA2023-01-234-4/+4
|
* [Bug #19335] `Integer#remainder` should respect `#coerce` (#7120)Nobuyoshi Nakada2023-01-151-0/+3
| | | Also `Numeric#remainder` should.
* Remove Encoding#replicateBenoit Daloze2023-01-111-1/+1
|
* Only RangeError on CRuby for shift width >= 2**67Benoit Daloze2023-01-072-28/+14
| | | | * It seems a better exception class too than NoMemoryError.
* Fix Integer#{<<,>>} specs with large shift widthBenoit Daloze2023-01-072-28/+46
| | | | | * The limit depends on the implementation and platform, it seems unavoidable. * See https://bugs.ruby-lang.org/issues/18518#note-9
* Add bug numberBenoit Daloze2023-01-061-1/+1
|
* Update to ruby/spec@5e48206Benoit Daloze2023-01-052-2/+2
|
* Update to ruby/spec@7e680faBenoit Daloze2023-01-052-3/+4
|
* * remove trailing spaces, append newline at EOF. [ci skip]git2023-01-052-2/+2
|
* Update to ruby/spec@9d69b95Benoit Daloze2023-01-0599-202/+1704
|
* Make IO#set_encoding with binary external encoding use nil internal encodingJeremy Evans2023-01-011-6/+18
| | | | | | | | | | | | | | 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]