The docsearch function is now working.

This commit is contained in:
2026-01-14 14:34:54 -05:00
parent 850b4aa43b
commit 03e9928e03
6 changed files with 163 additions and 68 deletions

View File

@@ -61,7 +61,7 @@ public:
}
}
// Read a single codepoint from a UTF16 string.
// Read a single UTF32 codepoint from a UTF16 string.
//
// Returns -1 if the string is empty. Returns -2 if the string
// starts with an invalid sequence.
@@ -96,7 +96,7 @@ public:
}
}
// Read a single codepoint from a UTF8 string.
// Read a single UTF32 codepoint from a UTF8 string.
//
// If the string_view starts with a valid codepoint, the codepoint
// is removed from the string_view and is returned.
@@ -109,7 +109,7 @@ public:
// If the string_view starts with a finish but invalid codepoint,
// returns -2.
//
static int32_t read_codepoint_utf8(std::string_view &source) {
static char32_t read_codepoint_utf8(std::string_view &source) {
size_t size = source.size();
if (size == 0) return -1;
@@ -161,7 +161,7 @@ public:
return codepoint;
}
// Convert a codepoint string into a UTF8-string.
// Convert a UTF32 string into a UTF8-string.
// If the codepoint string contains invalid codepoints, they're silently dropped.
//
static u8string utf32_to_utf8(const u32string &s) {