Re: [TF-LIB] first text for new library built-in functions

On 03/06/2010 8:43 PM, Gregory Williams wrote:
> On Jun 3, 2010, at 3:39 PM, Gregory Williams wrote:
>
>> On Jun 3, 2010, at 3:34 PM, Andy Seaborne wrote:
>>
>>> The prototype definitions define the types of arguments accepted by the function and that after evaluation of expressions.
>>
>> Ah, sorry. My mistake. I was misunderstanding the blockquoted prototypes in each section as something closer to grammar definitions (but didn't bother to actually check the grammar).
>
> After saying that, I think I'm still confused. Aren't IN and NOT IN similar to IF and COALESCE in that they treat evaluation errors differently?
>
> 2 IN (1/0, 2) yielding true seems like IN would have to function like COALESCE. Have I misunderstood how the evaluation happens?
>
> thanks,
> .greg
>

Good point: There is error magic here: it's in the &&

2 IN (1/0, 2) is equivalent to   2 = 1/0 || 2 = 2

and SPARQL || returns true if one side is true even if the other side is 
error.

Do you think putting "expression, ..." is sufficient?

	Andy

Received on Thursday, 3 June 2010 20:09:08 UTC