From 23d489c04101208f3f6e033338e89c4db9c9800c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C5=8Dshin?= Date: Thu, 6 Jun 2024 00:27:08 -0700 Subject: [PATCH] less (?) horrible set_big_capacity --- ctl/string.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ctl/string.h b/ctl/string.h index 12e42453a..e2cb4d16b 100644 --- a/ctl/string.h +++ b/ctl/string.h @@ -303,7 +303,8 @@ class string { if (c2 > __::big_mask) __builtin_trap(); - *((size_t *)__builtin_launder(blob) + 2) = ~__::big_mask | c2; + *(__builtin_launder(blob) + __::sso_max) = 0x80; + big()->c |= c2; } inline __::small_string* small() noexcept