There isn’t too much UB for it to be fixed.

Fil-C fixes it (albeit just for C, for now). CHERI fixes it (and it works great for C++). There are other systems that fix it, too.

Unfortunely Intel and AMD keep shoting themselves in regards to memory tagging implementations.