Claim slice 6b: language-neutral qualified-call resolver, Elixir and Clojure

Open
#390 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
18/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Active
Tech stack
clojure, cpp, elixir
Domain
tooling

Research direction

Start with src/elixir_resolve.h, which holds the module table to generalise into one shared resolver, and with the CONTRIBUTING.md section on adding a language. The work depends on PR #349 landing first and on coordinating with the maintainers' slice 6a. Begin with red-first Clojure alias/require fixtures, including the my.app.util example, same-name decoys, missing modules and ambiguous targets. Done means those fixtures pass and Elixir's regression output stays byte-identical.

Written by the indexing model from the issue text.

Description

I'd like to claim slice 6b: the language-neutral qualified-call resolver from Adding a language: common stays common, following the maintainer's invitation on #349.

This is a separate follow-up PR after #349 lands.

Problem and intended behavior

#349 records the written qualifier of a Clojure call but does not resolve namespace aliases or imports. Given:

(ns my.app.core
  (:require [my.app.util :as u]))

(defn run [x] (u/f x))

and an indexed f definition in my.app.util, the call should resolve to that definition rather than to unrelated bare-name candidates.

Scope

Generalise src/elixir_resolve.h's module table into one shared resolver driven by per-language alias/import/require facts. Preserve Elixir as an existing user and add Clojure as the first new user. Avoid a parallel Clojure-only module resolver or language-specific fallback guard.

Pin the supported Clojure namespace/require forms with fixtures before widening them; only indexed, statically established targets can supply resolved edges. Ambiguous, external, or unsupported forms must retain honest unresolved/declined behavior and disclosures.

The maintainers' slice 6a stops the wrong edge for an unplaced qualifier; 6b adds the right edge for a proven module target. Coordinate landing order with 6a and flip #349's retained str/join known-gap arm when the shared refusal lands. Implementing 6a is not claimed here.

Acceptance

  • Red-first alias/require and qualified-call fixtures, including same-name decoys, missing modules, and ambiguous targets.
  • The example above reaches my.app.util's f through the shared resolver.
  • Elixir's existing output stays byte-identical on the regression fixtures and before/after corpus comparisons.
  • No unrelated language's resolution changes; cold/warm cache parity, deterministic XML, and correct extraction-version / mirror / hash updates.
  • Document the supported namespace forms and remaining resolution limits.

Related: #349, the slice 5a/8a continuation #389, and the CONTRIBUTING feature-family map. Macro expansion, dynamic invocation, and protocol dispatch are outside this slice.

Dominant language
C++
Stars
2.5k
Forks
158
Avg merge
1d 7h
Merged PRs (30d)
87

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from redhat-et/ripwire

All issues in redhat-et/ripwire

Similar issues

More C++ issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.