styling C for readability and editability
here's how i write an else-if ladder
if (0) {
} else if (...) {
...
} else if (...) {
...
} else if (...) {
...
}
here's how i write an AND chain
(1 && ... && ... && ... )
here's an example snippet from Conversation's source
B32 is_prinicipal_frame = (1
&& R32_is_zero(part_projection->signed_distance_from_unprojected_origin_to_feature_plane)
&& geom3d_vector_has_unit_length(part_projection->normal)
&& R32_are_equal(1.0F, vec3_max(part_projection->normal))
);
if (0
|| (!part_projection->is_active)
|| (!is_prinicipal_frame)
) {
...
}