0

This question already has an answer here:

I read that TeX was written in SAIL and re-writen in Pascal. Do we still use that version today? In my Linux distribution, I use TeX-Live. Does that also use the Pascal version?

Wikipedia says the last major revision was in 1982 and that it's quite stable. So only a few changes have been necessarily over the years.

I don't quite totally agree, since certain layout features are quite difficult to execute, and what if I don't like Pascal?

For my first issue, it may be possible to learn TeX (rather than LaTeX) and address these graphic design issues myself. Still I am rather curious about to layers, thanks.

What language is TeX implemented in?


From blog Implementing TeX in Clojure:

TeX source code is full of examples of what would not be considered good programming style today, such as:

  • global variables
  • one-character variables
  • goto statements
  • procedures spanning hundreds of lines;
  • lots of macros;
  • duplicate code;
  • local variable reuse;
  • single-threaded assumption is “everywhere”;
  • mutability is just “pervasive”

marked as duplicate by David Carlisle tex-core Feb 3 '16 at 22:46

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 1
    It's implemented in Pascal, but the compilation process used by TeX Live first translates the WEB Pascal source into C. But you don't need to like or dislike Pascal, which has no role whatsoever in using TeX. TeX just uses its own language, like Perl that's surely not written in Perl. – egreg Feb 3 '16 at 22:37
  • "...what if I don't like Pascal?" ... :) – Werner Feb 3 '16 at 22:39
  • 2
    I don't like the Java language -- shall I drop Firefox and Thunderbird then? ;-) – user31729 Feb 3 '16 at 22:41
  • 2
    this must be a duplicate of something but didn't spot an exact match just now. note that you mean tex not texlive, the latter is a distribution of thousands of files written in all kinds of things, your last paragraph about difference between plain and latex seems rather unrelated to the first. the two – David Carlisle Feb 3 '16 at 22:42
  • 1
    Yes, in Knuth's WEB system (which he invented in order to write TeX), you write the program and the documentation at the same time---"literate programming." So the pdf you get from entering texdoc tex at the terminal is the documentation, containing the complete program in (theoretically) human-readable format. The same source code can be used to generate computer-readable program code. – musarithmia Feb 3 '16 at 23:21

Browse other questions tagged or ask your own question.