vector.c
10 KB
-
tests: fix warning for implicit conversion of integer to pointer · dbb4a586
GCC warns by default when implicitly converting integers to pointers or the other way round, and commit fa48d2ea (vector: do not malloc 0-length vectors on dup, 2018-09-26) introduced such an implicit conversion into our vector tests. While this is totally fine in this test, as the pointer's value is never being used in the first place, we can trivially avoid the warning by instead just inserting a pointer for a variable allocated on the stack into the vector.
Patrick Steinhardt committed