From: Amelia Coutard Date: Sun, 12 Jun 2022 11:15:02 +0000 (+0200) Subject: Removed println and replaced its usages by corresponding print calls X-Git-Url: https://git.ameliathe1st.gay/?a=commitdiff_plain;h=41bfceba1e85d45c508ae77a9a2a20f59ca8ad17;p=voyage-au-centre-des-fichiers.git Removed println and replaced its usages by corresponding print calls --- diff --git a/src/paging.cpp b/src/paging.cpp index 56b7135..9c2f133 100644 --- a/src/paging.cpp +++ b/src/paging.cpp @@ -38,7 +38,7 @@ os::paging::page_allocator_t::page_allocator_t(phys_ptr one_past_e void os::paging::page_allocator_t::print_all() const { if (is_empty()) { - os::println("No RAM left."); + os::print("No RAM left.\n"); } else for (auto it = begin(); it != end(); it = it->next) { os::print(it.get_phys_addr()); os::print("->"); diff --git a/src/serial.cpp b/src/serial.cpp index e60413b..5a8e8df 100644 --- a/src/serial.cpp +++ b/src/serial.cpp @@ -68,7 +68,8 @@ void os::print(std::int8_t v) { os::print(std::int64_t(v)); } void os::assert(bool cond, const char* diagnostic) { if (!cond) { os::print("Error: "); - os::println(diagnostic); + os::print(diagnostic); + os::printc('\n'); os::cli(); while (true) { os::hlt(); } } diff --git a/src/serial.hpp b/src/serial.hpp index d159456..07b61c5 100644 --- a/src/serial.hpp +++ b/src/serial.hpp @@ -23,11 +23,6 @@ void print(std::int64_t v); void print(std::int32_t v); void print(std::int16_t v); void print(std::int8_t v); -template -void println(const T& v) { - print(v); - printc('\n'); -} void assert(bool cond, const char* diagnostic); }