Transpiler, a Meaningless Word (2023)
people.csail.mit.edu
Transpiler, a Meaningless Word (2023)
1–10 of 117 posts
Re: Transpiler, a Meaningless Word (2023)
#2Re: Transpiler, a Meaningless Word (2023)
#3"Transpiler" is no less well-defined a term than "compiler".
I think this is a pretty acceptable definition, and yes, it does make the term transpiler a little useless.
Re: Transpiler, a Meaningless Word (2023)
#4"Transpiler" is no less well-defined a term than "compiler".
The definition of compiler i learned was “takes some code, translate it to semantically equivalent code in a different language (which might be machine language, bytecode…)”. This is also used in PLaI, a respected learning resource: https://www.plai.org/ I think this is a pretty acceptable definition, and yes, it does make the term transpiler a little useless.
Re: Transpiler, a Meaningless Word (2023)
#5So you do know the difference.
Re: Transpiler, a Meaningless Word (2023)
#6In my book, transpilers are compilers that consume a programming language and target human-readable code, to be consumed by another compiler or interpreter (either by itself, or to be integrated in other projects).
i.e. the TypeScript compiler is a transpiler from TS to JS, the Nim compiler is a transpiler from Nim to C, and so on.
I guess if you really want to be pedantic, one can argue (with the above definition) that `clang -S` might be seen as a transpiler from C to ASM, but at that point, do words mean anything to you?
Re: Transpiler, a Meaningless Word (2023)
#7Re: Transpiler, a Meaningless Word (2023)
#8"Transpiler" is no less well-defined a term than "compiler".
The definition of compiler i learned was “takes some code, translate it to semantically equivalent code in a different language (which might be machine language, bytecode…)”. This is also used in PLaI, a respected learning resource: https://www.plai.org/ I think this is a pretty acceptable definition, and yes, it does make the term transpiler a little useless.
I think this is how the word is commonly understood, and it’s not useless (even if there’s no absolute standard of when it does or does not apply).
Edit: sorry, realise I should have read the article before commenting. The article calls out my definition as one of their ‘lies’. I guess I just disagree with the article. Words can be useful even without a 100% watertight definition. They’re for communication as well as classification.
Re: Transpiler, a Meaningless Word (2023)
#9IMO: Transpilers are compilers, but not all compilers are transpilers. In my book, transpilers are compilers that consume a programming language and target human-readable code, to be consumed by another compiler or interpreter (either by itself, or to be integrated in other projects). i.e. the TypeScript compiler is a transpiler from TS to JS, the Nim compiler is a transpiler from Nim to C, and so on. I guess if you…
Re: Transpiler, a Meaningless Word (2023)
#10Earlier quoted context omitted.
The definition of compiler i learned was “takes some code, translate it to semantically equivalent code in a different language (which might be machine language, bytecode…)”. This is also used in PLaI, a respected learning resource: https://www.plai.org/ I think this is a pretty acceptable definition, and yes, it does make the term transpiler a little useless.
What I would add to your definition, to make a distinction from the common usage of compilation, is that the target language is on an approximately equivalent level of abstraction to the source. So, for example, Rust -> machine code is not transpilation, but Rust -> C++ is. I think this is how the word is commonly understood, and it’s not useless (even if there’s no absolute standard of when it does or does not apply…