~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/lex_string.h

  • Committer: Lee Bieber
  • Date: 2011-03-29 22:31:41 UTC
  • mfrom: (2257.1.3 build)
  • Revision ID: kalebral@gmail.com-20110329223141-yxc22h3l2he58sk0
Merge Andrew - 743842: Build failure using GCC 4.6
Merge Stewart - 738022: CachedDirectory silently fails to add entries if stat() fails
Merge Olaf - Common fwd: add copyright, add more declaration

Show diffs side-by-side

added added

removed removed

Lines of Context:
17
17
 *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
18
18
 */
19
19
 
20
 
#ifndef DRIZZLED_LEX_STRING_H
21
 
#define DRIZZLED_LEX_STRING_H
 
20
#pragma once
22
21
 
23
22
#include <stddef.h>
24
23
 
30
29
*/
31
30
 
32
31
/* This definition must match the one given in mysql/plugin.h */
33
 
typedef struct drizzle_lex_string
 
32
typedef struct lex_string_t
34
33
{
35
34
  char *str;
36
35
  size_t length;
37
36
} LEX_STRING;
38
37
 
39
 
struct execute_string_t : public drizzle_lex_string
 
38
inline const LEX_STRING &null_lex_string()
 
39
{
 
40
  static LEX_STRING tmp= { NULL, 0 };
 
41
  return tmp;
 
42
}
 
43
 
 
44
#define NULL_LEX_STRING null_lex_string()
 
45
 
 
46
struct execute_string_t : public lex_string_t
40
47
{
41
48
private:
42
49
  bool is_variable;
47
54
    return is_variable;
48
55
  }
49
56
 
50
 
  void set(const drizzle_lex_string& ptr, bool is_variable_arg= false)
 
57
  void set(const lex_string_t& ptr, bool is_variable_arg= false)
51
58
  {
52
59
    is_variable= is_variable_arg;
53
60
    str= ptr.str;
62
69
 
63
70
} /* namespace drizzled */
64
71
 
65
 
#endif /* DRIZZLED_LEX_STRING_H */