Commit 75e184c
fix(model): apply a leading ! in validation conditions to its own clause only (#3662)
$evaluateConditionString() stripped a leading `!` and inverted the result of the
whole remaining string before the top-level `||`/`&&` split ran, so
`!a || b` was evaluated as `!(a || b)` and `!a && b` as `!(a && b)`. CFML
binds `!` tighter than `&&` and `||`.
Only negate when the rest after the `!` is a single clause or a fully wrapped
parenthesised group (no top-level `||`/`&&`); otherwise fall through to the
compound split, where each operand recurses and negates just itself.
`!(a || b)` still negates the whole group.
Claude-Session: https://claude.ai/code/session_018RdXpVKos1AZ24dM4X8wL1
Signed-off-by: Claude <noreply@anthropic.com>
Co-authored-by: Claude <noreply@anthropic.com>1 parent 0d2dfa7 commit 75e184c
3 files changed
Lines changed: 47 additions & 10 deletions
File tree
- changelog.d
- vendor/wheels
- model
- tests/specs/model
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
854 | 854 | | |
855 | 855 | | |
856 | 856 | | |
857 | | - | |
858 | | - | |
| 857 | + | |
| 858 | + | |
859 | 859 | | |
860 | 860 | | |
861 | 861 | | |
862 | 862 | | |
| 863 | + | |
| 864 | + | |
| 865 | + | |
| 866 | + | |
| 867 | + | |
| 868 | + | |
863 | 869 | | |
864 | 870 | | |
865 | | - | |
866 | | - | |
867 | | - | |
| 871 | + | |
| 872 | + | |
| 873 | + | |
| 874 | + | |
| 875 | + | |
| 876 | + | |
| 877 | + | |
| 878 | + | |
868 | 879 | | |
869 | 880 | | |
870 | 881 | | |
| |||
877 | 888 | | |
878 | 889 | | |
879 | 890 | | |
880 | | - | |
881 | | - | |
| 891 | + | |
882 | 892 | | |
883 | 893 | | |
884 | 894 | | |
885 | | - | |
886 | | - | |
887 | | - | |
| 895 | + | |
| 896 | + | |
| 897 | + | |
888 | 898 | | |
889 | 899 | | |
890 | 900 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
430 | 430 | | |
431 | 431 | | |
432 | 432 | | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
433 | 459 | | |
434 | 460 | | |
435 | 461 | | |
| |||
0 commit comments