Tags: patch mksh supports characters well beyond [:alnum:_] in its function names. More specifically, syn.c:function_body says the following /*- * Check for valid characters in name. POSIX and AT&T ksh93 say * only allow [a-zA-Z_0-9] but this allows more as old pdkshs * have allowed more; the following were never allowed: * NUL TAB NL SP " $ & ' ( ) ; < = > \ ` | * C_QUOTE|C_SPC covers all but adds # * ? [ ] */ However, it seems like executing a function with a forward-slash (/) character in it is impossible as well. Attached patch adds a mksh-specific entry to sh-imenu-generic-expression to do that.