Skip to content

Commit ae44501

Browse files
committed
[clang-doc] construct in place
1 parent bb95de4 commit ae44501

File tree

2 files changed

+3
-9
lines changed

2 files changed

+3
-9
lines changed

clang-tools-extra/clang-doc/HTMLGenerator.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -635,8 +635,8 @@ static std::unique_ptr<HTMLNode> genHTML(const CommentInfo &I) {
635635

636636
if (I.Kind == "BlockCommandComment") {
637637
auto BlockComment = std::make_unique<TagNode>(HTMLTag::TAG_DIV);
638-
auto Command = std::make_unique<TagNode>(HTMLTag::TAG_DIV, I.Name);
639-
BlockComment->Children.emplace_back(std::move(Command));
638+
BlockComment->Children.emplace_back(
639+
std::make_unique<TagNode>(HTMLTag::TAG_DIV, I.Name));
640640
for (const auto &Child : I.Children) {
641641
std::unique_ptr<HTMLNode> Node = genHTML(*Child);
642642
if (Node)

clang-tools-extra/unittests/clang-doc/HTMLGeneratorTest.cpp

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -92,13 +92,7 @@ TEST(HTMLGeneratorTest, emitNamespaceHTML) {
9292
</div>
9393
<h2 id="Enums">Enums</h2>
9494
<div>
95-
<table id=\"0000000000000000000000000000000000000000\">
96-
<thead>
97-
<tr>
98-
<th colspan=\"2\">enum OneEnum</th>
99-
</tr>
100-
</thead>
101-
</table>
95+
<h3 id="0000000000000000000000000000000000000000">enum OneEnum</h3>
10296
</div>
10397
</div>
10498
<div id="sidebar-right" class="col-xs-6 col-sm-6 col-md-2 sidebar sidebar-offcanvas-right">

0 commit comments

Comments
 (0)