This was phrased as `{{0}}` to avoid a compiler warning on CentOS 7 about the
LHS being a nested struct. However it turns out this is a false positive in
older versions of GCC, and this form of zero initialization should be valid for
any aggregate in C99. Accordingly _newer_ versions of GCC warn if you use this
double braced phrasing. This change switches to the more standard C99
initialization, squashing warnings on newer platforms at the expense of
reintroducing some warnings on CentOS 7.
if (t->hi.y > t->lo.y + C_EPS && FP_EQUAL(seg[t->lseg].v0.x, seg[t->lseg].v1.x) &&
FP_EQUAL(seg[t->rseg].v0.x, seg[t->rseg].v1.x)) {
- boxf newbox = {{0}};
+ boxf newbox = {0};
if (flip) {
newbox.LL.x = t->lo.y;
newbox.LL.y = -seg[t->rseg].v0.x;
boxes_t rs = {0};
for (size_t i = 0; i < vert_decomp.size; ++i)
for (size_t j = 0; j < hor_decomp.size; ++j) {
- boxf newbox = {{0}};
+ boxf newbox = {0};
if (rectIntersect(&newbox, &vert_decomp.data[i], &hor_decomp.data[j]))
boxes_append(&rs, newbox);
}