From c791c2de8bdcd89035dd004b73d05217e40e179c Mon Sep 17 00:00:00 2001 From: Amlal Date: Sat, 26 Apr 2025 08:56:59 +0200 Subject: dev: codebase has been improved in terms of cli and consistency. Signed-off-by: Amlal --- dev/LibCompiler/Parser.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'dev/LibCompiler/Parser.h') diff --git a/dev/LibCompiler/Parser.h b/dev/LibCompiler/Parser.h index 04a7fab..64c46d6 100644 --- a/dev/LibCompiler/Parser.h +++ b/dev/LibCompiler/Parser.h @@ -109,7 +109,7 @@ struct SyntaxLeafList final { /// \param haystack base string /// \param needle the string we search for. /// \return if we found it or not. -inline bool find_word(const std::string& haystack, const std::string& needle) noexcept { +inline bool find_word(std::string haystack, std::string needle) noexcept { auto index = haystack.find(needle); // check for needle validity. @@ -131,8 +131,7 @@ inline bool find_word(const std::string& haystack, const std::string& needle) no /// \param haystack /// \param needle /// \return position of needle. -inline std::size_t find_word_range(const std::string& haystack, - const std::string& needle) noexcept { +inline std::size_t find_word_range(std::string haystack, std::string needle) noexcept { auto index = haystack.find(needle); // check for needle validity. -- cgit v1.2.3