Skip to content

Commit 901e366

Browse files
BowenYang666Bowen Yang (from Dev Box)
andauthored
Add default value for namedArg in Microsoft.Gen.Metrics.parser (#6238)
Co-authored-by: Bowen Yang (from Dev Box) <[email protected]>
1 parent 496cc2f commit 901e366

File tree

1 file changed

+1
-1
lines changed
  • src/Generators/Microsoft.Gen.Metrics

1 file changed

+1
-1
lines changed

src/Generators/Microsoft.Gen.Metrics/Parser.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -422,7 +422,7 @@ private void GetTagDescription(
422422
if (!methodAttribute.ConstructorArguments.IsDefaultOrEmpty
423423
&& methodAttribute.ConstructorArguments[0].Kind == TypedConstantKind.Type)
424424
{
425-
KeyValuePair<string, TypedConstant> namedArg;
425+
KeyValuePair<string, TypedConstant> namedArg = default;
426426
var ctorArg = methodAttribute.ConstructorArguments[0];
427427

428428
if (!methodAttribute.NamedArguments.IsDefaultOrEmpty)

0 commit comments

Comments
 (0)