MCPcopy Create free account
hub / github.com/PerroEngine/Perro / api_ref_headings_match_compiled_api_names

Function api_ref_headings_match_compiled_api_names

perro_website/src/docs.rs:261–279  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

259 let prev = pos
260 .checked_sub(1)
261 .and_then(|index| pages.get(index).copied());
262 let next = pages.get(pos + 1).copied();
263 (prev, next)
264}
265
266pub fn markdown_html(markdown: &str) -> String {
267 highlight::markdown_html(markdown)
268}
269
270fn doc_matches(doc: &DocPage, needle: &str) -> bool {
271 doc.search_text.contains(needle)
272}
273
274#[cfg(test)]
275mod tests {
276 use super::{docs, find_doc, markdown_html};
277 use pulldown_cmark::{Event, Parser, Tag};
278 use std::{
279 collections::{BTreeMap, BTreeSet},
280 fs,
281 path::{Path, PathBuf},
282 };

Callers

nothing calls this directly

Calls 7

collect_source_api_namesFunction · 0.85
docsFunction · 0.85
api_ref_headingsFunction · 0.85
workspace_rootFunction · 0.70
iterMethod · 0.45
containsMethod · 0.45
pushMethod · 0.45

Tested by

no test coverage detected