Created
February 22, 2017 04:20
-
-
Save OdatNurd/57c1b2ccdb5fb656b4d334a6063e06e0 to your computer and use it in GitHub Desktop.
Goto Definition and symbols containing a period
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%YAML 1.2 | |
--- | |
# See http://www.sublimetext.com/docs/3/syntax.html | |
file_extensions: | |
- lang | |
scope: source.lang | |
contexts: | |
main: | |
- match: '//' | |
scope: punctuation.definition.comment.lang | |
push: line_comment | |
- match: '([\w.]+):{' | |
captures: | |
1: entity.name.function | |
- match: '([\w.]+)(\[)' | |
captures: | |
1: support.function.call | |
line_comment: | |
- meta_scope: comment.line.lang | |
- match: $ | |
pop: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<plist version="1.0"> | |
<dict> | |
<key>scope</key> | |
<string>source.lang entity.name.function</string> | |
<key>settings</key> | |
<dict> | |
<key>showInSymbolList</key> | |
<integer>1</integer> | |
<key>showInIndexedSymbolList</key> | |
<integer>1</integer> | |
</dict> | |
</dict> | |
</plist> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Function 1 | |
function.name1:{} | |
// Function 2 | |
function.name2:{} | |
// Function 3 | |
function.name3:{} | |
// Function 4 | |
function.name4:{} | |
// Function 4 | |
function.name5:{} | |
.namespace.function:{} | |
function.name1[] | |
function.name2[] | |
function.name3[] | |
function.name4[] | |
function.name5[] | |
.namespace.function[] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
As defined, the goto definition code will not work with this syntax unless you select the entirety of the symbol before invoking it. This is because the method
symbol_at_point
inPackages\Default\symbol.py
is hard coded to assume various word characters (instead of pulling them from a setting or some such).