Why cast an unused function parameter value to void? January 2, 2023 by Tarik It is there to avoid warnings from the compiler because some parameters are unused.