in scripts/extract_redis_commands_argcounts.php [254:270]
function dump_mismatched_argument_types(array $types, array $commands): void {
foreach (EXPECTED_MAPS as $expected => $maps) {
foreach ($maps as $key) {
$actual = $types[$key];
if ($actual !== $expected) {
echo "Unexpected type for $key: got $actual, want $expected: " . json_encode($commands[$key]['arguments']) . "\n";
}
}
foreach ($types as $other_name => $type) {
if ($type === $expected && !in_array($other_name, $maps)) {
$command = $commands[$other_name];
echo "Expected $other_name in $expected: " . json_encode($command['arguments']) . "\n";
echo "> " . $command['group'] . ": " . $command['summary'] . "\n\n";
}
}
}
}