fix(compiler): resolve, name, and load namespaces by source extension (#116) - #117
Merged
Conversation
#116) IsCljAssembly matches .clj.dll, .cljc.dll and .cljr.dll; the coexistence import hooks use it instead of their own suffix check.
…#116) source-extensions becomes [".cljr" ".cljc" ".clj"] in both copies. compile-file derives the assembly name from the source extension, so foo.cljc emits foo.cljc.dll. -load takes the assembly candidate from the resolved source's extension instead of searching for it independently. smoke/interop becomes .cljr.
…rce extension fixes (#116)
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.
Closes #116
source-extensionsbecomes[".cljr" ".cljc" ".clj"]in both copies, matching ClojureCLR.compile-filederives the assembly name from the source extension, sofoo.cljcemitsfoo.cljc.dll.-loadtakes its assembly candidate from the resolved source's extension instead of searching independently, so a stalefoo.clj.dllcannot win an mtime comparison againstfoo.cljc.cljr.IsCljAssemblymatches all three suffixes, and the coexistence import hooks use it instead of their own check.interopnamespace becomes.cljr, giving the IL2CPP build a mixed assembly set.source-extensionsin agreement, sincebuild.cljcompilesmagic.apiagainst the previousclojure.core.