TRAC (for Text Reckoning And Compiling) Language is a
programming language
A programming language is a system of notation for writing computer programs. Most programming languages are text-based formal languages, but they may also be graphical. They are a kind of computer language.
The description of a programming ...
developed between 1959–1964 by
Calvin Mooers
Calvin Northrup Mooers (October 24, 1919 – December 1, 1994), was an American computer scientist known for his work in information retrieval and for the programming language TRAC.
Early life
Mooers was a native of Minneapolis, Minnesota, atte ...
and first implemented on the
PDP-1
The PDP-1 (''Programmed Data Processor-1'') is the first computer in Digital Equipment Corporation's PDP series and was first produced in 1959. It is famous for being the computer most important in the creation of hacker culture at Massachusetts ...
in 1964 by
L. Peter Deutsch
L Peter Deutsch (born Laurence Peter Deutsch on August 7, 1946, in Boston, Massachusetts) is the founder of Aladdin Enterprises and creator of Ghostscript, a free software PostScript and PDF interpreter.
Deutsch's other work includes the Sma ...
.
It was one of three "first languages" recommended by
Ted Nelson
Theodor Holm Nelson (born June 17, 1937) is an American pioneer of information technology, philosopher, and sociologist. He coined the terms ''hypertext'' and ''hypermedia'' in 1963 and published them in 1965. Nelson coined the terms ''transcl ...
in ''
Computer Lib
''Computer Lib/Dream Machines'' is a 1974 book by Ted Nelson, printed as a two-front-cover paperback to indicate its " intertwingled" nature. Originally self-published by Nelson, it was republished with a foreword by Stewart Brand in 1987 by Micr ...
''. TRAC T64 was used until at least 1984, when Mooers updated it to TRAC T84.
Language description
TRAC is a purely text-based language — a kind of
macro language
In computer programming, a macro (short for "macro instruction"; ) is a rule or pattern that specifies how a certain input should be mapped to a replacement output. Applying a macro to an input is known as macro expansion. The input and output ...
. Unlike traditional ''ad hoc'' macro languages of the time, such as those found in assemblers, TRAC is well planned, consistent, and in many senses complete. It has explicit input and output operators, unlike the typical implicit I/O at the outermost macro level, which makes it simultaneously simpler and more versatile than older macro languages.
It also differs from traditional macro languages in that TRAC numbers are strings of digits, with integer arithmetic (without specific limits on maximum values) being provided through built-in ("primitive") functions. Arguably, one aspect of its completeness is that the concept of error is limited to events like lack of file space and requesting expansion of a string longer than the interpreter's working storage; what would in many languages be described as illegal operations are dealt with in TRAC by defining a result (often a null string) for every possible combination of a function's argument strings.
TRAC is a text-processing language,
also called a string processing language.
The emphasis on strings as strings is so strong that TRAC provides mechanisms for handling the language's own syntactic characters either in their syntactic roles or like any other character, and
self-modifying code
In computer science, self-modifying code (SMC) is code that alters its own instructions while it is executing – usually to reduce the instruction path length and improve performance or simply to reduce otherwise repetitively similar code, ...
has more the feel of a natural consequence of typical TRAC programming techniques than of being a special feature.
TRAC is, like
APL or
LISP
A lisp is a speech impairment in which a person misarticulates sibilants (, , , , , , , ). These misarticulations often result in unclear speech.
Types
* A frontal lisp occurs when the tongue is placed anterior to the target. Interdental lisping ...
, an
expression oriented language (in contrast to more typical
procedure-oriented languages), but unlike APL, it completely lacks operators. In most respects, it is a case of pure
functional programming
In computer science, functional programming is a programming paradigm where programs are constructed by Function application, applying and Function composition (computer science), composing Function (computer science), functions. It is a declar ...
.
TRAC is
homoiconic
In computer programming, homoiconicity (from the Greek words ''homo-'' meaning "the same" and ''icon'' meaning "representation") is a property of some programming languages. A language is homoiconic if a program written in it can be manipulated as ...
.
[
][
]
TRAC has in common with LISP a syntax that generally involves the presence of many levels of nested parentheses.
The main inspiration for TRAC came from three papers by
Douglas McIlroy
Malcolm Douglas McIlroy (born 1932) is a mathematician, engineer, and programmer. As of 2019 he is an Adjunct Professor of Computer Science at Dartmouth College.
McIlroy is best known for having originally proposed Unix pipelines and developed se ...
.
Intellectual property
Mooers trademarked the name TRAC in an effort to maintain his control over the definition of the language, an unusual and pioneering action at the time. At one point, he brought an intellectual property infringement suit against
DEC, alleging that a contract to deliver a mini-computer with a TRAC interpreter violated his rights. "The first issue of
Dr. Dobb's Journal
''Dr. Dobb's Journal'' (''DDJ'') was a monthly magazine published in the United States by UBM Technology Group, part of UBM plc, UBM. It covered topics aimed at computer programmers. When launched in 1976, DDJ was the first regular periodical focu ...
, one of the early publications in the personal computer field, has a vitriolic editorial against Mooers and his rapacity in trying to charge people for his computing language."
The name has since been used several times for unrelated
information technology
Information technology (IT) is the use of computers to create, process, store, retrieve, and exchange all kinds of data . and information. IT forms part of information and communications technology (ICT). An information technology system (I ...
projects, including a current
open source
Open source is source code that is made freely available for possible modification and redistribution. Products include permission to use the source code, design documents, or content of the product. The open-source model is a decentralized sof ...
project management system called
Trac
Trac is an open-source software, open-source, web-based Project management software, project management and bug tracking system. It has been adopted by a variety of organizations for use as a bug tracking system for both free and open-source s ...
.
Influence and usage
TRAC was later implemented on the
PDP-8
The PDP-8 is a 12-bit computing, 12-bit minicomputer that was produced by Digital Equipment Corporation, Digital Equipment Corporation (DEC). It was the first commercially successful minicomputer, with over 50,000 units being sold over the model's ...
,
PDP-10
Digital Equipment Corporation (DEC)'s PDP-10, later marketed as the DECsystem-10, is a mainframe computer family manufactured beginning in 1966 and discontinued in 1983. 1970s models and beyond were marketed under the DECsystem-10 name, especi ...
, and
PDP-11
The PDP-11 is a series of 16-bit minicomputers sold by Digital Equipment Corporation (DEC) from 1970 into the 1990s, one of a set of products in the Programmed Data Processor (PDP) series. In total, around 600,000 PDP-11s of all models were sold, ...
.
There have been various languages inspired by TRAC. To avoid any trouble with Mooers, they renamed primitives and/or used different metacharacters. In SAM76's case, primitives were added, according to Claude Kagan, "because TRAC is baby talk". In MINT's case, primitives were added to give access to a sophisticated text editor machinery.
* one perceived shortcoming of TRAC was lack of full extensibility: some TRAC primitive functions are sensitive to the distinction between a null (zero-character) argument and a nonexistent (non-delimited) one, but beyond its last non-null argument, a user-defined function cannot make the distinction.
SAM76 was a TRAC-like language which eliminated that limitation.
*
Russ Nelson
Russell Nelson (born March 21, 1958) is an American computer programmer. He was a founding board member of the Open Source Initiative and briefly served as its president in 2005.
Career
Nelson wrote code for some programs: In 1983, he co-wrote ...
implemented an
emacs
Emacs , originally named EMACS (an acronym for "Editor MACroS"), is a family of text editors that are characterized by their extensibility. The manual for the most widely used variant, GNU Emacs, describes it as "the extensible, customizable, s ...
extension language named MINT (MINT Is Not TRAC). This language is used by the
FreeDOS
FreeDOS (formerly Free-DOS and PD-DOS) is a free software operating system for IBM PC compatible computers. It intends to provide a complete MS-DOS-compatible environment for running Legacy system, legacy software and supporting embedded system ...
editor
FreeMACS.
TRAC was used by FTP Software in its PC/TCP product as the modem dialer scripting language.
TRAC was also used as a front end on Digital Productions Cray renderer for films, including ''
The Last Starfighter
''The Last Starfighter'' is a 1984 American space opera film directed by Nick Castle. The film tells the story of Alex Rogan (Lance Guest), a teenager recruited by an alien defense force to fight in an interstellar war. It also features Robert ...
''.
Example program
TRAC T84 script to compute Fibonacci numbers:
TRAC information page
at The History of Computing Project
''The'' () is a grammatical article in English, denoting persons or things already mentioned, under discussion, implied or otherwise presumed familiar to listeners, readers, or speakers. It is the definite article in English. ''The'' is the m ...
, with small code sample and photo of C. M. Mooers.
:(s,fibo,(
:(ei,<1>, 1, 0,(
:(ei,<1>, 2, 1,(
:(aa, :(ri,fibo,:(as, <1>,1)),:(ri,fibo,:(as, <1>,2)))
))
))
))`
:(mw,fibo)'
See also
* TTM (programming language)
TTM is a string oriented, general purpose macro processing programming language developed in 1968 by Steven Caine and E. Kent Gordon at the California Institute of Technology.
Description
The following description is taken from the original TT ...
, a programming language inspired by TRAC
References
{{Reflist
External links
The TRAC Foundation
(Archived)
TRAC, a procedure-describing language for the reactive typewriter
in the Communications of the ACM, Volume 9 Issue 3, March 1966.
TRAC entry
in the HOPL
History of Programming Languages (HOPL) is an infrequent ACM SIGPLAN conference. Past conferences were held in 1978, 1993, and 2007. The fourth conference was originally intended to take place in June 2020, but was postponed to 2021.
HOPL I
HOPL ...
br>Encyclopedia of Computer Languages
A TRAC implementation project
on SourceForge
SourceForge is a web service that offers software consumers a centralized online location to control and manage open-source software projects and research business software. It provides source code repository hosting, bug tracking, mirrorin ...
.
Oral history interview with Calvin N. Mooers and Charlotte D. Mooers
at the Charles Babbage Institute
The IT History Society (ITHS) is an organization that supports the history and scholarship of information technology by encouraging, fostering, and facilitating archival and historical research. Formerly known as the Charles Babbage Foundation, ...
. Interview discusses information retrieval and programming language research from World War II through the early 1990s.
Macro programming languages
Text-oriented programming languages
Homoiconic programming languages