branch: externals/cm-mode
commit 6ab83e059d6ab8c44f457b28670654885efe4dfc
Author: Joost Kremers <[email protected]>
Commit: Joost Kremers <[email protected]>
Add LIMIT argument to `looking-back'.
---
cm-mode.el | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/cm-mode.el b/cm-mode.el
index cd43d20d87..93b90b7bbd 100644
--- a/cm-mode.el
+++ b/cm-mode.el
@@ -479,7 +479,7 @@ is, instead of 0, the return value will be NIL."
(save-excursion
(if end
(let ((distance (skip-chars-forward (substring delim 1) (+ (point)
2))))
- (if (looking-back (regexp-quote delim))
+ (if (looking-back (regexp-quote delim) (- (point) 3))
(if (> distance 0)
distance
(and (not strict) 0))))