How to search for typeclass instances in Hoogle?

Is there a way to search for class instances in Hoogle (or Stackage)?

For example, I want to know which package defines the Lift instance for Text .

I managed to find it in the th-lift-instances package, but it took about 10 minutes to manually search. It seems that there must be some Hoogle functionality that allows you to search for instances.

+7
haskell stackage hoogle
source share
2 answers

Not yet. However, a feature has recently been added to allow instances to reference their source, and all new documentation built on Hackage is included. Therefore, in the next release of the th-lift package, you should see the Source link next to the Lift Text instance, which will tell you what you need to know.

+5
source share

Turning to Kolmar's comment , some of Google’s methods greatly advance instance search.

Examples:

-inurl: used to clear unnecessary results from where the specification was defined.

+1
source share

All Articles