Joseph Ryan wrote:
Can someone provide clarification on what mixing languages will look like in practice, or point me to where its explained?
<delurk> Warning. This is perl 7 and a half:
#!/usr/bin/perl -w use prolog;
prolog: # prolog tells us:
needs_support_of(Db, Da):- designer(A, Da), designer(B, Db), needs(A, B).
designer(perl, larry). designer(parrot, dan). needs(perl, parrot).
prolog. ; # or some other end-quote
for needs_support_of { print; # prints 1st in the signature of the unification, # predicate, 2nd .. nth in the signature of the # match (for one member of the result). }
__END__
</delurk>