*julia> **type GGG end*


*julia> **call(::Type{GGG}, d::Int) = d*

*call (generic function with 858 methods)*


*julia> **GGG(4)*

*4*


*julia> **GGG(2)*

*2*



Cheers


Tobias

Am Mittwoch, 14. Januar 2015 23:09:26 UTC+1 schrieb Petr Krysl:
>
> Hi Tobias,
>
> Is there an example of  the use  of this new syntax  for  0.4?
>
> Thanks,
>
> Petr
>
> On Sunday, January 11, 2015 at 12:20:39 PM UTC-8, Tobias Knopp wrote:
>>
>> The call syntax is part of 0.4
>>
>> Cheers
>>
>> Tobi
>>
>> Am Sonntag, 11. Januar 2015 19:35:06 UTC+1 schrieb Petr Krysl:
>>>
>>> On Sunday, January 11, 2015 at 10:22:05 AM UTC-8, Tim Holy wrote:
>>>>
>>>>
>>>> Already implement in julia 0.4. 
>>>>
>>>  
>>> Very cool! Just checking: are you saying that  the solution  I proposed  
>>> with the  empty  types  would actually address the problem of  functions 
>>> being inefficient  as when passed in as callbacks, and that this is now 
>>> part of 0.4? Or rather that the syntactic sugar of being able to call on 
>>> object is part of 0.4?
>>>
>>> Thanks,
>>>
>>> P
>>>
>>

Reply via email to