method

infix_value_with_paren

Importance_0
Ruby on Rails latest stable (v7.1.3.2) - 0 notes - Class: ToSql
infix_value_with_paren(o, collector, value, suppress_parens = false) private

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activerecord/lib/arel/visitors/to_sql.rb, line 965
        def infix_value_with_paren(o, collector, value, suppress_parens = false)
          collector << "( " unless suppress_parens
          collector = if o.left.class == o.class
            infix_value_with_paren(o.left, collector, value, true)
          else
            visit o.left, collector
          end
          collector << value
          collector = if o.right.class == o.class
            infix_value_with_paren(o.right, collector, value, true)
          else
            visit o.right, collector
          end
          collector << " )" unless suppress_parens
          collector
        end
Register or log in to add new notes.