uinref (was Re: Not a bug but a feature?) 
Author Message
 uinref (was Re: Not a bug but a feature?)

Jon Meyer writes:
> An idea that has bounded around for a while is to introduce a special kind of
> ref to the system which can have an 'unassigned' contents, and which is
> treated specially by `=', i.e. if its contents are unassigned then `=' returns
> true and as a side effect sets the contents to the item that it is equal to.
> If it has an assigned contents then `=' returns true only if the contents
> are = to the item.

This could be done through the class_= procedure of the uniref. but =
only ever uses the class_= of the *top* argument of the stack. So

    vars funny = newuniref();
    3 = funny =>

would work, but

    vars funny = newuniref();
    funny = 3 =>

wouldn't. The only way around this would be for = to check the second
stack item as well, before choosing which class_= to use. This would be
quite an efficiency hit I think.


Mon, 18 Dec 1995 03:05:20 GMT  
 [ 1 post ] 

 Relevant Pages 

1. Not a bug but a feature?

2. Not a bug but a feature?

3. Why is this a feature, not a bug?

4. possible a bug (not a feature)

5. I am not deaf, but am I mute?

6. Bug #1464 in bug database is *not* fixed in Tcl/Tk 8.3.2

7. expr bug report not a bug

8. I am not visible!!!!!

9. IDX not CDX - What am I missing

10. I am not able to read a barcode from a image

11. I am not able to execute new.ccf in coboldpc when I call coboldpc through labview

12. I am looking for drivers of Tektronix TDS694C, which are not available on website


Powered by phpBB® Forum Software