Added initial support for skip decorator in sequence diagrams
This commit is contained in:
@@ -127,7 +127,7 @@ void generator::generate_activity(const activity &a, std::ostream &ostr,
|
||||
if (m.type() == message_t::kCall) {
|
||||
const auto &to =
|
||||
m_model.get_participant<model::participant>(m.to());
|
||||
if (!to)
|
||||
if (!to || to.value().skip())
|
||||
continue;
|
||||
|
||||
visited.push_back(m.from());
|
||||
|
||||
@@ -298,6 +298,8 @@ bool translation_unit_visitor::VisitCXXMethodDecl(clang::CXXMethodDecl *m)
|
||||
param->getType(), m->getASTContext(), false))));
|
||||
}
|
||||
|
||||
process_comment(*m, *m_ptr);
|
||||
|
||||
set_source_location(*m, *m_ptr);
|
||||
|
||||
const auto method_full_name = m_ptr->full_name(false);
|
||||
@@ -368,6 +370,8 @@ bool translation_unit_visitor::VisitFunctionDecl(clang::FunctionDecl *f)
|
||||
}
|
||||
set_unique_id(f->getID(), f_ptr->id());
|
||||
|
||||
process_comment(*f, *f_ptr);
|
||||
|
||||
set_source_location(*f, *f_ptr);
|
||||
|
||||
// TODO: Handle overloaded functions with different arguments
|
||||
@@ -400,6 +404,8 @@ bool translation_unit_visitor::VisitFunctionDecl(clang::FunctionDecl *f)
|
||||
}
|
||||
set_unique_id(f->getID(), f_ptr->id());
|
||||
|
||||
process_comment(*f, *f_ptr);
|
||||
|
||||
set_source_location(*f, *f_ptr);
|
||||
|
||||
// TODO: Handle overloaded functions with different arguments
|
||||
@@ -441,6 +447,8 @@ bool translation_unit_visitor::VisitFunctionTemplateDecl(
|
||||
f_ptr->is_void(
|
||||
function_template->getAsFunction()->getReturnType()->isVoidType());
|
||||
|
||||
process_comment(*function_template, *f_ptr);
|
||||
|
||||
set_source_location(*function_template, *f_ptr);
|
||||
|
||||
context().update(function_template);
|
||||
@@ -811,8 +819,7 @@ bool translation_unit_visitor::VisitCallExpr(clang::CallExpr *expr)
|
||||
return true;
|
||||
|
||||
// Skip casts, moves and such
|
||||
if (expr->isCallToStdMove())
|
||||
return true;
|
||||
if (expr->isCallToStdMove()) return true;
|
||||
|
||||
if (expr->isImplicitCXXThis())
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user