aboutsummaryrefslogtreecommitdiff
path: root/asm/parser.c
diff options
context:
space:
mode:
authorAryadev Chavali <aryadev@aryadevchavali.com>2023-11-03 21:22:02 +0000
committerAryadev Chavali <aryadev@aryadevchavali.com>2023-11-03 21:22:02 +0000
commit3fde04e1d2e0fba7a81718f3a7695d19920291b9 (patch)
tree920723eba34552d847936ced0ec69c3f2f6f0f3b /asm/parser.c
parent96a83db92b7f81a6fd4701f7b8779494283dd819 (diff)
downloadovm-3fde04e1d2e0fba7a81718f3a7695d19920291b9.tar.gz
ovm-3fde04e1d2e0fba7a81718f3a7695d19920291b9.tar.bz2
ovm-3fde04e1d2e0fba7a81718f3a7695d19920291b9.zip
Fixed bug where labels were off by one
Was used in a previous fix but not necessary anymore
Diffstat (limited to 'asm/parser.c')
-rw-r--r--asm/parser.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/asm/parser.c b/asm/parser.c
index 4eff0a5..4667eaf 100644
--- a/asm/parser.c
+++ b/asm/parser.c
@@ -524,7 +524,7 @@ perr_t process_presults(presult_t *results, size_t res_count,
case PRES_LABEL: {
label_t label = {.name = res.label,
.name_size = strlen(res.label),
- .addr = inst_count + 1};
+ .addr = inst_count};
darr_append_bytes(&label_registry, (byte *)&label, sizeof(label));
break;
}