Lots of warnings building?

I’m building Swift 5.8 on Linux, which builds LLVM as a sub project. I see a ton of warnings like this:

[243/4806][  5%][568.705s] Building CXX object utils/TableGen/GlobalISel/CMakeFiles/LLVMTableGenGlobalISel.dir/CodeExpander.cpp.o
In file included from /home/rmann/SwiftProject/llvm-project/llvm/utils/TableGen/GlobalISel/CodeExpander.cpp:13:
In file included from /home/rmann/SwiftProject/llvm-project/llvm/utils/TableGen/GlobalISel/CodeExpander.h:16:
In file included from /home/rmann/SwiftProject/llvm-project/llvm/include/llvm/ADT/ArrayRef.h:15:
/home/rmann/SwiftProject/llvm-project/llvm/include/llvm/ADT/STLExtras.h:2202:1: warning: 'tuple_size' defined as a struct template here but previously declared as a class template [-Wmismatched-tags]
struct tuple_size<llvm::detail::result_pair<R>>
^
/usr/bin/../lib/gcc/aarch64-linux-gnu/7.5.0/../../../../include/c++/7.5.0/array:342:5: note: did you mean struct here?
    class tuple_size;
    ^
In file included from /home/rmann/SwiftProject/llvm-project/llvm/utils/TableGen/GlobalISel/CodeExpander.cpp:13:
In file included from /home/rmann/SwiftProject/llvm-project/llvm/utils/TableGen/GlobalISel/CodeExpander.h:16:
In file included from /home/rmann/SwiftProject/llvm-project/llvm/include/llvm/ADT/ArrayRef.h:15:
/home/rmann/SwiftProject/llvm-project/llvm/include/llvm/ADT/STLExtras.h:2206:1: warning: 'tuple_element' defined as a struct template here but previously declared as a class template [-Wmismatched-tags]
struct tuple_element<i, llvm::detail::result_pair<R>>
^
/usr/bin/../lib/gcc/aarch64-linux-gnu/7.5.0/../../../../include/c++/7.5.0/array:351:5: note: did you mean struct here?
    class tuple_element;
    ^
2 warnings generated.

I believe this is with a fairly recent LLVM, although I’m not sure precisely what commit. In any case, this seems sloppy, at best. Is this the kind of thing a PR would be welcome for?

If it hasn’t already been fixed, then I’m sure it would a fix would be appreciated, although an alternative option might be to try to find out which commit caused the issue and flag it up with the author.

⚙ D131486 [llvm][ADT] Allow using structured bindings with `llvm::enumerate` introduced this code.

Looking into this further, the patch is correct to make it a struct, that’s what the standard says it is, this was just a libstdc++ bug fixed in PR libstdc++/82716 avoid stupid -Wmismatched-tags warnings · gcc-mirror/gcc@30e0aed · GitHub.