2009-12-28

unifying records with parameters

9.3: adda/unifying records with parameters:
. how is the arg an instance of record literal
with need to specify in/out mode too?
. how to param as record when it has additional properties?
types have similar : const is in-mode .
const cannot got to out or inout,
also out mode is same as ptr to type,
which is a record type,
. to be functional
rather than say inout in the param spec's,
list {out, inout}'s along with externals affected
together with the function's return .
. how does server refer to caller's locals?
same as caller would?
server could be either {local, external} to caller,
so make naming relative to server
plus,
if external,
then expecting access to caller local is a special priveledge
say in/out caller`
instead of reserved words,
just predefined optional reserved .

11.15: adda/type/contracts vs parameter`type:
. contracts are the way to
diff'tween a param's working type
vs what its init'value can be .
. this idea might be merged with
exceptions being part of a function's spec' .
. it could be like this:
f(x.t= ( ~range -> exception, nil -> default),
);
however, as with c,
the user should be able to see param instantiation
as being just like an assignment:
all syntax should match how a record is being assigned .

No comments:

Post a Comment