From owner-svn-src-all@freebsd.org Tue May 22 08:17:56 2018 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 62ECDEEC775; Tue, 22 May 2018 08:17:56 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from mout.gmx.net (mout.gmx.net [212.227.17.21]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "mout.gmx.net", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id CDFE869091; Tue, 22 May 2018 08:17:55 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from freyja.zeit4.iv.bundesimmobilien.de ([87.138.105.249]) by mail.gmx.com (mrgmx103 [212.227.17.168]) with ESMTPSA (Nemesis) id 0LlV4F-1fuNVI2pmh-00bIVf; Tue, 22 May 2018 10:17:43 +0200 Date: Tue, 22 May 2018 10:17:41 +0200 From: "O. Hartmann" To: Cy Schubert Cc: "O. Hartmann" , Jilles Tjoelker , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r334008 - head/bin/sh Message-ID: <20180522101737.52e76c0f@freyja.zeit4.iv.bundesimmobilien.de> In-Reply-To: <201805220445.w4M4jroR019550@slippy.cwsent.com> References: <20180522061339.2149763e@freyja.zeit4.iv.bundesimmobilien.de> <201805220445.w4M4jroR019550@slippy.cwsent.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:TKiYkbTt+cbszP/vzaRhQ06QIw1NRdxDn8rQO3BNGMMAaJO9Lg7 7+cwATscYklriQY9QcrWU8iNstIC5YHbXguyxDP+ufDNNlimhxlW9bkU0zvyNWciBJES6D0 UxIOWjqHeLmcykiqKOHO6FJ7qrtgWFjKrSxaLlh8r8pl/Bc4bM2SVM/NZd4oFserj04O7Cu T1E6QSfq9xDPDI4gQYpCA== X-UI-Out-Filterresults: notjunk:1;V01:K0:53ADJ2p6xHo=:UK2YcpT+KkP/o+afCZl2RH sg6LTx3hOJw9jsBXvtvtKWGERhd+HWD3ZkOjxLXDr6t/S1yQVf9hORToVsKgd7crJ6XMv08Ir LKT+LltiuFW1rRYgTCruyNiaZEmU1y3bPhx2G8MgiMc4X/XTkxt24UWaKKa+igh2n7b7hK0a/ CtH9kscLt5wkZqJlLS7qE7w0B8ZWiwzHx88ndHhZRfbJOOBwbo6rSp2+to1i/LnceEu4pKTJZ OMZnYqfTHNEUf0w88UnRXRYZtVgbFtIqbWkLuOoovSoZFoo3+dShhFl33OAVoLDghm8Amil/6 LcvHnS/tyCmUltSVZou4rcRNSDbLSkLQDVubReCsfHd9fxWQf6mRrMoj+wxfQ8WcN6AYxpIpV qS5igyfuNuYdkSiHpSs1Ge+KAcJo4J0HA0hQNROfZUMFhiET5bF+ykOyqUmPMI672eOri9aaJ yrtCF1UoWp6qxHilsKc8uwR+qdMHK9tSgAVysQpbdINgdqjswA98VlCGRlgyPXceZ9m3Bz1aE eU2xkeAWUMbJkXwLc9bLepTv5zlDca+8eye2nmPapdll52h82iHdE5RgxLUU52gpK+oV9xc+x 4mVBcs2V7sfp6/yvWIIxtG2DnUxUxLHy4kvJpDOZLJ8+ZShBGFYrc8mVh6Mele/N6QEF98f1p UIT5Rnz1gjxY2SC4dDjGjbS2QNJyMd/dDwMDla7V31KOPjWmYiWNHDwjnllY+2Y8YxWRQySz2 QYiw3n/kaEQ5VQCLOaJV+TaeCu3qsZMRM0SD5blU+Ma1PVbnpIti5gBHjzA5bNsLrFnNG2js6 nNoDdAc X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 May 2018 08:17:56 -0000 On Mon, 21 May 2018 21:45:53 -0700 Cy Schubert wrote: > In message <20180522061339.2149763e@freyja.zeit4.iv.bundesimmobilien.de> > , "O. H > artmann" writes: > > On Mon, 21 May 2018 21:52:48 +0000 (UTC) > > Jilles Tjoelker wrote: > > > > > Author: jilles > > > Date: Mon May 21 21:52:48 2018 > > > New Revision: 334008 > > > URL: https://svnweb.freebsd.org/changeset/base/334008 > > > > > > Log: > > > sh: Split CNL syntax category to avoid a check on state[level].syntax > > > > > > No functional change is intended. > > > > > > Modified: > > > head/bin/sh/mksyntax.c > > > head/bin/sh/parser.c > > > > > > Modified: head/bin/sh/mksyntax.c > > > =========================================================================== > > === > > > --- head/bin/sh/mksyntax.c Mon May 21 21:44:47 2018 > > > (r334007) +++ head/bin/sh/mksyntax.c Mon May 21 21:52:48 > > > 2018 (r334008) @@ -65,6 +65,7 @@ struct synclass { > > > static const struct synclass synclass[] = { > > > { "CWORD", "character is nothing special" }, > > > { "CNL", "newline character" }, > > > + { "CQNL", "newline character in quotes" }, > > > { "CBACK", "a backslash character" }, > > > { "CSBACK", "a backslash character in single quotes" }, > > > { "CSQUOTE", "single quote" }, > > > @@ -185,7 +186,7 @@ main(int argc __unused, char **argv __unused) > > > fputs("\n/* syntax table used when in double quotes */\n", > > > cfile); init("dqsyntax"); > > > add_default(); > > > - add("\n", "CNL"); > > > + add("\n", "CQNL"); > > > add("\\", "CBACK"); > > > add("\"", "CENDQUOTE"); > > > add("`", "CBQUOTE"); > > > @@ -198,7 +199,7 @@ main(int argc __unused, char **argv __unused) > > > fputs("\n/* syntax table used when in single quotes */\n", > > > cfile); init("sqsyntax"); > > > add_default(); > > > - add("\n", "CNL"); > > > + add("\n", "CQNL"); > > > add("\\", "CSBACK"); > > > add("'", "CENDQUOTE"); > > > /* ':/' for tilde expansion, '-^]' for [a\-x] pattern ranges */ > > > @@ -208,7 +209,7 @@ main(int argc __unused, char **argv __unused) > > > fputs("\n/* syntax table used when in arithmetic */\n", cfile); > > > init("arisyntax"); > > > add_default(); > > > - add("\n", "CNL"); > > > + add("\n", "CQNL"); > > > add("\\", "CBACK"); > > > add("`", "CBQUOTE"); > > > add("\"", "CIGN"); > > > > > > Modified: head/bin/sh/parser.c > > > =========================================================================== > > === > > > --- head/bin/sh/parser.c Mon May 21 21:44:47 2018 (r334007) > > > +++ head/bin/sh/parser.c Mon May 21 21:52:48 2018 (r334008) > > > @@ -1434,9 +1434,10 @@ readtoken1(int firstc, char const *initialsyntax, > > > co > > ns > > > > > > switch(synentry) { > > > case CNL: /* '\n' */ > > > - if (level == 0 && > > > - state[level].syntax == BASESYNTAX) > > > + if (level == 0) > > > goto endword; /* exit > > > outer loop */ > > > + /* FALLTHROUGH */ > > > + case CQNL: > > > USTPUTC(c, out); > > > plinno++; > > > if (doprompt) > > > _______________________________________________ > > > svn-src-head@freebsd.org mailing list > > > https://lists.freebsd.org/mailman/listinfo/svn-src-head > > > To unsubscribe, send any mail to "svn-src-head-unsubscribe@freebsd.org" > > > > > > Have this been tested? Doesn't compile for me: > > > > [...] > > Building /usr/obj/usr/src/amd64.amd64/kerberos5/libexec/hprop/hprop > > --- all_subdir_rescue --- > > --- parser.o --- > > /usr/src/bin/sh/parser.c:1440:9: error: use of undeclared identifier 'CQNL' > > case CQNL: > > ^ > > --- all_subdir_gnu --- > > Building /usr/obj/usr/src/amd64.amd64/gnu/usr.bin/gdb/libgdb/amd64bsd-nat.o > > --- all_subdir_rescue --- > > 1 error generated. > > *** [parser.o] Error code 1 > > > > make[6]: stopped in /usr/src/bin/sh > > > > CQNL is defined in /usr/obj/opt/src/svn-current/amd64.amd64/bin/sh/synta > x.h, generated by mksyntax. > > slippy$ ag -s CQNL /export/obj/opt/src/svn-current/amd64.amd64/bin/sh/*. > h > /export/obj/opt/src/svn-current/amd64.amd64/bin/sh/syntax.h > 11:#define CQNL 2 /* newline character in quotes */ > slippy$ > > Remove the file if it's not defined in your syntax.h. > > Just out of interest, do you use meta mode? I think such a question is of common interest if errors/bugs like that occur: Yes, I use/compile world/kernel with META mode. > > Thanks, kind regards, oh