746{
747 using sequence_diagram::model::class_;
748 using sequence_diagram::model::function;
749 using sequence_diagram::model::method;
750 using sequence_diagram::model::participant;
751
752 auto is_lambda = [&d](
const method &m) {
753 auto class_participant =
754 dynamic_cast<const sequence_diagram::model::diagram &>(d)
755 .get_participant<class_>(m.class_id());
756 if (!class_participant)
757 return false;
758
759 return class_participant.value().is_lambda();
760 };
761
764 auto is_function = [](const participant *p) {
765 return dynamic_cast<const function *>(p) != nullptr;
766 };
767
768 auto is_cuda_kernel = [](const participant *p) {
769 const auto *f =
dynamic_cast<const function *
>(p);
770 return (f != nullptr) && (f->is_cuda_kernel());
771 };
772
773 auto is_cuda_device = [](const participant *p) {
774 const auto *f =
dynamic_cast<const function *
>(p);
775 return (f != nullptr) && (f->is_cuda_device());
776 };
777
778 switch (ct) {
780 return p.type_name() == "method";
782 return p.type_name() == "method" &&
783 ((
method &)p).is_constructor();
785 return p.type_name() == "method" &&
786 ((
method &)p).is_assignment();
788 return is_function(&p) && ((
function &)p).is_operator();
790 return p.type_name() == "method" &&
791 ((
method &)p).is_defaulted();
793 return is_function(&p) && ((
function &)p).is_static();
795 return p.type_name() == "function";
797 return p.type_name() == "function_template";
799 return p.type_name() == "method" && is_lambda((method &)p);
801 return is_cuda_kernel(&p);
803 return is_cuda_device(&p);
804 }
805
806 return false;
807 });
808
812 "Participant {} rejected by callee_filter", p.full_name(false));
813 }
814
815 return res;
816}