From 68fbcbd6207819b9d653362e66236ea5e04e9b7d Mon Sep 17 00:00:00 2001 From: "Basil L. Contovounesios" Date: Fri, 24 Jun 2022 12:39:02 +0300 Subject: [PATCH] Reduce memory footprint of eglot--{} * eglot.el (eglot--{}): Specify smallest hash table :size, to spare ~1KiB according to memory-report-object-size. See also https://github.com/joaotavora/eglot/pull/315. GitHub-reference: per https://github.com/joaotavora/eglot/issues/978 --- lisp/progmodes/eglot.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el index 53ae6fae3c3..bde4a23f8e4 100644 --- a/lisp/progmodes/eglot.el +++ b/lisp/progmodes/eglot.el @@ -368,7 +368,7 @@ This can be useful when using docker to run a language server.") `((1 . eglot-diagnostic-tag-unnecessary-face) (2 . eglot-diagnostic-tag-deprecated-face))) -(defconst eglot--{} (make-hash-table) "The empty JSON object.") +(defconst eglot--{} (make-hash-table :size 1) "The empty JSON object.") (defun eglot--executable-find (command &optional remote) "Like Emacs 27's `executable-find', ignore REMOTE on Emacs 26." -- 2.39.5