diff options
author | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2020-09-23 21:59:35 +0900 |
---|---|---|
committer | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2020-09-23 22:01:44 +0900 |
commit | b717f73402dc6f2d6ba6a1d72d9c8543a4f2cd27 (patch) | |
tree | 9d4a4c198aa124592552c66e2a3e6d130b6486eb /lib/rubygems/package | |
parent | a46841612c846f00f31ff63d886620d66cdea5b3 (diff) | |
download | ruby-b717f73402dc6f2d6ba6a1d72d9c8543a4f2cd27.tar.gz |
Revert "Manually merged from https://github.com/rubygems/rubygems/pull/2636"
31a6eaabc165d8a222e176f2c809d90622d88ec2 is obsoleted with
https://github.com/rubygems/rubygems/pull/3820
Diffstat (limited to 'lib/rubygems/package')
-rw-r--r-- | lib/rubygems/package/digest_io.rb | 2 | ||||
-rw-r--r-- | lib/rubygems/package/file_source.rb | 2 | ||||
-rw-r--r-- | lib/rubygems/package/io_source.rb | 2 | ||||
-rw-r--r-- | lib/rubygems/package/old.rb | 2 | ||||
-rw-r--r-- | lib/rubygems/package/tar_header.rb | 2 | ||||
-rw-r--r-- | lib/rubygems/package/tar_reader.rb | 2 | ||||
-rw-r--r-- | lib/rubygems/package/tar_reader/entry.rb | 2 | ||||
-rw-r--r-- | lib/rubygems/package/tar_test_case.rb | 2 | ||||
-rw-r--r-- | lib/rubygems/package/tar_writer.rb | 6 |
9 files changed, 0 insertions, 22 deletions
diff --git a/lib/rubygems/package/digest_io.rb b/lib/rubygems/package/digest_io.rb index d9e6c3c021..4736f76d93 100644 --- a/lib/rubygems/package/digest_io.rb +++ b/lib/rubygems/package/digest_io.rb @@ -3,7 +3,6 @@ # IO wrapper that creates digests of contents written to the IO it wraps. class Gem::Package::DigestIO - ## # Collected digests for wrapped writes. # @@ -60,5 +59,4 @@ class Gem::Package::DigestIO result end - end diff --git a/lib/rubygems/package/file_source.rb b/lib/rubygems/package/file_source.rb index 8a4f9da6f2..114a950c77 100644 --- a/lib/rubygems/package/file_source.rb +++ b/lib/rubygems/package/file_source.rb @@ -7,7 +7,6 @@ # object to `Gem::Package.new`. class Gem::Package::FileSource < Gem::Package::Source # :nodoc: all - attr_reader :path def initialize(path) @@ -29,5 +28,4 @@ class Gem::Package::FileSource < Gem::Package::Source # :nodoc: all def with_read_io(&block) File.open path, 'rb', &block end - end diff --git a/lib/rubygems/package/io_source.rb b/lib/rubygems/package/io_source.rb index 669a859d0a..7d7383110b 100644 --- a/lib/rubygems/package/io_source.rb +++ b/lib/rubygems/package/io_source.rb @@ -8,7 +8,6 @@ # object to `Gem::Package.new`. class Gem::Package::IOSource < Gem::Package::Source # :nodoc: all - attr_reader :io def initialize(io) @@ -41,5 +40,4 @@ class Gem::Package::IOSource < Gem::Package::Source # :nodoc: all def path end - end diff --git a/lib/rubygems/package/old.rb b/lib/rubygems/package/old.rb index aeb6c999c0..25317ef23f 100644 --- a/lib/rubygems/package/old.rb +++ b/lib/rubygems/package/old.rb @@ -12,7 +12,6 @@ # Please pretend this doesn't exist. class Gem::Package::Old < Gem::Package - undef_method :spec= ## @@ -166,5 +165,4 @@ class Gem::Package::Old < Gem::Package true end - end diff --git a/lib/rubygems/package/tar_header.rb b/lib/rubygems/package/tar_header.rb index 19927c0e27..f19aea549d 100644 --- a/lib/rubygems/package/tar_header.rb +++ b/lib/rubygems/package/tar_header.rb @@ -28,7 +28,6 @@ # A header for a tar file class Gem::Package::TarHeader - ## # Fields in the tar header @@ -241,5 +240,4 @@ class Gem::Package::TarHeader def oct(num, len) "%0#{len}o" % num end - end diff --git a/lib/rubygems/package/tar_reader.rb b/lib/rubygems/package/tar_reader.rb index b7b5e01e99..e7c5620533 100644 --- a/lib/rubygems/package/tar_reader.rb +++ b/lib/rubygems/package/tar_reader.rb @@ -8,7 +8,6 @@ # TarReader reads tar files and allows iteration over their items class Gem::Package::TarReader - include Enumerable ## @@ -120,7 +119,6 @@ class Gem::Package::TarReader ensure rewind end - end require 'rubygems/package/tar_reader/entry' diff --git a/lib/rubygems/package/tar_reader/entry.rb b/lib/rubygems/package/tar_reader/entry.rb index d9c67ed8f2..5865599d3a 100644 --- a/lib/rubygems/package/tar_reader/entry.rb +++ b/lib/rubygems/package/tar_reader/entry.rb @@ -8,7 +8,6 @@ # Class for reading entries out of a tar file class Gem::Package::TarReader::Entry - ## # Header for this tar entry @@ -165,5 +164,4 @@ class Gem::Package::TarReader::Entry @io.pos = @orig_pos @read = 0 end - end diff --git a/lib/rubygems/package/tar_test_case.rb b/lib/rubygems/package/tar_test_case.rb index e4c408e416..5fc34d2e8c 100644 --- a/lib/rubygems/package/tar_test_case.rb +++ b/lib/rubygems/package/tar_test_case.rb @@ -6,7 +6,6 @@ require 'rubygems/package' # A test case for Gem::Package::Tar* classes class Gem::Package::TarTestCase < Gem::TestCase - def ASCIIZ(str, length) str + "\0" * (length - str.length) end @@ -137,5 +136,4 @@ class Gem::Package::TarTestCase < Gem::TestCase def util_symlink_entry util_entry tar_symlink_header("foo", "bar", 0, Time.now, "link") end - end diff --git a/lib/rubygems/package/tar_writer.rb b/lib/rubygems/package/tar_writer.rb index ed2577346d..877cc167c9 100644 --- a/lib/rubygems/package/tar_writer.rb +++ b/lib/rubygems/package/tar_writer.rb @@ -8,14 +8,12 @@ # Allows writing of tar files class Gem::Package::TarWriter - class FileOverflow < StandardError; end ## # IO wrapper that allows writing a limited amount of data class BoundedStream - ## # Maximum number of bytes that can be written @@ -47,14 +45,12 @@ class Gem::Package::TarWriter @written += data.bytesize data.bytesize end - end ## # IO wrapper that provides only #write class RestrictedStream - ## # Creates a new RestrictedStream wrapping +io+ @@ -68,7 +64,6 @@ class Gem::Package::TarWriter def write(data) @io.write data end - end ## @@ -330,5 +325,4 @@ class Gem::Package::TarWriter return name, prefix end - end |