|
|
|
|
|
by renewiltord
494 days ago
|
|
This is a completely unreasonable API. It reminds me of the `mysql_real_escape_string` vs. `mysql_escape_string`. The default API must be the strict one. You should be able to configure it to be broken but silent truncation is an insane piece of functionality. There is no universe in which this is logical. One might as well just have everything return void* and then put in the documentation what type to cast to. The invariant is clearly a historical accident. As a mistake, it's fine. Everyone writes up things like that. But defending it as an affirmatively good decision is wild. |
|