Skip to content

Commit e07df0b

Browse files
committed
Fix regex to enable autocomplete on dot
1 parent 1f6f97d commit e07df0b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ const { AutoLanguageClient } = require("atom-languageclient");
55

66
// Ref: https://github.com/nteract/hydrogen/blob/master/lib/autocomplete-provider.js#L33
77
// adapted from http://stackoverflow.com/q/5474008
8-
const PYTHON_REGEX = /([^\d\W]|[\u00A0-\uFFFF])[\w.\u00A0-\uFFFF]*$/;
8+
const PYTHON_REGEX = /(([^\d\W]|[\u00A0-\uFFFF])[\w.\u00A0-\uFFFF]*)|\.$/;
99

1010
class PythonLanguageClient extends AutoLanguageClient {
1111
getGrammarScopes() {

0 commit comments

Comments
 (0)