Subject: Re: bug#68477: 29.1; bibtex-braced-string-syntax-table should handle non-ASCII parentheses

From: Eli Zaretskii <[email-masked]>
Date: Thu, 02 Jan 2025 22:13:51 +0200

> Cc: [email-masked]
> From: Roland Winkler <[email-masked]>
> Date: Thu, 02 Jan 2025 13:09:41 -0600
> 
> > Note that the `abstract` field has a single opening FULLWIDTH OPENING
> > PARENTHESIS (code point #xff08), not the (ASCII) LEFT
> > PARENTHESIS. bibtex-mode cannot parse this entry correctly. (Do, e.g.,
> > `C-c C-c` on the entry, bound to `bibtex-clean-entry` and you'll get a
> > user error "Syntactically incorrect BibTeX entry starts here".)
> >
> > If the field contains an unmatched LEFT PARENTHESIS (code point #x28),
> > bibtex-mode has no trouble parsing the entry.
> >
> > This is ultimately due to the fact that
> > `bibtex-braced-string-syntax-table` contains an entry for the ASCII
> > parentheses, setting them to 'punctuation', but there is no similar
> > entry for non-ASCII parentheses.
> 
> I only discovered this bug report now.  I believe utf-8 defines lots of
> pairs of parentheses to which this bug report applies.  Is there a
> generic way to modify the syntax of "all" pairs of parentheses (except
> the curly brackets "{" and "}") to punctuation so that parsing will
> ignore such unpaired parentheses?

Emacs should already set up the syntax of those characters, see
char-syntax.  Is that what you were looking for?