Move DAAP query hash table inside DAAP2SQL

This commit is contained in:
Julien BLACHE 2011-04-01 19:45:40 +02:00
parent 303a3329eb
commit b8758a2aa2
3 changed files with 12 additions and 14 deletions

View File

@ -27,6 +27,7 @@ options {
@header { @header {
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>
#include <string.h>
#include <limits.h> #include <limits.h>
#include <errno.h> #include <errno.h>
@ -35,6 +36,17 @@ options {
#include "daap_query.h" #include "daap_query.h"
} }
@members {
struct dmap_query_field_map {
char *dmap_field;
char *db_col;
int as_int;
};
/* gperf static hash, daap_query.gperf */
#include "daap_query_hash.c"
}
query returns [ pANTLR3_STRING result ] query returns [ pANTLR3_STRING result ]
: e = expr : e = expr
{ {

View File

@ -34,10 +34,6 @@
#include "DAAP2SQL.h" #include "DAAP2SQL.h"
/* gperf static hash, daap_query.gperf */
#include "daap_query_hash.c"
char * char *
daap_query_parse_sql(const char *daap_query) daap_query_parse_sql(const char *daap_query)
{ {

View File

@ -5,16 +5,6 @@
#include "logger.h" #include "logger.h"
#include "misc.h" #include "misc.h"
struct dmap_query_field_map {
char *dmap_field;
char *db_col;
int as_int;
};
/* Generated by gperf - keep in sync, don't alter */
const struct dmap_query_field_map *
daap_query_field_lookup (register const char *str, register unsigned int len);
char * char *
daap_query_parse_sql(const char *daap_query); daap_query_parse_sql(const char *daap_query);