[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/csharp-mode ee9125d 163/459: Fix looking-back warnings.
From: |
ELPA Syncer |
Subject: |
[elpa] externals/csharp-mode ee9125d 163/459: Fix looking-back warnings. |
Date: |
Sun, 22 Aug 2021 13:59:18 -0400 (EDT) |
branch: externals/csharp-mode
commit ee9125d87374203cd9af480964419ea55122a41c
Author: Jostein Kjønigsen <jostein@kjonigsen.net>
Commit: Jostein Kjønigsen <jostein@kjonigsen.net>
Fix looking-back warnings.
Based on feedback in this exchange with cc-mode maintainer:
http://debbugs.gnu.org/cgi/bugreport.cgi?bug=23053
This closes https://github.com/josteink/csharp-mode/issues/48
---
csharp-mode.el | 66 +++++++++++++++++++++++++++++-----------------------------
1 file changed, 33 insertions(+), 33 deletions(-)
diff --git a/csharp-mode.el b/csharp-mode.el
index ed181e7..84eacb1 100644
--- a/csharp-mode.el
+++ b/csharp-mode.el
@@ -446,7 +446,7 @@ to work properly with code that includes attributes.
((and (looking-back
(concat "\\<new[ \t\n\f\v\r]+"
"\\(?:[A-Za-z_][[:alnum:]]*\\.\\)*"
- "[A-Za-z_][[:alnum:]]*[\ t\n\f\v\r]*"))
+ "[A-Za-z_][[:alnum:]]*[\ t\n\f\v\r]*") nil)
(looking-at "[ \t\n\f\v\r]*{"))
t)
@@ -1727,9 +1727,9 @@ This is a helper fn for
`csharp-move-back-to-beginning-of-defun' and
(if need-to-backup
(setq found (csharp-move-back-to-beginning-of-block)))
(if found
- (setq done (and (looking-back must-match)
+ (setq done (and (looking-back must-match nil)
(or (not must-not-match)
- (not (looking-back must-not-match))))
+ (not (looking-back must-not-match nil))))
need-to-backup t)
(setq done t)))
found))
@@ -1755,8 +1755,8 @@ See also, `csharp-move-fwd-to-end-of-defun'.
;; if the user is asking to move back, then obviously
;; he wants to move back to a *prior* defun.
(if (and (looking-at "{")
- (looking-back (csharp--regexp 'func-start))
- (not (looking-back (csharp--regexp 'namespace-start))))
+ (looking-back (csharp--regexp 'func-start) nil)
+ (not (looking-back (csharp--regexp 'namespace-start) nil)))
(forward-char -1))
;; now do the real work
@@ -1773,9 +1773,9 @@ See also, `csharp-move-fwd-to-end-of-defun'.
(save-excursion
(and
(progn (forward-char) (forward-sexp -1) t)
- (not (looking-back (csharp--regexp 'class-start)))
- (not (looking-back (csharp--regexp 'namespace-start)))
- (looking-back (csharp--regexp 'func-start))))))
+ (not (looking-back (csharp--regexp 'class-start) nil))
+ (not (looking-back (csharp--regexp 'namespace-start) nil))
+ (looking-back (csharp--regexp 'func-start) nil)))))
(defun csharp--on-ctor-close-curly-p ()
"return t when point is on the close-curly of a constructor."
@@ -1783,7 +1783,7 @@ See also, `csharp-move-fwd-to-end-of-defun'.
(save-excursion
(and
(progn (forward-char) (forward-sexp -1) t)
- (looking-back (csharp--regexp 'ctor-start))))))
+ (looking-back (csharp--regexp 'ctor-start) nil)))))
(defun csharp--on-class-close-curly-p ()
"return t when point is on the close-curly of a class or struct."
@@ -1791,8 +1791,8 @@ See also, `csharp-move-fwd-to-end-of-defun'.
(save-excursion
(and
(progn (forward-char) (forward-sexp -1) t)
- (not (looking-back (csharp--regexp 'namespace-start)))
- (looking-back (csharp--regexp 'class-start))))))
+ (not (looking-back (csharp--regexp 'namespace-start) nil))
+ (looking-back (csharp--regexp 'class-start) nil)))))
(defun csharp--on-intf-close-curly-p ()
"return t when point is on the close-curly of an interface."
@@ -1800,7 +1800,7 @@ See also, `csharp-move-fwd-to-end-of-defun'.
(save-excursion
(and
(progn (forward-char) (forward-sexp -1) t)
- (looking-back (csharp--regexp 'intf-start))))))
+ (looking-back (csharp--regexp 'intf-start) nil)))))
(defun csharp--on-enum-close-curly-p ()
"return t when point is on the close-curly of an enum."
@@ -1808,7 +1808,7 @@ See also, `csharp-move-fwd-to-end-of-defun'.
(save-excursion
(and
(progn (forward-char) (forward-sexp -1) t)
- (looking-back (csharp--regexp 'enum-start))))))
+ (looking-back (csharp--regexp 'enum-start) nil)))))
(defun csharp--on-namespace-close-curly-p ()
"return t when point is on the close-curly of a namespace."
@@ -1816,56 +1816,56 @@ See also, `csharp-move-fwd-to-end-of-defun'.
(save-excursion
(and
(progn (forward-char) (forward-sexp -1) t)
- (looking-back (csharp--regexp 'namespace-start))))))
+ (looking-back (csharp--regexp 'namespace-start) nil)))))
(defun csharp--on-defun-open-curly-p ()
"return t when point is on the open-curly of a method."
(and (looking-at "{")
- (not (looking-back (csharp--regexp 'class-start)))
- (not (looking-back (csharp--regexp 'namespace-start)))
- (looking-back (csharp--regexp 'func-start))))
+ (not (looking-back (csharp--regexp 'class-start) nil))
+ (not (looking-back (csharp--regexp 'namespace-start) nil))
+ (looking-back (csharp--regexp 'func-start) nil)))
(defun csharp--on-class-open-curly-p ()
"return t when point is on the open-curly of a class."
(and (looking-at "{")
- (not (looking-back (csharp--regexp 'namespace-start)))
- (looking-back (csharp--regexp 'class-start))))
+ (not (looking-back (csharp--regexp 'namespace-start) nil))
+ (looking-back (csharp--regexp 'class-start) nil)))
(defun csharp--on-genclass-open-curly-p ()
"return t when point is on the open-curly of a generic class."
(and (looking-at "{")
- (looking-back (csharp--regexp 'genclass-start))))
+ (looking-back (csharp--regexp 'genclass-start) nil)))
(defun csharp--on-namespace-open-curly-p ()
"return t when point is on the open-curly of a namespace."
(and (looking-at "{")
- (looking-back (csharp--regexp 'namespace-start))))
+ (looking-back (csharp--regexp 'namespace-start) nil)))
(defun csharp--on-ctor-open-curly-p ()
"return t when point is on the open-curly of a ctor."
(and (looking-at "{")
- (looking-back (csharp--regexp 'ctor-start))))
+ (looking-back (csharp--regexp 'ctor-start) nil)))
(defun csharp--on-intf-open-curly-p ()
"return t when point is on the open-curly of a interface."
(and (looking-at "{")
- (looking-back (csharp--regexp 'intf-start))))
+ (looking-back (csharp--regexp 'intf-start) nil)))
(defun csharp--on-prop-open-curly-p ()
"return t when point is on the open-curly of a property."
(and (looking-at "{")
- (not (looking-back (csharp--regexp 'class-start)))
- (looking-back (csharp--regexp 'prop-start))))
+ (not (looking-back (csharp--regexp 'class-start) nil))
+ (looking-back (csharp--regexp 'prop-start) nil)))
(defun csharp--on-indexer-open-curly-p ()
"return t when point is on the open-curly of a C# indexer."
(and (looking-at "{")
- (looking-back (csharp--regexp 'indexer-start))))
+ (looking-back (csharp--regexp 'indexer-start) nil)))
(defun csharp--on-enum-open-curly-p ()
"return t when point is on the open-curly of a interface."
(and (looking-at "{")
- (looking-back (csharp--regexp 'enum-start))))
+ (looking-back (csharp--regexp 'enum-start) nil)))
@@ -1915,7 +1915,7 @@ See also, `csharp-move-back-to-beginning-of-defun'.
;; case 4: we're at the bottom of a fn now (possibly
;; after just calling csharp-move-fwd-to-end-of-defun.
- ((and (looking-back "}")
+ ((and (looking-back "}" nil)
(save-excursion
(forward-sexp -1)
(csharp--on-defun-open-curly-p)))
@@ -1955,8 +1955,8 @@ See also, `csharp-move-fwd-to-end-of-defun'.
;; if the user is asking to move back, then obviously
;; he wants to move back to a *prior* defun.
(if (and (looking-at "{")
- (looking-back (csharp--regexp 'class-start))
- (not (looking-back (csharp--regexp 'namespace-start))))
+ (looking-back (csharp--regexp 'class-start) nil)
+ (not (looking-back (csharp--regexp 'namespace-start) nil)))
(forward-char -1))
;; now do the real work
@@ -2007,7 +2007,7 @@ to the beginning of the prior namespace.
;; if the user is asking to move back, then obviously
;; he wants to move back to a *prior* defun.
(if (and (looking-at "{")
- (looking-back (csharp--regexp 'namespace-start)))
+ (looking-back (csharp--regexp 'namespace-start) nil))
(forward-char -1))
;; now do the real work
@@ -2428,11 +2428,11 @@ more open-curlies are found.
(cond
;; case 1: open curly for an array initializer
- ((looking-back "\\[\\][ \t\n\r]*")
+ ((looking-back "\\[\\][ \t\n\r]*" nil)
(forward-sexp 1))
;; case 2: just jumped over a string
- ((looking-back "\"")
+ ((looking-back "\"" nil)
(forward-char 1))
;; case 3: at the head of a block of using statements
- [elpa] externals/csharp-mode 26737de 211/459: Fix build by cheating., (continued)
- [elpa] externals/csharp-mode 26737de 211/459: Fix build by cheating., ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode 7ced65e 225/459: Require cc-fonts, ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode 571c4c7 240/459: Stop misleading our poor users., ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode d72e5c6 242/459: Revert changes in changelog., ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode 0f39f84 122/459: Apply bug#18845 workaround, ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode 73e7ed6 125/459: Merge pull request #53 from ymarkovitch/master, ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode d01f22f 149/459: Imenu: fix interface-prefixed members, ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode b8073ed 151/459: Imenu: correctly report namespace for all types, ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode ed030e7 152/459: Ensure test-cases don't overlap., ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode c7932f9 156/459: Remove useless autoloads, ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode ee9125d 163/459: Fix looking-back warnings.,
ELPA Syncer <=
- [elpa] externals/csharp-mode f9e95d1 167/459: Ensure tests reproduce fontification bugs., ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode ca394f1 188/459: imenu: Fix indexing of methods in test-file., ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode c206dbc 191/459: extern is a modifier-keyword, not "other" keyword., ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode a8d8ef8 195/459: imenu: Index delegates, ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode 897c85a 197/459: imenu: Fix indexing of delegates., ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode fe3ca7e 200/459: Inline square-parenthesis detection., ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode f9122bb 208/459: Fix indentation for array collection initializers., ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode ebd67a1 209/459: Correctly indent nested generic object initializers, ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode 5b89db2 088/459: Imenu: Correctly handle default-values in param-lists., ELPA Syncer, 2021/08/22
- [elpa] externals/csharp-mode 8ccafbc 092/459: remove unused rule and documentation, ELPA Syncer, 2021/08/22