Actions
Bug #12215
closedURI::HTTP.new example is incorrect
Description
On this page (http://ruby-doc.org/stdlib-2.3.0/libdoc/uri/rdoc/URI/HTTP.html) the example for URI::HTTP.new will result in an error (ArgumentError: wrong number of arguments (given 7, expected 9..11)
).
A working example (2.3.0-dev) is: uri = URI::HTTP.new('http', nil, "www.example.com", nil, nil, "/path", nil, "query", 'fragment')
.
Updated by shevegen (Robert A. Heiler) almost 9 years ago
You are right.
uri = URI::HTTP.new('http', nil, "www.example.com", nil, "/path", "query", 'fragment')
Triggers the error. Should be changed.
Updated by nobu (Nobuyoshi Nakada) almost 9 years ago
- Status changed from Open to Closed
Applied in changeset r54257.
fix URI::HTTP.new example
- lib/uri/http.rb (URI::HTTP#initialize): [DOC] fix example,
missing mandatory arguments. [ruby-core:74540] [Bug #12215]
Updated by usa (Usaku NAKAMURA) almost 9 years ago
- Backport changed from 2.1: UNKNOWN, 2.2: UNKNOWN, 2.3: UNKNOWN to 2.1: REQUIRED, 2.2: REQUIRED, 2.3: REQUIRED
Updated by usa (Usaku NAKAMURA) almost 9 years ago
- Backport changed from 2.1: REQUIRED, 2.2: REQUIRED, 2.3: REQUIRED to 2.1: DONE, 2.2: REQUIRED, 2.3: REQUIRED
ruby_2_1 r54395 merged revision(s) 54257.
Updated by nagachika (Tomoyuki Chikanaga) almost 9 years ago
- Backport changed from 2.1: DONE, 2.2: REQUIRED, 2.3: REQUIRED to 2.1: DONE, 2.2: DONE, 2.3: REQUIRED
Backported into ruby_2_2
branch at r54427.
Updated by naruse (Yui NARUSE) almost 9 years ago
- Backport changed from 2.1: DONE, 2.2: DONE, 2.3: REQUIRED to 2.1: DONE, 2.2: DONE, 2.3: DONE
ruby_2_3 r54550 merged revision(s) 54257.
Actions
Like0
Like0Like0Like0Like0Like0Like0