aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* appveyor.yml: drop unnecessary 1.0. prefixk0kubun2018-08-131-77/+81
| | | | | | | | | | from version. Also I fixed the wrong way of using `for:`. Specifying `for` without `matrix.only` was just useless. This fix is for adding MinGW matrix in the future. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64342 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Add test for method_defined?(notimplement)kazu2018-08-131-0/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64341 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Revert "Support optional inherit argument for Module#method_defined?"kazu2018-08-132-152/+87
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64340 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* get rid of an encode noncompatible errorusa2018-08-131-0/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64339 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * remove trailing spaces.svn2018-08-131-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64338 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Support optional inherit argument for Module#method_defined?usa2018-08-132-87/+152
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Module has many introspection methods for methods and constants that either return an array or return true or false for whether the method or constant is defined. Most of these methods support an optional argument that controls whether to consider inheritance. Currently, the following Module methods support such a argument: * const_defined? * constants * instance_methods * private_instance_methods * protected_instance_methods * public_instance_methods and the following methods do not: * method_defined? * private_method_defined? * protected_method_defined? * public_method_defined? This patch supports such an argument for the *method_defined? methods. While you can currently work around the lack of support via: mod.instance_methods(false).include?(:method_name) This patch allows the simpler and more efficient: mod.method_defined?(:method_name, false) One case where you want to exclude inheritance when checking for a method definition is when you want to replace a method that may already exist. To avoid a verbose warning, you want to remove the method only if it is already defined: remove_method(:foo) if method_defined?(:foo, false) define_method(:foo){} You can't call remove_method without checking for the method definition, as that can raise a NameError, and you don't want to include inheritance because remove_method will still raise a NameError if the method is defined by an ancestor and not by the module itself. [ruby-core:88140] [Feature #14944] From: Jeremy Evans <code@jeremyevans.net> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64337 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/rinda/test_rinda.rb: Start keeper only on used testskazu2018-08-131-0/+32
| | | | | | to reduce sleeping threads on unrelated tests git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64336 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Makefile.in: drop MJIT_DLDFLAGS_NOCOMPRESSk0kubun2018-08-133-7/+0
| | | | | | which is obsoleted by r64331 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64335 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Don't free allocated uncompressed_debug_line until backtrace is printednaruse2018-08-131-8/+10
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64334 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Re-apply wrongly reverted r64330naruse2018-08-131-6/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64333 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Define parse_compressed_debug_line() only ifdef SUPPORT_COMPRESSED_DEBUG_LINEnaruse2018-08-131-1/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64332 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* support compressed debug_linenaruse2018-08-132-10/+66
| | | | | | | | re-commit r64328 https://blogs.oracle.com/solaris/elf_section_compression-v2 https://gnu.wildebeest.org/blog/mjw/2016/01/13/elf-libelf-compressed-sections-and-elfutils/ git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64331 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* configure.ac: use linker_flag to LIBRUBY_DLDFLAGSnobu2018-08-131-6/+2
| | | | | | | | | | * configure.ac: use a feature flag `linker_flag`, than checking if the compiler is `GCC`. * configure.ac: append to LIBRUBY_DLDFLAGS once after initialized with DLDFLAGS. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64330 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Revert "support compressed debug_line"naruse2018-08-132-55/+7
| | | | | | This reverts commit r64328 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64329 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* support compressed debug_linenaruse2018-08-132-7/+55
| | | | | | | https://blogs.oracle.com/solaris/elf_section_compression-v2 https://gnu.wildebeest.org/blog/mjw/2016/01/13/elf-libelf-compressed-sections-and-elfutils/ git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64328 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* timegm_noleapsecond uses calc_tm_yday.akr2018-08-121-5/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64327 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* configure.ac: use the correct argumentk0kubun2018-08-121-1/+1
| | | | | | | | | | | | for --compress-debug-sections. I thought "no" is the correct one because configure.ac has `AS_IF([test "x$compress_debug_sections" != xno]`, but it wasn't the case. This commit is needed to resolve errors like: /usr/bin/x86_64-linux-gnu-ld: invalid --compress-debug-sections option: `no' collect2: error: ld returned 1 exit status git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64326 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* configure.ac: MJIT_DLDFLAGS_NOCOMPRESSk0kubun2018-08-123-1/+5
| | | | | | | | | | | | | | is configured now, to force -Wl,--compress-debug-sections=no for MJIT only when the option is used in MJIT_DLDFLAGS. This needs to be done in configure.ac to resolve build failure like https://travis-ci.org/ruby/ruby/builds/415120662. Makefile.in: define it in mjit_config.h mjit_worker.c: replace hard-coded flag to MJIT_DLDFLAGS_NOCOMPRESS git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64325 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2018-08-13svn2018-08-121-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64324 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: lazily delete so filek0kubun2018-08-121-20/+20
| | | | | | | | | on ELF. I need symbol name and line number to lazily create program counter for optimization on ELF binary. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64323 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: allow showing line numberk0kubun2018-08-121-1/+10
| | | | | | | | | on addr2line.c, if --jit-save-temps is specified. I'm going to use the line number to lazily create program counter to improve the performance degraded in r64283. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64322 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit.c: reduce the number of variablesk0kubun2018-08-121-7/+5
| | | | | | in mark_ec_units() to simplify code. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64321 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Optimization for case when with splat operatornobu2018-08-121-4/+42
| | | | | | | | [Fix GH-1928] [Feature #14984] From: chopraanmol1 <chopraanmol1@gmail.com> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64318 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* tool/downloader.rb: increase retriesk0kubun2018-08-121-1/+1
| | | | | | | | | | | GitHub download failed on 13:50:36 https://ci.appveyor.com/project/ruby/ruby/build/1.0.9221 and it also failed on 13:51:35 (all builds between them failed too). It means that we need to expect GitHub 502 that continues 1 minute. So I configured 6 retries, that will sleep at most 91s in total. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64317 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* compile.c: use EXPECT_NODE macronobu2018-08-121-5/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64316 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* compile.c: check error in when_valsnobu2018-08-121-1/+2
| | | | | | | | * compile.c (when_vals): return a negative value on error. * compile.c (compile_case): check error in when_vals(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64315 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* vm_insnhelper.c: revert r64280k0kubun2018-08-122-25/+22
| | | | | | | This commit caused test-all failure with --jit-wait. I don't know the reason yet, but let me revert it to normalize CI. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64314 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* skip non-IP interfacesnobu2018-08-121-2/+2
| | | | | | | * spec/ruby/library/socket/socket/getifaddrs_spec.rb: VirtualBox host only adapter seems something different than ordinary interfaces. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64313 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* vm_insnhelper.c: drop duplicated inlinek0kubun2018-08-111-1/+1
| | | | | | | to resolve warning: c:\projects\ruby\vm_insnhelper.c(1661) : warning C4141: 'inline' : used more than once git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64312 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* appveyor.yml: customize icon_urlk0kubun2018-08-111-2/+5
| | | | | | | We're using "x" sign as an icon for incoming webhook, but the success notification by `on_build_status_changed` should not be an "x" asign. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64311 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2018-08-12svn2018-08-111-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64310 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* fix r64296naruse2018-08-111-9/+9
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64309 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_rubyvm_mjit.rb: skip testing MJIT if not supportedk0kubun2018-08-111-0/+6
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64308 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit.c: stop defining alias for a very limited usek0kubun2018-08-111-5/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64307 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit.c: drop obsoleted duplicated declarationk0kubun2018-08-111-3/+1
| | | | | | | of mjit_worker(). It was needed when mjit_worker.c is separated from mjit.c, but it's now just included. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64306 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: remove redundant cast for calloc/allocak0kubun2018-08-111-8/+8
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64305 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: handle calloc failurek0kubun2018-08-112-0/+11
| | | | | | | | Unlike ZALLOC, it's not automatically handled. mjit.c: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64304 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_env.rb: a failure on appveyornobu2018-08-111-1/+1
| | | | | | | * test/ruby/test_env.rb (test_huge_value): Windows 8 seems having a limit on single environment variable. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64303 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: never trigger GC on MJIT workerk0kubun2018-08-111-3/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64302 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: don't use ruby_strdupk0kubun2018-08-112-4/+13
| | | | | | | | on MJIT worker. That may trigger GC. And handled strdup failure instead. mjit_compile.c: update comment about GC git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64301 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* appveyor.yml: show the OS versionnobu2018-08-111-0/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64300 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_rubyvm_mjit.rb: dump output on test_pausek0kubun2018-08-111-1/+4
| | | | | | | failure. It's failing on mswinci but it's hard to know the cause without out/err. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64299 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: share MJIT warning logick0kubun2018-08-112-21/+29
| | | | | | | | as mjit_warning(). mjit.c: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64298 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Solaris 10 doesn't have getifaddrsnaruse2018-08-111-0/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64297 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Solaris raises EAI_SERVICE if hints.ai_socktype=0naruse2018-08-111-9/+13
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64296 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_iseq_load.rb: reduce timeout of test_stressful_roundtripk0kubun2018-08-111-1/+1
| | | | | | | We should increase RUBY_TEST_SUBPROCESS_TIMEOUT_SCALE for slow environments, and we configured some CI machines. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64295 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* upgrade the default WINNT versionnobu2018-08-111-2/+2
| | | | | | | | * configure.ac: set the default target Windows NT version to 0x0600, as well as mswin version since r50051. Windows XP has ended years ago. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64294 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* hash.c: env block size limit on Windowsnobu2018-08-112-11/+39
| | | | | | | | | | * hash.c (ruby_setenv): do not check environment block size. c.f. https://msdn.microsoft.com/en-us/library/windows/desktop/ms682653(v=vs.85).aspx Starting with Windows Vista and Windows Server 2008, there is no technical limitation on the size of the environment block. [ruby-core:88400] [Bug #14979] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64293 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: resurrect more static declarationsk0kubun2018-08-112-69/+51
| | | | | | | | and remove old mjit_ prefixes again. mjit.c: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64292 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: reorder functions and variablesk0kubun2018-08-111-133/+129
| | | | | | | | so that related things are placed closely. Sorry for mixing them in previous commits... git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64291 b2dd03c8-39d4-4d8f-98ff-823fe69b080e