Merge remote-tracking branch 'origin/topic/vern/field-assign-parsing'

* origin/topic/vern/field-assign-parsing:
  tightened up parsing of $field=X record constructor expressions
This commit is contained in:
Evan Typanski 2025-09-03 16:17:23 -04:00
commit 42f7a2d88c
6 changed files with 56 additions and 23 deletions

View file

@ -0,0 +1,2 @@
### BTest baseline data generated by btest-diff. Do not edit. Use "btest -U/-u" to update. Requires BTest >= 0.63.
error in <...>/bogus-field-assign.zeek, line 6: syntax error, at or near "$"

View file

@ -1,2 +1,2 @@
### BTest baseline data generated by btest-diff. Do not edit. Use "btest -U/-u" to update. Requires BTest >= 0.63.
error in <...>/record-bad-ctor3.zeek, line 13: bad type in record constructor ([$x=a + 5, a + 9] and a + 9)
error in <...>/record-bad-ctor3.zeek, line 13: syntax error, at or near "a"

View file

@ -0,0 +1,6 @@
# @TEST-EXEC-FAIL: zeek -b %INPUT >out 2>&1
# @TEST-EXEC: TEST_DIFF_CANONIFIER=$SCRIPTS/diff-remove-abspath btest-diff out
# Zeek used to happily print the value of "5" here.
print $foo=5;