4 ms·
The "FI" for "endif" is like bash. The semicolons are like C. The "PROGRAM" section is like COBOL.
by ape4 1y ago
The "FI" for "endif" is like bash.
The semicolons are like C.
The "PROGRAM" section is like COBOL.
- kragen 1y agoThe "fi" thing arose during the Algol-68 process, which Steve Bourne participated in, which is why he put it in his shell. (He would have put "od" there too to terminate "do" if it wasn't already used for a hexdumper.) You also find it in, for example, Dijkstra's Discipline of Programming. Semicolons were widely used as statement separators in Algol-family languages, but in Easy they seem to be statement terminators, so they are apparently like C rather than like earlier Algol-family languages such as Pascal. Pascal also had the "program" thing. I'm not sure if earlier Algol languages did?
- IAmBroom 1y agoCOBOL precedes Pascal.
- kragen 1y agoYes, of course it does. I didn't mean to imply that COBOL got it from Pascal. I meant that the practice was much more widespread than just COBOL, and given that the rest of Easy is clearly an Algol-family language very similar to Pascal or (then-draft) Ada, that's probably where he got it.
- Rendello 1y agoIf you're Stephen R. Bourne, "FI" is also like C! (From the Bourne Shell source): https://www.tuhs.org/cgi-bin/utree.pl?file=V7/usr/src/cmd/sh/mac.h https://www.tuhs.org/cgi-bin/utree.pl?file=V7/usr/src/cmd/sh...