Better HN
topnewbestaskshowjobs
Log inSign up

xandris

13 karma · joined Aug 10, 2020 (6y ago) · 4 submissions

Submissions

comment 6y ago · link · parent

Wait, --help should print to stdout so that

    fancycommand --help | less
works as expected. Otherwise, the help text will dump to the screen and less will erase it when it decides to redraw its empty buffer! Actual error messages should go to stderr so that I can redirect them to an error log or so I can suppress them if need be, or I could also be doing > /dev/stdout to silence normal output but I don't want errors to be discarded.

comment 6y ago · link · parent

This is my steady state. I don't think people shouldn't be valued by their output, and I'm content to spend time with my family, learn about the world around me, have fun, and do my best at work. I do go through episodes where the need to create something worthwhile takes ahold of me, though, and it can be debilitating for a few days.

comment 6y ago · link · parent

At least on the toolchains I'm familiar with, the linker will insert crt0.o, a very basic part of the C runtime, which contains a _start implementation that pulls argc, argv, and envp from the stack:

https://en.wikipedia.org/wiki/Crt0

So it's not really part of the "compiler" itself, it's usually an object file the linker includes in the linking job on your behalf.