Turns out this is a confirmed bug in GCC. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=122712
The attached patch contains a justification with a quite from the standard:
[module.global.frag] p3.3 says "A declaration D is decl-reachable from a declaration S in the same translation unit if ... S contains a dependent call E ([temp.dep]) and D is found by any name lookup performed for an expression synthesized from E by replacing each type-dependent argument or operand with a value of a placeholder type with no associated namespaces or entities".