Skip to content

Commit 863566e

Browse files
committed
Added CSharpSources.IsReservedKeyword static helper method.
1 parent c1ab16b commit 863566e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/Generator/Generators/CSharp/CSharpSources.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,8 @@ private void Init()
5959
"void", "partial", "yield", "where"
6060
};
6161

62+
public static bool IsReservedKeyword(string id) => ReservedKeywords.Contains(id);
63+
6264
public override string SafeIdentifier(string id)
6365
{
6466
if (id.All(char.IsLetterOrDigit))

0 commit comments

Comments
 (0)