bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#39911: 27.0.90; error in wisent-total-conflicts if no source filenam


From: Neil Okamoto
Subject: bug#39911: 27.0.90; error in wisent-total-conflicts if no source filename
Date: Wed, 4 Mar 2020 09:23:36 -0800


This bug was detected while running docker.el and other packages that depend on tablist [1].  Tablist is an extension of tabulated-list-mode that provides the ability to filter the tabulated list via an _expression_ language. I am not the author of tablist however the author is aware of this issue.

In 27.0.90, tablist is now giving an error when entering its _expression_ editor.  In the debugger I traced the error to wisent-total-conflicts in lisp/cedet/semantic/wisent/comp.el line 2273, in commit 390b4bc1e25fe691548d7ec982eb2f7027fe26a3 [2].  That commit introduced a mechanism to ignore “expected conflicts” via a symbol whose name is constructed on the fly like this:

    (format "wisent-%s--expected-conflicts"
                                     (replace-regexp-in-string "\\.el$" "" src)

However, this code doesn’t handle the case where the filename “src” is nil.

To reproduce the issue, compile a grammar like this:

    (require 'semantic/wisent/comp)
    (require 'semantic/wisent/wisent)

    (defvar tablist-filter-wisent-grammar
      '(
        ;; terminals
        ;; Use lowercase for better looking error messages.
        (operand unary-operator binary-operator or and not)

        ;; terminal associativity & precedence
        ((left binary-operator)
         (left unary-operator)
         (left or)
         (left and)
         (left not))

        ;; rules
        (filter-or-empty
         ((nil))
         ((?\( ?\)) nil)
         ((filter) $1))
        (filter
         ((operand) $1) ;;Named filter
         ((operand binary-operator operand) `(,(intern $2) ,$1 ,$3))
         ((unary-operator operand) `(,(intern $1) ,$2))
         ((not filter) `(not ,$2))
         ((filter and filter) `(and ,$1 ,$3))
         ((filter or filter) `(or ,$1 ,$3))
         ((?\( filter ?\)) $2))))

    (wisent-compile-grammar tablist-filter-wisent-grammar)

    ;; error => “
replace-regexp-in-string: Wrong type argument: arrayp, nil”


Thank you,
Neil

[1] https://github.com/politza/tablist
[2] http://git.savannah.gnu.org/cgit/emacs.git/commit/?h=emacs-27&id=390b4bc1e25fe691548d7ec982eb2f7027fe26a3



reply via email to

[Prev in Thread] Current Thread [Next in Thread]