MCPcopy Create free account
hub / github.com/PaddlePaddle/Paddle / GetTypeName

Function GetTypeName

paddle/ap/include/axpr/method_class.h:485–497  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

483
484template <typename ValueT>
485std::string GetTypeName(const ValueT& val) {
486 return val.Match(
487 [](const BuiltinClassInstance<ValueT>& impl) -> std::string {
488 return impl.type.class_attrs()->class_name;
489 },
490 [](const ClassInstance<ValueT>& impl) -> std::string {
491 return impl->type.class_attrs->class_name;
492 },
493 [](const auto& impl) -> std::string {
494 using T = std::decay_t<decltype(impl)>;
495 return TypeImpl<T>{}.Name();
496 });
497}
498
499} // namespace ap::axpr

Callers 15

HashMethod · 0.70
ToStringMethod · 0.70
BinaryFuncMethod · 0.70
ConstructDataValueFunction · 0.70
MakeComplex64Method · 0.70
MakeComplex128Method · 0.70
ToStringFunction · 0.70
InterpretComposedCallMethod · 0.70
GetItemMethod · 0.70
JoinMethod · 0.70

Calls 3

MatchMethod · 0.45
class_attrsMethod · 0.45
NameMethod · 0.45

Tested by

no test coverage detected