Skip to content

Commit 63193fa

Browse files
committed
review: forward emplace_back arguments
1 parent 0edfe43 commit 63193fa

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

clang/lib/Parse/ParseHLSLRootSignature.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,32 +33,32 @@ bool RootSignatureParser::parse() {
3333
auto Flags = parseRootFlags();
3434
if (!Flags.has_value())
3535
return true;
36-
Elements.emplace_back(RootSignatureElement(ElementLoc, *Flags));
36+
Elements.emplace_back(ElementLoc, *Flags);
3737
} else if (tryConsumeExpectedToken(TokenKind::kw_RootConstants)) {
3838
SourceLocation ElementLoc = getTokenLocation(CurToken);
3939
auto Constants = parseRootConstants();
4040
if (!Constants.has_value())
4141
return true;
42-
Elements.emplace_back(RootSignatureElement(ElementLoc, *Constants));
42+
Elements.emplace_back(ElementLoc, *Constants);
4343
} else if (tryConsumeExpectedToken(TokenKind::kw_DescriptorTable)) {
4444
SourceLocation ElementLoc = getTokenLocation(CurToken);
4545
auto Table = parseDescriptorTable();
4646
if (!Table.has_value())
4747
return true;
48-
Elements.emplace_back(RootSignatureElement(ElementLoc, *Table));
48+
Elements.emplace_back(ElementLoc, *Table);
4949
} else if (tryConsumeExpectedToken(
5050
{TokenKind::kw_CBV, TokenKind::kw_SRV, TokenKind::kw_UAV})) {
5151
SourceLocation ElementLoc = getTokenLocation(CurToken);
5252
auto Descriptor = parseRootDescriptor();
5353
if (!Descriptor.has_value())
5454
return true;
55-
Elements.emplace_back(RootSignatureElement(ElementLoc, *Descriptor));
55+
Elements.emplace_back(ElementLoc, *Descriptor);
5656
} else if (tryConsumeExpectedToken(TokenKind::kw_StaticSampler)) {
5757
SourceLocation ElementLoc = getTokenLocation(CurToken);
5858
auto Sampler = parseStaticSampler();
5959
if (!Sampler.has_value())
6060
return true;
61-
Elements.emplace_back(RootSignatureElement(ElementLoc, *Sampler));
61+
Elements.emplace_back(ElementLoc, *Sampler);
6262
}
6363

6464
// ',' denotes another element, otherwise, expected to be at end of stream
@@ -254,7 +254,7 @@ std::optional<DescriptorTable> RootSignatureParser::parseDescriptorTable() {
254254
auto Clause = parseDescriptorTableClause();
255255
if (!Clause.has_value())
256256
return std::nullopt;
257-
Elements.emplace_back(RootSignatureElement(ElementLoc, *Clause));
257+
Elements.emplace_back(ElementLoc, *Clause);
258258
Table.NumClauses++;
259259
} else if (tryConsumeExpectedToken(TokenKind::kw_visibility)) {
260260
// visibility = SHADER_VISIBILITY

0 commit comments

Comments
 (0)