Hacktoberfest 2026: as issues que os mantenedores marcaram para outubro, abertas e boas para iniciantes. Ver issues do Hacktoberfest

Hover and completion on an applied functor show the functor body's types

Aberta
#9,072 0 comentários 0 reações 0 responsáveis Ver no GitHub

Mantenedores costumam responder em até 1 dia

@cknitt já está trabalhando nisso.

Desde 27/10/2026.

  • #9084 de @cknitt — aberto

Avaliação

Dificuldade
4/5
Tempo estimado
3-5 dias
Facilidade para iniciantes
35/100
Tipo de issue
Bug
Clareza
Claramente especificada
Status de atividade
Estagnada
Stack de tecnologia
ocaml
Domínio
tooling

Direção de pesquisa

Start with for_module in analysis/src/process_cmt.ml, which the issue identifies as mishandling Tmod_apply by ignoring the argument. Compare its handling with the applied module's compiler signature and the supplied MakeSet example. Done means hover and completion for IntSet show the applied int types instead of the functor body's O.t types; linked pull request 9084 is already open.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

For a module created by applying a functor, hover and completion show the types of the functor's body instead of the applied signature:

module MakeSet = (O: Ord) => {
  type t = array<O.t>
  let add = (s: t, x: O.t) => s->Array.concat([x])
}
module IntSet = MakeSet({
  type t = int
  let compare = (a: int, b) => a - b
})
let s = IntSet.add([], 1)
//             ^ hover
// let s2 = IntSet.
//                 ^ completion

Hover on IntSet.add shows type IntSet.t = array<O.t>, and completion of IntSet. shows add: (t, O.t) => array<O.t>. The compiler's signature is type t = array<int> and let add: (t, int) => array<int>.

for_module in analysis/src/process_cmt.ml handles Tmod_apply by recursing into the functor's own module expression and ignores the argument.

Linguagem predominante
OCaml
Estrelas
7.5k
Forks
484
Merge médio
20h 19min
PRs com merge (30d)
242

Preparar o ambiente

Abrir no Codespaces

Inicia o contêiner de desenvolvimento do projeto no navegador, com a sua própria conta do GitHub.

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de rescript-lang/rescript

Todas as issues de rescript-lang/rescript

Issues semelhantes

Mais issues de DevTools

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.