all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#33973: Multi-line C++ raw string literal font lock is broken
@ 2019-01-04  5:21 Li Feng
       [not found] ` <mailman.6748.1546581187.1284.bug-gnu-emacs@gnu.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Li Feng @ 2019-01-04  5:21 UTC (permalink / raw)
  To: 33973

[-- Attachment #1: Type: text/plain, Size: 3228 bytes --]

Write a multi-line raw string literal in c++-mode, and font
lock doesn't show the correct syntax highlighting. Sample code:

const char* s1 = R"foo(
Hello
World
)foo";

const char* s2 = R"(
Hello
World
)";

In GNU Emacs 27.0.50 (build 1, x86_64-apple-darwin17.7.0, NS appkit-1561.60
Version 10.13.6 (Build 17G65))
 of 2019-01-04 built on C02WP42JHTD6
Repository revision: fe4922cbf01fa9161ffa142fc70972098d48186f
Repository branch: master
Windowing system distributor 'Apple', version 10.3.1561
System Description:  Mac OS X 10.13.6

Recent messages:
Mark set
next-line: End of buffer [15 times]
Mark set
next-line: End of buffer [14 times]
Saving file /Users/lifeng/Desktop/test.cpp...
Wrote /Users/lifeng/Desktop/test.cpp
Mark set [6 times]
Undo!
Making completion list...
user-error: End of history; no default available [2 times]

Configured using:
 'configure --with-modules'

Configured features:
RSVG GLIB NOTIFY KQUEUE ACL GNUTLS LIBXML2 ZLIB TOOLKIT_SCROLL_BARS NS
MODULES THREADS JSON LCMS2 GMP

Important settings:
  value of $LANG: en_AU.UTF-8
  locale-coding-system: utf-8-unix

Major mode: C++//l

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
  abbrev-mode: t

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message rmc puny seq byte-opt gv
bytecomp byte-compile cconv dired dired-loaddefs format-spec rfc822 mml
mml-sec password-cache epa derived epg epg-config gnus-util rmail
rmail-loaddefs time-date mm-decode mm-bodies mm-encode mail-parse
rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045
ietf-drums mm-util mail-prsvr mail-utils thingatpt cc-mode cc-fonts
easymenu cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars
cc-defs cl-loaddefs cl-lib elec-pair tooltip eldoc electric uniquify
ediff-hook vc-hooks lisp-float-type mwheel term/ns-win ns-win
ucs-normalize mule-util term/common-win tool-bar dnd fontset image
regexp-opt fringe tabulated-list replace newcomment text-mode elisp-mode
lisp-mode prog-mode register page menu-bar rfn-eshadow isearch timer
select scroll-bar mouse jit-lock font-lock syntax facemenu font-core
term/tty-colors frame 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 minibuffer cl-preloaded nadvice loaddefs
button faces cus-face macroexp files text-properties overlay sha1 md5
base64 format env code-pages mule custom widget hashtable-print-readable
backquote threads kqueue cocoa ns lcms2 multi-tty make-network-process
emacs)

Memory information:
((conses 16 227619 13680)
 (symbols 48 22362 1)
 (strings 32 35100 1976)
 (string-bytes 1 1069317)
 (vectors 16 37950)
 (vector-slots 8 757597 18070)
 (floats 8 47 152)
 (intervals 56 520 0)
 (buffers 992 14))

[-- Attachment #2: Type: text/html, Size: 3645 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#33973: Multi-line C++ raw string literal font lock is broken
       [not found] ` <mailman.6748.1546581187.1284.bug-gnu-emacs@gnu.org>
@ 2019-01-07 15:25   ` Alan Mackenzie
  2021-09-01  9:15     ` Lars Ingebrigtsen
  0 siblings, 1 reply; 3+ messages in thread
From: Alan Mackenzie @ 2019-01-07 15:25 UTC (permalink / raw)
  To: Li Feng; +Cc: 33973

Hello, Li.

In article <mailman.6748.1546581187.1284.bug-gnu-emacs@gnu.org> you wrote:
> [-- text/plain, encoding 7bit, charset: UTF-8, 102 lines --]

> Write a multi-line raw string literal in c++-mode, and font
> lock doesn't show the correct syntax highlighting. Sample code:

> const char* s1 = R"foo(
> Hello
> World
> )foo";

> const char* s2 = R"(
> Hello
> World
> )";

Yes.  Thank you for reporting this bug.  I'm working on fixing it, and
hope to commit a patch to master sometime in the next few days.

> In GNU Emacs 27.0.50 (build 1, x86_64-apple-darwin17.7.0, NS appkit-1561.60
> Version 10.13.6 (Build 17G65))
>  of 2019-01-04 built on C02WP42JHTD6
> Repository revision: fe4922cbf01fa9161ffa142fc70972098d48186f
> Repository branch: master
> Windowing system distributor 'Apple', version 10.3.1561
> System Description:  Mac OS X 10.13.6

[ .... ]

-- 
Alan Mackenzie (Nuremberg, Germany).






^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#33973: Multi-line C++ raw string literal font lock is broken
  2019-01-07 15:25   ` Alan Mackenzie
@ 2021-09-01  9:15     ` Lars Ingebrigtsen
  0 siblings, 0 replies; 3+ messages in thread
From: Lars Ingebrigtsen @ 2021-09-01  9:15 UTC (permalink / raw)
  To: Alan Mackenzie; +Cc: Li Feng, 33973

[-- Attachment #1: Type: text/plain, Size: 537 bytes --]

Alan Mackenzie <acm@muc.de> writes:

>> Write a multi-line raw string literal in c++-mode, and font
>> lock doesn't show the correct syntax highlighting. Sample code:
>
>> const char* s1 = R"foo(
>> Hello
>> World
>> )foo";
>
>> const char* s2 = R"(
>> Hello
>> World
>> )";
>
> Yes.  Thank you for reporting this bug.  I'm working on fixing it, and
> hope to commit a patch to master sometime in the next few days.

(I'm going through old bug reports that unfortunately weren't resolved
at the time.)

Testing this in Emacs 28, I get:


[-- Attachment #2: Type: image/png, Size: 11467 bytes --]

[-- Attachment #3: Type: text/plain, Size: 333 bytes --]


Which...  I think is correct?  So I guess this has been fixed in the
years since this was reported, and I'm closing this bug report.  (If
there's still bugs in this area, please respond to the debbugs address
and we'll reopen.)

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-09-01  9:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-01-04  5:21 bug#33973: Multi-line C++ raw string literal font lock is broken Li Feng
     [not found] ` <mailman.6748.1546581187.1284.bug-gnu-emacs@gnu.org>
2019-01-07 15:25   ` Alan Mackenzie
2021-09-01  9:15     ` Lars Ingebrigtsen

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.