diff options
author | Paul Wicking <paul.wicking@qt.io> | 2023-04-23 11:40:45 +0200 |
---|---|---|
committer | Paul Wicking <paul.wicking@qt.io> | 2023-04-28 11:03:56 +0200 |
commit | d52ced27496fe495376ddd817dd2d1475870588d (patch) | |
tree | 043f12cfda6e502fd1e32a8e977fc26edf6db61e /examples/linguist/hellotr/main.cpp | |
parent | acae7fc8f30a4a1eabe6a8439e6f8143b4458847 (diff) | |
download | qttools-d52ced27496fe495376ddd817dd2d1475870588d.tar.gz |
QDoc: Extract DocParser::insertKeyword from insertTarget
Recent refactoring of `DocParser::insertTarget` exposed that the method
is responsible for the handling of two separate concepts in QDoc, the
commands `\target` and `\keyword`, respectively. Handling of the latter
command was added to the method in question by extending it's signature
with a boolean parameter, whose value was significant in deciding which
code path to follow. However, this API design is no longer considered
appropriate for QDoc, as discussed in review of the previous
refactoring.
This patch extracts the code responsible for inserting keywords into
their related data structure from `DocParser::insertTarget`, and adds
this code to a new member method, `DocParser::insertKeyword`. The
signature of the former method is updated and the relevant call sites
are updated to call the correct method.
The new method is documented as part of its introduction to the code
base. Given that the two methods have striking similarities,
documentation is added to `DocParser::insertTarget` in its new form.
Fixes: QTBUG-113126
Change-Id: Id29bc655c15b6e12726100eb1f33adbf97487236
Reviewed-by: Topi Reiniƶ <topi.reinio@qt.io>
Diffstat (limited to 'examples/linguist/hellotr/main.cpp')
0 files changed, 0 insertions, 0 deletions