aboutsummaryrefslogtreecommitdiff
path: root/cabal-helper.cabal
diff options
context:
space:
mode:
authorDaniel Gröber <dxld@darkboxed.org>2019-08-16 03:58:28 +0200
committerDaniel Gröber (dxld) <dxld@darkboxed.org>2019-09-17 17:48:26 +0200
commitd19e59312f3a6648bd53d489c60ec11b73289f40 (patch)
tree5146177c3eafac13db252ea975012db244243d55 /cabal-helper.cabal
parentf73498e8c861871294e9472a261b66884df8ca7e (diff)
Make caching more fine grained
Previously we only had a cache for the project info and each unit info. However adding support for passing overridden compiler paths to build tools introduces a nasty data dependency: to fully configure 'Program's we (used to) need ProjInfo which needs an already configured 'Programs' in readProjInfo (ugh). After at least four failed attempts at untangling this I arrived at this solution. Simply splitting up the caches into some smaller parts does the trick and as a side product forced me to add an abstraction for the caching logic so as to not reapeat myself even more. Relatedly runQuery is not just a field accessor anymore but actualy does some IO of itself to manage the cache and make already configured 'Program's available to the rest of the library.
Diffstat (limited to 'cabal-helper.cabal')
0 files changed, 0 insertions, 0 deletions