fix issue 2407 - function pointer as an enum's base type doesn't work