From f7e7716df98021819ac0993a71d0c84ca909e27f Mon Sep 17 00:00:00 2001 From: chatlanin Date: Sat, 4 Jan 2025 11:44:42 +0300 Subject: [PATCH] fix logger for ring buffer --- bin/main.cpp | 2 +- src/hack/logger/logger.hpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/main.cpp b/bin/main.cpp index cb106f4..d97657c 100644 --- a/bin/main.cpp +++ b/bin/main.cpp @@ -12,7 +12,7 @@ auto main(int argc, char *argv[]) -> int { // patterns::ring_buffer { - hack::patterns::ring_buffer rb; + hack::patterns::ring_buffer rb(10); for (int i = 1; i < 12; ++i) rb.put(i); hack::log()(rb); } diff --git a/src/hack/logger/logger.hpp b/src/hack/logger/logger.hpp index bcdc816..363f4eb 100755 --- a/src/hack/logger/logger.hpp +++ b/src/hack/logger/logger.hpp @@ -135,8 +135,8 @@ namespace hack std::cout << data << (count != 0 ? devider : ""); } - template - static void print_t(const hack::patterns::ring_buffer& rb) + template + static void print_t(const hack::patterns::ring_buffer& rb) { print_t(rb.get_src()); }