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

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

[nongnu] elpa/emacsql eba26bead6 102/427: Add emacsql-compile function f


From: ELPA Syncer
Subject: [nongnu] elpa/emacsql eba26bead6 102/427: Add emacsql-compile function for debugging.
Date: Tue, 13 Dec 2022 02:59:32 -0500 (EST)

branch: elpa/emacsql
commit eba26bead62d01ac1c6a5d15229332367eb60104
Author: Christopher Wellons <wellons@nullprogram.com>
Commit: Christopher Wellons <wellons@nullprogram.com>

    Add emacsql-compile function for debugging.
---
 emacsql.el | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/emacsql.el b/emacsql.el
index 4e5464aad9..4e3875a12b 100644
--- a/emacsql.el
+++ b/emacsql.el
@@ -342,6 +342,10 @@ a list of (<string> [arg-pos] ...)."
                                    (emacsql-escape-identifier thing)
                                  (emacsql-escape-value thing)))))))))
 
+(defun emacsql-compile (sql &rest args)
+  "Compile structured SQL expression into a string."
+  (apply #'emacsql-format (emacsql-expand sql) args))
+
 (defun emacsql (conn sql &rest args)
   "Send structured SQL expression to CONN with ARGS."
   (emacsql--clear conn)



reply via email to

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