aboutsummaryrefslogtreecommitdiff
path: root/compiler.c
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2020-09-16 20:38:58 -0700
committerBruce Hill <bruce@bruce-hill.com>2020-09-16 20:38:58 -0700
commitf35d3c98b22ac3c708672493d27267de071989cd (patch)
tree6f49833558ec448768f5c90193d35b7d40c81664 /compiler.c
parent6c237850e90dce317ede7b0d4e53125df15ab62b (diff)
Added tons of file and line number stuff
Diffstat (limited to 'compiler.c')
-rw-r--r--compiler.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/compiler.c b/compiler.c
index fe7ad3f..99ff44f 100644
--- a/compiler.c
+++ b/compiler.c
@@ -252,6 +252,10 @@ vm_op_t *bpeg_simplepattern(file_t *f, const char *str)
}
// Capture
case '@': {
+ if (matchchar(&str, '@')) { // @@ -> current position
+ op->op = VM_POSITION;
+ break;
+ }
op->op = VM_CAPTURE;
str = after_spaces(str);
if (matchchar(&str, '[')) {