Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!bbn!oberon!randvax!narain From: narain@randvax.UUCP (Sanjai Narain) Newsgroups: comp.lang.prolog Subject: Re: Constraint satisfaction in LOG(F) Message-ID: <1942@randvax.UUCP> Date: 9 Apr 89 00:19:11 GMT References: <1632@kulcs.kulcs.uucp> Organization: Rand Corp., Santa Monica, Ca. Lines: 23 Lee, thanks for pointing out that make_list(ans,Z) should be used instead of reduce(ans,Z). My point was simply that coroutining can be accomplished efficiently, invisibly, and in *straight* Prolog. The underlying theoretical basis is well worked out in the form of completeness, computational determinism, confluence and optimality results. It is interesting that the NAC compiler can generate coroutining information automatically. I would be interested in knowing how general it is. Does the user ever have to specify coroutining annotations, or does the compiler always do the right thing? Can it handle arbitrary symbolic generate and test predicates, or did it do a good job because it knew about +? As to Bart's message, I never said that coroutining could not be programmed in Prolog. Of course it can be. My point was that its programming can greatly obscure the logic of the program. This does appear to be the case in Bart's program. Yes, it is a lot faster, but then wouldn't it be even faster in C? Regards. Sanjai Narain