lib/ruby-conf.rb in ruby-conf-2.6.0 vs lib/ruby-conf.rb in ruby-conf-2.6.1

- old
+ new

@@ -186,12 +186,11 @@ "[UNRESOLVED]" end str += " " * depth str += "#{key}:" - str += value.is_a?(Config) ? value.__rc_build_string(depth+1) : " #{value}\n" -# str += "\n" unless depth > 0 + str += value.is_a?(Config) ? (value == self ? " [SELF]\n" : value.__rc_build_string(depth+1)) : " #{value}\n" end str end def __rc_build_inspect() istr = "" @@ -202,10 +201,10 @@ self[key] rescue => e "[UNRESOLVED:#{e}]" end str += "#{key}: " - str += value.is_a?(Config) ? "{ #{value.__rc_build_inspect} }" : value.inspect + str += value.is_a?(Config) ? (value == self ? "[SELF]" : "{ #{value.__rc_build_inspect} }") : value.inspect str }.join(", ") istr end