Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data SearchResult
- = Tp TypeResult
- | Tm TermResult
- data TermResult = TermResult {}
- data TypeResult = TypeResult {}
- pattern Tm' :: HashQualified Name -> Referent -> Set (HashQualified Name) -> SearchResult
- pattern Tp' :: HashQualified Name -> Reference -> Set (HashQualified Name) -> SearchResult
- termResult :: HashQualified Name -> Referent -> Set (HashQualified Name) -> SearchResult
- termSearchResult :: Names -> Name -> Referent -> SearchResult
- typeResult :: HashQualified Name -> Reference -> Set (HashQualified Name) -> SearchResult
- typeSearchResult :: Names -> Name -> Reference -> SearchResult
- name :: SearchResult -> HashQualified Name
- aliases :: SearchResult -> Set (HashQualified Name)
- toReferent :: SearchResult -> Referent
- truncateAliases :: Int -> SearchResult -> SearchResult
- fromNames :: Names -> [SearchResult]
- _fromNames :: Names -> [SearchResult]
- compareByName :: SearchResult -> SearchResult -> Ordering
Documentation
data SearchResult Source #
Instances
Show SearchResult Source # | |
Defined in Unison.Server.SearchResult showsPrec :: Int -> SearchResult -> ShowS # show :: SearchResult -> String # showList :: [SearchResult] -> ShowS # | |
Eq SearchResult Source # | |
Defined in Unison.Server.SearchResult (==) :: SearchResult -> SearchResult -> Bool # (/=) :: SearchResult -> SearchResult -> Bool # | |
Ord SearchResult Source # | |
Defined in Unison.Server.SearchResult compare :: SearchResult -> SearchResult -> Ordering # (<) :: SearchResult -> SearchResult -> Bool # (<=) :: SearchResult -> SearchResult -> Bool # (>) :: SearchResult -> SearchResult -> Bool # (>=) :: SearchResult -> SearchResult -> Bool # max :: SearchResult -> SearchResult -> SearchResult # min :: SearchResult -> SearchResult -> SearchResult # |
data TermResult Source #
TermResult | |
|
Instances
Show TermResult Source # | |
Defined in Unison.Server.SearchResult showsPrec :: Int -> TermResult -> ShowS # show :: TermResult -> String # showList :: [TermResult] -> ShowS # | |
Eq TermResult Source # | |
Defined in Unison.Server.SearchResult (==) :: TermResult -> TermResult -> Bool # (/=) :: TermResult -> TermResult -> Bool # | |
Ord TermResult Source # | |
Defined in Unison.Server.SearchResult compare :: TermResult -> TermResult -> Ordering # (<) :: TermResult -> TermResult -> Bool # (<=) :: TermResult -> TermResult -> Bool # (>) :: TermResult -> TermResult -> Bool # (>=) :: TermResult -> TermResult -> Bool # max :: TermResult -> TermResult -> TermResult # min :: TermResult -> TermResult -> TermResult # |
data TypeResult Source #
TypeResult | |
|
Instances
Show TypeResult Source # | |
Defined in Unison.Server.SearchResult showsPrec :: Int -> TypeResult -> ShowS # show :: TypeResult -> String # showList :: [TypeResult] -> ShowS # | |
Eq TypeResult Source # | |
Defined in Unison.Server.SearchResult (==) :: TypeResult -> TypeResult -> Bool # (/=) :: TypeResult -> TypeResult -> Bool # | |
Ord TypeResult Source # | |
Defined in Unison.Server.SearchResult compare :: TypeResult -> TypeResult -> Ordering # (<) :: TypeResult -> TypeResult -> Bool # (<=) :: TypeResult -> TypeResult -> Bool # (>) :: TypeResult -> TypeResult -> Bool # (>=) :: TypeResult -> TypeResult -> Bool # max :: TypeResult -> TypeResult -> TypeResult # min :: TypeResult -> TypeResult -> TypeResult # |
pattern Tm' :: HashQualified Name -> Referent -> Set (HashQualified Name) -> SearchResult Source #
pattern Tp' :: HashQualified Name -> Reference -> Set (HashQualified Name) -> SearchResult Source #
termResult :: HashQualified Name -> Referent -> Set (HashQualified Name) -> SearchResult Source #
Construct a term search result from a primary name, referent, and set of aliases.
termSearchResult :: Names -> Name -> Referent -> SearchResult Source #
typeResult :: HashQualified Name -> Reference -> Set (HashQualified Name) -> SearchResult Source #
Construct a type search result from a primary name, reference, and set of aliases.
typeSearchResult :: Names -> Name -> Reference -> SearchResult Source #
name :: SearchResult -> HashQualified Name Source #
aliases :: SearchResult -> Set (HashQualified Name) Source #
toReferent :: SearchResult -> Referent Source #
TypeResults yield a Ref
truncateAliases :: Int -> SearchResult -> SearchResult Source #
fromNames :: Names -> [SearchResult] Source #
You may want to sort this list differently afterward.
_fromNames :: Names -> [SearchResult] Source #
compareByName :: SearchResult -> SearchResult -> Ordering Source #
Sort a list of search results by name. If names are equal, fall back to comparing by reference (putting types before terms).