Re:Show HN: A complete Bash parser in JavaScript transpiled ...
by tlrobinson on Thursday May 17, 2018 @12:04AM
(#17088633)
My position* is transpilers are a subset of compilers. So yes, Cfront was a compiler, and a transpiler.
* Which I admittedly didn't make clear in the parent comments, but did mention elsewhere in this thread.
Re:Show HN: A complete Bash parser in JavaScript transpiled ...
by Stratoscope on Thursday May 17, 2018 @01:15AM
(#17088912)
Ah, it sounds like we are on the same page after all. I mistook what you said for something I've occasionally seen other people say, that a transpiler is not a compiler. My apology for the misunderstanding.
Cfront was Bjarne's original C++ compiler. It translated C++ code into C code which would then be passed through a C compiler.
I didn't think Cfront should be called a compiler, because it didn't compile down to machine code and not even to assembly, only to another relatively high level language.
Bjarne was quite insistent that Cfront really was a compiler, and the fact that it compiled to another source language was immaterial. It did essentially the same things as any compiler, it only had a different back end code generator. And the code generator could later be swapped out for one that generates machine code.
Of course you can call it whatever you want, but Bjarne called it a compiler.