Skip to content

Commit

Permalink
Merge pull request #572 from dpaoliello/escann
Browse files Browse the repository at this point in the history
Escape strings in `annotate` attributes
  • Loading branch information
tannergooding authored Sep 24, 2024
2 parents 4d07e05 + 0ab0f87 commit c5a6a76
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sources/ClangSharp.PInvokeGenerator/PInvokeGenerator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6817,7 +6817,7 @@ private void WithAttributes(NamedDecl namedDecl, bool onlySupportedOSPlatform =

case CX_AttrKind_Annotate:
{
var annotationText = attr.Spelling;
var annotationText = EscapeString(attr.Spelling);
outputBuilder.WriteCustomAttribute($"""NativeAnnotation("{annotationText}")""");
break;
}
Expand Down

0 comments on commit c5a6a76

Please sign in to comment.