From: Pavol Droba (droba_at_[hidden])
Date: 2004-09-14 10:55:29
On Tue, Sep 14, 2004 at 09:34:11AM -0400, David Abrahams wrote:
> "G. Wang" <visionsoft_at_[hidden]> writes:
> >> I'm interested. My first question would be, "what kinds of real
> >> problems can I solve better/more easily/more expressively with UBL
> >> than with approaches we already have available?" That's the test that
> > UBL allows you to write Prolog-like code directly inside C++. The current
> > Prolog is modeled directly to the Prolog standard. So IMHO your question is
> > equivalent to
> > "what kind of real problems can I solve better/more easily/more expressively
> > with Prolog than with approaches we already have available in C++?"
> > Prolog is the preferred language in the field of AI, expert systems,
> > business logics, etc. There are lots of discussions about why Prolog
> > is better in those areas than traditional procedure-oriented or
> > object-oriented languages. I don't think that I can cover the
> > reasons in just a few paragraph.
> It's not quite equivalent. You have to ask whether a _C++ Program_
> would benefit enough from that paradigm to make it worthwhile to
> suffer the imperfect expression of it that you can achieve in a
> FC++ is modeled directly on Haskell, and I fully believe that there
> are real problems that one would choose to solve first in Haskell, but
> that didn't turn out to mean that a translation into C++ could provide
> compelling advantages to people already writing software in C++.
> Please take this question seriously. We all felt really badly about
> not accepting FC++ into Boost at the end of its formal review, which
> was a substantial emotional/time investment for its author. It was a
> really interesting library, but it seemed to fail a crucial
> utility/practicality test. I don't want something like that to
> happen to you.
I'd like to add my penny to this discussion. I'm not expert in the area
of the logical programmig, but I think, that there is a crucial difference
between FC++ and prolog library in the means of additional value to
Funcional programming is quite similar to C++ in the respect, that programmer
writes "how the solution should be computed". On the other hand, in prolog
the approach is different, because one writes "how the solution should look like"
and the engine provides the means to achieve it.
What I'm trying to tell (in very simple words) is that FC++ just allows you
to write a program in different syntax, while the prolog library enables
you to write it in a different way.
Therefore I think, that library like this (if done properly) can be viable
addition to boost. Even if it will be only in the form of unification/backtrack engine.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk