History log of /src/usr.bin/make/unit-tests/varmod-ifelse.exp |
Revision | | Date | Author | Comments |
1.32 |
| 29-Jun-2025 |
rillig | make: if a condition is erroneous, skip the whole .if/.endif
|
1.31 |
| 28-Jun-2025 |
rillig | make: consistently use double quotes in error messages
Previously, some error messages used single quotes, very few used backticks or parentheses, most already used double quotes.
While here, reword a few error messages to be clearer or more consistent with related error messages.
|
1.30 |
| 30-Apr-2025 |
rillig | make: fix order of error messages in the ":?" modifier
While here: In Var_Parse, EvalStack_Pop needs to be called before freeing the short-lived variable, as its name is part of the evaluation stack.
|
1.29 |
| 30-Apr-2025 |
rillig | tests/make: demonstrate wrong order of error messages
|
1.28 |
| 30-Mar-2025 |
rillig | make: use '"filename" line 123' for locations instead of 'filename:123'
The format 'filename:123' is commonly used for identifying a location in a file. Text editors recognize it and allow quick navigation through it. The previous format was specific to make and would have required custom support in editors.
The new format was already used in stack traces, except for the first line. Now all lines use the same format.
|
1.27 |
| 29-Mar-2025 |
rillig | make: add ":" to error message about unknown modifier
In the manual page, the modifiers are listed with a preceding ":", so use the same pattern in the error message. This removes an inconsistency between the error messages "Unknown modifier" and "Bad modifier".
|
1.26 |
| 11-Jan-2025 |
rillig | make: omit redundant follow-up message "Malformed conditional"
If there is a parse error or an evaluation error during the conditional, the conditional is already mentioned in the "while evaluating condition" line, so there's no reason to repeat it once again.
Same for the "Bad condition" message from the '?:' modifier.
|
1.25 |
| 29-Aug-2024 |
rillig | make: reduce line length in error messages
The error messages for deeply nested parse errors were hard to decipher, due to the large amount of text. Split these messages into individual lines, just as in the backtrace for .include files and .for loops. This unified backtrace makes the output more uniform.
|
1.24 |
| 06-Aug-2024 |
rillig | make: in error message about conditionals, use single quotes
Single quotes are used less often in the conditionals themselves, which leads to fewer confusions.
|
1.23 |
| 05-Jul-2024 |
rillig | make: in error messages, distinguish parsing from evaluating
|
1.22 |
| 05-Jul-2024 |
rillig | make: in error messages for anonymous variables, log the value
|
1.21 |
| 30-Jun-2024 |
rillig | make: error out on syntax error in conditions in ':?then:else' modifier
The 'Error' function only reports errors but does not affect the exit status, the 'Parse_Error' function does, while providing more details to find the cause of the syntax error.
|
1.20 |
| 20-Apr-2024 |
rillig | branches: 1.20.2; make: provide more context information for parse/evaluate errors
|
1.19 |
| 10-Dec-2023 |
rillig | make: remove redundant text from diagnostic about bad '?:' modifier
|
1.18 |
| 19-Nov-2023 |
rillig | tests/make: replace 'variable expression' with 'expression'
Each expression is based on a variable, there's no need for the verbosity. The wording in make's diagnostics will be changed in a follow-up commit.
|
1.17 |
| 01-Jul-2023 |
rillig | tests/make: show how to use indirect conditions in the '?:' modifier
|
1.16 |
| 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.15 |
| 18-Feb-2023 |
rillig | tests/make: document why ':?' cannot parse its operands in balanced mode
|
1.14 |
| 25-Sep-2022 |
rillig | tests/make: reduce trailing whitespace
|
1.13 |
| 04-Sep-2022 |
rillig | make: add more details to error message for numeric comparison
Before: String comparison operator must be either == or !=
After: Comparison with '>=' requires both operands 'no' and '10' to be numeric
Noticed by martin@ in pkgsrc/textproc/py-pygments.
|
1.12 |
| 03-Mar-2022 |
rillig | make: make debug logging for comparisons less technical
|
1.11 |
| 11-Jun-2021 |
rillig | tests/make: demonstrate handling of '+' and '*' in modifier ':?'
It doesn't make sense that these two characters are handled differently, but that's what the current code has been doing for years.
|
1.10 |
| 19-Apr-2021 |
rillig | make: do not complain when skipping the condition 'no >= 10'
Seen in external/bsd/tmux when building with Clang. See varmod-ifelse.mk for the detailed story.
|
1.9 |
| 19-Apr-2021 |
rillig | tests/make: add another example for parsing of the modifier ':?'
|
1.8 |
| 19-Apr-2021 |
rillig | tests/make: add detailed explanation for error message in conditional
|
1.7 |
| 19-Apr-2021 |
rillig | make: use straight quotes for error 'Bad conditional expression'
This diagnostic was supposed to be an error, see ApplyModifier_IfElse.
When such an error occurs while the makefiles are read, make stops with an error, as can be expected. But when such an error occurs later, after all makefiles have been read, the message is printed but make does not stop.
In lint mode (-dL), make stops in such a case. I didn't dare to make this the default behavior, out of fear of breaking existing build infrastructure, not only in NetBSD or pkgsrc, but also FreeBSD and other operating systems that use the bmake distribution, generated from the same source code.
|
1.6 |
| 19-Apr-2021 |
rillig | tests/make: demonstrate unexpected behavior of the modifier ':?'
|
1.5 |
| 10-Dec-2020 |
rillig | make(1): add test demonstrating how to defer evaluation in :? modifier
|
1.4 |
| 12-Nov-2020 |
rillig | make(1): add test for unhandled parse error in :? variable modifier
|
1.3 |
| 23-Oct-2020 |
rillig | make(1): move tests from cond2.mk to varmod-ifelse.mk (fixup)
|
1.2 |
| 23-Oct-2020 |
rillig | make(1): move tests from cond2.mk to varmod-ifelse.mk
|
1.1 |
| 16-Aug-2020 |
rillig | make(1): add dummies for fine-grained tests, one per single feature
The test names have been derived from the current manual page.
All these tests are dummies right now, and the code from the existing tests will be moved into the new tests step by step.
This is done to prevent modmisc, escape, varmod-edge and varmisc from growing without any bounds, and to reduce the side-effects of one test to the others.
|
1.20.2.2 |
| 02-Aug-2025 |
perseant | Sync with HEAD
|
1.20.2.1 |
| 01-Jul-2024 |
perseant | Sync with HEAD.
|