Skip to content

Deterministic generation and other ideas#33

Open
irigarae wants to merge 29 commits intohenryw374:masterfrom
irigarae:deterministic-generation
Open

Deterministic generation and other ideas#33
irigarae wants to merge 29 commits intohenryw374:masterfrom
irigarae:deterministic-generation

Conversation

@irigarae
Copy link
Copy Markdown
Contributor

@irigarae irigarae commented Apr 20, 2026

Hi @henryw374, as mentioned on #31 (comment) while looking how to add the constructor I had some ideas and here's a PR showing them.

I don't want to get this PR merged necessarily, just to leave the code here for you, in case you want to cherry-pick some or it gives you other ideas on what would be nice for the codebase.

The commits are atomic, followed with some generation, so you can take a look at them individually and see the changes.

  1. Deterministic order when multiple methods with the same number of arguments
  2. Deterministic args (not via gensym)
  3. Parse argument names from Java source and use them in the functions
  4. Non namespaces defn
  5. Remove ^{:line 89, :column 16} meta from output
  6. Pretty print with zprint
  7. Parse Java sources for the docstrings and plug them in the functions.
    • This gave some JSDoc errors on CI though. Haven't really touched ClojureScript, maybe the docstrings could be only on the .clj.
  8. Non namespaced clojure calls inside fn when multiple overloads with same number of arguments
  9. Unwrap and when single condition
  10. Tag this at method level instead of let
  11. Also wrap char like int
  12. Tag left hand side of the let local declaration
    • Requires bumping the clojure version on CI for the java.time.temporal.TemporalField/1 class syntax
  13. Docstrings for the constants too

As I say, I use this as a way to bring many ideas all at once, maybe unrelated, if you like some of them I could do individual PRs, or you can just do whatever :)

Thanks for the library.

@irigarae irigarae force-pushed the deterministic-generation branch from b63fe34 to 6c1ca99 Compare April 20, 2026 22:17
@irigarae irigarae force-pushed the deterministic-generation branch from a3b3f2d to b5b2c75 Compare April 21, 2026 07:06
@irigarae irigarae force-pushed the deterministic-generation branch from b5b2c75 to 9179960 Compare April 21, 2026 07:11
@irigarae irigarae force-pushed the deterministic-generation branch from 9179960 to b660117 Compare April 21, 2026 07:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant