void Item_args::set_arguments(THD *thd, List<Item> &list)
{
  arg_count= list.elements;
  if (arg_count <= 2)
  {
    args= tmp_arg;
  }
  else if (!(args= (Item**) thd->alloc(sizeof(Item*) * arg_count)))
  {
    arg_count= 0;
    return;
  }
  uint i= 0;
  List_iterator_fast<Item> li(list);
  Item *item;
  while ((item= li++))
    args[i++]= item;
}
void Item_args::set_arguments(THD *thd, List<Item> &list)
{
  arg_count= list.elements;
  if (arg_count <= 2)
  {
    args= tmp_arg;
  }
  else if (!(args= (Item**) thd->alloc(sizeof(Item*) * arg_count)))
  {
    arg_count= 0;
    return;
  }
  uint i= 0;
  List_iterator_fast<Item> li(list);
  Item *item;
  while ((item= li++))
    args[i++]= item;
}