mirror of
https://github.com/masscollaborationlabs/emacs.git
synced 2025-07-08 21:29:37 +00:00

The functions make-process and make-network-process have many keyword args and it's easy to misspell some of them. Use a compiler macro to warn about some possible mistakes. * lisp/emacs-lisp/bytecomp.el (bytecomp--check-keyword-args): New helper. (make-process, make-network-process): Define a compiler macro that performs some checks but doesn't anything else. * test/lisp/emacs-lisp/bytecomp-tests.el: Add some tests. * test/lisp/emacs-lisp/bytecomp-resources/: (warn-make-process-missing-keyword-arg.el, warn-make-process-missing-keyword-value.el, warn-make-process-repeated-keyword-arg.el, warn-make-process-unknown-keyword-arg.el): New test files
4 lines
127 B
EmacsLisp
4 lines
127 B
EmacsLisp
;;; -*- lexical-binding: t -*-
|
|
(defun foo ()
|
|
(make-process :name "ls" :command "ls"
|
|
:coding-system 'binary))
|