4.22: adda/oop/read only:
. the interface view of "(readonly)
is that the usual obj' has accessors
that allow both read and write .
[4.28:
. generally though, the obj's body defines
when operations are allowed to do modifications
so an instance needs a tag that indicates
whether this obj' should be changing,
and then methods that normally do any mod's
need to check this bit .]
. also,
the need for read-only subtyping is common;
so, for syntax,
something compact is needed, like the (!)
but that's still unresolved
since that clutters the (/) pointer symbol;
ie, you want it compact like c,
but you don't want c's reputation of looking like
math's full-blown greek .
[4.28:
. it could be changed by an editor preference,
where type T read-only was displayed either as
(T!) or (T-ROM) .]
2010-04-30
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment