aboutsummaryrefslogtreecommitdiffstats
path: root/test
Commit message (Collapse)AuthorAgeFilesLines
* test/ruby/test_jit.rb: Avoid a warningYusuke Endoh2021-01-191-0/+3
| | | | | | | | http://rubyci.s3.amazonaws.com/ubuntu2004/ruby-master/log/20210119T033003Z.log.html.gz ``` /home/chkbuild/chkbuild/tmp/build/20210119T033003Z/ruby/test/ruby/test_jit.rb:781: warning: -e:5: warning: possibly useless use of -@ in void context ```
* test/ruby/test_pattern_matching.rb: Avoid a warningYusuke Endoh2021-01-191-0/+1
| | | | | | | | http://rubyci.s3.amazonaws.com/ubuntu2004/ruby-master/log/20210119T033003Z.log.html.gz ``` /home/chkbuild/chkbuild/tmp/build/20210119T033003Z/ruby/test/ruby/test_pattern_matching.rb:798: warning: assigned but unused variable - x ```
* Mark pattern labels as unremoveableVladimir Dementyev2021-01-191-0/+10
| | | | | | | | | Peephole optimization doesn't play well with find pattern at least. The only case when a pattern matching could have unreachable patterns is when we have lasgn/dasgn node, which shouldn't happen in real-life. Fixes https://bugs.ruby-lang.org/issues/17534
* Fix JIT link failuresTakashi Kokubun2021-01-181-0/+14
| | | | forgotten in https://github.com/ruby/ruby/pull/4018
* [ruby/irb] skip a failling test on TruffleRubyNobuhiro IMAI2021-01-181-0/+1
| | | | | | * due to the difference of backtrace pointed out by @aycabta https://github.com/ruby/irb/commit/5e00a0ae61
* [ruby/irb] handle repeated exception separatelyNobuhiro IMAI2021-01-181-0/+18
| | | | https://github.com/ruby/irb/commit/fcf6b34bc5
* [ruby/irb] handle `__ENCODING__` as a keyword as wellNobuhiro IMAI2021-01-181-1/+2
| | | | https://github.com/ruby/irb/commit/a6a33d908f
* [ruby/reline] Windows needs more times to wait renderingaycabta2021-01-181-1/+3
| | | | https://github.com/ruby/reline/commit/53ff2b09c7
* [ruby/reline] Tests with yamatanooroti don't need chdiraycabta2021-01-181-2/+0
| | | | | | Because of chdir, log files ware created in temporary directries on Windows. https://github.com/ruby/reline/commit/200b469a68
* Use the dedicated assertionNobuyoshi Nakada2021-01-171-2/+2
|
* Warn Struct#initialize with only keyword args (#4070)Takashi Kokubun2021-01-171-0/+12
| | | | | | | | | | | | | | | * Warn Struct#initialize with only keyword args A part of [Feature #16806] * Do not warn if `keyword_init: false` is explicitly specified * Add a NEWS entry * s/in/from/ * Make sure all fields are initialized
* Fix Ripper with heredoc.manga_osyo2021-01-171-0/+10
|
* [ruby/bigdecimal] Fix for the coerce cases in divide and DoDivmodKenta Murata2021-01-161-0/+13
| | | | https://github.com/ruby/bigdecimal/commit/1cb92487f7
* Keep encoding in the result of File.expand_path [Bug #17517]Nobuyoshi Nakada2021-01-151-0/+2
|
* Make Module#prepend affect ancestor chain even if argument already included ↵Jeremy Evans2021-01-141-1/+36
| | | | | | | | | | | | | | | in receiver Previously, if a class included a module and then prepended the same module, the prepend had no effect. This changes the behavior so that the prepend has an effect unless the module is already prepended the receiver. While here, rename the origin_seen variable in include_modules_at, since it is misleading. The variable tracks whether c has been seen, not whether the origin of klass has been. Fixes [Bug #17423]
* Rename RubyVM::MJIT to RubyVM::JITTakashi Kokubun2021-01-1320-55/+55
| | | | | | | | because the name "MJIT" is an internal code name, it's inconsistent with --jit while they are related to each other, and I want to discourage future JIT implementation-specific (e.g. MJIT-specific) APIs by this rename. [Feature #17490]
* Guard callinfoAaron Patterson2021-01-131-0/+10
| | | | | | | | | | | | | | | | Callinfo was being written in to an array and the GC would not see the reference on the stack. `new_insn_send` creates a new callinfo object, then it calls `new_insn_core`. `new_insn_core` allocates a new INSN linked list item, which can end up calling `xmalloc` which will trigger a GC: https://github.com/ruby/ruby/blob/70cd351c7c71c48ee18d7c01e851a89614086f8f/compile.c#L968-L969 Since the callinfo object isn't on the stack, the GC won't see it, and it can get collected. This patch just refactors `new_insn_send` to keep the object on the stack Co-authored-by: John Hawthorn <john@hawthorn.email>
* Capture to reserved name variables if already defined [Bug #17533]Nobuyoshi Nakada2021-01-131-0/+11
|
* Positional and keyword arguments for timezone are exclusiveNobuyoshi Nakada2021-01-131-0/+1
| | | | [Feature #17485]
* Added `in:` timezone option to `Time.new` [Feature #17485]Nobuyoshi Nakada2021-01-131-0/+1
|
* Make warning values consistent [Bug #17523]Nobuyoshi Nakada2021-01-131-0/+9
| | | | | | They should be affected, as well as `$VERBOSE`, by `-w`/`-W` options, not only in the main script but in scripts loaded by `-r` option too.
* Revert "[Bug #11213] let defined?(super) call respond_to_missing?"Nobuyoshi Nakada2021-01-131-33/+0
| | | | | | This reverts commit fac2498e0299f13dffe4f09a7dd7657fb49bf643 for now, due to [Bug #17509], the breakage in the case `super` is called in `respond_to?`.
* Allow UTC offset without colons per ISO-8601 [Bug #17504]Nobuyoshi Nakada2021-01-131-0/+6
|
* Fix method protection for modules in the ancestry chain.Marc-Andre Lafortune2021-01-121-0/+34
| | | | [Fixes ruby/ostruct#23]
* [ruby/bigdecimal] Allow digits=0 in BigDecimal(flt) and Float#to_dKenta Murata2021-01-132-3/+7
| | | | | | | | | | | | | | Using dtoa of mode=0, we can determine the number of digits in decimal that is necessary to represent the given Float number without errors. This change permits digits=0 in BigDecimal(flt) and Float#to_d, and these methods use dtoa of mode=0 when the given digits is 0. Internal implicit conversion from Float also uses digits=0. [Fix GH-70] https://github.com/ruby/bigdecimal/commit/2dbe170e35
* Skip test when UDP server is no response.Hiroshi SHIBATA2021-01-131-0/+3
|
* [ruby/bigdecimal] Use pre-allocated objects for special valuesKenta Murata2021-01-131-1/+7
| | | | https://github.com/ruby/bigdecimal/commit/95c201f2d3
* [ruby/bigdecimal] Fix exception message raised in Kernel.BigDecimalKenta Murata2021-01-131-1/+13
| | | | | https://github.com/ruby/bigdecimal/commit/d163f170a4 https://github.com/ruby/bigdecimal/commit/ff8eeeb064
* [ruby/reline] Move the cursor correctly when deleting at eolaycabta2021-01-131-0/+18
| | | | | | This fixes ruby/reline#246. https://github.com/ruby/reline/commit/07a73ba601
* [ruby/reline] Handle ed_search_{prev,next}_history in multiline correctlyaycabta2021-01-132-0/+61
| | | | | | | The current line was being handled incorrectly when displaying the hit history, so it has been fixed to be correct. https://github.com/ruby/reline/commit/a3df4343b3
* Fix the failing test with XDG_CONFIG_HOMEHiroshi SHIBATA2021-01-121-0/+4
|
* Remove "." and ".." from Dir.glob with FNM_DOTMATCH [Bug #17280]Nobuyoshi Nakada2021-01-122-2/+5
| | | | Co-authored-by: Jeremy Evans <code@jeremyevans.net>
* Convert time component strings to integers more strictlyNobuyoshi Nakada2021-01-121-0/+1
| | | | https://bugs.ruby-lang.org/issues/17485#change-89871
* Show seconds of utc_offset if not zeroNobuyoshi Nakada2021-01-121-0/+4
|
* Suppress constant redefinition warningsNobuyoshi Nakada2021-01-113-1/+9
|
* Get rid of defining methods for tests in core classesNobuyoshi Nakada2021-01-0914-317/+323
| | | | Not to interfere in other tests.
* [ruby/bigdecimal] Add test cases of conversion from FloatKenta Murata2021-01-091-0/+6
| | | | https://github.com/ruby/bigdecimal/commit/28d3836366
* parse.y: handle "duplicated argument name" appropriately on ripper.yNobuhiro IMAI2021-01-091-0/+1
| | | | refs: 733ed1e184
* [ruby/irb] Make IRB::ColorPrinter.pp compatible with PP.ppTakashi Kokubun2021-01-071-3/+3
| | | | | | | | | The incompatible interface is not helpful, again if you want to use it as a standalone library, falling it back to PP. Original PP.pp also ends with `out << "\n"`. https://github.com/ruby/irb/commit/4c74c7d84c
* should use `assert_include` here.Koichi Sasada2021-01-081-1/+1
| | | | | Random ordering test can introduce antoher candidate so it should be `assert_include`.
* [ruby/reline] Suppress auto indent for adding newlines in pastingaycabta2021-01-081-0/+15
| | | | | | Co-authored-by: Juanito Fatas <me@juanitofatas.com> https://github.com/ruby/reline/commit/074bb017a7
* [ruby/reline] Suppress crashing when dynamic_prompt_proc returns a broken ↵aycabta2021-01-081-0/+12
| | | | | | | | prompt list Co-authored-by: Juanito Fatas <me@juanitofatas.com> https://github.com/ruby/reline/commit/558f7be168
* [ruby/reline] Suppress crashing when auto_indent_proc returns broken indent infoaycabta2021-01-081-0/+14
| | | | | | Co-authored-by: Juanito Fatas <me@juanitofatas.com> https://github.com/ruby/reline/commit/7c24276275
* [ruby/reline] Remove debug printaycabta2021-01-081-1/+0
| | | | https://github.com/ruby/reline/commit/d7fbaedc6a
* [ruby/reline] Correct var names in Reline were different from vi-*-mode-stringaycabta2021-01-081-6/+6
| | | | https://github.com/ruby/reline/commit/8255fc93b9
* [ruby/reline] Update cursor correctly when just cursor movingaycabta2021-01-081-0/+18
| | | | | | This fixes ruby/reline#236 and ruby/reline#239. https://github.com/ruby/reline/commit/3e3c89d00b
* [ruby/irb] Fix BACK_TRACE_LIMIT logicaycabta2021-01-081-0/+66
| | | | https://github.com/ruby/irb/commit/30dc5d43fe
* [ruby/irb] Use Exception#full_message to show backtrace in the correct orderaycabta2021-01-082-2/+63
| | | | | | [Bug #17466] https://github.com/ruby/irb/commit/1c76845cca
* [ruby/irb] refactoring an error handling in `IRB::Inspector`Nobuhiro IMAI2021-01-081-8/+15
| | | | | | | | * moved rescue clause to `#inspect_value` to catch all failures in inspectors * test with all (currently five kind of) inspect modes - tweaked the input due to only `Marshal` can inspect(dump) a `BasicObject` https://github.com/ruby/irb/commit/9d112fab8e
* [ruby/irb] do not escape a predicate method for doc namespaceNobuhiro IMAI2021-01-081-0/+8
| | | | | | * Fixes #88 https://github.com/ruby/irb/commit/d431a30af4