Commit 988b91ce authored by Eric M. Ludlam's avatar Eric M. Ludlam Committed by Chong Yidong

Fix to semantic-lex-spp-table-write-slot-value (Bug#6324).

* cedet/semantic/lex-spp.el
(semantic-lex-spp-table-write-slot-value): Instead of erroring on
invalid values during save, just save a nil (Bug#6324).
parent 78edd3b7
2010-06-03 Eric Ludlam <zappo@gnu.org>
* cedet/semantic/lex-spp.el
(semantic-lex-spp-table-write-slot-value): Instead of erroring on
invalid values during save, just save a nil (Bug#6324).
2010-06-03 Glenn Morris <rgm@gnu.org>
* desktop.el (desktop-clear-preserve-buffers):
......
......@@ -1121,37 +1121,31 @@ The VALUE is a spp lexical table."
(prin1 (car sym))
(let* ((first (car (cdr sym)))
(rest (cdr sym)))
(when (not (listp first))
(error "Error in macro \"%s\"" (car sym)))
(when (eq (car first) 'spp-arg-list)
(princ " ")
(prin1 first)
(setq rest (cdr rest))
)
(when rest
(princ " . ")
(let ((len (length (cdr rest))))
(cond ((< len 2)
(condition-case nil
(prin1 rest)
(error
(princ "nil ;; Error writing macro\n"))))
((< len semantic-lex-spp-macro-max-length-to-save)
(princ "\n ")
(condition-case nil
(prin1 rest)
(error
(princ "nil ;; Error writing macro\n ")))
)
(t ;; Too Long!
(princ "nil ;; Too Long!\n ")
))))
)
(princ ")\n ")
)
(princ ")\n"))
)
(if (not (listp first))
(insert "nil ;; bogus macro found.\n")
(when (eq (car first) 'spp-arg-list)
(princ " ")
(prin1 first)
(setq rest (cdr rest)))
(when rest
(princ " . ")
(let ((len (length (cdr rest))))
(cond ((< len 2)
(condition-case nil
(prin1 rest)
(error
(princ "nil ;; Error writing macro\n"))))
((< len semantic-lex-spp-macro-max-length-to-save)
(princ "\n ")
(condition-case nil
(prin1 rest)
(error
(princ "nil ;; Error writing macro\n "))))
(t ;; Too Long!
(princ "nil ;; Too Long!\n ")))))))
(princ ")\n "))
(princ ")\n")))
;;; MACRO TABLE DEBUG
;;
......
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