1
1
mirror of https://github.com/github/semantic.git synced 2025-01-03 04:51:57 +03:00

📝 the Origin constructors.

This commit is contained in:
Rob Rix 2018-04-02 17:53:02 -04:00
parent 0c6bbc92e9
commit 705a6b125f

View File

@ -7,9 +7,13 @@ import Prologue
-- | An 'Origin' encapsulates the location at which a name is bound or allocated.
data Origin term ty where
-- | We dont know anything, or there isnt even something to know anything about.
Unknown :: Origin term any
-- | We know the package.
Package :: P.PackageInfo -> Origin term 'P
-- | We know the module, and possibly package.
Module :: Origin term 'P -> M.ModuleInfo -> Origin term 'M
-- | We know the term, and possibly module and package.
Term :: Origin term 'M -> Base term () -> Origin term 'T
-- | A type index indicating the finest grain of information available in a given 'Origin'.