~sircmpwn/hare-dev

This thread contains a patchset. You're looking at the original emails, but you may wish to use the patch review UI. Review patch
1

[PATCH v3] strings::fromc: update documentation about invalid utf8

Details
Message ID
<20230212234155.26451-1-evan@d2evs.net>
DKIM signature
missing
Download raw message
Patch: +1 -1
Signed-off-by: Evan Johnston <evan@d2evs.net>
---
 strings/cstrings.ha | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/strings/cstrings.ha b/strings/cstrings.ha
index 8e6dec57..9348efea 100644
--- a/strings/cstrings.ha
+++ b/strings/cstrings.ha
@@ -27,7 +27,7 @@ export fn fromc_unsafe(cstr: *const char) const str = {
};

// Converts a C string to a Hare string in O(n). If the string is not valid
// UTF-8, abort.
// UTF-8, return encoding::utf8::invalid.
export fn fromc(cstr: *const char) (const str | utf8::invalid) = {
	let s = fromc_unsafe(cstr);
	return if (utf8::valid(s)) s else utf8::invalid;
-- 
2.39.1
Details
Message ID
<CQGZER0DLX1U.2W4CK8Q1GH5B4@monch>
In-Reply-To
<20230212234155.26451-1-evan@d2evs.net> (view parent)
DKIM signature
missing
Download raw message
thanks!

To git@git.sr.ht:~sircmpwn/hare
   3dff5c25..90f29aff  master -> master

with added [[]]
Reply to thread Export thread (mbox)