Path: utzoo!attcan!uunet!cs.utexas.edu!mailrus!ncar!tank!mimsy!alberto From: alberto@tove.umd.edu (Jose Alberto Fernandez R) Newsgroups: comp.lang.prolog Subject: Re: What does "extralogical" mean? Message-ID:Date: 27 Sep 89 15:49:47 GMT References: <2204@munnari.oz.au> Sender: nobody@mimsy.UUCP Organization: University of Maryland Computer Sc. Lines: 46 In-reply-to: ok@cs.mu.oz.au's message of 27 Sep 89 08:04:50 GMT >> The reason that I ask is that I was stunned to find a paper which >> described the Mycroft/O'Keefe type system as ``extralogical''. Now, >> we're talking about a type system where type declarations are >> syntactic sugar for certain Horn clauses, and where a predicate declaration >> pred p(T1, ..., Tn) >> is interpreted as saying that >> p(X1, ..., Xn) :- Body >> is to be read declaratively as >> p(X1, ..., Xn) :- isa(X1, T1), ..., isa(Xn, Tn), Body. >> (in essence, the type checks are ``factored'' out into the declaration.) >> I really can't see any side effects there, nor can I see how to simulate >> var/1 with this stuff, nor yet does it seem to me to lie outside the >> logic programming model. Is there some other sense of ``extralogical'' >> which does apply? Did presenting the system in proof theoretic rather >> than model theoretic terms damn it to extralogicality? Well, your ISA(Term, Type) predicate could be as extra-logical as VAR(Term) is. I think that it. For example, what happen if a variable is not instanciated when the predicate P is called? There are 3 alternatives: (1) The predicate fail, because the variable is not of the type at that time. (2) The variable is assumed to be of the type. No further checking is done. (3) The checking is delayed until the variable is instantiated, at that time the type checking is fired. Only the third option is not extra-logical, because the order in which the predicates are executed does not change the answer. The first 2 options are order-sensitive, that means that if I change the order of the calls in the clause the answer will be diferent (conjuctions are not conmutative) in other words, the denotational and operational semantics can be diferent. Jose Alberto. -- :/ \ Jose Alberto Fernandez R | INTERNET: alberto@tove.umd.edu :| o o | Dept. of Computer Sc. | :| ^ | Univesity of Marylad | :\ \_/ / College Park, MD 20742 |