Module Name: src
Committed By: rillig
Date: Tue Sep 1 17:38:26 UTC 2020
Modified Files:
src/usr.bin/make: buf.h parse.c
Log Message:
make(1): clean up documentation in buf.h, and redundant include files
To generate a diff of this commit:
cvs rdiff -u -r1.27 -r1.28 src/usr.bin/make/buf.h
cvs rdiff -u -r1.274 -r1.275 src/usr.bin/make/parse.c
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/buf.h
diff -u src/usr.bin/make/buf.h:1.27 src/usr.bin/make/buf.h:1.28
--- src/usr.bin/make/buf.h:1.27 Mon Aug 31 16:42:10 2020
+++ src/usr.bin/make/buf.h Tue Sep 1 17:38:26 2020
@@ -1,4 +1,4 @@
-/* $NetBSD: buf.h,v 1.27 2020/08/31 16:42:10 rillig Exp $ */
+/* $NetBSD: buf.h,v 1.28 2020/09/01 17:38:26 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990 The Regents of the University of California.
@@ -72,20 +72,18 @@
* from: @(#)buf.h 8.1 (Berkeley) 6/6/93
*/
-/*-
- * buf.h --
- * Automatically growing null-terminated buffer of characters.
- */
+/* Automatically growing null-terminated buffers of characters. */
#ifndef MAKE_BUF_H
#define MAKE_BUF_H
#include <stddef.h>
+/* An automatically growing null-terminated buffer of characters. */
typedef struct Buffer {
size_t size; /* Allocated size of the buffer, including the null */
size_t count; /* Number of bytes in buffer, excluding the null */
- char *buffer; /* The buffer itself (null-terminated) */
+ char *buffer; /* The buffer itself (always null-terminated) */
} Buffer;
/* If we aren't on NetBSD, __predict_false() might not be defined. */
Index: src/usr.bin/make/parse.c
diff -u src/usr.bin/make/parse.c:1.274 src/usr.bin/make/parse.c:1.275
--- src/usr.bin/make/parse.c:1.274 Sun Aug 30 11:15:05 2020
+++ src/usr.bin/make/parse.c Tue Sep 1 17:38:26 2020
@@ -1,4 +1,4 @@
-/* $NetBSD: parse.c,v 1.274 2020/08/30 11:15:05 rillig Exp $ */
+/* $NetBSD: parse.c,v 1.275 2020/09/01 17:38:26 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1993
@@ -69,14 +69,14 @@
*/
#ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: parse.c,v 1.274 2020/08/30 11:15:05 rillig Exp $";
+static char rcsid[] = "$NetBSD: parse.c,v 1.275 2020/09/01 17:38:26 rillig Exp $";
#else
#include <sys/cdefs.h>
#ifndef lint
#if 0
static char sccsid[] = "@(#)parse.c 8.3 (Berkeley) 3/19/94";
#else
-__RCSID("$NetBSD: parse.c,v 1.274 2020/08/30 11:15:05 rillig Exp $");
+__RCSID("$NetBSD: parse.c,v 1.275 2020/09/01 17:38:26 rillig Exp $");
#endif
#endif /* not lint */
#endif
@@ -139,10 +139,8 @@ __RCSID("$NetBSD: parse.c,v 1.274 2020/0
#endif
#include "make.h"
-#include "hash.h"
#include "dir.h"
#include "job.h"
-#include "buf.h"
#include "pathnames.h"
/* types and constants */