summaryrefslogtreecommitdiffhomepage
path: root/dev
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal@nekernel.org>2025-11-17 10:31:30 +0100
committerAmlal El Mahrouss <amlal@nekernel.org>2025-11-17 10:31:30 +0100
commit3827ae4e821ff3758d1eaf2dbacc55a22f802731 (patch)
tree0768b1a509bd104627675127f1e9785c702e7621 /dev
parent5c5a101c9618f8edea5038e94df64508b0f0a70e (diff)
feat: fixing merge conflicts.
Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
Diffstat (limited to 'dev')
-rw-r--r--dev/examples/allocator_system/allocator_system.cc2
-rw-r--r--dev/examples/cgi/cgi.cc4
-rw-r--r--dev/examples/equiv/equiv.cc6
-rw-r--r--dev/examples/fix/fix.cc6
-rw-r--r--dev/examples/opt/opt.cc4
-rw-r--r--dev/examples/tracked_ptr/tracked_ptr.cc8
-rw-r--r--dev/lib/core/allocator_system.hpp10
-rw-r--r--dev/lib/core/error_handler.hpp12
-rw-r--r--dev/lib/except/error.hpp10
-rw-r--r--dev/lib/fix/fix.hpp10
-rw-r--r--dev/lib/io/print.hpp10
-rw-r--r--dev/lib/logic/equiv.hpp4
-rw-r--r--dev/lib/logic/math.hpp4
-rw-r--r--dev/lib/logic/opt.hpp10
-rw-r--r--dev/lib/memory/tracked_ptr.hpp4
-rw-r--r--dev/lib/net/modem.hpp12
-rw-r--r--dev/lib/net/url.hpp4
-rw-r--r--dev/lib/simd/basic_simd.hpp8
-rw-r--r--dev/lib/simd/simd.hpp8
-rw-r--r--dev/lib/tests/hpptest.hpp8
-rw-r--r--dev/lib/utility/cgi_writer.hpp26
-rw-r--r--dev/lib/utility/chunk_string.hpp12
-rw-r--r--dev/lib/utility/crc32.hpp10
-rw-r--r--dev/lib/utility/embfs.hpp10
-rw-r--r--dev/tests/chunk_string/chunk_test.cc2
-rw-r--r--dev/tests/fix_basic/fix_test.cc6
-rw-r--r--dev/tests/network_basic/net_test.cc4
-rw-r--r--dev/tests/tracked_ptr_basic/tracked_ptr_test.cc8
-rw-r--r--dev/tests/tracked_ptr_leak/tracked_ptr_test.cc10
29 files changed, 116 insertions, 116 deletions
diff --git a/dev/examples/allocator_system/allocator_system.cc b/dev/examples/allocator_system/allocator_system.cc
index 169cd97..b500e30 100644
--- a/dev/examples/allocator_system/allocator_system.cc
+++ b/dev/examples/allocator_system/allocator_system.cc
@@ -32,7 +32,7 @@ public:
int main()
{
- scl::standard_allocator_type<MyClass> allocator;
+ ocl::standard_allocator_type<MyClass> allocator;
// Test 1: claim() + unclaim()
std::cout << "=== Test 1: claim/unclaim ===\n";
diff --git a/dev/examples/cgi/cgi.cc b/dev/examples/cgi/cgi.cc
index 6f73eff..692f90c 100644
--- a/dev/examples/cgi/cgi.cc
+++ b/dev/examples/cgi/cgi.cc
@@ -6,7 +6,7 @@
#include <lib/utility/cgi_writer.hpp>
-static scl::basic_chunk_string<char> text_sample = R"(
+static ocl::basic_chunk_string<char> text_sample = R"(
<!DOCTYPE html>
<html>
<head>
@@ -68,7 +68,7 @@ static scl::basic_chunk_string<char> text_sample = R"(
/* @brief this stub loads a 'index.html' or returns an error message if not found. */
int main(int argc, char** argv)
{
- scl::cgi::basic_writer<> writer;
+ ocl::cgi::basic_writer<> writer;
writer << text_sample;
return 0;
diff --git a/dev/examples/equiv/equiv.cc b/dev/examples/equiv/equiv.cc
index 9d41afb..12207f4 100644
--- a/dev/examples/equiv/equiv.cc
+++ b/dev/examples/equiv/equiv.cc
@@ -11,9 +11,9 @@
int main(int argc, char** argv)
{
std::cout << std::boolalpha;
- std::cout << scl::equiv::is_same<bool, int>::value << std::endl;
- std::cout << scl::equiv::is_same<bool, bool>::value << std::endl;
- std::cout << scl::equiv::is_same<int, int>::value << std::endl;
+ std::cout << ocl::equiv::is_same<bool, int>::value << std::endl;
+ std::cout << ocl::equiv::is_same<bool, bool>::value << std::endl;
+ std::cout << ocl::equiv::is_same<int, int>::value << std::endl;
return 0;
}
diff --git a/dev/examples/fix/fix.cc b/dev/examples/fix/fix.cc
index aaac979..ec6668a 100644
--- a/dev/examples/fix/fix.cc
+++ b/dev/examples/fix/fix.cc
@@ -15,14 +15,14 @@ int main(int argc, char** argv)
{
constexpr auto default_fix = "8=FIX.4.2|9=65|35=A|49=SERVER|56=CLIENT|34=177|52=20090107-18:15:16|98=0|108=30|10=062|";
- scl::fix::basic_visitor<char> basic_visitor;
- scl::fix::basic_range_data<char> fix = basic_visitor.visit(default_fix);
+ ocl::fix::basic_visitor<char> basic_visitor;
+ ocl::fix::basic_range_data<char> fix = basic_visitor.visit(default_fix);
std::cout << "magic=" << fix.magic_ << std::endl;
std::cout << "magic_len=" << fix.magic_len_ << std::endl;
std::cout << "is_valid=" << std::boolalpha << fix.is_valid() << std::endl;
- scl::fix::must_pass(fix);
+ ocl::fix::must_pass(fix);
for (auto fields : fix.body_)
{
diff --git a/dev/examples/opt/opt.cc b/dev/examples/opt/opt.cc
index eb725c4..8a74fa2 100644
--- a/dev/examples/opt/opt.cc
+++ b/dev/examples/opt/opt.cc
@@ -26,7 +26,7 @@ static auto do_some(const std::string recv_data, const std::string check_data)
const int hash_to_check = do_hash(check_data); /* here we assume this should match opt_hash */
const int opt_hash = do_hash(recv_data); /* we assume that the hash is correct */
- auto opt = scl::opt(scl::eval_eq(hash_to_check, opt_hash)); /* do the compute */
+ auto opt = ocl::opt(ocl::eval_eq(hash_to_check, opt_hash)); /* do the compute */
return opt;
}
@@ -35,7 +35,7 @@ int main(int argc, char** argv)
{
// ... let's assume we fetch data from network...
- scl::io::println("Testing data...");
+ ocl::io::println("Testing data...");
auto opt = do_some("Ohio", "Ohio");
opt.try_or_throw("Checksum failed, Ohio isn't Ohio!");
diff --git a/dev/examples/tracked_ptr/tracked_ptr.cc b/dev/examples/tracked_ptr/tracked_ptr.cc
index 6b8a859..6e3f4a2 100644
--- a/dev/examples/tracked_ptr/tracked_ptr.cc
+++ b/dev/examples/tracked_ptr/tracked_ptr.cc
@@ -9,13 +9,13 @@
static void summon_tracked_ptr()
{
- scl::memory::tracked_ptr<int> ptr = scl::memory::make_tracked<int>(42);
+ ocl::memory::tracked_ptr<int> ptr = ocl::memory::make_tracked<int>(42);
std::cout << ptr.data() << "=" << ptr.manager().allocator().allocated_count_ << std::endl;
}
static void summon_leak_tracked_ptr()
{
- scl::memory::tracked_ptr<int>* ptr = new scl::memory::tracked_ptr<int>(42);
+ ocl::memory::tracked_ptr<int>* ptr = new ocl::memory::tracked_ptr<int>(42);
std::cout << ptr->data() << "=" << ptr->manager().allocator().allocated_count_ << std::endl;
}
@@ -27,7 +27,7 @@ int main(int argc, char** argv)
summon_tracked_ptr();
summon_tracked_ptr();
- scl::memory::tracked_ptr<int> ptr;
+ ocl::memory::tracked_ptr<int> ptr;
std::cout << ptr.data() << "=" << ptr.manager().allocator().allocated_count_ << std::endl;
@@ -46,7 +46,7 @@ int main(int argc, char** argv)
std::cout << "total=" << ptr.manager().allocator().deallocated_count_ << std::endl;
std::cout << "leak-detected=" << std::boolalpha << (ptr.manager().allocator().allocated_count_ > ptr.manager().allocator().deallocated_count_) << std::endl;
- scl::memory::must_pass(ptr);
+ ocl::memory::must_pass(ptr);
return EXIT_SUCCESS;
}
diff --git a/dev/lib/core/allocator_system.hpp b/dev/lib/core/allocator_system.hpp
index 3ffa02a..6fd0119 100644
--- a/dev/lib/core/allocator_system.hpp
+++ b/dev/lib/core/allocator_system.hpp
@@ -5,13 +5,13 @@
* Copyright 2025, Amlal El Mahrouss. Licensed under the BSL 1.0 license
*/
-#ifndef _SCL_ALLOCATOR_SYSTEM_HPP
-#define _SCL_ALLOCATOR_SYSTEM_HPP
+#ifndef _OCL_ALLOCATOR_SYSTEM_HPP
+#define _OCL_ALLOCATOR_SYSTEM_HPP
#include <lib/core/includes.hpp>
#include <memory>
-namespace scl
+namespace ocl
{
template <typename type>
struct new_op final
@@ -69,6 +69,6 @@ namespace scl
template <typename type>
using standard_allocator_type = allocator_system<type, new_op<type>, delete_op<type>>;
-} // namespace scl
+} // namespace ocl
-#endif // ifndef _SCL_ALLOCATOR_SYSTEM_HPP
+#endif // ifndef _OCL_ALLOCATOR_SYSTEM_HPP
diff --git a/dev/lib/core/error_handler.hpp b/dev/lib/core/error_handler.hpp
index 449e255..67bf7b4 100644
--- a/dev/lib/core/error_handler.hpp
+++ b/dev/lib/core/error_handler.hpp
@@ -5,13 +5,13 @@
* Copyright 2025, Amlal El Mahrouss.
*/
-#ifndef _SCL_ERROR_HANDLER_HPP
-#define _SCL_ERROR_HANDLER_HPP
+#ifndef _OCL_ERROR_HANDLER_HPP
+#define _OCL_ERROR_HANDLER_HPP
#include <lib/core/includes.hpp>
#include <lib/io/print.hpp>
-namespace scl
+namespace ocl
{
struct basic_error_handler;
@@ -25,12 +25,12 @@ namespace scl
virtual void operator()(const std::basic_string<char>& msg)
{
- scl::io::print(msg);
+ ocl::io::print(msg);
}
};
using standard_error_handler = basic_error_handler;
using error_handler_type = basic_error_handler;
-} // namespace scl
+} // namespace ocl
-#endif // ifndef _SCL_ERROR_HANDLER_HPP
+#endif // ifndef _OCL_ERROR_HANDLER_HPP
diff --git a/dev/lib/except/error.hpp b/dev/lib/except/error.hpp
index 31b9894..16bf5eb 100644
--- a/dev/lib/except/error.hpp
+++ b/dev/lib/except/error.hpp
@@ -4,17 +4,17 @@
* Copyright 2023-2025, Amlal El Mahrouss
*/
-#ifndef _SCL_ERR_HPP
-#define _SCL_ERR_HPP
+#ifndef _OCL_ERR_HPP
+#define _OCL_ERR_HPP
#include <stdexcept>
-namespace scl
+namespace ocl
{
using runtime_error = std::runtime_error;
using fix_error = runtime_error;
using math_error = runtime_error;
using cgi_error = runtime_error;
-} // namespace scl
+} // namespace ocl
-#endif // _SCL_ERR_HPP \ No newline at end of file
+#endif // _OCL_ERR_HPP \ No newline at end of file
diff --git a/dev/lib/fix/fix.hpp b/dev/lib/fix/fix.hpp
index 672b8a1..243d01c 100644
--- a/dev/lib/fix/fix.hpp
+++ b/dev/lib/fix/fix.hpp
@@ -5,8 +5,8 @@
* Copyright 2025, Amlal El Mahrouss
*/
-#ifndef _SCL_FIX_PARSER_HPP
-#define _SCL_FIX_PARSER_HPP
+#ifndef _OCL_FIX_PARSER_HPP
+#define _OCL_FIX_PARSER_HPP
#include <cstddef>
#include <cassert>
@@ -17,7 +17,7 @@
#include <sys/types.h>
#include <unistd.h>
-namespace scl::fix
+namespace ocl::fix
{
template <typename char_type>
class basic_visitor;
@@ -210,6 +210,6 @@ namespace scl::fix
}
using fix_tag_type = std::uint32_t;
-} // namespace scl::fix
+} // namespace ocl::fix
-#endif // ifndef _SCL_FIX_PARSER_HPP
+#endif // ifndef _OCL_FIX_PARSER_HPP
diff --git a/dev/lib/io/print.hpp b/dev/lib/io/print.hpp
index 8463b6f..307c06f 100644
--- a/dev/lib/io/print.hpp
+++ b/dev/lib/io/print.hpp
@@ -5,13 +5,13 @@
* Copyright 2025
*/
-#ifndef _SCL_PRINT_HPP
-#define _SCL_PRINT_HPP
+#ifndef _OCL_PRINT_HPP
+#define _OCL_PRINT_HPP
#include <iostream>
#include <ostream>
-namespace scl::io
+namespace ocl::io
{
template <typename T, typename... Args>
inline void print(T fmt, Args... other) noexcept
@@ -37,6 +37,6 @@ namespace scl::io
print(fmt...);
print();
}
-} // namespace scl::io
+} // namespace ocl::io
-#endif // ifndef _SCL_PRINT_HPP
+#endif // ifndef _OCL_PRINT_HPP
diff --git a/dev/lib/logic/equiv.hpp b/dev/lib/logic/equiv.hpp
index 05d0f53..5b022f8 100644
--- a/dev/lib/logic/equiv.hpp
+++ b/dev/lib/logic/equiv.hpp
@@ -8,7 +8,7 @@
#pragma once
/// @brief OCL equivalence namespace.
-namespace scl::equiv
+namespace ocl::equiv
{
template <typename T>
struct basic_hash_trait
@@ -101,4 +101,4 @@ namespace scl::equiv
return left_ / right_ == 1;
}
};
-} // namespace scl::equiv
+} // namespace ocl::equiv
diff --git a/dev/lib/logic/math.hpp b/dev/lib/logic/math.hpp
index 2d00595..e796eae 100644
--- a/dev/lib/logic/math.hpp
+++ b/dev/lib/logic/math.hpp
@@ -9,7 +9,7 @@
#include <cmath>
-namespace scl
+namespace ocl
{
template <std::size_t T>
struct is_non_boolean_integer final
@@ -32,4 +32,4 @@ namespace scl
constexpr inline auto not_a_number = NAN;
constexpr inline auto positive_infinity = INFINITY;
constexpr inline auto negative_infinity = -positive_infinity;
-} // namespace scl \ No newline at end of file
+} // namespace ocl \ No newline at end of file
diff --git a/dev/lib/logic/opt.hpp b/dev/lib/logic/opt.hpp
index 4ce999c..137460c 100644
--- a/dev/lib/logic/opt.hpp
+++ b/dev/lib/logic/opt.hpp
@@ -4,13 +4,13 @@
* Copyright 2023-2025, Amlal El Mahrouss
*/
-#ifndef _SCL_OPT_HPP
-#define _SCL_OPT_HPP
+#ifndef _OCL_OPT_HPP
+#define _OCL_OPT_HPP
#include <lib/except/error.hpp>
#include <utility>
-namespace scl
+namespace ocl
{
enum class return_type
{
@@ -129,6 +129,6 @@ namespace scl
{
return return_type::err;
}
-} // namespace scl
+} // namespace ocl
-#endif /* ifndef _SCL_OPT_HPP */
+#endif /* ifndef _OCL_OPT_HPP */
diff --git a/dev/lib/memory/tracked_ptr.hpp b/dev/lib/memory/tracked_ptr.hpp
index eb33bd0..d2f8450 100644
--- a/dev/lib/memory/tracked_ptr.hpp
+++ b/dev/lib/memory/tracked_ptr.hpp
@@ -16,7 +16,7 @@
#include <unistd.h>
#include <signal.h>
-namespace scl::memory
+namespace ocl::memory
{
template <typename T>
class tracked_allocator;
@@ -232,4 +232,4 @@ namespace scl::memory
::kill(::getpid(), SIGTRAP);
}
}
-} // namespace scl::memory
+} // namespace ocl::memory
diff --git a/dev/lib/net/modem.hpp b/dev/lib/net/modem.hpp
index 6c63399..0e935c7 100644
--- a/dev/lib/net/modem.hpp
+++ b/dev/lib/net/modem.hpp
@@ -5,8 +5,8 @@
* Copyright 2025, Amlal El Mahrouss
*/
-#ifndef _SCL_NET_NETWORK_HPP
-#define _SCL_NET_NETWORK_HPP
+#ifndef _OCL_NET_NETWORK_HPP
+#define _OCL_NET_NETWORK_HPP
#include <unistd.h>
#include <arpa/inet.h>
@@ -14,9 +14,9 @@
#include <string>
#include <cstddef>
-#define SCL_MODEM_INTERFACE : public scl::net::basic_modem
+#define OCL_MODEM_INTERFACE : public ocl::net::basic_modem
-namespace scl::net
+namespace ocl::net
{
class basic_modem;
@@ -151,6 +151,6 @@ namespace scl::net
return true;
}
};
-} // namespace scl::net
+} // namespace ocl::net
-#endif // ifndef _SCL_NET_NETWORK_HPP
+#endif // ifndef _OCL_NET_NETWORK_HPP
diff --git a/dev/lib/net/url.hpp b/dev/lib/net/url.hpp
index 52991f2..83ab587 100644
--- a/dev/lib/net/url.hpp
+++ b/dev/lib/net/url.hpp
@@ -13,7 +13,7 @@
/// @author Amlal El Mahrouss (amlal@nekernel.org)
/// @brief Parse URLs (in a non-standard way).
-namespace scl::net
+namespace ocl::net
{
template <typename char_type>
class basic_url;
@@ -91,4 +91,4 @@ namespace scl::net
return m_ss_.size() > 0 && this->protocol_exists();
}
};
-} // namespace scl::net
+} // namespace ocl::net
diff --git a/dev/lib/simd/basic_simd.hpp b/dev/lib/simd/basic_simd.hpp
index d182aaf..f14d977 100644
--- a/dev/lib/simd/basic_simd.hpp
+++ b/dev/lib/simd/basic_simd.hpp
@@ -1,8 +1,8 @@
/*
* File: simd/basic_simd.hpp
* Purpose: Basic SIMD backend C++ library.
- * Author: Amlal El Mahrouss (founder@snu.systems)
- * Copyright 2025, Amlal El Mahrouss, and SNUPowered, licensed under the BSL 1.0 license.
+ * Author: Amlal El Mahrouss (amlal@nekernel.org)
+ * Copyright 2025, Amlal El Mahrouss, licensed under the BSL 1.0 license.
*/
#pragma once
@@ -19,7 +19,7 @@ using simd_type = __m256;
using simd_type = float32x4_t;
#endif
-namespace scl::snu::simd
+namespace ocl::snu::simd
{
struct basic_simd_backend final
{
@@ -44,4 +44,4 @@ namespace scl::snu::simd
return "basic_simd_backend";
}
};
-} // namespace scl::snu::simd
+} // namespace ocl::snu::simd
diff --git a/dev/lib/simd/simd.hpp b/dev/lib/simd/simd.hpp
index 9234e67..e571b23 100644
--- a/dev/lib/simd/simd.hpp
+++ b/dev/lib/simd/simd.hpp
@@ -1,8 +1,8 @@
/*
* File: simd/simd.hpp
* Purpose: SIMD C++ library.
- * Author: Amlal El Mahrouss (founder@snu.systems)
- * Copyright 2025, Amlal El Mahrouss, and SNUPowered, licensed under the BSL 1.0 license.
+ * Author: Amlal El Mahrouss (amlal@nekernel.org)
+ * Copyright 2025, Amlal El Mahrouss, licensed under the BSL 1.0 license.
*/
#pragma once
@@ -12,7 +12,7 @@
/// @author Amlal El Mahrouss
/// @brief Basic SIMD processor.
-namespace scl::snu::simd
+namespace ocl::snu::simd
{
template <typename backend_type>
class basic_simd_processor
@@ -57,4 +57,4 @@ namespace scl::snu::simd
return processor_.isa();
}
};
-} // namespace scl::snu::simd
+} // namespace ocl::snu::simd
diff --git a/dev/lib/tests/hpptest.hpp b/dev/lib/tests/hpptest.hpp
index 63fc962..f5fa5c2 100644
--- a/dev/lib/tests/hpptest.hpp
+++ b/dev/lib/tests/hpptest.hpp
@@ -7,15 +7,15 @@
#pragma once
-namespace scl::hpptest
+namespace ocl::hpptest
{
typedef bool condition_type;
template <condition_type expr = true>
consteval inline void must_pass()
{
-#ifdef SCL_HPPTEST
- SCL_HPPTEST_ASSERT(expr);
+#ifdef OCL_HPPTEST
+ OCL_HPPTEST_ASSERT(expr);
#endif
}
-} // namespace scl::hpptest
+} // namespace ocl::hpptest
diff --git a/dev/lib/utility/cgi_writer.hpp b/dev/lib/utility/cgi_writer.hpp
index 87354ac..d54d9de 100644
--- a/dev/lib/utility/cgi_writer.hpp
+++ b/dev/lib/utility/cgi_writer.hpp
@@ -4,15 +4,15 @@
* Copyright 2023-2025, Amlal El Mahrouss.
*/
-#ifndef _SCL_CGI_WRITER_HPP
-#define _SCL_CGI_WRITER_HPP
+#ifndef _OCL_CGI_WRITER_HPP
+#define _OCL_CGI_WRITER_HPP
#include <lib/io/print.hpp>
#include <lib/utility/chunk_string.hpp>
#include <sstream>
#include <format>
-namespace scl
+namespace ocl
{
namespace cgi
{
@@ -21,7 +21,7 @@ namespace scl
class basic_writer
{
private:
- basic_writer& eval_(const scl::basic_chunk_string<char_type>& mime, const scl::basic_chunk_string<char_type>& ss) noexcept
+ basic_writer& eval_(const ocl::basic_chunk_string<char_type>& mime, const ocl::basic_chunk_string<char_type>& ss) noexcept
{
std::basic_stringstream<char_type> ss_out;
@@ -30,7 +30,7 @@ namespace scl
ss_out << std::format("Content-Length: {}\r\n\r\n", ss.str().size());
ss_out << ss.str();
- scl::io::print(ss_out.str());
+ ocl::io::print(ss_out.str());
return *this;
}
@@ -43,37 +43,37 @@ namespace scl
basic_writer(const basic_writer&) = default;
public:
- friend void operator<<(basic_writer& self, const scl::basic_chunk_string<char_type>& ss_in)
+ friend void operator<<(basic_writer& self, const ocl::basic_chunk_string<char_type>& ss_in)
{
self = self.eval_("text/plain", ss_in);
}
- basic_writer& binary(const scl::basic_chunk_string<char_type>& ss_in)
+ basic_writer& binary(const ocl::basic_chunk_string<char_type>& ss_in)
{
return this->eval_("application/octet-stream", ss_in);
}
- basic_writer& html(const scl::basic_chunk_string<char_type>& ss_in)
+ basic_writer& html(const ocl::basic_chunk_string<char_type>& ss_in)
{
return this->eval_("text/html", ss_in);
}
- basic_writer& xml(const scl::basic_chunk_string<char_type>& ss_in)
+ basic_writer& xml(const ocl::basic_chunk_string<char_type>& ss_in)
{
return this->eval_("application/xml", ss_in);
}
- basic_writer& json(const scl::basic_chunk_string<char_type>& ss_in)
+ basic_writer& json(const ocl::basic_chunk_string<char_type>& ss_in)
{
return this->eval_("application/json", ss_in);
}
- basic_writer& js(const scl::basic_chunk_string<char_type>& ss_in)
+ basic_writer& js(const ocl::basic_chunk_string<char_type>& ss_in)
{
return this->eval_("text/javascript", ss_in);
}
};
} // namespace cgi
-} // namespace scl
+} // namespace ocl
-#endif // ifndef _SCL_CGI_WRITER_HPP
+#endif // ifndef _OCL_CGI_WRITER_HPP
diff --git a/dev/lib/utility/chunk_string.hpp b/dev/lib/utility/chunk_string.hpp
index 6778173..4fe5cc2 100644
--- a/dev/lib/utility/chunk_string.hpp
+++ b/dev/lib/utility/chunk_string.hpp
@@ -5,12 +5,12 @@
* Copyright 2025, Amlal El Mahrouss
*/
-#ifndef SCL_UTILITY_CHUNK_STRING_HPP
-#define SCL_UTILITY_CHUNK_STRING_HPP
+#ifndef OCL_UTILITY_CHUNK_STRING_HPP
+#define OCL_UTILITY_CHUNK_STRING_HPP
#include <lib/core/includes.hpp>
-namespace scl
+namespace ocl
{
template <typename char_type, std::size_t max_chunk_size = 8196>
class basic_chunk_string;
@@ -89,7 +89,7 @@ namespace scl
void print() noexcept
{
- scl::io::print(packed_chunks_);
+ ocl::io::print(packed_chunks_);
}
};
@@ -98,5 +98,5 @@ namespace scl
{
fmt.print();
}
-} // namespace scl
-#endif // ifndef SCL_UTILITY_CHUNK_STRING_HPP
+} // namespace ocl
+#endif // ifndef OCL_UTILITY_CHUNK_STRING_HPP
diff --git a/dev/lib/utility/crc32.hpp b/dev/lib/utility/crc32.hpp
index 93347a8..ea09b94 100644
--- a/dev/lib/utility/crc32.hpp
+++ b/dev/lib/utility/crc32.hpp
@@ -5,8 +5,8 @@
* Copyright 2025, Amlal El Mahrouss.
*/
-#ifndef _SCL_CRC32_HPP
-#define _SCL_CRC32_HPP
+#ifndef _OCL_CRC32_HPP
+#define _OCL_CRC32_HPP
#include <cstdint>
#include <string>
@@ -15,7 +15,7 @@
/// @brief Crc32 implementation in C++
/// @author Amlal EL Mahrouss (amlal@nekernel.org)
-namespace scl::crc32
+namespace ocl::crc32
{
namespace detail
{
@@ -76,6 +76,6 @@ namespace scl::crc32
{
return detail::crc32(in.c_str(), in.size());
}
-} // namespace scl::crc32
+} // namespace ocl::crc32
-#endif // !_SCL_CRC32_HPP \ No newline at end of file
+#endif // !_OCL_CRC32_HPP \ No newline at end of file
diff --git a/dev/lib/utility/embfs.hpp b/dev/lib/utility/embfs.hpp
index 2738ae7..6da8874 100644
--- a/dev/lib/utility/embfs.hpp
+++ b/dev/lib/utility/embfs.hpp
@@ -5,8 +5,8 @@
* Copyright 2025, Amlal El Mahrouss.
*/
-#ifndef _SCL_EMBFS_HPP
-#define _SCL_EMBFS_HPP
+#ifndef _OCL_EMBFS_HPP
+#define _OCL_EMBFS_HPP
#include <cstdint>
#include <cstddef>
@@ -14,7 +14,7 @@
/// @brief A filesystem designed for tiny storage medias.
/// @author Amlal EL Mahrouss (amlal@nekernel.org)
-namespace scl::embfs
+namespace ocl::embfs
{
namespace traits
{
@@ -76,6 +76,6 @@ namespace scl::embfs
/// @brief Indexed node linear array.
typedef embfs_inode embfs_inode_arr_t[_inode_arr_len];
} // namespace traits
-} // namespace scl::embfs
+} // namespace ocl::embfs
-#endif // ifndef _SCL_EMBFS_HPP \ No newline at end of file
+#endif // ifndef _OCL_EMBFS_HPP \ No newline at end of file
diff --git a/dev/tests/chunk_string/chunk_test.cc b/dev/tests/chunk_string/chunk_test.cc
index b24b332..ad3d31b 100644
--- a/dev/tests/chunk_string/chunk_test.cc
+++ b/dev/tests/chunk_string/chunk_test.cc
@@ -16,7 +16,7 @@ TEST(ChunkTest, BasicChunkUsage)
auto start = std::chrono::high_resolution_clock::now();
- scl::basic_chunk_string<char, 1000000> optimized;
+ ocl::basic_chunk_string<char, 1000000> optimized;
for (unsigned i = 0; i < iterations; ++i)
{
diff --git a/dev/tests/fix_basic/fix_test.cc b/dev/tests/fix_basic/fix_test.cc
index 5457f21..1c80716 100644
--- a/dev/tests/fix_basic/fix_test.cc
+++ b/dev/tests/fix_basic/fix_test.cc
@@ -10,9 +10,9 @@
TEST(FIXTest, BasicFIXUsage)
{
- scl::fix::basic_visitor<char> basic_visitor;
- scl::fix::basic_range_data<char> fix = basic_visitor.visit("8=FIX.4.2|9=65|35=A|49=SERVER|56=CLIENT|34=177|52=20090107-18:15:16|98=0|108=30|10=062|");
+ ocl::fix::basic_visitor<char> basic_visitor;
+ ocl::fix::basic_range_data<char> fix = basic_visitor.visit("8=FIX.4.2|9=65|35=A|49=SERVER|56=CLIENT|34=177|52=20090107-18:15:16|98=0|108=30|10=062|");
- EXPECT_EQ(fix.magic_, scl::fix::detail::begin_fix());
+ EXPECT_EQ(fix.magic_, ocl::fix::detail::begin_fix());
EXPECT_TRUE(fix.is_valid());
}
diff --git a/dev/tests/network_basic/net_test.cc b/dev/tests/network_basic/net_test.cc
index 4bd3a9f..61d0b28 100644
--- a/dev/tests/network_basic/net_test.cc
+++ b/dev/tests/network_basic/net_test.cc
@@ -12,8 +12,8 @@
TEST(NetworkTest, BasicNetworkUsage)
{
- scl::net::basic_modem modem;
- modem.construct<AF_INET, SOCK_STREAM, 8000>(scl::net::basic_modem::local_address_ip4, true);
+ ocl::net::basic_modem modem;
+ modem.construct<AF_INET, SOCK_STREAM, 8000>(ocl::net::basic_modem::local_address_ip4, true);
EXPECT_TRUE(modem.is_valid());
diff --git a/dev/tests/tracked_ptr_basic/tracked_ptr_test.cc b/dev/tests/tracked_ptr_basic/tracked_ptr_test.cc
index decae88..1e97188 100644
--- a/dev/tests/tracked_ptr_basic/tracked_ptr_test.cc
+++ b/dev/tests/tracked_ptr_basic/tracked_ptr_test.cc
@@ -10,16 +10,16 @@
TEST(TrackedPtrTest, BasicTrackedPtrUsage)
{
- scl::memory::tracked_ptr<int> ptr = scl::memory::make_tracked<int>(42);
+ ocl::memory::tracked_ptr<int> ptr = ocl::memory::make_tracked<int>(42);
ASSERT_TRUE(ptr);
EXPECT_EQ(*ptr, 42);
- scl::memory::tracked_ptr<int> ptr2;
+ ocl::memory::tracked_ptr<int> ptr2;
- scl::memory::swap(ptr, ptr2);
+ ocl::memory::swap(ptr, ptr2);
ptr2.reset();
- EXPECT_EQ(scl::memory::tracked_ptr<int>::manager().allocator().allocated_count_, 1);
+ EXPECT_EQ(ocl::memory::tracked_ptr<int>::manager().allocator().allocated_count_, 1);
} \ No newline at end of file
diff --git a/dev/tests/tracked_ptr_leak/tracked_ptr_test.cc b/dev/tests/tracked_ptr_leak/tracked_ptr_test.cc
index 375fb35..f349f47 100644
--- a/dev/tests/tracked_ptr_leak/tracked_ptr_test.cc
+++ b/dev/tests/tracked_ptr_leak/tracked_ptr_test.cc
@@ -10,10 +10,10 @@
TEST(TrackedPtrTest, LeakTrackedPtrUsage)
{
- scl::memory::tracked_ptr<int>* ptr = new scl::memory::tracked_ptr<int>(42);
- scl::memory::tracked_ptr<int>* ptr2 = new scl::memory::tracked_ptr<int>(42);
- scl::memory::tracked_ptr<int>* ptr3 = new scl::memory::tracked_ptr<int>(42);
+ ocl::memory::tracked_ptr<int>* ptr = new ocl::memory::tracked_ptr<int>(42);
+ ocl::memory::tracked_ptr<int>* ptr2 = new ocl::memory::tracked_ptr<int>(42);
+ ocl::memory::tracked_ptr<int>* ptr3 = new ocl::memory::tracked_ptr<int>(42);
- EXPECT_EQ(scl::memory::tracked_ptr<int>::manager().allocator().allocated_count_, 3);
- ASSERT_TRUE(scl::memory::tracked_ptr<int>::manager().allocator().deallocated_count_ == 0);
+ EXPECT_EQ(ocl::memory::tracked_ptr<int>::manager().allocator().allocated_count_, 3);
+ ASSERT_TRUE(ocl::memory::tracked_ptr<int>::manager().allocator().deallocated_count_ == 0);
} \ No newline at end of file