Skip to main content Accessibility help
×
Hostname: page-component-7479d7b7d-wxhwt Total loading time: 0 Render date: 2024-07-10T11:18:43.157Z Has data issue: false hasContentIssue false

6 - Theory into practice

Published online by Cambridge University Press:  05 May 2010

Mark P. Jones
Affiliation:
University of Nottingham
Get access

Summary

This chapter describes a number of features that might be useful in practical work with qualified types. We adopt a less rigourous approach than in previous chapters and we do not attempt to deal with all of the technical issues that are involved.

Section 6.1 suggests a number of techniques that can be used to reduce the size of the predicate set in the types calculated by the type inference algorithm, resulting in smaller types that are often easier to understand. As a further benefit, the number of evidence parameters in the translation of an overloaded term may also be reduced, leading to a potentially more efficient implementation.

Section 6.2 shows how the use of information about satisfiability of predicate sets may be used to infer more accurate typings for some terms and reject others for which suitable evidence values cannot be produced.

Finally, Section 6.3 discusses the possibility of adding the rule of subsumption to the type system of OML to allow the use of implicit coercions from one type to another within a given term.

It would also be useful to consider the task of extending the language of OML terms with constructs that correspond more closely to concrete programming languages such as recursion, groups of local binding and the use of explicit type signatures. One example where these features have been dealt with is in the proposed static semantics for Haskell given in (Peyton Jones and Wadler, 1992) but, for reasons of space, we do not consider this here.

Type
Chapter
Information
Qualified Types
Theory and Practice
, pp. 67 - 77
Publisher: Cambridge University Press
Print publication year: 1994

Access options

Get access to the full version of this content by using one of the access options below. (Log in options will check for institutional or personal access. Content may require purchase if you do not have access.)

Save book to Kindle

To save this book to your Kindle, first ensure coreplatform@cambridge.org is added to your Approved Personal Document E-mail List under your Personal Document Settings on the Manage Your Content and Devices page of your Amazon account. Then enter the ‘name’ part of your Kindle email address below. Find out more about saving to your Kindle.

Note you can select to save to either the @free.kindle.com or @kindle.com variations. ‘@free.kindle.com’ emails are free but can only be saved to your device when it is connected to wi-fi. ‘@kindle.com’ emails can be delivered even when you are not connected to wi-fi, but note that service fees apply.

Find out more about the Kindle Personal Document Service.

  • Theory into practice
  • Mark P. Jones, University of Nottingham
  • Book: Qualified Types
  • Online publication: 05 May 2010
  • Chapter DOI: https://doi.org/10.1017/CBO9780511663086.007
Available formats
×

Save book to Dropbox

To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Dropbox.

  • Theory into practice
  • Mark P. Jones, University of Nottingham
  • Book: Qualified Types
  • Online publication: 05 May 2010
  • Chapter DOI: https://doi.org/10.1017/CBO9780511663086.007
Available formats
×

Save book to Google Drive

To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Google Drive.

  • Theory into practice
  • Mark P. Jones, University of Nottingham
  • Book: Qualified Types
  • Online publication: 05 May 2010
  • Chapter DOI: https://doi.org/10.1017/CBO9780511663086.007
Available formats
×