1
1
mirror of https://github.com/github/semantic.git synced 2024-11-24 08:54:07 +03:00

Generalize concreteAnalysis over the name type.

This commit is contained in:
Rob Rix 2019-10-11 11:02:31 -04:00
parent d62dc3c5cf
commit 12739872c5
No known key found for this signature in database
GPG Key ID: F188A01508EA1CF7

View File

@ -111,15 +111,18 @@ runFile eval file = traverse run file
concreteAnalysis :: ( Carrier sig m
, Foldable term
, IsString name
, Member Fresh sig
, Member (Reader (Env Name)) sig
, Member (Reader (Env name)) sig
, Member (Reader Path.AbsRelFile) sig
, Member (Reader Span) sig
, Member (State (Heap (term Name) Name)) sig
, Member (State (Heap (term name) name)) sig
, MonadFail m
, Show (term Name)
, Ord name
, Show name
, Show (term name)
)
=> Analysis (term Name) Name Precise (Concrete (term Name) Name) m
=> Analysis (term name) name Precise (Concrete (term name) name) m
concreteAnalysis = Analysis{..}
where alloc _ = fresh
bind name addr m = local (Map.insert name addr) m