Skip to content

Commit

Permalink
clean up code
Browse files Browse the repository at this point in the history
  • Loading branch information
goanpeca committed Aug 13, 2017
1 parent 052101e commit 18ad46a
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions tools/compile_stdlib.py
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ def ouroboros_compiled_folder(target='java'):


def module_overrides():
""""""
"""Find stdlib modules already implemented in java."""
folder_overrides = os.path.join(REPO_ROOT, 'python', 'common', 'python')
paths = []
for folder, subfolders, files in os.walk(folder_overrides):
Expand Down Expand Up @@ -271,7 +271,7 @@ def list_files():

def compile_with_voc(args):
"""
Compile the given (path, queue1, queue2) with voc.
Compile the given (path, queue1, queue2, target) with voc.
Save results in the queues passed by pool.map.
"""
Expand Down Expand Up @@ -353,13 +353,15 @@ def run_process(paths, target='java'):


def main(target='java'):
""""""
"""Run main compilation process."""
start = datetime.now()
clone_update_repo()
paths = list_files()

# List valid files to try to compile
paths = list_files()
print('\nFound: {} python files\n'.format(len(paths)))

# Run compilation process
failed_list , xpassed_list = run_process(paths)
n_err = len(failed_list) + len(xpassed_list)
n_compiled = len(paths) - len(MODULES_NOT_COMPILING)
Expand Down

0 comments on commit 18ad46a

Please sign in to comment.