Found in 8 comments on Hacker News
belter · 2022-10-08 · Original thread
Start by reading Redis code, slowly take notes on paper, try to make your version changing small bits at a time.

https://github.com/redis/redis/tree/unstable/src

Entry point here at line 6816: https://github.com/redis/redis/blob/unstable/src/server.c

Also "Code Reading" will be useful. - https://www.amazon.com/Code-Reading-Open-Source-Perspective/...

"Code Reading" tends to be criticized, but I think mostly unfairly.

rmk · 2022-07-30 · Original thread
I started reading this book, but lost interest pretty quickly. Maybe you'll like it if you give it a shot: https://www.amazon.com/Code-Reading-Open-Source-Perspective/...

Effective Java by Joshua Bloch has code snippets that are very well-written, as are the examples in The Go Programming Language by Donovan et. al. I read practically all the code in Effective Java, and a lot of the examples in The Go Programming Language (I keep dipping into this book every now and then as I have to learn some aspect of Go, which I use at work; I think I may actually sit down and read this book cover-to-cover and perhaps play with most of the examples).

If you know C, you may want to give the examples in The C Programming Language by Kernighan et. al a go. The examples are written in a bit of an archaic dialect but still very clear.

Another book of note that is funny and engaging (but of course not something that has professional value) is If Hemingway Wrote Code by Angus Croll: https://nostarch.com/hemingway. I think I have read all of the code in this book.

guiraldelli · 2021-09-20 · Original thread
I just skimmed the article, but a more comprehensive text on acquiring the skill to read code is the book Code Reading, from Diomedis Spinelli [1].

[1]: https://www.amazon.com/Code-Reading-Open-Source-Perspective/...

llimllib · 2020-03-08 · Original thread
In the vein of working effectively with legacy code, "Reading Code" by Spinelli taught me a lot when I was a younger engineer https://www.amazon.com/Code-Reading-Open-Source-Perspective/...

(Amazon says I bought it 14 years ago!)

okaram · 2014-04-17 · Original thread
You may want to look at the book 'Code Reading' ; it's been a while, and I gave away my copy, but it was useful

http://www.amazon.com/Code-Reading-Open-Source-Perspective/d...

gtani · 2011-12-24 · Original thread
Hmm, tough question to google but: I was going to blog about but: didn't get around toit. Look at static code analysis and runtime tools (debuggers) there's SO tags for that, python+code-analysis.

http://stackoverflow.com/questions/3883484/using-python-code...

Python has a very rich toolset, including inspect module,

http://stackoverflow.com/questions/1568544/given-a-python-cl...

http://code.activestate.com/recipes/213898-drawing-inheritan...

Also (this thread)[http://stackoverflow.com/questions/334009/how-to-read-source...] mentions ctags, doxygen, tools like that. Reading test suites (and running code coverage) is where a lot of people start with new to them codebases. And python specific emacs and vim plugins, and python-specific IDE's, komodo and pycharm, at the tools they provide for folding code, showing module dependencies/call graphs, stuff like that

---------

My python's a little rusty, but could generate stacktraces, or use an IDE's stepper/debugger to show where you are at some point in execution of django code

-----------

Finally [a book](http://www.amazon.com/Code-Reading-Open-Source-Perspective/d...)

Maybe try this book? http://www.amazon.com/Code-Reading-Open-Source-Perspective/d... I'm not sure how good it is.
llimllib · 2009-02-17 · Original thread
You need this book, it's excellent: http://www.amazon.com/dp/0201799405 .

Fresh book recommendations delivered straight to your inbox every Thursday.