]> Cypherpunks repositories - gostls13.git/commitdiff
misc/notepadplus: fix functionList regex issue
authorChaiShushan <chaishushan@gmail.com>
Thu, 8 Aug 2013 17:57:32 +0000 (10:57 -0700)
committerBrad Fitzpatrick <bradfitz@golang.org>
Thu, 8 Aug 2013 17:57:32 +0000 (10:57 -0700)
The receiver name is optional. when Method's receiver name messing,
the functionList regex can't match the Method,
e.g. `func (*T) ProtoMessage() {}`.

R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/12530044

misc/notepadplus/functionList.xml

index 3d86bad7fa61872a597732faa9b614ac5e4ad5ea..6e00305fa37dd2fa08826ea8099091827b729013 100644 (file)
@@ -7,7 +7,7 @@
                <!-- <parsers> -->
                        <parser id="go" displayName="Go" commentExpr="((/\*.*?\*)/|(//.*?$))">
                                <function
-                                       mainExpr="(^func\s+\w+)|(^func\s*\(\s*\w+\s*\*?\s*\w+\s*\)\s*\w+)"
+                                       mainExpr="(^func\s+\w+)|(^func\s*\(\s*\w*\s*\*?\s*\w+\s*\)\s*\w+)"
                                        displayMode="$className->$functionName">
                                        <functionName>
                                                <nameExpr expr="((func\s+\w+)|(\)\s*\w+))"/>