4 ms·
It does fit into that dictum, or at least grep does. Your file is still a stream of bytes. Rather than providing a regular expression, though, you create a cont
by jff 15y ago
It does fit into that dictum, or at least grep does. Your file is still a stream of bytes. Rather than providing a regular expression, though, you create a context-free grammar to specify the structure of different things, presumably even multi-line structures. Grep then parses the file, making it less "grep" and more "the first stage of a compiler". Seems like a neat idea, but I probably wouldn't find myself using it too much--and if you think vendors are going to provide context-free grammars (that actually work!), well, you're a more optimistic man than I.