Sha256: 56a1f3fdbb92e72856869c8ff82e046607d5f82b354fc489f90fa2778ded5ce9
Contents?: true
Size: 233 Bytes
Versions: 15
Compression:
Stored size: 233 Bytes
Contents
require "myrrha/to_ruby_literal" class Foo attr_reader :arg def initialize(arg) @arg = arg end def to_ruby_literal "Foo.new(#{arg.inspect})" end end Myrrha.to_ruby_literal(Foo.new(:hello)) # => "Foo.new(:hello)"
Version data entries
15 entries across 15 versions & 1 rubygems