Talk:Enforced immutability

From Rosetta Code
Revision as of 15:00, 25 June 2011 by rosettacode>Ledrug (C const: a joke)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

C const: a joke

The C const is such a joke. <lang C>void some_func(const int const *a) {

   ((int*)a)[0]++;

}</lang>Not even a compiler warning! So much for "immutable".