View · Search · Index
No registered users in community xowiki
in last 10 minutes

XOTcl/NX mailing list by object move?

From: Scott Gargash <scottg_at_atc.creative.com>
Date: Sun, 19 Mar 2006 05:09:07 -0700

xotcl-bounces_at_alice.wu-wien.ac.at wrote on 03/19/2006 04:08:40 AM:

>
> On 19 Mar 2006, at 00:12, Scott Gargash wrote:
> >
> > When would you need the namespace of the object?
> I have only ever needed the namespace of an object which attaching
> traces to variables (f.ex. with Tk), but for that it is,
> unfortunately quite necessary.

I haven't used it yet, but doesn't the "trace" method handle this?

> > As an aside, I find Tcl's lack of true references to be one of its
> > nagging flaws.
> Yes, this is a problem. If Tcl had proper references then we could do
> garbage collection for objects. The problem is that Tcl's principle
> of everything being a string kind of conflicts with references.
> References can be represented as strings, although not very useful
> strings, but they really aren't strings. I mean, if the string output
> for a reference is 0x123456, but I generated that through some other
> string operations (or, say we lose the original Tcl object through
> various operations) then that will no longer necessarily work as a
> reference if the original is gone.

Amen, brother. For years I've tossed around thoughts on how to have references in Tcl, but I can't
come up with a way to do it without breaking "everything is a string". And if that breaks, well,
it's not Tcl anymore.

But I want lambdas. :)

> This is particularly problematic as Tcl still has quite a habit of
> losing that original representation which naturally I hope will be
> reduced in the future.

Where do you see this happening? Do you mean losing the original representation via shimmering, or
something else?

      Scott