Open cfcs opened 5 years ago
Personally I'm no longer using topfind
, the cognitive burden of remembering in which ocamlfind
package the module I want to use lives is is too high, so I simply load modules via omod
.
Moreover both points becomes moot if we can get this to work https://github.com/b0-system/odig/issues/10#issuecomment-315884371 (replace Odig
mentions there by Omod
). In other words we can automatically (or after manual confirmation) load modules and their dependencies on the fly when users try to access them. But for it to be made to work seamlessly it needs fixes upstream which I would like to encourage to people to consider https://github.com/ocaml/ocaml/issues/7589.
So no plans for topfind
sorry. But if you can cook something up that is not too invasive I might consider it for inclusion.
In general completion improvements are tracked in https://github.com/dbuenzli/down/issues/11
@dbuenzli Ah, I didn't know about omod
and am not tied to topfind
by any means; I'd be happy to use omod
instead. Is this how you would use it? (either I'm using it wrong or something seems slightly broken)
# Omod.load "Unix";;
[INC] /home/user/.opam/4.07.1+afl/lib/ocaml
[ERROR] include /home/user/.opam/4.07.1+afl/lib/ocaml:
Unknown exception:
Invalid_argument
- : bool = false
Try to export OCAMLRUNPARAM='b'
to get a better stacktrace and report any problems on the omod
bug tracker and not here, also please try to confirm the error with a stock 4.07.1 so that this can be pinned down.
1) It would be nice to have tab completion for
topfind
, not sure if that is out of scope fordown
, but it would make my life easier, I imagine something like this (pulling from#list
):2) Additionally, I currently get tab completion for (for example)
Ptime_clock
, but when I try to use it, I get:Would it be possible to determine if Ptime_clock.now was currently in scope, and if not, print the required package name as a suggestion, either in the tab completion or when a line referencing it is executed?