big compiler refactoring; avoid globals for multi method dispatcher generation
This commit is contained in:
parent
311253ef2f
commit
46efaf294b
29 changed files with 225 additions and 215 deletions
|
|
@ -567,6 +567,15 @@ proc newFileInfo(fullPath, projPath: string): TFileInfo =
|
|||
if optEmbedOrigSrc in gGlobalOptions or true:
|
||||
result.lines = @[]
|
||||
|
||||
proc fileInfoKnown*(filename: string): bool =
|
||||
var
|
||||
canon: string
|
||||
try:
|
||||
canon = canonicalizePath(filename)
|
||||
except:
|
||||
canon = filename
|
||||
result = filenameToIndexTbl.hasKey(canon)
|
||||
|
||||
proc fileInfoIdx*(filename: string; isKnownFile: var bool): int32 =
|
||||
var
|
||||
canon: string
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue