Function: treesit--call-process-signal

treesit--call-process-signal is a byte-compiled function defined in treesit.el.gz.

Signature

(treesit--call-process-signal &rest ARGS)

Documentation

Run call-process with ARGS.

If it returns anything but 0, signal an error. Use the buffer content as signal data, and erase buffer afterwards.

Source Code

;; Defined in /usr/src/emacs/lisp/treesit.el.gz
(defun treesit--call-process-signal (&rest args)
  "Run `call-process' with ARGS.
If it returns anything but 0, signal an error.  Use the buffer
content as signal data, and erase buffer afterwards."
  (unless (eq 0 (apply #'call-process args))
    (signal 'treesit-error (list "Command:"
                                 (string-join (cons (car args)
                                                    (nthcdr 4 args))
                                              " ")
                                 "Error output:"
                                 (buffer-string)))
    (erase-buffer)))