Date: Fri, 31 Jan 2025 14:50:30 +0000
Why are you using "char32_t*" store a pointer to something that is unaligned?
Maybe don't do that?
If it isn't aligned to a char32_t, it can not be a char32_t right?
Does a "duck pointer" point to a "duck"?
I know that bitwise data alias is a thing, but why would you choose a type that is neither 1byte long nor has the same size and alignment requirements of the thing being aliased?
> Of course this will never happen -- but the C++ Standard accommodates it.
Then stop bringing that as an example. You are the only one bringing up this example. This isn't the issue.
Maybe don't do that?
If it isn't aligned to a char32_t, it can not be a char32_t right?
Does a "duck pointer" point to a "duck"?
I know that bitwise data alias is a thing, but why would you choose a type that is neither 1byte long nor has the same size and alignment requirements of the thing being aliased?
> Of course this will never happen -- but the C++ Standard accommodates it.
Then stop bringing that as an example. You are the only one bringing up this example. This isn't the issue.
Received on 2025-01-31 14:50:37