Home | History | Annotate | Download | only in unit-tests
History log of /src/usr.bin/make/unit-tests/directive-for-break.mk
RevisionDateAuthorComments
 1.5  01-Jun-2023  rillig tests/make: force line-based diagnostics to be listed in the tests

This way, contradictions between the intended output and the actual
output are closer together and have a better chance of being spotted.
 1.4  01-Jun-2023  rillig make: error out on a .break directive with arguments
 1.3  24-Sep-2022  rillig tests/make: add test for .if/.for/.if/.break
 1.2  03-Sep-2022  rillig make: clean up handling of .break in .for loops

Move For_Break further up, as the functions in that file are sorted from
small to big. The cast from size_t to unsigned int is required by lint.

In parse.c, move the code into a separate function to keep
ParseDirective small. Its only job is to parse the directive and then
delegate to another function doing the actual work.

In the manual page, remove empty lines.

In the test, ensure that .break stops processing of the .for loop
immediately; anything after the .break is not processed anymore.
Replace ':=' with '=', as there is no need to evaluate '$i' early.
Check the expected value in the .mk file instead of the .exp file, to
keep the reading scope as small as possible.
 1.1  02-Sep-2022  sjg make: add .break to terminate .for loop early

When .break is encountered within a .for loop
it causes immediate termination.

Outside of a .for loop .break causes a parse error.

Reviewed by: christos

RSS XML Feed