QDoc: Viva \concept!


QDoc doesn't have a dedicated way for authors to document their C++20
concepts. It's possible through the use of the \page command or a
collection of QDoc macros, but that leaves the responsibility for
linking correctly and maintaining coherence entirely on the author,
without any tool support.

QDoc now treats \concept as a topic command equivalent in shape to
\module and \group. A \concept block declares a documentation page,
backed by a CollectionNode tagged as NodeType::Concept. This avoids
adding a dedicated node subclass while allowing the reuse of the
collection-page scaffolding already used by the module and group
commands. The page takes the concept's name as its title unless the
author supplies a \title, so a documented concept always renders with a
heading. This machinery serializes the node through .index files, so
concepts cross module boundaries via the existing dependency-index path.

This change is the first in a series. Subsequent commits attach
Clang-driven extraction and reverse-indexing, and route the page through
the generator pipelines.

Task-number: QTBUG-145046
Pick-to: 6.12
Change-Id: I64308f7e6d85ef4e1b15c108ae414938b9d5e396
Reviewed-by: Topi Reinio <topi.reinio@qt.io>
commitf8c4cfc76c262e256f6e793ff9300bf5153e04f7
parent261fbc642c76b3834f07ed2ba611f4403ec33643
authorPaul Wicking <paul.wicking@qt.io>
committerPaul Wicking <paul.wicking@qt.io>
commit timeThu, 4 Jun 2026 17:43:28 +0000