Cleaned up code

This commit is contained in:
Bartek Kryza
2022-08-28 19:46:01 +02:00
parent 0701a082e9
commit feb19c23c7
10 changed files with 150 additions and 166 deletions

View File

@@ -59,6 +59,12 @@ void class_::add_method(class_method &&method)
void class_::add_parent(class_parent &&parent)
{
for (const auto &p : bases_) {
if (p.id() == parent.id()) {
return;
}
}
bases_.emplace_back(std::move(parent));
}
@@ -85,12 +91,7 @@ void class_::set_base_template(const std::string &full_name)
std::string class_::base_template() const { return base_template_full_name_; }
bool operator==(const class_ &l, const class_ &r)
{
return l.id() == r.id();
//(l.name_and_ns() == r.name_and_ns()) &&
// (l.templates_ == r.templates_);
}
bool operator==(const class_ &l, const class_ &r) { return l.id() == r.id(); }
void class_::add_type_alias(type_alias &&ta)
{