Category:Imp77

From Rosetta Code
Language
Imp77
This programming language may be used to instruct a computer to perform a task.
Execution method: Compiled (machine code)
Garbage collected: No
Parameter passing methods: By value or by address
Type checking: Static
Lang tag(s): imp77
See Also:


Listed below are all of the tasks on Rosetta Code which have been solved using Imp77.

Imp77 is a general-purpose, procedural, imperative computer programming language developed around 1977 by the Computer Science Department at Edinburgh University. The original Imp was an incremental development of its predecessor, AtlasAutocode, via Imp9 .

Versions

  • Atlas Autocode was originally created by Tony Brooker as his response to the 1958 IAL proposal which was the prototype for Algol60. It was very similar to Algol 60 but without some of the problematic areas such as 'call-by-name'.
  • Imp(AA) was the first Imp compiler (running on the KDF9) to use the name Imp, but it was almost identical to Atlas Autocode apart from having removed a few unused language features such as %complex variables and minor syntax that was dependent on the use of the Flexowriter and the KDF9 character set, which happened when the compiler was modified to use the 7-bit ISO character set.
  • Imp9 was the final release of Imp on the ICL System 4/75. By this point Imp had acquired records and strings.
  • Impi was an interactive version of the Imp language based on the Imp9 specification, which compiled a statement at a time or a procedure at a time to executable code in memory. Although the Impi name meant "Imp Interpreter" it was not an interpreter in the sense of interpreting an intermediate code, but was rather a true dynamic and interactive compiler.
  • Iopt was the Imp9 compiler modernised and ported to the ICL 29XX range. This was the most fully-featured version of Imp until Imp77 was created.
  • Skimp was a cut-down version of the language, at about the same level of complexity as Atlas Autocode, used for teaching compiler-writing to third-year computer science students at Edinburgh University. It was also used as a bootstrapping compiler when porting imp to new systems.
  • Imp15 was an implementation of Imp for the PDP9 and PDP15 systems, which ran in 8K words (words being 18 bits).
  • Imp11 was a version of Imp, bootstrapped through Skimp but implementing most of the language, written to support the PDP11 processors used at Edinburgh for the communications network.
  • Imp77 was a full implementation of Imp supporting all language features, written by Peter Robertson of the Department of Computer Science in support of his PhD thesis on the subject of portable intermediate codes. Imp77 was adopted as the primary compiler of the Department of Computer Science at Edinburgh and made available on many architectures. Most Imp submissions to Rosetta Code will be in Imp77 because it is the only version of Imp remaining with a native compiler available (x86) although there are a few other architectures still usable under emulation. The current Imp77 compiler is a hobbyist revival and is to some extent still under development, lacking the extensive library support and runtime diagnostics that were present in Edinburgh University implementations.
  • Imp80 was an attempt to merge Iopt and Imp77 into a common subset language, as the versions of Imp used by the Edinburgh Regional Computing Center and the Department of Computer Science had diverged sufficiently by 1980, that much code was not compatible between the two versions. The standardisation process that Imp80 started was never completed as Edinburgh abandoned the use of Imp in the 1980's, under political pressure to switch to using languages with a broader code base.

Overview

Imp is structurally very similar to Algol 60 except that instead of Algol's "name" parameters which implement a somewhat broken call-by-substitution mechanism, Imp uses call-by-reference, passing the address of a variable instead, and implicitly de-referencing such variables within a procedure, without requiring explicit syntax to access them as would be done in C for example.

Stropping

Imp uses keywords rather than reserved words, and in principle keywords in an Imp program are written with underlining. However this was seldom done in practise (in fact the last implementation to support underlining was back when the language was still called Atlas Autocode) and the convention used was that alphabetic sequences introduced by a '%' character were to be considered as being underlined, with the underlining terminating on the first non-alphabetic character. Imp compilers applied a 'line reconstruction' phase to their input, converting underlined letters into an internal representation distinct from regular letters, whilst removing all spaces (but not line endings) from the input other than within quoted strings and characters.

It is however quite acceptable to show listings of Imp programs with underlined (or bold) keywords in place of %-stropped keywords.

Citation

Todo

Pages in category "Imp77"

The following 4 pages are in this category, out of 4 total.