Hacker News new | ask | show | jobs
by augustk 783 days ago
"The current POSIX standard defines source code-level compatibility for only two programming languages: The C language (C99) and the command language (shell)."

There is also a definition of AWK:

https://pubs.opengroup.org/onlinepubs/9699919799/utilities/a...

4 comments

Just short of good ones!
I'd always take the old POSIX stuff over whatever gets bought by IBM next year.
Given their longevity, it seems difficult to label them "bad".
There used to be POSIX.5 which standardised Ada bindings and POSIX.9 which standardised Fortran bindings, but both were abandoned (I assume due to lack of interest)
Certainly true. I just referred to this definition

"2.4 Other Language-Related Specifications

POSIX.1-2017 is currently specified in terms of the shell command language and ISO C. Bindings to other programming languages are being developed."

I've added a few words and links to other "utilities".

There is an argument that Awk's language isn't the same category as it is a DSL not intended to be a general purpose language (it is turning-complete, but was not specifically designed as such), and awk itself is considered a complex tool not a language interpreter.

Though having said that, any definition that separates awk from general programming languages like that could probably apply to shell syntax too.

Awk can do more than you think. Read The AWK Progamming Language.

Also:

gopher://hoi.st/1/dl and gopher://hoi.st/0/files/tgl.awk

make up a pretty complete language.

Don't think on AWK as a more powerful grep, you are missing a great mini-language.