I am trying to get the Fucntion List function in notepad ++ (v 6.7.5) that works in Perl with classes (or packages, in the perl language). By default, only regular routines outside of packages are supported.
The following is an XML snippet from the function list configuration file (located on my Windows machine in the C: \ Users \ user \ AppData \ Roaming \ Notepad ++ \ functionList.xml folder). I added the "classRange" node itself on top of the "default" node function.
EDIT: below adjusted XML, thanks to user stribizhev
UPDATE: I commented on the “normal” function section because it made all my methods appear twice in the function list.
<parser id="perl_function" displayName="Perl">
<classRange mainExpr="^package.*?(?=\npackage|\Z)">
<className>
<nameExpr expr="\s\K[^;]+"/>
</className>
<function mainExpr="^[\s]*(?<!#)[\s]*sub[\s]+[\w]+[\s]*\(?[^\)\(]*?\)?[\n\s]*\{" displayMode="$className->$functionName">
<functionName>
<funcNameExpr expr="(sub[\s]+)?\K[\w]+"/>
</functionName>
</function>
</classRange>
</parser>
The documentation for this is here .