6 research outputs found

    Transforming floundering into success

    Full text link
    We show how logic programs with "delays" can be transformed to programs without delays in a way which preserves information concerning floundering (also known as deadlock). This allows a declarative (model-theoretic), bottom-up or goal independent approach to be used for analysis and debugging of properties related to floundering. We rely on some previously introduced restrictions on delay primitives and a key observation which allows properties such as groundness to be analysed by approximating the (ground) success set. This paper is to appear in Theory and Practice of Logic Programming (TPLP). Keywords: Floundering, delays, coroutining, program analysis, abstract interpretation, program transformation, declarative debuggingComment: Number of pages: 24 Number of figures: 9 Number of tables: non

    Two Aspects of Directional Types

    No full text
    The idea of directional types is to describe the computational behaviour of Prolog programs by associating an input and an output assertion to every predicate. The input assertion puts a restriction on the form of the arguments of the predicate in the initial atomic goals. The output assertion describes the form of the arguments at success, given that the predicate is called as specified by its input assertion. This paper discusses two aspects of directional types: the declarative notion of input-output correctness and the operational notion of call correctness . By separating these two concepts, we readily obtain better correctness criteria than those existing in the literature. We further show how directional types can be used for controlling execution of logic programs through a delay mechanism. 1 Introduction Recently there has been a growing interest in the notion of directional types for Prolog programs [6, 12, 2, 3, 1, 11]. This kind of prescriptive typing describes the intende..
    corecore