use precise getTokenAt
This commit is contained in:
parent
34922a0d03
commit
c94d9dca94
|
@ -494,7 +494,7 @@ function createAppliesToLineWidget(cm) {
|
||||||
const eatToken = sticky => {
|
const eatToken = sticky => {
|
||||||
if (!sticky) skipSpace(pos, posEnd);
|
if (!sticky) skipSpace(pos, posEnd);
|
||||||
pos.ch++;
|
pos.ch++;
|
||||||
const token = cm.getTokenAt(pos);
|
const token = cm.getTokenAt(pos, true);
|
||||||
pos.ch = token.end;
|
pos.ch = token.end;
|
||||||
return CodeMirror.cmpPos(pos, posEnd) <= 0 ? token : {};
|
return CodeMirror.cmpPos(pos, posEnd) <= 0 ? token : {};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue
Block a user