~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/sql_lex.cc

  • Committer: Olaf van der Spek
  • Date: 2011-06-22 21:57:14 UTC
  • mto: This revision was merged to the branch mainline in revision 2348.
  • Revision ID: olafvdspek@gmail.com-20110622215714-0wmhwrx6of27etov
Refactor

Show diffs side-by-side

added added

removed removed

Lines of Context:
47
47
/* Stay outside of the namespace because otherwise bison goes nuts */
48
48
int base_sql_lex(ParserType *arg, drizzled::Session *yysession);
49
49
 
50
 
namespace drizzled
51
 
{
 
50
namespace drizzled {
52
51
 
53
52
static int lex_one_token(ParserType *arg, drizzled::Session *yysession);
54
53
 
57
56
*/
58
57
static void add_to_list(Session *session, SQL_LIST &list, Item *item, bool asc)
59
58
{
60
 
  Order* order = (Order *) session->mem.alloc(sizeof(Order));
 
59
  Order* order = new (session->mem) Order;
61
60
  order->item_ptr= item;
62
61
  order->item= &order->item_ptr;
63
62
  order->asc = asc;