Skip to content
This repository has been archived by the owner on Nov 2, 2019. It is now read-only.

Commit

Permalink
Add # and ' to regex for non-module reference searches and type inspe…
Browse files Browse the repository at this point in the history
…ction expander. Fixes #6.
  • Loading branch information
TheSpyder committed Feb 20, 2014
1 parent f266996 commit 61b14e0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sublime_ocp_index.py
Expand Up @@ -58,7 +58,7 @@ def extract_query(self, view, location):


line = view.substr(sublime.Region(view.line(location).begin(), location))
match = re.search(r"[,\s]*([A-Z][\w_.#']*|[\w_]+)$", line)
match = re.search(r"[,\s]*([A-Z][\w_.#']*|[\w_#']+)$", line)

if match != None:
(queryString,) = match.groups()
Expand All @@ -84,7 +84,7 @@ def extract_query(self, view, location):

def query_type(self, view, location):
endword = view.word(location).end()
while view.substr(endword) is '_':
while view.substr(endword) in ['_', '#', '\'']:
endword = endword + 1
if view.substr(endword) is not ' ':
endword = view.word(endword).end()
Expand Down

0 comments on commit 61b14e0

Please sign in to comment.