git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH v2 0/2] grep: introduce and use grep_and_expr()

From
Taylor Blau <me@ttaylorr.com>
Date
Jan 6, 2022, 22:42 UTC
Message-ID
<cover.1641508884.git.me@ttaylorr.com>
In-Reply-To
<cover.1641498525.git.me@ttaylorr.com>

This small reroll fixes an issue in the second patch where a stack variable was left unused.

Taylor Blau (2):
  grep: extract grep_binexp() from grep_or_expr()
  grep: use grep_and_expr() in compile_pattern_and()
 grep.c | 24 ++++++++++++++++--------
 1 file changed, 16 insertions(+), 8 deletions(-)
Range-diff against v1:
-:  ---------- > 1:  dae476d1bd grep: extract grep_binexp() from grep_or_expr()
1:  71bd2d1bcc ! 2:  f637e02422 grep: use grep_and_expr() in compile_pattern_and()
    @@ grep.c: static struct grep_expr *grep_or_expr(struct grep_expr *left, struct gre
      static struct grep_expr *compile_pattern_or(struct grep_pat **);
      static struct grep_expr *compile_pattern_atom(struct grep_pat **list)
      {
    +@@ grep.c: static struct grep_expr *compile_pattern_not(struct grep_pat **list)
    + static struct grep_expr *compile_pattern_and(struct grep_pat **list)
    + {
    + 	struct grep_pat *p;
    +-	struct grep_expr *x, *y, *z;
    ++	struct grep_expr *x, *y;
    +
    + 	x = compile_pattern_not(list);
    + 	p = *list;
     @@ grep.c: static struct grep_expr *compile_pattern_and(struct grep_pat **list)
      		y = compile_pattern_and(list);
      		if (!y)
--
2.34.1.455.gd6eb6fd089
Previous: Taylor BlauNext: Taylor Blau
Message 8 of 13 in “grep: use grep_or_expr() in compile_pattern_or()”
  1. 1/2 grep: use grep_or_expr() in compile_pattern_or()René Scharfe, Jan 6, 2022
  2. 2/2 grep: use grep_not_expr() in compile_pattern_not()René Scharfe, Jan 6, 2022
  3. 0/2 grep: introduce and use grep_and_expr()Taylor Blau, Jan 6, 2022
  4. 1/2 grep: extract grep_binexp() from grep_or_expr()Taylor Blau, Jan 6, 2022
  5. 2/2 grep: use grep_and_expr() in compile_pattern_and()Taylor Blau, Jan 6, 2022
  6. Junio C HamanoJan 6, 2022
  7. Taylor BlauJan 6, 2022
  8. 0/2 grep: introduce and use grep_and_expr()Taylor Blau, Jan 6, 2022
  9. 1/2 grep: extract grep_binexp() from grep_or_expr()Taylor Blau, Jan 6, 2022
  10. 2/2 grep: use grep_and_expr() in compile_pattern_and()Taylor Blau, Jan 6, 2022
  11. René ScharfeJan 7, 2022
  12. Taylor BlauJan 7, 2022
  13. René ScharfeJan 7, 2022

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.