Skip to content

Commit be48edf

Browse files
[PATH] Allow gcc_jit_type_get_size to work with pointers
gcc/jit/ChangeLog: * libgccjit.cc (gcc_jit_type_get_size): Add pointer support
1 parent 78dc50f commit be48edf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

gcc/jit/libgccjit.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -575,8 +575,8 @@ gcc_jit_type_get_size (gcc_jit_type *type)
575575
{
576576
RETURN_VAL_IF_FAIL (type, -1, NULL, NULL, "NULL type");
577577
RETURN_VAL_IF_FAIL
578-
(type->is_int () || type->is_float (), -1, NULL, NULL,
579-
"only getting the size of integer or floating-point types is supported for now");
578+
(type->is_int () || type->is_float () || type->is_pointer (), -1, NULL, NULL,
579+
"only getting the size of integer or floating-point or pointer types is supported for now");
580580
return type->get_size ();
581581
}
582582

0 commit comments

Comments
 (0)