diff options
Diffstat (limited to 'userdiff.c')
-rw-r--r-- | userdiff.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/userdiff.c b/userdiff.c index 2ccbee50cb..cd0cf21f88 100644 --- a/userdiff.c +++ b/userdiff.c @@ -146,6 +146,13 @@ PATTERNS("csharp", "[a-zA-Z_][a-zA-Z0-9_]*" "|[-+0-9.e]+[fFlL]?|0[xXbB]?[0-9a-fA-F]+[lL]?" "|[-+*/<>%&^|=!]=|--|\\+\\+|<<=?|>>=?|&&|\\|\\||::|->"), +PATTERNS("sh", + "^([ \t]*(function[ \t]+)?[a-zA-Z_][a-zA-Z0-9_]*[ \t]*\\([ \t]*\\).*)$", + /* -- */ + "[a-zA-Z0-9_]+" + "|[-+0-9]+" + "|[-+*/<>%&^|=!]=|>>=?|<<=?|\\+\\+|--|\\*\\*|&&|\\|\\||\\[\\[|\\]\\]" + "|>\\||[<>]+&|<>|<<-|;;"), { "default", NULL, -1, { NULL, 0 } }, }; #undef PATTERNS |