3 ms·
> There's a fundamental problem with generating a beautifully typeset document for a codebase: it's dead. [...] > You can't work with it, you can't try to make
by camel-cdr 2y ago
> There's a fundamental problem with generating a beautifully typeset document for a codebase: it's dead. [...]
> You can't work with it, you can't try to make changes to it to see what happens, and you certainly can't run it interactively.
I think an aspect where " classical" literate programming excels is in the form of printed educational books.
A great example of this is LCC "A Retargetable Compiler for ANSI C" by David R. Hanson.
Reading about how to write compilers in theory is fine, but it's very nice to learn from a full working example implementation.
- bluGill 2y agoTruth and Knuth is an author of books so it makes sense for him to write code for books when writing code for books. However code that isn't bound into book has different needs and should be different. I've printed out code before (the floor gives a lot more space to spread out text than even the largest monitor, and taking a pen to circle useful parts is helpful) - but I recycled that paper as soon as the bug was found/fixed. In that case I'm never interested in how the code is documented/supposed to work in the authors imagination - I care about what it actually does.
- WillAdams 2y agoNote that it is possible to apply a [draft] option to some LaTeX documentclasses so as to avoid that appearance and encourage folks to treat as not-yet final/finished.
- zelphirkalt 2y ago> > There's a fundamental problem with generating a beautifully typeset document for a codebase: it's dead. [...] I think this is false. The typeset document should only be the output of a rendering/compilation step, of a document that exists in plain text. Usually that is the case. Why would one throw away the source once the typeset document is created? One would then simply edit the source, just like we do with other code that runs. > > You can't work with it, you can't try to make changes to it to see what happens, and you certainly can't run it interactively. Yes you can. Just normal compile cycle. What am I missing here?