Commit ac30157b authored by NicolasPetton's avatar NicolasPetton
Browse files

Do not sharp-quote lambdas

* lisp/progmodes/sql.el: Remove sharp-quotes in lambdas.
parent 9ad05bec
......@@ -1340,7 +1340,7 @@ Based on `comint-mode-map'.")
;; double quotes (") don't delimit strings
(modify-syntax-entry ?\" "." table)
;; Make these all punctuation
(mapc #'(lambda (c) (modify-syntax-entry c "." table))
(mapc (lambda (c) (modify-syntax-entry c "." table))
(string-to-list "!#$%&+,.:;<=>?@\\|"))
"Syntax table used in `sql-mode' and `sql-interactive-mode'.")
......@@ -2441,7 +2441,7 @@ highlighting rules in SQL mode.")
(let ((init (or (and initial (symbol-name initial)) "ansi")))
(intern (completing-read
(mapcar #'(lambda (info) (symbol-name (car info)))
(mapcar (lambda (info) (symbol-name (car info)))
nil 'require-match
init 'sql-product-history init))))
......@@ -2476,7 +2476,7 @@ configuration."
;; after this product's name.
(let ((next-item)
(down-display (downcase display)))
(map-keymap #'(lambda (k b)
(map-keymap (lambda (k b)
(when (and (not next-item)
(string-lessp down-display
(downcase (cadr b))))
......@@ -2582,7 +2582,7 @@ also be configured."
(font-lock-mode-internal t))
(add-hook 'font-lock-mode-hook
#'(lambda ()
(lambda ()
;; Provide defaults for new font-lock faces.
(defvar font-lock-builtin-face
(if (boundp 'font-lock-preprocessor-face)
......@@ -2631,7 +2631,7 @@ adds a fontification pattern to fontify identifiers ending in
"Iterate through login parameters and return a list of results."
(delq nil
#'(lambda (param)
(lambda (param)
(let ((token (or (car-safe param) param))
(plist (cdr-safe param)))
(funcall body token plist)))
......@@ -2643,7 +2643,7 @@ adds a fontification pattern to fontify identifiers ending in
(defun sql-product-syntax-table ()
(let ((table (copy-syntax-table sql-mode-syntax-table)))
(mapc #'(lambda (entry)
(mapc (lambda (entry)
(modify-syntax-entry (car entry) (cdr entry) table))
(sql-get-product-feature sql-product :syntax-alist))
......@@ -2652,7 +2652,7 @@ adds a fontification pattern to fontify identifiers ending in
;; Change all symbol character to word characters
#'(lambda (entry) (if (string= (substring (cdr entry) 0 1) "_")
(lambda (entry) (if (string= (substring (cdr entry) 0 1) "_")
(cons (car entry)
(concat "w" (substring (cdr entry) 1)))
......@@ -3025,7 +3025,7 @@ In order to qualify, the SQLi buffer must be alive, be in
;; Look thru each buffer
(car (apply #'append
(mapcar #'(lambda (b)
(mapcar (lambda (b)
(and (sql-buffer-live-p b prod connection)
(list (buffer-name b))))
......@@ -3112,7 +3112,7 @@ server/database name."
(apply #'append nil
(sql-get-product-feature sql-product :sqli-login)
#'(lambda (token plist)
(lambda (token plist)
(pcase token
(unless (string= "" sql-user)
......@@ -3278,12 +3278,12 @@ Allows the suppression of continuation prompts.")
((functionp filter)
(setq string (funcall filter string)))
((listp filter)
(mapc #'(lambda (f) (setq string (funcall f string))) filter))
(mapc (lambda (f) (setq string (funcall f string))) filter))
(t nil))
;; Count how many newlines in the string
(setq sql-output-newline-count
(apply #'+ (mapcar #'(lambda (ch)
(apply #'+ (mapcar (lambda (ch)
(if (eq ch ?\n) 1 0)) string)))
;; Send the string
......@@ -3510,7 +3510,7 @@ list of SQLi command strings."
(when visible
(message "Executing SQL command..."))
(if (consp command)
(mapc #'(lambda (c) (sql-redirect-one sqlbuf c outbuf save-prior))
(mapc (lambda (c) (sql-redirect-one sqlbuf c outbuf save-prior))
(sql-redirect-one sqlbuf command outbuf save-prior))
(when visible
......@@ -3594,7 +3594,7 @@ for each match."
(match-string regexp-groups))
;; list of numbers; return the specified matches only
((consp regexp-groups)
(mapcar #'(lambda (c)
(mapcar (lambda (c)
((numberp c) (match-string c))
((stringp c) (match-substitute-replacement c))
......@@ -3624,7 +3624,7 @@ strings are formatted with ARG and executed.
If the results are empty the OUTBUF is deleted, otherwise the
buffer is popped into a view window."
#'(lambda (c)
(lambda (c)
((stringp c)
(sql-redirect sqlbuf (if arg (format c arg) c) outbuf) t)
......@@ -4009,7 +4009,7 @@ Sentinels will always get the two parameters PROCESS and EVENT."
"Read a connection name."
(let ((completion-ignore-case t))
(completing-read prompt
(mapcar #'(lambda (c) (car c))
(mapcar (lambda (c) (car c))
nil t initial 'sql-connection-history default)))
......@@ -4052,7 +4052,7 @@ is specified in the connection settings."
;; Params in the connection
(setq set-params
#'(lambda (v)
(lambda (v)
(pcase (car v)
(`sql-user 'user)
(`sql-password 'password)
......@@ -4065,13 +4065,13 @@ is specified in the connection settings."
;; the remaining params (w/o the connection params)
(setq rem-params
(sql-for-each-login login-params
#'(lambda (token plist)
(lambda (token plist)
(unless (member token set-params)
(if plist (cons token plist) token)))))
;; Set the parameters and start the interactive session
#'(lambda (vv)
(lambda (vv)
(set-default (car vv) (eval (cadr vv))))
(cdr connect-set))
(setq-default sql-connection connection)
......@@ -4125,7 +4125,7 @@ optionally is saved to the user's init file."
(cons name
`(product ,@login)
#'(lambda (token _plist)
(lambda (token _plist)
(pcase token
(`product `(sql-product ',product))
(`user `(sql-user ,user))
......@@ -4144,7 +4144,7 @@ optionally is saved to the user's init file."
"Generate menu entries for using each connection."
#'(lambda (conn)
(lambda (conn)
(format "Connection <%s>\t%s" (car conn)
(let ((sql-user "") (sql-database "")
......@@ -4428,7 +4428,7 @@ The default comes from `process-coding-system-alist' and
;; Remove any settings that haven't changed
#'(lambda (one-cur-setting)
(lambda (one-cur-setting)
(setq saved-settings (delete one-cur-setting saved-settings)))
(sql-oracle-save-settings sqlbuf))
......@@ -4946,7 +4946,7 @@ Try to set `comint-output-filter-functions' like this:
(sql-redirect sqlbuf "\\a"))
;; Return the list of table names (public schema name can be omitted)
(mapcar #'(lambda (tbl)
(mapcar (lambda (tbl)
(if (string= (car tbl) "public")
(format "\"%s\"" (cadr tbl))
(format "\"%s\".\"%s\"" (car tbl) (cadr tbl))))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment