Jump to content

User talk:Steamerandy/editing/metacompiler2

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia

talk about proposed change to Metacompiler topic

[edit]

Damon Simms created the Metacompiler topic. I have proposed changes to emphasize the great things about metacompiler. Not self-hosting as Damon Simms is so special. I am sorry for the disagreement but hay shit happens. But really? Writing a program from scratch is mind-bending?

Forth programmars talk about Forth performing metacompilation and being a metacompiler.

I agree the forth process is close to a metacompilation. And I have heard the term metacompilation for years also. In fact I can see no reason that it isn't a metacompilation. Not just the cross compilation but the extending of the language defining new words in it's own language. That is fairly close to the definition of metacompilation. Somehow metacompilation became metacompiler which is a vary different animal. The first time I heard of it being a metacompiler is the links Damon Simms gave here. When did Forth metacompilation become metacompiler?

This topic is under Computer Science category and thus should agree to computer science definitions. In all the recognized authoritative references I can find same thing. One can find thht definitions from the McGraw-Hill Dictionary of Scientific and Technical Terms, 6th edition defines metacompiler: "A Metacompiler is a compiler that is used chiefly to construct compilers for other programming languages" chiefly: most importantly, principally, especially or essentially above all, the main intent. The main intent of a metacompiler is to construct compilers for other languages. [[webopedia definstion of meta in computer science http://www.webopedia.com/TERM/M/meta.html] :In computer science, a common prefix that means "about". So, for example, metadata is data that describes other data (data about data). A metalanguage is a language used to describe other languages. I think the confusion came from thinking that a metacompiler does a metacompilation. It can be said that metacompilation describe an extensible language which Forth is. I do not see were Forth satisfies that definition of a metacompiler. The purpose of a metacompiler has always been to write compilers for other languages.

The other problem with saying "The feature that sets a metacompiler apart from a standard compiler-compiler is that a metacompiler is written in its own language and translates itself." is the historical facts contradicting it. There are documented metacompiler written in assembly, lisp and PL/1.

Actually the definition of metacompiler originally given by Damon Simms excludes forth:

A metacompiler is defined by a set of grammar production rules defining itself, written in its own specialized language. The metacompiler translates this grammar definition into the executable form of itself. Usually the grammar reduction rules are intermixed with semantic translation rules. Defining itself and translating itself this way constitutes the meta-step that sets a metacompiler apart from other compiler-compilers.

In the first line grammar is a link to Formal grammar. Forth is not a formal grammar. It is stated on the Forth talk page that forth cannot be defined by a formal grammar. So this paragraph eliminates Forth and most other metacompilers. The Schorre line of metacompilers are top down analytical parsing languages. Metacompilers are limited by that paragraph to taking Formal grammar. Formal grammar that generate strings of a language. That description does not describe FORTH, META II or TREEMETA or any meta compiler other then maybe yacc. --Steamerandy (talk) 07:26, 7 November 2014 (UTC)[reply]