Øyvind Harboe wrote:
> > The shorter one. But it is rather confusing to deal with the
> > different types of Tcl variables (or whatever they are?) which
> > have the same names, but obviously do different things.
> >
> > E.g. what exactly is the difference between _CHIPNAME and $CHIPNAME ?
> >
> > Would it be possible to get rid of one of the two classes of names?
> 
> It's just a convention.

Well, how deep does the rabbit hole go? What is the scope of the
convention? Never outside a single file?

And are they both the exact same kind of Tcl values/variables/apples?


> Perhaps we should think a bit about how we pass parameters to
> scripts?
> 
> Instead of:
> 
> source [find target/foo.cfg]
> 
> We could define a procedure:
> 
> load_target foo at91r40008

It may be a very good idea to move parameters out of the global
namespace that is Tcl variables into the exact scope where they
are relevant; call time between files - iff this is an accurate
model?

But watch out for the general find target/* vs. a specialized
load_target. Seeing the former made it clear to me that there was a
set of cfg files in a hierarchy somewhere and I could also easily
find it. load_target removes many bits of information and makes
things less transparent IMO. We don't need that so much..


//Peter
_______________________________________________
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development

Reply via email to