Publication | Open Access
Understanding functional dependencies via constraint handling rules
75
Citations
16
References
2006
Year
EngineeringType TheoryConstraintsNew ApplicationsSemanticsSoftware AnalysisFormal VerificationConstraint SolvingSyntaxDependently Typed ProgrammingLanguage StudiesDependency AnalysisComputer ScienceType SystemFunctional ProgrammingFunctional Programming LanguageAutomated ReasoningProgram AnalysisFormal MethodsSufficient ConditionsConstraint Handling RulesAbstract Functional DependenciesLinguistics
Functional dependencies extend Haskell type classes, but existing sufficient conditions are restrictive, and prior work used CHRs to describe type extensions. The paper reformulates functional dependencies using Constraint Handling Rules. The authors relax the restrictive conditions and propose sound extensions of functional dependencies via CHRs. These extensions enable sound, complete, and decidable type inference and broaden the applicability of functional dependencies.
Abstract Functional dependencies are a popular and useful extension to Haskell style type classes. We give a reformulation of functional dependencies in terms of Constraint Handling Rules (CHRs). In previous work, CHRs have been employed for describing user-programmable type extensions in the context of Haskell style type classes. Here, we make use of CHRs to provide for the first time a concise result that under some sufficient conditions, functional dependencies allow for sound, complete and decidable type inference. The sufficient conditions imposed on functional dependencies can be very limiting. We show how to safely relax these conditions and suggest several sound extensions of functional dependencies. Our results allow for a better understanding of functional dependencies and open up the opportunity for new applications.
| Year | Citations | |
|---|---|---|
Page 1
Page 1