Index: tools/clang-format/clang-format.el =================================================================== --- tools/clang-format/clang-format.el +++ tools/clang-format/clang-format.el @@ -147,16 +147,15 @@ ;; always use ‘utf-8-unix’ and ignore the buffer coding system. (default-process-coding-system '(utf-8-unix . utf-8-unix))) (unwind-protect - (let ((status (apply 'call-process-region - (append `(nil nil ,clang-format-executable - nil (,temp-buffer ,temp-file) nil) - '("-output-replacements-xml") - (if assume-file - `("-assume-filename" ,assume-file) nil) - `("-style" ,style - "-offset" ,(number-to-string file-start) - "-length" ,(number-to-string (- file-end file-start)) - "-cursor" ,(number-to-string cursor))))) + (let ((status (apply #'call-process-region + nil nil clang-format-executable + nil `(,temp-buffer ,temp-file) nil + `("-output-replacements-xml" + ,@(and assume-file (list "-assume-filename" assume-file)) + "-style" ,style + "-offset" ,(number-to-string file-start) + "-length" ,(number-to-string (- file-end file-start)) + "-cursor" ,(number-to-string cursor)))) (stderr (with-temp-buffer (unless (zerop (cadr (insert-file-contents temp-file))) (insert ": "))