1

I'm probably missing something incredibly obvious, but I'm having trouble generating documentation for my code. I'm reading this tutorial and from what I understand, I can simply do something like

/// this is a doc comment
pub fn something() {

}

and run cargo doc --no-deps --open to get my crate's html page. However, my index.html is just showing the crate name and nothing else.

I have the following structure:

src/
  | main.rs
  | random_file.rs
  | drivers/
    | mod.rs 
    | foo.rs 
    | dummy.rs 

and in my foo.rs I have

/// in foo doc
pub fn bar() {

}

What am I missing?

Ayumu Kasugano
  • 440
  • 4
  • 13

0 Answers0