Eli   Documents Get Eli: Translator Construction Made Easy at SourceForge.net.
    Fast, secure and Free Open Source software downloads

General Information

 o Eli: Translator Construction Made Easy
 o Global Index
 o Frequently Asked Questions
 o Typical Eli Usage Errors


 o Quick Reference Card
 o Guide For new Eli Users
 o Release Notes of Eli
 o Tutorial on Name Analysis
 o Tutorial on Type Analysis
 o Typical Eli Usage Errors

Reference Manuals

 o User Interface
 o Eli products and parameters
 o LIDO Reference Manual
 o Typical Eli Usage Errors


 o Eli library routines
 o Specification Module Library

Translation Tasks

 o Lexical analysis specification
 o Syntactic Analysis Manual
 o Computation in Trees


 o LIGA Control Language
 o Debugging Information for LIDO
 o Graphical ORder TOol

 o FunnelWeb User's Manual

 o Pattern-based Text Generator
 o Property Definition Language
 o Operator Identification Language
 o Tree Grammar Specification Language
 o Command Line Processing
 o COLA Options Reference Manual

 o Generating Unparsing Code

 o Monitoring a Processor's Execution


 o System Administration Guide

Mail Home

Type Analysis

Next Chapter Table of Contents


Language designers define type systems in order to constrain the ways in which values may interact. These constraints protect the underlying representation of values from use that is contrary to the language designer's model, allowing early detection of a number of programming errors. The purpose of a compiler's type analysis task is to verify, insofar as possible, that the constraints of the type system have been obeyed.

Type analysis is complex, even for simple languages, but it is based upon a number of language-independent concepts. The type analysis of source text in a particular language can be described in terms of those concepts, by identifying constructs playing specific roles in the type system of that language. Once that identification has been made, most of the code required to carry out the analysis can be deduced automatically.

The modules of the type analysis library define a comprehensive collection of computational roles that can be played by symbols of an abstract syntax; they also define computational roles that characterize specific contexts within expressions. They allow you to focus your attention on the important issues and make strategic decisions without delving into implementation details.

This document is a reference manual for the type analysis specification modules. (For a tutorial on how to develop a type analyzer for a specific language, see Overview of Tutorial on Type Analysis.) Examples are drawn from a variety of languages. Our strategy is to provide only the specification fragments needed to illustrate the relevant principles. In most cases, these fragments will be LIDO rules. We expect that the meaning of the abstract syntax for these rules will be obvious, although we will sometimes show snippets of source code to make the application clearer.

Next Chapter Table of Contents