xref: /freebsd/contrib/bmake/unit-tests/dep-op-missing.mk (revision 1b10e191f341111fad7be32ead11484dfd09b800)
1# $NetBSD: dep-op-missing.mk,v 1.1 2021/12/14 00:02:57 rillig Exp $
2#
3# Test for a missing dependency operator, in a line with trailing whitespace.
4
5# Before parse.c 1.578 from 2021-12-14, there was some unreachable error
6# handling code in ParseDependencyOp.  This test tried to reach it and failed.
7# To reach that point, there would have to be trailing whitespace in the line,
8# but that is removed in an early stage of parsing.
9
10all: .PHONY
11	@printf 'target ' > dep-op-missing.tmp
12	@${MAKE} -r -f dep-op-missing.tmp || exit 0
13	@rm dep-op-missing.tmp
14