diff --git a/.github/workflows/check.yaml b/.github/workflows/check.yaml index 46db596..b3569b5 100644 --- a/.github/workflows/check.yaml +++ b/.github/workflows/check.yaml @@ -12,23 +12,26 @@ jobs: name: Test runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - - name: ACTIONS_ALLOW_UNSECURE_COMMANDS - id: ACTIONS_ALLOW_UNSECURE_COMMANDS - run: echo 'ACTIONS_ALLOW_UNSECURE_COMMANDS=true' >> $GITHUB_ENV + - uses: supplypike/setup-bin@v3 + with: + uri: 'https://github.com/calcit-lang/calcit/releases/download/0.8.9/cr' + name: 'cr' + version: '0.8.9' - - name: add cr - run: | - mkdir -p $GITHUB_WORKSPACE/bin - wget -O $GITHUB_WORKSPACE/bin/cr http://repo.calcit-lang.org/binaries/linux/cr - chmod +x $GITHUB_WORKSPACE/bin/cr - echo "::add-path::$GITHUB_WORKSPACE/bin" + - uses: supplypike/setup-bin@v3 + with: + uri: 'https://github.com/calcit-lang/calcit/releases/download/0.8.9/caps' + name: 'caps' + version: '0.8.9' - - uses: actions-rs/toolchain@v1 + - uses: dtolnay/rust-toolchain@stable with: toolchain: stable + - uses: Swatinem/rust-cache@v2 + - run: cargo build --release - run: mkdir dylibs/ && ls target/release/ && cp -v target/release/*.* dylibs/ diff --git a/Cargo.lock b/Cargo.lock index 267ce99..e3ce95e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4,9 +4,9 @@ version = 3 [[package]] name = "aho-corasick" -version = "0.7.18" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e37cfd5e7657ada45f742d6e99ca5788580b5c529dc78faf11ece6dc702656f" +checksum = "b2969dcb958b36655471fc61f7e416fa76033bdd4bfed0678d8fee1e2d07a1f0" dependencies = [ "memchr", ] @@ -22,9 +22,9 @@ dependencies = [ [[package]] name = "cirru_edn" -version = "0.2.11" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a0ee334f8cc2ee791e8f0df7f934a50ce4cb48d2169b3d1bf7a3b2fbace3564a" +checksum = "8a35d38ee59f7409023f9dee361dc98760f33c9ad1f21283e536939d9561ed44" dependencies = [ "cirru_parser", "hex", @@ -33,9 +33,9 @@ dependencies = [ [[package]] name = "cirru_parser" -version = "0.1.16" +version = "0.1.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5004e11be1bc491748d59b73e3e0ad4f73ff2bbb47e0a9b3e205a83dc416fde" +checksum = "1297388204c9d3c72d1cafea80682fd6384e79c66dfe980460886bff7387e684" [[package]] name = "hex" @@ -51,15 +51,27 @@ checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" [[package]] name = "memchr" -version = "2.4.1" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "308cc39be01b73d0d18f82a0e7b2a3df85245f84af96fdddc5d202d27e47b86a" +checksum = "f665ee40bc4a3c5590afb1e9677db74a508659dfd71e126420da8274909a0167" [[package]] name = "regex" -version = "1.5.4" +version = "1.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d07a8629359eb56f1e2fb1652bb04212c072a87ba68546a04065d525673ac461" +checksum = "380b951a9c5e80ddfd6136919eef32310721aa4aacd4889a8d39124b026ab343" +dependencies = [ + "aho-corasick", + "memchr", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "regex-automata" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f804c7828047e88b2d32e2d7fe5a105da8ee3264f01902f796c8e067dc2483f" dependencies = [ "aho-corasick", "memchr", @@ -68,6 +80,6 @@ dependencies = [ [[package]] name = "regex-syntax" -version = "0.6.25" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f497285884f3fcff424ffc933e56d7cbca511def0c9831a7f9b5f6153e3cc89b" +checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" diff --git a/Cargo.toml b/Cargo.toml index b8707c3..835ab96 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -2,7 +2,7 @@ name = "calcit_regex" version = "0.0.2" authors = ["jiyinyiyong "] -edition = "2018" +edition = "2021" [lib] name = "calcit_std" @@ -13,6 +13,6 @@ crate-type = ["dylib"] # Creates dynamic lib # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -cirru_edn = "0.2.11" -cirru_parser = "0.1.16" -regex = "1.5.4" +cirru_edn = "0.5.0" +cirru_parser = "0.1.25" +regex = "1.8.4" diff --git a/build.sh b/build.sh index 3ed301b..88d50bc 100755 --- a/build.sh +++ b/build.sh @@ -1,3 +1,4 @@ +rm -rfv dylibs cargo build --release mkdir -p dylibs/ && ls target/release/ && cp -v target/release/*.* dylibs/ diff --git a/calcit.cirru b/calcit.cirru index 143ef69..3aa54fb 100644 --- a/calcit.cirru +++ b/calcit.cirru @@ -1,393 +1,401 @@ -{} - :users $ {} - |u0 $ {} (:theme :star-trail) (:id |u0) (:name |chen) (:nickname |chen) (:avatar nil) (:password |d41d8cd98f00b204e9800998ecf8427e) - :ir $ {} (:package |regex) - :files $ {} - |regex.core $ {} - :ns $ {} (:type :expr) (:by |u0) (:at 1636960151241) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |ns) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |regex.core) - |r $ {} (:type :expr) (:by |u0) (:at 1636960151241) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |:require) - |j $ {} (:type :expr) (:by |u0) (:at 1636960151241) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |regex.$meta) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |:refer) - |r $ {} (:type :expr) (:by |u0) (:at 1636960151241) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |calcit-dirname) - |r $ {} (:type :expr) (:by |u0) (:at 1636960151241) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |regex.util) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |:refer) - |r $ {} (:type :expr) (:by |u0) (:at 1636960151241) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |get-dylib-path) - :defs $ {} - |re-find-all $ {} (:type :expr) (:by |u0) (:at 1636960151241) +{} (:package |regex) + :configs $ {} (:init-fn |regex.test/main!) (:port 6001) (:reload-fn |regex.test/reload!) (:version |0.0.3) + :modules $ [] + :entries $ {} + :files $ {} + |regex.core $ %{} :FileEntry + :defs $ {} + |re-find $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |defn) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |re-find-all) - |r $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |defn) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |re-find) + |r $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |s) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |pattern) - |v $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |s) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |pattern) + |v $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |&call-dylib-edn) - |j $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |&call-dylib-edn) + |j $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |get-dylib-path) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text "|\"/dylibs/libcalcit_std") - |r $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text "|\"re_find_all") - |v $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |s) - |x $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |pattern) - |re-matches $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |get-dylib-path) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text "|\"/dylibs/libcalcit_std") + |r $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text "|\"re_find") + |v $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |s) + |x $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |pattern) + |re-find-all $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |defn) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |re-matches) - |r $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |defn) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |re-find-all) + |r $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |s) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |pattern) - |v $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |s) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |pattern) + |v $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |&call-dylib-edn) - |j $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |&call-dylib-edn) + |j $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |get-dylib-path) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text "|\"/dylibs/libcalcit_std") - |r $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text "|\"re_matches") - |v $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |s) - |x $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |pattern) - |re-find-index $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |get-dylib-path) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text "|\"/dylibs/libcalcit_std") + |r $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text "|\"re_find_all") + |v $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |s) + |x $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |pattern) + |re-find-index $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |defn) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |re-find-index) - |r $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |defn) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |re-find-index) + |r $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |s) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |pattern) - |v $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |s) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |pattern) + |v $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |&call-dylib-edn) - |j $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |&call-dylib-edn) + |j $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |get-dylib-path) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text "|\"/dylibs/libcalcit_std") - |r $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text "|\"re_find_index") - |v $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |s) - |x $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |pattern) - |re-find $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |get-dylib-path) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text "|\"/dylibs/libcalcit_std") + |r $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text "|\"re_find_index") + |v $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |s) + |x $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |pattern) + |re-matches $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |defn) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |re-find) - |r $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |defn) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |re-matches) + |r $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |s) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |pattern) - |v $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |s) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |pattern) + |v $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |&call-dylib-edn) - |j $ {} (:type :expr) (:by |u0) (:at 1636960151241) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |&call-dylib-edn) + |j $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |get-dylib-path) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text "|\"/dylibs/libcalcit_std") - |r $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text "|\"re_find") - |v $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |s) - |x $ {} (:type :leaf) (:by |u0) (:at 1636960151241) (:text |pattern) - |re-split $ {} (:type :expr) (:by |u0) (:at 1637157509604) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |get-dylib-path) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text "|\"/dylibs/libcalcit_std") + |r $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text "|\"re_matches") + |v $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |s) + |x $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |pattern) + |re-replace-all $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1637157516835) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157509604) (:text |defn) - |j $ {} (:type :leaf) (:by |u0) (:at 1637157509604) (:text |re-split) - |r $ {} (:type :expr) (:by |u0) (:at 1637157527168) + |T $ %{} :Leaf (:at 1637157516835) (:by |u0) (:text |defn) + |j $ %{} :Leaf (:at 1637157516835) (:by |u0) (:text |re-replace-all) + |r $ %{} :Expr (:at 1637157540472) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157527168) (:text |s) - |j $ {} (:type :leaf) (:by |u0) (:at 1637157527168) (:text |pattern) - |v $ {} (:type :expr) (:by |u0) (:at 1637157527168) + |T $ %{} :Leaf (:at 1637157540472) (:by |u0) (:text |s) + |j $ %{} :Leaf (:at 1637157540472) (:by |u0) (:text |pattern) + |r $ %{} :Leaf (:at 1637157547063) (:by |u0) (:text |next) + |v $ %{} :Expr (:at 1637157540472) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157527168) (:text |&call-dylib-edn) - |j $ {} (:type :expr) (:by |u0) (:at 1637157527168) + |T $ %{} :Leaf (:at 1637157540472) (:by |u0) (:text |&call-dylib-edn) + |j $ %{} :Expr (:at 1637157540472) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157527168) (:text |get-dylib-path) - |j $ {} (:type :leaf) (:by |u0) (:at 1637157527168) (:text "|\"/dylibs/libcalcit_std") - |r $ {} (:type :leaf) (:by |u0) (:at 1637157535118) (:text "|\"re_split") - |v $ {} (:type :leaf) (:by |u0) (:at 1637157527168) (:text |s) - |x $ {} (:type :leaf) (:by |u0) (:at 1637157527168) (:text |pattern) - |re-replace-all $ {} (:type :expr) (:by |u0) (:at 1637157516835) + |T $ %{} :Leaf (:at 1637157540472) (:by |u0) (:text |get-dylib-path) + |j $ %{} :Leaf (:at 1637157540472) (:by |u0) (:text "|\"/dylibs/libcalcit_std") + |r $ %{} :Leaf (:at 1637157553738) (:by |u0) (:text "|\"re_replace_all") + |v $ %{} :Leaf (:at 1637157540472) (:by |u0) (:text |s) + |x $ %{} :Leaf (:at 1637157540472) (:by |u0) (:text |pattern) + |y $ %{} :Leaf (:at 1637157556670) (:by |u0) (:text |next) + |re-split $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1637157509604) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157516835) (:text |defn) - |j $ {} (:type :leaf) (:by |u0) (:at 1637157516835) (:text |re-replace-all) - |r $ {} (:type :expr) (:by |u0) (:at 1637157540472) + |T $ %{} :Leaf (:at 1637157509604) (:by |u0) (:text |defn) + |j $ %{} :Leaf (:at 1637157509604) (:by |u0) (:text |re-split) + |r $ %{} :Expr (:at 1637157527168) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157540472) (:text |s) - |j $ {} (:type :leaf) (:by |u0) (:at 1637157540472) (:text |pattern) - |r $ {} (:type :leaf) (:by |u0) (:at 1637157547063) (:text |next) - |v $ {} (:type :expr) (:by |u0) (:at 1637157540472) + |T $ %{} :Leaf (:at 1637157527168) (:by |u0) (:text |s) + |j $ %{} :Leaf (:at 1637157527168) (:by |u0) (:text |pattern) + |v $ %{} :Expr (:at 1637157527168) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157540472) (:text |&call-dylib-edn) - |j $ {} (:type :expr) (:by |u0) (:at 1637157540472) + |T $ %{} :Leaf (:at 1637157527168) (:by |u0) (:text |&call-dylib-edn) + |j $ %{} :Expr (:at 1637157527168) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157540472) (:text |get-dylib-path) - |j $ {} (:type :leaf) (:by |u0) (:at 1637157540472) (:text "|\"/dylibs/libcalcit_std") - |r $ {} (:type :leaf) (:by |u0) (:at 1637157553738) (:text "|\"re_replace_all") - |v $ {} (:type :leaf) (:by |u0) (:at 1637157540472) (:text |s) - |x $ {} (:type :leaf) (:by |u0) (:at 1637157540472) (:text |pattern) - |y $ {} (:type :leaf) (:by |u0) (:at 1637157556670) (:text |next) - |regex.util $ {} - :ns $ {} (:type :expr) (:by |u0) (:at 1633181044360) + |T $ %{} :Leaf (:at 1637157527168) (:by |u0) (:text |get-dylib-path) + |j $ %{} :Leaf (:at 1637157527168) (:by |u0) (:text "|\"/dylibs/libcalcit_std") + |r $ %{} :Leaf (:at 1637157535118) (:by |u0) (:text "|\"re_split") + |v $ %{} :Leaf (:at 1637157527168) (:by |u0) (:text |s) + |x $ %{} :Leaf (:at 1637157527168) (:by |u0) (:text |pattern) + :ns $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1633181044360) (:text |ns) - |j $ {} (:type :leaf) (:by |u0) (:at 1633181044360) (:text |regex.util) - |r $ {} (:type :expr) (:by |u0) (:at 1634804160546) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |ns) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |regex.core) + |r $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1634804161330) (:text |:require) - |j $ {} (:type :expr) (:by |u0) (:at 1634804162771) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |:require) + |j $ %{} :Expr (:at 1636960151241) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |regex.$meta) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |:refer) + |r $ %{} :Expr (:at 1636960151241) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |calcit-dirname) + |r $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960076571) (:text |regex.$meta) - |j $ {} (:type :leaf) (:by |u0) (:at 1634804168120) (:text |:refer) - |r $ {} (:type :expr) (:by |u0) (:at 1634804168421) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |regex.util) + |j $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |:refer) + |r $ %{} :Expr (:at 1636960151241) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1634804171748) (:text |calcit-dirname) - |j $ {} (:type :leaf) (:by |u0) (:at 1634804175462) (:text |calcit-filename) - :configs $ {} - :defs $ {} - |get-dylib-ext $ {} (:type :expr) (:by |u0) (:at 1630231398718) + |T $ %{} :Leaf (:at 1636960151241) (:by |u0) (:text |get-dylib-path) + |regex.test $ %{} :FileEntry + :defs $ {} + |main! $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1630231418304) (:text |defmacro) - |j $ {} (:type :leaf) (:by |u0) (:at 1633181058353) (:text |get-dylib-ext) - |r $ {} (:type :expr) (:by |u0) (:at 1630231398718) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |defn) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |main!) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |v $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |println) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text "|\"%%%% test for regex") + |x $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |v $ {} (:type :expr) (:by |u0) (:at 1630231403270) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |println) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text "||Test regular expression") + |y $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1630231423910) (:text |case-default) - |b $ {} (:type :expr) (:by |u0) (:at 1630231429893) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |assert=) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |true) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1630231433951) (:text |&get-os) - |j $ {} (:type :leaf) (:by |u0) (:at 1630231427453) (:text "|\".so") - |r $ {} (:type :expr) (:by |u0) (:at 1630231437150) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-matches) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||2) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||\d) + |yT $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |assert=) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |true) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1630231439152) (:text |:macos) - |j $ {} (:type :leaf) (:by |u0) (:at 1630231447585) (:text "|\".dylib") - |v $ {} (:type :expr) (:by |u0) (:at 1630231448478) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-matches) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||23) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||\d+) + |yj $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |assert=) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |false) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1630231449901) (:text |:windows) - |j $ {} (:type :leaf) (:by |u0) (:at 1630231461388) (:text "|\".dll") - |get-dylib-path $ {} (:type :expr) (:by |u0) (:at 1634804142034) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1634804142034) (:text |defn) - |j $ {} (:type :leaf) (:by |u0) (:at 1634804142034) (:text |get-dylib-path) - |n $ {} (:type :expr) (:by |u0) (:at 1634804146574) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1634804230294) (:text |p) - |r $ {} (:type :expr) (:by |u0) (:at 1634804145483) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1634804145483) (:text |str) - |j $ {} (:type :expr) (:by |u0) (:at 1634804145483) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-matches) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||a) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||\d) + |yr $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |assert=) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text "|\"4") + |r $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1634804145483) (:text |or-current-path) - |j $ {} (:type :leaf) (:by |u0) (:at 1634804145483) (:text |calcit-dirname) - |r $ {} (:type :leaf) (:by |u0) (:at 1634804157377) (:text |p) - |v $ {} (:type :expr) (:by |u0) (:at 1634804145483) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-find) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||a4) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||\d) + |yv $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |assert=) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |1) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1634804145483) (:text |get-dylib-ext) - |or-current-path $ {} (:type :expr) (:by |u0) (:at 1630245582276) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1630245583936) (:text |defn) - |j $ {} (:type :leaf) (:by |u0) (:at 1633181131099) (:text |or-current-path) - |r $ {} (:type :expr) (:by |u0) (:at 1630245582276) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1630245585364) (:text |p) - |v $ {} (:type :expr) (:by |u0) (:at 1630245585942) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1630245586336) (:text |if) - |j $ {} (:type :expr) (:by |u0) (:at 1630245586894) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-find-index) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||a1) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||\d) + |yx $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |assert=) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |-1) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1630245614560) (:text |blank?) - |j $ {} (:type :leaf) (:by |u0) (:at 1630245615061) (:text |p) - |r $ {} (:type :leaf) (:by |u0) (:at 1630245616843) (:text "|\".") - |v $ {} (:type :leaf) (:by |u0) (:at 1630245618366) (:text |p) - :proc $ {} (:type :expr) (:by |u0) (:at 1633181044360) - :data $ {} - |regex.test $ {} - :ns $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |ns) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |regex.test) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |:require) - |j $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |regex.core) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |:refer) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-matches) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-find-index) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-find) - |v $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-find-all) - |x $ {} (:type :leaf) (:by |u0) (:at 1637157659783) (:text |re-split) - |y $ {} (:type :leaf) (:by |u0) (:at 1637157663541) (:text |re-replace-all) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |regex.$meta) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |:refer) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |calcit-dirname) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |calcit-filename) - :defs $ {} - |main! $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |yyT $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-find-index) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||aa) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||\d) + |yy $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |assert=) - |j $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |assert=) + |j $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |[]) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||123) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |[]) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||1) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||2) + |v $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||3) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-find-all) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||123) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||\d+) - |yyj $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-find-all) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||123) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||\d) + |yyT $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |assert=) - |j $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |assert=) + |j $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |[]) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||1) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||2) - |v $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||3) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |[]) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||123) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-find-all) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||1a2a3) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||\d+) - |yyr $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-find-all) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||123) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||\d+) + |yyj $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |assert=) - |j $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |assert=) + |j $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |[]) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||1) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||2) - |v $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||34) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |[]) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||1) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||2) + |v $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||3) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-find-all) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||1a2a34) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||\d+) - |yyv $ {} (:type :expr) (:by |u0) (:at 1637157564769) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157566683) (:text |assert=) - |j $ {} (:type :leaf) (:by |u0) (:at 1637157612595) (:text ||1abXcX3) - |r $ {} (:type :expr) (:by |u0) (:at 1637157570399) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-find-all) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||1a2a3) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||\d+) + |yyr $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |assert=) + |j $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157576826) (:text |re-replace-all) - |j $ {} (:type :leaf) (:by |u0) (:at 1637157591536) (:text ||1ab22c333) - |r $ {} (:type :leaf) (:by |u0) (:at 1637157596985) (:text ||\d{2}) - |v $ {} (:type :leaf) (:by |u0) (:at 1637157603611) (:text "|\"X") - |yyx $ {} (:type :expr) (:by |u0) (:at 1637157564769) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157566683) (:text |assert=) - |r $ {} (:type :expr) (:by |u0) (:at 1637157570399) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |[]) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||1) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||2) + |v $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||34) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157620368) (:text |re-split) - |j $ {} (:type :leaf) (:by |u0) (:at 1637157591536) (:text ||1ab22c333) - |r $ {} (:type :leaf) (:by |u0) (:at 1637157596985) (:text ||\d{2}) - |f $ {} (:type :expr) (:by |u0) (:at 1637157629847) + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-find-all) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||1a2a34) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text ||\d+) + |yyv $ %{} :Expr (:at 1637157564769) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1637157566683) (:by |u0) (:text |assert=) + |j $ %{} :Leaf (:at 1637157612595) (:by |u0) (:text ||1abXcX3) + |r $ %{} :Expr (:at 1637157570399) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1637157630274) (:text |[]) - |j $ {} (:type :leaf) (:by |u0) (:at 1637157635843) (:text "|\"1ab") - |r $ {} (:type :leaf) (:by |u0) (:at 1637157639002) (:text "|\"c") - |v $ {} (:type :leaf) (:by |u0) (:at 1637157640155) (:text "|\"3") - |yT $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |assert=) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |true) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1637157576826) (:by |u0) (:text |re-replace-all) + |j $ %{} :Leaf (:at 1637157591536) (:by |u0) (:text ||1ab22c333) + |r $ %{} :Leaf (:at 1637157596985) (:by |u0) (:text ||\d{2}) + |v $ %{} :Leaf (:at 1637157603611) (:by |u0) (:text "|\"X") + |yyx $ %{} :Expr (:at 1637157564769) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1637157566683) (:by |u0) (:text |assert=) + |f $ %{} :Expr (:at 1637157629847) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-matches) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||23) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||\d+) - |yj $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |assert=) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |false) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1637157630274) (:by |u0) (:text |[]) + |j $ %{} :Leaf (:at 1637157635843) (:by |u0) (:text "|\"1ab") + |r $ %{} :Leaf (:at 1637157639002) (:by |u0) (:text "|\"c") + |v $ %{} :Leaf (:at 1637157640155) (:by |u0) (:text "|\"3") + |r $ %{} :Expr (:at 1637157570399) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-matches) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||a) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||\d) - |yr $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |assert=) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text "|\"4") - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1637157620368) (:by |u0) (:text |re-split) + |j $ %{} :Leaf (:at 1637157591536) (:by |u0) (:text ||1ab22c333) + |r $ %{} :Leaf (:at 1637157596985) (:by |u0) (:text ||\d{2}) + :ns $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |ns) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |regex.test) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |:require) + |j $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |regex.core) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |:refer) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-matches) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-find-index) + |r $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-find) + |v $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |re-find-all) + |x $ %{} :Leaf (:at 1637157659783) (:by |u0) (:text |re-split) + |y $ %{} :Leaf (:at 1637157663541) (:by |u0) (:text |re-replace-all) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |regex.$meta) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |:refer) + |r $ %{} :Expr (:at 1636960219938) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |calcit-dirname) + |j $ %{} :Leaf (:at 1636960219938) (:by |u0) (:text |calcit-filename) + |regex.util $ %{} :FileEntry + :defs $ {} + |get-dylib-ext $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1630231398718) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1630231418304) (:by |u0) (:text |defmacro) + |j $ %{} :Leaf (:at 1633181058353) (:by |u0) (:text |get-dylib-ext) + |r $ %{} :Expr (:at 1630231398718) (:by |u0) + :data $ {} + |v $ %{} :Expr (:at 1630231403270) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1630231423910) (:by |u0) (:text |case-default) + |b $ %{} :Expr (:at 1630231429893) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-find) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||a4) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||\d) - |yv $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |assert=) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |1) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1630231433951) (:by |u0) (:text |&get-os) + |j $ %{} :Leaf (:at 1630231427453) (:by |u0) (:text "|\".so") + |r $ %{} :Expr (:at 1630231437150) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-find-index) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||a1) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||\d) - |yx $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |assert=) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |-1) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1630231439152) (:by |u0) (:text |:macos) + |j $ %{} :Leaf (:at 1630231447585) (:by |u0) (:text "|\".dylib") + |v $ %{} :Expr (:at 1630231448478) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-find-index) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||aa) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||\d) - |yy $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1630231449901) (:by |u0) (:text |:windows) + |j $ %{} :Leaf (:at 1630231461388) (:by |u0) (:text "|\".dll") + |get-dylib-path $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1634804142034) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1634804142034) (:by |u0) (:text |defn) + |j $ %{} :Leaf (:at 1634804142034) (:by |u0) (:text |get-dylib-path) + |n $ %{} :Expr (:at 1634804146574) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1634804230294) (:by |u0) (:text |p) + |r $ %{} :Expr (:at 1634804145483) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |assert=) - |j $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1634804145483) (:by |u0) (:text |str) + |j $ %{} :Expr (:at 1634804145483) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |[]) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||1) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||2) - |v $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||3) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1634804145483) (:by |u0) (:text |or-current-path) + |j $ %{} :Leaf (:at 1634804145483) (:by |u0) (:text |calcit-dirname) + |r $ %{} :Leaf (:at 1634804157377) (:by |u0) (:text |p) + |v $ %{} :Expr (:at 1634804145483) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-find-all) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||123) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||\d) - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |defn) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |main!) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |v $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |println) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text "|\"%%%% test for regex") - |x $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |println) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text "||Test regular expression") - |y $ {} (:type :expr) (:by |u0) (:at 1636960219938) - :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |assert=) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |true) - |r $ {} (:type :expr) (:by |u0) (:at 1636960219938) + |T $ %{} :Leaf (:at 1634804145483) (:by |u0) (:text |get-dylib-ext) + |or-current-path $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1630245582276) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1630245583936) (:by |u0) (:text |defn) + |j $ %{} :Leaf (:at 1633181131099) (:by |u0) (:text |or-current-path) + |r $ %{} :Expr (:at 1630245582276) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1630245585364) (:by |u0) (:text |p) + |v $ %{} :Expr (:at 1630245585942) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1630245586336) (:by |u0) (:text |if) + |j $ %{} :Expr (:at 1630245586894) (:by |u0) :data $ {} - |T $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text |re-matches) - |j $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||2) - |r $ {} (:type :leaf) (:by |u0) (:at 1636960219938) (:text ||\d) - :configs $ {} (:port 6001) (:init-fn |regex.test/main!) (:reload-fn |regex.test/reload!) - :modules $ [] - :version |0.0.2 - :entries $ {} + |T $ %{} :Leaf (:at 1630245614560) (:by |u0) (:text |blank?) + |j $ %{} :Leaf (:at 1630245615061) (:by |u0) (:text |p) + |r $ %{} :Leaf (:at 1630245616843) (:by |u0) (:text "|\".") + |v $ %{} :Leaf (:at 1630245618366) (:by |u0) (:text |p) + :ns $ %{} :CodeEntry (:doc |) + :code $ %{} :Expr (:at 1633181044360) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1633181044360) (:by |u0) (:text |ns) + |j $ %{} :Leaf (:at 1633181044360) (:by |u0) (:text |regex.util) + |r $ %{} :Expr (:at 1634804160546) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1634804161330) (:by |u0) (:text |:require) + |j $ %{} :Expr (:at 1634804162771) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1636960076571) (:by |u0) (:text |regex.$meta) + |j $ %{} :Leaf (:at 1634804168120) (:by |u0) (:text |:refer) + |r $ %{} :Expr (:at 1634804168421) (:by |u0) + :data $ {} + |T $ %{} :Leaf (:at 1634804171748) (:by |u0) (:text |calcit-dirname) + |j $ %{} :Leaf (:at 1634804175462) (:by |u0) (:text |calcit-filename) + :users $ {} + |u0 $ {} (:avatar nil) (:id |u0) (:name |chen) (:nickname |chen) (:password |d41d8cd98f00b204e9800998ecf8427e) (:theme :star-trail) diff --git a/compact.cirru b/compact.cirru index e569d2a..213fcea 100644 --- a/compact.cirru +++ b/compact.cirru @@ -1,64 +1,76 @@ {} (:package |regex) - :configs $ {} (:init-fn |regex.test/main!) (:reload-fn |regex.test/reload!) + :configs $ {} (:init-fn |regex.test/main!) (:reload-fn |regex.test/reload!) (:version |0.0.3) :modules $ [] - :version |0.0.2 :entries $ {} :files $ {} - |regex.core $ {} - :ns $ quote - ns regex.core $ :require - regex.$meta :refer $ calcit-dirname - regex.util :refer $ get-dylib-path + |regex.core $ %{} :FileEntry :defs $ {} - |re-find-all $ quote - defn re-find-all (s pattern) - &call-dylib-edn (get-dylib-path "\"/dylibs/libcalcit_std") "\"re_find_all" s pattern - |re-matches $ quote - defn re-matches (s pattern) - &call-dylib-edn (get-dylib-path "\"/dylibs/libcalcit_std") "\"re_matches" s pattern - |re-find-index $ quote - defn re-find-index (s pattern) - &call-dylib-edn (get-dylib-path "\"/dylibs/libcalcit_std") "\"re_find_index" s pattern - |re-find $ quote - defn re-find (s pattern) - &call-dylib-edn (get-dylib-path "\"/dylibs/libcalcit_std") "\"re_find" s pattern - |re-split $ quote - defn re-split (s pattern) - &call-dylib-edn (get-dylib-path "\"/dylibs/libcalcit_std") "\"re_split" s pattern - |re-replace-all $ quote - defn re-replace-all (s pattern next) - &call-dylib-edn (get-dylib-path "\"/dylibs/libcalcit_std") "\"re_replace_all" s pattern next - |regex.util $ {} - :ns $ quote - ns regex.util $ :require - regex.$meta :refer $ calcit-dirname calcit-filename + |re-find $ %{} :CodeEntry (:doc |) + :code $ quote + defn re-find (s pattern) + &call-dylib-edn (get-dylib-path "\"/dylibs/libcalcit_std") "\"re_find" s pattern + |re-find-all $ %{} :CodeEntry (:doc |) + :code $ quote + defn re-find-all (s pattern) + &call-dylib-edn (get-dylib-path "\"/dylibs/libcalcit_std") "\"re_find_all" s pattern + |re-find-index $ %{} :CodeEntry (:doc |) + :code $ quote + defn re-find-index (s pattern) + &call-dylib-edn (get-dylib-path "\"/dylibs/libcalcit_std") "\"re_find_index" s pattern + |re-matches $ %{} :CodeEntry (:doc |) + :code $ quote + defn re-matches (s pattern) + &call-dylib-edn (get-dylib-path "\"/dylibs/libcalcit_std") "\"re_matches" s pattern + |re-replace-all $ %{} :CodeEntry (:doc |) + :code $ quote + defn re-replace-all (s pattern next) + &call-dylib-edn (get-dylib-path "\"/dylibs/libcalcit_std") "\"re_replace_all" s pattern next + |re-split $ %{} :CodeEntry (:doc |) + :code $ quote + defn re-split (s pattern) + &call-dylib-edn (get-dylib-path "\"/dylibs/libcalcit_std") "\"re_split" s pattern + :ns $ %{} :CodeEntry (:doc |) + :code $ quote + ns regex.core $ :require + regex.$meta :refer $ calcit-dirname + regex.util :refer $ get-dylib-path + |regex.test $ %{} :FileEntry :defs $ {} - |get-dylib-ext $ quote - defmacro get-dylib-ext () $ case-default (&get-os) "\".so" (:macos "\".dylib") (:windows "\".dll") - |get-dylib-path $ quote - defn get-dylib-path (p) - str (or-current-path calcit-dirname) p $ get-dylib-ext - |or-current-path $ quote - defn or-current-path (p) - if (blank? p) "\"." p - |regex.test $ {} - :ns $ quote - ns regex.test $ :require - regex.core :refer $ re-matches re-find-index re-find re-find-all re-split re-replace-all - regex.$meta :refer $ calcit-dirname calcit-filename + |main! $ %{} :CodeEntry (:doc |) + :code $ quote + defn main! () (println "\"%%%% test for regex") (println "|Test regular expression") + assert= true $ re-matches |2 |\d + assert= true $ re-matches |23 |\d+ + assert= false $ re-matches |a |\d + assert= "\"4" $ re-find |a4 |\d + assert= 1 $ re-find-index |a1 |\d + assert= -1 $ re-find-index |aa |\d + assert= ([] |1 |2 |3) (re-find-all |123 |\d) + assert= ([] |123) (re-find-all |123 |\d+) + assert= ([] |1 |2 |3) (re-find-all |1a2a3 |\d+) + assert= ([] |1 |2 |34) (re-find-all |1a2a34 |\d+) + assert= |1abXcX3 $ re-replace-all |1ab22c333 |\d{2} "\"X" + assert= ([] "\"1ab" "\"c" "\"3") (re-split |1ab22c333 |\d{2}) + :ns $ %{} :CodeEntry (:doc |) + :code $ quote + ns regex.test $ :require + regex.core :refer $ re-matches re-find-index re-find re-find-all re-split re-replace-all + regex.$meta :refer $ calcit-dirname calcit-filename + |regex.util $ %{} :FileEntry :defs $ {} - |main! $ quote - defn main! () (println "\"%%%% test for regex") (println "|Test regular expression") - assert= true $ re-matches |2 |\d - assert= true $ re-matches |23 |\d+ - assert= false $ re-matches |a |\d - assert= "\"4" $ re-find |a4 |\d - assert= 1 $ re-find-index |a1 |\d - assert= -1 $ re-find-index |aa |\d - assert= ([] |1 |2 |3) (re-find-all |123 |\d) - assert= ([] |123) (re-find-all |123 |\d+) - assert= ([] |1 |2 |3) (re-find-all |1a2a3 |\d+) - assert= ([] |1 |2 |34) (re-find-all |1a2a34 |\d+) - assert= |1abXcX3 $ re-replace-all |1ab22c333 |\d{2} "\"X" - assert= ([] "\"1ab" "\"c" "\"3") (re-split |1ab22c333 |\d{2}) + |get-dylib-ext $ %{} :CodeEntry (:doc |) + :code $ quote + defmacro get-dylib-ext () $ case-default (&get-os) "\".so" (:macos "\".dylib") (:windows "\".dll") + |get-dylib-path $ %{} :CodeEntry (:doc |) + :code $ quote + defn get-dylib-path (p) + str (or-current-path calcit-dirname) p $ get-dylib-ext + |or-current-path $ %{} :CodeEntry (:doc |) + :code $ quote + defn or-current-path (p) + if (blank? p) "\"." p + :ns $ %{} :CodeEntry (:doc |) + :code $ quote + ns regex.util $ :require + regex.$meta :refer $ calcit-dirname calcit-filename