[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#10494: 24.0.92; Syntax table and non-ASCII character interaction
From: |
Eli Zaretskii |
Subject: |
bug#10494: 24.0.92; Syntax table and non-ASCII character interaction |
Date: |
Sat, 13 Aug 2016 17:55:14 +0300 |
> Date: Sat, 13 Aug 2016 17:31:48 +0300
> From: Eli Zaretskii <eliz@gnu.org>
> Cc: 10494@debbugs.gnu.org, aaronecay@gmail.com
>
> > From: npostavs@users.sourceforge.net
> > Cc: 10494@debbugs.gnu.org, aaronecay@gmail.com
> > Date: Sat, 13 Aug 2016 10:19:34 -0400
> >
> > >> (modify-syntax-entry ?’ "w" text-mode-syntax-table)
> > >> (defconst my-text-char-script-table
> > >> (let ((table (copy-sequence char-script-table)))
> > >> (aset table ?’ 'latin)
> > >> table))
> > >>
> > >> (defun my-text-mode-hook ()
> > >> (set (make-local-variable 'char-script-table)
> > >> my-text-char-script-table))
> > >> (add-hook 'text-mode-hook 'my-text-mode-hook)
> > >
> > > Are you sure nothing in text-mode will ever want to use \s_ in any
> > > regexp?
> >
> > Did you mean \> (word boundary) or \s. (punctation)? \s_ doesn't match
> > ’ regardless because its syntax class is punctuation, not symbol.
>
> Sorry, I guess I was thinking of \cl. It will not match ’, although
> it might be expected.
>
> Anyway, my point is that these char-tables should really be treated as
> read-only by Lisp applications.
Btw, some believe that using ’ as an apostrophe is wrong. They say
U+02BC should be used instead; see, for example, this discussion:
http://www.unicode.org/mail-arch/unicode-ml/y2015-m06/0047.html
That character already is word-constituent.
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, npostavs, 2016/08/10
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, Eli Zaretskii, 2016/08/11
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, npostavs, 2016/08/12
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, Eli Zaretskii, 2016/08/13
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, npostavs, 2016/08/13
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, Eli Zaretskii, 2016/08/13
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, npostavs, 2016/08/13
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, Eli Zaretskii, 2016/08/13
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction,
Eli Zaretskii <=
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, npostavs, 2016/08/13
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, Eli Zaretskii, 2016/08/13
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, npostavs, 2016/08/13
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, Eli Zaretskii, 2016/08/13
- bug#10494: 24.0.92; Syntax table and non-ASCII character interaction, npostavs, 2016/08/13