2015-08-17 56 views
0

我不知道我做了什麼,但突然間,當我在Aquamacs中執行各種操作時,出現一堆錯誤。例如,當我嘗試打開一個C文件時,出現錯誤「File mode specification error:(wrong-type-argument number-or-marker-p nil)」。如果打開調試器,我會得到以下堆棧跟蹤:Aquamacs文件模式規範錯誤

Debugger entered--Lisp error: (wrong-type-argument number-or-marker-p nil) 
    define-abbrev([## 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 else 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...] "else" "else" c-electric-continued-statement 0 t) 
    apply(define-abbrev [## 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 else 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...] ("else" "else" c-electric-continued-statement 0 t)) 
    byte-code("\302\303\304 @\305\"#\207" [table defs apply define-abbrev append (t)] 6) 
    c-define-abbrev-table(c-mode-abbrev-table (("else" "else" c-electric-continued-statement 0) ("while" "while" c-electric-continued-statement 0)) "Abbreviation table used in c-mode buffers.") 
    c-mode() 
    set-auto-mode-0(c-mode nil) 
    set-auto-mode() 
    normal-mode(t) 
    after-find-file(nil t) 
    find-file-noselect-1(#<buffer EventLog.h> "~/repositories/ghc/rts/eventlog/EventLog.h" nil nil "~/repositories/ghc/rts/eventlog/EventLog.h" (12100462 16777218)) 
    find-file-noselect("~/.cabal/../repositories/ghc/rts/eventlog/EventLog.h" nil nil t) 
    find-file("~/.cabal/../repositories/ghc/rts/eventlog/EventLog.h" t) 
    call-interactively(find-file nil nil) 
    command-execute(find-file) 

任何人對此有何看法?

+0

'M-x emacs-version'說什麼? (我在問,因爲[此消息](https://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01273.html)表明這是在23.1中修復的。) – legoscia

+0

Aquamacs 3.2 GNU 2014-11-07(Aquamacs-3.2)的Emacs 24.4.51.2(x86_64-apple-darwin14.0.0,NS apple-appkit-1343.14) – Matt

回答

0

好的,所以我不知道發生了什麼,但我能夠通過做一個(非常)乾淨的重新安裝來解決它。我首先刪除了應用程序文件夾,然後爲文件系統中的任何Aquamacs文件夾執行遞歸查找。

find . -regex "Aquamacs.*" -maxdepth 5 

能夠給我所有這些文件的清單。有一堆緩存的首選項目錄在卸載應用程序時不會被刪除。我第一次嘗試使用App Cleaner,它無法獲得所有這些。我刪除了每個Aquamacs相關的目錄並重新安裝後,它工作得很好。