Repository navigation
A variadic function that stores its own next argument is where the argument list starts: libcurl's curl_share_setopt (D213, #3124) - #3561
Merged
Conversation
…gument list starts: libcurl's curl_share_setopt (D213, #3124)
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.
A small extension of #3556.
The variadic rule walked from the storing function up its callers to the functions that start the argument list. The simplest shape was not covered: a public variadic function that reads its own list and stores the argument itself, as libcurl's
curl_share_setoptdoes for its lock callbacks (share->lockfunc = va_arg(param, curl_lock_function)). The list is then no parameter of the storing function, and the store was reported as not under acaseof a switch on a parameter.Such a function is itself where the list starts: its own facts are the ones asked for
case K, and the package's own calls of it are the ones checked.Test: a
directcase inconan_facade_callback_variadic_test.Battery green (503 s).
:release-checks: the run chained after the battery reported a failure whose log I did not keep (the output was piped through a filter); three reruns on the same sources are green, and I could not reproduce it. Named here so it is not lost; release-check output goes to a file from now on.