diff options
author | David RodrÃguez <deivid.rodriguez@riseup.net> | 2020-07-13 12:01:07 +0200 |
---|---|---|
committer | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2020-07-31 21:07:19 +0900 |
commit | a89665b7b1abb5bb6005fd638dc920848cc50f72 (patch) | |
tree | f6c84f1bfb1148d203cd63c72c458de3a8f5e961 /lib/rubygems/errors.rb | |
parent | a6bfc951aa9c48e2a4608a9ae84e2e3b4fd9b390 (diff) |
Enforce no empty lines around class body in rubygems
To normalize the code style with `bundler`.
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/3379
Diffstat (limited to 'lib/rubygems/errors.rb')
-rw-r--r-- | lib/rubygems/errors.rb | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/lib/rubygems/errors.rb b/lib/rubygems/errors.rb index 362a07865f..abee20651e 100644 --- a/lib/rubygems/errors.rb +++ b/lib/rubygems/errors.rb @@ -13,13 +13,11 @@ module Gem # already activated gems or that RubyGems is otherwise unable to activate. class LoadError < ::LoadError - # Name of gem attr_accessor :name # Version requirement of gem attr_accessor :requirement - end ## @@ -27,7 +25,6 @@ module Gem # system. Instead of rescuing from this class, make sure to rescue from the # superclass Gem::LoadError to catch all types of load errors. class MissingSpecError < Gem::LoadError - def initialize(name, requirement, extra_message=nil) @name = name @requirement = requirement @@ -45,7 +42,6 @@ module Gem total = Gem::Specification.stubs.size "Could not find '#{name}' (#{requirement}) among #{total} total gem(s)\n" end - end ## @@ -53,7 +49,6 @@ module Gem # not the requested version. Instead of rescuing from this class, make sure to # rescue from the superclass Gem::LoadError to catch all types of load errors. class MissingSpecVersionError < MissingSpecError - attr_reader :specs def initialize(name, requirement, specs) @@ -70,13 +65,11 @@ module Gem names = specs.map(&:full_name) "Could not find '#{name}' (#{requirement}) - did find: [#{names.join ','}]\n" end - end # Raised when there are conflicting gem specs loaded class ConflictError < LoadError - ## # A Hash mapping conflicting specifications to the dependencies that # caused the conflict @@ -101,7 +94,6 @@ module Gem super("Unable to activate #{target.full_name}, because #{reason}") end - end class ErrorReason; end @@ -113,7 +105,6 @@ module Gem # in figuring out why a gem couldn't be installed. # class PlatformMismatch < ErrorReason - ## # the name of the gem attr_reader :name @@ -151,7 +142,6 @@ module Gem @platforms.size == 1 ? '' : 's', @platforms.join(' ,')] end - end ## @@ -159,7 +149,6 @@ module Gem # data from a source class SourceFetchProblem < ErrorReason - ## # Creates a new SourceFetchProblem for the given +source+ and +error+. @@ -190,6 +179,5 @@ module Gem # The "exception" alias allows you to call raise on a SourceFetchProblem. alias exception error - end end |