Sha256: ea79d7906e14dbef18ca52242d48adc4295f90e7aca613dbed2ebd732294e165

Contents?: true

Size: 353 Bytes

Versions: 4

Compression:

Stored size: 353 Bytes

Contents

class Symbol
  # Successor method for symobol. This simply converts
  # the symbol to a string uses String#succ and then
  # converts it back to a symbol.
  #
  #   require 'facet/symbol/succ'
  #
  #   :a.succ => :b
  #
  #--
  # In the future I would like this to work more like
  # a simple dial.
  #++
  def succ
    self.to_s.succ.intern
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
facets-0.6.3 lib/facet/symbol/succ.rb
facets-0.7.0 lib/facet/symbol/succ.rb
facets-0.7.1 lib/facet/symbol/succ.rb
facets-0.7.2 lib/facet/symbol/succ.rb