Skip to content

Better typing recovery#1484

Merged
voodoos merged 6 commits intomasterfrom
better-typing-recovery
Jun 28, 2022
Merged

Better typing recovery#1484
voodoos merged 6 commits intomasterfrom
better-typing-recovery

Conversation

@trefis
Copy link
Copy Markdown
Contributor

@trefis trefis commented Jun 22, 2022

Most notably: we now recover at the granularity of core_types.
This in particular mean that value bindings with a faulty type annotation are not dropped from the typedtree anymore, and show up in the result of outline.

I also added a call to with_saved_types which seems right to me, but to be checked by @let-def .

exp_type = ty_expected_explained.ty;
exp_env = env;
exp_attributes = merlin_recovery_attributes [];
exp_attributes = Msupport.recovery_attributes [];
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel like this [] should instead be sexp.pexp_attributes...

@voodoos voodoos added this to the 4.6 / 3.8 milestone Jun 24, 2022
@voodoos voodoos requested a review from let-def June 27, 2022 14:06
@trefis trefis force-pushed the better-typing-recovery branch from 43d7323 to 14dbb95 Compare June 28, 2022 16:15
@trefis trefis force-pushed the better-typing-recovery branch from 9cf5c0e to e72132f Compare June 28, 2022 16:26
@voodoos voodoos merged commit d6943ba into master Jun 28, 2022
voodoos added a commit to voodoos/merlin that referenced this pull request Jun 29, 2022
from ocaml/better-typing-recovery
voodoos added a commit to voodoos/merlin that referenced this pull request Jun 30, 2022
from ocaml/better-typing-recovery
voodoos added a commit to voodoos/opam-repository that referenced this pull request Jun 30, 2022
CHANGES:

Thu Jun 30 14:51:42 CEST 2022

  + merlin binary
    - make most library public and split merlin in two packages: the
      `merlin-lib` package that exposes merlin's internals and the `merlin`
      package with the frontend. (ocaml/merlin#1448, ocaml/merlin#1455, ocaml/merlin#1457, ocaml/merlin#1497, @rgrinberg,
      @tmattio, @kit-ty-kate)
    - Type printing: use best_module_path for paths from Mty_alias (ocaml/merlin#1470)
    - Attempt at finding the 'real' capitalization of files on windows (ocaml/merlin#1462 by
      @mlasson)
    - Use newer `Seq`-based API of Yojson 2.0, avoiding the need for the
      deprecated `Stream` module (ocaml/merlin#1475 by @Leonidas-from-XIV)
    - unify parsing of `MERLIN_LOG` (ocaml/merlin#1480 by @ulugbekna)
    - Fix type deduplication in `type-enclosing` results (ocaml/merlin#1483, fixes ocaml/merlin#1477)
    - Only weakly reduce the shapes to speed up the new Merlin locate
      implementation. (ocaml/merlin#1488)
    - Ignore unknown configuration tags from dune configuration provider but not
      from dot-merlin-reader (ocaml/merlin#1486)
    - typing recovery: recover at the granularity of `core_type` (ocaml/merlin#1484)
  + editor modes
    - add method imenu items for emacs (ocaml/merlin#1481, @mndrix)
    - emacs: Make the prefix argument to `merlin-locate` optional, both for
      consistency with Emacs convention and for backwards compatibility. (ocaml/merlin#1476,
      @antalsz)
    - emacs: fix duplicated prefix path in imenu entries (ocaml/merlin#1495, @bcc32)
voodoos added a commit to voodoos/opam-repository that referenced this pull request Jul 1, 2022
CHANGES:

Fri Jul  1 12:51:42 CEST 2022

  + merlin binary
    - Type printing: use `best_module_path` for paths from `Mty_alias` (ocaml/merlin#1470)
    - Attempt at finding the 'real' capitalization of files on windows (ocaml/merlin#1462 by
      @mlasson)
    - Use newer `Seq`-based API of Yojson 2.0, avoiding the need for the
      deprecated `Stream` module (ocaml/merlin#1475 by @Leonidas-from-XIV)
    - unify parsing of `MERLIN_LOG` (ocaml/merlin#1480 by @ulugbekna)
    - Fix type deduplication in `type-enclosing` results (ocaml/merlin#1483, fixes ocaml/merlin#1477)
    - Ignore unknown configuration tags from dune configuration provider but not
      from dot-merlin-reader (ocaml/merlin#1486)
    - typing recovery: recover at the granularity of `core_type` (ocaml/merlin#1484)
  + editor modes
    - Fix `merlin-locate-in-new-window` is ignored (ocaml/merlin#1461 by @emturner,
      fixes ocaml/merlin#1460)
    - add method imenu items for emacs (ocaml/merlin#1481, @mndrix)
    - emacs: Make the prefix argument to `merlin-locate` optional, both for
      consistency with Emacs convention and for backwards compatibility. (ocaml/merlin#1476,
      @antalsz)
voodoos added a commit to voodoos/opam-repository that referenced this pull request Jul 1, 2022
CHANGES:

Fri Jul  1 12:51:42 CEST 2022

  + merlin binary
    - Type printing: use `best_module_path` for paths from `Mty_alias` (ocaml/merlin#1470)
    - Attempt at finding the 'real' capitalization of files on windows (ocaml/merlin#1462 by
      @mlasson)
    - Use newer `Seq`-based API of Yojson 2.0, avoiding the need for the
      deprecated `Stream` module (ocaml/merlin#1475 by @Leonidas-from-XIV)
    - unify parsing of `MERLIN_LOG` (ocaml/merlin#1480 by @ulugbekna)
    - Fix type deduplication in `type-enclosing` results (ocaml/merlin#1483, fixes ocaml/merlin#1477)
    - Ignore unknown configuration tags from dune configuration provider but not
      from dot-merlin-reader (ocaml/merlin#1486)
    - typing recovery: recover at the granularity of `core_type` (ocaml/merlin#1484)
  + editor modes
    - Fix `merlin-locate-in-new-window` is ignored (ocaml/merlin#1461 by @emturner,
      fixes ocaml/merlin#1460)
    - add method imenu items for emacs (ocaml/merlin#1481, @mndrix)
    - emacs: Make the prefix argument to `merlin-locate` optional, both for
      consistency with Emacs convention and for backwards compatibility. (ocaml/merlin#1476,
      @antalsz)
    - emacs: fix duplicated prefix path in imenu entries (ocaml/merlin#1495, @bcc32)
voodoos added a commit to voodoos/opam-repository that referenced this pull request Jul 1, 2022
CHANGES:

Fri Jul  1 12:51:42 CEST 2022

  + merlin binary
    - Type printing: use `best_module_path` for paths from `Mty_alias` (ocaml/merlin#1470)
    - Attempt at finding the 'real' capitalization of files on windows (ocaml/merlin#1462 by
      @mlasson)
    - Use newer `Seq`-based API of Yojson 2.0, avoiding the need for the
      deprecated `Stream` module (ocaml/merlin#1475 by @Leonidas-from-XIV)
    - unify parsing of `MERLIN_LOG` (ocaml/merlin#1480 by @ulugbekna)
    - Fix type deduplication in `type-enclosing` results (ocaml/merlin#1483, fixes ocaml/merlin#1477)
    - Ignore unknown configuration tags from dune configuration provider but not
      from dot-merlin-reader (ocaml/merlin#1486)
    - typing recovery: recover at the granularity of `core_type` (ocaml/merlin#1484)
  + editor modes
    - Fix `merlin-locate-in-new-window` is ignored (ocaml/merlin#1461 by @emturner,
      fixes ocaml/merlin#1460)
    - add method imenu items for emacs (ocaml/merlin#1481, @mndrix)
    - emacs: Make the prefix argument to `merlin-locate` optional, both for
      consistency with Emacs convention and for backwards compatibility. (ocaml/merlin#1476,
      @antalsz)
    - emacs: fix duplicated prefix path in imenu entries (ocaml/merlin#1495, @bcc32)
voodoos added a commit to voodoos/opam-repository that referenced this pull request Jul 1, 2022
CHANGES:

Fri Jul  1 12:51:42 CEST 2022

  + merlin binary
    - Type printing: use `best_module_path` for paths from `Mty_alias` (ocaml/merlin#1470)
    - Attempt at finding the 'real' capitalization of files on windows (ocaml/merlin#1462 by
      @mlasson)
    - Use newer `Seq`-based API of Yojson 2.0, avoiding the need for the
      deprecated `Stream` module (ocaml/merlin#1475 by @Leonidas-from-XIV)
    - unify parsing of `MERLIN_LOG` (ocaml/merlin#1480 by @ulugbekna)
    - Fix type deduplication in `type-enclosing` results (ocaml/merlin#1483, fixes ocaml/merlin#1477)
    - Ignore unknown configuration tags from dune configuration provider but not
      from dot-merlin-reader (ocaml/merlin#1486)
    - typing recovery: recover at the granularity of `core_type` (ocaml/merlin#1484)
  + editor modes
    - Fix `merlin-locate-in-new-window` is ignored (ocaml/merlin#1461 by @emturner,
      fixes ocaml/merlin#1460)
    - add method imenu items for emacs (ocaml/merlin#1481, @mndrix)
    - emacs: Make the prefix argument to `merlin-locate` optional, both for
      consistency with Emacs convention and for backwards compatibility. (ocaml/merlin#1476,
      @antalsz)
@trefis trefis deleted the better-typing-recovery branch February 6, 2023 13:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants