3 ms·
I think it's a good approach but I would do it the opposite way : create an UnsafeString and use that whenever your program takes external inputs. Then make it
by ajnin 5y ago
I think it's a good approach but I would do it the opposite way : create an UnsafeString and use that whenever your program takes external inputs. Then make it so that this UnsafeString can't be used directly but must always be consciously converted to (safe) String when using that data anywhere.