mirror of
https://github.com/janet-lang/janet
synced 2025-01-01 11:20:27 +00:00
Fix MSVC compiler warnings.
This commit is contained in:
parent
00a47dc0cb
commit
df550efb6b
@ -38,7 +38,7 @@ static void test_valid_str(const char *str) {
|
||||
double cnum, jnum;
|
||||
jnum = 0.0;
|
||||
cnum = atof(str);
|
||||
err = janet_scan_number((const uint8_t *) str, strlen(str), &jnum);
|
||||
err = janet_scan_number((const uint8_t *) str, (int32_t) strlen(str), &jnum);
|
||||
assert(!err);
|
||||
assert(cnum == jnum);
|
||||
}
|
||||
|
@ -629,7 +629,7 @@ void janet_buffer_format(
|
||||
}
|
||||
case 's': {
|
||||
const uint8_t *s = janet_getstring(argv, arg);
|
||||
size_t l = janet_string_length(s);
|
||||
int32_t l = janet_string_length(s);
|
||||
if (form[2] == '\0')
|
||||
janet_buffer_push_bytes(b, s, l);
|
||||
else {
|
||||
|
@ -190,7 +190,7 @@ const uint8_t *janet_symbol(const uint8_t *str, int32_t len) {
|
||||
|
||||
/* Get a symbol from a cstring */
|
||||
const uint8_t *janet_csymbol(const char *cstr) {
|
||||
return janet_symbol((const uint8_t *)cstr, strlen(cstr));
|
||||
return janet_symbol((const uint8_t *)cstr, (int32_t) strlen(cstr));
|
||||
}
|
||||
|
||||
/* Store counter for genysm to avoid quadratic behavior */
|
||||
|
Loading…
Reference in New Issue
Block a user