aboutsummaryrefslogtreecommitdiff
path: root/src/asm
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2019-07-31 22:29:24 +0200
committerdec05eba <dec05eba@protonmail.com>2020-07-25 14:36:46 +0200
commit0f26e1d204d3a3026ca3edfc4c6bd9638b2632e7 (patch)
treede196ca25cf8f685e14b219198162d68c61efcfd /src/asm
parentfa2a9e79e21063137f863887adc88fc74d3573e2 (diff)
Add nullable, add bytecode documentation
Diffstat (limited to 'src/asm')
-rw-r--r--src/asm/x86_64.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/asm/x86_64.c b/src/asm/x86_64.c
index 2cbeead..16e6bc6 100644
--- a/src/asm/x86_64.c
+++ b/src/asm/x86_64.c
@@ -109,9 +109,11 @@ static CHECK_RESULT int asm_ensure_capacity(Asm *self, usize size) {
return 0;
}
+#ifdef DEBUG
static isize asm_get_capacity_left(Asm *self) {
return (isize)self->size - (isize)((u8*)self->code_it - (u8*)self->code);
}
+#endif
int asm_nop(Asm *self) {
return_if_error(asm_ensure_capacity(self, 1));