3 ms·
The problem is that you have to do that by hand, and thus it will be possible to get out of sync with the actual requirements of the generated code, leading to
by Rusky 4y ago
The problem is that you have to do that by hand, and thus it will be possible to get out of sync with the actual requirements of the generated code, leading to C++-like template error messages that have to include the entire stack for you to make sense of what went wrong.
Or in other words, there are two parts to checking constraints: checking that the caller satisfies them, and checking that the callee doesn't accidentally rely on anything beyond those constraints. Zig's approach only gives you the first one.
- deleted 4y ago[deleted]