mirror of
https://github.com/TomHarte/CLK.git
synced 2026-04-26 03:29:40 +00:00
Switch to a non-macro route for startup declarations.
This commit is contained in:
@@ -223,13 +223,6 @@ struct State: public Reflection::StructImpl<State> {
|
||||
|
||||
// TODO: all audio-production thread state.
|
||||
|
||||
State() {
|
||||
if(needs_declare()) {
|
||||
DeclareField(registers);
|
||||
DeclareField(selected_register);
|
||||
}
|
||||
}
|
||||
|
||||
template <typename AY> void apply(AY &target) {
|
||||
// Establish emulator-thread state
|
||||
for(uint8_t c = 0; c < 16; c++) {
|
||||
@@ -238,6 +231,13 @@ struct State: public Reflection::StructImpl<State> {
|
||||
}
|
||||
target.select_register(selected_register);
|
||||
}
|
||||
|
||||
private:
|
||||
friend Reflection::StructImpl<State>;
|
||||
void declare_fields() {
|
||||
DeclareField(registers);
|
||||
DeclareField(selected_register);
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user