From ba24c12f6a782bbb636c4161d7a2c5a11fc79ece Mon Sep 17 00:00:00 2001 From: rillig Date: Sat, 19 Dec 2020 13:30:00 +0000 Subject: [PATCH] make(1): reduce debugging details in Parse_SetInput The address of readMoreArg is hardly useful when stepping through this part of the code, therefore omit it. Instead of mentioning the exact function names of the data source, describe them in words, which helps especially in the case of .for loops. --- usr.bin/make/parse.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/usr.bin/make/parse.c b/usr.bin/make/parse.c index 94dd519aa5ab..3e04f96d05e5 100644 --- a/usr.bin/make/parse.c +++ b/usr.bin/make/parse.c @@ -1,4 +1,4 @@ -/* $NetBSD: parse.c,v 1.496 2020/12/19 13:16:25 rillig Exp $ */ +/* $NetBSD: parse.c,v 1.497 2020/12/19 13:30:00 rillig Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1993 @@ -117,7 +117,7 @@ #include "pathnames.h" /* "@(#)parse.c 8.3 (Berkeley) 3/19/94" */ -MAKE_RCSID("$NetBSD: parse.c,v 1.496 2020/12/19 13:16:25 rillig Exp $"); +MAKE_RCSID("$NetBSD: parse.c,v 1.497 2020/12/19 13:30:00 rillig Exp $"); /* types and constants */ @@ -2442,13 +2442,9 @@ Parse_SetInput(const char *name, int lineno, int fd, else ParseTrackInput(name); - if (DEBUG(PARSE)) { - const char *caller = readMore == loadedfile_readMore - ? "loadedfile" : "other"; - debug_printf( - "%s: file %s, line %d, fd %d, readMore %s, readMoreArg %p\n", - __func__, name, lineno, fd, caller, readMoreArg); - } + DEBUG3(PARSE, "Parse_SetInput: %s %s, line %d\n", + readMore == loadedfile_readMore ? "file" : ".for loop in", + name, lineno); if (fd == -1 && readMore == NULL) /* sanity */