Re: [E-devel] Eolian property setters with return values

2019-10-28 Thread Xavi Artigas
> > IMO, we should just use a typedef for a known type which generators > can use to know that it means error, and the typedef documentation > can mention if false means error, or true means error. Which Eina_Bool > is not explicit about. > Agreed! Let's move forward with

Re: [E-devel] Eolian property setters with return values

2019-10-25 Thread Felipe Magno de Almeida
On Fri, Oct 25, 2019 at 5:44 AM Xavi Artigas wrote: > > > > > As for having an error_return flag/type, this also seems fine from a > > functional and documentation perspective, though it feels a bit strange and > > not-intuitive to have a different keyword/return type specific to property > > set

Re: [E-devel] Eolian property setters with return values

2019-10-25 Thread Xavi Artigas
> > As for having an error_return flag/type, this also seems fine from a > functional and documentation perspective, though it feels a bit strange and > not-intuitive to have a different keyword/return type specific to property > set methods than is used for methods which return bool. > We could

Re: [E-devel] Eolian property setters with return values

2019-10-21 Thread Mike Blumenkrantz
Hi, I think either proposal is reasonable. In the case where "bool return on property set indicates success", this can be enforced in eolian since it's a combination of property+typereturn, and it can be documented (and expanded on automatically in doc generation) to be more descriptive for

Re: [E-devel] Eolian property setters with return values

2019-10-21 Thread Tom Hacohen
On 21/10/2019 18:54, Xavi Artigas wrote: >> >> Maybe in general we need a way to mark a return/parameter as an error >> indicator? It's just a half-baked thought, though maybe worth exploring. >> > > There's already a couple of ideas on Phab in this direction: Add custom > tags to Eolian (

Re: [E-devel] Eolian property setters with return values

2019-10-21 Thread Tom Hacohen
On 21/10/2019 18:51, Marcel Hollerbach wrote: > On 10/21/19 5:37 PM, Tom Hacohen wrote: >> I agree it's most of them, though it's not all of them. IIRC there are >> some that indicate "nothing happened", at least in textblock. It >> shouldn't be too hard to fix these though. >> >> Maybe in

Re: [E-devel] Eolian property setters with return values

2019-10-21 Thread Xavi Artigas
> > Maybe in general we need a way to mark a return/parameter as an error > indicator? It's just a half-baked thought, though maybe worth exploring. > There's already a couple of ideas on Phab in this direction: Add custom tags to Eolian ( https://phab.enlightenment.org/T8294 ) or use Eina.Error

Re: [E-devel] Eolian property setters with return values

2019-10-21 Thread Marcel Hollerbach
On 10/21/19 5:37 PM, Tom Hacohen wrote: I agree it's most of them, though it's not all of them. IIRC there are some that indicate "nothing happened", at least in textblock. It shouldn't be too hard to fix these though. Maybe in general we need a way to mark a return/parameter as an error

Re: [E-devel] Eolian property setters with return values

2019-10-21 Thread Tom Hacohen
I agree it's most of them, though it's not all of them. IIRC there are some that indicate "nothing happened", at least in textblock. It shouldn't be too hard to fix these though. Maybe in general we need a way to mark a return/parameter as an error indicator? It's just a half-baked thought,

[E-devel] Eolian property setters with return values

2019-10-21 Thread Xavi Artigas
Hi people, We are encountering a problem when matching EO properties to C# properties, since the C# ones cannot have a return value. We mostly use return values in EO property setters to indicate error conditions and this is pretty easily matched to C# by throwing an exception. We just need to