gleam-lang/gleam

LSP: Support triggering find references from imports

Open

#5544 opened on Mar 31, 2026

View on GitHub
 (1 comment) (0 reactions) (0 assignees)Rust (21,417 stars) (960 forks)batch import
help wanted

Description

In the following example, triggering find references on any of the underlined locations should show all of the uses of the type Foo. It currently works everywhere but in the import line.

// -- foo.gleam
pub type Foo
//       ^^^

// -- app.gleam
import foo.{type Foo}
//               ^^^ ← this line shows up in all results, but triggering here fails
fn main() {
  let _: Foo = todo
  //     ^^^
}

Contributor guide