xref: /freebsd/contrib/bmake/unit-tests/lint.mk (revision 1f474190)
1# $NetBSD: lint.mk,v 1.2 2020/08/08 13:00:07 rillig Exp $
2#
3# Demonstrates stricter checks that are only enabled in the lint mode,
4# using the -dL option.
5
6# Ouch: as of 2020-08-03, make exits successfully even though the error
7# message has been issued as PARSE_FATAL.
8
9# Ouch: as of 2020-08-03, the variable is malformed and parsing stops
10# for a moment, but is continued after the wrongly-guessed end of the
11# variable, which echoes "y@:Q}".
12
13all: mod-loop-varname
14
15mod-loop-varname:
16	@echo ${VAR:Uvalue:@${:Ubar:S,b,v,}@x${var}y@:Q}
17	@echo ${VAR:Uvalue:@!@x$!y@:Q}	# surprisingly allowed
18