Mercurial > pub > dyncall > dyncall
changeset 347:a2a42f477662
- C declaration order fix
author | Tassilo Philipp |
---|---|
date | Wed, 08 Jan 2020 17:10:17 +0100 |
parents | d3d6dbe3c2bc |
children | da4b267c10bf |
files | dyncall/dyncall_callvm_x64.c |
diffstat | 1 files changed, 4 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/dyncall/dyncall_callvm_x64.c Wed Jan 08 02:39:45 2020 +0100 +++ b/dyncall/dyncall_callvm_x64.c Wed Jan 08 17:10:17 2020 +0100 @@ -194,11 +194,13 @@ #include <assert.h> void dc_callvm_call_x64_syscall_sysv(DCCallVM* in_self, DCpointer target) { + DCCallVM_x64* self; + /* syscalls can have up to 6 args, required to be "Only values of class INTEGER or class MEMORY" (from */ - /* SysV manual), so we can use self->mRegData.i directly; verify this holds at least 6 values, though. */ + /* SysV manual), so we can use self->mRegData.i directly; verify this has space for at least 6 values, though. */ assert(numIntRegs >= 6); - DCCallVM_x64* self = (DCCallVM_x64*)in_self; + self = (DCCallVM_x64*)in_self; dcCall_x64_syscall_sysv(self->mRegData.i, target); }