zsh-workers
 help / color / mirror / code / Atom feed
From: Oliver Kiddle <okiddle@yahoo.co.uk>
To: Zsh hackers list <zsh-workers@sunsite.dk>
Subject: Re: 4.2.0-pre-3; HP-UX
Date: Wed, 10 Mar 2004 18:43:04 +0100	[thread overview]
Message-ID: <3855.1078940584@trentino.logica.co.uk> (raw)
In-Reply-To: <6316.1078935662@csr.com>

Peter wrote:
> 
> But they compile OK?  Error messages?  Might simply be missing library
> functions.

Yes, compiles Ok with no error messages. make check just hangs and
without being able to load the completion library, it doesn't seem
particularly usable. When I get some time, I'll investigate further.

> > This warning comes up a lot for many times in different places:
> > Warning 952: "compctl.c", line 608 # Conversion of 'const char *' to 'char *'
> >     loses 'const'.
> >                         *argv = "" - 1;
> >                         ^^^^^^
> > 
> > What is that code trying to do? Isn't that taking the address of a
> > constant string. Seems dodgy to me.
> 
> Harmless.  We're not strict about `const'.  It would be nice to be,
> but when you start going down that road you find you have to change
> *everything*.  It's a hack so that argv[1] contains a NULL --- not a
> particularly nice one.

The warnings are spewed out for this on Tru64 too. Is there not
something we could change it to so that it is both more readable and
doesn't create warnings. Perhaps using a macro to wrap around any nasty
hacks or by having a single null-string variable. I'm happy to go
through all the instances changing them.

> >                 *DM, *DO, *ED, *EI, *K0, *K1, *K2, *K3, *K4, *K5, *K6,
> > ---------------------^
> 
> It's probably defined somewhere else.  We could rename those arguments.

Line 212 in zsh.h. Patch below renames our DO to DOLOOP which solves
the problem. It then builds and all tests pass (on Tru64 5.1). They
have a Tru64 4.0 machine too so I can also try that. And they have gcc
in /usr/local so that can also be tried.

> Frankly, I'm hanged if I personally am going to go round changing all
> the version numbers again, but I don't mind releasing 4.2.0 and warning
> users of HP-UX and AIX they may want to wait.  Nobody expects versions
> ending in `0' to work anyway.

Sounds like a fair enough plan.

Oliver

Index: Src/hashtable.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/hashtable.c,v
retrieving revision 1.16
diff -u -r1.16 hashtable.c
--- Src/hashtable.c	29 Oct 2003 19:17:30 -0000	1.16
+++ Src/hashtable.c	10 Mar 2004 17:04:45 -0000
@@ -925,7 +925,7 @@
     {NULL, "}", 0, OUTBRACE},
     {NULL, "case", 0, CASE},
     {NULL, "coproc", 0, COPROC},
-    {NULL, "do", 0, DO},
+    {NULL, "do", 0, DOLOOP},
     {NULL, "done", 0, DONE},
     {NULL, "elif", 0, ELIF},
     {NULL, "else", 0, ELSE},
Index: Src/lex.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/lex.c,v
retrieving revision 1.27
diff -u -r1.27 lex.c
--- Src/lex.c	3 Sep 2003 10:15:36 -0000	1.27
+++ Src/lex.c	10 Mar 2004 17:04:45 -0000
@@ -393,7 +393,7 @@
     case BAR:
     case BARAMP:
     case INOUTPAR:
-    case DO:
+    case DOLOOP:
     case THEN:
     case ELIF:
     case ELSE:
Index: Src/parse.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/parse.c,v
retrieving revision 1.41
diff -u -r1.41 parse.c
--- Src/parse.c	29 Oct 2003 19:17:30 -0000	1.41
+++ Src/parse.c	10 Mar 2004 17:04:45 -0000
@@ -978,7 +978,7 @@
     incmdpos = 1;
     while (tok == SEPER)
 	yylex();
-    if (tok == DO) {
+    if (tok == DOLOOP) {
 	yylex();
 	par_save_list(complex);
 	if (tok != DONE)
@@ -1260,7 +1260,7 @@
     incmdpos = 1;
     while (tok == SEPER)
 	yylex();
-    if (tok == DO) {
+    if (tok == DOLOOP) {
 	yylex();
 	par_save_list(complex);
 	if (tok != DONE)
@@ -1304,7 +1304,7 @@
     yylex();
     while (tok == SEPER)
 	yylex();
-    if (tok == DO) {
+    if (tok == DOLOOP) {
 	yylex();
 	par_save_list(complex);
 	if (tok != DONE)
Index: Src/zsh.h
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/zsh.h,v
retrieving revision 1.53
diff -u -r1.53 zsh.h
--- Src/zsh.h	6 Mar 2004 00:23:03 -0000	1.53
+++ Src/zsh.h	10 Mar 2004 17:04:45 -0000
@@ -209,7 +209,7 @@
     OUTBRACE,   /* }         */
     CASE,	/* case      */
     COPROC,	/* coproc    */
-    DO,		/* do        */
+    DOLOOP,	/* do        */
     DONE,	/* done      */ /* 45 */
     ELIF,	/* elif      */
     ELSE,	/* else      */
Index: Src/Zle/zle_tricky.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/Zle/zle_tricky.c,v
retrieving revision 1.42
diff -u -r1.42 zle_tricky.c
--- Src/Zle/zle_tricky.c	8 Mar 2004 11:44:14 -0000	1.42
+++ Src/Zle/zle_tricky.c	10 Mar 2004 17:04:45 -0000
@@ -1105,7 +1105,7 @@
 	/* We reached the end. */
 	if (tok == ENDINPUT)
 	    break;
-	if ((ins && (tok == DO || tok == SEPER)) ||
+	if ((ins && (tok == DOLOOP || tok == SEPER)) ||
 	    (ins == 2 && i == 2) || (ins == 3 && i == 3) ||
 	    tok == BAR    || tok == AMPER     ||
 	    tok == BARAMP || tok == AMPERBANG ||


  reply	other threads:[~2004-03-10 17:43 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20681.1078496403@csr.com>
2004-03-08 19:34 ` Paul Ackersviller
2004-03-09 12:17   ` Peter Stephenson
2004-03-09 15:25     ` Bart Schaefer
2004-03-09 16:00       ` Clint Adams
2004-03-09 16:06         ` Bart Schaefer
2004-03-09 16:11           ` Clint Adams
2004-03-10 16:05             ` Oliver Kiddle
2004-03-10 16:21               ` Peter Stephenson
2004-03-10 17:43                 ` Oliver Kiddle [this message]
2004-03-10 18:08                 ` Oliver Kiddle
2004-03-10  4:27     ` Paul Ackersviller
2004-03-10 11:01       ` Peter Stephenson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3855.1078940584@trentino.logica.co.uk \
    --to=okiddle@yahoo.co.uk \
    --cc=zsh-workers@sunsite.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).