On Thu, 30 Apr 2020, Jakub Jelinek via Gcc-patches wrote: > Hi! > > If there are _Atomic side-effects in the parameter declarations > of non-nested function, when they are parsed, current_function_decl is > NULL, the create_artificial_label created labels during build_atomic* are > then adjusted by store_parm_decls through set_labels_context_r callback. > Unfortunately, if such thing happens in nested function parameter > declarations, while those decls are parsed current_function_decl is the > parent function (and am not sure it is a good idea to temporarily clear it, > some code perhaps should be aware it is in a nested function, or it can > refer to variables from the parent function etc.) and that means > store_param_decls through set_labels_context_r doesn't adjust anything. > As those labels are emitted in the nested function body rather than in the > parent, I think it is ok to override the context in those cases. > > Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?
OK. -- Joseph S. Myers jos...@codesourcery.com