This makes sure that CAPTURE works when called with variadic arguments,
and also works that way when disabled.
The underlying fix to #2316 is not applicable (CAPTURE is already
variadic when disabled).
This is a port of 5e94498ed04820b1022f0bead0f7d4d5fb7a06dd to the
devel branch.