| Trees | Indices | Help |
|
|---|
|
|
1 # Copyright 2004-2008 Roman Yakovenko. 2 # Distributed under the Boost Software License, Version 1.0. (See 3 # accompanying file LICENSE_1_0.txt or copy at 4 # http://www.boost.org/LICENSE_1_0.txt) 5 6 import types 7 from pygccxml.declarations import * 811 decl_visitor_t.__init__(self) 12 type_visitor_t.__init__(self) 13 object.__init__(self) 14 15 self.__decls = decls 16 self.__types = types 17 self.__access = access 18 self.__membership = membership 19 self.__files = files 20 self.__inst = None 21 22 self.__compiler = None 23 if self.__decls: 24 for d in self.__decls.itervalues(): 25 self.__compiler = d.compiler 26 break2731 self.__inst = inst 32 #use inst, to reduce attribute access time 33 if isinstance( inst, declaration_t ) and inst.location: 34 inst.location.file_name = self.__files[inst.location.file_name]35 instance = property( _get_inst, _set_inst ) 3638 if type_id is None: 39 return None #in some situations type_id is None, return_type of constructor or destructor 40 elif self.__types.has_key( type_id ): 41 return self.__types[type_id] 42 elif self.__decls.has_key( type_id ): 43 base = declarated_t( declaration=self.__decls[ type_id ] ) 44 self.__types[type_id] = base 45 return base 46 elif '...' == type_id: