~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to sql/sql_lex.h

Merging from trunk r102

Show diffs side-by-side

added added

removed removed

Lines of Context:
23
23
class Table_ident;
24
24
class sql_exchange;
25
25
class LEX_COLUMN;
26
 
class st_alter_tablespace;
27
26
 
28
27
#ifdef MYSQL_SERVER
29
28
/*
36
35
#ifdef MYSQL_YACC
37
36
#define LEX_YYSTYPE void *
38
37
#else
39
 
#if MYSQL_LEX
 
38
#if defined(MYSQL_LEX)
40
39
#include "lex_symbol.h"
41
40
#include "sql_yacc.h"
42
41
#define LEX_YYSTYPE YYSTYPE *
83
82
  SQLCOM_SHOW_BINLOG_EVENTS,
84
83
  SQLCOM_SHOW_WARNS, SQLCOM_EMPTY_QUERY, SQLCOM_SHOW_ERRORS,
85
84
  SQLCOM_CHECKSUM,
86
 
  SQLCOM_ALTER_TABLESPACE,
87
85
  SQLCOM_BINLOG_BASE64_EVENT,
88
86
  SQLCOM_SHOW_PLUGINS,
89
87
  SQLCOM_ALTER_DB_UPGRADE,
366
364
  }
367
365
  static void *operator new(size_t size, MEM_ROOT *mem_root)
368
366
  { return (void*) alloc_root(mem_root, (uint) size); }
369
 
  static void operator delete(void *ptr,size_t size) { TRASH(ptr, size); }
370
 
  static void operator delete(void *ptr, MEM_ROOT *mem_root) {}
 
367
  static void operator delete(void *ptr __attribute__((__unused__)),
 
368
                              size_t size __attribute__((__unused__)))
 
369
  { TRASH(ptr, size); }
 
370
  static void operator delete(void *ptr __attribute__((__unused__)),
 
371
                              MEM_ROOT *mem_root __attribute__((__unused__)))
 
372
  {}
371
373
  st_select_lex_node(): linkage(UNSPECIFIED_TYPE) {}
372
374
  virtual ~st_select_lex_node() {}
373
375
  inline st_select_lex_node* get_master() { return master; }
390
392
  virtual List<Item>* get_item_list();
391
393
  virtual ulong get_table_join_options();
392
394
  virtual TABLE_LIST *add_table_to_list(THD *thd, Table_ident *table,
393
 
                                        LEX_STRING *alias,
394
 
                                        ulong table_options,
395
 
                                        thr_lock_type flags= TL_UNLOCK,
396
 
                                        List<Index_hint> *hints= 0,
 
395
                                        LEX_STRING *alias,
 
396
                                        ulong table_options,
 
397
                                        thr_lock_type flags= TL_UNLOCK,
 
398
                                        List<Index_hint> *hints= 0,
397
399
                                        LEX_STRING *option= 0);
398
 
  virtual void set_lock_for_tables(thr_lock_type lock_type) {}
 
400
  virtual void set_lock_for_tables(thr_lock_type lock_type __attribute__((__unused__)))
 
401
  {}
399
402
 
400
403
  friend class st_select_lex_unit;
401
404
  friend bool mysql_new_select(struct st_lex *lex, bool move_down);
1504
1507
 
1505
1508
  uint profile_query_id;
1506
1509
  uint profile_options;
1507
 
  enum ha_storage_media storage_type;
1508
1510
  enum column_format_type column_format;
1509
1511
  uint which_columns;
1510
1512
  enum Foreign_key::fk_match_opt fk_match_option;
1561
1563
    (see Item_field::fix_fields()). 
1562
1564
  */
1563
1565
  bool use_only_table_context;
1564
 
 
1565
 
  /*
1566
 
    Reference to a struct that contains information in various commands
1567
 
    to add/create/drop/change table spaces.
1568
 
  */
1569
 
  st_alter_tablespace *alter_tablespace_info;
1570
1566
  
1571
1567
  bool escape_used;
1572
1568
  bool is_lex_started; /* If lex_start() did run. For debugging. */
1677
1673
  {
1678
1674
    return (void*) alloc_root(mem_root, (uint) size);
1679
1675
  }
1680
 
  static void operator delete(void *ptr,size_t size)
 
1676
  static void operator delete(void *ptr __attribute__((__unused__)),
 
1677
                              size_t size __attribute__((__unused__)))
1681
1678
  { TRASH(ptr, size); }
1682
 
  static void operator delete(void *ptr, MEM_ROOT *mem_root)
 
1679
  static void operator delete(void *ptr __attribute__((__unused__)),
 
1680
                              MEM_ROOT *mem_root __attribute__((__unused__)))
1683
1681
  { /* Never called */ }
1684
1682
};
1685
1683