send-message-list arg-count forgiveness, plus better error checking - #7670
Open
Goober5000 wants to merge 1 commit into
Open
send-message-list arg-count forgiveness, plus better error checking#7670Goober5000 wants to merge 1 commit into
Goober5000 wants to merge 1 commit into
Conversation
Due to a long-standing bug, the groups-of-4 argument count check for send-message-list and send-message-chain never actually worked, so missions through 25.0 could includes sexps with truncated argument lists that recovered gracefully at runtime. Now that the check works, don't punish those missions: introduce SEXP_CHECK_BAD_ARG_COUNT_BENIGN, which warns but does not prevent the mission from loading. To make sexp tree validation more robust, check_sexp_syntax now defers recoverable errors rather than returning them immediately; otherwise a recoverable error could mask a fatal error deeper in the tree. Also fix a stale-variable bug in FRED's fred_check_sexp that could produce a bogus empty dialog. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Goober5000
force-pushed
the
fix/msg_arg_count
branch
from
July 30, 2026 05:03
a225389 to
5fa6674
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Due to a long-standing bug, the groups-of-4 argument count check for send-message-list and send-message-chain never actually worked, so missions through 25.0 could includes sexps with truncated argument lists that recovered gracefully at runtime. Now that the check works, don't punish those missions: introduce SEXP_CHECK_BAD_ARG_COUNT_BENIGN, which warns but does not prevent the mission from loading.
To make sexp tree validation more robust, check_sexp_syntax now defers recoverable errors rather than returning them immediately; otherwise a recoverable error could mask a fatal error deeper in the tree.
Also fix a stale-variable bug in FRED's fred_check_sexp that could produce a bogus empty dialog.