user-documentation icon indicating copy to clipboard operation
user-documentation copied to clipboard

Add signature search

Open fredemmott opened this issue 7 years ago • 2 comments

For example, searching for:

  • (string): string could return Str\uppercase
  • (vec<Ta>): vec<Tb> could return Vec\map
  • (vec<_>): vec<_> should also return Vec\map
  • (dict<_, _>): vec<_> should also return Vec\map
  • (vec<_>): int should return C\count

This should have a basic understanding of generics and variance (e.g. if I search for vec<T> as a parameter type that should include Container<T>); _ could be implemented as a universal base type instead of a special-cased subtype

fredemmott avatar Dec 06 '18 18:12 fredemmott

https://www.haskell.org/hoogle/ is comparable

fredemmott avatar Dec 06 '18 18:12 fredemmott

This would likely involve changes to:

  • src/api-gen and src/hh-apidocs to include signatures in metadata
  • src/search to implement the actual search

fredemmott avatar Dec 06 '18 18:12 fredemmott