Re:Designing a programming language to speedrun Advent of Code
by xigoi on Wednesday November 15, 2023 @05:03AM
(#38275065)
I know. The only thing surprising me is your previous claim that `< file` is equivalent to `: < file`.
[ Parent
| on HN ]
Re:Designing a programming language to speedrun Advent of Code
by frou_dh on Wednesday November 15, 2023 @05:08AM
(#38275093)
My interpretation of sgarland's question was that he meant `<file` being the entirety of the statement, i.e. typing only that at a shell prompt and pressing return.
Re:Designing a programming language to speedrun Advent of Code
by xigoi on Wednesday November 15, 2023 @05:14AM
(#38275133)
Ah. Now I understand where the misunderstanding was. It confused me that we were talking about redirection as a replacement for useless use of cat.
Re:Designing a programming language to speedrun Advent of Code
by frou_dh on Wednesday November 15, 2023 @05:28AM
(#38275205)
Yep I can appreciate the misunderstanding. For completeness of the discussion, I think where sgarland mentioned a sub-shell, he was possibly referencing the Bashism `$(<` detailed on this page https://www.gnu.org/software/bash/manual/html_node/Command-S... in addition to what I called a "statement" above.