]> git.bundesbrandschatzamt.de Git - emacsconfig.git/commitdiff
Update let-alist.
authorAndreas Gerler <baronNOSPAMbundesbrandschatzamt.de>
Tue, 22 Jan 2019 14:54:53 +0000 (15:54 +0100)
committerAndreas Gerler <baronNOSPAMbundesbrandschatzamt.de>
Tue, 22 Jan 2019 14:54:53 +0000 (15:54 +0100)
Signed-off-by: Andreas Gerler <baronNOSPAMbundesbrandschatzamt.de>
elpa/let-alist-1.0.4.signed [deleted file]
elpa/let-alist-1.0.4/let-alist-autoloads.el [deleted file]
elpa/let-alist-1.0.4/let-alist-pkg.el [deleted file]
elpa/let-alist-1.0.4/let-alist.el [deleted file]
elpa/let-alist-1.0.5/let-alist-autoloads.el [new file with mode: 0644]
elpa/let-alist-1.0.5/let-alist-pkg.el [new file with mode: 0644]
elpa/let-alist-1.0.5/let-alist.el [new file with mode: 0644]

diff --git a/elpa/let-alist-1.0.4.signed b/elpa/let-alist-1.0.4.signed
deleted file mode 100644 (file)
index 281ce60..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Good signature from 474F05837FBDEF9B GNU ELPA Signing Agent <elpasignNOSPAMelpa.gnu.org> (trust undefined) created at 2015-06-12T11:05:02+0200 using DSA
\ No newline at end of file
diff --git a/elpa/let-alist-1.0.4/let-alist-autoloads.el b/elpa/let-alist-1.0.4/let-alist-autoloads.el
deleted file mode 100644 (file)
index 375b561..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-;;; let-alist-autoloads.el --- automatically extracted autoloads
-;;
-;;; Code:
-(add-to-list 'load-path (or (file-name-directory #$) (car load-path)))
-\f
-;;;### (autoloads nil "let-alist" "let-alist.el" (21908 10928 0 0))
-;;; Generated autoloads from let-alist.el
-
-(autoload 'let-alist "let-alist" "\
-Let-bind dotted symbols to their cdrs in ALIST and execute BODY.
-Dotted symbol is any symbol starting with a `.'.  Only those present
-in BODY are let-bound and this search is done at compile time.
-
-For instance, the following code
-
-  (let-alist alist
-    (if (and .title .body)
-        .body
-      .site
-      .site.contents))
-
-essentially expands to
-
-  (let ((.title (cdr (assq 'title alist)))
-        (.body  (cdr (assq 'body alist)))
-        (.site  (cdr (assq 'site alist)))
-        (.site.contents (cdr (assq 'contents (cdr (assq 'site alist))))))
-    (if (and .title .body)
-        .body
-      .site
-      .site.contents))
-
-If you nest `let-alist' invocations, the inner one can't access
-the variables of the outer one. You can, however, access alists
-inside the original alist by using dots inside the symbol, as
-displayed in the example above.
-
-\(fn ALIST &rest BODY)" nil t)
-
-(put 'let-alist 'lisp-indent-function '1)
-
-;;;***
-\f
-;; Local Variables:
-;; version-control: never
-;; no-byte-compile: t
-;; no-update-autoloads: t
-;; End:
-;;; let-alist-autoloads.el ends here
diff --git a/elpa/let-alist-1.0.4/let-alist-pkg.el b/elpa/let-alist-1.0.4/let-alist-pkg.el
deleted file mode 100644 (file)
index ff29474..0000000
+++ /dev/null
@@ -1 +0,0 @@
-(define-package "let-alist" "1.0.4" "Easily let-bind values of an assoc-list by their names" 'nil :url "http://elpa.gnu.org/packages/let-alist.html" :keywords '("extensions" "lisp"))
diff --git a/elpa/let-alist-1.0.4/let-alist.el b/elpa/let-alist-1.0.4/let-alist.el
deleted file mode 100644 (file)
index dbf31e0..0000000
+++ /dev/null
@@ -1,170 +0,0 @@
-;;; let-alist.el --- Easily let-bind values of an assoc-list by their names -*- lexical-binding: t; -*-
-
-;; Copyright (C) 2014-2015 Free Software Foundation, Inc.
-
-;; Author: Artur Malabarba <bruce.connor.amNOSPAMgmail.com>
-;; Maintainer: Artur Malabarba <bruce.connor.amNOSPAMgmail.com>
-;; Version: 1.0.4
-;; Keywords: extensions lisp
-;; Prefix: let-alist
-;; Separator: -
-
-;; This file is part of GNU Emacs.
-
-;; GNU Emacs is free software: you can redistribute it and/or modify
-;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation, either version 3 of the License, or
-;; (at your option) any later version.
-
-;; GNU Emacs is distributed in the hope that it will be useful,
-;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-;; GNU General Public License for more details.
-
-;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.
-
-;;; Commentary:
-
-;; This package offers a single macro, `let-alist'.  This macro takes a
-;; first argument (whose value must be an alist) and a body.
-;;
-;; The macro expands to a let form containing body, where each dotted
-;; symbol inside body is let-bound to their cdrs in the alist.  Dotted
-;; symbol is any symbol starting with a `.'.  Only those present in
-;; the body are let-bound and this search is done at compile time.
-;;
-;; For instance, the following code
-;;
-;;   (let-alist alist
-;;     (if (and .title .body)
-;;         .body
-;;       .site
-;;       .site.contents))
-;;
-;; essentially expands to
-;;
-;;   (let ((.title (cdr (assq 'title alist)))
-;;         (.body  (cdr (assq 'body alist)))
-;;         (.site  (cdr (assq 'site alist)))
-;;         (.site.contents (cdr (assq 'contents (cdr (assq 'site alist))))))
-;;     (if (and .title .body)
-;;         .body
-;;       .site
-;;       .site.contents))
-;;
-;; If you nest `let-alist' invocations, the inner one can't access
-;; the variables of the outer one. You can, however, access alists
-;; inside the original alist by using dots inside the symbol, as
-;; displayed in the example above by the `.site.contents'.
-;;
-;;; Code:
-\f
-
-(defun let-alist--deep-dot-search (data)
-  "Return alist of symbols inside DATA that start with a `.'.
-Perform a deep search and return an alist where each car is the
-symbol, and each cdr is the same symbol without the `.'."
-  (cond
-   ((symbolp data)
-    (let ((name (symbol-name data)))
-      (when (string-match "\\`\\." name)
-        ;; Return the cons cell inside a list, so it can be appended
-        ;; with other results in the clause below.
-        (list (cons data (intern (replace-match "" nil nil name)))))))
-   ((not (consp data)) nil)
-   (t (append (let-alist--deep-dot-search (car data))
-              (let-alist--deep-dot-search (cdr data))))))
-
-(defun let-alist--access-sexp (symbol variable)
-  "Return a sexp used to access SYMBOL inside VARIABLE."
-  (let* ((clean (let-alist--remove-dot symbol))
-         (name (symbol-name clean)))
-    (if (string-match "\\`\\." name)
-        clean
-      (let-alist--list-to-sexp
-       (mapcar #'intern (nreverse (split-string name "\\.")))
-       variable))))
-
-(defun let-alist--list-to-sexp (list var)
-  "Turn symbols LIST into recursive calls to `cdr' `assq' on VAR."
-  `(cdr (assq ',(car list)
-              ,(if (cdr list) (let-alist--list-to-sexp (cdr list) var)
-                 var))))
-
-(defun let-alist--remove-dot (symbol)
-  "Return SYMBOL, sans an initial dot."
-  (let ((name (symbol-name symbol)))
-    (if (string-match "\\`\\." name)
-        (intern (replace-match "" nil nil name))
-      symbol)))
-
-\f
-;;; The actual macro.
-;;;###autoload
-(defmacro let-alist (alist &rest body)
-  "Let-bind dotted symbols to their cdrs in ALIST and execute BODY.
-Dotted symbol is any symbol starting with a `.'.  Only those present
-in BODY are let-bound and this search is done at compile time.
-
-For instance, the following code
-
-  (let-alist alist
-    (if (and .title .body)
-        .body
-      .site
-      .site.contents))
-
-essentially expands to
-
-  (let ((.title (cdr (assq 'title alist)))
-        (.body  (cdr (assq 'body alist)))
-        (.site  (cdr (assq 'site alist)))
-        (.site.contents (cdr (assq 'contents (cdr (assq 'site alist))))))
-    (if (and .title .body)
-        .body
-      .site
-      .site.contents))
-
-If you nest `let-alist' invocations, the inner one can't access
-the variables of the outer one. You can, however, access alists
-inside the original alist by using dots inside the symbol, as
-displayed in the example above."
-  (declare (indent 1) (debug t))
-  (let ((var (make-symbol "alist")))
-    `(let ((,var ,alist))
-       (let ,(mapcar (lambda (x) `(,(car x) ,(let-alist--access-sexp (car x) var)))
-               (delete-dups (let-alist--deep-dot-search body)))
-         ,@body))))
-
-;;;; ChangeLog:
-
-;; 2015-06-11  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
-;; 
-;;     * let-alist (let-alist--deep-dot-search): Fix cons
-;; 
-;; 2015-03-07  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
-;; 
-;;     let-alist: Update copyright
-;; 
-;; 2014-12-22  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
-;; 
-;;     packages/let-alist: Use `make-symbol' instead of `gensym'.
-;; 
-;; 2014-12-20  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
-;; 
-;;     packages/let-alist: Enable access to deeper alists
-;; 
-;; 2014-12-14  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
-;; 
-;;     let-alist.el: Add lexical binding. Version bump.
-;; 
-;; 2014-12-11  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
-;; 
-;;     let-alist: New package
-;; 
-
-
-(provide 'let-alist)
-
-;;; let-alist.el ends here
diff --git a/elpa/let-alist-1.0.5/let-alist-autoloads.el b/elpa/let-alist-1.0.5/let-alist-autoloads.el
new file mode 100644 (file)
index 0000000..1ba87ee
--- /dev/null
@@ -0,0 +1,50 @@
+;;; let-alist-autoloads.el --- automatically extracted autoloads
+;;
+;;; Code:
+(add-to-list 'load-path (directory-file-name (or (file-name-directory #$) (car load-path))))
+\f
+;;;### (autoloads nil "let-alist" "let-alist.el" (23082 53688 65987
+;;;;;;  795000))
+;;; Generated autoloads from let-alist.el
+
+(autoload 'let-alist "let-alist" "\
+Let-bind dotted symbols to their cdrs in ALIST and execute BODY.
+Dotted symbol is any symbol starting with a `.'.  Only those present
+in BODY are let-bound and this search is done at compile time.
+
+For instance, the following code
+
+  (let-alist alist
+    (if (and .title .body)
+        .body
+      .site
+      .site.contents))
+
+essentially expands to
+
+  (let ((.title (cdr (assq \\='title alist)))
+        (.body  (cdr (assq \\='body alist)))
+        (.site  (cdr (assq \\='site alist)))
+        (.site.contents (cdr (assq \\='contents (cdr (assq \\='site alist))))))
+    (if (and .title .body)
+        .body
+      .site
+      .site.contents))
+
+If you nest `let-alist' invocations, the inner one can't access
+the variables of the outer one. You can, however, access alists
+inside the original alist by using dots inside the symbol, as
+displayed in the example above.
+
+\(fn ALIST &rest BODY)" nil t)
+
+(function-put 'let-alist 'lisp-indent-function '1)
+
+;;;***
+\f
+;; Local Variables:
+;; version-control: never
+;; no-byte-compile: t
+;; no-update-autoloads: t
+;; End:
+;;; let-alist-autoloads.el ends here
diff --git a/elpa/let-alist-1.0.5/let-alist-pkg.el b/elpa/let-alist-1.0.5/let-alist-pkg.el
new file mode 100644 (file)
index 0000000..30740b7
--- /dev/null
@@ -0,0 +1,2 @@
+;;; -*- no-byte-compile: t -*-
+(define-package "let-alist" "1.0.5" "Easily let-bind values of an assoc-list by their names" '((emacs "24.1")) :url "http://elpa.gnu.org/packages/let-alist.html" :keywords '("extensions" "lisp"))
diff --git a/elpa/let-alist-1.0.5/let-alist.el b/elpa/let-alist-1.0.5/let-alist.el
new file mode 100644 (file)
index 0000000..43973c2
--- /dev/null
@@ -0,0 +1,182 @@
+;;; let-alist.el --- Easily let-bind values of an assoc-list by their names -*- lexical-binding: t; -*-
+
+;; Copyright (C) 2014-2017 Free Software Foundation, Inc.
+
+;; Author: Artur Malabarba <emacsNOSPAMendlessparentheses.com>
+;; Package-Requires: ((emacs "24.1"))
+;; Version: 1.0.5
+;; Keywords: extensions lisp
+;; Prefix: let-alist
+;; Separator: -
+
+;; This is an Elpa :core package. Don't use functionality that is not
+;; compatible with Emacs 24.1.
+
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software: you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.
+
+;;; Commentary:
+
+;; This package offers a single macro, `let-alist'.  This macro takes a
+;; first argument (whose value must be an alist) and a body.
+;;
+;; The macro expands to a let form containing body, where each dotted
+;; symbol inside body is let-bound to their cdrs in the alist.  Dotted
+;; symbol is any symbol starting with a `.'.  Only those present in
+;; the body are let-bound and this search is done at compile time.
+;;
+;; For instance, the following code
+;;
+;;   (let-alist alist
+;;     (if (and .title .body)
+;;         .body
+;;       .site
+;;       .site.contents))
+;;
+;; essentially expands to
+;;
+;;   (let ((.title (cdr (assq 'title alist)))
+;;         (.body  (cdr (assq 'body alist)))
+;;         (.site  (cdr (assq 'site alist)))
+;;         (.site.contents (cdr (assq 'contents (cdr (assq 'site alist))))))
+;;     (if (and .title .body)
+;;         .body
+;;       .site
+;;       .site.contents))
+;;
+;; If you nest `let-alist' invocations, the inner one can't access
+;; the variables of the outer one. You can, however, access alists
+;; inside the original alist by using dots inside the symbol, as
+;; displayed in the example above by the `.site.contents'.
+;;
+;;; Code:
+\f
+
+(defun let-alist--deep-dot-search (data)
+  "Return alist of symbols inside DATA that start with a `.'.
+Perform a deep search and return an alist where each car is the
+symbol, and each cdr is the same symbol without the `.'."
+  (cond
+   ((symbolp data)
+    (let ((name (symbol-name data)))
+      (when (string-match "\\`\\." name)
+        ;; Return the cons cell inside a list, so it can be appended
+        ;; with other results in the clause below.
+        (list (cons data (intern (replace-match "" nil nil name)))))))
+   ((not (consp data)) nil)
+   ((eq (car data) 'let-alist)
+    ;; For nested ‘let-alist’ forms, ignore symbols appearing in the
+    ;; inner body because they don’t refer to the alist currently
+    ;; being processed.  See Bug#24641.
+    (let-alist--deep-dot-search (cadr data)))
+   (t (append (let-alist--deep-dot-search (car data))
+              (let-alist--deep-dot-search (cdr data))))))
+
+(defun let-alist--access-sexp (symbol variable)
+  "Return a sexp used to access SYMBOL inside VARIABLE."
+  (let* ((clean (let-alist--remove-dot symbol))
+         (name (symbol-name clean)))
+    (if (string-match "\\`\\." name)
+        clean
+      (let-alist--list-to-sexp
+       (mapcar #'intern (nreverse (split-string name "\\.")))
+       variable))))
+
+(defun let-alist--list-to-sexp (list var)
+  "Turn symbols LIST into recursive calls to `cdr' `assq' on VAR."
+  `(cdr (assq ',(car list)
+              ,(if (cdr list) (let-alist--list-to-sexp (cdr list) var)
+                 var))))
+
+(defun let-alist--remove-dot (symbol)
+  "Return SYMBOL, sans an initial dot."
+  (let ((name (symbol-name symbol)))
+    (if (string-match "\\`\\." name)
+        (intern (replace-match "" nil nil name))
+      symbol)))
+
+\f
+;;; The actual macro.
+;;;###autoload
+(defmacro let-alist (alist &rest body)
+  "Let-bind dotted symbols to their cdrs in ALIST and execute BODY.
+Dotted symbol is any symbol starting with a `.'.  Only those present
+in BODY are let-bound and this search is done at compile time.
+
+For instance, the following code
+
+  (let-alist alist
+    (if (and .title .body)
+        .body
+      .site
+      .site.contents))
+
+essentially expands to
+
+  (let ((.title (cdr (assq \\='title alist)))
+        (.body  (cdr (assq \\='body alist)))
+        (.site  (cdr (assq \\='site alist)))
+        (.site.contents (cdr (assq \\='contents (cdr (assq \\='site alist))))))
+    (if (and .title .body)
+        .body
+      .site
+      .site.contents))
+
+If you nest `let-alist' invocations, the inner one can't access
+the variables of the outer one. You can, however, access alists
+inside the original alist by using dots inside the symbol, as
+displayed in the example above."
+  (declare (indent 1) (debug t))
+  (let ((var (make-symbol "alist")))
+    `(let ((,var ,alist))
+       (let ,(mapcar (lambda (x) `(,(car x) ,(let-alist--access-sexp (car x) var)))
+                     (delete-dups (let-alist--deep-dot-search body)))
+         ,@body))))
+
+;;;; ChangeLog:
+
+;; 2015-12-01  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
+;; 
+;;     packages/let-alist: Define it as a :core package
+;; 
+;; 2015-06-11  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
+;; 
+;;     * let-alist (let-alist--deep-dot-search): Fix cons
+;; 
+;; 2015-03-07  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
+;; 
+;;     let-alist: Update copyright
+;; 
+;; 2014-12-22  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
+;; 
+;;     packages/let-alist: Use `make-symbol' instead of `gensym'.
+;; 
+;; 2014-12-20  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
+;; 
+;;     packages/let-alist: Enable access to deeper alists
+;; 
+;; 2014-12-14  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
+;; 
+;;     let-alist.el: Add lexical binding. Version bump.
+;; 
+;; 2014-12-11  Artur Malabarba  <bruce.connor.amNOSPAMgmail.com>
+;; 
+;;     let-alist: New package
+;; 
+
+
+(provide 'let-alist)
+
+;;; let-alist.el ends here