title: Can you rescue from specific errors with messages in ruby?
body: <p>I'm trying to understand how errors propogate between classes in Ruby. I have this so far:</p>
  
  <pre><code>class User
    def charge
      puts "charging order soon"
      raise RuntimeError.new("This is a runtime error")
    rescue ArgumentError
      puts "should never gets here"
    end
  end
  
  class Runner
    def run
      begin
        User.new.charge
      rescue RuntimeError =&gt; e
        puts e.message
      end
    end
  end
  
  Runner.new.run
  </code></pre>
  
  <p>When I run this, I get this which seems right:</p>
  
  <pre><code>$ ruby errors.rb
  charging order soon
  This is a runtime error
  </code></pre>
  
  <p>Inside runner, can I rescue from the <code>RuntimeError</code> with a specific message? If I have multiple <code>RuntimeErrors</code> being raised around my application, is there any way for the Runner's rescue clause to be raised only for RuntimeErrors with specific messages?</p>