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

-----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?

> BTW I have fixed the issue with walking the AND and OR operands from left
> to right, as discussed yesterday:
> 
> https://github.com/w3c/data-shapes/commit/0b7a54857026b1ab1852912e60df99094b
5482d0

You
> 
have now stated that and and or are evaluated left to right and
short-circuit when they hit false for and and true for or.  (Well, except
for the bugs.)

What happens if the recursive shape is returning a value that overrides
false for and or true for or?

> Are there any other problems with the sh:hasShape approach?


> Thanks, Holger
> 


peter

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

iQEcBAEBCAAGBQJVgFAxAAoJECjN6+QThfjzHvYH/2gyK4uSyf7qAuq79gujCTtA
Noz/Ksdi68hzUDuCpA/oRZ83sRghcOfBtlBqs7WxMVF1rW7x4hX5+U/4z6II+hji
mi5i1k16xxwRuwwiNp2rCYUMiZBLHpMo+x5DCoHMIkXJf+YKydzx/pbqpvVh5l/+
/58Pl8F2Dg1WhwmfJYRfdOX5p/n2/sSBgncvxwdCKFpU482SrQubS2tyjsu3EN+5
uPQYe7BcZ8/VvU8vUtAvSUZcYbBTAzM+kpK3mJJmthFf1BUcvaq9i5KSCOQy8Llu
OXBDvKFZt9Uef7yn/MmHyE77qavyeExVP2f6sVX6ha5JjfbUrFW7aPswI4UV0fw=
=J9uh
-----END PGP SIGNATURE-----

Received on Tuesday, 16 June 2015 16:35:32 UTC