Re: ISSUE-22: Proposal based on sh:hasShape

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256



On 06/17/2015 02:11 AM, Holger Knublauch wrote:
> On 6/17/2015 2:35, Peter F. Patel-Schneider wrote:
>> -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256
>> 
>> 
>> 
>> On 06/15/2015 05:35 PM, Holger Knublauch wrote:
>>> On 6/15/2015 23:35, Peter F. Patel-Schneider wrote:
>>>>> Wouldn't this problem be resolved by disallowing memoizing? 
>>>>> sh:hasShape is our own function that we can define in whatever
>>>>> way we want.
>>>> Some form of memoizing is needed in procedural approaches to
>>>> recursion so that loops terminate.
>>> I don't see why. In my proposal sh:hasShape will terminate on the
>>> first truly recursive call (with exactly the same arguments).
>> This is a simple form of memoization.
>> 
>>> Do you have a counter example?
>> A counter example to what?  That some form of memoizing is needed?
> 
> I am looking for an example where my proposal with sh:hasShape (throwing
> an exception on recursion) would still lead to infinite loops.

I don't have an example at hand that would cause an implementation of
sh:hasShape that cuts off calls with the same arguments as a call higher in
the call stack to go into an infinite loop.

That doesn't mean that such an implementation does the right thing, of course.

[...]


> Regards, Holger

peter

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQEcBAEBCAAGBQJVgZPnAAoJECjN6+QThfjzkMgH/A4ENJTzwapFYavWTWsswfwH
2ICm5A0XxdZoeFhXfgoK7qNztgDO8IhYgpXV+N0CNkeqnm3xGxrd1gwSjt+e1QBX
2RiSQyBvNOihfpe5NBCylWGLgAUKDDmvcA99TEfpnZIP0RHe+tdq1biGmlO0ayy3
DxzJv5tmLYPFOghxEhl8EpCKZhsivMjN7BQ3Mx2EcGp4etVrHY+TXYFUDddySv42
VcuuTj4EiqTcvSyT+C0izO8+oggtGUYE2WxNKMSMKqgFF1VkAwFgWxW8CL4RA62N
3+4E6zFnjhTSzZanVDGxTa+7Y43wchZEZfKIoKz0I7WDlEgrtxj+CFYJP2E7Xvg=
=SZAe
-----END PGP SIGNATURE-----

Received on Wednesday, 17 June 2015 15:36:39 UTC