The name 'getOwningModuleForLinkage' is a little confusing, now that the standard defines the term 'attachment' to mean the same thing. Renames the function to match the latter.
Note, the ModuleInternalLinkage concept will go away (and hence the defaulted argument) once p1815 is implemented. This is already noted in the body of the function.
This is based on top of the new mangling patch, but I could rebase it before if that's prefered.
clang-format: please reformat the code