733{
734 using sequence_diagram::model::class_;
735 using sequence_diagram::model::function;
736 using sequence_diagram::model::method;
737 using sequence_diagram::model::participant;
738
739 auto is_lambda = [&d](
const method &m) {
740 auto class_participant =
741 dynamic_cast<const sequence_diagram::model::diagram &>(d)
742 .get_participant<class_>(m.class_id());
743 if (!class_participant)
744 return false;
745
746 return class_participant.value().is_lambda();
747 };
748
751 auto is_function = [](const participant *p) {
752 return dynamic_cast<const function *>(p) != nullptr;
753 };
754
755 auto is_cuda_kernel = [](const participant *p) {
756 const auto *f =
dynamic_cast<const function *
>(p);
757 return (f != nullptr) && (f->is_cuda_kernel());
758 };
759
760 auto is_cuda_device = [](const participant *p) {
761 const auto *f =
dynamic_cast<const function *
>(p);
762 return (f != nullptr) && (f->is_cuda_device());
763 };
764
765 switch (ct) {
767 return p.type_name() == "method";
769 return p.type_name() == "method" &&
770 ((
method &)p).is_constructor();
772 return p.type_name() == "method" &&
773 ((
method &)p).is_assignment();
775 return is_function(&p) && ((
function &)p).is_operator();
777 return p.type_name() == "method" &&
778 ((
method &)p).is_defaulted();
780 return is_function(&p) && ((
function &)p).is_static();
782 return p.type_name() == "function";
784 return p.type_name() == "function_template";
786 return p.type_name() == "method" && is_lambda((method &)p);
788 return is_cuda_kernel(&p);
790 return is_cuda_device(&p);
791 }
792
793 return false;
794 });
795
799 "Participant {} rejected by callee_filter", p.full_name(false));
800 }
801
802 return res;
803}