Efficient string copying and concatenation in C 169 points by beefhash·2636 days ago·developers.redhat.com·Show in HN
Efficiency looks past current deficiency.
We have the empty string: "\0"
We have the null string: NULL
There is no concept of an INVALID string, as float has NAN.
This would be the result of trying to copy a string to a buffer that is too small.
Or sprintf() into a small buffer.
Or a raw string parsed as UTF-8 and is invalid.
Correctness over efficiency.