Re:Infrequently Asked Questions in Comp.lang.c
by archfrog on Sunday August 20, 2023 @10:44AM
(#37199631)
I don't want to be toxic but why make a function to cast a char to an int? I was astounded when I briefly skimmed through the list. I hope this is not curriculum in education.
[ Parent
| on HN ]
Re:Infrequently Asked Questions in Comp.lang.c
by Kamq on Sunday August 20, 2023 @11:01AM
(#37199821)
I don't see the one you're talking to on a brief skim, but there are several functions that deal with processing a file character by character. They generally use ints because they need a way to signal end of file and you can't do that with any value of a byte.
Re:Infrequently Asked Questions in Comp.lang.c
by chihuahua on Sunday August 20, 2023 @11:01AM
(#37199826)
I got the impression that the entire document is meant as a joke.
Re:Infrequently Asked Questions in Comp.lang.c
by MobiusHorizons on Sunday August 20, 2023 @11:36AM
(#37200131)
Unambiguously so if you click to any of the footnotes.