aboutsummaryrefslogtreecommitdiff
path: root/pattern.h
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2024-05-28 02:05:57 -0400
committerBruce Hill <bruce@bruce-hill.com>2024-05-28 02:05:57 -0400
commit2ec9f76b7221938061d12e268e97bc33e5653a8e (patch)
tree478a13579034b8bf0a2a533f59ed526b6667573d /pattern.h
parentacdb6ff91b60dab1c65d92f2de35a553ebcb3301 (diff)
Rename 'Match' macro to avoid confusion
Diffstat (limited to 'pattern.h')
-rw-r--r--pattern.h4
1 files changed, 1 insertions, 3 deletions
diff --git a/pattern.h b/pattern.h
index 046a792..f9bfc6c 100644
--- a/pattern.h
+++ b/pattern.h
@@ -15,9 +15,7 @@
#endif
#define UNBOUNDED(pat) ((pat)->max_matchlen == -1)
-#define Match(x, _tag) ((x)->type == _tag ? &(x)->__tagged._tag : (errx(1, __FILE__ ":%d This was supposed to be a " # _tag "\n", __LINE__), &(x)->__tagged._tag))
-#define Pattern(_tag, _start, _end, _min, _max, ...) allocate_pat((pat_t){.type=_tag, .start=_start, .end=_end, \
- .min_matchlen=_min, .max_matchlen=_max, .__tagged._tag={__VA_ARGS__}})
+
// BP virtual machine pattern types
enum pattype_e {
BP_ERROR = 0,