Resolved! HAL_GPIO_WritePin and HAL_GPIO_ReadPin are not boolean compatible with c++ compiler.
You can interpret return value as boolean (and pass value as boolean for gpio read and write as long as you compile you project in C but as soon as tried to compile in C++ those are not compatibles with boolean but return GPIO_PIN_SET or GPIO_PIN_RES...