summaryrefslogtreecommitdiff
path: root/src/qdoc/cppcodeparser.cpp
diff options
context:
space:
mode:
authorTopi Reinio <topi.reinio@qt.io>2023-03-23 15:54:16 +0000
committerTopi Reinio <topi.reinio@qt.io>2023-03-24 10:19:12 +0000
commit65e94d012b7d38669e9cdc4e885bdc34a86607af (patch)
tree25c1eb8471f12210abf84607a226a40fae08430e /src/qdoc/cppcodeparser.cpp
parent9b4f32d9abc657fcf9d42587e40ff85d7125cfc7 (diff)
downloadqttools-65e94d012b7d38669e9cdc4e885bdc34a86607af.tar.gz
qdoc: Warn about documented global functions that generate no docs
Generator::generateDocumentation() recursively traverses the tree of PageNode objects, i.e. nodes that generate output. However, it did not check if there are documented nodes in the global scope (root namespace) that generate no output. A typical case where this happens is global functions, where the author forgot to associate the function to something using the \relates command. Make QDoc print out a warning for these nodes, and mark them to have 'DontDocument' status so they will be ignored later on for linking and inclusion in the .qhp file. Also in Generator::generateDocumentation(), rename a variable local to a for-loop from 'node' to 'child', to prevent shadowing a 'node' in the outer scope. Pick-to: 6.5 Fixes: QTBUG-112256 Change-Id: I74fcc704f6848fc1eef8529da80f57678a83766e Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Diffstat (limited to 'src/qdoc/cppcodeparser.cpp')
0 files changed, 0 insertions, 0 deletions