CMake: Add LLVM 22 to supported QDoc Clang versions


QDoc builds against libclang for C++ parsing, and the build system
gates which Clang versions it accepts. LLVM 22 isn't in the list yet,
preventing builds against the latest release.

Adding LLVM 22.1 to the supported versions list enables building QDoc
with the latest Clang toolchain. The accompanying compatibility changes
ensure stable documentation output across LLVM 21 and 22.

This isn't picked back to earlier branches. LLVM 22 produces more
accurate type spellings and template parameter names, which changes
documentation output. The companion SFINAE rendering feature is also
new to 6.12. Picking back would introduce output churn without the
full feature set to justify it.

[ChangeLog][QDoc] QDoc now supports Clang from LLVM 22.

Fixes: QTBUG-144620
Change-Id: I168dd3ecea5d30246b4a99b764779981a881b5ff
Reviewed-by: Topi Reinio <topi.reinio@qt.io>
commit0b831cc7e1d9d78a70e61034adaa5f89520bca6a
parentf75f4090ed8e5c9dc898a313a5dd9b6878c2f034
authorPaul Wicking <paul.wicking@qt.io>
committerPaul Wicking <paul.wicking@qt.io>
commit timeFri, 20 Mar 2026 15:47:15 +0100