* The files whose declarations are a file's unit's own, the file first: the * unit is its own file and the include files it pulls in, so code in * `mormot.core.os.pas` sees a variable `mormot.core.os.posix.inc` declares, * and that file's code sees the unit's (see unitFilesOf).
(filePath: string, context: ResolutionContext)
| 872 | * and that file's code sees the unit's (see unitFilesOf). |
| 873 | */ |
| 874 | function ownUnitFiles(filePath: string, context: ResolutionContext): string[] { |
| 875 | const memo = memos(context).ownFiles; |
| 876 | let own = memo.get(filePath); |
| 877 | if (!own) { |
| 878 | const unit = unitFilesOf(filePath, context); |
| 879 | own = unit[0] === filePath ? unit : [filePath, ...unit.filter((f) => f !== filePath)]; |
| 880 | memo.set(filePath, own); |
| 881 | } |
| 882 | return own; |
| 883 | } |
| 884 | |
| 885 | /** |
| 886 | * The files one unit is made of: its own file, then the include files it |
no test coverage detected