On Tuesday 16 March 2004 16:00, Gay, Jerry wrote:
> On Tuesday, March 16, 2004 7:32 AM, Jens Rieks wrote:
> > You can also use another namespace:
> >     store_global "TCL::InternalData", "globals", the_hash
> >     ...
> >     find_global the_hash, "TCL::InternalData", "globals"
>
> is there a good reason why the signatures are different for 'store_global'
> and 'find_global'? i can see the logic for either way, but a different
> argument list for each is inconsistant, and a bit confusing.
I had the same problem too, but I finally found out that it is consistent with 
the rest of the ops. The fist argument is an OUT for ops that return 
something; all parameter are IN for ops that "store" something (or are doing 
other things).

"OUT" examples:
add OUT, IN, IN
open OUT, IN, IN
read OUT, IN, IN
newsub OUT, IN, IN
getprop OUT, IN, IN

"IN" examples:
store_global( in STR, in STR, in PMC)
setprop( in STR, in STR, in PMC)
compreg(in STR, in PMC)
unless(in INT, inconst INT)
setp_ind(in INT, in PMC)
set_encoding(in STR, in INT)

> i know that store_global and find_global are new, and they aren't listed in
> ops.num yet, so modifying one of their signatures shouldn't affect too much
> code.
>
> where would i go about finding more info on this? i'm source diving now,
> but it's a deep pool and i'm not a very good swimmer yet. i'd like to
> submit a patch (if needed), or at least where a patch may make changes to
> this functionality.
>
> --jerry
jens

Reply via email to