summaryrefslogtreecommitdiff
path: root/lib
AgeCommit message (Collapse)Author
2018-05-13optparse.rb: Remove redundant `.freeze`nobu
[Fix GH-1873] From: Masataka Pocke Kuwabara <kuwabara@pocke.me> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63411 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-12optparse.rb: [DOC] about into: optionnobu
* lib/optparse.rb: add documentation for "into" option of #parse and family, which stores options to a Hash. [ruby-core:87004] [Misc #14753] From: pocke (Masataka Kuwabara) <kuwabara@pocke.me> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63410 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-12irb.rb: update `_`nobu
* lib/irb.rb (IRB::Irb#eval_input): update `_` after exception. [ruby-core:86989] [Bug #14749] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63409 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-12rss: Add option Hash support to RSS::Parser.parsekou
Available options: * :validate * :ignore_unknown_element * :parser_class git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63407 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-11lib/securerandom.rb: improve docsstomar
* lib/securerandom.rb: [DOC] drop unnecessary `p' from code examples. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63402 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-11mkmf.rb: set cppflagsngoto
* ext/mkmf.rb (configuration): set the default cppflags, which is referred from the default CPPFLAGS, for extension libraries. This fixes build failure of ext/zlib on Solaris 10. [Bug #14746] [ruby-dev:50539] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63398 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-11net/imap: Fix ArgumentError in send_string_datashugo
Thanks to ShockwaveNN (Pavel Lobashov) for reporting the bug. [ruby-core:86990] [Bug #14750] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63396 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-09Use hard-coded file list instead of Dir.glob.hsbt
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63377 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-09Revert "Use hard-coded vesion number for CI broken."hsbt
This reverts commit f5fef0a80d597f40c2d1a8cc8079bf190039fd6f. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63376 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-09Use hard-coded vesion number for CI broken.hsbt
https://rubyci.org/logs/rubyci.s3.amazonaws.com/ubuntu/ruby-trunk/log/20180509T063003Z.fail.html.gz git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63374 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-09Fixed file structure for csv.gemspec.hsbt
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63367 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-09* append newline at EOF.svn
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63365 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-09Merge csv-1.0.2 from upstream.hsbt
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63364 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-08Merge rdoc-6.0.4 from upstream.hsbt
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63356 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-06optparse: Suppress warningsnobu
Ruby warns "instance variable `@version` not initialized" for optparse when it receives `--version` option. `test.rb` ```ruby require 'optparse' Version = '1' OptionParser.new.parse(ARGV) ``` ``` $ ruby -w test.rb --version /home/pocke/.rbenv/versions/2.5.1/lib/ruby/2.5.0/optparse.rb:1168: warning: instance variable @version not initialized /home/pocke/.rbenv/versions/2.5.1/lib/ruby/2.5.0/optparse.rb:1175: warning: instance variable @release not initialized test 1 ``` This change will suppress the warnings. [Fix GH-1871] From: Masataka Pocke Kuwabara <kuwabara@pocke.me> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63342 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-05securerandom.rb: [DOC] require in examplesnobu
* lib/securerandom.rb: added `require 'securerandom'` to each example, to state these methods are defined in this library and require it explicitly. [ruby-core:85933] [Bug #14576] [ci skip] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63341 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-04Use `&.` instead of modifier ifkazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63336 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-01rexml: Suppress warningskou
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63311 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-30Use `&.` instead of modifier ifkazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63306 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-28rexml: disable XPath 1.0 compatible "#{ELEMENT_NAME}" processing by defaultkou
It breaks backward compatibility than I thought. So it's disabled by default. It means that REXML's XPath processor isn't compatible with XPath 1.0. But it will be acceptable for users. We can enable it by specifying "strict: true" to REXML::XPathParser.new explicitly. * lib/rexml/xpath.rb, lib/rexml/xpath_parser.rb: Accept "strict: true" option. * test/rexml/test_contrib.rb, test/rexml/xpath/test_base.rb: Use not XPath 1.0 compatible behavior. * test/rexml/test_jaxen.rb: Use XPath 1.0 compatible behavior. * test/rss/test_1.0.rb, test/rss/test_dublincore.rb, spec/ruby/library/rexml/element/namespace_spec.rb, spec/ruby/library/rexml/element/namespaces_spec.rb, spec/ruby/library/rexml/element/prefixes_spec.rb: Enable again. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63278 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-25[DOC] Fix capitallizing [ci skip]kazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63260 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-25common.rb: unused constantnobu
* lib/uri/common.rb (URI::HTML5ASCIIINCOMPAT): remove the constant which has been unused since r40460, and wrong since r49069 due to the operator precedence. [ruby-core:86678] [Bug #14711] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63259 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-23[DOC] URI::Generic#port returns Integer [ci skip]kazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63247 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-22net/imap: set SO_KEEPALIVE on TCP socketsnormal
Otherwise connections (commonly on IDLE, but it could be any command) may never receive notifications of link errors. [ruby-core:86628] [Feature #14703] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63243 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-22rexml: Fix XPath bug of //#{ELEMENT_NAME}[#{POSITION}]kou
The position should be counted for each nodeset but the previous implementation counts position for union-ed nodeset. For example, "/a/*/*[1]" should be matched to "<c1/>" and "<c2/>" with the following XML. <a> <b> <c1/> </b> <b> <c2/> </b> </a> But the previous implementation just returns only "<c1/>". * lib/rexml/element.rb (REXML::Attributes#each_attribute): Support Enumerator for no block use. * lib/rexml/element.rb (REXML::Attributes#each): Support Enumerator for no block use. * lib/rexml/functions.rb (REXML::Functions.string): Support NaN again. * lib/rexml/xpath_parser.rb: Re-implement "Step" evaluator. It should evaluate "AxisSpecifier", "NodeTest" and "Predicate" in one step to respect position for each nodeset. * test/rexml/test_jaxen.rb: Enable more tests. Remained tests should be also enabled but it'll not be near future. * test/rexml/xpath/test_base.rb: Fix expected value. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63237 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-22rexml: Fix XPath bug of /#{ELEMENT_NAME}kou
It doesn't mean that all elements which name "ELEMENT_NAME" with any namespace URI including null namespace URI. It means that all elements which name "ELEMENT_NAME" with null namespace URI. https://www.w3.org/TR/1999/REC-xpath-19991116/#NT-NodeTest > if the QName does not have a prefix, then the namespace URI is null > (this is the same way attribute names are expanded). We need to use "*[local-name()='#{ELEMENT_NAME}']" for all elements which name "ELEMENT_NAME" with any namespace URI including null namespace URI in XPath 1.0. But it's inconvenient. So this change includes "*:#{LOCAL_NAME}" syntax support that is introduced since XPath 2.0. * lib/rexml/parsers/xpathparser.rb: Support "*:#{LOCAL_NAME}" syntax that is introduced since XPath 2.0. * lib/rexml/xpath_parser.rb: * Fix namespace URI processing for "#{ELEMENT_NAME}". Now, "#{ELEMENT_NAME}" doesn't accept elements with null namespace URI. * Add "*:#{LOCAL_NAME}" support. * test/rexml/test_contrib.rb, test/rexml/test_core.rb, test/rexml/xpath/test_base.rb: Follow this change. * test/rexml/test_jaxen.rb: Fix namespace processing. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63236 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-21Improve docs for URI librarystomar
* lib/uri/generic.rb: [DOC] fix invalid example code to make it syntax highlighted; drop unnecessary `puts', `p'; adapt to current inspect format without Object id; do not display unnecessary return values in examples; fix or prevent unintended description lists; fix broken RDoc; fix grammar and typos. * lib/uri.rb: ditto. * lib/uri/common.rb: ditto. * lib/uri/file.rb: ditto. * lib/uri/ftp.rb: ditto. * lib/uri/http.rb: ditto. * lib/uri/ldap.rb: ditto. * lib/uri/mailto.rb: ditto. * lib/uri/rfc2396_parser.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63228 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-21rexml: Fix XPath concat() implementationkou
* lib/rexml/functions.rb (REXML::Functions.concat): Implement. * test/rexml/test_jaxen.rb: Enable one more test. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63222 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-21rexml: Fix XPath string() implementationkou
* lib/rexml/functions.rb( REXML::Functions.string): * Support context node. * Fix implementation for document node to remove out of root nodes. * Support processing instruction node. * Improve implementation for integer to omit decimals. * test/rexml/test_jaxen.rb: Enable processing instruction test. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63221 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-19rexml: Fix a XPath bug that white spaces aren't ignoredkou
lib/rexml/parsers/xpathparser.rb: Ignore white spaces in relative location path. test/rexml/xpath/test_base.rb: Add more test patterns and use more debug friendly assertion style. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63204 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-17lib/uri/generic.rb: fix error in docs for URI::Generic#opaquestomar
* lib/uri/generic.rb: [DOC] fix description of URI::Generic#opaque, and add an example. According to RFC2396, opaque path components do not use the slash "/" character, as opposed to hierarchical path components. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63186 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-17lib/uri/ldap.rb: fix errors in docs for URI::LDAPstomar
* lib/uri/ldap.rb: [DOC] fix errors in example code for URI::LDAP.build and URI::LDAP.new. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63185 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-17lib/uri/file.rb: fix errors in docs for URI::File.buildstomar
* lib/uri/file.rb: [DOC] fix description and example for URI::File.build; for file URIs the path component must be absolute, escaping of absolute paths is only done for URI::FTP. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63184 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-17lib/uri/file.rb: improve docs for URI::Filestomar
* lib/uri/file.rb: [DOC] fix invalid example code for URI::File.build to make it syntax highlighted; drop unnecessary `puts'; fix unintended description list; fix typos. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63182 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-16[DOC] Fix links of cve [ci skip]k0kubun
`http://www.cve.mitre.org/` seem to move `http://cve.mitre.org/`. I can't access `http://www.cve.mitre.org/`. [Fix GH-1857] From: willnet <netwillnet@gmail.com> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63166 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-14lib/fileutils.rb: [DOC] fix typos and grammarstomar
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63156 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-14irb.rb: restore the last errornobu
* lib/irb.rb (eval_input): restore the last error `$!`, as the previous result. [Feature #14684] * lib/irb/context.rb (evaluate): add `exception` keyword argument to set the last error. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63150 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-14irb/{context,workspace}.rb: use local_variable_setnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63149 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-14irb/context.rb: using input-methodnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63148 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-13irb.rb: backtrace ordernobu
* lib/irb.rb (handle_exception): show backtrace from the topmost if stdout is not a tty. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63146 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-13irb.rb: hoist out handle_exceptionnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63144 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-09rexml: Fix a XPath bug of -kou
[Bug #14600] * lib/rexml/parsers/xpathparser.rb: Fix a bug that "N-M" requires a space before "-". git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63128 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-05lib/rubygems/test_case.rb: take over @gem_prelude_indexmame
Gem::TestCase normalizes each path in $LOAD_PATH, which deleted the flag of @gem_prelude_index. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63100 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-04rexml: Fix a XPath bug of /child::node()kou
[Bug #14600] * lib/rexml/xpath_parser.rb: Fix a bug that "/child::node()" returns XML declaration and text nodes out of root element. * test/rexml/test_jaxen.rb: Enable more tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63088 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-04rexml: Add codes for debugging XPath logickou
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63087 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-04rexml: Fix a XPath bug of function()/pathkou
[Bug #14600] * lib/rexml/functions.rb: Fix a bug that "function()/path" always returns nothing. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63086 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-04rexml: Fix a XPath bug of @attribute/parentkou
[Bug #14600] * lib/rexml/functions.rb: Fix a bug that "@attribute/parent" doesn't return element of its attribute. * test/rexml/test_jaxen.rb: Enable more tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63083 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-04rexml: Fix a XPath bug of $variablekou
[Bug #14600] * lib/rexml/functions.rb: Fix a bug that "$variable" returns node instead of ndoe set. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63082 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-03rexml: Fix a XPath bug of name(node-set)kou
[Bug #14600] * lib/rexml/functions.rb: Fix a bug that "name(node-set)" returns element instead of element name. * test/rexml/test_jaxen.rb: Enable more tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63079 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-03repatch r62966 and r62969.ko1
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63074 b2dd03c8-39d4-4d8f-98ff-823fe69b080e