mistake in compilet 1.8.7? - enum and bool?

Hi all,
last version IDE 1.8.7 (Mac OS X) have strange behavior.

I use this code:

bool bSendValue = false;

typedef enum SIGNAL_VALUE
{
  LED_OFF = 0,
  LED_ON = 1
};

SIGNAL_VALUE SignalStatus;

void setup()
{
  Serial.begin(115200); // init DEBUG
}

void loop()
{
  SendValue();
  SetSignal(LED_ON);
}

bool SendValue(void) 
{
  if(bSendValue)
  {
    
  }
}

void SetSignal(SIGNAL_VALUE Val)
{
  SignalStatus = Val;
}

compiling result is:

enumTest:30:16: error: variable or field 'SetSignal' declared void
 void SetSignal(SIGNAL_VALUE Val)
                ^
enumTest:30:16: error: 'SIGNAL_VALUE' was not declared in this scope
/Users/jirijaneba/Documents/Arduino/enumTest/enumTest.ino: In function 'void loop()':
enumTest:19:19: error: 'SetSignal' was not declared in this scope
   SetSignal(LED_ON);
                   ^
exit status 1
variable or field 'SetSignal' declared void

but if a I make one from this changes - all is OK:

  1. rename function "SendValue"
    OR
  2. move declaration "bool bSendValue = false;" after enum declaration
    OR
  3. use IDE 1.8.5

Do you (anybody) know what is happen?

typedef enum SIGNAL_VALUE
{
  LED_OFF = 0,
  LED_ON = 1
};

A typedef statement defines an alternate name for the named type. Your named type is enum SIGNAL_VALUE. Your alternate name is?

"typedef" don't has influence to result (with and without) has the same bad result.

Known bug with a fix.

This will fix it:
https://github.com/arduino/arduino-builder/pull/294