Function: semantic-tag-make-plist

semantic-tag-make-plist is a byte-compiled function defined in tag.el.gz.

Signature

(semantic-tag-make-plist ARGS)

Documentation

Create a property list with ARGS.

Args is a property list of the form (KEY1 VALUE1 ... KEYN VALUEN). Where KEY is a symbol, and VALUE is the value for that symbol. The return value will be a new property list, with these KEY/VALUE pairs eliminated:

  - KEY associated to nil VALUE.
  - KEY associated to an empty string VALUE.
  - KEY associated to a zero VALUE.

Source Code

;; Defined in /usr/src/emacs/lisp/cedet/semantic/tag.el.gz
;; Is this function still necessary?
(defun semantic-tag-make-plist (args)
  "Create a property list with ARGS.
Args is a property list of the form (KEY1 VALUE1 ... KEYN VALUEN).
Where KEY is a symbol, and VALUE is the value for that symbol.
The return value will be a new property list, with these KEY/VALUE
pairs eliminated:

  - KEY associated to nil VALUE.
  - KEY associated to an empty string VALUE.
  - KEY associated to a zero VALUE."
  (let (plist key val)
    (while args
      (setq key  (car args)
            val  (nth 1 args)
            args (nthcdr 2 args))
      (or (member val '("" nil))
          (and (numberp val) (zerop val))
          (setq plist (cons key (cons val plist)))))
    ;; It is not useful to reverse the new plist.
    plist))