On Mon, Dec 18, 2017 at 11:31 PM, Jean-Philippe AndrĂ© <[email protected]> wrote:
> Hi,
>
> On Tue, Dec 19, 2017 at 12:25 AM, Andrew Williams <[email protected]>
> wrote:
>
>> Hi,
>>
>> Is there a way that we can preserve type information when using
>> Eina_Future?
>>
>> For example on the Efl.Io.Manager "open" method I have to read the full
>> description to find it's return type:
>>  https://www.enlightenment.org/develop/api/efl/io/manager/method/open
>
>
> I believe in this specific case it should be declared as
>   return: future<Eina.File>;
>
> But I think this still generates Efl.Future stuff, rather than Eina.Future.
> Cedriiiic! :)
>
> That being said, without documentation it remains near impossible to guess
> the type.
> It would be nice to have some introspection, I think?

You're right, it should be declared as you said, but q66 still needs
to convert that part of the code, then we must properly annotate them.

but eina_future dispatches eina_value, which always carry a type...
then you can do something like:

printf("type %p (%s)\n", value.type, value.type ? value.type->name : NULL);

to discover what you received.

-- 
Gustavo Sverzut Barbieri
--------------------------------------
Mobile: +55 (16) 99354-9890

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
enlightenment-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to