In tracing source code of task.c for freeRTOS, i see a function named portTASK_FUNCTION. its code is as below
static portTASK_FUNCTION( prvIdleTask, pvParameters )
{
    /* Stop warnings. */
    ( void ) pvParameters;  //<--what for??
    for( ;; )
    {
        do something
    }
}
i don't understand what ( void ) pvParameters means, hope someone could help me, thx
btw, this function's type of args are not declared, why does it can work?
                        
This code consists of comment:
The optimizer will remove the code you mentioned. But there is unused parameter in function -
pvParameters. And this code is written to shut up compiler. It does nothing.