def ExpandExpression(stack):

  def IsEncrypted(tokens):
    for token in tokens:
      if util.IsEncrypted(token):
        return True
    return False

  if not IsEncrypted(stack):
    return [[[1.0, ToInfix(stack)]], 0.0]
  return _ExpandExpression(stack)
Convert stack into the form of factor * field + constant.
dataset/ETHPy150Open google/encrypted-bigquery-client/src/query_interpreter.py/ExpandExpression