diff options
author | Titus Wormer <tituswormer@gmail.com> | 2022-08-12 14:21:53 +0200 |
---|---|---|
committer | Titus Wormer <tituswormer@gmail.com> | 2022-08-12 14:21:53 +0200 |
commit | 504729a4a0c8f3e0d8fc9159e0273150b169e184 (patch) | |
tree | a6bf291322decccd6011580337b1feed6151b554 /src/parser.rs | |
parent | db5a491e6c2223d1db9b458307431a54db3c40f2 (diff) | |
download | markdown-rs-504729a4a0c8f3e0d8fc9159e0273150b169e184.tar.gz markdown-rs-504729a4a0c8f3e0d8fc9159e0273150b169e184.tar.bz2 markdown-rs-504729a4a0c8f3e0d8fc9159e0273150b169e184.zip |
Refactor to improve docs of each function
Diffstat (limited to '')
-rw-r--r-- | src/parser.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/parser.rs b/src/parser.rs index dc2c07a..a8416ed 100644 --- a/src/parser.rs +++ b/src/parser.rs @@ -4,10 +4,10 @@ use crate::content::document::document; use crate::event::{Event, Point}; use crate::{Constructs, Options}; -/// Information needed, in all content types, when parsing markdown. +/// Info needed, in all content types, when parsing markdown. /// /// Importantly, this contains a set of known definitions. -/// It also references the input value as a `Vec<char>`. +/// It also references the input value as bytes (`u8`). #[derive(Debug)] pub struct ParseState<'a> { pub constructs: &'a Constructs, @@ -19,7 +19,7 @@ pub struct ParseState<'a> { /// Turn a string of markdown into events. /// -/// Passes the codes back so the compiler can access the source. +/// Passes the bytes back so the compiler can access the source. pub fn parse<'a>(value: &'a str, options: &'a Options) -> (Vec<Event>, &'a [u8]) { let mut parse_state = ParseState { constructs: &options.constructs, |