resolve answers only for classes the host models - #617
Merged
Conversation
The no-var class fallback accepted any dotted capitalized name (the syntactic class shape), so resolve returned a token for classes jolt cannot back. Tooling feature-detects by resolving a class name — compliment gates its JDK9 module scanner on resolving java.lang.module.ModuleFinder — and a truthy answer sent it into Files.walk/Collectors machinery that then died, killing completion wholesale (the release fleet's nrepl job caught it). The dotted arm now requires the class graph or a registration, like the bare-symbol arm always did; the bare symbol still evaluates syntactically. Unit rows pin the feature-detection contract; the nil-versus- ClassNotFoundException difference is documented.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The v0.7.10 fleet's nrepl job caught a real #608 regression: resolve's no-var fallback accepted any dotted capitalized name (the syntactic class shape), so it returned a class token for classes jolt cannot back. compliment gates its JDK9 module scanner on (resolve-class ns 'java.lang.module.ModuleFinder) — truthy sent it into Files.walk/Collectors machinery that died with Unknown class Collectors, killing completion wholesale (every candidate set empty, 7 suite failures).
The dotted fallback now requires the class graph or a host registration, like the bare-symbol arm always did. Modeled classes keep resolving ((= (resolve 'java.util.Map) java.util.Map) still holds); unmodeled ones answer nil, which is the feature-detection answer tools want (the JVM throws ClassNotFoundException there — documented in known-divergences). Bare symbols in code keep the syntactic class model.
nrepl suite against a release binary with this fix: 63 tests, 132 assertions, 0 failures (was 7). Full make test green, cts matches baseline.