(PUP-844) is_inherited readonly

Is_inherited should be read only since aces are not allow to specify that they
are inherited.
(PUP-1893) cache to_hash

Increase performance of to_hash with a variable that is invalidated when
properties are set.