🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.emacs.bug
Article #1775

Re: c-mode can't handle { at beg. of line inside string

#1775
From: Joe Wells
Date: Mon, 18 Dec 1989 03:01
28 lines
1185 bytes
In article <8912160114.AA00605@paris.Berkeley.EDU> mcgrath%paris.Berkeley.EDU@GINGER.BERKELEY.EDU (Roland McGrath) writes:

   Put this:

   foo()
   {
     bar("hi\
   {...}",

   in a buffer in c-mode, put point at the end of the buffer, and hit LFD.

Well, I sympathize with you, but this is a documented weakness.
Fortunately in the C language, "{" is equivalent to "\{", so you can get
around this:

foo()
{
  bar("hi\
\{...}",

Enjoy,

-- 
Joe Wells <jbw@bucsf.bu.edu>
jbw%bucsf.bu.edu@bu-it.bu.edu
...!harvard!bu-cs!bucsf!jbw
(617) 375-6893
200-202 Bay State Rd., Box 1486, Boston, MA 02215, USA
Technical Details
Message-ID: <JBW.89Dec17220131@bucsf.bu.edu>
Path: arc1-ca.pugleaf.net!utzoo!mnetor!tmsoft!torsqnt!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!bu-cs!bucsb!bucsf!jbw
References: <8912160114.AA00605@paris.Berkeley.EDU>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!mnetor!tmsoft!torsqnt!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!bu-cs!bucsb!bucsf!jbw
From: jbw@bucsf.bu.edu (Joe Wells)
Newsgroups: gnu.emacs.bug
Subject: Re: c-mode can't handle { at beg. of line inside string
Message-ID: <JBW.89Dec17220131@bucsf.bu.edu>
Date: 18 Dec 89 03:01:31 GMT
References: <8912160114.AA00605@paris.Berkeley.EDU>
Distribution: gnu
Organization: Boston University Computer Science Department
Lines: 28
In-reply-to: mcgrath%paris.Berkeley.EDU@GINGER.BERKELEY.EDU's message of 16 Dec 89 01:13:59 GMT