make: fix spacing, and a typo in a test

This commit is contained in:
rillig 2022-03-27 18:39:01 +00:00
parent 71457ba882
commit 3b385e4c9c
2 changed files with 7 additions and 7 deletions

View File

@ -1,4 +1,4 @@
# $NetBSD: varmod-match.mk,v 1.7 2022/03/03 20:20:23 rillig Exp $
# $NetBSD: varmod-match.mk,v 1.8 2022/03/27 18:39:01 rillig Exp $
#
# Tests for the :M variable modifier, which filters words that match the
# given pattern.
@ -119,8 +119,8 @@ ${:U*}= asterisk
.endif
# [^a-c67]
# matches a single character, except for 'a', 'b', 'c', '8' or
# '9'
# matches a single character, except for 'a', 'b', 'c', '6' or
# '7'
.if ${ A B C a b c d 5 6 7 8 [a-c] [a] :L:M[^a-c67]} != "A B C d 5 8"
. error
.endif

View File

@ -1,4 +1,4 @@
/* $NetBSD: var.c,v 1.1018 2022/03/26 14:34:07 rillig Exp $ */
/* $NetBSD: var.c,v 1.1019 2022/03/27 18:39:01 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1993
@ -139,7 +139,7 @@
#include "metachar.h"
/* "@(#)var.c 8.3 (Berkeley) 3/19/94" */
MAKE_RCSID("$NetBSD: var.c,v 1.1018 2022/03/26 14:34:07 rillig Exp $");
MAKE_RCSID("$NetBSD: var.c,v 1.1019 2022/03/27 18:39:01 rillig Exp $");
/*
* Variables are defined using one of the VAR=value assignments. Their
@ -476,7 +476,7 @@ ValueDescription(const char *value)
{
if (value[0] == '\0')
return "# (empty)";
if (ch_isspace(value[strlen(value)-1]))
if (ch_isspace(value[strlen(value) - 1]))
return "# (ends with space)";
return "";
}
@ -3221,7 +3221,7 @@ ApplyModifier_Words(const char **pp, ModChain *ch)
/* Normal case: select the words described by first and last. */
Expr_SetValueOwn(expr,
VarSelectWords(Expr_Str(expr), first, last,
ch->sep, ch->oneBigWord));
ch->sep, ch->oneBigWord));
ok:
FStr_Done(&festr);