From cc04dff0b9b49cd58c5c9206123615db19d2ffe3 Mon Sep 17 00:00:00 2001 From: Savio Sena Date: Thu, 24 Jul 2014 15:45:53 -0300 Subject: [PATCH] eolian-cxx: Removed unused code. Sanitized grammar removing old code which is not unecessary for good. --- .../grammar/inheritance_base_generator.hh | 31 ---------------------- src/lib/eolian_cxx/grammar/parameters_generator.hh | 15 ----------- 2 files changed, 46 deletions(-) diff --git a/src/lib/eolian_cxx/grammar/inheritance_base_generator.hh b/src/lib/eolian_cxx/grammar/inheritance_base_generator.hh index 54617f1..5c32498 100644 --- a/src/lib/eolian_cxx/grammar/inheritance_base_generator.hh +++ b/src/lib/eolian_cxx/grammar/inheritance_base_generator.hh @@ -83,37 +83,6 @@ operator<<(std::ostream& out, inheritance_operations_description const& x) return out; } -struct inheritance_wrapper -{ - eo_class const& _cls; - eo_function const& _func; - inheritance_wrapper(eo_class const& cls, eo_function const& func) - : _cls(cls), _func(func) - {} -}; - -inline std::ostream& -operator<<(std::ostream& out, inheritance_wrapper const& x) -{ - out << "template " << endl - << reinterpret_type(x._func.ret) << " " - << _ns_as_prefix(x._cls) << "_" - << x._cls.name << "_" << x._func.name - << "_wrapper(Eo* objid EINA_UNUSED, " - << "efl::eo::detail::Inherit_Private_Data* self" - << (x._func.params.size() ? ", " : "") - << parameters_c_declaration(x._func.params) - << ")" << endl - << "{" << endl - << tab(1) - << (!function_is_void(x._func) ? "return ": "") - << "static_cast(self->this_)->" - << x._func.name << "(" << parameters_c_list(x._func.params) << ");" << endl - << "}" << endl << endl; - - return out; -} - struct inheritance_wrappers { eo_class const& _cls; diff --git a/src/lib/eolian_cxx/grammar/parameters_generator.hh b/src/lib/eolian_cxx/grammar/parameters_generator.hh index 053cef6..83de297 100644 --- a/src/lib/eolian_cxx/grammar/parameters_generator.hh +++ b/src/lib/eolian_cxx/grammar/parameters_generator.hh @@ -86,21 +86,6 @@ operator<<(std::ostream& out, parameters_types const& x) return out; } -inline -std::ostream& parameter_names_enumerate(std::ostream& out - , parameters_container_type const& params) -{ - for (auto first = params.begin() - , iterator = first - , last = params.end() - ; iterator != last; ++iterator) - { - if(iterator != first) out << ", "; - out << iterator->name; - } - return out; -} - struct parameters_list { -- 2.7.4