Open
Conversation
Changes across 5 files to make instaparse loadable from source in babashka: - auto_flatten_seq.cljc: For :bb, use plain vectors with metadata markers (::afs, ::dirty) instead of custom deftype. Extend ConjFlat protocol to PersistentVector. Skip JVM-only macros (compile-if, mix-collection-hash-bc). - gll.cljc: Skip Segment deftype (use plain strings like cljs). Add :bb branches for text->segment, sub-sequence. Preserve existing metadata in safe-with-meta for :bb (merge instead of replace) to keep AFS markers. - cfg.cljc: Use edn/read-string for safe-read-string in :bb. - core.cljc: Skip IFn implementation on Parser defrecord for :bb. - reduction.cljc: Remove debug instrumentation.
Wrap Parser records in callable fns for bb (IFn via fn + metadata), unwrap in parse/parses. Add bb.edn with test:bb task. Skip round-trip-test and print-test (require record printing) and StringBuilder test (bb text->segment only supports String) in bb.
Author
|
Sorry, I realized that there was already a test runner in CircleCI. Moved the test-bb job there. |
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.
Hi @Engelberg. In this PR I've added babashka compatibility. The main difference with JVM Clojure is that it doesn't support the AutoFlattenSeq deftype stuff as of today. This PR relies on changes that are only available in the master branch of babashka. I've added a Github test runner to verify that everything works. If you would like to have any changes to this, please let me know!