From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Tom Gillespie Newsgroups: gmane.emacs.devel Subject: Font lock in org+elisp confused with ?\[ Date: Wed, 31 Mar 2021 22:43:12 -0700 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="6544"; mail-complaints-to="usenet@ciao.gmane.io" To: arthur.miller@live.com, emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Apr 01 07:45:07 2021 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 1lRq8h-0001Zx-5u for ged-emacs-devel@m.gmane-mx.org; Thu, 01 Apr 2021 07:45:07 +0200 Original-Received: from localhost ([::1]:47526 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lRq8g-000399-30 for ged-emacs-devel@m.gmane-mx.org; Thu, 01 Apr 2021 01:45:06 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:33420) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lRq74-0002eq-1E for emacs-devel@gnu.org; Thu, 01 Apr 2021 01:43:26 -0400 Original-Received: from mail-wr1-x430.google.com ([2a00:1450:4864:20::430]:44902) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lRq72-00075m-99 for emacs-devel@gnu.org; Thu, 01 Apr 2021 01:43:25 -0400 Original-Received: by mail-wr1-x430.google.com with SMTP id c8so508595wrq.11 for ; Wed, 31 Mar 2021 22:43:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=8Tbrj4b6arbziSfTUZv50yTKj/Ti4sIoKpbFkZr10mM=; b=HGdLh3KQwg1kaxmC7fpleduZCbyTdTagL32mTAbAcY8YX7Gt7xojhtv9O8/zw4q+JH EqwQ5s31/3PT8ngBSb6YoQlaWMNZAircaRo/t8bKFtrc8iMJAc/FNsXmi/d9tbfRavJZ PoItB25GaBoufhk7BwftDFXKf6kxwQRN094EwyAbmAk4guXdoPJ5LvdILawoFgZMWA2C adn5yq7YPj+Q43il95KgAga05qMk8aZG1oQOnA5NcT378JmdxP9fn/I8yrMZhWSIr5nE 4azrTWy3C2ntrxRab44kZUUOtQ5YZfHtXQt77MPcwQC3wprZWXakGFDEKJ3gDy1SYbIp oF/g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=8Tbrj4b6arbziSfTUZv50yTKj/Ti4sIoKpbFkZr10mM=; b=JDwWMwFOuuiy2wdRDJjTfI6c5dIDSw7lzv/WxK+pO8SAi2yMOBpw+IFFn9C3NzmyWw 7uFljjHq06RvJqAsfVwQ1jbWBG2e2co8Gf+vvLxGLtI01eflhFw3nDfD2oo+EJuXSNUh u1vxXcttAVP3eWZiMOmoRmiYS7sSXgWxsspti7mVd/mDEsDq2QumqxErwygHsKwfghvX BChJ6i01NpPckRkMN71xavAlOcsFb/A1yz1cd7S2BYXgBN1TVL8NGQ8B3RAO2LL/SPKV vXPU/BjQC+r4NIfTTVn+gdWJJjUYp78r8OEQIdeP24Mjt3anFnV5V5HoDE726jmxxxND ZMiQ== X-Gm-Message-State: AOAM5319BpYhyq8VwqV8SAmhFePVAlI8TBtqWAbFdESdtPWZWiIJb6i1 xHcFjWhCfVkpHHl94UQ1qEfEmdXjJwtVFY05YRw= X-Google-Smtp-Source: ABdhPJxxDDy6Hr4WDPi3xmrA4xYHz4mfmVXubRuJYLGU5geVt9k8vwreug5dmU1RgauZzDIgVaKTLyizRyloARceKPI= X-Received: by 2002:adf:f843:: with SMTP id d3mr7340527wrq.55.1617255802863; Wed, 31 Mar 2021 22:43:22 -0700 (PDT) Received-SPF: pass client-ip=2a00:1450:4864:20::430; envelope-from=tgbugs@gmail.com; helo=mail-wr1-x430.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.23 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" Xref: news.gmane.io gmane.emacs.devel:267234 Archived-At: This is a known issue with org babel blocks. It is due to the fact that org babel translates the font locking for the language but not the syntax propertization. Another frequent cause is the bash case statement. The end result is that unmatched parens leak out from the babel blocks and wreak havoc elsewhere in the org file unless you balance out the parens e.g. in a comment. I have a hacked fix for this, but it has horrible performance, especially with line numbers enabled. I think that a proper solution would run arbitrary syntax propertization on subsets of a buffer without having to continually check where those subsets start or end. Best, Tom