JavaMemoryModel: Serialization and final fields

From: Doug Lea (dl@altair.cs.oswego.edu)
Date: Wed Aug 25 1999 - 06:15:12 EDT


> * It is apparent that the defaultReadObject function can set final
> fields.

If necessary, a kludgy, difficult to specify, but entirely plausible
solution is to say that any default readObject setting final fields
must arrange a GLOBAL memory barrier. But I think this (and all other
reference to serialization) could just be left unsaid, leaving VM
implementors to figure out how to simultaneously conform to memory and
serialization rules.

-- 
Doug Lea, Computer Science Department, SUNY Oswego, Oswego, NY 13126 USA
dl@cs.oswego.edu 315-341-2688 FAX:315-341-5424 http://gee.cs.oswego.edu/  
-------------------------------
JavaMemoryModel mailing list - http://www.cs.umd.edu/~pugh/java/memoryModel



This archive was generated by hypermail 2b29 : Thu Oct 13 2005 - 07:00:18 EDT