]>
git.ipfire.org Git - thirdparty/git.git/blob - grep.h
21 struct grep_pat
*next
;
24 enum grep_pat_token token
;
37 enum grep_expr_node node
;
40 struct grep_pat
*atom
;
41 struct grep_expr
*unary
;
43 struct grep_expr
*left
;
44 struct grep_expr
*right
;
50 struct grep_pat
*pattern_list
;
51 struct grep_pat
**pattern_tail
;
52 struct grep_expr
*pattern_expression
;
57 unsigned status_only
:1;
59 unsigned unmatch_name_only
:1;
61 unsigned word_regexp
:1;
64 #define GREP_BINARY_DEFAULT 0
65 #define GREP_BINARY_NOMATCH 1
66 #define GREP_BINARY_TEXT 2
73 unsigned post_context
;
76 extern void append_grep_pattern(struct grep_opt
*opt
, const char *pat
, const char *origin
, int no
, enum grep_pat_token t
);
77 extern void compile_grep_patterns(struct grep_opt
*opt
);
78 extern void free_grep_patterns(struct grep_opt
*opt
);
79 extern int grep_buffer(struct grep_opt
*opt
, const char *name
, char *buf
, unsigned long size
);