From: mvar <mvar.40k@gmail.com>
To: 44465@debbugs.gnu.org
Subject: bug#44465: 28.0.50; tcl-mode mismatched parenthesis for nested [strings]
Date: Thu, 05 Nov 2020 14:35:24 +0200 [thread overview]
Message-ID: <87eel8asmr.fsf@cnu407c2zx.nsn-intra.net> (raw)
After the applied fix in #39277, font locking fails in the following case:
set a "Testing: [split "192.168.1.1/24" "/"] address"
the last bracket ] reports "no matching parenthesis found"
this part:
192.168.1.1/24"
is not locked as a string, but "/" is.
Note that the whole argument is evaluated properly by tclsh as a
single contiguous string:
% set a "Testing: [split "192.168.1.1/24" "/"] address"
Testing: 192.168.1.1 24 address
i can't find a way around this behavior even with escaping the double
quotes or using single quotes, because doing that will change how the
argument is evaluated by tcl (array instead of string):
% set b "Testing: [split '192.168.1.1/24' '/'] address"
Testing: {} 192.168.1.1 24 {} address
% set a "Testing: [split \"192.168.1.1/24\" \"/\"] address"
Testing: {} 192.168.1.1 24 {} address
%
--
there's also another case of font locking failure, unrelated
to the #39277 changes:
puts {#test}
anything following # until end of line is locked as comment. But this
one is ok:
puts {a#test}
the inner a#test string is not locked as string but at least the
open-close brackets are marked properly.
In GNU Emacs 28.0.50 (build 4, x86_64-pc-linux-gnu, GTK+ Version 3.22.30, cairo version 1.15.12)
of 2020-11-04 built on localhost
Repository revision: 2668bb47b03230400f94855a58b81a516b46acc5
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12004000
System Description: Red Hat Enterprise Linux Client 7.3 (Maipo)
Configured using:
'configure --prefix=/opt/emacs-28_latest'
Configured features:
XPM JPEG TIFF GIF PNG CAIRO SOUND GPM DBUS GSETTINGS GLIB NOTIFY INOTIFY
LIBSELINUX GNUTLS LIBXML2 FREETYPE HARFBUZZ ZLIB TOOLKIT_SCROLL_BARS
GTK3 X11 XDBE XIM MODULES THREADS JSON PDUMPER
Important settings:
value of $LANG: en_US.utf8
locale-coding-system: utf-8-unix
Major mode: Tcl
Minor modes in effect:
tooltip-mode: t
global-eldoc-mode: t
electric-indent-mode: t
mouse-wheel-mode: t
tool-bar-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
blink-cursor-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
line-number-mode: t
transient-mark-mode: t
Load-path shadows:
None found.
Features:
(shadow sort mail-extr emacsbug message rmc puny dired dired-loaddefs
rfc822 mml mml-sec epa derived epg epg-config gnus-util rmail
rmail-loaddefs auth-source cl-seq eieio eieio-core cl-macs
eieio-loaddefs password-cache json map text-property-search time-date
subr-x seq byte-opt gv bytecomp byte-compile cconv mm-decode mm-bodies
mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader cl-loaddefs
cl-lib sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils
tcl easymenu comint ansi-color ring tooltip eldoc electric uniquify
ediff-hook vc-hooks lisp-float-type mwheel term/x-win x-win
term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe
tabulated-list replace newcomment text-mode elisp-mode lisp-mode
prog-mode register page tab-bar menu-bar rfn-eshadow isearch timer
select scroll-bar mouse jit-lock font-lock syntax facemenu font-core
term/tty-colors frame minibuffer cl-generic cham georgian utf-8-lang
misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms
cp51932 hebrew greek romanian slovak czech european ethiopic indian
cyrillic chinese composite charscript charprop case-table epa-hook
jka-cmpr-hook help simple abbrev obarray cl-preloaded nadvice button
loaddefs faces cus-face macroexp files window text-properties overlay
sha1 md5 base64 format env code-pages mule custom widget
hashtable-print-readable backquote threads dbusbind inotify
dynamic-setting system-font-setting font-render-setting cairo
move-toolbar gtk x-toolkit x multi-tty make-network-process emacs)
Memory information:
((conses 16 56454 12331)
(symbols 48 7150 1)
(strings 32 20173 1496)
(string-bytes 1 673817)
(vectors 16 12950)
(vector-slots 8 174548 13602)
(floats 8 23 28)
(intervals 56 216 0)
(buffers 992 12)
(heap 1024 14579 1030))
next reply other threads:[~2020-11-05 12:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-05 12:35 mvar [this message]
2021-01-22 19:25 ` bug#44465: Still open after applying fix for #44834 and #44083 Anticrisis
2021-08-14 22:22 ` bug#44465: 28.0.50; tcl-mode mismatched parenthesis for nested [strings] mvar
2021-08-14 23:51 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87eel8asmr.fsf@cnu407c2zx.nsn-intra.net \
--to=mvar.40k@gmail.com \
--cc=44465@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).