DSPCore: Make DSPCore_SetException() take an enum type instead of a u8
Makes it more immediately indicative which values are intended to be passed to this function.
This commit is contained in:
parent
6bfbc1988e
commit
8459d2bc5d
|
@ -202,9 +202,9 @@ void DSPCore_Reset()
|
||||||
Analyzer::Analyze();
|
Analyzer::Analyze();
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPCore_SetException(u8 level)
|
void DSPCore_SetException(ExceptionType exception)
|
||||||
{
|
{
|
||||||
g_dsp.exceptions |= 1 << level;
|
g_dsp.exceptions |= 1 << exception;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Notify that an external interrupt is pending (used by thread mode)
|
// Notify that an external interrupt is pending (used by thread mode)
|
||||||
|
|
|
@ -208,7 +208,7 @@ enum : u16
|
||||||
};
|
};
|
||||||
|
|
||||||
// Exception vectors
|
// Exception vectors
|
||||||
enum : int
|
enum ExceptionType : int
|
||||||
{
|
{
|
||||||
EXP_STOVF = 1, // 0x0002 stack under/over flow
|
EXP_STOVF = 1, // 0x0002 stack under/over flow
|
||||||
EXP_2 = 2, // 0x0004
|
EXP_2 = 2, // 0x0004
|
||||||
|
@ -356,7 +356,7 @@ void DSPCore_CheckExceptions();
|
||||||
void DSPCore_SetExternalInterrupt(bool val);
|
void DSPCore_SetExternalInterrupt(bool val);
|
||||||
|
|
||||||
// sets a flag in the pending exception register.
|
// sets a flag in the pending exception register.
|
||||||
void DSPCore_SetException(u8 level);
|
void DSPCore_SetException(ExceptionType exception);
|
||||||
|
|
||||||
enum class State
|
enum class State
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue