summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2026-03-18 11:03:33 -0700
committerGitHub <noreply@github.com>2026-03-18 11:03:33 -0700
commit5faab28916603bb324d9faba057021ce028ca847 (patch)
tree7ca4a55e3c0a78fd7dac150210c55f728f5f9747
parent9cc1e804395342bc028800d87c5318ccd97d6071 (diff)
parent9919943f1337e66dd40fcc39782998a15f99539e (diff)
Merge pull request #199 from jwiegley/fix-issue-165-encoding-commentsexternals/async
Clean up encoding comments after utf-8-auto fix
-rw-r--r--async.el18
1 files changed, 8 insertions, 10 deletions
diff --git a/async.el b/async.el
index cad9270..34b11bf 100644
--- a/async.el
+++ b/async.el
@@ -283,15 +283,13 @@ is used."
(move-marker async-read-marker (point)))))))
(defun async--receive-sexp (&optional stream)
- ;; FIXME: Why use `utf-8-auto' instead of `utf-8-unix'? This is
- ;; a communication channel over which we have complete control,
- ;; so we get to choose exactly which encoding and EOL we use, isn't
- ;; it?
- ;; UPDATE: We use now `utf-8-emacs-unix' instead of `utf-8-auto' as
- ;; recommended in bug#165.
+ ;; We use `utf-8-emacs-unix' for the communication channel between
+ ;; parent and child Emacs processes. This encoding can represent any
+ ;; character that Emacs is capable of processing and gives us full
+ ;; control over the EOL format. (See bug#165)
(let ((sexp (decode-coding-string (base64-decode-string (read stream))
'utf-8-emacs-unix))
- ;; Parent expects UTF-8 encoded text.
+ ;; Parent expects utf-8-emacs-unix encoded text.
(coding-system-for-write 'utf-8-emacs-unix))
(if async-debug
(message "Received sexp {{{%s}}}" (pp-to-string sexp)))
@@ -323,8 +321,8 @@ is used."
(defun async-batch-invoke ()
"Called from the child Emacs process' command line."
- ;; Make sure 'message' and 'prin1' encode stuff in UTF-8, as parent
- ;; process expects.
+ ;; Make sure 'message' and 'prin1' encode stuff in utf-8-emacs-unix,
+ ;; as parent process expects.
(let ((coding-system-for-write 'utf-8-emacs-unix)
(args-left command-line-args-left))
(setq async-in-child-emacs t
@@ -559,7 +557,7 @@ passed to FINISH-FUNC). Call `async-get' on such a future always
returns nil. It can still be useful, however, as an argument to
`async-ready' or `async-wait'."
(let ((sexp start-func)
- ;; Subordinate Emacs will send text encoded in UTF-8.
+ ;; Subordinate Emacs will send text encoded in utf-8-emacs-unix.
(coding-system-for-read 'utf-8-emacs-unix))
(setq async--procvar
(apply 'async-start-process