https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118513
--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Note, on the structured binding base VAR_DECL, DECL_INTERFACE_KNOWN has been set in #0 constrain_visibility (decl=<var_decl 0x7fffea2e02f8>, visibility=4, tmpl=false) at ../../gcc/cp/decl2.cc:2815 #1 0x00000000005962ad in determine_visibility (decl=<var_decl 0x7fffea2e02f8>) at ../../gcc/cp/decl2.cc:3068 #2 0x0000000000551b80 in cp_finish_decl (decl=<var_decl 0x7fffea2e02f8>, init=<target_expr 0x7fffea2eb150>, init_const_expr_p=true, asmspec_tree=<tree 0x0>, flags=5, decomp=0x7fffffffcdf0) at ../../gcc/cp/decl.cc:9107 Later on we copy_linkage from that base VAR_DECL to x and y VAR_DECLs, but that just copies DECL_VISIBILITY and the like, but doesn't actually set DECL_INTERFACE_KNOWN. Shall copy_linkage call constraint_visibility (or perhaps just for VISIBILITY_ANON)?