Implicit Parameters for Logic Programming

Research output: Contribution to book/anthology/report/proceedingArticle in proceedingsResearchpeer-review

DOI

Implicit parameters allow programmers to omit certain arguments from function calls and have them automatically inferred by the compiler based on their types. At every call site, the compiler determines the values of the implicit parameters based on their declared types and the bindings currently in implicit scope. The programmer controls this mechanism in two ways: by adding bindings to the implicit scope, or by explicitly providing the implicit parameters for the function call.

Implicit parameters are known from functional and object-oriented languages such as Haskell and Scala. In recent years, more languages have added support for implicit parameters, including Agda, Coq, and Idris. Implicit parameters have played an impressive role as the foundation for a broad range of language features such as type classes, capability and effect systems, software transactional memory, macros, and more.

In this paper, we propose a design of implicit parameters for typed Horn clause based logic programming languages, such as Datalog and Prolog. We illustrate the usefulness of implicit parameters and show how they support logic programming in the large. We explore some of the differences that arise between implicit parameters in functional languages and in logic languages.

Original languageEnglish
Title of host publicationProceedings of the 20th International Symposium on Principles and Practice of Declarative Programming
Editors David Sabel, Peter Thiemann
Number of pages14
Place of publicationNew York, NY, USA
PublisherAssociation for Computing Machinery
Publication year3 Sep 2018
Article number14
ISBN (print)978-1-4503-6441-6
DOIs
Publication statusPublished - 3 Sep 2018
Externally publishedYes
EventInternational Symposium on Principles and Practice of Declarative Programming - Frankfurt am Main, Germany
Duration: 3 Sep 20185 Sep 2018
Conference number: 20
http://ppdp-lopstr-18.cs.uni-frankfurt.de/ppdp18.html

Conference

ConferenceInternational Symposium on Principles and Practice of Declarative Programming
Nummer20
LandGermany
ByFrankfurt am Main
Periode03/09/201805/09/2018
Internetadresse
SeriesPPDP '18

    Research areas

  • typed logic programming, implicit parameters

See relations at Aarhus University Citationformats

ID: 138364642