summaryrefslogblamecommitdiff
path: root/src/tests/eo/mixin/mixin_inherit.c
blob: 8098c1c2202a448d3e542f1145c1ecea7636a412 (plain) (tree)
1
2
3
4
5
6
7
8
9



                    
               


                          
 

                              

                                             
 
               
                                                    
                                    
 
              

 

                                               

  
                                                
                

                           
                                        

          
          



                                                                                  
#ifdef HAVE_CONFIG_H
# include <config.h>
#endif

#include "Eo.h"
#include "mixin_simple.h"
#include "mixin_mixin4.h"
#include "mixin_inherit.h"

#define MY_CLASS INHERIT_CLASS

static int
_a_get(Eo *obj, void *class_data EINA_UNUSED)
{
   int ret = 0;
   eo_do_super(obj, MY_CLASS, ret = simple_a_get());
   printf("%s %d\n", __func__, ret);

   return ret;
}

static Eo_Op_Description op_descs[] = {
     EO_OP_FUNC_OVERRIDE(simple_a_get, _a_get),
};

static const Eo_Class_Description class_desc = {
     EO_VERSION,
     "Inherit",
     EO_CLASS_TYPE_REGULAR,
     EO_CLASS_DESCRIPTION_OPS(op_descs),
     NULL,
     0,
     NULL,
     NULL
};

EO_DEFINE_CLASS(inherit_class_get, &class_desc, SIMPLE_CLASS, MIXIN4_CLASS, NULL);