Skip to content

Commit

Permalink
Second attempt to fix #417 (and fix #458 too) (#460)
Browse files Browse the repository at this point in the history
* Revert "Hide lowercase modules. (#418)"

This reverts commit a8458b1.

* Omit lowercase modules in value completions.
  • Loading branch information
fhammerschmidt authored Jul 29, 2020
1 parent fe64076 commit 9cec6be
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/analyze/NewCompletions.re
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,11 @@ let valueCompletions = (~env: Query.queryEnv, suffix) => {
Log.log(" - Completing in " ++ env.file.uri);
let results = [];
let results =
if (isCapitalized(suffix)) {
if (suffix == "" || isCapitalized(suffix)) {

// Get rid of lowercase modules (#417)
env.exported.modules |> Hashtbl.filter_map_inplace((name, key) => isCapitalized(name) ? Some(key) : None);

let moduleCompletions = completionForExporteds(
env.exported.modules, env.file.stamps.modules, suffix, m =>
Module(m)
Expand Down

0 comments on commit 9cec6be

Please sign in to comment.