summaryrefslogtreecommitdiffhomepage
path: root/dev/lib/logic
diff options
context:
space:
mode:
Diffstat (limited to 'dev/lib/logic')
-rw-r--r--dev/lib/logic/equiv.hpp18
-rw-r--r--dev/lib/logic/math.hpp2
-rw-r--r--dev/lib/logic/opt.hpp6
3 files changed, 13 insertions, 13 deletions
diff --git a/dev/lib/logic/equiv.hpp b/dev/lib/logic/equiv.hpp
index 704e451..1d16958 100644
--- a/dev/lib/logic/equiv.hpp
+++ b/dev/lib/logic/equiv.hpp
@@ -2,7 +2,7 @@
* File: equiv.hpp
* Purpose: Equivalence runtime c++ header.
* Author: Amlal El Mahrouss (amlal@nekernel.org)
- * Copyright 2025, Amlal El Mahrouss, licensed under the MIT license.
+ * Copyright 2025, Amlal El Mahrouss, licensed under the Boost Software License.
*/
#pragma once
@@ -13,8 +13,8 @@ namespace ocl::equiv
template <typename T>
struct basic_hash_trait
{
- /// @brief hash from T's result.
- static typename T::result hash()
+ /// @brief hash from T's result_type.
+ static typename T::result_type hash()
{
static T val;
return val.hash();
@@ -63,9 +63,9 @@ namespace ocl::equiv
T left_ = 127, right_ = 127;
public:
- using result = T;
+ using result_type = T;
- constexpr result hash()
+ constexpr result_type hash()
{
return (left_ + right_) < 1;
}
@@ -79,9 +79,9 @@ namespace ocl::equiv
T left_ = 127, right_ = 127;
public:
- using result = T;
+ using result_type = T;
- constexpr result hash()
+ constexpr result_type hash()
{
return (left_ + right_) > 0;
}
@@ -94,9 +94,9 @@ namespace ocl::equiv
T left_ = 5, right_ = 3;
public:
- using result = T;
+ using result_type = T;
- constexpr result hash()
+ constexpr result_type hash()
{
return left_ / right_ == 1;
}
diff --git a/dev/lib/logic/math.hpp b/dev/lib/logic/math.hpp
index e796eae..ce73aa6 100644
--- a/dev/lib/logic/math.hpp
+++ b/dev/lib/logic/math.hpp
@@ -2,7 +2,7 @@
* File: math.hpp
* Purpose: Mathematics c++ header.
* Author: Amlal El Mahrouss (amlal@nekernel.org)
- * Copyright 2025, Amlal El Mahrouss.
+ * Copyright 2025, Amlal El Mahrouss, Licensed under the Boost Software License.
*/
#pragma once
diff --git a/dev/lib/logic/opt.hpp b/dev/lib/logic/opt.hpp
index ceee917..19f02df 100644
--- a/dev/lib/logic/opt.hpp
+++ b/dev/lib/logic/opt.hpp
@@ -1,7 +1,7 @@
/*
* File: opt.hpp
* Author: Amlal El Mahrouss,
- * Copyright 2023-2025, Amlal El Mahrouss
+ * Copyright 2023-2025, Amlal El Mahrouss, Licensed under the Boost Software License
*/
#ifndef _OCL_OPT_HPP
@@ -120,12 +120,12 @@ namespace ocl
return greater_than(std::forward<Lst>(arg)...) ? return_type::okay : return_type::err;
}
- inline return_type eval_true()
+ inline return_type eval_true() noexcept
{
return return_type::okay;
}
- inline return_type eval_false()
+ inline return_type eval_false() noexcept
{
return return_type::err;
}