Closed JohnTitor closed 3 years ago
One possible option in the future is to use
{{#rustdoc_include}}
(along with mdbook's include anchors), and place the sample code in a separate directory where it can be more thoroughly tested. I notice there are huge chunks of code that aren't tested at all, which means there is a good likelihood that it contains errors, or may become incorrect in the future. TRPL is written this way. A big downside is that it becomes more difficult to edit/read the markdown source since the examples are in a separate file, so it is tough to decide if that is worth it.
Sounds good to me, at least we could use that for the examples using the libc
crate, I believe. I'll open an issue about that not to forget and to discuss.
Fixes #283