Alvaro Herrera <alvhe...@alvh.no-ip.org> writes: > Right ... the problem, as I understand, is that the syntax for > [[maybe_unused]] is different from what we can do with the current > pg_attribute_unused -- [[maybe_unused]] goes before the variable name. > We would need to define pg_attribute_unused macro (maybe have it take > the variable name and initializator value as arguments?), and also > define PG_USED_FOR_ASSERTS_ONLY in the same style.
I've thought all along that PG_USED_FOR_ASSERTS_ONLY was making unwarranted assumptions about what the underlying syntax would be, and it seems I was right. Anyone want to look into what it'd take to change this? (It might be an idea to introduce a new macro with a slightly different name, so we don't have to touch every usage site right away.) regards, tom lane