First sorry for the delayed second mail --- I sent it only seconds after the first, but for some reason it only showed up after Raph's response.

On Jul 3, 2008, at 1:48 PM, Pavel wrote:
Isn't this normal? A structure is a list if it has a head and tail and
tail is also a list. So it should fail as soon as it figures out it has no
tail which could be significantly earlier than any other data is
available...

I agree, the funnny thing is only that IsList does behave differently for kinded FD vars and FS vars.

But Raphael already commented that there is an implementation limitation concerning type checking, so I likely will end up writing my private library of type checks which always checks for kinded variables to avoid unintended blocking programs (I took me some time to figure out that some constraints where not applied at all simply because some IsRecord just blocked for variables...)

Best
Torsten

On Wed, 2 Jul 2008, Torsten Anders wrote:

On Jul 2, 2008, at 11:09 AM, Torsten Anders wrote:
I just realised that IsAtom and IsRecord block on undetermined FD and
FSvariables.

{IsRecord {FD.decl}}

{IsAtom {FD.decl}}

{IsAtom {FS.var.decl}}

Is there a reason for that? I feel these functions should immediately return false for kinded variables -- they cannot become atoms or records anymore. However, it appears many other functions behave likewise, e.g.

{IsInt {FS.var.decl}}

Just to mention: there are counterexamples as well. For example,

{IsList {FD.decl}}

immediately returns false, but

{IsList {FS.var.decl}}

blocks again.

Best
Torsten




_________________________________________________________________________________
mozart-users mailing list                               
[email protected]
http://www.mozart-oz.org/mailman/listinfo/mozart-users

Reply via email to