MCPcopy Create free account
hub / github.com/ycm-core/YouCompleteMe / CurrentIdentifierFinished

Function CurrentIdentifierFinished

python/ycm/base.py:64–77  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

62
63
64def CurrentIdentifierFinished():
65 line, current_column = vimsupport.CurrentLineContentsAndCodepointColumn()
66 previous_char_index = current_column - 1
67 if previous_char_index < 0:
68 return True
69 filetype = vimsupport.CurrentFiletypes()[ 0 ]
70 regex = identifier_utils.IdentifierRegexForFiletype( filetype )
71
72 for match in regex.finditer( line ):
73 if match.end() == previous_char_index:
74 return True
75 # If the whole line is whitespace, that means the user probably finished an
76 # identifier on the previous line.
77 return line[ : current_column ].isspace()
78
79
80def LastEnteredCharIsIdentifierChar():

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected