summaryrefslogtreecommitdiffhomepage
path: root/dev/LibCompiler/src/Frontend.cc
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal@nekernel.org>2025-06-18 10:27:31 +0200
committerAmlal El Mahrouss <amlal@nekernel.org>2025-06-18 10:27:31 +0200
commitfbbcfd27436fe61799c79aec14f9c2c3fdf73497 (patch)
treed8be437f572605462637007f6bd371b6b4a650cb /dev/LibCompiler/src/Frontend.cc
parent2a1e217019f66b1913034b6bd760052f3b37cea4 (diff)
feat: PEF format update `5.0` and codebase refactors.
Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
Diffstat (limited to 'dev/LibCompiler/src/Frontend.cc')
-rw-r--r--dev/LibCompiler/src/Frontend.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/dev/LibCompiler/src/Frontend.cc b/dev/LibCompiler/src/Frontend.cc
index 69ff6fd..2ed5309 100644
--- a/dev/LibCompiler/src/Frontend.cc
+++ b/dev/LibCompiler/src/Frontend.cc
@@ -11,11 +11,11 @@ namespace LibCompiler {
/// \param haystack base string
/// \param needle the string we search for.
/// \return if we found it or not.
-bool find_word(std::string haystack, std::string needle) noexcept {
+BOOL find_word(STLString haystack, STLString needle) noexcept {
auto index = haystack.find(needle);
// check for needle validity.
- if (index == std::string::npos) return false;
+ if (index == STLString::npos) return false;
// declare lambda
auto not_part_of_word = [&](int index) {
@@ -33,11 +33,11 @@ bool find_word(std::string haystack, std::string needle) noexcept {
/// \param haystack
/// \param needle
/// \return position of needle.
-std::size_t find_word_range(std::string haystack, std::string needle) noexcept {
+SizeType find_word_range(STLString haystack, STLString needle) noexcept {
auto index = haystack.find(needle);
// check for needle validity.
- if (index == std::string::npos) return false;
+ if (index == STLString::npos) return false;
if (!isalnum((haystack[index + needle.size() + 1])) &&
!isdigit(haystack[index + needle.size() + 1]) &&
@@ -46,6 +46,6 @@ std::size_t find_word_range(std::string haystack, std::string needle) noexcept {
return index;
}
- return std::string::npos;
+ return STLString::npos;
}
} // namespace LibCompiler \ No newline at end of file