Simplify handler signatures: return response struct, typed_handler does encoding

This commit is contained in:
Ian Gulliver
2026-04-10 22:21:31 +09:00
parent e2a5d97dae
commit 58db392bf3
5 changed files with 19 additions and 21 deletions

View File

@@ -4,9 +4,9 @@
std::string_view firmware_name = "picomap";
static constexpr handler_entry handlers[] = {
{RequestPICOBOOT::ext_id, handle_picoboot},
{RequestInfo::ext_id, handle_info},
{RequestLog::ext_id, handle_log},
{RequestPICOBOOT::ext_id, typed_handler<RequestPICOBOOT, handle_picoboot>},
{RequestInfo::ext_id, typed_handler<RequestInfo, handle_info>},
{RequestLog::ext_id, typed_handler<RequestLog, handle_log>},
};
int main() {