How does this line work? static bool const unused = (WillOnlyRunOnce(), true)
I stumbled upon a piece of code similar to this one and I can't grasp it.
void WillOnlyRunOnce() {
std::cout << "WillOnlyRunOnce" << std::endl;
}
void Init() {
static bool const unused = (WillOnlyRunOnce(), true);
}
void main()
{
Init();
Init();
Init();
}