Module Name: src
Committed By: rillig
Date: Mon Sep 7 19:48:09 UTC 2020
Modified Files:
src/usr.bin/make: dir.c
src/usr.bin/make/unit-tests: dir.mk
Log Message:
make(1): document that nested braces work as expected now
To generate a diff of this commit:
cvs rdiff -u -r1.136 -r1.137 src/usr.bin/make/dir.c
cvs rdiff -u -r1.4 -r1.5 src/usr.bin/make/unit-tests/dir.mk
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/usr.bin/make/dir.c
diff -u src/usr.bin/make/dir.c:1.136 src/usr.bin/make/dir.c:1.137
--- src/usr.bin/make/dir.c:1.136 Sat Sep 5 13:55:08 2020
+++ src/usr.bin/make/dir.c Mon Sep 7 19:48:08 2020
@@ -1,4 +1,4 @@
-/* $NetBSD: dir.c,v 1.136 2020/09/05 13:55:08 rillig Exp $ */
+/* $NetBSD: dir.c,v 1.137 2020/09/07 19:48:08 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990 The Regents of the University of California.
@@ -70,14 +70,14 @@
*/
#ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: dir.c,v 1.136 2020/09/05 13:55:08 rillig Exp $";
+static char rcsid[] = "$NetBSD: dir.c,v 1.137 2020/09/07 19:48:08 rillig Exp $";
#else
#include <sys/cdefs.h>
#ifndef lint
#if 0
static char sccsid[] = "@(#)dir.c 8.2 (Berkeley) 1/2/94";
#else
-__RCSID("$NetBSD: dir.c,v 1.136 2020/09/05 13:55:08 rillig Exp $");
+__RCSID("$NetBSD: dir.c,v 1.137 2020/09/07 19:48:08 rillig Exp $");
#endif
#endif /* not lint */
#endif
@@ -256,7 +256,6 @@ static Hash_Table mtimes;
static Hash_Table lmtimes; /* same as mtimes but for lstat */
-static void DirExpandCurly(const char *, const char *, Lst, Lst);
static void DirExpandInt(const char *, Lst, Lst);
static int DirPrintWord(void *, void *);
static int DirPrintDir(void *, void *);
Index: src/usr.bin/make/unit-tests/dir.mk
diff -u src/usr.bin/make/unit-tests/dir.mk:1.4 src/usr.bin/make/unit-tests/dir.mk:1.5
--- src/usr.bin/make/unit-tests/dir.mk:1.4 Fri Jul 31 20:16:21 2020
+++ src/usr.bin/make/unit-tests/dir.mk Mon Sep 7 19:48:08 2020
@@ -1,8 +1,9 @@
-# $NetBSD: dir.mk,v 1.4 2020/07/31 20:16:21 rillig Exp $
+# $NetBSD: dir.mk,v 1.5 2020/09/07 19:48:08 rillig Exp $
#
# Tests for dir.c.
# Dependency lines may use braces for expansion.
+# See DirExpandCurly for the implementation.
all: {one,two,three}
one:
@@ -22,7 +23,8 @@ five:
six:
@echo 6
-# But nested braces don't work.
+# Nested braces work as expected since 2020-07-31 19:06 UTC.
+# They had been broken at least since 2003-01-01, probably even longer.
all: {{thi,fou}r,fif}teen
thirteen: