I use Object#freeze
to freeze the value of an object. I can write a function to deep-freeze a complex object structure. But neither will prevent me from assigning a new value to an object.
$O=cl()
$O.thorough_freeze
$O[:file] = "makefile" # => TypeError
$O[:commands][0] = "clean" # => TypeError
$O = "reticulate" # => TypeError
In C I say
int const * const ptr = argv;
How can I thoroughly freeze an identifier?