class SyntaxTree::HashKeyFormatter::Identity
When
formatting a single assoc node without the context of the parent hash, this formatter is used. It uses whatever is present in the node, because there is nothing to be consistent with.
Public Instance Methods
format_key(q, key)
click to toggle source
# File lib/syntax_tree/node.rb, line 1776 def format_key(q, key) if key.is_a?(Label) q.format(key) else q.format(key) q.text(" =>") end end