fix what-to-include doc example

Fixes the second example in the Examples section of what-to-include.md  by marking main as a function.
This commit is contained in:
Cameron Ditchfield 2023-10-21 19:40:08 -05:00
parent 1c05d50c84
commit 65962708f8

View File

@ -73,7 +73,7 @@ and your test suite, this example needs some additional code:
``````text ``````text
/// Example /// Example
/// ```rust /// ```rust
/// # main() -> Result<(), std::num::ParseIntError> { /// # fn main() -> Result<(), std::num::ParseIntError> {
/// let fortytwo = "42".parse::<u32>()?; /// let fortytwo = "42".parse::<u32>()?;
/// println!("{} + 10 = {}", fortytwo, fortytwo+10); /// println!("{} + 10 = {}", fortytwo, fortytwo+10);
/// # Ok(()) /// # Ok(())