Paste number 45613: add-hook doesnt work?

Paste number 45613: add-hook doesnt work?
Pasted by: taid
When:4 years, 6 months ago
Share:Tweet this! | http://paste.lisp.org/+Z71
Channel:#XEmacs
Paste contents:
Raw Source | XML | Display As
This is the added hook:

(add-hook 'comint-mode-hook (lambda () ((message "pocho"))))

This is the backtrace:

Debugger entered--Lisp error: (invalid-function (message "pocho"))
  ((message "pocho"))
  (lambda nil ((message "pocho")))()
  run-hooks((lambda nil ((message "pocho"))))
  comint-mode()
  make-comint-1(#<buffer "*inferior-erlang*"> "erl" nil "-newshell" "-env" "TERM" "vt100")
  apply(make-comint-1 #<buffer "*inferior-erlang*"> "erl" nil ("-newshell" "-env" "TERM" "vt100"))
  make-comint("inferior-erlang" "erl" nil "-newshell" "-env" "TERM" "vt100")
  apply(make-comint "inferior-erlang" "erl" nil ("-newshell" "-env" "TERM" "vt100"))
  inferior-erlang()
  #<compiled-function nil "...(93)" [inferior-erlang-buffer dir noext tmpvar end tmpvar2 save-some-buffers inferior-erlang-running-p inferior-erlang error "Error starting inferior Erlang shell" file-name-directory buffer-file-name 0 -4 "Tmp7236" "Tmp8742" nil inferior-erlang-display-buffer inferior-erlang-wait-prompt inferior-erlang-send-command format "c(\"%s\", [{outdir, \"%s\"}])." "f(%s), {ok, %s} = file:get_cwd(), file:set_cwd(\"%s\"), %s = c(\"%s\"), file:set_cwd(%s), f(%s), %s." erlang-compile-use-outdir compilation-error-list compilation-parsing-end compilation-last-buffer] 11 ("/usr/share/xemacs21/site-lisp/erlang/erlang.elc" . 136541) nil>()
  call-interactively(inferior-erlang-compile)
  #<compiled-function nil "...(4)" [erlang-compile-function call-interactively] 2 ("/usr/share/xemacs21/site-lisp/erlang/erlang.elc" . 125816) nil>()
  call-interactively(erlang-compile)

This paste has no annotations.

Colorize as:
Show Line Numbers

Lisppaste pastes can be made by anyone at any time. Imagine a fearsomely comprehensive disclaimer of liability. Now fear, comprehensively.