mirror of
https://github.com/github/semantic.git
synced 2025-01-05 14:11:33 +03:00
Move MonadOrigin into the Origin module.
This commit is contained in:
parent
c8829b39f3
commit
a0667d0414
@ -5,10 +5,6 @@ import Control.Abstract.Addressable
|
||||
import Data.Abstract.Address
|
||||
import Data.Abstract.Origin
|
||||
|
||||
class Monad m => MonadOrigin m where
|
||||
askOrigin :: m Origin
|
||||
|
||||
|
||||
data Located location = Located { location :: location, provenance :: !Origin }
|
||||
deriving (Eq, Ord, Show)
|
||||
|
||||
|
@ -11,6 +11,11 @@ data Origin
|
||||
| Local !ModuleName !FilePath !Range !Span
|
||||
deriving (Eq, Ord, Show)
|
||||
|
||||
|
||||
class Monad m => MonadOrigin m where
|
||||
askOrigin :: m Origin
|
||||
|
||||
|
||||
instance Semigroup Origin where
|
||||
a <> Unknown = a
|
||||
_ <> b = b
|
||||
|
Loading…
Reference in New Issue
Block a user