Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

20221217 assign #103

Merged
merged 42 commits into from
Aug 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
50d7dec
WIP assign
prozacchiwawa Dec 20, 2022
02cbf82
Assign WIP part 2: patterns woven in without disturbing users of non-…
prozacchiwawa Dec 20, 2022
6cae84f
A couple more things and it'll be good
prozacchiwawa Dec 20, 2022
b5e6728
Some tests (needs lots more)
prozacchiwawa Dec 20, 2022
1aaca9c
Merge remote-tracking branch 'chia/base' into 20221217-assign
prozacchiwawa Dec 22, 2022
5e71ceb
Tests of assign
prozacchiwawa Dec 22, 2022
52405bd
Add more tests for assign form
prozacchiwawa Dec 23, 2022
23b12d8
Add some basic toposort tests
prozacchiwawa Dec 23, 2022
b0aa0bf
fmt + clippy
prozacchiwawa Dec 23, 2022
04cc061
fmt
prozacchiwawa Dec 23, 2022
227ec90
Clean up spam
prozacchiwawa Jan 3, 2023
f2b26aa
Pull base, remove spam
prozacchiwawa Jan 3, 2023
84b1e70
Add duplicate binding check
prozacchiwawa Jan 4, 2023
abc7357
Merge branch 'base' into 20221217-assign
prozacchiwawa Jan 12, 2023
e01676a
Merge remote-tracking branch 'chia/base' into 20221217-assign
prozacchiwawa Feb 1, 2023
0f54e04
merge up + fmt + clippy
prozacchiwawa Feb 1, 2023
71afd1f
merge up
prozacchiwawa Feb 4, 2023
6e24388
Merge up
prozacchiwawa Feb 7, 2023
69504c7
Merge up
prozacchiwawa Mar 16, 2023
aaacf4b
Add selection for assign inlining
prozacchiwawa Mar 17, 2023
9c3a7c7
Move to box to tighten the stack up
prozacchiwawa Mar 17, 2023
1e34276
Improve a bit so we don't clobber non-inline assigns via the first st…
prozacchiwawa Mar 17, 2023
af18062
Merge remote-tracking branch 'chia/base' into 20221217-assign
prozacchiwawa Apr 6, 2023
17fbb55
Change default to non-inline
prozacchiwawa Apr 20, 2023
8de55ad
Revert "Change default to non-inline"
prozacchiwawa Apr 21, 2023
38a63d9
Merge up
prozacchiwawa Apr 26, 2023
00d2e13
Try updating requests on behalf of twine re: error in ci
prozacchiwawa Apr 26, 2023
95a7a46
Merge up
prozacchiwawa May 17, 2023
3babcdb
Update from assign refactor
prozacchiwawa May 22, 2023
cd03d68
fmt + clippy
prozacchiwawa May 22, 2023
16b26d5
Merge up base
prozacchiwawa Aug 3, 2023
b593df5
Merge up base
prozacchiwawa Aug 8, 2023
b1f6730
Merge up
prozacchiwawa Aug 14, 2023
3a7bd43
Pull in fixes from nightly
prozacchiwawa Aug 14, 2023
2f2d70e
fmt + clippy
prozacchiwawa Aug 14, 2023
f5005e9
Add commentary and do some light refactoring
prozacchiwawa Aug 15, 2023
f7dac02
fmt + clippy
prozacchiwawa Aug 15, 2023
012c212
Add some matrix style assign tests
prozacchiwawa Aug 15, 2023
fc74dff
Exclude tests from coverage now that we have an ignored test
prozacchiwawa Aug 15, 2023
a4a6be7
Merge up base
prozacchiwawa Aug 15, 2023
4055053
Merge up
prozacchiwawa Aug 15, 2023
b07a31f
Opps remove merge marks
prozacchiwawa Aug 16, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,10 @@ jobs:
if: startsWith(matrix.os, 'ubuntu') && startsWith(matrix.python, '3.8')
run: cargo test --no-default-features

- name: Exhaustive assign tests
if: startsWith(matrix.os, 'ubuntu') && startsWith(matrix.python, '3.8')
run: cargo test -- --include-ignored assign

- name: Check coverage
if: startsWith(matrix.os, 'ubuntu') && startsWith(matrix.python, '3.8')
run: |
Expand Down
2 changes: 1 addition & 1 deletion resources/coverage/run_coverage.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ def collect_coverage():
required_percentage = int(args.require_percent)
has_required_pct = True

for file in result:
for file in filter(lambda f: '/tests/' not in f['name'], result):
have_pct = int(file['coveragePercent'])
if have_pct < required_percentage:
print(f"{file['name']} lacks required coverage have {have_pct} want {required_percentage}")
Expand Down
39 changes: 39 additions & 0 deletions resources/tests/chia-gaming/last.clinc
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
(
(defun last_inner ((next . remainder))
(if remainder
(last_inner remainder)
next
)
)

(defmacro last ARGS
(defun snoc (L agg)
(if L
(if (r L)
(snoc (r L) (c (f L) agg))
(c (f L) agg)
)
(c () ())
)
)

(defun prefix (L P)
(if L
(c (f L) (prefix (r L) P))
P
)
)

(if ARGS
(if (r ARGS)
(assign
(final . rest) (snoc ARGS ())
reversed (prefix rest (list final))
(qq (last_inner (unquote (c list reversed))))
)
(qq (last_inner (unquote (f ARGS))))
)
(x "Last takes at least one argument")
)
)
)
6 changes: 6 additions & 0 deletions resources/tests/chia-gaming/test-last.clsp
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
(mod ()
(include *standard-cl-21*)
(include last.clinc)

(last 99 100 101)
)
Loading
Loading