]> git.eshelyaron.com Git - emacs.git/commitdiff
* emacs-lisp/cl-lib.el (cl--old-struct-type-of): Accept `[]'
authorStefan Monnier <monnier@iro.umontreal.ca>
Tue, 18 Jul 2017 16:01:27 +0000 (12:01 -0400)
committerStefan Monnier <monnier@iro.umontreal.ca>
Tue, 18 Jul 2017 16:01:27 +0000 (12:01 -0400)
lisp/emacs-lisp/cl-lib.el

index c183852fd3ba2abab43149d53daaff564c5a9a9e..6ac08d839b19430c90e0089167d31e1d31d65d93 100644 (file)
@@ -631,7 +631,7 @@ If ALIST is non-nil, the new pairs are prepended to it."
   (require 'cl-seq))
 
 (defun cl--old-struct-type-of (orig-fun object)
-  (or (and (vectorp object)
+  (or (and (vectorp object) (> (length object) 0)
            (let ((tag (aref object 0)))
              (when (and (symbolp tag)
                         (string-prefix-p "cl-struct-" (symbol-name tag)))