2 ms·
It can't, because C doesn't have the ability to create library types as if they were built-ins.
by pjmlp 2y ago
It can't, because C doesn't have the ability to create library types as if they were built-ins.
- uecker 2y agoWhy would this be required?
- pjmlp 2y agoBecause otherwise there is no mechanism to introduce types, that can be used as built-is, while having the connection points across the language to enforce variants.
- uecker 2y agoWhat I do not get is the "can be used as built-in" part. What exactly does this mean? You can enforce invariants by encapsulating structures behind an API. This works fine in C (even better than in C++ IMHO).