1 # $NetBSD: directive-else.mk,v 1.6 2020/11/13 09:01:59 rillig Exp $
3 # Tests for the .else directive.
5 .MAKEFLAGS: -dL # To enable the check for ".else <cond>"
7 # The .else directive does not take any arguments.
8 # As of 2020-08-29, make doesn't warn about this.
10 . warning must not be reached
18 . warning must not be reached
21 # An .else without a corresponding .if is an error.
24 # Accidental extra .else directives are detected too.
26 . warning must not be reached
30 . info After an extra .else, everything is skipped.
33 # An .else may have a comment. This comment does not count as an argument,
34 # therefore no parse error.
39 # A variable expression does count as an argument, even if it is empty.
40 # XXX: This should be a parse error.