Files
grblHAL/regex.h
Terje Io 71dc5ac333 Changed safety door/parking handling to be compliant with legacy Grbl.
Added $384 setting for controlling G92 offset persistence.
Improved $help command output and handling.
Moved the optional tool table in non-volatile storage.
Added gcode parameter support and optional expression support.
2021-09-29 10:22:47 +02:00

23 lines
720 B
C

// regex.h - A Regular Expression Matcher
//
// Code by Rob Pike, exegesis by Brian Kernighan
//
// http://genius.cat-v.org/brian-kernighan/articles/beautiful
//
// c matches any literal character c
// . matches any single character
// ^ matches the beginning of the input string
// $ matches the end of the input string
// * matches zero or more occurrences of the previous character
#pragma once
/* match: search for regexp anywhere in text */
int match(char *regexp, char *text);
/* matchhere: search for regexp at beginning of text */
int matchhere(char *regexp, char *text);
/* matchstar: search for c*regexp at beginning of text */
int matchstar(int c, char *regexp, char *text);