1.8 API for Bytecode Paths
(require compiler/compilation-path) | package: base |
Added in version 6.0.1.10 of package base.
procedure
(get-compilation-dir+name path [ #:modes modes #:roots roots]) →
path? path? path : path-string?
modes : (non-empty-listof (and/c path-string? relative-path?)) = (use-compiled-file-paths)
roots : (non-empty-listof (or/c path-string? 'same)) = (current-compiled-file-roots)
Determines the directory that holds the bytecode form of path
plus the base name of path.
The directory is determined by checking roots in order, and for each element of roots checking modes in order. The first such directory that contains a file whose name matches path with ".zo" added (in the sense of path-add-suffix) is reported as the return directory path. If no such file is found, the result corresponds to the first elements of modes and roots.
procedure
(get-compilation-dir path [ #:modes modes #:roots roots]) → path? path : path-string?
modes : (non-empty-listof (and/c path-string? relative-path?)) = (use-compiled-file-paths)
roots : (non-empty-listof (or/c path-string? 'same)) = (current-compiled-file-roots)
The same as get-compilation-dir+name, but returning only the first result.
procedure
(get-compilation-bytecode-file path [ #:modes modes #:roots roots]) → path? path : path-string?
modes : (non-empty-listof (and/c path-string? relative-path?)) = (use-compiled-file-paths)
roots : (non-empty-listof (or/c path-string? 'same)) = (current-compiled-file-roots)
The same as get-compilation-dir+name, but combines the
results and adds a ".zo" suffix to arrive at a bytecode file
path.