Value here is checksum, basic value, no need to clone it. There is a need to clone only arrays and hashes.
This code is not pretty, we really should use small classes for that.