This is actually a very tricky bug: readResolve is not called anywhere, it is used during java deserialization, and if marked public, it is not inherited by the subclasses of Variables.