Browse Source

Fix GetterSetterToProperty pass heuristic to also detect “to” as a verb.

pull/1316/merge
João Matos 6 years ago committed by João Matos
parent
commit
a4766719cd
  1. 2
      src/Generator/Passes/GetterSetterToPropertyPass.cs

2
src/Generator/Passes/GetterSetterToPropertyPass.cs

@ -115,7 +115,7 @@ namespace CppSharp.Passes @@ -115,7 +115,7 @@ namespace CppSharp.Passes
Match(firstWord, new[] { "get", "is", "has" }))
continue;
if (Match(firstWord, new[] { "to", "new" }) ||
if (Match(firstWord, new[] { "to", "new", "on" }) ||
verbs.Contains(firstWord))
{
property.GetMethod.GenerationKind = GenerationKind.Generate;

Loading…
Cancel
Save