while testing this source generator with another one I noticed an issue with some generated parameter names.
Methods that use keywords such as long as identifiers don't get properly prefixed with @ in the generated interface.
Example:
public void VoidMethodWithKeywordParam(long @long)
Hey,
while testing this source generator with another one I noticed an issue with some generated parameter names. Methods that use keywords such as
long
as identifiers don't get properly prefixed with@
in the generated interface.Example:
results in:
but should be:
This should be the line where
param.Name
needs to be checked and sometimes prefixed. https://github.com/daver32/InterfaceGenerator/blob/9382c69cf8c72bdc21bcb1e2984f4b7f3902dbae/InterfaceGenerator/AutoInterfaceGenerator.cs#L327e. g. AutoRest is handling these identifiers like this: 1. Writing the identifier. 2. Checking for C# keywords