aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuanma Barranquero2007-10-15 17:39:35 +0000
committerJuanma Barranquero2007-10-15 17:39:35 +0000
commited5117041521183b6ac0403bddbb232c8e1e9907 (patch)
treebc8ed77bd58ebbe409997c15683027fe2c365c03
parenta1547e7b3939144615befdb1357e30fe5dd593ea (diff)
downloademacs-ed5117041521183b6ac0403bddbb232c8e1e9907.tar.gz
emacs-ed5117041521183b6ac0403bddbb232c8e1e9907.zip
(filesets-alist-get): Use `let' rather than `let*'.
(filesets-ormap, filesets-sort-case-sensitive-flag, filesets-remake-shortcut, filesets-ingroup-collect-files): Fix typos in docstrings. (filesets-data-get-name, filesets-data-get-data, filesets-data-set, filesets-cmd-query-replace-getargs, filesets-ingroup-collect, filesets-find-or-display-file): Doc fixes.
-rw-r--r--lisp/ChangeLog10
-rw-r--r--lisp/filesets.el37
2 files changed, 28 insertions, 19 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 4c19ecffffa..79733686e16 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,13 @@
12007-10-15 Juanma Barranquero <lekktu@gmail.com>
2
3 * filesets.el (filesets-alist-get): Use `let' rather than `let*'.
4 (filesets-ormap, filesets-sort-case-sensitive-flag)
5 (filesets-remake-shortcut, filesets-ingroup-collect-files):
6 Fix typos in docstrings.
7 (filesets-data-get-name, filesets-data-get-data)
8 (filesets-data-set, filesets-cmd-query-replace-getargs)
9 (filesets-ingroup-collect, filesets-find-or-display-file): Doc fixes.
10
12007-10-15 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> 112007-10-15 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
2 12
3 * term/mac-win.el: Don't require url when compiling, as url-type is 13 * term/mac-win.el: Don't require url when compiling, as url-type is
diff --git a/lisp/filesets.el b/lisp/filesets.el
index 5554e26bc06..d4ec52fb650 100644
--- a/lisp/filesets.el
+++ b/lisp/filesets.el
@@ -162,7 +162,7 @@ COND-FN takes one argument: the current element."
162 (setq rv (append rv (list elt))))))) 162 (setq rv (append rv (list elt)))))))
163 163
164(defun filesets-ormap (fsom-pred lst) 164(defun filesets-ormap (fsom-pred lst)
165 "Return the tail of FSOM-LST for the head of which FSOM-PRED is non-nil." 165 "Return the tail of LST for the head of which FSOM-PRED is non-nil."
166 (let ((fsom-lst lst) 166 (let ((fsom-lst lst)
167 (fsom-rv nil)) 167 (fsom-rv nil))
168 (while (and (not (null fsom-lst)) 168 (while (and (not (null fsom-lst))
@@ -539,7 +539,7 @@ computer environments."
539 :group 'filesets) 539 :group 'filesets)
540 540
541(defcustom filesets-sort-case-sensitive-flag t 541(defcustom filesets-sort-case-sensitive-flag t
542 "*Non-nil means sorting of the filesete menu is case sensitive." 542 "*Non-nil means sorting of the filesets menu is case sensitive."
543 :set (function filesets-set-default) 543 :set (function filesets-set-default)
544 :type 'boolean 544 :type 'boolean
545 :group 'filesets) 545 :group 'filesets)
@@ -1096,7 +1096,6 @@ non-nil, remove all directory names."
1096(defun filesets-conditional-sort (lst &optional access-fn simply-do-it) 1096(defun filesets-conditional-sort (lst &optional access-fn simply-do-it)
1097 "Return a sorted copy of LST, LST being a list of strings. 1097 "Return a sorted copy of LST, LST being a list of strings.
1098If `filesets-sort-menu-flag' is nil, return LST itself. 1098If `filesets-sort-menu-flag' is nil, return LST itself.
1099
1100ACCESS-FN ... function to get the string value of LST's elements. 1099ACCESS-FN ... function to get the string value of LST's elements.
1101 1100
1102If SIMPLY-DO-IT is non-nil, the list is sorted regardless of 1101If SIMPLY-DO-IT is non-nil, the list is sorted regardless of
@@ -1368,7 +1367,7 @@ not be opened."
1368 (find-file file))) 1367 (find-file file)))
1369 1368
1370(defun filesets-find-or-display-file (&optional file viewer) 1369(defun filesets-find-or-display-file (&optional file viewer)
1371 "Visit FILE using an external viewer or open it in an Emacs buffer." 1370 "Visit FILE using an external VIEWER or open it in an Emacs buffer."
1372 (interactive) 1371 (interactive)
1373 (let* ((file (or file 1372 (let* ((file (or file
1374 (read-file-name "Find file: " nil nil viewer))) 1373 (read-file-name "Find file: " nil nil viewer)))
@@ -1419,24 +1418,24 @@ not be opened."
1419 something))) 1418 something)))
1420 1419
1421(defun filesets-data-get-name (entry) 1420(defun filesets-data-get-name (entry)
1422 "Access to `filesets-data'. Get the entry's name" 1421 "Access to `filesets-data'. Get the ENTRY's name."
1423 (car entry)) 1422 (car entry))
1424 1423
1425(defun filesets-data-get-data (entry) 1424(defun filesets-data-get-data (entry)
1426 "Access to `filesets-data'. Get the entry's data section" 1425 "Access to `filesets-data'. Get the ENTRY's data section."
1427 (cdr entry)) 1426 (cdr entry))
1428 1427
1429(defun filesets-alist-get (alist key &optional default carp) 1428(defun filesets-alist-get (alist key &optional default carp)
1430 "Get KEY's value in the association list ALIST. 1429 "Get KEY's value in the association list ALIST.
1431Return DEFAULT if not found. Return (car VALUE) if CARP is non-nil." 1430Return DEFAULT if not found. Return (car VALUE) if CARP is non-nil."
1432 (let* ((elt (assoc key alist))) 1431 (let ((elt (assoc key alist)))
1433 (cond 1432 (cond
1434 (elt 1433 (elt
1435 (if carp 1434 (if carp
1436 (cadr elt) 1435 (cadr elt)
1437 (cdr elt))) 1436 (cdr elt)))
1438 (default default) 1437 (default default)
1439 (t nil)))) 1438 (t nil))))
1440 1439
1441(defun filesets-data-get (entry key &optional default carp) 1440(defun filesets-data-get (entry key &optional default carp)
1442 "Extract the value for KEY in the data part of fileset ENTRY. 1441 "Extract the value for KEY in the data part of fileset ENTRY.
@@ -1444,7 +1443,7 @@ Return DEFAULT if not found. Return (car VALUE) if CARP is non-nil."
1444 (filesets-alist-get (filesets-data-get-data entry) key default carp)) 1443 (filesets-alist-get (filesets-data-get-data entry) key default carp))
1445 1444
1446(defun filesets-data-set (entry key value) 1445(defun filesets-data-set (entry key value)
1447 "Set the value for KEY in the data part of fileset ENTRY." 1446 "Set the VALUE for KEY in the data part of fileset ENTRY."
1448 (let* ((alist (filesets-data-get-data entry)) 1447 (let* ((alist (filesets-data-get-data entry))
1449 (elt (assoc key alist))) 1448 (elt (assoc key alist)))
1450 (if elt 1449 (if elt
@@ -1671,9 +1670,9 @@ Replace <file-name> or <<file-name>> with filename."
1671 filesets-commands))) 1670 filesets-commands)))
1672 1671
1673 1672
1674;;; sampe commands 1673;;; sample commands
1675(defun filesets-cmd-query-replace-getargs () 1674(defun filesets-cmd-query-replace-getargs ()
1676 "Get arguments for `filesets-cmd-query-replace'." 1675 "Get arguments for `query-replace' and `query-replace-regexp'."
1677 (let* ((from-string (read-string "Filesets query replace: " 1676 (let* ((from-string (read-string "Filesets query replace: "
1678 "" 1677 ""
1679 'query-replace-history)) 1678 'query-replace-history))
@@ -1880,7 +1879,7 @@ User will be queried, if no fileset name is provided."
1880 (browse-url filesets-homepage)) 1879 (browse-url filesets-homepage))
1881 1880
1882(defun filesets-remake-shortcut (count submenu) 1881(defun filesets-remake-shortcut (count submenu)
1883 "Remake a submenus shortcut when wrapping long menus." 1882 "Remake a submenu's shortcut when wrapping long menus."
1884 (let* ((name (concat (filesets-get-shortcut count) 1883 (let* ((name (concat (filesets-get-shortcut count)
1885 (substring (elt submenu 0) 2)))) 1884 (substring (elt submenu 0) 2))))
1886 (if (listp submenu) 1885 (if (listp submenu)
@@ -2037,7 +2036,7 @@ LOOKUP-NAME is used as lookup name for retrieving fileset specific settings."
2037 (lax-plist-put filesets-ingroup-cache emaster this)))) 2036 (lax-plist-put filesets-ingroup-cache emaster this))))
2038 2037
2039(defun filesets-ingroup-collect-files (fs &optional remdupl-flag master depth) 2038(defun filesets-ingroup-collect-files (fs &optional remdupl-flag master depth)
2040 "Helper function for `filesets-ingroup-collect'. Collect file names." 2039 "Helper function for `filesets-ingroup-collect'. Collect file names."
2041 (let* ((master (or master 2040 (let* ((master (or master
2042 (filesets-entry-get-master fs))) 2041 (filesets-entry-get-master fs)))
2043 (remdupl-flag (or remdupl-flag 2042 (remdupl-flag (or remdupl-flag
@@ -2151,7 +2150,7 @@ FS is a fileset's name. FLIST is a list returned by
2151 `([,nm (filesets-file-open nil ',master ',fsn)]))))))))) 2150 `([,nm (filesets-file-open nil ',master ',fsn)])))))))))
2152 2151
2153(defun filesets-ingroup-collect (fs remdupl-flag master &optional depth) 2152(defun filesets-ingroup-collect (fs remdupl-flag master &optional depth)
2154 "Collect names of included files & build submenu." 2153 "Collect names of included files and build submenu."
2155 (filesets-ingroup-cache-put master nil) 2154 (filesets-ingroup-cache-put master nil)
2156 (filesets-message 2 "Filesets: parsing %S" master) 2155 (filesets-message 2 "Filesets: parsing %S" master)
2157 (filesets-ingroup-collect-build-menu 2156 (filesets-ingroup-collect-build-menu