MCPcopy Index your code
hub / github.com/RustPython/RustPython / optional_name

Method optional_name

crates/derive-impl/src/util.rs:292–294  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

290 }
291
292 fn optional_name(&self) -> Option<String> {
293 self.inner()._optional_str("name").ok().flatten()
294 }
295
296 fn new_meta_error(&self, msg: &str) -> syn::Error {
297 let inner = self.inner();

Callers 1

gen_module_itemMethod · 0.80

Implementers 3

pyclass.rscrates/derive-impl/src/pyclass.rs
util.rscrates/derive-impl/src/util.rs
pystructseq.rscrates/derive-impl/src/pystructseq.rs

Calls 4

okMethod · 0.80
_optional_strMethod · 0.80
flattenMethod · 0.45
innerMethod · 0.45

Tested by

no test coverage detected