summaryrefslogtreecommitdiff
path: root/src/bin
diff options
context:
space:
mode:
authorYeongjong Lee <yj34.lee@samsung.com>2019-12-17 11:34:30 -0300
committerLauro Moura <lauromoura@expertisesolutions.com.br>2019-12-17 11:34:30 -0300
commitf90a97470d54edb20116e55739025e71cdfbbd92 (patch)
tree6b77b487baa2c4a4632fe71252438bab32434d32 /src/bin
parent7855a97f0d1cb0c1caac0180ae3a6a91e627ad06 (diff)
eina_mono: replace EinaAccessor and EinaIerator with IEnumerable
Summary: Eina.Accessor<T> => System.Collections.IEnumerable<T> Eina.Iterator<T> => System.Collections.IEnumerable<T> Unit test will work with D10879. ref T8486 Test Plan: meson build -Dbindings=mono,cxx -Dmono-beta=true Reviewers: lauromoura Reviewed By: lauromoura Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T8486 Differential Revision: https://phab.enlightenment.org/D10878
Diffstat (limited to 'src/bin')
-rw-r--r--src/bin/eolian_mono/eolian/mono/events.hh14
-rw-r--r--src/bin/eolian_mono/eolian/mono/parameter.hh141
-rw-r--r--src/bin/eolian_mono/eolian/mono/struct_definition.hh10
-rw-r--r--src/bin/eolian_mono/eolian/mono/type_impl.hh4
4 files changed, 128 insertions, 41 deletions
diff --git a/src/bin/eolian_mono/eolian/mono/events.hh b/src/bin/eolian_mono/eolian/mono/events.hh
index f0367c3..a77f6d7 100644
--- a/src/bin/eolian_mono/eolian/mono/events.hh
+++ b/src/bin/eolian_mono/eolian/mono/events.hh
@@ -133,9 +133,14 @@ struct unpack_event_args_visitor
133 { 133 {
134 return as_generator("(Efl.Eo.Globals.CreateWrapperFor(info) as " + name_helpers::klass_full_concrete_name(cls) + ")").generate(sink, attributes::unused, *context); 134 return as_generator("(Efl.Eo.Globals.CreateWrapperFor(info) as " + name_helpers::klass_full_concrete_name(cls) + ")").generate(sink, attributes::unused, *context);
135 } 135 }
136 bool operator()(attributes::complex_type_def const&) const 136 bool operator()(attributes::complex_type_def const& types) const
137 { 137 {
138 return as_generator("new " << eolian_mono::type << "(info, false, false)").generate(sink, type, *context); 138 if (types.outer.base_type == "iterator")
139 return as_generator("Efl.Eo.Globals.IteratorTo" << eolian_mono::type << "(info)").generate(sink, type, *context);
140 else if (types.outer.base_type == "accessor")
141 return as_generator("Efl.Eo.Globals.AccessorTo" << eolian_mono::type << "(info)").generate(sink, type, *context);
142 else
143 return as_generator("new " << eolian_mono::type << "(info, false, false)").generate(sink, type, *context);
139 } 144 }
140}; 145};
141 146
@@ -222,9 +227,12 @@ struct pack_event_info_and_call_visitor
222 << "CallNativeEventCallback(" << library_name << ", \"_" << evt_c_name << "\", IntPtr.Zero, null);\n" 227 << "CallNativeEventCallback(" << library_name << ", \"_" << evt_c_name << "\", IntPtr.Zero, null);\n"
223 ).generate(sink, attributes::unused, *context); 228 ).generate(sink, attributes::unused, *context);
224 } 229 }
225 bool operator()(attributes::complex_type_def const&) const 230 bool operator()(attributes::complex_type_def const& type) const
226 { 231 {
227 auto const& indent = current_indentation(*context); 232 auto const& indent = current_indentation(*context);
233 if ((type.outer.base_type == "iterator") || (type.outer.base_type == "accessor"))
234 return true;
235
228 return as_generator(indent << "IntPtr info = e.arg.Handle;\n" 236 return as_generator(indent << "IntPtr info = e.arg.Handle;\n"
229 << "CallNativeEventCallback(" << library_name << ", \"_" << evt_c_name << "\", IntPtr.Zero, null);\n" 237 << "CallNativeEventCallback(" << library_name << ", \"_" << evt_c_name << "\", IntPtr.Zero, null);\n"
230 ).generate(sink, attributes::unused, *context); 238 ).generate(sink, attributes::unused, *context);
diff --git a/src/bin/eolian_mono/eolian/mono/parameter.hh b/src/bin/eolian_mono/eolian/mono/parameter.hh
index d27889f..a5a70f2 100644
--- a/src/bin/eolian_mono/eolian/mono/parameter.hh
+++ b/src/bin/eolian_mono/eolian/mono/parameter.hh
@@ -639,16 +639,23 @@ struct native_convert_in_variable_generator
639 << ");\n" 639 << ");\n"
640 ).generate(sink, std::make_tuple(in_variable_name(param.param_name), param.type), context); 640 ).generate(sink, std::make_tuple(in_variable_name(param.param_name), param.type), context);
641 } 641 }
642 else if (param.type.c_type == "Eina_Iterator *" || param.type.c_type == "const Eina_Iterator *" 642 else if (param.type.c_type == "Eina_Iterator *" || param.type.c_type == "const Eina_Iterator *")
643 || param.type.c_type == "Eina_Accessor *" || param.type.c_type == "const Eina_Accessor *"
644 )
645 { 643 {
646 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type); 644 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type);
647 if (!complex) 645 if (!complex)
648 return false; 646 return false;
649 return as_generator( 647 return as_generator(
650 "var " << string << " = new " << type << "(" << escape_keyword(param.param_name) 648 "var " << string << " = Efl.Eo.Globals.IteratorTo" << type << "(" << escape_keyword(param.param_name)
651 << ", " << (param.type.has_own ? "true" : "false") 649 << ");\n"
650 ).generate(sink, std::make_tuple(in_variable_name(param.param_name), param.type), context);
651 }
652 else if (param.type.c_type == "Eina_Accessor *" || param.type.c_type == "const Eina_Accessor *")
653 {
654 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type);
655 if (!complex)
656 return false;
657 return as_generator(
658 "var " << string << " = Efl.Eo.Globals.AccessorTo" << type << "(" << escape_keyword(param.param_name)
652 << ");\n" 659 << ");\n"
653 ).generate(sink, std::make_tuple(in_variable_name(param.param_name), param.type), context); 660 ).generate(sink, std::make_tuple(in_variable_name(param.param_name), param.type), context);
654 } 661 }
@@ -724,8 +731,6 @@ struct convert_in_variable_generator
724 } 731 }
725 else if (param.type.c_type == "Eina_Array *" || param.type.c_type == "const Eina_Array *" 732 else if (param.type.c_type == "Eina_Array *" || param.type.c_type == "const Eina_Array *"
726 || param.type.c_type == "Eina_List *" || param.type.c_type == "const Eina_List *" 733 || param.type.c_type == "Eina_List *" || param.type.c_type == "const Eina_List *"
727 || param.type.c_type == "Eina_Iterator *" || param.type.c_type == "const Eina_Iterator *"
728 || param.type.c_type == "Eina_Accessor *" || param.type.c_type == "const Eina_Accessor *"
729 ) 734 )
730 { 735 {
731 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type); 736 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type);
@@ -741,18 +746,34 @@ struct convert_in_variable_generator
741 ).generate(sink, attributes::unused, context)) 746 ).generate(sink, attributes::unused, context))
742 return false; 747 return false;
743 748
744 // Iterators and Accessors can't own their content.
745 if (param.type.c_type == "Eina_Iterator *" || param.type.c_type == "const Eina_Iterator *"
746 || param.type.c_type == "Eina_Accessor *" || param.type.c_type == "const Eina_Accessor *"
747 )
748 return true;
749
750 if ((param.type.has_own && (complex->subtypes.front().is_value_type || complex->subtypes.front().has_own)) 749 if ((param.type.has_own && (complex->subtypes.front().is_value_type || complex->subtypes.front().has_own))
751 && !as_generator( 750 && !as_generator(
752 escape_keyword(param.param_name) << ".OwnContent = false;\n" 751 escape_keyword(param.param_name) << ".OwnContent = false;\n"
753 ).generate(sink, attributes::unused, context)) 752 ).generate(sink, attributes::unused, context))
754 return false; 753 return false;
755 } 754 }
755 else if (param.type.c_type == "Eina_Iterator *" || param.type.c_type == "const Eina_Iterator *")
756 {
757 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type);
758 if (!complex)
759 return false;
760 auto var_name = in_variable_name(param.param_name);
761 if (!as_generator(
762 "var " << string << " = " << "Efl.Eo.Globals.IEnumerableToIterator(" << escape_keyword(param.param_name) << ");\n"
763 ).generate(sink, var_name, context))
764 return false;
765 }
766 else if (param.type.c_type == "Eina_Accessor *" || param.type.c_type == "const Eina_Accessor *")
767 {
768 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type);
769 if (!complex)
770 return false;
771 auto var_name = in_variable_name(param.param_name);
772 if (!as_generator(
773 "var " << string << " = " << "Efl.Eo.Globals.IEnumerableToAccessor(" << escape_keyword(param.param_name) << ");\n"
774 ).generate(sink, var_name, context))
775 return false;
776 }
756 else if (param.type.c_type == "Eina_Value") 777 else if (param.type.c_type == "Eina_Value")
757 { 778 {
758 return as_generator( 779 return as_generator(
@@ -991,22 +1012,31 @@ struct convert_out_assign_generator
991 << ");\n" 1012 << ");\n"
992 ).generate(sink, std::make_tuple(escape_keyword(param.param_name), param.type, out_variable_name(param.param_name)), context); 1013 ).generate(sink, std::make_tuple(escape_keyword(param.param_name), param.type, out_variable_name(param.param_name)), context);
993 } 1014 }
1015 else if (param_is_acceptable(param, "Eina_Accessor *", WANT_OWN, WANT_OUT)
1016 || param_is_acceptable(param, "Eina_Accessor *", !WANT_OWN, WANT_OUT)
1017 || param_is_acceptable(param, "const Eina_Accessor *", WANT_OWN, WANT_OUT)
1018 || param_is_acceptable(param, "const Eina_Accessor *", !WANT_OWN, WANT_OUT)
1019 )
1020 {
1021 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type);
1022 if (!complex)
1023 return false;
1024 return as_generator(
1025 string << " = Efl.Eo.Globals.AccessorTo" << type << "(" << string
1026 << ");\n"
1027 ).generate(sink, std::make_tuple(escape_keyword(param.param_name), param.type, out_variable_name(param.param_name)), context);
1028 }
994 else if (param_is_acceptable(param, "Eina_Iterator *", WANT_OWN, WANT_OUT) 1029 else if (param_is_acceptable(param, "Eina_Iterator *", WANT_OWN, WANT_OUT)
995 || param_is_acceptable(param, "Eina_Iterator *", !WANT_OWN, WANT_OUT) 1030 || param_is_acceptable(param, "Eina_Iterator *", !WANT_OWN, WANT_OUT)
996 || param_is_acceptable(param, "const Eina_Iterator *", WANT_OWN, WANT_OUT) 1031 || param_is_acceptable(param, "const Eina_Iterator *", WANT_OWN, WANT_OUT)
997 || param_is_acceptable(param, "const Eina_Iterator *", !WANT_OWN, WANT_OUT) 1032 || param_is_acceptable(param, "const Eina_Iterator *", !WANT_OWN, WANT_OUT)
998 || param_is_acceptable(param, "Eina_Accessor *", WANT_OWN, WANT_OUT)
999 || param_is_acceptable(param, "Eina_Accessor *", !WANT_OWN, WANT_OUT)
1000 || param_is_acceptable(param, "const Eina_Accessor *", WANT_OWN, WANT_OUT)
1001 || param_is_acceptable(param, "const Eina_Accessor *", !WANT_OWN, WANT_OUT)
1002 ) 1033 )
1003 { 1034 {
1004 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type); 1035 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type);
1005 if (!complex) 1036 if (!complex)
1006 return false; 1037 return false;
1007 return as_generator( 1038 return as_generator(
1008 string << " = new " << type << "(" << string 1039 string << " = Efl.Eo.Globals.IteratorTo" << type << "(" << string
1009 << ", " << (param.type.has_own ? "true" : "false")
1010 << ");\n" 1040 << ");\n"
1011 ).generate(sink, std::make_tuple(escape_keyword(param.param_name), param.type, out_variable_name(param.param_name)), context); 1041 ).generate(sink, std::make_tuple(escape_keyword(param.param_name), param.type, out_variable_name(param.param_name)), context);
1012 } 1042 }
@@ -1121,14 +1151,21 @@ struct convert_return_generator
1121 .generate(sink, ret_type, context)) 1151 .generate(sink, ret_type, context))
1122 return false; 1152 return false;
1123 } 1153 }
1124 else if(ret_type.c_type == "Eina_Iterator *" || ret_type.c_type == "const Eina_Iterator *" 1154 else if (ret_type.c_type == "Eina_Accessor *" || ret_type.c_type == "const Eina_Accessor *")
1125 || ret_type.c_type == "Eina_Accessor *" || ret_type.c_type == "const Eina_Accessor *" 1155 {
1126 ) 1156 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&ret_type.original_type);
1157 if (!complex)
1158 return false;
1159 if (!as_generator("return Efl.Eo.Globals.AccessorTo" << type << "(_ret_var);")
1160 .generate(sink, ret_type, context))
1161 return false;
1162 }
1163 else if (ret_type.c_type == "Eina_Iterator *" || ret_type.c_type == "const Eina_Iterator *")
1127 { 1164 {
1128 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&ret_type.original_type); 1165 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&ret_type.original_type);
1129 if (!complex) 1166 if (!complex)
1130 return false; 1167 return false;
1131 if (!as_generator("return new " << type << "(_ret_var, " << std::string{ret_type.has_own ? "true" : "false"} << ");\n") 1168 if (!as_generator("return Efl.Eo.Globals.IteratorTo" << type << "(_ret_var);")
1132 .generate(sink, ret_type, context)) 1169 .generate(sink, ret_type, context))
1133 return false; 1170 return false;
1134 } 1171 }
@@ -1239,14 +1276,6 @@ struct native_convert_out_assign_generator
1239 || param_is_acceptable(param, "Eina_List *", !WANT_OWN, WANT_OUT) 1276 || param_is_acceptable(param, "Eina_List *", !WANT_OWN, WANT_OUT)
1240 || param_is_acceptable(param, "const Eina_List *", WANT_OWN, WANT_OUT) 1277 || param_is_acceptable(param, "const Eina_List *", WANT_OWN, WANT_OUT)
1241 || param_is_acceptable(param, "const Eina_List *", !WANT_OWN, WANT_OUT) 1278 || param_is_acceptable(param, "const Eina_List *", !WANT_OWN, WANT_OUT)
1242 || param_is_acceptable(param, "Eina_Iterator *", WANT_OWN, WANT_OUT)
1243 || param_is_acceptable(param, "Eina_Iterator *", !WANT_OWN, WANT_OUT)
1244 || param_is_acceptable(param, "const Eina_Iterator *", WANT_OWN, WANT_OUT)
1245 || param_is_acceptable(param, "const Eina_Iterator *", !WANT_OWN, WANT_OUT)
1246 || param_is_acceptable(param, "Eina_Accessor *", WANT_OWN, WANT_OUT)
1247 || param_is_acceptable(param, "Eina_Accessor *", !WANT_OWN, WANT_OUT)
1248 || param_is_acceptable(param, "const Eina_Accessor *", WANT_OWN, WANT_OUT)
1249 || param_is_acceptable(param, "const Eina_Accessor *", !WANT_OWN, WANT_OUT)
1250 ) 1279 )
1251 { 1280 {
1252 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type); 1281 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type);
@@ -1274,6 +1303,36 @@ struct native_convert_out_assign_generator
1274 ).generate(sink, outvar, context)) 1303 ).generate(sink, outvar, context))
1275 return false; 1304 return false;
1276 } 1305 }
1306 else if (param_is_acceptable(param, "Eina_Accessor *", WANT_OWN, WANT_OUT)
1307 || param_is_acceptable(param, "Eina_Accessor *", !WANT_OWN, WANT_OUT)
1308 || param_is_acceptable(param, "const Eina_Accessor *", WANT_OWN, WANT_OUT)
1309 || param_is_acceptable(param, "const Eina_Accessor *", !WANT_OWN, WANT_OUT)
1310 )
1311 {
1312 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type);
1313 if (!complex)
1314 return false;
1315 auto outvar = out_variable_name(param.param_name);
1316 if (!as_generator(
1317 string << " = Efl.Eo.Globals.IEnumerableToAccessor(" << string << ");\n"
1318 ).generate(sink, std::make_tuple(escape_keyword(param.param_name), outvar), context))
1319 return false;
1320 }
1321 else if (param_is_acceptable(param, "Eina_Iterator *", WANT_OWN, WANT_OUT)
1322 || param_is_acceptable(param, "Eina_Iterator *", !WANT_OWN, WANT_OUT)
1323 || param_is_acceptable(param, "const Eina_Iterator *", WANT_OWN, WANT_OUT)
1324 || param_is_acceptable(param, "const Eina_Iterator *", !WANT_OWN, WANT_OUT)
1325 )
1326 {
1327 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&param.type.original_type);
1328 if (!complex)
1329 return false;
1330 auto outvar = out_variable_name(param.param_name);
1331 if (!as_generator(
1332 string << " = Efl.Eo.Globals.IEnumerableToIterator(" << string << ");\n"
1333 ).generate(sink, std::make_tuple(escape_keyword(param.param_name), outvar), context))
1334 return false;
1335 }
1277 return true; 1336 return true;
1278 } 1337 }
1279 1338
@@ -1284,7 +1343,13 @@ struct native_convert_return_variable_generator
1284 template <typename OutputIterator, typename Context> 1343 template <typename OutputIterator, typename Context>
1285 bool generate(OutputIterator sink, attributes::type_def const& ret_type, Context const& context) const 1344 bool generate(OutputIterator sink, attributes::type_def const& ret_type, Context const& context) const
1286 { 1345 {
1287 if (ret_type.c_type != "void") 1346 if (ret_type.c_type == "Eina_Accessor *" || ret_type.c_type == "const Eina_Accessor *" ||
1347 ret_type.c_type == "Eina_Iterator *" || ret_type.c_type == "const Eina_Iterator *")
1348 return as_generator(
1349 type << " _ret_var = null;"
1350 ).generate(sink, ret_type, context);
1351
1352 else if (ret_type.c_type != "void")
1288 return as_generator( 1353 return as_generator(
1289 type << " _ret_var = default(" << type << ");" 1354 type << " _ret_var = default(" << type << ");"
1290 ).generate(sink, std::make_tuple(ret_type, ret_type), context); 1355 ).generate(sink, std::make_tuple(ret_type, ret_type), context);
@@ -1379,8 +1444,6 @@ struct native_convert_return_generator
1379 } 1444 }
1380 else if (ret_type.c_type == "Eina_Array *" || ret_type.c_type == "const Eina_Array *" 1445 else if (ret_type.c_type == "Eina_Array *" || ret_type.c_type == "const Eina_Array *"
1381 || ret_type.c_type == "Eina_List *" || ret_type.c_type == "const Eina_List *" 1446 || ret_type.c_type == "Eina_List *" || ret_type.c_type == "const Eina_List *"
1382 || ret_type.c_type == "Eina_Iterator *" || ret_type.c_type == "const Eina_Iterator *"
1383 || ret_type.c_type == "Eina_Accessor *" || ret_type.c_type == "const Eina_Accessor *"
1384 ) 1447 )
1385 { 1448 {
1386 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&ret_type.original_type); 1449 attributes::complex_type_def const* complex = efl::eina::get<attributes::complex_type_def>(&ret_type.original_type);
@@ -1404,6 +1467,16 @@ struct native_convert_return_generator
1404 return as_generator("return _ret_var.Handle;") 1467 return as_generator("return _ret_var.Handle;")
1405 .generate(sink, attributes::unused, context); 1468 .generate(sink, attributes::unused, context);
1406 } 1469 }
1470 else if (ret_type.c_type == "Eina_Accessor *" || ret_type.c_type == "const Eina_Accessor *")
1471 {
1472 return as_generator("return Efl.Eo.Globals.IEnumerableToAccessor(_ret_var);")
1473 .generate(sink, attributes::unused, context);
1474 }
1475 else if (ret_type.c_type == "Eina_Iterator *" || ret_type.c_type == "const Eina_Iterator *")
1476 {
1477 return as_generator("return Efl.Eo.Globals.IEnumerableToIterator(_ret_var);")
1478 .generate(sink, attributes::unused, context);
1479 }
1407 else if (ret_type.c_type != "void") 1480 else if (ret_type.c_type != "void")
1408 return as_generator("return _ret_var;").generate(sink, ret_type, context); 1481 return as_generator("return _ret_var;").generate(sink, ret_type, context);
1409 return true; 1482 return true;
diff --git a/src/bin/eolian_mono/eolian/mono/struct_definition.hh b/src/bin/eolian_mono/eolian/mono/struct_definition.hh
index 403778f..1267a8d 100644
--- a/src/bin/eolian_mono/eolian/mono/struct_definition.hh
+++ b/src/bin/eolian_mono/eolian/mono/struct_definition.hh
@@ -69,9 +69,15 @@ struct to_internal_field_convert_generator
69 .generate(sink, std::make_tuple(field_name, field_name), context)) 69 .generate(sink, std::make_tuple(field_name, field_name), context))
70 return false; 70 return false;
71 } 71 }
72 else if ((complex && (complex->outer.base_type == "iterator")))
73 {
74 if (!as_generator(
75 indent << scope_tab << scope_tab << "_internal_struct." << string << " = Efl.Eo.Globals.IEnumerableToIterator(_external_struct." << string << ");\n")
76 .generate(sink, std::make_tuple(field_name, field_name), context))
77 return false;
78 }
72 else if ((complex && (complex->outer.base_type == "array" 79 else if ((complex && (complex->outer.base_type == "array"
73 || complex->outer.base_type == "list" 80 || complex->outer.base_type == "list"
74 || complex->outer.base_type == "iterator"
75 || complex->outer.base_type == "hash")) 81 || complex->outer.base_type == "hash"))
76 || field.type.c_type == "Eina_Binbuf *" || field.type.c_type == "const Eina_Binbuf *") 82 || field.type.c_type == "Eina_Binbuf *" || field.type.c_type == "const Eina_Binbuf *")
77 { 83 {
@@ -206,7 +212,7 @@ struct to_external_field_convert_generator
206 else if (complex && complex->outer.base_type == "iterator") 212 else if (complex && complex->outer.base_type == "iterator")
207 { 213 {
208 if (!as_generator( 214 if (!as_generator(
209 indent << scope_tab << scope_tab << "_external_struct." << string << " = new " << type << "(_internal_struct." << string << ", false);\n") 215 indent << scope_tab << scope_tab << "_external_struct." << string << " = Efl.Eo.Globals.IteratorTo" << type << "(_internal_struct." << string << ");\n")
210 .generate(sink, std::make_tuple(field_name, field.type, field_name), context)) 216 .generate(sink, std::make_tuple(field_name, field.type, field_name), context))
211 return false; 217 return false;
212 } 218 }
diff --git a/src/bin/eolian_mono/eolian/mono/type_impl.hh b/src/bin/eolian_mono/eolian/mono/type_impl.hh
index fb521f2..f365a0d 100644
--- a/src/bin/eolian_mono/eolian/mono/type_impl.hh
+++ b/src/bin/eolian_mono/eolian/mono/type_impl.hh
@@ -393,14 +393,14 @@ struct visitor_generate
393 , {"iterator", nullptr, nullptr, [&] 393 , {"iterator", nullptr, nullptr, [&]
394 { 394 {
395 complex_type_def c = complex; 395 complex_type_def c = complex;
396 c.outer.base_type = "Eina.Iterator"; 396 c.outer.base_type = "IEnumerable";
397 return c; 397 return c;
398 } 398 }
399 } 399 }
400 , {"accessor", nullptr, nullptr, [&] 400 , {"accessor", nullptr, nullptr, [&]
401 { 401 {
402 complex_type_def c = complex; 402 complex_type_def c = complex;
403 c.outer.base_type = "Eina.Accessor"; 403 c.outer.base_type = "IEnumerable";
404 return c; 404 return c;
405 } 405 }
406 } 406 }