aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Set Thread.report_on_exception=true by default to report exceptions in Threadseregon2017-12-125-17/+42
| | | | | | | | | | | | | | * [Feature #14143] [ruby-core:83979] * vm.c (vm_init2): Set Thread.report_on_exception to true. * thread.c (thread_start_func_2): Add indication the message is caused by report_on_exception = true. * spec/ruby: Specify the new behavior. * test/ruby/test_thread.rb: Adapt and improve tests for Thread.report_on_exception and Thread#report_on_exception. * test/ruby/test_thread.rb, test/ruby/test_exception.rb: Unset report_on_exception for tests expecting no extra output. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61183 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* struct.c: don't explain implementation detailsk0kubun2017-12-121-4/+8
| | | | | | | | | | | | of keyword_init option. [DOC] [ci skip] It's implemented to take Hash, but it's just implementation detail and it's intended to behave in the same way as keyword arguments (for :keyword_init option too). Also I unified coding style of r61137 with other places. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61182 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* struct.c: show `keyword_init: true` on inspectk0kubun2017-12-122-0/+13
| | | | | | | | | | | | | | | | | for debugging if it's specified for the Struct class. This follows up r61137. We don't provide a method to check it because I don't think of any use case, but showing this to inspect would be helpful for debugging if someone is debugging whether keyword_init is properly enabled or not. In this commit, I didn't show `keyword_init: false` because of backward compatibility. Ideally any application should not depend on the behavior of inspect, but I don't have strong motivation to break it too. [close GH-1773] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61181 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* set ino at `File.lstat` on Windowsusa2017-12-121-103/+24
| | | | | | | | | | | | | * win32/win32.c (winnt_stat): support symbolic link and others. * win32/win32.c (w32_stati128, wstati128, name_for_stat, rb_w32_{,ul}stati128, wutimensat): follow above change. [Feature #14169] From: Takehiro Kubo kubo@jiubao.org git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61180 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Add more example of `Enumerable#one?` [ci skip]kazu2017-12-121-0/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61179 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* pattern and modulo are not keyword argument [ci skip]kazu2017-12-121-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61178 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Fix typos [ci skip]kazu2017-12-121-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61177 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* atime,mtime,ctime of File::Stat are instance methodskazu2017-12-121-1/+1
| | | | | | [ci skip] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61176 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Remove unnecessary `:`kazu2017-12-121-1/+1
| | | | | | | | | | | | | | Before: `.../irb/init.rb:280: warning: :LoadError: cannot load such file -- hoge` After: `.../irb/init.rb:280: warning: LoadError: cannot load such file -- hoge` [ci skip] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61175 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Use printf instead of puts and sprintfkazu2017-12-121-1/+1
| | | | | | [ci skip] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61174 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2017-12-13svn2017-12-121-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61173 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* [DOC] Process.last_status may return nilkazu2017-12-121-1/+1
| | | | | | [ci skip] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61172 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: Change the last location of noneyui-knk2017-12-121-1/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * parse.y: Change the last location of none to be equal to the first location of none. Sometimes none has length (`parser->tokp` does not match `lex_p` when none is generated). This leads to invalid code_ranges. e.g. The locations of the NODE_CALL (:sort) is fixed: ``` x.sort.join(" ") ``` * Before ``` NODE_CALL (line: 1, code_range: (1,0)-(1,7)) ``` * After ``` NODE_CALL (line: 1, code_range: (1,0)-(1,6)) ``` git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61171 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: Set locations of nd_body in NODE_ITER explicitlyyui-knk2017-12-121-0/+4
| | | | | | * parse.y: Same as r61168, but for brace_block. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61170 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Revert "switch from http to https for Unicode data file downloads"hsbt2017-12-121-1/+1
| | | | | | | | | This reverts commit 90de118a75921a08497b41de2950971073b3c924. The environment of mswinci couldn't handle https download. (It's certificates problem, We should upgrade its environment) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61169 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: Set locations of nd_body in NODE_ITER explicitlyyui-knk2017-12-121-0/+4
| | | | | | | | | | | | | | * parse.y: Currently the location of do_body is set by new_do_body. Sometimes the last part of do_body is none, because bodystmt ends with opt_ensure. Token keyword_end has been looked ahead when a tokenizer generates none, so the last location of opt_ensure matches the last location of `end`. But this relation will be broken when we change the last location of none to be equal to the first location of none. So set locations of nd_body in NODE_ITER explicitly. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61168 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* irb/test_init.rb: add test to ensure $0k0kubun2017-12-121-0/+6
| | | | | | | | | | | | is not changed. At first `ARGV.unshift('something')` was suggested for r61149, but it wasn't sufficient because it modifies $0. Not only to preserve ARGV, but also r61149 intends to preserve $0. This test prevents future breakage of the behavior. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61167 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_struct.rb: rename constants to clarifyk0kubun2017-12-121-10/+10
| | | | | | | | | the intention. Follows up r61137. They were forgotten to be renamed when :keyword_args is renamed to :keyword_init. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61166 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/coverage/coverage.c: Add test casesyui-knk2017-12-121-0/+7
| | | | | | | | * ext/coverage/coverage.c (test_method_coverage_for_define_method): Add test cases for method coverages which test do-end block define_method. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61165 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * remove trailing spaces.svn2017-12-121-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61164 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* NEWS: polishsorah2017-12-121-88/+156
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61163 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ignore lines (to catch up r61155).ko12017-12-122-3/+3
| | | | | | | | | * spec/ruby/library/net/ftp/return_code_spec.rb: check message body only. * spec/ruby/library/net/http/http/set_debug_output_spec.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61162 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* error.c(rb_error_write): Remove ec_ from its namesorah2017-12-122-4/+4
| | | | | | | It's unrelated to rb_execution_context_t during writing the patch r61154 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61161 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* NEWS for Method#===a_matsuda2017-12-121-0/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61160 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Unneeded assertiona_matsuda2017-12-121-1/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61159 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Add Method#=== that invokes #calla_matsuda2017-12-122-0/+7
| | | | | | Patch by osyo via [Feature #14142] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61158 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* hotfix implicit-function-declarationsorah2017-12-122-1/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61157 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* NEWS entry for [Feature #12882]shyouhei2017-12-121-0/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61156 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Add uplevel keyword to Kernel#warn and use itshyouhei2017-12-1232-63/+92
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If uplevel keyword is given, the warning message is prepended with caller file and line information and the string "warning: ". The use of the uplevel keyword makes Kernel#warn format output similar to how rb_warn formats output. This patch modifies net/ftp and net/imap to use Kernel#warn instead of $stderr.puts or $stderr.printf, since they are used for printing warnings. This makes lib/cgi/core and tempfile use $stderr.puts instead of warn for debug logging, since they are used for debug printing and not for warning. This does not modify bundler, rubygems, or rdoc, as those are maintained outside of ruby and probably wish to remain backwards compatible with older ruby versions. rb_warn_m code is originally from nobu, but I've changed it so that it only includes the path and lineno from uplevel (not the method), and also prepends the string "warning: ", to make it more similar to rb_warn. From: Jeremy Evans code@jeremyevans.net Signed-off-by: Urabe Shyouhei shyouhei@ruby-lang.org git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* error.c(exc_full_message): Exception#full_messagesorah2017-12-124-53/+109
| | | | | | | | | Add a method to retrieve a String expression of an exception, formatted in the same way that Ruby prints an uncaught exception out. [Feature #14141] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61154 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* remove unused variableusa2017-12-121-1/+0
| | | | | | | thanks kubo-san. c.f. [ruby-dev:50345] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61153 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* NEWS entry for FrozenError [Feature #13224]shyouhei2017-12-121-0/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61152 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* irb/init.rb: make sure ARGV refers to toplevel onek0kubun2017-12-121-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61151 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * properties.svn2017-12-120-0/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61150 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* irb.rb: preserve ARGV on binding.irbk0kubun2017-12-123-16/+41
| | | | | | | | | | | | | | | This is not perfectly good solution (at least we don't want to have ARGV as default value of `argv` argument), but unfortunately IRB.setup and IRB.parse_opts are public methods and we can't make breaking change to those methods. We may deprecate using them and then make them private in the future, but the removal should not be in Ruby 2.5. So I kept their interface for now. [Bug #14162] [close GH-1770] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61149 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Bump version to fileutils-1.0.1.hsbt2017-12-121-1/+7
| | | | | | | Update source code url metadata on rubygems.org. [Feature #13197][ruby-core:79455] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61148 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Integer#allbits?, Integer#anybits?, Integer#nobits? [Feature #12753]naruse2017-12-123-0/+67
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61147 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Bump version to fileutils-1.0.0 as default gems.hsbt2017-12-121-3/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61146 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* switch from http to https for Unicode data file downloadsduerst2017-12-121-1/+1
| | | | | | (patch from MSP-Greg (Greg L), this closes issue #13962) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61145 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* NEWS: mention Process.last_statusmrkn2017-12-121-0/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61144 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* process.c: add Process.last_statusmrkn2017-12-122-0/+27
| | | | | | | | | | * process.c (proc_s_last_status): add Process.last_status [ruby-core:83514] [Feature #14043] * test/ruby/test_process.rb (test_last_status): add a test case for Process.last_status. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61143 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: Fix the locations of NODE_ITER (cmd_brace_block)yui-knk2017-12-121-0/+9
| | | | | | | | | | | | | | | | | | | | | | | * parse.y: Update the locations of NODE_ITER when nd_iter is determined. ``` a (1) {|i|} ``` * Before ``` NODE_ITER (line: 1, code_range: (1,6)-(1,10)) ``` * After ``` NODE_ITER (line: 1, code_range: (1,0)-(1,11)) ``` git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61142 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mention support of emoji-related Unicode character properties in NEWSduerst2017-12-121-0/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61141 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * properties.svn2017-12-120-0/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61140 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Ignore gemspec under the lib directory for documentation.hsbt2017-12-122-0/+30
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61139 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* NEWS: add entry for r61137k0kubun2017-12-121-0/+5
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61138 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* struct.c: add keyword_init option to Struct.newk0kubun2017-12-123-11/+92
| | | | | | | | to initialize struct with keyword arguments. [Feature #11925] [close GH-1771] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61137 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * properties.svn2017-12-120-0/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61136 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * remove trailing spaces, append newline at EOF.svn2017-12-122-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61135 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Merge 1-16-stable branch of bundler.hsbt2017-12-1225-58/+226
| | | | | | | It's rc version for bundler-1.16.1. I'm going to update it version after official release from bundler team. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61134 b2dd03c8-39d4-4d8f-98ff-823fe69b080e