Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.compilers > #2738
| From | gah4 <gah4@u.washington.edu> |
|---|---|
| Newsgroups | comp.compilers |
| Subject | Re: Are transpiling techniques different than compiling techniques? |
| Date | 2021-10-17 08:37 -0700 |
| Organization | Compilers Central |
| Message-ID | <21-10-030@comp.compilers> (permalink) |
| References | <21-10-017@comp.compilers> <21-10-019@comp.compilers> <21-10-026@comp.compilers> |
On Saturday, October 16, 2021 at 10:48:14 AM UTC-7, Kaz Kylheku wrote: (snip on the word transpiler) > It isn't; that's just a word used by some web programming hipsters. > Transpilers are everywhere, because browsers are stuck with Javascript > as their lowest-level target language*, and it sucks so terribly that > people want to use almost anything else. The bar is quite low; it's easy > to write toy languages that spit out Javascript, so it has become a kind > of popular sport, and from there came "transpiling". In the 1970's, programs to improve Fortran were common, with Ratfor and Mortran as two examples. (That is, Fortran IV or Fortran 66.) The ones I know were written as macro processors, where macros match some strings in the input data, along with arguments, and replace them with new strings. At least for the Mortran processor, macros can create or modify macros. A fairly simple processor, then, allows for a somewhat complicated language. One problem, though, is that such processors don't fully parse the input. Syntax errors in the input produce some strange output, and strange errors from the final compiler. It does seem that there are some macro processors for use with Javascript. [Ratfor used a yacc grammar, which is why early versions of yacc could produce ratfor output. As you note, it didn't understand all of Fortran so it let syntax errors through, which is why I did my PDP-10 hack to put the source line numbers in the Fortran output, to help figure out where the bug is. I later wrote a full Fortran 77 parser which was awful. No wonder they didn't try to do it in ratfor. -John]
Back to comp.compilers | Previous | Next — Previous in thread | Find similar
Are transpiling techniques different than compiling techniques? Roger L Costello <costello@mitre.org> - 2021-10-11 13:26 +0000
Re: Are transpiling techniques different than compiling techniques? Kartik Agaram <ak@akkartik.com> - 2021-10-11 11:23 -0700
Re: Are transpiling techniques different than compiling techniques? Hans-Peter Diettrich <DrDiettrich1@netscape.net> - 2021-10-12 20:05 +0200
Re: Are transpiling techniques different than compiling techniques? Kaz Kylheku <480-992-1380@kylheku.com> - 2021-10-16 17:16 +0000
Re: Are transpiling techniques different than compiling techniques? Thomas Koenig <tkoenig@netcologne.de> - 2021-10-16 20:22 +0000
Re: Are transpiling techniques different than compiling techniques? Hans-Peter Diettrich <DrDiettrich1@netscape.net> - 2021-10-16 23:55 +0200
Re: Are transpiling techniques different than compiling techniques? Hans-Peter Diettrich <DrDiettrich1@netscape.net> - 2021-10-17 07:02 +0200
Re: Are transpiling techniques different than compiling techniques? gah4 <gah4@u.washington.edu> - 2021-10-17 15:01 -0700
Re: Are transpiling techniques different than compiling techniques? "Detlef Meyer-Eltz" <Meyer-Eltz@t-online.de> - 2021-10-12 11:34 +0200
Re: Are transpiling techniques different than compiling techniques? jan van katwijk <j.vankatwijk@gmail.com> - 2021-10-12 17:59 +0200
Re: Are transpiling techniques different than compiling techniques? Hans-Peter Diettrich <DrDiettrich1@netscape.net> - 2021-10-12 20:19 +0200
Re: Are transpiling techniques different than compiling techniques? Christopher F Clark <christopher.f.clark@compiler-resources.com> - 2021-10-14 00:33 +0300
Re: Are transpiling techniques different than compiling techniques? Kaz Kylheku <480-992-1380@kylheku.com> - 2021-10-16 17:26 +0000
Re: Are transpiling techniques different than compiling techniques? gah4 <gah4@u.washington.edu> - 2021-10-17 08:37 -0700
csiph-web