From c547aac3154962508fed5829d4c166394f2c168b Mon Sep 17 00:00:00 2001 From: Egor Tensin Date: Thu, 4 Jun 2026 16:39:58 +0200 Subject: fix std::string_view usage --- server/lexer/input.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'server/lexer/input.hpp') diff --git a/server/lexer/input.hpp b/server/lexer/input.hpp index 0e28b13..1f3b749 100644 --- a/server/lexer/input.hpp +++ b/server/lexer/input.hpp @@ -14,9 +14,9 @@ namespace math::server::lexer { class Input { public: - explicit Input(const std::string_view& input) : m_pos{0}, m_input{input} {} + explicit Input(std::string_view input) : m_pos{0}, m_input{input} {} - const std::string_view& get_input() const { + std::string_view get_input() const { return m_input; } @@ -40,7 +40,7 @@ public: m_input.remove_prefix(len); } - void consume(const std::string_view& sub) { + void consume(std::string_view sub) { consume(sub.length()); } -- cgit v1.3