summaryrefslogtreecommitdiff
path: root/lib/strings.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/strings.hpp')
-rw-r--r--lib/strings.hpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/strings.hpp b/lib/strings.hpp
new file mode 100644
index 0000000..ee0db95
--- /dev/null
+++ b/lib/strings.hpp
@@ -0,0 +1,14 @@
+#ifndef STRINGS_HPP
+#define STRINGS_HPP
+
+constexpr auto
+constexpr_strlen(const GLchar * const s)
+{
+ std::size_t ch {};
+ while (s[ch]) {
+ ch++;
+ }
+ return ch;
+}
+
+#endif