pyccel.codegen.compiling.file_locks module#
Module handling classes which handle file locking to avoid deadlocks.
- class pyccel.codegen.compiling.file_locks.FileLockSet(locks=())[source]View on GitHub#
Bases:
objectClass for grouping file locks.
A class which groups file locks. By grouping these the locking can be handled via a context manager which reduces the risk of the locks not being correctly released.
- Parameters:
locks (iterable[FileLock], optional) – The locks that should be stored in the FileLockSet.
- append(new_lock)[source]View on GitHub#
Add a new lock to the FileLockSet.
Add a new lock to the FileLockSet.
- Parameters:
new_lock (FileLock) – The new lock.