q66 pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=f24fa691e7c25ed6779f78affcbfe7310fa85dda

commit f24fa691e7c25ed6779f78affcbfe7310fa85dda
Author: Daniel Kolesa <[email protected]>
Date:   Thu Mar 8 23:01:01 2018 +0100

    pyolian: wipe out declaration api
---
 src/scripts/pyolian/eolian.py     | 50 ---------------------------------------
 src/scripts/pyolian/eolian_lib.py | 34 --------------------------
 2 files changed, 84 deletions(-)

diff --git a/src/scripts/pyolian/eolian.py b/src/scripts/pyolian/eolian.py
index 0693ebae05..db4b35fad0 100644
--- a/src/scripts/pyolian/eolian.py
+++ b/src/scripts/pyolian/eolian.py
@@ -53,7 +53,6 @@ class Eolian_Object_Type(IntEnum):
     IMPLEMENT = 12
     CONSTRUCTOR = 13
     DOCUMENTATION = 14
-    DECLARATION = 15
 
 class Eolian_Function_Type(IntEnum):
     UNRESOLVED = 0
@@ -225,14 +224,6 @@ class Eolian_Unary_Operator(IntEnum):
     NOT = 3   # ! int, float, bool
     BNOT = 4  # ~ int
 
-class Eolian_Declaration_Type(IntEnum):
-    UNKNOWN = 0
-    CLASS = 1
-    ALIAS = 2
-    STRUCT = 3
-    ENUM = 4
-    VAR = 5
-
 class Eolian_Doc_Token_Type(IntEnum):
     UNKNOWN = 0
     TEXT = 1
@@ -425,19 +416,6 @@ class Eolian_Unit(EolianBaseObject):
     def namespace_get_by_name(self, name):
         return Namespace(self, name)
 
-    @property
-    def all_declarations(self):
-        return Iterator(Declaration, 
lib.eolian_all_declarations_get(self._obj))
-
-    def declaration_get_by_name(self, name):
-        c_decl = lib.eolian_declaration_get_by_name(self._obj, 
_str_to_bytes(name))
-        return Declaration(c_decl) if c_decl else None
-
-    def declarations_get_by_file(self, fname):
-        return Iterator(Declaration,
-            lib.eolian_declarations_get_by_file(self._obj, 
_str_to_bytes(fname)))
-
-
 class Eolian_State(Eolian_Unit):
     def __init__(self):
         self._obj = lib.eolian_state_new()  # Eolian_State *
@@ -1458,34 +1436,6 @@ class Variable(Object):
         return Documentation(c_doc) if c_doc else None
 
 
-class Declaration(Object):
-    def __repr__(self):
-        return "<eolian.Declaration '{0.name}'>".format(self)
-
-    @cached_property
-    def name(self):
-        return _str_to_py(lib.eolian_declaration_name_get(self._obj))
-
-    @cached_property
-    def type(self):
-        return 
Eolian_Declaration_Type(lib.eolian_declaration_type_get(self._obj))
-
-    @cached_property
-    def class_(self):
-        c_cls = lib.eolian_declaration_class_get(self._obj)
-        return Class(c_cls) if c_cls else None
-
-    @cached_property
-    def data_type(self):
-        c_typedec = lib.eolian_declaration_data_type_get(self._obj)
-        return Typedecl(c_typedec) if c_typedec else None
-
-    @cached_property
-    def variable(self):
-        c_var = lib.eolian_declaration_variable_get(self._obj)
-        return Variable(c_var) if c_var else None
-
-
 class _Eolian_Doc_Token_Struct(ctypes.Structure):
     _fields_ = [("type", c_int),
                 ("text", c_char_p),
diff --git a/src/scripts/pyolian/eolian_lib.py 
b/src/scripts/pyolian/eolian_lib.py
index 1ea3898d58..26d631234c 100644
--- a/src/scripts/pyolian/eolian_lib.py
+++ b/src/scripts/pyolian/eolian_lib.py
@@ -165,10 +165,6 @@ lib.eolian_state_structs_get.restype = c_void_p
 lib.eolian_state_enums_get.argtypes = [c_void_p,]
 lib.eolian_state_enums_get.restype = c_void_p
 
-# EAPI Eina_Iterator *eolian_declarations_get_by_file(const Eolian_State 
*state, const char *fname);
-lib.eolian_declarations_get_by_file.argtypes = [c_void_p, c_char_p]
-lib.eolian_declarations_get_by_file.restype = c_void_p
-
 ###  Eolian_Unit  #############################################################
 
 # EAPI Eina_Iterator *eolian_unit_children_get(const Eolian_Unit *unit);
@@ -227,14 +223,6 @@ lib.eolian_unit_constants_get.restype = c_void_p
 lib.eolian_unit_globals_get.argtypes = [c_void_p,]
 lib.eolian_unit_globals_get.restype = c_void_p
 
-# EAPI Eina_Iterator *eolian_all_declarations_get(const Eolian_Unit *unit);
-lib.eolian_all_declarations_get.argtypes = [c_void_p,]
-lib.eolian_all_declarations_get.restype = c_void_p
-
-# EAPI const Eolian_Declaration *eolian_declaration_get_by_name(const 
Eolian_Unit *unit, const char *name);
-lib.eolian_declaration_get_by_name.argtypes = [c_void_p, c_char_p]
-lib.eolian_declaration_get_by_name.restype = c_void_p
-
 ###  Eolian_Object  ###########################################################
 
 # EAPI Eolian_Object_Type eolian_object_type_get(const Eolian_Object *obj);
@@ -788,28 +776,6 @@ lib.eolian_variable_namespaces_get.restype = c_void_p
 lib.eolian_variable_is_extern.argtypes = [c_void_p,]
 lib.eolian_variable_is_extern.restype = c_bool
 
-###  Eolian_Declaration  ######################################################
-
-# EAPI Eolian_Declaration_Type eolian_declaration_type_get(const 
Eolian_Declaration *decl);
-lib.eolian_declaration_type_get.argtypes = [c_void_p,]
-lib.eolian_declaration_type_get.restype = c_int
-
-# EAPI Eina_Stringshare *eolian_declaration_name_get(const Eolian_Declaration 
*decl);
-lib.eolian_declaration_name_get.argtypes = [c_void_p,]
-lib.eolian_declaration_name_get.restype = c_char_p
-
-# EAPI const Eolian_Class *eolian_declaration_class_get(const 
Eolian_Declaration *decl);
-lib.eolian_declaration_class_get.argtypes = [c_void_p,]
-lib.eolian_declaration_class_get.restype = c_void_p
-
-# EAPI const Eolian_Typedecl *eolian_declaration_data_type_get(const 
Eolian_Declaration *decl);
-lib.eolian_declaration_data_type_get.argtypes = [c_void_p,]
-lib.eolian_declaration_data_type_get.restype = c_void_p
-
-# EAPI const Eolian_Variable *eolian_declaration_variable_get(const 
Eolian_Declaration *decl);
-lib.eolian_declaration_variable_get.argtypes = [c_void_p,]
-lib.eolian_declaration_variable_get.restype = c_void_p
-
 ###  Eolian_Documentation  ####################################################
 
 # EAPI Eina_Stringshare *eolian_documentation_summary_get(const 
Eolian_Documentation *doc);

-- 


Reply via email to