Implement F/invoke_if() in C.