|
|
|
|
|
by pornel
27 days ago
|
|
Depends how you define "can", because you can invent your own conventions not checked by the compiler, or even make a compile-to-C language. But more directly, C barely lets you define non-NULL pointers. It doesn't have pointers that guarantee the data behind them is initialized, it doesn't have never-leaves-this-thread data types. Const merely guarantees that you can't (strongly shouldn't) mutate data, not that it definitely won't be mutated by any thread. |
|
This is why I think a book is missing, people think C is much worse than it is because they do not understand what can be achieved.