Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 15 Sep 1996 15:30:03 -0700 (PDT)
From:      Steve Price <sprice@hiwaay.net>
To:        freebsd-bugs
Subject:   Re: bin/1230: make ``.for'' loops iterate backwards
Message-ID:  <199609152230.PAA18935@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/1230; it has been noted by GNATS.

From: Steve Price <sprice@hiwaay.net>
To: archie@whistle.com
Cc: hackers@freebsd.org, FreeBSD-gnats-submit@freebsd.org
Subject: Re: bin/1230: make ``.for'' loops iterate backwards
	
Date: Sun, 15 Sep 1996 17:18:40 -0500

 Attached is patch that fixes the problem pointed out in
 bin/1230.
 
 steve[~]$ cat Makefile
 ORIG= a b c
 
 .for VAR in a b c
 LIST+=  ${VAR}
 .endfor
 
 default:
         @echo ${LIST}
 ^D
 steve[~]$ make
 a b c
 steve[~]$ 
 
 
 Regards,
 
 Steve
 
 
 Index: for.c
 ===================================================================
 RCS file: /u/FreeBSD/cvs/src/usr.bin/make/for.c,v
 retrieving revision 1.3
 diff -u -r1.3 for.c
 --- for.c	1995/05/30 06:31:52	1.3
 +++ for.c	1996/09/14 00:26:03
 @@ -174,7 +174,7 @@
  #define ADDWORD() \
  	Buf_AddBytes(buf, ptr - wrd, (Byte *) wrd), \
  	Buf_AddByte(buf, (Byte) '\0'), \
 -	Lst_AtEnd(forLst, (ClientData) Buf_GetAll(buf, &varlen)), \
 +	Lst_AtFront(forLst, (ClientData) Buf_GetAll(buf, &varlen)), \
  	Buf_Destroy(buf, FALSE)
  
  	for (ptr = sub; *ptr && isspace((unsigned char) *ptr); ptr++)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199609152230.PAA18935>