Live data from Hacker News

Chibicc: A Small C Compiler

github.com

11–20 of 48 posts

Re: Chibicc: A Small C Compiler

#12
When I find a bug in this compiler, I go back to the original commit that introduced the bug and rewrite the commit history as if there were no such bug from the beginning. This is an unusual way of fixing bugs, but as a a part of a book, it is important to keep every commit bug-free.

Somehow I can't imagine Brian Kernighan or Dennis Ritchie making those sorts of commits.

Re: Chibicc: A Small C Compiler

#13
post #7

Where will we be able to buy a copy? Is there a mailing list? I will certainly forget about this book in n months time.

Author here. No publishing date has been set yet. At least a half-written Japanese version of the book is available online for free (https://www.sigbus.info/compilerbook), and I'll probably translate this to English and share at least a few chapters for free. But nothing is set in stone yet. There's no mailing list for notifications yet.

Re: Chibicc: A Small C Compiler

#14
post #6

It would be helpful if the title was edited to feature the compiler's name: chibicc. It would make it easier to search and SEO-wise it would be helpful to disseminate the project.

Send an email to the mods hn@ycombinator.com They sometimes makes these changes.

Re: Chibicc: A Small C Compiler

#18
post #12

When I find a bug in this compiler, I go back to the original commit that introduced the bug and rewrite the commit history as if there were no such bug from the beginning. This is an unusual way of fixing bugs, but as a a part of a book, it is important to keep every commit bug-free. Somehow I can't imagine Brian Kernighan or Dennis Ritchie making those sorts of commits.

I would imagine it is done to avoid having a chapter at the end showing all the patches and why they were needed. A compiler course shouldn't have a bunch of errors if they can be avoided.

I doubt Brian Kernighan or Dennis Ritchie put all the errata at the end of their books on subsequent printings. They fixed the main text.

Post reply on HN