From 900eab129be1cb0cb50c152df4a33f19e4c19a7c Mon Sep 17 00:00:00 2001 From: levlam Date: Wed, 19 Sep 2018 01:35:45 +0300 Subject: [PATCH] Make Binlog helper template functions non-static. GitOrigin-RevId: db82e3468f8bf3e1bd0835721c57a72c97a0b859 --- td/telegram/td_emscripten.cpp | 3 ++- tddb/td/db/binlog/BinlogHelper.h | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/td/telegram/td_emscripten.cpp b/td/telegram/td_emscripten.cpp index 585ea379..d259711f 100644 --- a/td/telegram/td_emscripten.cpp +++ b/td/telegram/td_emscripten.cpp @@ -7,9 +7,10 @@ // Just for testing. // Will be completly rewritten +#include "td/actor/actor.h" + #include "td/telegram/td_json_client.h" #include "td/telegram/td_log.h" -#include "td/actor/actor.h" #include diff --git a/tddb/td/db/binlog/BinlogHelper.h b/tddb/td/db/binlog/BinlogHelper.h index 9fbba9cf..ed9cb298 100644 --- a/tddb/td/db/binlog/BinlogHelper.h +++ b/tddb/td/db/binlog/BinlogHelper.h @@ -15,7 +15,7 @@ namespace td { template -static uint64 binlog_add(const BinlogT &binlog_ptr, int32 type, const StorerT &storer, +uint64 binlog_add(const BinlogT &binlog_ptr, int32 type, const StorerT &storer, Promise<> promise = Promise<>()) { auto logevent_id = binlog_ptr->next_id(); binlog_ptr->add_raw_event(logevent_id, BinlogEvent::create_raw(logevent_id, type, 0, storer), std::move(promise)); @@ -23,7 +23,7 @@ static uint64 binlog_add(const BinlogT &binlog_ptr, int32 type, const StorerT &s } template -static uint64 binlog_rewrite(const BinlogT &binlog_ptr, uint64 logevent_id, int32 type, const StorerT &storer, +uint64 binlog_rewrite(const BinlogT &binlog_ptr, uint64 logevent_id, int32 type, const StorerT &storer, Promise<> promise = Promise<>()) { auto seq_no = binlog_ptr->next_id(); binlog_ptr->add_raw_event(seq_no, BinlogEvent::create_raw(logevent_id, type, BinlogEvent::Flags::Rewrite, storer), @@ -34,7 +34,7 @@ static uint64 binlog_rewrite(const BinlogT &binlog_ptr, uint64 logevent_id, int3 #define binlog_erase(...) binlog_erase_impl({__FILE__, __LINE__}, __VA_ARGS__) template -static uint64 binlog_erase_impl(BinlogDebugInfo info, const BinlogT &binlog_ptr, uint64 logevent_id, +uint64 binlog_erase_impl(BinlogDebugInfo info, const BinlogT &binlog_ptr, uint64 logevent_id, Promise<> promise = Promise<>()) { auto seq_no = binlog_ptr->next_id(); binlog_ptr->add_raw_event(info, seq_no,