Exemple #1
0
 def __init__(self, extmodule, files_sum_repository=None, encoding='ascii'):
     object.__init__(self)
     self.__extmodule = extmodule
     self.__files_sum_repository = files_sum_repository
     self.__encoding=encoding
     if None is files_sum_repository:
         self.__files_sum_repository = md5sum_repository.dummy_repository_t()
     self.__exposed_decls_db = utils.exposed_decls_db_t()
     self.__exposed_decls_db.register_decls( extmodule.global_ns
                                             , extmodule.specially_exposed_decls )
Exemple #2
0
    def register_module_dependency(self, other_module_generated_code_dir):
        """
        `already_exposed` solution is pretty good when you mix hand-written
        modules with `Py++` generated. It doesn't work/scale for "true"
        multi-module development. This is exactly the reason why `Py++`
        offers "semi automatic" solution.

        For every exposed module, `Py++` generates `exposed_decl.pypp.txt` file.
        This file contains the list of all parsed declarations and whether they
        were included or excluded. Later, when you work on another module, you
        can tell `Py++` that the current module depends on the previously
        generated one. `Py++` will load `exposed_decl.pypp.txt` file and update
        the declarations.
        """

        db = utils.exposed_decls_db_t()
        db.load(other_module_generated_code_dir)
        db.update_decls(self.global_ns)
Exemple #3
0
    def register_module_dependency( self, other_module_generated_code_dir ):
        """
        `already_exposed` solution is pretty good when you mix hand-written
        modules with `Py++` generated. It doesn't work/scale for "true"
        multi-module development. This is exactly the reason why `Py++`
        offers "semi automatic" solution.

        For every exposed module, `Py++` generates `exposed_decl.pypp.txt` file.
        This file contains the list of all parsed declarations and whether they
        were included or excluded. Later, when you work on another module, you
        can tell `Py++` that the current module depends on the previously
        generated one. `Py++` will load `exposed_decl.pypp.txt` file and update
        the declarations.
        """

        db = utils.exposed_decls_db_t()
        db.load( other_module_generated_code_dir )
        db.update_decls( self.global_ns )