4 This tests random features of the parser that need to be supported, and
5 which have either broken at some point in the past or seem likely to
9 # We want to allow both empty commands _and_ commands that resolve to empty.
12 .PHONY: all a1 a2 a3 a4
22 \# Non-empty lines that expand to nothing should also be ignored.
24 TAB = \t \# A TAB and some spaces
29 '', "#MAKE#: Nothing to be done for `all'.");
33 # Make sure files without trailing newlines are handled properly.
34 # Have to use the old style invocation to test this.
36 $makefile2 = &get_tmpfile;
38 open(MAKEFILE, "> $makefile2");
39 print MAKEFILE "all:;\@echo FOO = \$(FOO)\nFOO = foo";
42 &run_make_with_options($makefile2,"",&get_logfile);
43 $answer = "FOO = foo\n";
44 &compare_output($answer,&get_logfile(1));
48 # Check semicolons in variable references
51 $(if true,$(info true; true))
58 # Check that backslashes in command scripts are handled according to POSIX.
59 # Checks Savannah bug # 1332.
61 # Test the fastpath / no quotes
90 # Test the fastpath / single quotes
127 # Test the fastpath / double quotes
156 # Test the slow path / no quotes
193 # Test the slow path / no quotes. This time we put the slow path
194 # determination _after_ the backslash-newline handling.
231 # Test the slow path / single quotes
234 \@echo hi; echo 'foo\\
236 \@echo hi; echo 'foo\\
238 \@echo hi; echo 'foo\\
240 \@echo hi; echo 'foo\\
242 \@echo hi; echo 'foo \\
244 \@echo hi; echo 'foo \\
246 \@echo hi; echo 'foo \\
248 \@echo hi; echo 'foo \\
276 # Test the slow path / double quotes
287 @echo hi; echo "foo \
289 @echo hi; echo "foo \
291 @echo hi; echo "foo \
293 @echo hi; echo "foo \