emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/emacsql 3176aeee61 345/427: Use elisp--preceding-sexp if a


From: ELPA Syncer
Subject: [nongnu] elpa/emacsql 3176aeee61 345/427: Use elisp--preceding-sexp if available
Date: Tue, 13 Dec 2022 03:00:00 -0500 (EST)

branch: elpa/emacsql
commit 3176aeee6140e464e1cede60e05b6523d1e38a23
Author: Jonas Bernoulli <jonas@bernoul.li>
Commit: Jonas Bernoulli <jonas@bernoul.li>

    Use elisp--preceding-sexp if available
    
    in order to avoid a warning from the byte-compiler.
---
 emacsql.el | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/emacsql.el b/emacsql.el
index ea6ba3094b..1703756444 100644
--- a/emacsql.el
+++ b/emacsql.el
@@ -373,7 +373,10 @@ Each column must be a plain symbol, no expressions allowed 
here."
   "Display the compiled SQL of the s-expression SQL expression before point.
 A prefix argument causes the SQL to be printed into the current buffer."
   (interactive "P")
-  (let ((sexp (preceding-sexp)))
+  (let ((sexp (if (fboundp 'elisp--preceding-sexp)
+                  (elisp--preceding-sexp)
+                (with-no-warnings
+                  (preceding-sexp)))))
     (if (emacsql-sql-p sexp)
         (let ((sql (emacsql-flatten-sql sexp)))
           (if prefix



reply via email to

[Prev in Thread] Current Thread [Next in Thread]