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