On Thu, Mar 8, 2018 at 5:04 AM, Thomas Levesque <thomas.leves...@gmail.com> wrote: > Currently C# async methods are not shown in diff hunk headers. I just > added the async keyword to the csharp method pattern so that they are > properly detected.
Thanks for the contribution. Please sign-off your patch (see SubmittingPatches[1]). [1]: https://github.com/git/git/blob/master/Documentation/SubmittingPatches#L278 > --- > diff --git a/userdiff.c b/userdiff.c > index dbfb4e13cddce..b92caf42b27be 100644 > --- a/userdiff.c > +++ b/userdiff.c > @@ -138,7 +138,7 @@ PATTERNS("csharp", > /* Keywords */ > "!^[ > \t]*(do|while|for|if|else|instanceof|new|return|switch|case|throw|catch|using)\n" > /* Methods and constructors */ > - "^[ > \t]*(((static|public|internal|private|protected|new|virtual|sealed|override|unsafe)[ > \t]+)*[][<>@.~_[:alnum:]]+[ \t]+[<>@._[:alnum:]]+[ \t]*\\(.*\\))[ \t]*$\n" > + "^[ > \t]*(((static|public|internal|private|protected|new|virtual|sealed|override|unsafe|async)[ > \t]+)*[][<>@.~_[:alnum:]]+[ \t]+[<>@._[:alnum:]]+[ \t]*\\(.*\\))[ \t]*$\n" > /* Properties */ > "^[ > \t]*(((static|public|internal|private|protected|new|virtual|sealed|override|unsafe)[ > \t]+)*[][<>@.~_[:alnum:]]+[ \t]+[@._[:alnum:]]+)[ \t]*$\n" > /* Type definitions */