diff options
author | Gavin Howard <gavin@yzena.com> | 2021-07-26 13:40:32 -0600 |
---|---|---|
committer | Gavin Howard <gavin@yzena.com> | 2021-07-26 13:43:11 -0600 |
commit | 43233b88c802596e3be13bbe5ee4a3350df178eb (patch) | |
tree | b3258b808069e866f65fef0b4281ecd737731ae7 /src | |
parent | 769e980b03f247d7c6ceadaa2eb9048cc9e91653 (diff) | |
download | platform_external_bc-43233b88c802596e3be13bbe5ee4a3350df178eb.tar.gz platform_external_bc-43233b88c802596e3be13bbe5ee4a3350df178eb.tar.bz2 platform_external_bc-43233b88c802596e3be13bbe5ee4a3350df178eb.zip |
Fix compiler warnings
Signed-off-by: Gavin Howard <gavin@yzena.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/bc_parse.c | 2 | ||||
-rw-r--r-- | src/program.c | 2 | ||||
-rw-r--r-- | src/vector.c | 1 |
3 files changed, 1 insertions, 4 deletions
diff --git a/src/bc_parse.c b/src/bc_parse.c index a2bd7324..d0635a3b 100644 --- a/src/bc_parse.c +++ b/src/bc_parse.c @@ -358,12 +358,10 @@ static void bc_parse_name(BcParse *p, BcInst *type, bool *can_assign, uint8_t flags) { char *name; - size_t len; BC_SIG_LOCK; // We want a copy of the name since the lexer might overwrite its copy. - len = p->l.str.len; name = bc_vm_strdup(p->l.str.v); BC_SETJMP_LOCKED(err); diff --git a/src/program.c b/src/program.c index 38255927..eb7e6b45 100644 --- a/src/program.c +++ b/src/program.c @@ -1048,7 +1048,7 @@ static void bc_program_logical(BcProgram *p, uchar inst) { /** * Assigns a string to a variable. * @param p The program. - * @param loc The location of the string. + * @param num The location of the string as a BcNum. * @param v The stack for the variable. * @param push Whether to push the string or not. To push means to move the * string from the results stack and push it onto the variable diff --git a/src/vector.c b/src/vector.c index 7b695d5e..1cd90f72 100644 --- a/src/vector.c +++ b/src/vector.c @@ -491,7 +491,6 @@ char* bc_slabvec_strdup(BcVec *v, const char *str) { size_t len; BcSlab slab; BcSlab *slab_ptr; - size_t alloc; BC_SIG_ASSERT_LOCKED; |