MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / ret_wrapper_re

Function ret_wrapper_re

codegraph-kernel/src/ccpp/mod.rs:124–130  ·  view source on GitHub ↗

normalizeCppReturnType: smart-pointer/optional unwrap.

()

Source from the content-addressed store, hash-verified

122}
123/// normalizeCppReturnType: smart-pointer/optional unwrap.
124fn ret_wrapper_re() -> &'static Regex {
125 static RE: OnceLock<Regex> = OnceLock::new();
126 RE.get_or_init(|| {
127 Regex::new(r"\b(?:std\s*::\s*)?(?:unique_ptr|shared_ptr|weak_ptr|optional)\s*<\s*([^,>]+?)\s*>")
128 .unwrap()
129 })
130}
131fn ret_keyword_re() -> &'static Regex {
132 static RE: OnceLock<Regex> = OnceLock::new();
133 RE.get_or_init(|| Regex::new(r"\b(?:const|volatile|typename|struct|class|enum)\b").unwrap())

Callers 1

Calls 1

unwrapMethod · 0.60

Tested by

no test coverage detected