From f2068b5783fff01526d87b7c8e9d733023803b98 Mon Sep 17 00:00:00 2001 From: Lassi Kortela Date: Sun, 11 Aug 2019 23:27:12 +0300 Subject: [PATCH] Add missing const qualifiers --- c/cvalues.h | 4 ++-- c/flisp.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/c/cvalues.h b/c/cvalues.h index dfdd396..42b822a 100644 --- a/c/cvalues.h +++ b/c/cvalues.h @@ -206,14 +206,14 @@ value_t cvalue_static_cstring(const char *str) return cvalue_from_ref(stringtype, (char *)str, strlen(str), NIL); } -value_t string_from_cstrn(char *str, size_t n) +value_t string_from_cstrn(const char *str, size_t n) { value_t v = cvalue_string(n); memcpy(cvalue_data(v), str, n); return v; } -value_t string_from_cstr(char *str) +value_t string_from_cstr(const char *str) { return string_from_cstrn(str, strlen(str)); } diff --git a/c/flisp.h b/c/flisp.h index a00e359..cb01ef8 100644 --- a/c/flisp.h +++ b/c/flisp.h @@ -336,8 +336,8 @@ value_t size_wrap(size_t sz); size_t toulong(value_t n, char *fname); value_t cvalue_string(size_t sz); value_t cvalue_static_cstring(const char *str); -value_t string_from_cstr(char *str); -value_t string_from_cstrn(char *str, size_t n); +value_t string_from_cstr(const char *str); +value_t string_from_cstrn(const char *str, size_t n); int fl_isstring(value_t v); int fl_isnumber(value_t v); int fl_isgensym(value_t v);