From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Augusto Stoffel Newsgroups: gmane.emacs.devel Subject: Re: Explain a bit more on how to configure language server in Eglot's manual' Date: Thu, 09 Mar 2023 09:28:12 +0100 Message-ID: <87sfeee3c3.fsf@gmail.com> References: Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="28523"; mail-complaints-to="usenet@ciao.gmane.io" Cc: arstoffel@gmail.com, casouri@gmail.com, emacs-devel@gnu.org, stephen_leake@stephe-leake.org To: joaotavora@gmail.com Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Mar 09 09:28:47 2023 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1paBdm-0007Ft-Lk for ged-emacs-devel@m.gmane-mx.org; Thu, 09 Mar 2023 09:28:46 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1paBdN-0005Kx-Ml; Thu, 09 Mar 2023 03:28:21 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1paBdL-0005Kg-ID for emacs-devel@gnu.org; Thu, 09 Mar 2023 03:28:19 -0500 Original-Received: from mail-ed1-x531.google.com ([2a00:1450:4864:20::531]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1paBdJ-0003Bl-W2 for emacs-devel@gnu.org; Thu, 09 Mar 2023 03:28:19 -0500 Original-Received: by mail-ed1-x531.google.com with SMTP id cy23so3723137edb.12 for ; Thu, 09 Mar 2023 00:28:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1678350494; h=mime-version:message-id:date:in-reply-to:subject:cc:to:from:from:to :cc:subject:date:message-id:reply-to; bh=ukxRAk+GmApxsSUSxm6HpZmHs0SzDln4Sj8P9VufUIk=; b=abn7XDWqAngxqQFJrRn4HfpREZxiNIxN/cL9hq37glq9GlQapttKvPk0cSgrsfGrKC cHrFl88/w4dSTQLt5llANdRJUL8MzPzfOKCGCZ5eL477y+mL5b41ep3D0GMrMDBGNLAm 8sZyiLxuluVXNOiA36bkkXWXhHqMXIJBt1YdothwpRaz1ZrIf1tCvY1nnCTtwxhCfCz3 iKzUuDZ/VW0kFXwYsYIJtTZYZW4Bx7RbQ4l7Itfoqq0+N0fu2SuUdxkDFt5r36IJQSDP jth7DhK1qDr5kwdTrlULZepy33qwmisdogpcOlzBXVo2CHHCDhjimOSAJ3EuJxpuk9vI BP4w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678350494; h=mime-version:message-id:date:in-reply-to:subject:cc:to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=ukxRAk+GmApxsSUSxm6HpZmHs0SzDln4Sj8P9VufUIk=; b=RK+PlJu1lltfBfzFkX+HaBcNent8pun0kz15fDhDiIp8H7ELqwQ6zKX+7QZGdTzRaq ceLHrMq5woTYg/sXDVnAIruQrbwixFMKmzGdZjdZVLUK7018x3F7tzjeLyYfcSeNarc9 EoJvP9b7dPDdbX3igv3fxfxtTMjEAGvKjVHtBkYQorjwdGlcwXM/PW1t2MOl2MWvISFl zFC/3Sn+mvBzeQXK6chX9YNyryhMqpWH+Mg9O937fZUePvpBw1Lj9+WERWic8BOTGlSy jpDuCDW6QZBHHx2ozrnUdAKXWa9QmI9XeY1RozcUdDZrTmllT2KdB9klu13Bm0mjvX95 PamQ== X-Gm-Message-State: AO0yUKUYxOlYSXUnDvCVxTh8buN7CD9/7faY6QziSfM+w4Ke9pTPChpX S9M6kTN5mBm5L8LAbPUaLGY= X-Google-Smtp-Source: AK7set9wVHu0yahbqndWeN0S5d98EHcAjDfUklPSrJ6yHcenY3raxTPiNPx3YV4LCDYxmaXiViXQQw== X-Received: by 2002:a17:907:8b11:b0:8b1:749f:b2c0 with SMTP id sz17-20020a1709078b1100b008b1749fb2c0mr21390845ejc.74.1678350494315; Thu, 09 Mar 2023 00:28:14 -0800 (PST) Original-Received: from ars3 ([2a02:8109:8ac0:56d0::8b3a]) by smtp.gmail.com with ESMTPSA id q27-20020a17090622db00b008b1787ce722sm8493792eja.152.2023.03.09.00.28.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 09 Mar 2023 00:28:13 -0800 (PST) In-Reply-To: Received-SPF: pass client-ip=2a00:1450:4864:20::531; envelope-from=arstoffel@gmail.com; helo=mail-ed1-x531.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:304171 Archived-At: >> The utility function belongs to map.el. It is called `assoc-in` in >> Clojure. > > Yuri presented some pretty good arguments about how that would > be a bad idea. Also, not a Clojure expert, but AFAIK that > function doesn't take dotted notation strings as input. Good, let's not do it then. In any case, just for fun and because it could be useful in some other situation, I proposed in bug#62068 the suitable additions to map.el. Then the conversion we were discussing looks like this: (defun dotted-to-nested (items) (seq-reduce (pcase-lambda (map `(,ks . ,v)) (map-insert-in map (mapcar 'intern (string-split ks "\\.")) v 'plist)) (map-pairs items) nil)) (dotted-to-nested '("a.b.c" 1 "a.b.d" 2 "a.e.f" 3)) => (a (e (f 3) b (d 2 c 1))) [modulo bug#62067]