No monitor for immutable class instances?

bearophile bearophileHUGS at lycos.com
Mon Mar 11 18:54:46 PDT 2013


Maybe a stupid question: an immutable class instance can't 
change, so is it possible and is it a good idea to remove (to not 
add) the monitor pointer field from immutable class instances, 
saving memory and allowing them to store one more word in the 
same amount of memory?

Bye,
bearophile


More information about the Digitalmars-d-learn mailing list