Misc warning fixes

This commit is contained in:
Behdad Esfahbod 2018-02-10 15:52:35 -06:00
parent 7039803b51
commit 6c1848b1e3
3 changed files with 9 additions and 9 deletions

View File

@ -116,7 +116,7 @@ free_up_free (fixture_t *fixture)
static uintptr_t
get_pagesize (void)
{
uintptr_t pagesize = -1;
uintptr_t pagesize = (uintptr_t) -1;
#if defined(HAVE_SYSCONF) && defined(_SC_PAGE_SIZE)
pagesize = (uintptr_t) sysconf (_SC_PAGE_SIZE);

View File

@ -764,15 +764,15 @@ typedef struct {
/* note: we skip the first and last item from utf32 when adding to buffer */
static const utf32_conversion_test_t utf32_conversion_tests[] = {
{{0x41, 0x004D, 0x0430, 0x4E8C, 0xD800, 0xDF02, 0x61} , {0x004D, 0x0430, 0x4E8C, -3, -3}},
{{0x41, 0x004D, 0x0430, 0x4E8C, 0xD800, 0xDF02, 0x61} , {0x004D, 0x0430, 0x4E8C, (hb_codepoint_t) -3, (hb_codepoint_t) -3}},
{{0x41, 0x004D, 0x0430, 0x4E8C, 0x10302, 0x61} , {0x004D, 0x0430, 0x4E8C, 0x10302}},
{{0x41, 0xD800, 0xDF02, 0x61}, {-3, -3}},
{{0x41, 0xD800, 0xDF02}, {-3}},
{{0x41, 0x61, 0xD800, 0xDF02}, {0x61, -3}},
{{0x41, 0xD800, 0x61, 0xDF02}, {-3, 0x61}},
{{0x41, 0xDF00, 0x61}, {-3}},
{{0x41, 0xD800, 0xDF02, 0x61}, {(hb_codepoint_t) -3, (hb_codepoint_t) -3}},
{{0x41, 0xD800, 0xDF02}, {(hb_codepoint_t) -3}},
{{0x41, 0x61, 0xD800, 0xDF02}, {0x61, (hb_codepoint_t) -3}},
{{0x41, 0xD800, 0x61, 0xDF02}, {(hb_codepoint_t) -3, 0x61}},
{{0x41, 0xDF00, 0x61}, {(hb_codepoint_t) -3}},
{{0x41, 0x10FFFF, 0x61}, {0x10FFFF}},
{{0x41, 0x110000, 0x61}, {-3}},
{{0x41, 0x110000, 0x61}, {(hb_codepoint_t) -3}},
{{0x41, 0x61}, {0}}
};

View File

@ -37,7 +37,7 @@ static void
test_simple_tags (const char *s, hb_script_t script)
{
hb_script_t tag;
hb_script_t t1, t2;
hb_tag_t t1, t2;
g_test_message ("Testing script %c%c%c%c: tag %s", HB_UNTAG (hb_script_to_iso15924_tag (script)), s);
tag = hb_tag_from_string (s, -1);