🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.prolog
Article #1248

Re: PDC prolog gripe/question

#1248
From: jgarland
Date: Sat, 13 Oct 1990 21:09
47 lines
2097 bytes
In article <90285.232430F0O@psuvm.psu.edu>, F0O@psuvm.psu.edu writes:
>      I've been reading over the section in the book on how you can have
> modules in PDC prolog.  You have to make what they call a 'project file'
> or what I call a make file.  This is ok.  What I don't like is:
> 
>      For each module, you have to put the name of the project at the top of
> the file.
> 
>      The next part is taken right out of the book, pg 76:
> 
>      ALL THE MODULES IN A PROJECT NEED TO HAVE EXACTLY THE SAME GLOBAL
> DATABASE AND GLOBAL DOMAINS DECLARATIONS.
> 
>      and pg 77:
> 
>      Global predicate declarations differ from local predicate declarations
> because they must contain a description of the flow pattern(s) by which
> each given predicate can be called.
> 
> 
> 
>      Good heavens!  This seems like a lot of work to me.  In Turbo Pascal,
> to use other modules, all you need is a:
> 
>      USES module1 module2 module3 ...
> 
> 
>      Also, if I read the book right, why would you want to make a DATABASE
> accessible to a module that might never use it?  This does not seem like
> good programming technique.
>      I do have to say, I have not tried any of this myself; just reading
> the book sounds bad enough to scare me away.  The Turbo pascal way of doing
> modules sounds more elegant to me.
>      Do other people feel the same way, or am I just not understanding
> something(quite possible :-) ).
> 

>

Personally, I just think of global declarations as .h files (in the C 
sense) and put them in include files.  But as that takes you back 
towards C...

John Garland

jgarland@mun                              Bitnet
jgarland@kean.ucs.mun.ca                  Internet
Technical Details
Message-ID: <145400@kean.ucs.mun.ca>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!stretch.cs.mun.ca!leif!jgarland
References: <90285.232430F0O@psuvm.psu.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!stretch.cs.mun.ca!leif!jgarland
From: jgarland@kean.ucs.mun.ca
Newsgroups: comp.lang.prolog
Subject: Re: PDC prolog gripe/question
Message-ID: <145400@kean.ucs.mun.ca>
Date: 13 Oct 90 21:09:26 GMT
References: <90285.232430F0O@psuvm.psu.edu>
Organization: Memorial University. St.John's Nfld, Canada
Lines: 47