]> arthur.barton.de Git - netatalk.git/blob - etc/afpd/spotlight_rawquery_lexer.l
Add lots of mappings and dont ignore case stuff
[netatalk.git] / etc / afpd / spotlight_rawquery_lexer.l
1 %{
2 #include <string.h>
3 #include <stdbool.h>
4 #include <gio/gio.h>
5 #include <atalk/talloc.h>
6 #include "spotlight.h"
7 #include "spotlight_rawquery_parser.h"
8 %}
9
10 %%
11 InRange                               return FUNC_INRANGE;
12 \$time\.iso                           return DATE_ISO;
13 false                                 {yylval.bval = false; return BOOL;}
14 true                                  {yylval.bval = true; return BOOL;}
15 [a-zA-Z0-9\*\:\-\.]+                  {yylval.sval = talloc_strdup(ssp_slq, yytext); return WORD;}
16 \"                                    return QUOTE;
17 \(                                    return OBRACE;
18 \)                                    return CBRACE;
19 \&\&                                  return AND;
20 \|\|                                  return OR;
21 \=\=                                  return EQUAL;
22 \!\=                                  return UNEQUAL;
23 \<                                    return LT;
24 \>                                    return GT;
25 \,                                    return COMMA;
26 [ \t\n]                               /* ignore */
27 %%