Couldn't you just extend the dictionary class to handle this using a  
pair of complementary Operator_Assigns functions??

Granted, you loose the loveliness that is auto-complete, and you  
sacrifice strongly typed keys, but still, it would give you...

d.fred = 5
d.harry = 10
d.herman = 7.5

integer = d.fred


Function Operator_Assigns(keyname as string, assigns v as variant)
        me.value(keyname) = v
End

Function Operator_Assigns(keyname as string) as variant
        if me.haskey(keyname) then
                return me.value(keyname)
        else
                return nil
        end
End


- Tom

On 26/03/2007, at 2:08 AM, Kem Tekinay wrote:

> On 3/25/07 11:45 AM, Theodore H. Smith at [EMAIL PROTECTED] wrote:
>
>> But one idea for a language addition, would be to allow for function
>> call type syntax.
>>
>> dim d as new dictionary
>>
>> d("fred") = 5
>> d("harry") = 10
>> d("herman") = 7.5
>
> Hey, I like this idea. So much, in fact, that I went to file a feature
> request, but it turns out that there is one already, and it's even  
> more
> extensive:
>
> <http://tinyurl.com/26kcee>
>
> (That's report bxulszrk.)
>
> And it turns out to have been filed by you, Theo, almost two years  
> ago. :-)
>
> ______________________________________________________________________ 
> ____
> Kem Tekinay                                                 (212)  
> 201-1465
> MacTechnologies Consulting                              Fax (914)  
> 242-7294
> http://www.mactechnologies.com                        Pager (917)  
> 491-5546
>
>   To join the MacTechnologies Consulting mailing list, send an e- 
> mail to:
>            [EMAIL PROTECTED]
>
>
>
>
>
>
>
>
> _______________________________________________
> Unsubscribe or switch delivery mode:
> <http://www.realsoftware.com/support/listmanager/>
>
> Search the archives:
> <http://support.realsoftware.com/listarchives/lists.html>

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to