mirror of
https://github.com/apple/swift-log
synced 2026-11-22 03:40:39 +00:00
Motivation: Right now, we use the full path (`#file`) for the logging as well as for parsing out the module name (which goes into `source` by default). This has two problems: 1. The file names contain the build server's full path, ie. aren't portable across different compiles (and are very long). 2. The module name parsing fails if we log from a file that's not in a directory named just like the module. Modification: Switch `#file` for `#fileID`. This changes a bunch of things: - `source` is always the module name by default (great!) - `file` changes from `/the/full/path/on/disk` to `ModuleName/FileBaseName.swift` (I think better, but it's a change) Result: `source` is more correct, `file` will be different.