def expand_definition(definition)
      return definition if definition.is_a? Hash
      definition.each_with_object({}) do |key, result|
        if key.is_a? String
          result[key] = :default
        elsif key.is_a? Hash
          result.merge!(expand_sub_definitions(key))
        end
      end
    end
def expand_definition(definition)
      return definition if definition.is_a? Hash
      definition.each_with_object({}) do |key, result|
        if key.is_a? String
          result[key] = :default
        elsif key.is_a? Hash
          result.merge!(expand_sub_definitions(key))
        end
      end
    end
expands simple arrays into full hash definitions
 @api private
 @param definition [Array<String,Hash>]
 @return [Hash]